@wraps.dev/cli 2.2.0 → 2.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,471 @@
1
+ var yU=Object.defineProperty;var bU=(e,t,n)=>t in e?yU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var rb=(e,t,n)=>bU(e,typeof t!="symbol"?t+"":t,n);function xU(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const o=Object.getOwnPropertyDescriptor(r,i);o&&Object.defineProperty(e,i,o.get?o:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const l of o.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=n(i);fetch(i.href,o)}})();var mh=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function bt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ab={exports:{}},hu={};/**
2
+ * @license React
3
+ * react-jsx-runtime.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and 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 L2;function wU(){if(L2)return hu;L2=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,o){var l=null;if(o!==void 0&&(l=""+o),i.key!==void 0&&(l=""+i.key),"key"in i){o={};for(var u in i)u!=="key"&&(o[u]=i[u])}else o=i;return i=o.ref,{$$typeof:e,type:r,key:l,ref:i!==void 0?i:null,props:o}}return hu.Fragment=t,hu.jsx=n,hu.jsxs=n,hu}var z2;function SU(){return z2||(z2=1,ab.exports=wU()),ab.exports}var c=SU(),ib={exports:{}},Le={};/**
10
+ * @license React
11
+ * react.production.js
12
+ *
13
+ * Copyright (c) Meta Platforms, Inc. and 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 B2;function jU(){if(B2)return Le;B2=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),l=Symbol.for("react.context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),v=Symbol.for("react.lazy"),p=Symbol.for("react.activity"),g=Symbol.iterator;function b($){return $===null||typeof $!="object"?null:($=g&&$[g]||$["@@iterator"],typeof $=="function"?$:null)}var O={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},j=Object.assign,x={};function _($,V,q){this.props=$,this.context=V,this.refs=x,this.updater=q||O}_.prototype.isReactComponent={},_.prototype.setState=function($,V){if(typeof $!="object"&&typeof $!="function"&&$!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,$,V,"setState")},_.prototype.forceUpdate=function($){this.updater.enqueueForceUpdate(this,$,"forceUpdate")};function A(){}A.prototype=_.prototype;function E($,V,q){this.props=$,this.context=V,this.refs=x,this.updater=q||O}var C=E.prototype=new A;C.constructor=E,j(C,_.prototype),C.isPureReactComponent=!0;var N=Array.isArray;function M(){}var R={H:null,A:null,T:null,S:null},D=Object.prototype.hasOwnProperty;function z($,V,q){var U=q.ref;return{$$typeof:e,type:$,key:V,ref:U!==void 0?U:null,props:q}}function Y($,V){return z($.type,V,$.props)}function L($){return typeof $=="object"&&$!==null&&$.$$typeof===e}function F($){var V={"=":"=0",":":"=2"};return"$"+$.replace(/[=:]/g,function(q){return V[q]})}var W=/\/+/g;function Q($,V){return typeof $=="object"&&$!==null&&$.key!=null?F(""+$.key):V.toString(36)}function X($){switch($.status){case"fulfilled":return $.value;case"rejected":throw $.reason;default:switch(typeof $.status=="string"?$.then(M,M):($.status="pending",$.then(function(V){$.status==="pending"&&($.status="fulfilled",$.value=V)},function(V){$.status==="pending"&&($.status="rejected",$.reason=V)})),$.status){case"fulfilled":return $.value;case"rejected":throw $.reason}}throw $}function k($,V,q,U,ne){var fe=typeof $;(fe==="undefined"||fe==="boolean")&&($=null);var ie=!1;if($===null)ie=!0;else switch(fe){case"bigint":case"string":case"number":ie=!0;break;case"object":switch($.$$typeof){case e:case t:ie=!0;break;case v:return ie=$._init,k(ie($._payload),V,q,U,ne)}}if(ie)return ne=ne($),ie=U===""?"."+Q($,0):U,N(ne)?(q="",ie!=null&&(q=ie.replace(W,"$&/")+"/"),k(ne,V,q,"",function(ve){return ve})):ne!=null&&(L(ne)&&(ne=Y(ne,q+(ne.key==null||$&&$.key===ne.key?"":(""+ne.key).replace(W,"$&/")+"/")+ie)),V.push(ne)),1;ie=0;var pe=U===""?".":U+":";if(N($))for(var re=0;re<$.length;re++)U=$[re],fe=pe+Q(U,re),ie+=k(U,V,q,fe,ne);else if(re=b($),typeof re=="function")for($=re.call($),re=0;!(U=$.next()).done;)U=U.value,fe=pe+Q(U,re++),ie+=k(U,V,q,fe,ne);else if(fe==="object"){if(typeof $.then=="function")return k(X($),V,q,U,ne);throw V=String($),Error("Objects are not valid as a React child (found: "+(V==="[object Object]"?"object with keys {"+Object.keys($).join(", ")+"}":V)+"). If you meant to render a collection of children, use an array instead.")}return ie}function H($,V,q){if($==null)return $;var U=[],ne=0;return k($,U,"","",function(fe){return V.call(q,fe,ne++)}),U}function B($){if($._status===-1){var V=$._result;V=V(),V.then(function(q){($._status===0||$._status===-1)&&($._status=1,$._result=q)},function(q){($._status===0||$._status===-1)&&($._status=2,$._result=q)}),$._status===-1&&($._status=0,$._result=V)}if($._status===1)return $._result.default;throw $._result}var Z=typeof reportError=="function"?reportError:function($){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var V=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof $=="object"&&$!==null&&typeof $.message=="string"?String($.message):String($),error:$});if(!window.dispatchEvent(V))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",$);return}console.error($)},le={map:H,forEach:function($,V,q){H($,function(){V.apply(this,arguments)},q)},count:function($){var V=0;return H($,function(){V++}),V},toArray:function($){return H($,function(V){return V})||[]},only:function($){if(!L($))throw Error("React.Children.only expected to receive a single React element child.");return $}};return Le.Activity=p,Le.Children=le,Le.Component=_,Le.Fragment=n,Le.Profiler=i,Le.PureComponent=E,Le.StrictMode=r,Le.Suspense=d,Le.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=R,Le.__COMPILER_RUNTIME={__proto__:null,c:function($){return R.H.useMemoCache($)}},Le.cache=function($){return function(){return $.apply(null,arguments)}},Le.cacheSignal=function(){return null},Le.cloneElement=function($,V,q){if($==null)throw Error("The argument must be a React element, but you passed "+$+".");var U=j({},$.props),ne=$.key;if(V!=null)for(fe in V.key!==void 0&&(ne=""+V.key),V)!D.call(V,fe)||fe==="key"||fe==="__self"||fe==="__source"||fe==="ref"&&V.ref===void 0||(U[fe]=V[fe]);var fe=arguments.length-2;if(fe===1)U.children=q;else if(1<fe){for(var ie=Array(fe),pe=0;pe<fe;pe++)ie[pe]=arguments[pe+2];U.children=ie}return z($.type,ne,U)},Le.createContext=function($){return $={$$typeof:l,_currentValue:$,_currentValue2:$,_threadCount:0,Provider:null,Consumer:null},$.Provider=$,$.Consumer={$$typeof:o,_context:$},$},Le.createElement=function($,V,q){var U,ne={},fe=null;if(V!=null)for(U in V.key!==void 0&&(fe=""+V.key),V)D.call(V,U)&&U!=="key"&&U!=="__self"&&U!=="__source"&&(ne[U]=V[U]);var ie=arguments.length-2;if(ie===1)ne.children=q;else if(1<ie){for(var pe=Array(ie),re=0;re<ie;re++)pe[re]=arguments[re+2];ne.children=pe}if($&&$.defaultProps)for(U in ie=$.defaultProps,ie)ne[U]===void 0&&(ne[U]=ie[U]);return z($,fe,ne)},Le.createRef=function(){return{current:null}},Le.forwardRef=function($){return{$$typeof:u,render:$}},Le.isValidElement=L,Le.lazy=function($){return{$$typeof:v,_payload:{_status:-1,_result:$},_init:B}},Le.memo=function($,V){return{$$typeof:h,type:$,compare:V===void 0?null:V}},Le.startTransition=function($){var V=R.T,q={};R.T=q;try{var U=$(),ne=R.S;ne!==null&&ne(q,U),typeof U=="object"&&U!==null&&typeof U.then=="function"&&U.then(M,Z)}catch(fe){Z(fe)}finally{V!==null&&q.types!==null&&(V.types=q.types),R.T=V}},Le.unstable_useCacheRefresh=function(){return R.H.useCacheRefresh()},Le.use=function($){return R.H.use($)},Le.useActionState=function($,V,q){return R.H.useActionState($,V,q)},Le.useCallback=function($,V){return R.H.useCallback($,V)},Le.useContext=function($){return R.H.useContext($)},Le.useDebugValue=function(){},Le.useDeferredValue=function($,V){return R.H.useDeferredValue($,V)},Le.useEffect=function($,V){return R.H.useEffect($,V)},Le.useEffectEvent=function($){return R.H.useEffectEvent($)},Le.useId=function(){return R.H.useId()},Le.useImperativeHandle=function($,V,q){return R.H.useImperativeHandle($,V,q)},Le.useInsertionEffect=function($,V){return R.H.useInsertionEffect($,V)},Le.useLayoutEffect=function($,V){return R.H.useLayoutEffect($,V)},Le.useMemo=function($,V){return R.H.useMemo($,V)},Le.useOptimistic=function($,V){return R.H.useOptimistic($,V)},Le.useReducer=function($,V,q){return R.H.useReducer($,V,q)},Le.useRef=function($){return R.H.useRef($)},Le.useState=function($){return R.H.useState($)},Le.useSyncExternalStore=function($,V,q){return R.H.useSyncExternalStore($,V,q)},Le.useTransition=function(){return R.H.useTransition()},Le.version="19.2.3",Le}var q2;function Ep(){return q2||(q2=1,ib.exports=jU()),ib.exports}var w=Ep();const I=bt(w),Dj=xU({__proto__:null,default:I},[w]);var ob={exports:{}},mu={},sb={exports:{}},lb={};/**
18
+ * @license React
19
+ * scheduler.production.js
20
+ *
21
+ * Copyright (c) Meta Platforms, Inc. and 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
+ */var U2;function OU(){return U2||(U2=1,(function(e){function t(k,H){var B=k.length;k.push(H);e:for(;0<B;){var Z=B-1>>>1,le=k[Z];if(0<i(le,H))k[Z]=H,k[B]=le,B=Z;else break e}}function n(k){return k.length===0?null:k[0]}function r(k){if(k.length===0)return null;var H=k[0],B=k.pop();if(B!==H){k[0]=B;e:for(var Z=0,le=k.length,$=le>>>1;Z<$;){var V=2*(Z+1)-1,q=k[V],U=V+1,ne=k[U];if(0>i(q,B))U<le&&0>i(ne,q)?(k[Z]=ne,k[U]=B,Z=U):(k[Z]=q,k[V]=B,Z=V);else if(U<le&&0>i(ne,B))k[Z]=ne,k[U]=B,Z=U;else break e}}return H}function i(k,H){var B=k.sortIndex-H.sortIndex;return B!==0?B:k.id-H.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var l=Date,u=l.now();e.unstable_now=function(){return l.now()-u}}var d=[],h=[],v=1,p=null,g=3,b=!1,O=!1,j=!1,x=!1,_=typeof setTimeout=="function"?setTimeout:null,A=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;function C(k){for(var H=n(h);H!==null;){if(H.callback===null)r(h);else if(H.startTime<=k)r(h),H.sortIndex=H.expirationTime,t(d,H);else break;H=n(h)}}function N(k){if(j=!1,C(k),!O)if(n(d)!==null)O=!0,M||(M=!0,F());else{var H=n(h);H!==null&&X(N,H.startTime-k)}}var M=!1,R=-1,D=5,z=-1;function Y(){return x?!0:!(e.unstable_now()-z<D)}function L(){if(x=!1,M){var k=e.unstable_now();z=k;var H=!0;try{e:{O=!1,j&&(j=!1,A(R),R=-1),b=!0;var B=g;try{t:{for(C(k),p=n(d);p!==null&&!(p.expirationTime>k&&Y());){var Z=p.callback;if(typeof Z=="function"){p.callback=null,g=p.priorityLevel;var le=Z(p.expirationTime<=k);if(k=e.unstable_now(),typeof le=="function"){p.callback=le,C(k),H=!0;break t}p===n(d)&&r(d),C(k)}else r(d);p=n(d)}if(p!==null)H=!0;else{var $=n(h);$!==null&&X(N,$.startTime-k),H=!1}}break e}finally{p=null,g=B,b=!1}H=void 0}}finally{H?F():M=!1}}}var F;if(typeof E=="function")F=function(){E(L)};else if(typeof MessageChannel<"u"){var W=new MessageChannel,Q=W.port2;W.port1.onmessage=L,F=function(){Q.postMessage(null)}}else F=function(){_(L,0)};function X(k,H){R=_(function(){k(e.unstable_now())},H)}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(k){k.callback=null},e.unstable_forceFrameRate=function(k){0>k||125<k?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):D=0<k?Math.floor(1e3/k):5},e.unstable_getCurrentPriorityLevel=function(){return g},e.unstable_next=function(k){switch(g){case 1:case 2:case 3:var H=3;break;default:H=g}var B=g;g=H;try{return k()}finally{g=B}},e.unstable_requestPaint=function(){x=!0},e.unstable_runWithPriority=function(k,H){switch(k){case 1:case 2:case 3:case 4:case 5:break;default:k=3}var B=g;g=k;try{return H()}finally{g=B}},e.unstable_scheduleCallback=function(k,H,B){var Z=e.unstable_now();switch(typeof B=="object"&&B!==null?(B=B.delay,B=typeof B=="number"&&0<B?Z+B:Z):B=Z,k){case 1:var le=-1;break;case 2:le=250;break;case 5:le=1073741823;break;case 4:le=1e4;break;default:le=5e3}return le=B+le,k={id:v++,callback:H,priorityLevel:k,startTime:B,expirationTime:le,sortIndex:-1},B>Z?(k.sortIndex=B,t(h,k),n(d)===null&&k===n(h)&&(j?(A(R),R=-1):j=!0,X(N,B-Z))):(k.sortIndex=le,t(d,k),O||b||(O=!0,M||(M=!0,F()))),k},e.unstable_shouldYield=Y,e.unstable_wrapCallback=function(k){var H=g;return function(){var B=g;g=H;try{return k.apply(this,arguments)}finally{g=B}}}})(lb)),lb}var H2;function _U(){return H2||(H2=1,sb.exports=OU()),sb.exports}var cb={exports:{}},bn={};/**
26
+ * @license React
27
+ * react-dom.production.js
28
+ *
29
+ * Copyright (c) Meta Platforms, Inc. and 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 F2;function EU(){if(F2)return bn;F2=1;var e=Ep();function t(d){var h="https://react.dev/errors/"+d;if(1<arguments.length){h+="?args[]="+encodeURIComponent(arguments[1]);for(var v=2;v<arguments.length;v++)h+="&args[]="+encodeURIComponent(arguments[v])}return"Minified React error #"+d+"; visit "+h+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(){}var r={d:{f:n,r:function(){throw Error(t(522))},D:n,C:n,L:n,m:n,X:n,S:n,M:n},p:0,findDOMNode:null},i=Symbol.for("react.portal");function o(d,h,v){var p=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:i,key:p==null?null:""+p,children:d,containerInfo:h,implementation:v}}var l=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function u(d,h){if(d==="font")return"";if(typeof h=="string")return h==="use-credentials"?h:""}return bn.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,bn.createPortal=function(d,h){var v=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!h||h.nodeType!==1&&h.nodeType!==9&&h.nodeType!==11)throw Error(t(299));return o(d,h,null,v)},bn.flushSync=function(d){var h=l.T,v=r.p;try{if(l.T=null,r.p=2,d)return d()}finally{l.T=h,r.p=v,r.d.f()}},bn.preconnect=function(d,h){typeof d=="string"&&(h?(h=h.crossOrigin,h=typeof h=="string"?h==="use-credentials"?h:"":void 0):h=null,r.d.C(d,h))},bn.prefetchDNS=function(d){typeof d=="string"&&r.d.D(d)},bn.preinit=function(d,h){if(typeof d=="string"&&h&&typeof h.as=="string"){var v=h.as,p=u(v,h.crossOrigin),g=typeof h.integrity=="string"?h.integrity:void 0,b=typeof h.fetchPriority=="string"?h.fetchPriority:void 0;v==="style"?r.d.S(d,typeof h.precedence=="string"?h.precedence:void 0,{crossOrigin:p,integrity:g,fetchPriority:b}):v==="script"&&r.d.X(d,{crossOrigin:p,integrity:g,fetchPriority:b,nonce:typeof h.nonce=="string"?h.nonce:void 0})}},bn.preinitModule=function(d,h){if(typeof d=="string")if(typeof h=="object"&&h!==null){if(h.as==null||h.as==="script"){var v=u(h.as,h.crossOrigin);r.d.M(d,{crossOrigin:v,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0})}}else h==null&&r.d.M(d)},bn.preload=function(d,h){if(typeof d=="string"&&typeof h=="object"&&h!==null&&typeof h.as=="string"){var v=h.as,p=u(v,h.crossOrigin);r.d.L(d,v,{crossOrigin:p,integrity:typeof h.integrity=="string"?h.integrity:void 0,nonce:typeof h.nonce=="string"?h.nonce:void 0,type:typeof h.type=="string"?h.type:void 0,fetchPriority:typeof h.fetchPriority=="string"?h.fetchPriority:void 0,referrerPolicy:typeof h.referrerPolicy=="string"?h.referrerPolicy:void 0,imageSrcSet:typeof h.imageSrcSet=="string"?h.imageSrcSet:void 0,imageSizes:typeof h.imageSizes=="string"?h.imageSizes:void 0,media:typeof h.media=="string"?h.media:void 0})}},bn.preloadModule=function(d,h){if(typeof d=="string")if(h){var v=u(h.as,h.crossOrigin);r.d.m(d,{as:typeof h.as=="string"&&h.as!=="script"?h.as:void 0,crossOrigin:v,integrity:typeof h.integrity=="string"?h.integrity:void 0})}else r.d.m(d)},bn.requestFormReset=function(d){r.d.r(d)},bn.unstable_batchedUpdates=function(d,h){return d(h)},bn.useFormState=function(d,h,v){return l.H.useFormState(d,h,v)},bn.useFormStatus=function(){return l.H.useHostTransitionStatus()},bn.version="19.2.3",bn}var G2;function q4(){if(G2)return cb.exports;G2=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),cb.exports=EU(),cb.exports}/**
34
+ * @license React
35
+ * react-dom-client.production.js
36
+ *
37
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
38
+ *
39
+ * This source code is licensed under the MIT license found in the
40
+ * LICENSE file in the root directory of this source tree.
41
+ */var V2;function AU(){if(V2)return mu;V2=1;var e=_U(),t=Ep(),n=q4();function r(a){var s="https://react.dev/errors/"+a;if(1<arguments.length){s+="?args[]="+encodeURIComponent(arguments[1]);for(var f=2;f<arguments.length;f++)s+="&args[]="+encodeURIComponent(arguments[f])}return"Minified React error #"+a+"; visit "+s+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(a){return!(!a||a.nodeType!==1&&a.nodeType!==9&&a.nodeType!==11)}function o(a){var s=a,f=a;if(a.alternate)for(;s.return;)s=s.return;else{a=s;do s=a,(s.flags&4098)!==0&&(f=s.return),a=s.return;while(a)}return s.tag===3?f:null}function l(a){if(a.tag===13){var s=a.memoizedState;if(s===null&&(a=a.alternate,a!==null&&(s=a.memoizedState)),s!==null)return s.dehydrated}return null}function u(a){if(a.tag===31){var s=a.memoizedState;if(s===null&&(a=a.alternate,a!==null&&(s=a.memoizedState)),s!==null)return s.dehydrated}return null}function d(a){if(o(a)!==a)throw Error(r(188))}function h(a){var s=a.alternate;if(!s){if(s=o(a),s===null)throw Error(r(188));return s!==a?null:a}for(var f=a,m=s;;){var y=f.return;if(y===null)break;var S=y.alternate;if(S===null){if(m=y.return,m!==null){f=m;continue}break}if(y.child===S.child){for(S=y.child;S;){if(S===f)return d(y),a;if(S===m)return d(y),s;S=S.sibling}throw Error(r(188))}if(f.return!==m.return)f=y,m=S;else{for(var T=!1,P=y.child;P;){if(P===f){T=!0,f=y,m=S;break}if(P===m){T=!0,m=y,f=S;break}P=P.sibling}if(!T){for(P=S.child;P;){if(P===f){T=!0,f=S,m=y;break}if(P===m){T=!0,m=S,f=y;break}P=P.sibling}if(!T)throw Error(r(189))}}if(f.alternate!==m)throw Error(r(190))}if(f.tag!==3)throw Error(r(188));return f.stateNode.current===f?a:s}function v(a){var s=a.tag;if(s===5||s===26||s===27||s===6)return a;for(a=a.child;a!==null;){if(s=v(a),s!==null)return s;a=a.sibling}return null}var p=Object.assign,g=Symbol.for("react.element"),b=Symbol.for("react.transitional.element"),O=Symbol.for("react.portal"),j=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),_=Symbol.for("react.profiler"),A=Symbol.for("react.consumer"),E=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),N=Symbol.for("react.suspense"),M=Symbol.for("react.suspense_list"),R=Symbol.for("react.memo"),D=Symbol.for("react.lazy"),z=Symbol.for("react.activity"),Y=Symbol.for("react.memo_cache_sentinel"),L=Symbol.iterator;function F(a){return a===null||typeof a!="object"?null:(a=L&&a[L]||a["@@iterator"],typeof a=="function"?a:null)}var W=Symbol.for("react.client.reference");function Q(a){if(a==null)return null;if(typeof a=="function")return a.$$typeof===W?null:a.displayName||a.name||null;if(typeof a=="string")return a;switch(a){case j:return"Fragment";case _:return"Profiler";case x:return"StrictMode";case N:return"Suspense";case M:return"SuspenseList";case z:return"Activity"}if(typeof a=="object")switch(a.$$typeof){case O:return"Portal";case E:return a.displayName||"Context";case A:return(a._context.displayName||"Context")+".Consumer";case C:var s=a.render;return a=a.displayName,a||(a=s.displayName||s.name||"",a=a!==""?"ForwardRef("+a+")":"ForwardRef"),a;case R:return s=a.displayName||null,s!==null?s:Q(a.type)||"Memo";case D:s=a._payload,a=a._init;try{return Q(a(s))}catch{}}return null}var X=Array.isArray,k=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,H=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,B={pending:!1,data:null,method:null,action:null},Z=[],le=-1;function $(a){return{current:a}}function V(a){0>le||(a.current=Z[le],Z[le]=null,le--)}function q(a,s){le++,Z[le]=a.current,a.current=s}var U=$(null),ne=$(null),fe=$(null),ie=$(null);function pe(a,s){switch(q(fe,s),q(ne,a),q(U,null),s.nodeType){case 9:case 11:a=(a=s.documentElement)&&(a=a.namespaceURI)?s2(a):0;break;default:if(a=s.tagName,s=s.namespaceURI)s=s2(s),a=l2(s,a);else switch(a){case"svg":a=1;break;case"math":a=2;break;default:a=0}}V(U),q(U,a)}function re(){V(U),V(ne),V(fe)}function ve(a){a.memoizedState!==null&&q(ie,a);var s=U.current,f=l2(s,a.type);s!==f&&(q(ne,a),q(U,f))}function ge(a){ne.current===a&&(V(U),V(ne)),ie.current===a&&(V(ie),cu._currentValue=B)}var oe,ke;function we(a){if(oe===void 0)try{throw Error()}catch(f){var s=f.stack.trim().match(/\n( *(at )?)/);oe=s&&s[1]||"",ke=-1<f.stack.indexOf(`
42
+ at`)?" (<anonymous>)":-1<f.stack.indexOf("@")?"@unknown:0:0":""}return`
43
+ `+oe+a+ke}var Ie=!1;function Ze(a,s){if(!a||Ie)return"";Ie=!0;var f=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var m={DetermineComponentFrameRoot:function(){try{if(s){var he=function(){throw Error()};if(Object.defineProperty(he.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(he,[])}catch(se){var ae=se}Reflect.construct(a,[],he)}else{try{he.call()}catch(se){ae=se}a.call(he.prototype)}}else{try{throw Error()}catch(se){ae=se}(he=a())&&typeof he.catch=="function"&&he.catch(function(){})}}catch(se){if(se&&ae&&typeof se.stack=="string")return[se.stack,ae.stack]}return[null,null]}};m.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var y=Object.getOwnPropertyDescriptor(m.DetermineComponentFrameRoot,"name");y&&y.configurable&&Object.defineProperty(m.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var S=m.DetermineComponentFrameRoot(),T=S[0],P=S[1];if(T&&P){var G=T.split(`
44
+ `),te=P.split(`
45
+ `);for(y=m=0;m<G.length&&!G[m].includes("DetermineComponentFrameRoot");)m++;for(;y<te.length&&!te[y].includes("DetermineComponentFrameRoot");)y++;if(m===G.length||y===te.length)for(m=G.length-1,y=te.length-1;1<=m&&0<=y&&G[m]!==te[y];)y--;for(;1<=m&&0<=y;m--,y--)if(G[m]!==te[y]){if(m!==1||y!==1)do if(m--,y--,0>y||G[m]!==te[y]){var ce=`
46
+ `+G[m].replace(" at new "," at ");return a.displayName&&ce.includes("<anonymous>")&&(ce=ce.replace("<anonymous>",a.displayName)),ce}while(1<=m&&0<=y);break}}}finally{Ie=!1,Error.prepareStackTrace=f}return(f=a?a.displayName||a.name:"")?we(f):""}function lt(a,s){switch(a.tag){case 26:case 27:case 5:return we(a.type);case 16:return we("Lazy");case 13:return a.child!==s&&s!==null?we("Suspense Fallback"):we("Suspense");case 19:return we("SuspenseList");case 0:case 15:return Ze(a.type,!1);case 11:return Ze(a.type.render,!1);case 1:return Ze(a.type,!0);case 31:return we("Activity");default:return""}}function en(a){try{var s="",f=null;do s+=lt(a,f),f=a,a=a.return;while(a);return s}catch(m){return`
47
+ Error generating stack: `+m.message+`
48
+ `+m.stack}}var mt=Object.prototype.hasOwnProperty,ur=e.unstable_scheduleCallback,Gn=e.unstable_cancelCallback,Mt=e.unstable_shouldYield,fr=e.unstable_requestPaint,tn=e.unstable_now,ms=e.unstable_getCurrentPriorityLevel,uo=e.unstable_ImmediatePriority,ed=e.unstable_UserBlockingPriority,fo=e.unstable_NormalPriority,Sc=e.unstable_LowPriority,Sa=e.unstable_IdlePriority,td=e.log,di=e.unstable_setDisableYieldValue,ho=null,On=null;function kr(a){if(typeof td=="function"&&di(a),On&&typeof On.setStrictMode=="function")try{On.setStrictMode(ho,a)}catch{}}var gn=Math.clz32?Math.clz32:Jr,Vv=Math.log,jc=Math.LN2;function Jr(a){return a>>>=0,a===0?32:31-(Vv(a)/jc|0)|0}var ps=256,vs=262144,mo=4194304;function ea(a){var s=a&42;if(s!==0)return s;switch(a&-a){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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return a&261888;case 262144:case 524288:case 1048576:case 2097152:return a&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return a&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return a}}function $e(a,s,f){var m=a.pendingLanes;if(m===0)return 0;var y=0,S=a.suspendedLanes,T=a.pingedLanes;a=a.warmLanes;var P=m&134217727;return P!==0?(m=P&~S,m!==0?y=ea(m):(T&=P,T!==0?y=ea(T):f||(f=P&~a,f!==0&&(y=ea(f))))):(P=m&~S,P!==0?y=ea(P):T!==0?y=ea(T):f||(f=m&~a,f!==0&&(y=ea(f)))),y===0?0:s!==0&&s!==y&&(s&S)===0&&(S=y&-y,f=s&-s,S>=f||S===32&&(f&4194048)!==0)?s:y}function At(a,s){return(a.pendingLanes&~(a.suspendedLanes&~a.pingedLanes)&s)===0}function nn(a,s){switch(a){case 1:case 2:case 4:case 8:case 64:return s+250;case 16:case 32: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 s+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function yn(){var a=mo;return mo<<=1,(mo&62914560)===0&&(mo=4194304),a}function hi(a){for(var s=[],f=0;31>f;f++)s.push(a);return s}function Rt(a,s){a.pendingLanes|=s,s!==268435456&&(a.suspendedLanes=0,a.pingedLanes=0,a.warmLanes=0)}function Tn(a,s,f,m,y,S){var T=a.pendingLanes;a.pendingLanes=f,a.suspendedLanes=0,a.pingedLanes=0,a.warmLanes=0,a.expiredLanes&=f,a.entangledLanes&=f,a.errorRecoveryDisabledLanes&=f,a.shellSuspendCounter=0;var P=a.entanglements,G=a.expirationTimes,te=a.hiddenUpdates;for(f=T&~f;0<f;){var ce=31-gn(f),he=1<<ce;P[ce]=0,G[ce]=-1;var ae=te[ce];if(ae!==null)for(te[ce]=null,ce=0;ce<ae.length;ce++){var se=ae[ce];se!==null&&(se.lane&=-536870913)}f&=~he}m!==0&&po(a,m,0),S!==0&&y===0&&a.tag!==0&&(a.suspendedLanes|=S&~(T&~s))}function po(a,s,f){a.pendingLanes|=s,a.suspendedLanes&=~s;var m=31-gn(s);a.entangledLanes|=s,a.entanglements[m]=a.entanglements[m]|1073741824|f&261930}function Mn(a,s){var f=a.entangledLanes|=s;for(a=a.entanglements;f;){var m=31-gn(f),y=1<<m;y&s|a[m]&s&&(a[m]|=s),f&=~y}}function Rn(a,s){var f=s&-s;return f=(f&42)!==0?1:gs(f),(f&(a.suspendedLanes|s))!==0?0:f}function gs(a){switch(a){case 2:a=1;break;case 8:a=4;break;case 32:a=16;break;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:a=128;break;case 268435456:a=134217728;break;default:a=0}return a}function $r(a){return a&=-a,2<a?8<a?(a&134217727)!==0?32:268435456:8:2}function Yv(){var a=H.p;return a!==0?a:(a=window.event,a===void 0?32:M2(a.type))}function Y_(a,s){var f=H.p;try{return H.p=a,s()}finally{H.p=f}}var mi=Math.random().toString(36).slice(2),cn="__reactFiber$"+mi,Dn="__reactProps$"+mi,ys="__reactContainer$"+mi,Wv="__reactEvents$"+mi,s8="__reactListeners$"+mi,l8="__reactHandles$"+mi,W_="__reactResources$"+mi,Oc="__reactMarker$"+mi;function Kv(a){delete a[cn],delete a[Dn],delete a[Wv],delete a[s8],delete a[l8]}function bs(a){var s=a[cn];if(s)return s;for(var f=a.parentNode;f;){if(s=f[ys]||f[cn]){if(f=s.alternate,s.child!==null||f!==null&&f.child!==null)for(a=p2(a);a!==null;){if(f=a[cn])return f;a=p2(a)}return s}a=f,f=a.parentNode}return null}function xs(a){if(a=a[cn]||a[ys]){var s=a.tag;if(s===5||s===6||s===13||s===31||s===26||s===27||s===3)return a}return null}function _c(a){var s=a.tag;if(s===5||s===26||s===27||s===6)return a.stateNode;throw Error(r(33))}function ws(a){var s=a[W_];return s||(s=a[W_]={hoistableStyles:new Map,hoistableScripts:new Map}),s}function rn(a){a[Oc]=!0}var K_=new Set,X_={};function vo(a,s){Ss(a,s),Ss(a+"Capture",s)}function Ss(a,s){for(X_[a]=s,a=0;a<s.length;a++)K_.add(s[a])}var c8=RegExp("^[: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]*$"),Q_={},Z_={};function u8(a){return mt.call(Z_,a)?!0:mt.call(Q_,a)?!1:c8.test(a)?Z_[a]=!0:(Q_[a]=!0,!1)}function nd(a,s,f){if(u8(s))if(f===null)a.removeAttribute(s);else{switch(typeof f){case"undefined":case"function":case"symbol":a.removeAttribute(s);return;case"boolean":var m=s.toLowerCase().slice(0,5);if(m!=="data-"&&m!=="aria-"){a.removeAttribute(s);return}}a.setAttribute(s,""+f)}}function rd(a,s,f){if(f===null)a.removeAttribute(s);else{switch(typeof f){case"undefined":case"function":case"symbol":case"boolean":a.removeAttribute(s);return}a.setAttribute(s,""+f)}}function ja(a,s,f,m){if(m===null)a.removeAttribute(f);else{switch(typeof m){case"undefined":case"function":case"symbol":case"boolean":a.removeAttribute(f);return}a.setAttributeNS(s,f,""+m)}}function dr(a){switch(typeof a){case"bigint":case"boolean":case"number":case"string":case"undefined":return a;case"object":return a;default:return""}}function J_(a){var s=a.type;return(a=a.nodeName)&&a.toLowerCase()==="input"&&(s==="checkbox"||s==="radio")}function f8(a,s,f){var m=Object.getOwnPropertyDescriptor(a.constructor.prototype,s);if(!a.hasOwnProperty(s)&&typeof m<"u"&&typeof m.get=="function"&&typeof m.set=="function"){var y=m.get,S=m.set;return Object.defineProperty(a,s,{configurable:!0,get:function(){return y.call(this)},set:function(T){f=""+T,S.call(this,T)}}),Object.defineProperty(a,s,{enumerable:m.enumerable}),{getValue:function(){return f},setValue:function(T){f=""+T},stopTracking:function(){a._valueTracker=null,delete a[s]}}}}function Xv(a){if(!a._valueTracker){var s=J_(a)?"checked":"value";a._valueTracker=f8(a,s,""+a[s])}}function eE(a){if(!a)return!1;var s=a._valueTracker;if(!s)return!0;var f=s.getValue(),m="";return a&&(m=J_(a)?a.checked?"true":"false":a.value),a=m,a!==f?(s.setValue(a),!0):!1}function ad(a){if(a=a||(typeof document<"u"?document:void 0),typeof a>"u")return null;try{return a.activeElement||a.body}catch{return a.body}}var d8=/[\n"\\]/g;function hr(a){return a.replace(d8,function(s){return"\\"+s.charCodeAt(0).toString(16)+" "})}function Qv(a,s,f,m,y,S,T,P){a.name="",T!=null&&typeof T!="function"&&typeof T!="symbol"&&typeof T!="boolean"?a.type=T:a.removeAttribute("type"),s!=null?T==="number"?(s===0&&a.value===""||a.value!=s)&&(a.value=""+dr(s)):a.value!==""+dr(s)&&(a.value=""+dr(s)):T!=="submit"&&T!=="reset"||a.removeAttribute("value"),s!=null?Zv(a,T,dr(s)):f!=null?Zv(a,T,dr(f)):m!=null&&a.removeAttribute("value"),y==null&&S!=null&&(a.defaultChecked=!!S),y!=null&&(a.checked=y&&typeof y!="function"&&typeof y!="symbol"),P!=null&&typeof P!="function"&&typeof P!="symbol"&&typeof P!="boolean"?a.name=""+dr(P):a.removeAttribute("name")}function tE(a,s,f,m,y,S,T,P){if(S!=null&&typeof S!="function"&&typeof S!="symbol"&&typeof S!="boolean"&&(a.type=S),s!=null||f!=null){if(!(S!=="submit"&&S!=="reset"||s!=null)){Xv(a);return}f=f!=null?""+dr(f):"",s=s!=null?""+dr(s):f,P||s===a.value||(a.value=s),a.defaultValue=s}m=m??y,m=typeof m!="function"&&typeof m!="symbol"&&!!m,a.checked=P?a.checked:!!m,a.defaultChecked=!!m,T!=null&&typeof T!="function"&&typeof T!="symbol"&&typeof T!="boolean"&&(a.name=T),Xv(a)}function Zv(a,s,f){s==="number"&&ad(a.ownerDocument)===a||a.defaultValue===""+f||(a.defaultValue=""+f)}function js(a,s,f,m){if(a=a.options,s){s={};for(var y=0;y<f.length;y++)s["$"+f[y]]=!0;for(f=0;f<a.length;f++)y=s.hasOwnProperty("$"+a[f].value),a[f].selected!==y&&(a[f].selected=y),y&&m&&(a[f].defaultSelected=!0)}else{for(f=""+dr(f),s=null,y=0;y<a.length;y++){if(a[y].value===f){a[y].selected=!0,m&&(a[y].defaultSelected=!0);return}s!==null||a[y].disabled||(s=a[y])}s!==null&&(s.selected=!0)}}function nE(a,s,f){if(s!=null&&(s=""+dr(s),s!==a.value&&(a.value=s),f==null)){a.defaultValue!==s&&(a.defaultValue=s);return}a.defaultValue=f!=null?""+dr(f):""}function rE(a,s,f,m){if(s==null){if(m!=null){if(f!=null)throw Error(r(92));if(X(m)){if(1<m.length)throw Error(r(93));m=m[0]}f=m}f==null&&(f=""),s=f}f=dr(s),a.defaultValue=f,m=a.textContent,m===f&&m!==""&&m!==null&&(a.value=m),Xv(a)}function Os(a,s){if(s){var f=a.firstChild;if(f&&f===a.lastChild&&f.nodeType===3){f.nodeValue=s;return}}a.textContent=s}var h8=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function aE(a,s,f){var m=s.indexOf("--")===0;f==null||typeof f=="boolean"||f===""?m?a.setProperty(s,""):s==="float"?a.cssFloat="":a[s]="":m?a.setProperty(s,f):typeof f!="number"||f===0||h8.has(s)?s==="float"?a.cssFloat=f:a[s]=(""+f).trim():a[s]=f+"px"}function iE(a,s,f){if(s!=null&&typeof s!="object")throw Error(r(62));if(a=a.style,f!=null){for(var m in f)!f.hasOwnProperty(m)||s!=null&&s.hasOwnProperty(m)||(m.indexOf("--")===0?a.setProperty(m,""):m==="float"?a.cssFloat="":a[m]="");for(var y in s)m=s[y],s.hasOwnProperty(y)&&f[y]!==m&&aE(a,y,m)}else for(var S in s)s.hasOwnProperty(S)&&aE(a,S,s[S])}function Jv(a){if(a.indexOf("-")===-1)return!1;switch(a){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 m8=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),p8=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function id(a){return p8.test(""+a)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":a}function Oa(){}var eg=null;function tg(a){return a=a.target||a.srcElement||window,a.correspondingUseElement&&(a=a.correspondingUseElement),a.nodeType===3?a.parentNode:a}var _s=null,Es=null;function oE(a){var s=xs(a);if(s&&(a=s.stateNode)){var f=a[Dn]||null;e:switch(a=s.stateNode,s.type){case"input":if(Qv(a,f.value,f.defaultValue,f.defaultValue,f.checked,f.defaultChecked,f.type,f.name),s=f.name,f.type==="radio"&&s!=null){for(f=a;f.parentNode;)f=f.parentNode;for(f=f.querySelectorAll('input[name="'+hr(""+s)+'"][type="radio"]'),s=0;s<f.length;s++){var m=f[s];if(m!==a&&m.form===a.form){var y=m[Dn]||null;if(!y)throw Error(r(90));Qv(m,y.value,y.defaultValue,y.defaultValue,y.checked,y.defaultChecked,y.type,y.name)}}for(s=0;s<f.length;s++)m=f[s],m.form===a.form&&eE(m)}break e;case"textarea":nE(a,f.value,f.defaultValue);break e;case"select":s=f.value,s!=null&&js(a,!!f.multiple,s,!1)}}}var ng=!1;function sE(a,s,f){if(ng)return a(s,f);ng=!0;try{var m=a(s);return m}finally{if(ng=!1,(_s!==null||Es!==null)&&(Vd(),_s&&(s=_s,a=Es,Es=_s=null,oE(s),a)))for(s=0;s<a.length;s++)oE(a[s])}}function Ec(a,s){var f=a.stateNode;if(f===null)return null;var m=f[Dn]||null;if(m===null)return null;f=m[s];e:switch(s){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(m=!m.disabled)||(a=a.type,m=!(a==="button"||a==="input"||a==="select"||a==="textarea")),a=!m;break e;default:a=!1}if(a)return null;if(f&&typeof f!="function")throw Error(r(231,s,typeof f));return f}var _a=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),rg=!1;if(_a)try{var Ac={};Object.defineProperty(Ac,"passive",{get:function(){rg=!0}}),window.addEventListener("test",Ac,Ac),window.removeEventListener("test",Ac,Ac)}catch{rg=!1}var pi=null,ag=null,od=null;function lE(){if(od)return od;var a,s=ag,f=s.length,m,y="value"in pi?pi.value:pi.textContent,S=y.length;for(a=0;a<f&&s[a]===y[a];a++);var T=f-a;for(m=1;m<=T&&s[f-m]===y[S-m];m++);return od=y.slice(a,1<m?1-m:void 0)}function sd(a){var s=a.keyCode;return"charCode"in a?(a=a.charCode,a===0&&s===13&&(a=13)):a=s,a===10&&(a=13),32<=a||a===13?a:0}function ld(){return!0}function cE(){return!1}function Pn(a){function s(f,m,y,S,T){this._reactName=f,this._targetInst=y,this.type=m,this.nativeEvent=S,this.target=T,this.currentTarget=null;for(var P in a)a.hasOwnProperty(P)&&(f=a[P],this[P]=f?f(S):S[P]);return this.isDefaultPrevented=(S.defaultPrevented!=null?S.defaultPrevented:S.returnValue===!1)?ld:cE,this.isPropagationStopped=cE,this}return p(s.prototype,{preventDefault:function(){this.defaultPrevented=!0;var f=this.nativeEvent;f&&(f.preventDefault?f.preventDefault():typeof f.returnValue!="unknown"&&(f.returnValue=!1),this.isDefaultPrevented=ld)},stopPropagation:function(){var f=this.nativeEvent;f&&(f.stopPropagation?f.stopPropagation():typeof f.cancelBubble!="unknown"&&(f.cancelBubble=!0),this.isPropagationStopped=ld)},persist:function(){},isPersistent:ld}),s}var go={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(a){return a.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},cd=Pn(go),Nc=p({},go,{view:0,detail:0}),v8=Pn(Nc),ig,og,Cc,ud=p({},Nc,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:lg,button:0,buttons:0,relatedTarget:function(a){return a.relatedTarget===void 0?a.fromElement===a.srcElement?a.toElement:a.fromElement:a.relatedTarget},movementX:function(a){return"movementX"in a?a.movementX:(a!==Cc&&(Cc&&a.type==="mousemove"?(ig=a.screenX-Cc.screenX,og=a.screenY-Cc.screenY):og=ig=0,Cc=a),ig)},movementY:function(a){return"movementY"in a?a.movementY:og}}),uE=Pn(ud),g8=p({},ud,{dataTransfer:0}),y8=Pn(g8),b8=p({},Nc,{relatedTarget:0}),sg=Pn(b8),x8=p({},go,{animationName:0,elapsedTime:0,pseudoElement:0}),w8=Pn(x8),S8=p({},go,{clipboardData:function(a){return"clipboardData"in a?a.clipboardData:window.clipboardData}}),j8=Pn(S8),O8=p({},go,{data:0}),fE=Pn(O8),_8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},E8={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"},A8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function N8(a){var s=this.nativeEvent;return s.getModifierState?s.getModifierState(a):(a=A8[a])?!!s[a]:!1}function lg(){return N8}var C8=p({},Nc,{key:function(a){if(a.key){var s=_8[a.key]||a.key;if(s!=="Unidentified")return s}return a.type==="keypress"?(a=sd(a),a===13?"Enter":String.fromCharCode(a)):a.type==="keydown"||a.type==="keyup"?E8[a.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:lg,charCode:function(a){return a.type==="keypress"?sd(a):0},keyCode:function(a){return a.type==="keydown"||a.type==="keyup"?a.keyCode:0},which:function(a){return a.type==="keypress"?sd(a):a.type==="keydown"||a.type==="keyup"?a.keyCode:0}}),T8=Pn(C8),M8=p({},ud,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),dE=Pn(M8),R8=p({},Nc,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:lg}),D8=Pn(R8),P8=p({},go,{propertyName:0,elapsedTime:0,pseudoElement:0}),k8=Pn(P8),$8=p({},ud,{deltaX:function(a){return"deltaX"in a?a.deltaX:"wheelDeltaX"in a?-a.wheelDeltaX:0},deltaY:function(a){return"deltaY"in a?a.deltaY:"wheelDeltaY"in a?-a.wheelDeltaY:"wheelDelta"in a?-a.wheelDelta:0},deltaZ:0,deltaMode:0}),I8=Pn($8),L8=p({},go,{newState:0,oldState:0}),z8=Pn(L8),B8=[9,13,27,32],cg=_a&&"CompositionEvent"in window,Tc=null;_a&&"documentMode"in document&&(Tc=document.documentMode);var q8=_a&&"TextEvent"in window&&!Tc,hE=_a&&(!cg||Tc&&8<Tc&&11>=Tc),mE=" ",pE=!1;function vE(a,s){switch(a){case"keyup":return B8.indexOf(s.keyCode)!==-1;case"keydown":return s.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function gE(a){return a=a.detail,typeof a=="object"&&"data"in a?a.data:null}var As=!1;function U8(a,s){switch(a){case"compositionend":return gE(s);case"keypress":return s.which!==32?null:(pE=!0,mE);case"textInput":return a=s.data,a===mE&&pE?null:a;default:return null}}function H8(a,s){if(As)return a==="compositionend"||!cg&&vE(a,s)?(a=lE(),od=ag=pi=null,As=!1,a):null;switch(a){case"paste":return null;case"keypress":if(!(s.ctrlKey||s.altKey||s.metaKey)||s.ctrlKey&&s.altKey){if(s.char&&1<s.char.length)return s.char;if(s.which)return String.fromCharCode(s.which)}return null;case"compositionend":return hE&&s.locale!=="ko"?null:s.data;default:return null}}var F8={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 yE(a){var s=a&&a.nodeName&&a.nodeName.toLowerCase();return s==="input"?!!F8[a.type]:s==="textarea"}function bE(a,s,f,m){_s?Es?Es.push(m):Es=[m]:_s=m,s=Jd(s,"onChange"),0<s.length&&(f=new cd("onChange","change",null,f,m),a.push({event:f,listeners:s}))}var Mc=null,Rc=null;function G8(a){t2(a,0)}function fd(a){var s=_c(a);if(eE(s))return a}function xE(a,s){if(a==="change")return s}var wE=!1;if(_a){var ug;if(_a){var fg="oninput"in document;if(!fg){var SE=document.createElement("div");SE.setAttribute("oninput","return;"),fg=typeof SE.oninput=="function"}ug=fg}else ug=!1;wE=ug&&(!document.documentMode||9<document.documentMode)}function jE(){Mc&&(Mc.detachEvent("onpropertychange",OE),Rc=Mc=null)}function OE(a){if(a.propertyName==="value"&&fd(Rc)){var s=[];bE(s,Rc,a,tg(a)),sE(G8,s)}}function V8(a,s,f){a==="focusin"?(jE(),Mc=s,Rc=f,Mc.attachEvent("onpropertychange",OE)):a==="focusout"&&jE()}function Y8(a){if(a==="selectionchange"||a==="keyup"||a==="keydown")return fd(Rc)}function W8(a,s){if(a==="click")return fd(s)}function K8(a,s){if(a==="input"||a==="change")return fd(s)}function X8(a,s){return a===s&&(a!==0||1/a===1/s)||a!==a&&s!==s}var Vn=typeof Object.is=="function"?Object.is:X8;function Dc(a,s){if(Vn(a,s))return!0;if(typeof a!="object"||a===null||typeof s!="object"||s===null)return!1;var f=Object.keys(a),m=Object.keys(s);if(f.length!==m.length)return!1;for(m=0;m<f.length;m++){var y=f[m];if(!mt.call(s,y)||!Vn(a[y],s[y]))return!1}return!0}function _E(a){for(;a&&a.firstChild;)a=a.firstChild;return a}function EE(a,s){var f=_E(a);a=0;for(var m;f;){if(f.nodeType===3){if(m=a+f.textContent.length,a<=s&&m>=s)return{node:f,offset:s-a};a=m}e:{for(;f;){if(f.nextSibling){f=f.nextSibling;break e}f=f.parentNode}f=void 0}f=_E(f)}}function AE(a,s){return a&&s?a===s?!0:a&&a.nodeType===3?!1:s&&s.nodeType===3?AE(a,s.parentNode):"contains"in a?a.contains(s):a.compareDocumentPosition?!!(a.compareDocumentPosition(s)&16):!1:!1}function NE(a){a=a!=null&&a.ownerDocument!=null&&a.ownerDocument.defaultView!=null?a.ownerDocument.defaultView:window;for(var s=ad(a.document);s instanceof a.HTMLIFrameElement;){try{var f=typeof s.contentWindow.location.href=="string"}catch{f=!1}if(f)a=s.contentWindow;else break;s=ad(a.document)}return s}function dg(a){var s=a&&a.nodeName&&a.nodeName.toLowerCase();return s&&(s==="input"&&(a.type==="text"||a.type==="search"||a.type==="tel"||a.type==="url"||a.type==="password")||s==="textarea"||a.contentEditable==="true")}var Q8=_a&&"documentMode"in document&&11>=document.documentMode,Ns=null,hg=null,Pc=null,mg=!1;function CE(a,s,f){var m=f.window===f?f.document:f.nodeType===9?f:f.ownerDocument;mg||Ns==null||Ns!==ad(m)||(m=Ns,"selectionStart"in m&&dg(m)?m={start:m.selectionStart,end:m.selectionEnd}:(m=(m.ownerDocument&&m.ownerDocument.defaultView||window).getSelection(),m={anchorNode:m.anchorNode,anchorOffset:m.anchorOffset,focusNode:m.focusNode,focusOffset:m.focusOffset}),Pc&&Dc(Pc,m)||(Pc=m,m=Jd(hg,"onSelect"),0<m.length&&(s=new cd("onSelect","select",null,s,f),a.push({event:s,listeners:m}),s.target=Ns)))}function yo(a,s){var f={};return f[a.toLowerCase()]=s.toLowerCase(),f["Webkit"+a]="webkit"+s,f["Moz"+a]="moz"+s,f}var Cs={animationend:yo("Animation","AnimationEnd"),animationiteration:yo("Animation","AnimationIteration"),animationstart:yo("Animation","AnimationStart"),transitionrun:yo("Transition","TransitionRun"),transitionstart:yo("Transition","TransitionStart"),transitioncancel:yo("Transition","TransitionCancel"),transitionend:yo("Transition","TransitionEnd")},pg={},TE={};_a&&(TE=document.createElement("div").style,"AnimationEvent"in window||(delete Cs.animationend.animation,delete Cs.animationiteration.animation,delete Cs.animationstart.animation),"TransitionEvent"in window||delete Cs.transitionend.transition);function bo(a){if(pg[a])return pg[a];if(!Cs[a])return a;var s=Cs[a],f;for(f in s)if(s.hasOwnProperty(f)&&f in TE)return pg[a]=s[f];return a}var ME=bo("animationend"),RE=bo("animationiteration"),DE=bo("animationstart"),Z8=bo("transitionrun"),J8=bo("transitionstart"),eq=bo("transitioncancel"),PE=bo("transitionend"),kE=new Map,vg="abort auxClick beforeToggle 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(" ");vg.push("scrollEnd");function Ir(a,s){kE.set(a,s),vo(s,[a])}var dd=typeof reportError=="function"?reportError:function(a){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var s=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof a=="object"&&a!==null&&typeof a.message=="string"?String(a.message):String(a),error:a});if(!window.dispatchEvent(s))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",a);return}console.error(a)},mr=[],Ts=0,gg=0;function hd(){for(var a=Ts,s=gg=Ts=0;s<a;){var f=mr[s];mr[s++]=null;var m=mr[s];mr[s++]=null;var y=mr[s];mr[s++]=null;var S=mr[s];if(mr[s++]=null,m!==null&&y!==null){var T=m.pending;T===null?y.next=y:(y.next=T.next,T.next=y),m.pending=y}S!==0&&$E(f,y,S)}}function md(a,s,f,m){mr[Ts++]=a,mr[Ts++]=s,mr[Ts++]=f,mr[Ts++]=m,gg|=m,a.lanes|=m,a=a.alternate,a!==null&&(a.lanes|=m)}function yg(a,s,f,m){return md(a,s,f,m),pd(a)}function xo(a,s){return md(a,null,null,s),pd(a)}function $E(a,s,f){a.lanes|=f;var m=a.alternate;m!==null&&(m.lanes|=f);for(var y=!1,S=a.return;S!==null;)S.childLanes|=f,m=S.alternate,m!==null&&(m.childLanes|=f),S.tag===22&&(a=S.stateNode,a===null||a._visibility&1||(y=!0)),a=S,S=S.return;return a.tag===3?(S=a.stateNode,y&&s!==null&&(y=31-gn(f),a=S.hiddenUpdates,m=a[y],m===null?a[y]=[s]:m.push(s),s.lane=f|536870912),S):null}function pd(a){if(50<nu)throw nu=0,Ay=null,Error(r(185));for(var s=a.return;s!==null;)a=s,s=a.return;return a.tag===3?a.stateNode:null}var Ms={};function tq(a,s,f,m){this.tag=a,this.key=f,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=s,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=m,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Yn(a,s,f,m){return new tq(a,s,f,m)}function bg(a){return a=a.prototype,!(!a||!a.isReactComponent)}function Ea(a,s){var f=a.alternate;return f===null?(f=Yn(a.tag,s,a.key,a.mode),f.elementType=a.elementType,f.type=a.type,f.stateNode=a.stateNode,f.alternate=a,a.alternate=f):(f.pendingProps=s,f.type=a.type,f.flags=0,f.subtreeFlags=0,f.deletions=null),f.flags=a.flags&65011712,f.childLanes=a.childLanes,f.lanes=a.lanes,f.child=a.child,f.memoizedProps=a.memoizedProps,f.memoizedState=a.memoizedState,f.updateQueue=a.updateQueue,s=a.dependencies,f.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext},f.sibling=a.sibling,f.index=a.index,f.ref=a.ref,f.refCleanup=a.refCleanup,f}function IE(a,s){a.flags&=65011714;var f=a.alternate;return f===null?(a.childLanes=0,a.lanes=s,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=f.childLanes,a.lanes=f.lanes,a.child=f.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=f.memoizedProps,a.memoizedState=f.memoizedState,a.updateQueue=f.updateQueue,a.type=f.type,s=f.dependencies,a.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),a}function vd(a,s,f,m,y,S){var T=0;if(m=a,typeof a=="function")bg(a)&&(T=1);else if(typeof a=="string")T=oU(a,f,U.current)?26:a==="html"||a==="head"||a==="body"?27:5;else e:switch(a){case z:return a=Yn(31,f,s,y),a.elementType=z,a.lanes=S,a;case j:return wo(f.children,y,S,s);case x:T=8,y|=24;break;case _:return a=Yn(12,f,s,y|2),a.elementType=_,a.lanes=S,a;case N:return a=Yn(13,f,s,y),a.elementType=N,a.lanes=S,a;case M:return a=Yn(19,f,s,y),a.elementType=M,a.lanes=S,a;default:if(typeof a=="object"&&a!==null)switch(a.$$typeof){case E:T=10;break e;case A:T=9;break e;case C:T=11;break e;case R:T=14;break e;case D:T=16,m=null;break e}T=29,f=Error(r(130,a===null?"null":typeof a,"")),m=null}return s=Yn(T,f,s,y),s.elementType=a,s.type=m,s.lanes=S,s}function wo(a,s,f,m){return a=Yn(7,a,m,s),a.lanes=f,a}function xg(a,s,f){return a=Yn(6,a,null,s),a.lanes=f,a}function LE(a){var s=Yn(18,null,null,0);return s.stateNode=a,s}function wg(a,s,f){return s=Yn(4,a.children!==null?a.children:[],a.key,s),s.lanes=f,s.stateNode={containerInfo:a.containerInfo,pendingChildren:null,implementation:a.implementation},s}var zE=new WeakMap;function pr(a,s){if(typeof a=="object"&&a!==null){var f=zE.get(a);return f!==void 0?f:(s={value:a,source:s,stack:en(s)},zE.set(a,s),s)}return{value:a,source:s,stack:en(s)}}var Rs=[],Ds=0,gd=null,kc=0,vr=[],gr=0,vi=null,ta=1,na="";function Aa(a,s){Rs[Ds++]=kc,Rs[Ds++]=gd,gd=a,kc=s}function BE(a,s,f){vr[gr++]=ta,vr[gr++]=na,vr[gr++]=vi,vi=a;var m=ta;a=na;var y=32-gn(m)-1;m&=~(1<<y),f+=1;var S=32-gn(s)+y;if(30<S){var T=y-y%5;S=(m&(1<<T)-1).toString(32),m>>=T,y-=T,ta=1<<32-gn(s)+y|f<<y|m,na=S+a}else ta=1<<S|f<<y|m,na=a}function Sg(a){a.return!==null&&(Aa(a,1),BE(a,1,0))}function jg(a){for(;a===gd;)gd=Rs[--Ds],Rs[Ds]=null,kc=Rs[--Ds],Rs[Ds]=null;for(;a===vi;)vi=vr[--gr],vr[gr]=null,na=vr[--gr],vr[gr]=null,ta=vr[--gr],vr[gr]=null}function qE(a,s){vr[gr++]=ta,vr[gr++]=na,vr[gr++]=vi,ta=s.id,na=s.overflow,vi=a}var un=null,Ot=null,tt=!1,gi=null,yr=!1,Og=Error(r(519));function yi(a){var s=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw $c(pr(s,a)),Og}function UE(a){var s=a.stateNode,f=a.type,m=a.memoizedProps;switch(s[cn]=a,s[Dn]=m,f){case"dialog":Xe("cancel",s),Xe("close",s);break;case"iframe":case"object":case"embed":Xe("load",s);break;case"video":case"audio":for(f=0;f<au.length;f++)Xe(au[f],s);break;case"source":Xe("error",s);break;case"img":case"image":case"link":Xe("error",s),Xe("load",s);break;case"details":Xe("toggle",s);break;case"input":Xe("invalid",s),tE(s,m.value,m.defaultValue,m.checked,m.defaultChecked,m.type,m.name,!0);break;case"select":Xe("invalid",s);break;case"textarea":Xe("invalid",s),rE(s,m.value,m.defaultValue,m.children)}f=m.children,typeof f!="string"&&typeof f!="number"&&typeof f!="bigint"||s.textContent===""+f||m.suppressHydrationWarning===!0||i2(s.textContent,f)?(m.popover!=null&&(Xe("beforetoggle",s),Xe("toggle",s)),m.onScroll!=null&&Xe("scroll",s),m.onScrollEnd!=null&&Xe("scrollend",s),m.onClick!=null&&(s.onclick=Oa),s=!0):s=!1,s||yi(a,!0)}function HE(a){for(un=a.return;un;)switch(un.tag){case 5:case 31:case 13:yr=!1;return;case 27:case 3:yr=!0;return;default:un=un.return}}function Ps(a){if(a!==un)return!1;if(!tt)return HE(a),tt=!0,!1;var s=a.tag,f;if((f=s!==3&&s!==27)&&((f=s===5)&&(f=a.type,f=!(f!=="form"&&f!=="button")||Uy(a.type,a.memoizedProps)),f=!f),f&&Ot&&yi(a),HE(a),s===13){if(a=a.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(317));Ot=m2(a)}else if(s===31){if(a=a.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(317));Ot=m2(a)}else s===27?(s=Ot,Ri(a.type)?(a=Yy,Yy=null,Ot=a):Ot=s):Ot=un?xr(a.stateNode.nextSibling):null;return!0}function So(){Ot=un=null,tt=!1}function _g(){var a=gi;return a!==null&&(Ln===null?Ln=a:Ln.push.apply(Ln,a),gi=null),a}function $c(a){gi===null?gi=[a]:gi.push(a)}var Eg=$(null),jo=null,Na=null;function bi(a,s,f){q(Eg,s._currentValue),s._currentValue=f}function Ca(a){a._currentValue=Eg.current,V(Eg)}function Ag(a,s,f){for(;a!==null;){var m=a.alternate;if((a.childLanes&s)!==s?(a.childLanes|=s,m!==null&&(m.childLanes|=s)):m!==null&&(m.childLanes&s)!==s&&(m.childLanes|=s),a===f)break;a=a.return}}function Ng(a,s,f,m){var y=a.child;for(y!==null&&(y.return=a);y!==null;){var S=y.dependencies;if(S!==null){var T=y.child;S=S.firstContext;e:for(;S!==null;){var P=S;S=y;for(var G=0;G<s.length;G++)if(P.context===s[G]){S.lanes|=f,P=S.alternate,P!==null&&(P.lanes|=f),Ag(S.return,f,a),m||(T=null);break e}S=P.next}}else if(y.tag===18){if(T=y.return,T===null)throw Error(r(341));T.lanes|=f,S=T.alternate,S!==null&&(S.lanes|=f),Ag(T,f,a),T=null}else T=y.child;if(T!==null)T.return=y;else for(T=y;T!==null;){if(T===a){T=null;break}if(y=T.sibling,y!==null){y.return=T.return,T=y;break}T=T.return}y=T}}function ks(a,s,f,m){a=null;for(var y=s,S=!1;y!==null;){if(!S){if((y.flags&524288)!==0)S=!0;else if((y.flags&262144)!==0)break}if(y.tag===10){var T=y.alternate;if(T===null)throw Error(r(387));if(T=T.memoizedProps,T!==null){var P=y.type;Vn(y.pendingProps.value,T.value)||(a!==null?a.push(P):a=[P])}}else if(y===ie.current){if(T=y.alternate,T===null)throw Error(r(387));T.memoizedState.memoizedState!==y.memoizedState.memoizedState&&(a!==null?a.push(cu):a=[cu])}y=y.return}a!==null&&Ng(s,a,f,m),s.flags|=262144}function yd(a){for(a=a.firstContext;a!==null;){if(!Vn(a.context._currentValue,a.memoizedValue))return!0;a=a.next}return!1}function Oo(a){jo=a,Na=null,a=a.dependencies,a!==null&&(a.firstContext=null)}function fn(a){return FE(jo,a)}function bd(a,s){return jo===null&&Oo(a),FE(a,s)}function FE(a,s){var f=s._currentValue;if(s={context:s,memoizedValue:f,next:null},Na===null){if(a===null)throw Error(r(308));Na=s,a.dependencies={lanes:0,firstContext:s},a.flags|=524288}else Na=Na.next=s;return f}var nq=typeof AbortController<"u"?AbortController:function(){var a=[],s=this.signal={aborted:!1,addEventListener:function(f,m){a.push(m)}};this.abort=function(){s.aborted=!0,a.forEach(function(f){return f()})}},rq=e.unstable_scheduleCallback,aq=e.unstable_NormalPriority,qt={$$typeof:E,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Cg(){return{controller:new nq,data:new Map,refCount:0}}function Ic(a){a.refCount--,a.refCount===0&&rq(aq,function(){a.controller.abort()})}var Lc=null,Tg=0,$s=0,Is=null;function iq(a,s){if(Lc===null){var f=Lc=[];Tg=0,$s=Dy(),Is={status:"pending",value:void 0,then:function(m){f.push(m)}}}return Tg++,s.then(GE,GE),s}function GE(){if(--Tg===0&&Lc!==null){Is!==null&&(Is.status="fulfilled");var a=Lc;Lc=null,$s=0,Is=null;for(var s=0;s<a.length;s++)(0,a[s])()}}function oq(a,s){var f=[],m={status:"pending",value:null,reason:null,then:function(y){f.push(y)}};return a.then(function(){m.status="fulfilled",m.value=s;for(var y=0;y<f.length;y++)(0,f[y])(s)},function(y){for(m.status="rejected",m.reason=y,y=0;y<f.length;y++)(0,f[y])(void 0)}),m}var VE=k.S;k.S=function(a,s){CN=tn(),typeof s=="object"&&s!==null&&typeof s.then=="function"&&iq(a,s),VE!==null&&VE(a,s)};var _o=$(null);function Mg(){var a=_o.current;return a!==null?a:xt.pooledCache}function xd(a,s){s===null?q(_o,_o.current):q(_o,s.pool)}function YE(){var a=Mg();return a===null?null:{parent:qt._currentValue,pool:a}}var Ls=Error(r(460)),Rg=Error(r(474)),wd=Error(r(542)),Sd={then:function(){}};function WE(a){return a=a.status,a==="fulfilled"||a==="rejected"}function KE(a,s,f){switch(f=a[f],f===void 0?a.push(s):f!==s&&(s.then(Oa,Oa),s=f),s.status){case"fulfilled":return s.value;case"rejected":throw a=s.reason,QE(a),a;default:if(typeof s.status=="string")s.then(Oa,Oa);else{if(a=xt,a!==null&&100<a.shellSuspendCounter)throw Error(r(482));a=s,a.status="pending",a.then(function(m){if(s.status==="pending"){var y=s;y.status="fulfilled",y.value=m}},function(m){if(s.status==="pending"){var y=s;y.status="rejected",y.reason=m}})}switch(s.status){case"fulfilled":return s.value;case"rejected":throw a=s.reason,QE(a),a}throw Ao=s,Ls}}function Eo(a){try{var s=a._init;return s(a._payload)}catch(f){throw f!==null&&typeof f=="object"&&typeof f.then=="function"?(Ao=f,Ls):f}}var Ao=null;function XE(){if(Ao===null)throw Error(r(459));var a=Ao;return Ao=null,a}function QE(a){if(a===Ls||a===wd)throw Error(r(483))}var zs=null,zc=0;function jd(a){var s=zc;return zc+=1,zs===null&&(zs=[]),KE(zs,a,s)}function Bc(a,s){s=s.props.ref,a.ref=s!==void 0?s:null}function Od(a,s){throw s.$$typeof===g?Error(r(525)):(a=Object.prototype.toString.call(s),Error(r(31,a==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":a)))}function ZE(a){function s(J,K){if(a){var ee=J.deletions;ee===null?(J.deletions=[K],J.flags|=16):ee.push(K)}}function f(J,K){if(!a)return null;for(;K!==null;)s(J,K),K=K.sibling;return null}function m(J){for(var K=new Map;J!==null;)J.key!==null?K.set(J.key,J):K.set(J.index,J),J=J.sibling;return K}function y(J,K){return J=Ea(J,K),J.index=0,J.sibling=null,J}function S(J,K,ee){return J.index=ee,a?(ee=J.alternate,ee!==null?(ee=ee.index,ee<K?(J.flags|=67108866,K):ee):(J.flags|=67108866,K)):(J.flags|=1048576,K)}function T(J){return a&&J.alternate===null&&(J.flags|=67108866),J}function P(J,K,ee,de){return K===null||K.tag!==6?(K=xg(ee,J.mode,de),K.return=J,K):(K=y(K,ee),K.return=J,K)}function G(J,K,ee,de){var Ae=ee.type;return Ae===j?ce(J,K,ee.props.children,de,ee.key):K!==null&&(K.elementType===Ae||typeof Ae=="object"&&Ae!==null&&Ae.$$typeof===D&&Eo(Ae)===K.type)?(K=y(K,ee.props),Bc(K,ee),K.return=J,K):(K=vd(ee.type,ee.key,ee.props,null,J.mode,de),Bc(K,ee),K.return=J,K)}function te(J,K,ee,de){return K===null||K.tag!==4||K.stateNode.containerInfo!==ee.containerInfo||K.stateNode.implementation!==ee.implementation?(K=wg(ee,J.mode,de),K.return=J,K):(K=y(K,ee.children||[]),K.return=J,K)}function ce(J,K,ee,de,Ae){return K===null||K.tag!==7?(K=wo(ee,J.mode,de,Ae),K.return=J,K):(K=y(K,ee),K.return=J,K)}function he(J,K,ee){if(typeof K=="string"&&K!==""||typeof K=="number"||typeof K=="bigint")return K=xg(""+K,J.mode,ee),K.return=J,K;if(typeof K=="object"&&K!==null){switch(K.$$typeof){case b:return ee=vd(K.type,K.key,K.props,null,J.mode,ee),Bc(ee,K),ee.return=J,ee;case O:return K=wg(K,J.mode,ee),K.return=J,K;case D:return K=Eo(K),he(J,K,ee)}if(X(K)||F(K))return K=wo(K,J.mode,ee,null),K.return=J,K;if(typeof K.then=="function")return he(J,jd(K),ee);if(K.$$typeof===E)return he(J,bd(J,K),ee);Od(J,K)}return null}function ae(J,K,ee,de){var Ae=K!==null?K.key:null;if(typeof ee=="string"&&ee!==""||typeof ee=="number"||typeof ee=="bigint")return Ae!==null?null:P(J,K,""+ee,de);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case b:return ee.key===Ae?G(J,K,ee,de):null;case O:return ee.key===Ae?te(J,K,ee,de):null;case D:return ee=Eo(ee),ae(J,K,ee,de)}if(X(ee)||F(ee))return Ae!==null?null:ce(J,K,ee,de,null);if(typeof ee.then=="function")return ae(J,K,jd(ee),de);if(ee.$$typeof===E)return ae(J,K,bd(J,ee),de);Od(J,ee)}return null}function se(J,K,ee,de,Ae){if(typeof de=="string"&&de!==""||typeof de=="number"||typeof de=="bigint")return J=J.get(ee)||null,P(K,J,""+de,Ae);if(typeof de=="object"&&de!==null){switch(de.$$typeof){case b:return J=J.get(de.key===null?ee:de.key)||null,G(K,J,de,Ae);case O:return J=J.get(de.key===null?ee:de.key)||null,te(K,J,de,Ae);case D:return de=Eo(de),se(J,K,ee,de,Ae)}if(X(de)||F(de))return J=J.get(ee)||null,ce(K,J,de,Ae,null);if(typeof de.then=="function")return se(J,K,ee,jd(de),Ae);if(de.$$typeof===E)return se(J,K,ee,bd(K,de),Ae);Od(K,de)}return null}function Se(J,K,ee,de){for(var Ae=null,at=null,_e=K,He=K=0,et=null;_e!==null&&He<ee.length;He++){_e.index>He?(et=_e,_e=null):et=_e.sibling;var it=ae(J,_e,ee[He],de);if(it===null){_e===null&&(_e=et);break}a&&_e&&it.alternate===null&&s(J,_e),K=S(it,K,He),at===null?Ae=it:at.sibling=it,at=it,_e=et}if(He===ee.length)return f(J,_e),tt&&Aa(J,He),Ae;if(_e===null){for(;He<ee.length;He++)_e=he(J,ee[He],de),_e!==null&&(K=S(_e,K,He),at===null?Ae=_e:at.sibling=_e,at=_e);return tt&&Aa(J,He),Ae}for(_e=m(_e);He<ee.length;He++)et=se(_e,J,He,ee[He],de),et!==null&&(a&&et.alternate!==null&&_e.delete(et.key===null?He:et.key),K=S(et,K,He),at===null?Ae=et:at.sibling=et,at=et);return a&&_e.forEach(function(Ii){return s(J,Ii)}),tt&&Aa(J,He),Ae}function Me(J,K,ee,de){if(ee==null)throw Error(r(151));for(var Ae=null,at=null,_e=K,He=K=0,et=null,it=ee.next();_e!==null&&!it.done;He++,it=ee.next()){_e.index>He?(et=_e,_e=null):et=_e.sibling;var Ii=ae(J,_e,it.value,de);if(Ii===null){_e===null&&(_e=et);break}a&&_e&&Ii.alternate===null&&s(J,_e),K=S(Ii,K,He),at===null?Ae=Ii:at.sibling=Ii,at=Ii,_e=et}if(it.done)return f(J,_e),tt&&Aa(J,He),Ae;if(_e===null){for(;!it.done;He++,it=ee.next())it=he(J,it.value,de),it!==null&&(K=S(it,K,He),at===null?Ae=it:at.sibling=it,at=it);return tt&&Aa(J,He),Ae}for(_e=m(_e);!it.done;He++,it=ee.next())it=se(_e,J,He,it.value,de),it!==null&&(a&&it.alternate!==null&&_e.delete(it.key===null?He:it.key),K=S(it,K,He),at===null?Ae=it:at.sibling=it,at=it);return a&&_e.forEach(function(gU){return s(J,gU)}),tt&&Aa(J,He),Ae}function gt(J,K,ee,de){if(typeof ee=="object"&&ee!==null&&ee.type===j&&ee.key===null&&(ee=ee.props.children),typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case b:e:{for(var Ae=ee.key;K!==null;){if(K.key===Ae){if(Ae=ee.type,Ae===j){if(K.tag===7){f(J,K.sibling),de=y(K,ee.props.children),de.return=J,J=de;break e}}else if(K.elementType===Ae||typeof Ae=="object"&&Ae!==null&&Ae.$$typeof===D&&Eo(Ae)===K.type){f(J,K.sibling),de=y(K,ee.props),Bc(de,ee),de.return=J,J=de;break e}f(J,K);break}else s(J,K);K=K.sibling}ee.type===j?(de=wo(ee.props.children,J.mode,de,ee.key),de.return=J,J=de):(de=vd(ee.type,ee.key,ee.props,null,J.mode,de),Bc(de,ee),de.return=J,J=de)}return T(J);case O:e:{for(Ae=ee.key;K!==null;){if(K.key===Ae)if(K.tag===4&&K.stateNode.containerInfo===ee.containerInfo&&K.stateNode.implementation===ee.implementation){f(J,K.sibling),de=y(K,ee.children||[]),de.return=J,J=de;break e}else{f(J,K);break}else s(J,K);K=K.sibling}de=wg(ee,J.mode,de),de.return=J,J=de}return T(J);case D:return ee=Eo(ee),gt(J,K,ee,de)}if(X(ee))return Se(J,K,ee,de);if(F(ee)){if(Ae=F(ee),typeof Ae!="function")throw Error(r(150));return ee=Ae.call(ee),Me(J,K,ee,de)}if(typeof ee.then=="function")return gt(J,K,jd(ee),de);if(ee.$$typeof===E)return gt(J,K,bd(J,ee),de);Od(J,ee)}return typeof ee=="string"&&ee!==""||typeof ee=="number"||typeof ee=="bigint"?(ee=""+ee,K!==null&&K.tag===6?(f(J,K.sibling),de=y(K,ee),de.return=J,J=de):(f(J,K),de=xg(ee,J.mode,de),de.return=J,J=de),T(J)):f(J,K)}return function(J,K,ee,de){try{zc=0;var Ae=gt(J,K,ee,de);return zs=null,Ae}catch(_e){if(_e===Ls||_e===wd)throw _e;var at=Yn(29,_e,null,J.mode);return at.lanes=de,at.return=J,at}finally{}}}var No=ZE(!0),JE=ZE(!1),xi=!1;function Dg(a){a.updateQueue={baseState:a.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Pg(a,s){a=a.updateQueue,s.updateQueue===a&&(s.updateQueue={baseState:a.baseState,firstBaseUpdate:a.firstBaseUpdate,lastBaseUpdate:a.lastBaseUpdate,shared:a.shared,callbacks:null})}function wi(a){return{lane:a,tag:0,payload:null,callback:null,next:null}}function Si(a,s,f){var m=a.updateQueue;if(m===null)return null;if(m=m.shared,(st&2)!==0){var y=m.pending;return y===null?s.next=s:(s.next=y.next,y.next=s),m.pending=s,s=pd(a),$E(a,null,f),s}return md(a,m,s,f),pd(a)}function qc(a,s,f){if(s=s.updateQueue,s!==null&&(s=s.shared,(f&4194048)!==0)){var m=s.lanes;m&=a.pendingLanes,f|=m,s.lanes=f,Mn(a,f)}}function kg(a,s){var f=a.updateQueue,m=a.alternate;if(m!==null&&(m=m.updateQueue,f===m)){var y=null,S=null;if(f=f.firstBaseUpdate,f!==null){do{var T={lane:f.lane,tag:f.tag,payload:f.payload,callback:null,next:null};S===null?y=S=T:S=S.next=T,f=f.next}while(f!==null);S===null?y=S=s:S=S.next=s}else y=S=s;f={baseState:m.baseState,firstBaseUpdate:y,lastBaseUpdate:S,shared:m.shared,callbacks:m.callbacks},a.updateQueue=f;return}a=f.lastBaseUpdate,a===null?f.firstBaseUpdate=s:a.next=s,f.lastBaseUpdate=s}var $g=!1;function Uc(){if($g){var a=Is;if(a!==null)throw a}}function Hc(a,s,f,m){$g=!1;var y=a.updateQueue;xi=!1;var S=y.firstBaseUpdate,T=y.lastBaseUpdate,P=y.shared.pending;if(P!==null){y.shared.pending=null;var G=P,te=G.next;G.next=null,T===null?S=te:T.next=te,T=G;var ce=a.alternate;ce!==null&&(ce=ce.updateQueue,P=ce.lastBaseUpdate,P!==T&&(P===null?ce.firstBaseUpdate=te:P.next=te,ce.lastBaseUpdate=G))}if(S!==null){var he=y.baseState;T=0,ce=te=G=null,P=S;do{var ae=P.lane&-536870913,se=ae!==P.lane;if(se?(Je&ae)===ae:(m&ae)===ae){ae!==0&&ae===$s&&($g=!0),ce!==null&&(ce=ce.next={lane:0,tag:P.tag,payload:P.payload,callback:null,next:null});e:{var Se=a,Me=P;ae=s;var gt=f;switch(Me.tag){case 1:if(Se=Me.payload,typeof Se=="function"){he=Se.call(gt,he,ae);break e}he=Se;break e;case 3:Se.flags=Se.flags&-65537|128;case 0:if(Se=Me.payload,ae=typeof Se=="function"?Se.call(gt,he,ae):Se,ae==null)break e;he=p({},he,ae);break e;case 2:xi=!0}}ae=P.callback,ae!==null&&(a.flags|=64,se&&(a.flags|=8192),se=y.callbacks,se===null?y.callbacks=[ae]:se.push(ae))}else se={lane:ae,tag:P.tag,payload:P.payload,callback:P.callback,next:null},ce===null?(te=ce=se,G=he):ce=ce.next=se,T|=ae;if(P=P.next,P===null){if(P=y.shared.pending,P===null)break;se=P,P=se.next,se.next=null,y.lastBaseUpdate=se,y.shared.pending=null}}while(!0);ce===null&&(G=he),y.baseState=G,y.firstBaseUpdate=te,y.lastBaseUpdate=ce,S===null&&(y.shared.lanes=0),Ai|=T,a.lanes=T,a.memoizedState=he}}function eA(a,s){if(typeof a!="function")throw Error(r(191,a));a.call(s)}function tA(a,s){var f=a.callbacks;if(f!==null)for(a.callbacks=null,a=0;a<f.length;a++)eA(f[a],s)}var Bs=$(null),_d=$(0);function nA(a,s){a=La,q(_d,a),q(Bs,s),La=a|s.baseLanes}function Ig(){q(_d,La),q(Bs,Bs.current)}function Lg(){La=_d.current,V(Bs),V(_d)}var Wn=$(null),br=null;function ji(a){var s=a.alternate;q($t,$t.current&1),q(Wn,a),br===null&&(s===null||Bs.current!==null||s.memoizedState!==null)&&(br=a)}function zg(a){q($t,$t.current),q(Wn,a),br===null&&(br=a)}function rA(a){a.tag===22?(q($t,$t.current),q(Wn,a),br===null&&(br=a)):Oi()}function Oi(){q($t,$t.current),q(Wn,Wn.current)}function Kn(a){V(Wn),br===a&&(br=null),V($t)}var $t=$(0);function Ed(a){for(var s=a;s!==null;){if(s.tag===13){var f=s.memoizedState;if(f!==null&&(f=f.dehydrated,f===null||Gy(f)||Vy(f)))return s}else if(s.tag===19&&(s.memoizedProps.revealOrder==="forwards"||s.memoizedProps.revealOrder==="backwards"||s.memoizedProps.revealOrder==="unstable_legacy-backwards"||s.memoizedProps.revealOrder==="together")){if((s.flags&128)!==0)return s}else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===a)break;for(;s.sibling===null;){if(s.return===null||s.return===a)return null;s=s.return}s.sibling.return=s.return,s=s.sibling}return null}var Ta=0,qe=null,pt=null,Ut=null,Ad=!1,qs=!1,Co=!1,Nd=0,Fc=0,Us=null,sq=0;function Dt(){throw Error(r(321))}function Bg(a,s){if(s===null)return!1;for(var f=0;f<s.length&&f<a.length;f++)if(!Vn(a[f],s[f]))return!1;return!0}function qg(a,s,f,m,y,S){return Ta=S,qe=s,s.memoizedState=null,s.updateQueue=null,s.lanes=0,k.H=a===null||a.memoizedState===null?BA:ny,Co=!1,S=f(m,y),Co=!1,qs&&(S=iA(s,f,m,y)),aA(a),S}function aA(a){k.H=Yc;var s=pt!==null&&pt.next!==null;if(Ta=0,Ut=pt=qe=null,Ad=!1,Fc=0,Us=null,s)throw Error(r(300));a===null||Ht||(a=a.dependencies,a!==null&&yd(a)&&(Ht=!0))}function iA(a,s,f,m){qe=a;var y=0;do{if(qs&&(Us=null),Fc=0,qs=!1,25<=y)throw Error(r(301));if(y+=1,Ut=pt=null,a.updateQueue!=null){var S=a.updateQueue;S.lastEffect=null,S.events=null,S.stores=null,S.memoCache!=null&&(S.memoCache.index=0)}k.H=qA,S=s(f,m)}while(qs);return S}function lq(){var a=k.H,s=a.useState()[0];return s=typeof s.then=="function"?Gc(s):s,a=a.useState()[0],(pt!==null?pt.memoizedState:null)!==a&&(qe.flags|=1024),s}function Ug(){var a=Nd!==0;return Nd=0,a}function Hg(a,s,f){s.updateQueue=a.updateQueue,s.flags&=-2053,a.lanes&=~f}function Fg(a){if(Ad){for(a=a.memoizedState;a!==null;){var s=a.queue;s!==null&&(s.pending=null),a=a.next}Ad=!1}Ta=0,Ut=pt=qe=null,qs=!1,Fc=Nd=0,Us=null}function _n(){var a={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ut===null?qe.memoizedState=Ut=a:Ut=Ut.next=a,Ut}function It(){if(pt===null){var a=qe.alternate;a=a!==null?a.memoizedState:null}else a=pt.next;var s=Ut===null?qe.memoizedState:Ut.next;if(s!==null)Ut=s,pt=a;else{if(a===null)throw qe.alternate===null?Error(r(467)):Error(r(310));pt=a,a={memoizedState:pt.memoizedState,baseState:pt.baseState,baseQueue:pt.baseQueue,queue:pt.queue,next:null},Ut===null?qe.memoizedState=Ut=a:Ut=Ut.next=a}return Ut}function Cd(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Gc(a){var s=Fc;return Fc+=1,Us===null&&(Us=[]),a=KE(Us,a,s),s=qe,(Ut===null?s.memoizedState:Ut.next)===null&&(s=s.alternate,k.H=s===null||s.memoizedState===null?BA:ny),a}function Td(a){if(a!==null&&typeof a=="object"){if(typeof a.then=="function")return Gc(a);if(a.$$typeof===E)return fn(a)}throw Error(r(438,String(a)))}function Gg(a){var s=null,f=qe.updateQueue;if(f!==null&&(s=f.memoCache),s==null){var m=qe.alternate;m!==null&&(m=m.updateQueue,m!==null&&(m=m.memoCache,m!=null&&(s={data:m.data.map(function(y){return y.slice()}),index:0})))}if(s==null&&(s={data:[],index:0}),f===null&&(f=Cd(),qe.updateQueue=f),f.memoCache=s,f=s.data[s.index],f===void 0)for(f=s.data[s.index]=Array(a),m=0;m<a;m++)f[m]=Y;return s.index++,f}function Ma(a,s){return typeof s=="function"?s(a):s}function Md(a){var s=It();return Vg(s,pt,a)}function Vg(a,s,f){var m=a.queue;if(m===null)throw Error(r(311));m.lastRenderedReducer=f;var y=a.baseQueue,S=m.pending;if(S!==null){if(y!==null){var T=y.next;y.next=S.next,S.next=T}s.baseQueue=y=S,m.pending=null}if(S=a.baseState,y===null)a.memoizedState=S;else{s=y.next;var P=T=null,G=null,te=s,ce=!1;do{var he=te.lane&-536870913;if(he!==te.lane?(Je&he)===he:(Ta&he)===he){var ae=te.revertLane;if(ae===0)G!==null&&(G=G.next={lane:0,revertLane:0,gesture:null,action:te.action,hasEagerState:te.hasEagerState,eagerState:te.eagerState,next:null}),he===$s&&(ce=!0);else if((Ta&ae)===ae){te=te.next,ae===$s&&(ce=!0);continue}else he={lane:0,revertLane:te.revertLane,gesture:null,action:te.action,hasEagerState:te.hasEagerState,eagerState:te.eagerState,next:null},G===null?(P=G=he,T=S):G=G.next=he,qe.lanes|=ae,Ai|=ae;he=te.action,Co&&f(S,he),S=te.hasEagerState?te.eagerState:f(S,he)}else ae={lane:he,revertLane:te.revertLane,gesture:te.gesture,action:te.action,hasEagerState:te.hasEagerState,eagerState:te.eagerState,next:null},G===null?(P=G=ae,T=S):G=G.next=ae,qe.lanes|=he,Ai|=he;te=te.next}while(te!==null&&te!==s);if(G===null?T=S:G.next=P,!Vn(S,a.memoizedState)&&(Ht=!0,ce&&(f=Is,f!==null)))throw f;a.memoizedState=S,a.baseState=T,a.baseQueue=G,m.lastRenderedState=S}return y===null&&(m.lanes=0),[a.memoizedState,m.dispatch]}function Yg(a){var s=It(),f=s.queue;if(f===null)throw Error(r(311));f.lastRenderedReducer=a;var m=f.dispatch,y=f.pending,S=s.memoizedState;if(y!==null){f.pending=null;var T=y=y.next;do S=a(S,T.action),T=T.next;while(T!==y);Vn(S,s.memoizedState)||(Ht=!0),s.memoizedState=S,s.baseQueue===null&&(s.baseState=S),f.lastRenderedState=S}return[S,m]}function oA(a,s,f){var m=qe,y=It(),S=tt;if(S){if(f===void 0)throw Error(r(407));f=f()}else f=s();var T=!Vn((pt||y).memoizedState,f);if(T&&(y.memoizedState=f,Ht=!0),y=y.queue,Xg(cA.bind(null,m,y,a),[a]),y.getSnapshot!==s||T||Ut!==null&&Ut.memoizedState.tag&1){if(m.flags|=2048,Hs(9,{destroy:void 0},lA.bind(null,m,y,f,s),null),xt===null)throw Error(r(349));S||(Ta&127)!==0||sA(m,s,f)}return f}function sA(a,s,f){a.flags|=16384,a={getSnapshot:s,value:f},s=qe.updateQueue,s===null?(s=Cd(),qe.updateQueue=s,s.stores=[a]):(f=s.stores,f===null?s.stores=[a]:f.push(a))}function lA(a,s,f,m){s.value=f,s.getSnapshot=m,uA(s)&&fA(a)}function cA(a,s,f){return f(function(){uA(s)&&fA(a)})}function uA(a){var s=a.getSnapshot;a=a.value;try{var f=s();return!Vn(a,f)}catch{return!0}}function fA(a){var s=xo(a,2);s!==null&&zn(s,a,2)}function Wg(a){var s=_n();if(typeof a=="function"){var f=a;if(a=f(),Co){kr(!0);try{f()}finally{kr(!1)}}}return s.memoizedState=s.baseState=a,s.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ma,lastRenderedState:a},s}function dA(a,s,f,m){return a.baseState=f,Vg(a,pt,typeof m=="function"?m:Ma)}function cq(a,s,f,m,y){if(Pd(a))throw Error(r(485));if(a=s.action,a!==null){var S={payload:y,action:a,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(T){S.listeners.push(T)}};k.T!==null?f(!0):S.isTransition=!1,m(S),f=s.pending,f===null?(S.next=s.pending=S,hA(s,S)):(S.next=f.next,s.pending=f.next=S)}}function hA(a,s){var f=s.action,m=s.payload,y=a.state;if(s.isTransition){var S=k.T,T={};k.T=T;try{var P=f(y,m),G=k.S;G!==null&&G(T,P),mA(a,s,P)}catch(te){Kg(a,s,te)}finally{S!==null&&T.types!==null&&(S.types=T.types),k.T=S}}else try{S=f(y,m),mA(a,s,S)}catch(te){Kg(a,s,te)}}function mA(a,s,f){f!==null&&typeof f=="object"&&typeof f.then=="function"?f.then(function(m){pA(a,s,m)},function(m){return Kg(a,s,m)}):pA(a,s,f)}function pA(a,s,f){s.status="fulfilled",s.value=f,vA(s),a.state=f,s=a.pending,s!==null&&(f=s.next,f===s?a.pending=null:(f=f.next,s.next=f,hA(a,f)))}function Kg(a,s,f){var m=a.pending;if(a.pending=null,m!==null){m=m.next;do s.status="rejected",s.reason=f,vA(s),s=s.next;while(s!==m)}a.action=null}function vA(a){a=a.listeners;for(var s=0;s<a.length;s++)(0,a[s])()}function gA(a,s){return s}function yA(a,s){if(tt){var f=xt.formState;if(f!==null){e:{var m=qe;if(tt){if(Ot){t:{for(var y=Ot,S=yr;y.nodeType!==8;){if(!S){y=null;break t}if(y=xr(y.nextSibling),y===null){y=null;break t}}S=y.data,y=S==="F!"||S==="F"?y:null}if(y){Ot=xr(y.nextSibling),m=y.data==="F!";break e}}yi(m)}m=!1}m&&(s=f[0])}}return f=_n(),f.memoizedState=f.baseState=s,m={pending:null,lanes:0,dispatch:null,lastRenderedReducer:gA,lastRenderedState:s},f.queue=m,f=IA.bind(null,qe,m),m.dispatch=f,m=Wg(!1),S=ty.bind(null,qe,!1,m.queue),m=_n(),y={state:s,dispatch:null,action:a,pending:null},m.queue=y,f=cq.bind(null,qe,y,S,f),y.dispatch=f,m.memoizedState=a,[s,f,!1]}function bA(a){var s=It();return xA(s,pt,a)}function xA(a,s,f){if(s=Vg(a,s,gA)[0],a=Md(Ma)[0],typeof s=="object"&&s!==null&&typeof s.then=="function")try{var m=Gc(s)}catch(T){throw T===Ls?wd:T}else m=s;s=It();var y=s.queue,S=y.dispatch;return f!==s.memoizedState&&(qe.flags|=2048,Hs(9,{destroy:void 0},uq.bind(null,y,f),null)),[m,S,a]}function uq(a,s){a.action=s}function wA(a){var s=It(),f=pt;if(f!==null)return xA(s,f,a);It(),s=s.memoizedState,f=It();var m=f.queue.dispatch;return f.memoizedState=a,[s,m,!1]}function Hs(a,s,f,m){return a={tag:a,create:f,deps:m,inst:s,next:null},s=qe.updateQueue,s===null&&(s=Cd(),qe.updateQueue=s),f=s.lastEffect,f===null?s.lastEffect=a.next=a:(m=f.next,f.next=a,a.next=m,s.lastEffect=a),a}function SA(){return It().memoizedState}function Rd(a,s,f,m){var y=_n();qe.flags|=a,y.memoizedState=Hs(1|s,{destroy:void 0},f,m===void 0?null:m)}function Dd(a,s,f,m){var y=It();m=m===void 0?null:m;var S=y.memoizedState.inst;pt!==null&&m!==null&&Bg(m,pt.memoizedState.deps)?y.memoizedState=Hs(s,S,f,m):(qe.flags|=a,y.memoizedState=Hs(1|s,S,f,m))}function jA(a,s){Rd(8390656,8,a,s)}function Xg(a,s){Dd(2048,8,a,s)}function fq(a){qe.flags|=4;var s=qe.updateQueue;if(s===null)s=Cd(),qe.updateQueue=s,s.events=[a];else{var f=s.events;f===null?s.events=[a]:f.push(a)}}function OA(a){var s=It().memoizedState;return fq({ref:s,nextImpl:a}),function(){if((st&2)!==0)throw Error(r(440));return s.impl.apply(void 0,arguments)}}function _A(a,s){return Dd(4,2,a,s)}function EA(a,s){return Dd(4,4,a,s)}function AA(a,s){if(typeof s=="function"){a=a();var f=s(a);return function(){typeof f=="function"?f():s(null)}}if(s!=null)return a=a(),s.current=a,function(){s.current=null}}function NA(a,s,f){f=f!=null?f.concat([a]):null,Dd(4,4,AA.bind(null,s,a),f)}function Qg(){}function CA(a,s){var f=It();s=s===void 0?null:s;var m=f.memoizedState;return s!==null&&Bg(s,m[1])?m[0]:(f.memoizedState=[a,s],a)}function TA(a,s){var f=It();s=s===void 0?null:s;var m=f.memoizedState;if(s!==null&&Bg(s,m[1]))return m[0];if(m=a(),Co){kr(!0);try{a()}finally{kr(!1)}}return f.memoizedState=[m,s],m}function Zg(a,s,f){return f===void 0||(Ta&1073741824)!==0&&(Je&261930)===0?a.memoizedState=s:(a.memoizedState=f,a=MN(),qe.lanes|=a,Ai|=a,f)}function MA(a,s,f,m){return Vn(f,s)?f:Bs.current!==null?(a=Zg(a,f,m),Vn(a,s)||(Ht=!0),a):(Ta&42)===0||(Ta&1073741824)!==0&&(Je&261930)===0?(Ht=!0,a.memoizedState=f):(a=MN(),qe.lanes|=a,Ai|=a,s)}function RA(a,s,f,m,y){var S=H.p;H.p=S!==0&&8>S?S:8;var T=k.T,P={};k.T=P,ty(a,!1,s,f);try{var G=y(),te=k.S;if(te!==null&&te(P,G),G!==null&&typeof G=="object"&&typeof G.then=="function"){var ce=oq(G,m);Vc(a,s,ce,Zn(a))}else Vc(a,s,m,Zn(a))}catch(he){Vc(a,s,{then:function(){},status:"rejected",reason:he},Zn())}finally{H.p=S,T!==null&&P.types!==null&&(T.types=P.types),k.T=T}}function dq(){}function Jg(a,s,f,m){if(a.tag!==5)throw Error(r(476));var y=DA(a).queue;RA(a,y,s,B,f===null?dq:function(){return PA(a),f(m)})}function DA(a){var s=a.memoizedState;if(s!==null)return s;s={memoizedState:B,baseState:B,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ma,lastRenderedState:B},next:null};var f={};return s.next={memoizedState:f,baseState:f,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ma,lastRenderedState:f},next:null},a.memoizedState=s,a=a.alternate,a!==null&&(a.memoizedState=s),s}function PA(a){var s=DA(a);s.next===null&&(s=a.alternate.memoizedState),Vc(a,s.next.queue,{},Zn())}function ey(){return fn(cu)}function kA(){return It().memoizedState}function $A(){return It().memoizedState}function hq(a){for(var s=a.return;s!==null;){switch(s.tag){case 24:case 3:var f=Zn();a=wi(f);var m=Si(s,a,f);m!==null&&(zn(m,s,f),qc(m,s,f)),s={cache:Cg()},a.payload=s;return}s=s.return}}function mq(a,s,f){var m=Zn();f={lane:m,revertLane:0,gesture:null,action:f,hasEagerState:!1,eagerState:null,next:null},Pd(a)?LA(s,f):(f=yg(a,s,f,m),f!==null&&(zn(f,a,m),zA(f,s,m)))}function IA(a,s,f){var m=Zn();Vc(a,s,f,m)}function Vc(a,s,f,m){var y={lane:m,revertLane:0,gesture:null,action:f,hasEagerState:!1,eagerState:null,next:null};if(Pd(a))LA(s,y);else{var S=a.alternate;if(a.lanes===0&&(S===null||S.lanes===0)&&(S=s.lastRenderedReducer,S!==null))try{var T=s.lastRenderedState,P=S(T,f);if(y.hasEagerState=!0,y.eagerState=P,Vn(P,T))return md(a,s,y,0),xt===null&&hd(),!1}catch{}finally{}if(f=yg(a,s,y,m),f!==null)return zn(f,a,m),zA(f,s,m),!0}return!1}function ty(a,s,f,m){if(m={lane:2,revertLane:Dy(),gesture:null,action:m,hasEagerState:!1,eagerState:null,next:null},Pd(a)){if(s)throw Error(r(479))}else s=yg(a,f,m,2),s!==null&&zn(s,a,2)}function Pd(a){var s=a.alternate;return a===qe||s!==null&&s===qe}function LA(a,s){qs=Ad=!0;var f=a.pending;f===null?s.next=s:(s.next=f.next,f.next=s),a.pending=s}function zA(a,s,f){if((f&4194048)!==0){var m=s.lanes;m&=a.pendingLanes,f|=m,s.lanes=f,Mn(a,f)}}var Yc={readContext:fn,use:Td,useCallback:Dt,useContext:Dt,useEffect:Dt,useImperativeHandle:Dt,useLayoutEffect:Dt,useInsertionEffect:Dt,useMemo:Dt,useReducer:Dt,useRef:Dt,useState:Dt,useDebugValue:Dt,useDeferredValue:Dt,useTransition:Dt,useSyncExternalStore:Dt,useId:Dt,useHostTransitionStatus:Dt,useFormState:Dt,useActionState:Dt,useOptimistic:Dt,useMemoCache:Dt,useCacheRefresh:Dt};Yc.useEffectEvent=Dt;var BA={readContext:fn,use:Td,useCallback:function(a,s){return _n().memoizedState=[a,s===void 0?null:s],a},useContext:fn,useEffect:jA,useImperativeHandle:function(a,s,f){f=f!=null?f.concat([a]):null,Rd(4194308,4,AA.bind(null,s,a),f)},useLayoutEffect:function(a,s){return Rd(4194308,4,a,s)},useInsertionEffect:function(a,s){Rd(4,2,a,s)},useMemo:function(a,s){var f=_n();s=s===void 0?null:s;var m=a();if(Co){kr(!0);try{a()}finally{kr(!1)}}return f.memoizedState=[m,s],m},useReducer:function(a,s,f){var m=_n();if(f!==void 0){var y=f(s);if(Co){kr(!0);try{f(s)}finally{kr(!1)}}}else y=s;return m.memoizedState=m.baseState=y,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:a,lastRenderedState:y},m.queue=a,a=a.dispatch=mq.bind(null,qe,a),[m.memoizedState,a]},useRef:function(a){var s=_n();return a={current:a},s.memoizedState=a},useState:function(a){a=Wg(a);var s=a.queue,f=IA.bind(null,qe,s);return s.dispatch=f,[a.memoizedState,f]},useDebugValue:Qg,useDeferredValue:function(a,s){var f=_n();return Zg(f,a,s)},useTransition:function(){var a=Wg(!1);return a=RA.bind(null,qe,a.queue,!0,!1),_n().memoizedState=a,[!1,a]},useSyncExternalStore:function(a,s,f){var m=qe,y=_n();if(tt){if(f===void 0)throw Error(r(407));f=f()}else{if(f=s(),xt===null)throw Error(r(349));(Je&127)!==0||sA(m,s,f)}y.memoizedState=f;var S={value:f,getSnapshot:s};return y.queue=S,jA(cA.bind(null,m,S,a),[a]),m.flags|=2048,Hs(9,{destroy:void 0},lA.bind(null,m,S,f,s),null),f},useId:function(){var a=_n(),s=xt.identifierPrefix;if(tt){var f=na,m=ta;f=(m&~(1<<32-gn(m)-1)).toString(32)+f,s="_"+s+"R_"+f,f=Nd++,0<f&&(s+="H"+f.toString(32)),s+="_"}else f=sq++,s="_"+s+"r_"+f.toString(32)+"_";return a.memoizedState=s},useHostTransitionStatus:ey,useFormState:yA,useActionState:yA,useOptimistic:function(a){var s=_n();s.memoizedState=s.baseState=a;var f={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return s.queue=f,s=ty.bind(null,qe,!0,f),f.dispatch=s,[a,s]},useMemoCache:Gg,useCacheRefresh:function(){return _n().memoizedState=hq.bind(null,qe)},useEffectEvent:function(a){var s=_n(),f={impl:a};return s.memoizedState=f,function(){if((st&2)!==0)throw Error(r(440));return f.impl.apply(void 0,arguments)}}},ny={readContext:fn,use:Td,useCallback:CA,useContext:fn,useEffect:Xg,useImperativeHandle:NA,useInsertionEffect:_A,useLayoutEffect:EA,useMemo:TA,useReducer:Md,useRef:SA,useState:function(){return Md(Ma)},useDebugValue:Qg,useDeferredValue:function(a,s){var f=It();return MA(f,pt.memoizedState,a,s)},useTransition:function(){var a=Md(Ma)[0],s=It().memoizedState;return[typeof a=="boolean"?a:Gc(a),s]},useSyncExternalStore:oA,useId:kA,useHostTransitionStatus:ey,useFormState:bA,useActionState:bA,useOptimistic:function(a,s){var f=It();return dA(f,pt,a,s)},useMemoCache:Gg,useCacheRefresh:$A};ny.useEffectEvent=OA;var qA={readContext:fn,use:Td,useCallback:CA,useContext:fn,useEffect:Xg,useImperativeHandle:NA,useInsertionEffect:_A,useLayoutEffect:EA,useMemo:TA,useReducer:Yg,useRef:SA,useState:function(){return Yg(Ma)},useDebugValue:Qg,useDeferredValue:function(a,s){var f=It();return pt===null?Zg(f,a,s):MA(f,pt.memoizedState,a,s)},useTransition:function(){var a=Yg(Ma)[0],s=It().memoizedState;return[typeof a=="boolean"?a:Gc(a),s]},useSyncExternalStore:oA,useId:kA,useHostTransitionStatus:ey,useFormState:wA,useActionState:wA,useOptimistic:function(a,s){var f=It();return pt!==null?dA(f,pt,a,s):(f.baseState=a,[a,f.queue.dispatch])},useMemoCache:Gg,useCacheRefresh:$A};qA.useEffectEvent=OA;function ry(a,s,f,m){s=a.memoizedState,f=f(m,s),f=f==null?s:p({},s,f),a.memoizedState=f,a.lanes===0&&(a.updateQueue.baseState=f)}var ay={enqueueSetState:function(a,s,f){a=a._reactInternals;var m=Zn(),y=wi(m);y.payload=s,f!=null&&(y.callback=f),s=Si(a,y,m),s!==null&&(zn(s,a,m),qc(s,a,m))},enqueueReplaceState:function(a,s,f){a=a._reactInternals;var m=Zn(),y=wi(m);y.tag=1,y.payload=s,f!=null&&(y.callback=f),s=Si(a,y,m),s!==null&&(zn(s,a,m),qc(s,a,m))},enqueueForceUpdate:function(a,s){a=a._reactInternals;var f=Zn(),m=wi(f);m.tag=2,s!=null&&(m.callback=s),s=Si(a,m,f),s!==null&&(zn(s,a,f),qc(s,a,f))}};function UA(a,s,f,m,y,S,T){return a=a.stateNode,typeof a.shouldComponentUpdate=="function"?a.shouldComponentUpdate(m,S,T):s.prototype&&s.prototype.isPureReactComponent?!Dc(f,m)||!Dc(y,S):!0}function HA(a,s,f,m){a=s.state,typeof s.componentWillReceiveProps=="function"&&s.componentWillReceiveProps(f,m),typeof s.UNSAFE_componentWillReceiveProps=="function"&&s.UNSAFE_componentWillReceiveProps(f,m),s.state!==a&&ay.enqueueReplaceState(s,s.state,null)}function To(a,s){var f=s;if("ref"in s){f={};for(var m in s)m!=="ref"&&(f[m]=s[m])}if(a=a.defaultProps){f===s&&(f=p({},f));for(var y in a)f[y]===void 0&&(f[y]=a[y])}return f}function FA(a){dd(a)}function GA(a){console.error(a)}function VA(a){dd(a)}function kd(a,s){try{var f=a.onUncaughtError;f(s.value,{componentStack:s.stack})}catch(m){setTimeout(function(){throw m})}}function YA(a,s,f){try{var m=a.onCaughtError;m(f.value,{componentStack:f.stack,errorBoundary:s.tag===1?s.stateNode:null})}catch(y){setTimeout(function(){throw y})}}function iy(a,s,f){return f=wi(f),f.tag=3,f.payload={element:null},f.callback=function(){kd(a,s)},f}function WA(a){return a=wi(a),a.tag=3,a}function KA(a,s,f,m){var y=f.type.getDerivedStateFromError;if(typeof y=="function"){var S=m.value;a.payload=function(){return y(S)},a.callback=function(){YA(s,f,m)}}var T=f.stateNode;T!==null&&typeof T.componentDidCatch=="function"&&(a.callback=function(){YA(s,f,m),typeof y!="function"&&(Ni===null?Ni=new Set([this]):Ni.add(this));var P=m.stack;this.componentDidCatch(m.value,{componentStack:P!==null?P:""})})}function pq(a,s,f,m,y){if(f.flags|=32768,m!==null&&typeof m=="object"&&typeof m.then=="function"){if(s=f.alternate,s!==null&&ks(s,f,y,!0),f=Wn.current,f!==null){switch(f.tag){case 31:case 13:return br===null?Yd():f.alternate===null&&Pt===0&&(Pt=3),f.flags&=-257,f.flags|=65536,f.lanes=y,m===Sd?f.flags|=16384:(s=f.updateQueue,s===null?f.updateQueue=new Set([m]):s.add(m),Ty(a,m,y)),!1;case 22:return f.flags|=65536,m===Sd?f.flags|=16384:(s=f.updateQueue,s===null?(s={transitions:null,markerInstances:null,retryQueue:new Set([m])},f.updateQueue=s):(f=s.retryQueue,f===null?s.retryQueue=new Set([m]):f.add(m)),Ty(a,m,y)),!1}throw Error(r(435,f.tag))}return Ty(a,m,y),Yd(),!1}if(tt)return s=Wn.current,s!==null?((s.flags&65536)===0&&(s.flags|=256),s.flags|=65536,s.lanes=y,m!==Og&&(a=Error(r(422),{cause:m}),$c(pr(a,f)))):(m!==Og&&(s=Error(r(423),{cause:m}),$c(pr(s,f))),a=a.current.alternate,a.flags|=65536,y&=-y,a.lanes|=y,m=pr(m,f),y=iy(a.stateNode,m,y),kg(a,y),Pt!==4&&(Pt=2)),!1;var S=Error(r(520),{cause:m});if(S=pr(S,f),tu===null?tu=[S]:tu.push(S),Pt!==4&&(Pt=2),s===null)return!0;m=pr(m,f),f=s;do{switch(f.tag){case 3:return f.flags|=65536,a=y&-y,f.lanes|=a,a=iy(f.stateNode,m,a),kg(f,a),!1;case 1:if(s=f.type,S=f.stateNode,(f.flags&128)===0&&(typeof s.getDerivedStateFromError=="function"||S!==null&&typeof S.componentDidCatch=="function"&&(Ni===null||!Ni.has(S))))return f.flags|=65536,y&=-y,f.lanes|=y,y=WA(y),KA(y,a,f,m),kg(f,y),!1}f=f.return}while(f!==null);return!1}var oy=Error(r(461)),Ht=!1;function dn(a,s,f,m){s.child=a===null?JE(s,null,f,m):No(s,a.child,f,m)}function XA(a,s,f,m,y){f=f.render;var S=s.ref;if("ref"in m){var T={};for(var P in m)P!=="ref"&&(T[P]=m[P])}else T=m;return Oo(s),m=qg(a,s,f,T,S,y),P=Ug(),a!==null&&!Ht?(Hg(a,s,y),Ra(a,s,y)):(tt&&P&&Sg(s),s.flags|=1,dn(a,s,m,y),s.child)}function QA(a,s,f,m,y){if(a===null){var S=f.type;return typeof S=="function"&&!bg(S)&&S.defaultProps===void 0&&f.compare===null?(s.tag=15,s.type=S,ZA(a,s,S,m,y)):(a=vd(f.type,null,m,s,s.mode,y),a.ref=s.ref,a.return=s,s.child=a)}if(S=a.child,!my(a,y)){var T=S.memoizedProps;if(f=f.compare,f=f!==null?f:Dc,f(T,m)&&a.ref===s.ref)return Ra(a,s,y)}return s.flags|=1,a=Ea(S,m),a.ref=s.ref,a.return=s,s.child=a}function ZA(a,s,f,m,y){if(a!==null){var S=a.memoizedProps;if(Dc(S,m)&&a.ref===s.ref)if(Ht=!1,s.pendingProps=m=S,my(a,y))(a.flags&131072)!==0&&(Ht=!0);else return s.lanes=a.lanes,Ra(a,s,y)}return sy(a,s,f,m,y)}function JA(a,s,f,m){var y=m.children,S=a!==null?a.memoizedState:null;if(a===null&&s.stateNode===null&&(s.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),m.mode==="hidden"){if((s.flags&128)!==0){if(S=S!==null?S.baseLanes|f:f,a!==null){for(m=s.child=a.child,y=0;m!==null;)y=y|m.lanes|m.childLanes,m=m.sibling;m=y&~S}else m=0,s.child=null;return eN(a,s,S,f,m)}if((f&536870912)!==0)s.memoizedState={baseLanes:0,cachePool:null},a!==null&&xd(s,S!==null?S.cachePool:null),S!==null?nA(s,S):Ig(),rA(s);else return m=s.lanes=536870912,eN(a,s,S!==null?S.baseLanes|f:f,f,m)}else S!==null?(xd(s,S.cachePool),nA(s,S),Oi(),s.memoizedState=null):(a!==null&&xd(s,null),Ig(),Oi());return dn(a,s,y,f),s.child}function Wc(a,s){return a!==null&&a.tag===22||s.stateNode!==null||(s.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),s.sibling}function eN(a,s,f,m,y){var S=Mg();return S=S===null?null:{parent:qt._currentValue,pool:S},s.memoizedState={baseLanes:f,cachePool:S},a!==null&&xd(s,null),Ig(),rA(s),a!==null&&ks(a,s,m,!0),s.childLanes=y,null}function $d(a,s){return s=Ld({mode:s.mode,children:s.children},a.mode),s.ref=a.ref,a.child=s,s.return=a,s}function tN(a,s,f){return No(s,a.child,null,f),a=$d(s,s.pendingProps),a.flags|=2,Kn(s),s.memoizedState=null,a}function vq(a,s,f){var m=s.pendingProps,y=(s.flags&128)!==0;if(s.flags&=-129,a===null){if(tt){if(m.mode==="hidden")return a=$d(s,m),s.lanes=536870912,Wc(null,a);if(zg(s),(a=Ot)?(a=h2(a,yr),a=a!==null&&a.data==="&"?a:null,a!==null&&(s.memoizedState={dehydrated:a,treeContext:vi!==null?{id:ta,overflow:na}:null,retryLane:536870912,hydrationErrors:null},f=LE(a),f.return=s,s.child=f,un=s,Ot=null)):a=null,a===null)throw yi(s);return s.lanes=536870912,null}return $d(s,m)}var S=a.memoizedState;if(S!==null){var T=S.dehydrated;if(zg(s),y)if(s.flags&256)s.flags&=-257,s=tN(a,s,f);else if(s.memoizedState!==null)s.child=a.child,s.flags|=128,s=null;else throw Error(r(558));else if(Ht||ks(a,s,f,!1),y=(f&a.childLanes)!==0,Ht||y){if(m=xt,m!==null&&(T=Rn(m,f),T!==0&&T!==S.retryLane))throw S.retryLane=T,xo(a,T),zn(m,a,T),oy;Yd(),s=tN(a,s,f)}else a=S.treeContext,Ot=xr(T.nextSibling),un=s,tt=!0,gi=null,yr=!1,a!==null&&qE(s,a),s=$d(s,m),s.flags|=4096;return s}return a=Ea(a.child,{mode:m.mode,children:m.children}),a.ref=s.ref,s.child=a,a.return=s,a}function Id(a,s){var f=s.ref;if(f===null)a!==null&&a.ref!==null&&(s.flags|=4194816);else{if(typeof f!="function"&&typeof f!="object")throw Error(r(284));(a===null||a.ref!==f)&&(s.flags|=4194816)}}function sy(a,s,f,m,y){return Oo(s),f=qg(a,s,f,m,void 0,y),m=Ug(),a!==null&&!Ht?(Hg(a,s,y),Ra(a,s,y)):(tt&&m&&Sg(s),s.flags|=1,dn(a,s,f,y),s.child)}function nN(a,s,f,m,y,S){return Oo(s),s.updateQueue=null,f=iA(s,m,f,y),aA(a),m=Ug(),a!==null&&!Ht?(Hg(a,s,S),Ra(a,s,S)):(tt&&m&&Sg(s),s.flags|=1,dn(a,s,f,S),s.child)}function rN(a,s,f,m,y){if(Oo(s),s.stateNode===null){var S=Ms,T=f.contextType;typeof T=="object"&&T!==null&&(S=fn(T)),S=new f(m,S),s.memoizedState=S.state!==null&&S.state!==void 0?S.state:null,S.updater=ay,s.stateNode=S,S._reactInternals=s,S=s.stateNode,S.props=m,S.state=s.memoizedState,S.refs={},Dg(s),T=f.contextType,S.context=typeof T=="object"&&T!==null?fn(T):Ms,S.state=s.memoizedState,T=f.getDerivedStateFromProps,typeof T=="function"&&(ry(s,f,T,m),S.state=s.memoizedState),typeof f.getDerivedStateFromProps=="function"||typeof S.getSnapshotBeforeUpdate=="function"||typeof S.UNSAFE_componentWillMount!="function"&&typeof S.componentWillMount!="function"||(T=S.state,typeof S.componentWillMount=="function"&&S.componentWillMount(),typeof S.UNSAFE_componentWillMount=="function"&&S.UNSAFE_componentWillMount(),T!==S.state&&ay.enqueueReplaceState(S,S.state,null),Hc(s,m,S,y),Uc(),S.state=s.memoizedState),typeof S.componentDidMount=="function"&&(s.flags|=4194308),m=!0}else if(a===null){S=s.stateNode;var P=s.memoizedProps,G=To(f,P);S.props=G;var te=S.context,ce=f.contextType;T=Ms,typeof ce=="object"&&ce!==null&&(T=fn(ce));var he=f.getDerivedStateFromProps;ce=typeof he=="function"||typeof S.getSnapshotBeforeUpdate=="function",P=s.pendingProps!==P,ce||typeof S.UNSAFE_componentWillReceiveProps!="function"&&typeof S.componentWillReceiveProps!="function"||(P||te!==T)&&HA(s,S,m,T),xi=!1;var ae=s.memoizedState;S.state=ae,Hc(s,m,S,y),Uc(),te=s.memoizedState,P||ae!==te||xi?(typeof he=="function"&&(ry(s,f,he,m),te=s.memoizedState),(G=xi||UA(s,f,G,m,ae,te,T))?(ce||typeof S.UNSAFE_componentWillMount!="function"&&typeof S.componentWillMount!="function"||(typeof S.componentWillMount=="function"&&S.componentWillMount(),typeof S.UNSAFE_componentWillMount=="function"&&S.UNSAFE_componentWillMount()),typeof S.componentDidMount=="function"&&(s.flags|=4194308)):(typeof S.componentDidMount=="function"&&(s.flags|=4194308),s.memoizedProps=m,s.memoizedState=te),S.props=m,S.state=te,S.context=T,m=G):(typeof S.componentDidMount=="function"&&(s.flags|=4194308),m=!1)}else{S=s.stateNode,Pg(a,s),T=s.memoizedProps,ce=To(f,T),S.props=ce,he=s.pendingProps,ae=S.context,te=f.contextType,G=Ms,typeof te=="object"&&te!==null&&(G=fn(te)),P=f.getDerivedStateFromProps,(te=typeof P=="function"||typeof S.getSnapshotBeforeUpdate=="function")||typeof S.UNSAFE_componentWillReceiveProps!="function"&&typeof S.componentWillReceiveProps!="function"||(T!==he||ae!==G)&&HA(s,S,m,G),xi=!1,ae=s.memoizedState,S.state=ae,Hc(s,m,S,y),Uc();var se=s.memoizedState;T!==he||ae!==se||xi||a!==null&&a.dependencies!==null&&yd(a.dependencies)?(typeof P=="function"&&(ry(s,f,P,m),se=s.memoizedState),(ce=xi||UA(s,f,ce,m,ae,se,G)||a!==null&&a.dependencies!==null&&yd(a.dependencies))?(te||typeof S.UNSAFE_componentWillUpdate!="function"&&typeof S.componentWillUpdate!="function"||(typeof S.componentWillUpdate=="function"&&S.componentWillUpdate(m,se,G),typeof S.UNSAFE_componentWillUpdate=="function"&&S.UNSAFE_componentWillUpdate(m,se,G)),typeof S.componentDidUpdate=="function"&&(s.flags|=4),typeof S.getSnapshotBeforeUpdate=="function"&&(s.flags|=1024)):(typeof S.componentDidUpdate!="function"||T===a.memoizedProps&&ae===a.memoizedState||(s.flags|=4),typeof S.getSnapshotBeforeUpdate!="function"||T===a.memoizedProps&&ae===a.memoizedState||(s.flags|=1024),s.memoizedProps=m,s.memoizedState=se),S.props=m,S.state=se,S.context=G,m=ce):(typeof S.componentDidUpdate!="function"||T===a.memoizedProps&&ae===a.memoizedState||(s.flags|=4),typeof S.getSnapshotBeforeUpdate!="function"||T===a.memoizedProps&&ae===a.memoizedState||(s.flags|=1024),m=!1)}return S=m,Id(a,s),m=(s.flags&128)!==0,S||m?(S=s.stateNode,f=m&&typeof f.getDerivedStateFromError!="function"?null:S.render(),s.flags|=1,a!==null&&m?(s.child=No(s,a.child,null,y),s.child=No(s,null,f,y)):dn(a,s,f,y),s.memoizedState=S.state,a=s.child):a=Ra(a,s,y),a}function aN(a,s,f,m){return So(),s.flags|=256,dn(a,s,f,m),s.child}var ly={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function cy(a){return{baseLanes:a,cachePool:YE()}}function uy(a,s,f){return a=a!==null?a.childLanes&~f:0,s&&(a|=Qn),a}function iN(a,s,f){var m=s.pendingProps,y=!1,S=(s.flags&128)!==0,T;if((T=S)||(T=a!==null&&a.memoizedState===null?!1:($t.current&2)!==0),T&&(y=!0,s.flags&=-129),T=(s.flags&32)!==0,s.flags&=-33,a===null){if(tt){if(y?ji(s):Oi(),(a=Ot)?(a=h2(a,yr),a=a!==null&&a.data!=="&"?a:null,a!==null&&(s.memoizedState={dehydrated:a,treeContext:vi!==null?{id:ta,overflow:na}:null,retryLane:536870912,hydrationErrors:null},f=LE(a),f.return=s,s.child=f,un=s,Ot=null)):a=null,a===null)throw yi(s);return Vy(a)?s.lanes=32:s.lanes=536870912,null}var P=m.children;return m=m.fallback,y?(Oi(),y=s.mode,P=Ld({mode:"hidden",children:P},y),m=wo(m,y,f,null),P.return=s,m.return=s,P.sibling=m,s.child=P,m=s.child,m.memoizedState=cy(f),m.childLanes=uy(a,T,f),s.memoizedState=ly,Wc(null,m)):(ji(s),fy(s,P))}var G=a.memoizedState;if(G!==null&&(P=G.dehydrated,P!==null)){if(S)s.flags&256?(ji(s),s.flags&=-257,s=dy(a,s,f)):s.memoizedState!==null?(Oi(),s.child=a.child,s.flags|=128,s=null):(Oi(),P=m.fallback,y=s.mode,m=Ld({mode:"visible",children:m.children},y),P=wo(P,y,f,null),P.flags|=2,m.return=s,P.return=s,m.sibling=P,s.child=m,No(s,a.child,null,f),m=s.child,m.memoizedState=cy(f),m.childLanes=uy(a,T,f),s.memoizedState=ly,s=Wc(null,m));else if(ji(s),Vy(P)){if(T=P.nextSibling&&P.nextSibling.dataset,T)var te=T.dgst;T=te,m=Error(r(419)),m.stack="",m.digest=T,$c({value:m,source:null,stack:null}),s=dy(a,s,f)}else if(Ht||ks(a,s,f,!1),T=(f&a.childLanes)!==0,Ht||T){if(T=xt,T!==null&&(m=Rn(T,f),m!==0&&m!==G.retryLane))throw G.retryLane=m,xo(a,m),zn(T,a,m),oy;Gy(P)||Yd(),s=dy(a,s,f)}else Gy(P)?(s.flags|=192,s.child=a.child,s=null):(a=G.treeContext,Ot=xr(P.nextSibling),un=s,tt=!0,gi=null,yr=!1,a!==null&&qE(s,a),s=fy(s,m.children),s.flags|=4096);return s}return y?(Oi(),P=m.fallback,y=s.mode,G=a.child,te=G.sibling,m=Ea(G,{mode:"hidden",children:m.children}),m.subtreeFlags=G.subtreeFlags&65011712,te!==null?P=Ea(te,P):(P=wo(P,y,f,null),P.flags|=2),P.return=s,m.return=s,m.sibling=P,s.child=m,Wc(null,m),m=s.child,P=a.child.memoizedState,P===null?P=cy(f):(y=P.cachePool,y!==null?(G=qt._currentValue,y=y.parent!==G?{parent:G,pool:G}:y):y=YE(),P={baseLanes:P.baseLanes|f,cachePool:y}),m.memoizedState=P,m.childLanes=uy(a,T,f),s.memoizedState=ly,Wc(a.child,m)):(ji(s),f=a.child,a=f.sibling,f=Ea(f,{mode:"visible",children:m.children}),f.return=s,f.sibling=null,a!==null&&(T=s.deletions,T===null?(s.deletions=[a],s.flags|=16):T.push(a)),s.child=f,s.memoizedState=null,f)}function fy(a,s){return s=Ld({mode:"visible",children:s},a.mode),s.return=a,a.child=s}function Ld(a,s){return a=Yn(22,a,null,s),a.lanes=0,a}function dy(a,s,f){return No(s,a.child,null,f),a=fy(s,s.pendingProps.children),a.flags|=2,s.memoizedState=null,a}function oN(a,s,f){a.lanes|=s;var m=a.alternate;m!==null&&(m.lanes|=s),Ag(a.return,s,f)}function hy(a,s,f,m,y,S){var T=a.memoizedState;T===null?a.memoizedState={isBackwards:s,rendering:null,renderingStartTime:0,last:m,tail:f,tailMode:y,treeForkCount:S}:(T.isBackwards=s,T.rendering=null,T.renderingStartTime=0,T.last=m,T.tail=f,T.tailMode=y,T.treeForkCount=S)}function sN(a,s,f){var m=s.pendingProps,y=m.revealOrder,S=m.tail;m=m.children;var T=$t.current,P=(T&2)!==0;if(P?(T=T&1|2,s.flags|=128):T&=1,q($t,T),dn(a,s,m,f),m=tt?kc:0,!P&&a!==null&&(a.flags&128)!==0)e:for(a=s.child;a!==null;){if(a.tag===13)a.memoizedState!==null&&oN(a,f,s);else if(a.tag===19)oN(a,f,s);else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===s)break e;for(;a.sibling===null;){if(a.return===null||a.return===s)break e;a=a.return}a.sibling.return=a.return,a=a.sibling}switch(y){case"forwards":for(f=s.child,y=null;f!==null;)a=f.alternate,a!==null&&Ed(a)===null&&(y=f),f=f.sibling;f=y,f===null?(y=s.child,s.child=null):(y=f.sibling,f.sibling=null),hy(s,!1,y,f,S,m);break;case"backwards":case"unstable_legacy-backwards":for(f=null,y=s.child,s.child=null;y!==null;){if(a=y.alternate,a!==null&&Ed(a)===null){s.child=y;break}a=y.sibling,y.sibling=f,f=y,y=a}hy(s,!0,f,null,S,m);break;case"together":hy(s,!1,null,null,void 0,m);break;default:s.memoizedState=null}return s.child}function Ra(a,s,f){if(a!==null&&(s.dependencies=a.dependencies),Ai|=s.lanes,(f&s.childLanes)===0)if(a!==null){if(ks(a,s,f,!1),(f&s.childLanes)===0)return null}else return null;if(a!==null&&s.child!==a.child)throw Error(r(153));if(s.child!==null){for(a=s.child,f=Ea(a,a.pendingProps),s.child=f,f.return=s;a.sibling!==null;)a=a.sibling,f=f.sibling=Ea(a,a.pendingProps),f.return=s;f.sibling=null}return s.child}function my(a,s){return(a.lanes&s)!==0?!0:(a=a.dependencies,!!(a!==null&&yd(a)))}function gq(a,s,f){switch(s.tag){case 3:pe(s,s.stateNode.containerInfo),bi(s,qt,a.memoizedState.cache),So();break;case 27:case 5:ve(s);break;case 4:pe(s,s.stateNode.containerInfo);break;case 10:bi(s,s.type,s.memoizedProps.value);break;case 31:if(s.memoizedState!==null)return s.flags|=128,zg(s),null;break;case 13:var m=s.memoizedState;if(m!==null)return m.dehydrated!==null?(ji(s),s.flags|=128,null):(f&s.child.childLanes)!==0?iN(a,s,f):(ji(s),a=Ra(a,s,f),a!==null?a.sibling:null);ji(s);break;case 19:var y=(a.flags&128)!==0;if(m=(f&s.childLanes)!==0,m||(ks(a,s,f,!1),m=(f&s.childLanes)!==0),y){if(m)return sN(a,s,f);s.flags|=128}if(y=s.memoizedState,y!==null&&(y.rendering=null,y.tail=null,y.lastEffect=null),q($t,$t.current),m)break;return null;case 22:return s.lanes=0,JA(a,s,f,s.pendingProps);case 24:bi(s,qt,a.memoizedState.cache)}return Ra(a,s,f)}function lN(a,s,f){if(a!==null)if(a.memoizedProps!==s.pendingProps)Ht=!0;else{if(!my(a,f)&&(s.flags&128)===0)return Ht=!1,gq(a,s,f);Ht=(a.flags&131072)!==0}else Ht=!1,tt&&(s.flags&1048576)!==0&&BE(s,kc,s.index);switch(s.lanes=0,s.tag){case 16:e:{var m=s.pendingProps;if(a=Eo(s.elementType),s.type=a,typeof a=="function")bg(a)?(m=To(a,m),s.tag=1,s=rN(null,s,a,m,f)):(s.tag=0,s=sy(null,s,a,m,f));else{if(a!=null){var y=a.$$typeof;if(y===C){s.tag=11,s=XA(null,s,a,m,f);break e}else if(y===R){s.tag=14,s=QA(null,s,a,m,f);break e}}throw s=Q(a)||a,Error(r(306,s,""))}}return s;case 0:return sy(a,s,s.type,s.pendingProps,f);case 1:return m=s.type,y=To(m,s.pendingProps),rN(a,s,m,y,f);case 3:e:{if(pe(s,s.stateNode.containerInfo),a===null)throw Error(r(387));m=s.pendingProps;var S=s.memoizedState;y=S.element,Pg(a,s),Hc(s,m,null,f);var T=s.memoizedState;if(m=T.cache,bi(s,qt,m),m!==S.cache&&Ng(s,[qt],f,!0),Uc(),m=T.element,S.isDehydrated)if(S={element:m,isDehydrated:!1,cache:T.cache},s.updateQueue.baseState=S,s.memoizedState=S,s.flags&256){s=aN(a,s,m,f);break e}else if(m!==y){y=pr(Error(r(424)),s),$c(y),s=aN(a,s,m,f);break e}else{switch(a=s.stateNode.containerInfo,a.nodeType){case 9:a=a.body;break;default:a=a.nodeName==="HTML"?a.ownerDocument.body:a}for(Ot=xr(a.firstChild),un=s,tt=!0,gi=null,yr=!0,f=JE(s,null,m,f),s.child=f;f;)f.flags=f.flags&-3|4096,f=f.sibling}else{if(So(),m===y){s=Ra(a,s,f);break e}dn(a,s,m,f)}s=s.child}return s;case 26:return Id(a,s),a===null?(f=b2(s.type,null,s.pendingProps,null))?s.memoizedState=f:tt||(f=s.type,a=s.pendingProps,m=eh(fe.current).createElement(f),m[cn]=s,m[Dn]=a,hn(m,f,a),rn(m),s.stateNode=m):s.memoizedState=b2(s.type,a.memoizedProps,s.pendingProps,a.memoizedState),null;case 27:return ve(s),a===null&&tt&&(m=s.stateNode=v2(s.type,s.pendingProps,fe.current),un=s,yr=!0,y=Ot,Ri(s.type)?(Yy=y,Ot=xr(m.firstChild)):Ot=y),dn(a,s,s.pendingProps.children,f),Id(a,s),a===null&&(s.flags|=4194304),s.child;case 5:return a===null&&tt&&((y=m=Ot)&&(m=Yq(m,s.type,s.pendingProps,yr),m!==null?(s.stateNode=m,un=s,Ot=xr(m.firstChild),yr=!1,y=!0):y=!1),y||yi(s)),ve(s),y=s.type,S=s.pendingProps,T=a!==null?a.memoizedProps:null,m=S.children,Uy(y,S)?m=null:T!==null&&Uy(y,T)&&(s.flags|=32),s.memoizedState!==null&&(y=qg(a,s,lq,null,null,f),cu._currentValue=y),Id(a,s),dn(a,s,m,f),s.child;case 6:return a===null&&tt&&((a=f=Ot)&&(f=Wq(f,s.pendingProps,yr),f!==null?(s.stateNode=f,un=s,Ot=null,a=!0):a=!1),a||yi(s)),null;case 13:return iN(a,s,f);case 4:return pe(s,s.stateNode.containerInfo),m=s.pendingProps,a===null?s.child=No(s,null,m,f):dn(a,s,m,f),s.child;case 11:return XA(a,s,s.type,s.pendingProps,f);case 7:return dn(a,s,s.pendingProps,f),s.child;case 8:return dn(a,s,s.pendingProps.children,f),s.child;case 12:return dn(a,s,s.pendingProps.children,f),s.child;case 10:return m=s.pendingProps,bi(s,s.type,m.value),dn(a,s,m.children,f),s.child;case 9:return y=s.type._context,m=s.pendingProps.children,Oo(s),y=fn(y),m=m(y),s.flags|=1,dn(a,s,m,f),s.child;case 14:return QA(a,s,s.type,s.pendingProps,f);case 15:return ZA(a,s,s.type,s.pendingProps,f);case 19:return sN(a,s,f);case 31:return vq(a,s,f);case 22:return JA(a,s,f,s.pendingProps);case 24:return Oo(s),m=fn(qt),a===null?(y=Mg(),y===null&&(y=xt,S=Cg(),y.pooledCache=S,S.refCount++,S!==null&&(y.pooledCacheLanes|=f),y=S),s.memoizedState={parent:m,cache:y},Dg(s),bi(s,qt,y)):((a.lanes&f)!==0&&(Pg(a,s),Hc(s,null,null,f),Uc()),y=a.memoizedState,S=s.memoizedState,y.parent!==m?(y={parent:m,cache:m},s.memoizedState=y,s.lanes===0&&(s.memoizedState=s.updateQueue.baseState=y),bi(s,qt,m)):(m=S.cache,bi(s,qt,m),m!==y.cache&&Ng(s,[qt],f,!0))),dn(a,s,s.pendingProps.children,f),s.child;case 29:throw s.pendingProps}throw Error(r(156,s.tag))}function Da(a){a.flags|=4}function py(a,s,f,m,y){if((s=(a.mode&32)!==0)&&(s=!1),s){if(a.flags|=16777216,(y&335544128)===y)if(a.stateNode.complete)a.flags|=8192;else if(kN())a.flags|=8192;else throw Ao=Sd,Rg}else a.flags&=-16777217}function cN(a,s){if(s.type!=="stylesheet"||(s.state.loading&4)!==0)a.flags&=-16777217;else if(a.flags|=16777216,!O2(s))if(kN())a.flags|=8192;else throw Ao=Sd,Rg}function zd(a,s){s!==null&&(a.flags|=4),a.flags&16384&&(s=a.tag!==22?yn():536870912,a.lanes|=s,Ys|=s)}function Kc(a,s){if(!tt)switch(a.tailMode){case"hidden":s=a.tail;for(var f=null;s!==null;)s.alternate!==null&&(f=s),s=s.sibling;f===null?a.tail=null:f.sibling=null;break;case"collapsed":f=a.tail;for(var m=null;f!==null;)f.alternate!==null&&(m=f),f=f.sibling;m===null?s||a.tail===null?a.tail=null:a.tail.sibling=null:m.sibling=null}}function _t(a){var s=a.alternate!==null&&a.alternate.child===a.child,f=0,m=0;if(s)for(var y=a.child;y!==null;)f|=y.lanes|y.childLanes,m|=y.subtreeFlags&65011712,m|=y.flags&65011712,y.return=a,y=y.sibling;else for(y=a.child;y!==null;)f|=y.lanes|y.childLanes,m|=y.subtreeFlags,m|=y.flags,y.return=a,y=y.sibling;return a.subtreeFlags|=m,a.childLanes=f,s}function yq(a,s,f){var m=s.pendingProps;switch(jg(s),s.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return _t(s),null;case 1:return _t(s),null;case 3:return f=s.stateNode,m=null,a!==null&&(m=a.memoizedState.cache),s.memoizedState.cache!==m&&(s.flags|=2048),Ca(qt),re(),f.pendingContext&&(f.context=f.pendingContext,f.pendingContext=null),(a===null||a.child===null)&&(Ps(s)?Da(s):a===null||a.memoizedState.isDehydrated&&(s.flags&256)===0||(s.flags|=1024,_g())),_t(s),null;case 26:var y=s.type,S=s.memoizedState;return a===null?(Da(s),S!==null?(_t(s),cN(s,S)):(_t(s),py(s,y,null,m,f))):S?S!==a.memoizedState?(Da(s),_t(s),cN(s,S)):(_t(s),s.flags&=-16777217):(a=a.memoizedProps,a!==m&&Da(s),_t(s),py(s,y,a,m,f)),null;case 27:if(ge(s),f=fe.current,y=s.type,a!==null&&s.stateNode!=null)a.memoizedProps!==m&&Da(s);else{if(!m){if(s.stateNode===null)throw Error(r(166));return _t(s),null}a=U.current,Ps(s)?UE(s):(a=v2(y,m,f),s.stateNode=a,Da(s))}return _t(s),null;case 5:if(ge(s),y=s.type,a!==null&&s.stateNode!=null)a.memoizedProps!==m&&Da(s);else{if(!m){if(s.stateNode===null)throw Error(r(166));return _t(s),null}if(S=U.current,Ps(s))UE(s);else{var T=eh(fe.current);switch(S){case 1:S=T.createElementNS("http://www.w3.org/2000/svg",y);break;case 2:S=T.createElementNS("http://www.w3.org/1998/Math/MathML",y);break;default:switch(y){case"svg":S=T.createElementNS("http://www.w3.org/2000/svg",y);break;case"math":S=T.createElementNS("http://www.w3.org/1998/Math/MathML",y);break;case"script":S=T.createElement("div"),S.innerHTML="<script><\/script>",S=S.removeChild(S.firstChild);break;case"select":S=typeof m.is=="string"?T.createElement("select",{is:m.is}):T.createElement("select"),m.multiple?S.multiple=!0:m.size&&(S.size=m.size);break;default:S=typeof m.is=="string"?T.createElement(y,{is:m.is}):T.createElement(y)}}S[cn]=s,S[Dn]=m;e:for(T=s.child;T!==null;){if(T.tag===5||T.tag===6)S.appendChild(T.stateNode);else if(T.tag!==4&&T.tag!==27&&T.child!==null){T.child.return=T,T=T.child;continue}if(T===s)break e;for(;T.sibling===null;){if(T.return===null||T.return===s)break e;T=T.return}T.sibling.return=T.return,T=T.sibling}s.stateNode=S;e:switch(hn(S,y,m),y){case"button":case"input":case"select":case"textarea":m=!!m.autoFocus;break e;case"img":m=!0;break e;default:m=!1}m&&Da(s)}}return _t(s),py(s,s.type,a===null?null:a.memoizedProps,s.pendingProps,f),null;case 6:if(a&&s.stateNode!=null)a.memoizedProps!==m&&Da(s);else{if(typeof m!="string"&&s.stateNode===null)throw Error(r(166));if(a=fe.current,Ps(s)){if(a=s.stateNode,f=s.memoizedProps,m=null,y=un,y!==null)switch(y.tag){case 27:case 5:m=y.memoizedProps}a[cn]=s,a=!!(a.nodeValue===f||m!==null&&m.suppressHydrationWarning===!0||i2(a.nodeValue,f)),a||yi(s,!0)}else a=eh(a).createTextNode(m),a[cn]=s,s.stateNode=a}return _t(s),null;case 31:if(f=s.memoizedState,a===null||a.memoizedState!==null){if(m=Ps(s),f!==null){if(a===null){if(!m)throw Error(r(318));if(a=s.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(r(557));a[cn]=s}else So(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;_t(s),a=!1}else f=_g(),a!==null&&a.memoizedState!==null&&(a.memoizedState.hydrationErrors=f),a=!0;if(!a)return s.flags&256?(Kn(s),s):(Kn(s),null);if((s.flags&128)!==0)throw Error(r(558))}return _t(s),null;case 13:if(m=s.memoizedState,a===null||a.memoizedState!==null&&a.memoizedState.dehydrated!==null){if(y=Ps(s),m!==null&&m.dehydrated!==null){if(a===null){if(!y)throw Error(r(318));if(y=s.memoizedState,y=y!==null?y.dehydrated:null,!y)throw Error(r(317));y[cn]=s}else So(),(s.flags&128)===0&&(s.memoizedState=null),s.flags|=4;_t(s),y=!1}else y=_g(),a!==null&&a.memoizedState!==null&&(a.memoizedState.hydrationErrors=y),y=!0;if(!y)return s.flags&256?(Kn(s),s):(Kn(s),null)}return Kn(s),(s.flags&128)!==0?(s.lanes=f,s):(f=m!==null,a=a!==null&&a.memoizedState!==null,f&&(m=s.child,y=null,m.alternate!==null&&m.alternate.memoizedState!==null&&m.alternate.memoizedState.cachePool!==null&&(y=m.alternate.memoizedState.cachePool.pool),S=null,m.memoizedState!==null&&m.memoizedState.cachePool!==null&&(S=m.memoizedState.cachePool.pool),S!==y&&(m.flags|=2048)),f!==a&&f&&(s.child.flags|=8192),zd(s,s.updateQueue),_t(s),null);case 4:return re(),a===null&&Iy(s.stateNode.containerInfo),_t(s),null;case 10:return Ca(s.type),_t(s),null;case 19:if(V($t),m=s.memoizedState,m===null)return _t(s),null;if(y=(s.flags&128)!==0,S=m.rendering,S===null)if(y)Kc(m,!1);else{if(Pt!==0||a!==null&&(a.flags&128)!==0)for(a=s.child;a!==null;){if(S=Ed(a),S!==null){for(s.flags|=128,Kc(m,!1),a=S.updateQueue,s.updateQueue=a,zd(s,a),s.subtreeFlags=0,a=f,f=s.child;f!==null;)IE(f,a),f=f.sibling;return q($t,$t.current&1|2),tt&&Aa(s,m.treeForkCount),s.child}a=a.sibling}m.tail!==null&&tn()>Fd&&(s.flags|=128,y=!0,Kc(m,!1),s.lanes=4194304)}else{if(!y)if(a=Ed(S),a!==null){if(s.flags|=128,y=!0,a=a.updateQueue,s.updateQueue=a,zd(s,a),Kc(m,!0),m.tail===null&&m.tailMode==="hidden"&&!S.alternate&&!tt)return _t(s),null}else 2*tn()-m.renderingStartTime>Fd&&f!==536870912&&(s.flags|=128,y=!0,Kc(m,!1),s.lanes=4194304);m.isBackwards?(S.sibling=s.child,s.child=S):(a=m.last,a!==null?a.sibling=S:s.child=S,m.last=S)}return m.tail!==null?(a=m.tail,m.rendering=a,m.tail=a.sibling,m.renderingStartTime=tn(),a.sibling=null,f=$t.current,q($t,y?f&1|2:f&1),tt&&Aa(s,m.treeForkCount),a):(_t(s),null);case 22:case 23:return Kn(s),Lg(),m=s.memoizedState!==null,a!==null?a.memoizedState!==null!==m&&(s.flags|=8192):m&&(s.flags|=8192),m?(f&536870912)!==0&&(s.flags&128)===0&&(_t(s),s.subtreeFlags&6&&(s.flags|=8192)):_t(s),f=s.updateQueue,f!==null&&zd(s,f.retryQueue),f=null,a!==null&&a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(f=a.memoizedState.cachePool.pool),m=null,s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(m=s.memoizedState.cachePool.pool),m!==f&&(s.flags|=2048),a!==null&&V(_o),null;case 24:return f=null,a!==null&&(f=a.memoizedState.cache),s.memoizedState.cache!==f&&(s.flags|=2048),Ca(qt),_t(s),null;case 25:return null;case 30:return null}throw Error(r(156,s.tag))}function bq(a,s){switch(jg(s),s.tag){case 1:return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 3:return Ca(qt),re(),a=s.flags,(a&65536)!==0&&(a&128)===0?(s.flags=a&-65537|128,s):null;case 26:case 27:case 5:return ge(s),null;case 31:if(s.memoizedState!==null){if(Kn(s),s.alternate===null)throw Error(r(340));So()}return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 13:if(Kn(s),a=s.memoizedState,a!==null&&a.dehydrated!==null){if(s.alternate===null)throw Error(r(340));So()}return a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 19:return V($t),null;case 4:return re(),null;case 10:return Ca(s.type),null;case 22:case 23:return Kn(s),Lg(),a!==null&&V(_o),a=s.flags,a&65536?(s.flags=a&-65537|128,s):null;case 24:return Ca(qt),null;case 25:return null;default:return null}}function uN(a,s){switch(jg(s),s.tag){case 3:Ca(qt),re();break;case 26:case 27:case 5:ge(s);break;case 4:re();break;case 31:s.memoizedState!==null&&Kn(s);break;case 13:Kn(s);break;case 19:V($t);break;case 10:Ca(s.type);break;case 22:case 23:Kn(s),Lg(),a!==null&&V(_o);break;case 24:Ca(qt)}}function Xc(a,s){try{var f=s.updateQueue,m=f!==null?f.lastEffect:null;if(m!==null){var y=m.next;f=y;do{if((f.tag&a)===a){m=void 0;var S=f.create,T=f.inst;m=S(),T.destroy=m}f=f.next}while(f!==y)}}catch(P){dt(s,s.return,P)}}function _i(a,s,f){try{var m=s.updateQueue,y=m!==null?m.lastEffect:null;if(y!==null){var S=y.next;m=S;do{if((m.tag&a)===a){var T=m.inst,P=T.destroy;if(P!==void 0){T.destroy=void 0,y=s;var G=f,te=P;try{te()}catch(ce){dt(y,G,ce)}}}m=m.next}while(m!==S)}}catch(ce){dt(s,s.return,ce)}}function fN(a){var s=a.updateQueue;if(s!==null){var f=a.stateNode;try{tA(s,f)}catch(m){dt(a,a.return,m)}}}function dN(a,s,f){f.props=To(a.type,a.memoizedProps),f.state=a.memoizedState;try{f.componentWillUnmount()}catch(m){dt(a,s,m)}}function Qc(a,s){try{var f=a.ref;if(f!==null){switch(a.tag){case 26:case 27:case 5:var m=a.stateNode;break;case 30:m=a.stateNode;break;default:m=a.stateNode}typeof f=="function"?a.refCleanup=f(m):f.current=m}}catch(y){dt(a,s,y)}}function ra(a,s){var f=a.ref,m=a.refCleanup;if(f!==null)if(typeof m=="function")try{m()}catch(y){dt(a,s,y)}finally{a.refCleanup=null,a=a.alternate,a!=null&&(a.refCleanup=null)}else if(typeof f=="function")try{f(null)}catch(y){dt(a,s,y)}else f.current=null}function hN(a){var s=a.type,f=a.memoizedProps,m=a.stateNode;try{e:switch(s){case"button":case"input":case"select":case"textarea":f.autoFocus&&m.focus();break e;case"img":f.src?m.src=f.src:f.srcSet&&(m.srcset=f.srcSet)}}catch(y){dt(a,a.return,y)}}function vy(a,s,f){try{var m=a.stateNode;qq(m,a.type,f,s),m[Dn]=s}catch(y){dt(a,a.return,y)}}function mN(a){return a.tag===5||a.tag===3||a.tag===26||a.tag===27&&Ri(a.type)||a.tag===4}function gy(a){e:for(;;){for(;a.sibling===null;){if(a.return===null||mN(a.return))return null;a=a.return}for(a.sibling.return=a.return,a=a.sibling;a.tag!==5&&a.tag!==6&&a.tag!==18;){if(a.tag===27&&Ri(a.type)||a.flags&2||a.child===null||a.tag===4)continue e;a.child.return=a,a=a.child}if(!(a.flags&2))return a.stateNode}}function yy(a,s,f){var m=a.tag;if(m===5||m===6)a=a.stateNode,s?(f.nodeType===9?f.body:f.nodeName==="HTML"?f.ownerDocument.body:f).insertBefore(a,s):(s=f.nodeType===9?f.body:f.nodeName==="HTML"?f.ownerDocument.body:f,s.appendChild(a),f=f._reactRootContainer,f!=null||s.onclick!==null||(s.onclick=Oa));else if(m!==4&&(m===27&&Ri(a.type)&&(f=a.stateNode,s=null),a=a.child,a!==null))for(yy(a,s,f),a=a.sibling;a!==null;)yy(a,s,f),a=a.sibling}function Bd(a,s,f){var m=a.tag;if(m===5||m===6)a=a.stateNode,s?f.insertBefore(a,s):f.appendChild(a);else if(m!==4&&(m===27&&Ri(a.type)&&(f=a.stateNode),a=a.child,a!==null))for(Bd(a,s,f),a=a.sibling;a!==null;)Bd(a,s,f),a=a.sibling}function pN(a){var s=a.stateNode,f=a.memoizedProps;try{for(var m=a.type,y=s.attributes;y.length;)s.removeAttributeNode(y[0]);hn(s,m,f),s[cn]=a,s[Dn]=f}catch(S){dt(a,a.return,S)}}var Pa=!1,Ft=!1,by=!1,vN=typeof WeakSet=="function"?WeakSet:Set,an=null;function xq(a,s){if(a=a.containerInfo,By=sh,a=NE(a),dg(a)){if("selectionStart"in a)var f={start:a.selectionStart,end:a.selectionEnd};else e:{f=(f=a.ownerDocument)&&f.defaultView||window;var m=f.getSelection&&f.getSelection();if(m&&m.rangeCount!==0){f=m.anchorNode;var y=m.anchorOffset,S=m.focusNode;m=m.focusOffset;try{f.nodeType,S.nodeType}catch{f=null;break e}var T=0,P=-1,G=-1,te=0,ce=0,he=a,ae=null;t:for(;;){for(var se;he!==f||y!==0&&he.nodeType!==3||(P=T+y),he!==S||m!==0&&he.nodeType!==3||(G=T+m),he.nodeType===3&&(T+=he.nodeValue.length),(se=he.firstChild)!==null;)ae=he,he=se;for(;;){if(he===a)break t;if(ae===f&&++te===y&&(P=T),ae===S&&++ce===m&&(G=T),(se=he.nextSibling)!==null)break;he=ae,ae=he.parentNode}he=se}f=P===-1||G===-1?null:{start:P,end:G}}else f=null}f=f||{start:0,end:0}}else f=null;for(qy={focusedElem:a,selectionRange:f},sh=!1,an=s;an!==null;)if(s=an,a=s.child,(s.subtreeFlags&1028)!==0&&a!==null)a.return=s,an=a;else for(;an!==null;){switch(s=an,S=s.alternate,a=s.flags,s.tag){case 0:if((a&4)!==0&&(a=s.updateQueue,a=a!==null?a.events:null,a!==null))for(f=0;f<a.length;f++)y=a[f],y.ref.impl=y.nextImpl;break;case 11:case 15:break;case 1:if((a&1024)!==0&&S!==null){a=void 0,f=s,y=S.memoizedProps,S=S.memoizedState,m=f.stateNode;try{var Se=To(f.type,y);a=m.getSnapshotBeforeUpdate(Se,S),m.__reactInternalSnapshotBeforeUpdate=a}catch(Me){dt(f,f.return,Me)}}break;case 3:if((a&1024)!==0){if(a=s.stateNode.containerInfo,f=a.nodeType,f===9)Fy(a);else if(f===1)switch(a.nodeName){case"HEAD":case"HTML":case"BODY":Fy(a);break;default:a.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((a&1024)!==0)throw Error(r(163))}if(a=s.sibling,a!==null){a.return=s.return,an=a;break}an=s.return}}function gN(a,s,f){var m=f.flags;switch(f.tag){case 0:case 11:case 15:$a(a,f),m&4&&Xc(5,f);break;case 1:if($a(a,f),m&4)if(a=f.stateNode,s===null)try{a.componentDidMount()}catch(T){dt(f,f.return,T)}else{var y=To(f.type,s.memoizedProps);s=s.memoizedState;try{a.componentDidUpdate(y,s,a.__reactInternalSnapshotBeforeUpdate)}catch(T){dt(f,f.return,T)}}m&64&&fN(f),m&512&&Qc(f,f.return);break;case 3:if($a(a,f),m&64&&(a=f.updateQueue,a!==null)){if(s=null,f.child!==null)switch(f.child.tag){case 27:case 5:s=f.child.stateNode;break;case 1:s=f.child.stateNode}try{tA(a,s)}catch(T){dt(f,f.return,T)}}break;case 27:s===null&&m&4&&pN(f);case 26:case 5:$a(a,f),s===null&&m&4&&hN(f),m&512&&Qc(f,f.return);break;case 12:$a(a,f);break;case 31:$a(a,f),m&4&&xN(a,f);break;case 13:$a(a,f),m&4&&wN(a,f),m&64&&(a=f.memoizedState,a!==null&&(a=a.dehydrated,a!==null&&(f=Cq.bind(null,f),Kq(a,f))));break;case 22:if(m=f.memoizedState!==null||Pa,!m){s=s!==null&&s.memoizedState!==null||Ft,y=Pa;var S=Ft;Pa=m,(Ft=s)&&!S?Ia(a,f,(f.subtreeFlags&8772)!==0):$a(a,f),Pa=y,Ft=S}break;case 30:break;default:$a(a,f)}}function yN(a){var s=a.alternate;s!==null&&(a.alternate=null,yN(s)),a.child=null,a.deletions=null,a.sibling=null,a.tag===5&&(s=a.stateNode,s!==null&&Kv(s)),a.stateNode=null,a.return=null,a.dependencies=null,a.memoizedProps=null,a.memoizedState=null,a.pendingProps=null,a.stateNode=null,a.updateQueue=null}var Nt=null,kn=!1;function ka(a,s,f){for(f=f.child;f!==null;)bN(a,s,f),f=f.sibling}function bN(a,s,f){if(On&&typeof On.onCommitFiberUnmount=="function")try{On.onCommitFiberUnmount(ho,f)}catch{}switch(f.tag){case 26:Ft||ra(f,s),ka(a,s,f),f.memoizedState?f.memoizedState.count--:f.stateNode&&(f=f.stateNode,f.parentNode.removeChild(f));break;case 27:Ft||ra(f,s);var m=Nt,y=kn;Ri(f.type)&&(Nt=f.stateNode,kn=!1),ka(a,s,f),ou(f.stateNode),Nt=m,kn=y;break;case 5:Ft||ra(f,s);case 6:if(m=Nt,y=kn,Nt=null,ka(a,s,f),Nt=m,kn=y,Nt!==null)if(kn)try{(Nt.nodeType===9?Nt.body:Nt.nodeName==="HTML"?Nt.ownerDocument.body:Nt).removeChild(f.stateNode)}catch(S){dt(f,s,S)}else try{Nt.removeChild(f.stateNode)}catch(S){dt(f,s,S)}break;case 18:Nt!==null&&(kn?(a=Nt,f2(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,f.stateNode),tl(a)):f2(Nt,f.stateNode));break;case 4:m=Nt,y=kn,Nt=f.stateNode.containerInfo,kn=!0,ka(a,s,f),Nt=m,kn=y;break;case 0:case 11:case 14:case 15:_i(2,f,s),Ft||_i(4,f,s),ka(a,s,f);break;case 1:Ft||(ra(f,s),m=f.stateNode,typeof m.componentWillUnmount=="function"&&dN(f,s,m)),ka(a,s,f);break;case 21:ka(a,s,f);break;case 22:Ft=(m=Ft)||f.memoizedState!==null,ka(a,s,f),Ft=m;break;default:ka(a,s,f)}}function xN(a,s){if(s.memoizedState===null&&(a=s.alternate,a!==null&&(a=a.memoizedState,a!==null))){a=a.dehydrated;try{tl(a)}catch(f){dt(s,s.return,f)}}}function wN(a,s){if(s.memoizedState===null&&(a=s.alternate,a!==null&&(a=a.memoizedState,a!==null&&(a=a.dehydrated,a!==null))))try{tl(a)}catch(f){dt(s,s.return,f)}}function wq(a){switch(a.tag){case 31:case 13:case 19:var s=a.stateNode;return s===null&&(s=a.stateNode=new vN),s;case 22:return a=a.stateNode,s=a._retryCache,s===null&&(s=a._retryCache=new vN),s;default:throw Error(r(435,a.tag))}}function qd(a,s){var f=wq(a);s.forEach(function(m){if(!f.has(m)){f.add(m);var y=Tq.bind(null,a,m);m.then(y,y)}})}function $n(a,s){var f=s.deletions;if(f!==null)for(var m=0;m<f.length;m++){var y=f[m],S=a,T=s,P=T;e:for(;P!==null;){switch(P.tag){case 27:if(Ri(P.type)){Nt=P.stateNode,kn=!1;break e}break;case 5:Nt=P.stateNode,kn=!1;break e;case 3:case 4:Nt=P.stateNode.containerInfo,kn=!0;break e}P=P.return}if(Nt===null)throw Error(r(160));bN(S,T,y),Nt=null,kn=!1,S=y.alternate,S!==null&&(S.return=null),y.return=null}if(s.subtreeFlags&13886)for(s=s.child;s!==null;)SN(s,a),s=s.sibling}var Lr=null;function SN(a,s){var f=a.alternate,m=a.flags;switch(a.tag){case 0:case 11:case 14:case 15:$n(s,a),In(a),m&4&&(_i(3,a,a.return),Xc(3,a),_i(5,a,a.return));break;case 1:$n(s,a),In(a),m&512&&(Ft||f===null||ra(f,f.return)),m&64&&Pa&&(a=a.updateQueue,a!==null&&(m=a.callbacks,m!==null&&(f=a.shared.hiddenCallbacks,a.shared.hiddenCallbacks=f===null?m:f.concat(m))));break;case 26:var y=Lr;if($n(s,a),In(a),m&512&&(Ft||f===null||ra(f,f.return)),m&4){var S=f!==null?f.memoizedState:null;if(m=a.memoizedState,f===null)if(m===null)if(a.stateNode===null){e:{m=a.type,f=a.memoizedProps,y=y.ownerDocument||y;t:switch(m){case"title":S=y.getElementsByTagName("title")[0],(!S||S[Oc]||S[cn]||S.namespaceURI==="http://www.w3.org/2000/svg"||S.hasAttribute("itemprop"))&&(S=y.createElement(m),y.head.insertBefore(S,y.querySelector("head > title"))),hn(S,m,f),S[cn]=a,rn(S),m=S;break e;case"link":var T=S2("link","href",y).get(m+(f.href||""));if(T){for(var P=0;P<T.length;P++)if(S=T[P],S.getAttribute("href")===(f.href==null||f.href===""?null:f.href)&&S.getAttribute("rel")===(f.rel==null?null:f.rel)&&S.getAttribute("title")===(f.title==null?null:f.title)&&S.getAttribute("crossorigin")===(f.crossOrigin==null?null:f.crossOrigin)){T.splice(P,1);break t}}S=y.createElement(m),hn(S,m,f),y.head.appendChild(S);break;case"meta":if(T=S2("meta","content",y).get(m+(f.content||""))){for(P=0;P<T.length;P++)if(S=T[P],S.getAttribute("content")===(f.content==null?null:""+f.content)&&S.getAttribute("name")===(f.name==null?null:f.name)&&S.getAttribute("property")===(f.property==null?null:f.property)&&S.getAttribute("http-equiv")===(f.httpEquiv==null?null:f.httpEquiv)&&S.getAttribute("charset")===(f.charSet==null?null:f.charSet)){T.splice(P,1);break t}}S=y.createElement(m),hn(S,m,f),y.head.appendChild(S);break;default:throw Error(r(468,m))}S[cn]=a,rn(S),m=S}a.stateNode=m}else j2(y,a.type,a.stateNode);else a.stateNode=w2(y,m,a.memoizedProps);else S!==m?(S===null?f.stateNode!==null&&(f=f.stateNode,f.parentNode.removeChild(f)):S.count--,m===null?j2(y,a.type,a.stateNode):w2(y,m,a.memoizedProps)):m===null&&a.stateNode!==null&&vy(a,a.memoizedProps,f.memoizedProps)}break;case 27:$n(s,a),In(a),m&512&&(Ft||f===null||ra(f,f.return)),f!==null&&m&4&&vy(a,a.memoizedProps,f.memoizedProps);break;case 5:if($n(s,a),In(a),m&512&&(Ft||f===null||ra(f,f.return)),a.flags&32){y=a.stateNode;try{Os(y,"")}catch(Se){dt(a,a.return,Se)}}m&4&&a.stateNode!=null&&(y=a.memoizedProps,vy(a,y,f!==null?f.memoizedProps:y)),m&1024&&(by=!0);break;case 6:if($n(s,a),In(a),m&4){if(a.stateNode===null)throw Error(r(162));m=a.memoizedProps,f=a.stateNode;try{f.nodeValue=m}catch(Se){dt(a,a.return,Se)}}break;case 3:if(rh=null,y=Lr,Lr=th(s.containerInfo),$n(s,a),Lr=y,In(a),m&4&&f!==null&&f.memoizedState.isDehydrated)try{tl(s.containerInfo)}catch(Se){dt(a,a.return,Se)}by&&(by=!1,jN(a));break;case 4:m=Lr,Lr=th(a.stateNode.containerInfo),$n(s,a),In(a),Lr=m;break;case 12:$n(s,a),In(a);break;case 31:$n(s,a),In(a),m&4&&(m=a.updateQueue,m!==null&&(a.updateQueue=null,qd(a,m)));break;case 13:$n(s,a),In(a),a.child.flags&8192&&a.memoizedState!==null!=(f!==null&&f.memoizedState!==null)&&(Hd=tn()),m&4&&(m=a.updateQueue,m!==null&&(a.updateQueue=null,qd(a,m)));break;case 22:y=a.memoizedState!==null;var G=f!==null&&f.memoizedState!==null,te=Pa,ce=Ft;if(Pa=te||y,Ft=ce||G,$n(s,a),Ft=ce,Pa=te,In(a),m&8192)e:for(s=a.stateNode,s._visibility=y?s._visibility&-2:s._visibility|1,y&&(f===null||G||Pa||Ft||Mo(a)),f=null,s=a;;){if(s.tag===5||s.tag===26){if(f===null){G=f=s;try{if(S=G.stateNode,y)T=S.style,typeof T.setProperty=="function"?T.setProperty("display","none","important"):T.display="none";else{P=G.stateNode;var he=G.memoizedProps.style,ae=he!=null&&he.hasOwnProperty("display")?he.display:null;P.style.display=ae==null||typeof ae=="boolean"?"":(""+ae).trim()}}catch(Se){dt(G,G.return,Se)}}}else if(s.tag===6){if(f===null){G=s;try{G.stateNode.nodeValue=y?"":G.memoizedProps}catch(Se){dt(G,G.return,Se)}}}else if(s.tag===18){if(f===null){G=s;try{var se=G.stateNode;y?d2(se,!0):d2(G.stateNode,!1)}catch(Se){dt(G,G.return,Se)}}}else if((s.tag!==22&&s.tag!==23||s.memoizedState===null||s===a)&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===a)break e;for(;s.sibling===null;){if(s.return===null||s.return===a)break e;f===s&&(f=null),s=s.return}f===s&&(f=null),s.sibling.return=s.return,s=s.sibling}m&4&&(m=a.updateQueue,m!==null&&(f=m.retryQueue,f!==null&&(m.retryQueue=null,qd(a,f))));break;case 19:$n(s,a),In(a),m&4&&(m=a.updateQueue,m!==null&&(a.updateQueue=null,qd(a,m)));break;case 30:break;case 21:break;default:$n(s,a),In(a)}}function In(a){var s=a.flags;if(s&2){try{for(var f,m=a.return;m!==null;){if(mN(m)){f=m;break}m=m.return}if(f==null)throw Error(r(160));switch(f.tag){case 27:var y=f.stateNode,S=gy(a);Bd(a,S,y);break;case 5:var T=f.stateNode;f.flags&32&&(Os(T,""),f.flags&=-33);var P=gy(a);Bd(a,P,T);break;case 3:case 4:var G=f.stateNode.containerInfo,te=gy(a);yy(a,te,G);break;default:throw Error(r(161))}}catch(ce){dt(a,a.return,ce)}a.flags&=-3}s&4096&&(a.flags&=-4097)}function jN(a){if(a.subtreeFlags&1024)for(a=a.child;a!==null;){var s=a;jN(s),s.tag===5&&s.flags&1024&&s.stateNode.reset(),a=a.sibling}}function $a(a,s){if(s.subtreeFlags&8772)for(s=s.child;s!==null;)gN(a,s.alternate,s),s=s.sibling}function Mo(a){for(a=a.child;a!==null;){var s=a;switch(s.tag){case 0:case 11:case 14:case 15:_i(4,s,s.return),Mo(s);break;case 1:ra(s,s.return);var f=s.stateNode;typeof f.componentWillUnmount=="function"&&dN(s,s.return,f),Mo(s);break;case 27:ou(s.stateNode);case 26:case 5:ra(s,s.return),Mo(s);break;case 22:s.memoizedState===null&&Mo(s);break;case 30:Mo(s);break;default:Mo(s)}a=a.sibling}}function Ia(a,s,f){for(f=f&&(s.subtreeFlags&8772)!==0,s=s.child;s!==null;){var m=s.alternate,y=a,S=s,T=S.flags;switch(S.tag){case 0:case 11:case 15:Ia(y,S,f),Xc(4,S);break;case 1:if(Ia(y,S,f),m=S,y=m.stateNode,typeof y.componentDidMount=="function")try{y.componentDidMount()}catch(te){dt(m,m.return,te)}if(m=S,y=m.updateQueue,y!==null){var P=m.stateNode;try{var G=y.shared.hiddenCallbacks;if(G!==null)for(y.shared.hiddenCallbacks=null,y=0;y<G.length;y++)eA(G[y],P)}catch(te){dt(m,m.return,te)}}f&&T&64&&fN(S),Qc(S,S.return);break;case 27:pN(S);case 26:case 5:Ia(y,S,f),f&&m===null&&T&4&&hN(S),Qc(S,S.return);break;case 12:Ia(y,S,f);break;case 31:Ia(y,S,f),f&&T&4&&xN(y,S);break;case 13:Ia(y,S,f),f&&T&4&&wN(y,S);break;case 22:S.memoizedState===null&&Ia(y,S,f),Qc(S,S.return);break;case 30:break;default:Ia(y,S,f)}s=s.sibling}}function xy(a,s){var f=null;a!==null&&a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(f=a.memoizedState.cachePool.pool),a=null,s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(a=s.memoizedState.cachePool.pool),a!==f&&(a!=null&&a.refCount++,f!=null&&Ic(f))}function wy(a,s){a=null,s.alternate!==null&&(a=s.alternate.memoizedState.cache),s=s.memoizedState.cache,s!==a&&(s.refCount++,a!=null&&Ic(a))}function zr(a,s,f,m){if(s.subtreeFlags&10256)for(s=s.child;s!==null;)ON(a,s,f,m),s=s.sibling}function ON(a,s,f,m){var y=s.flags;switch(s.tag){case 0:case 11:case 15:zr(a,s,f,m),y&2048&&Xc(9,s);break;case 1:zr(a,s,f,m);break;case 3:zr(a,s,f,m),y&2048&&(a=null,s.alternate!==null&&(a=s.alternate.memoizedState.cache),s=s.memoizedState.cache,s!==a&&(s.refCount++,a!=null&&Ic(a)));break;case 12:if(y&2048){zr(a,s,f,m),a=s.stateNode;try{var S=s.memoizedProps,T=S.id,P=S.onPostCommit;typeof P=="function"&&P(T,s.alternate===null?"mount":"update",a.passiveEffectDuration,-0)}catch(G){dt(s,s.return,G)}}else zr(a,s,f,m);break;case 31:zr(a,s,f,m);break;case 13:zr(a,s,f,m);break;case 23:break;case 22:S=s.stateNode,T=s.alternate,s.memoizedState!==null?S._visibility&2?zr(a,s,f,m):Zc(a,s):S._visibility&2?zr(a,s,f,m):(S._visibility|=2,Fs(a,s,f,m,(s.subtreeFlags&10256)!==0||!1)),y&2048&&xy(T,s);break;case 24:zr(a,s,f,m),y&2048&&wy(s.alternate,s);break;default:zr(a,s,f,m)}}function Fs(a,s,f,m,y){for(y=y&&((s.subtreeFlags&10256)!==0||!1),s=s.child;s!==null;){var S=a,T=s,P=f,G=m,te=T.flags;switch(T.tag){case 0:case 11:case 15:Fs(S,T,P,G,y),Xc(8,T);break;case 23:break;case 22:var ce=T.stateNode;T.memoizedState!==null?ce._visibility&2?Fs(S,T,P,G,y):Zc(S,T):(ce._visibility|=2,Fs(S,T,P,G,y)),y&&te&2048&&xy(T.alternate,T);break;case 24:Fs(S,T,P,G,y),y&&te&2048&&wy(T.alternate,T);break;default:Fs(S,T,P,G,y)}s=s.sibling}}function Zc(a,s){if(s.subtreeFlags&10256)for(s=s.child;s!==null;){var f=a,m=s,y=m.flags;switch(m.tag){case 22:Zc(f,m),y&2048&&xy(m.alternate,m);break;case 24:Zc(f,m),y&2048&&wy(m.alternate,m);break;default:Zc(f,m)}s=s.sibling}}var Jc=8192;function Gs(a,s,f){if(a.subtreeFlags&Jc)for(a=a.child;a!==null;)_N(a,s,f),a=a.sibling}function _N(a,s,f){switch(a.tag){case 26:Gs(a,s,f),a.flags&Jc&&a.memoizedState!==null&&sU(f,Lr,a.memoizedState,a.memoizedProps);break;case 5:Gs(a,s,f);break;case 3:case 4:var m=Lr;Lr=th(a.stateNode.containerInfo),Gs(a,s,f),Lr=m;break;case 22:a.memoizedState===null&&(m=a.alternate,m!==null&&m.memoizedState!==null?(m=Jc,Jc=16777216,Gs(a,s,f),Jc=m):Gs(a,s,f));break;default:Gs(a,s,f)}}function EN(a){var s=a.alternate;if(s!==null&&(a=s.child,a!==null)){s.child=null;do s=a.sibling,a.sibling=null,a=s;while(a!==null)}}function eu(a){var s=a.deletions;if((a.flags&16)!==0){if(s!==null)for(var f=0;f<s.length;f++){var m=s[f];an=m,NN(m,a)}EN(a)}if(a.subtreeFlags&10256)for(a=a.child;a!==null;)AN(a),a=a.sibling}function AN(a){switch(a.tag){case 0:case 11:case 15:eu(a),a.flags&2048&&_i(9,a,a.return);break;case 3:eu(a);break;case 12:eu(a);break;case 22:var s=a.stateNode;a.memoizedState!==null&&s._visibility&2&&(a.return===null||a.return.tag!==13)?(s._visibility&=-3,Ud(a)):eu(a);break;default:eu(a)}}function Ud(a){var s=a.deletions;if((a.flags&16)!==0){if(s!==null)for(var f=0;f<s.length;f++){var m=s[f];an=m,NN(m,a)}EN(a)}for(a=a.child;a!==null;){switch(s=a,s.tag){case 0:case 11:case 15:_i(8,s,s.return),Ud(s);break;case 22:f=s.stateNode,f._visibility&2&&(f._visibility&=-3,Ud(s));break;default:Ud(s)}a=a.sibling}}function NN(a,s){for(;an!==null;){var f=an;switch(f.tag){case 0:case 11:case 15:_i(8,f,s);break;case 23:case 22:if(f.memoizedState!==null&&f.memoizedState.cachePool!==null){var m=f.memoizedState.cachePool.pool;m!=null&&m.refCount++}break;case 24:Ic(f.memoizedState.cache)}if(m=f.child,m!==null)m.return=f,an=m;else e:for(f=a;an!==null;){m=an;var y=m.sibling,S=m.return;if(yN(m),m===f){an=null;break e}if(y!==null){y.return=S,an=y;break e}an=S}}}var Sq={getCacheForType:function(a){var s=fn(qt),f=s.data.get(a);return f===void 0&&(f=a(),s.data.set(a,f)),f},cacheSignal:function(){return fn(qt).controller.signal}},jq=typeof WeakMap=="function"?WeakMap:Map,st=0,xt=null,Ke=null,Je=0,ft=0,Xn=null,Ei=!1,Vs=!1,Sy=!1,La=0,Pt=0,Ai=0,Ro=0,jy=0,Qn=0,Ys=0,tu=null,Ln=null,Oy=!1,Hd=0,CN=0,Fd=1/0,Gd=null,Ni=null,Wt=0,Ci=null,Ws=null,za=0,_y=0,Ey=null,TN=null,nu=0,Ay=null;function Zn(){return(st&2)!==0&&Je!==0?Je&-Je:k.T!==null?Dy():Yv()}function MN(){if(Qn===0)if((Je&536870912)===0||tt){var a=vs;vs<<=1,(vs&3932160)===0&&(vs=262144),Qn=a}else Qn=536870912;return a=Wn.current,a!==null&&(a.flags|=32),Qn}function zn(a,s,f){(a===xt&&(ft===2||ft===9)||a.cancelPendingCommit!==null)&&(Ks(a,0),Ti(a,Je,Qn,!1)),Rt(a,f),((st&2)===0||a!==xt)&&(a===xt&&((st&2)===0&&(Ro|=f),Pt===4&&Ti(a,Je,Qn,!1)),aa(a))}function RN(a,s,f){if((st&6)!==0)throw Error(r(327));var m=!f&&(s&127)===0&&(s&a.expiredLanes)===0||At(a,s),y=m?Eq(a,s):Cy(a,s,!0),S=m;do{if(y===0){Vs&&!m&&Ti(a,s,0,!1);break}else{if(f=a.current.alternate,S&&!Oq(f)){y=Cy(a,s,!1),S=!1;continue}if(y===2){if(S=s,a.errorRecoveryDisabledLanes&S)var T=0;else T=a.pendingLanes&-536870913,T=T!==0?T:T&536870912?536870912:0;if(T!==0){s=T;e:{var P=a;y=tu;var G=P.current.memoizedState.isDehydrated;if(G&&(Ks(P,T).flags|=256),T=Cy(P,T,!1),T!==2){if(Sy&&!G){P.errorRecoveryDisabledLanes|=S,Ro|=S,y=4;break e}S=Ln,Ln=y,S!==null&&(Ln===null?Ln=S:Ln.push.apply(Ln,S))}y=T}if(S=!1,y!==2)continue}}if(y===1){Ks(a,0),Ti(a,s,0,!0);break}e:{switch(m=a,S=y,S){case 0:case 1:throw Error(r(345));case 4:if((s&4194048)!==s)break;case 6:Ti(m,s,Qn,!Ei);break e;case 2:Ln=null;break;case 3:case 5:break;default:throw Error(r(329))}if((s&62914560)===s&&(y=Hd+300-tn(),10<y)){if(Ti(m,s,Qn,!Ei),$e(m,0,!0)!==0)break e;za=s,m.timeoutHandle=c2(DN.bind(null,m,f,Ln,Gd,Oy,s,Qn,Ro,Ys,Ei,S,"Throttled",-0,0),y);break e}DN(m,f,Ln,Gd,Oy,s,Qn,Ro,Ys,Ei,S,null,-0,0)}}break}while(!0);aa(a)}function DN(a,s,f,m,y,S,T,P,G,te,ce,he,ae,se){if(a.timeoutHandle=-1,he=s.subtreeFlags,he&8192||(he&16785408)===16785408){he={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Oa},_N(s,S,he);var Se=(S&62914560)===S?Hd-tn():(S&4194048)===S?CN-tn():0;if(Se=lU(he,Se),Se!==null){za=S,a.cancelPendingCommit=Se(qN.bind(null,a,s,S,f,m,y,T,P,G,ce,he,null,ae,se)),Ti(a,S,T,!te);return}}qN(a,s,S,f,m,y,T,P,G)}function Oq(a){for(var s=a;;){var f=s.tag;if((f===0||f===11||f===15)&&s.flags&16384&&(f=s.updateQueue,f!==null&&(f=f.stores,f!==null)))for(var m=0;m<f.length;m++){var y=f[m],S=y.getSnapshot;y=y.value;try{if(!Vn(S(),y))return!1}catch{return!1}}if(f=s.child,s.subtreeFlags&16384&&f!==null)f.return=s,s=f;else{if(s===a)break;for(;s.sibling===null;){if(s.return===null||s.return===a)return!0;s=s.return}s.sibling.return=s.return,s=s.sibling}}return!0}function Ti(a,s,f,m){s&=~jy,s&=~Ro,a.suspendedLanes|=s,a.pingedLanes&=~s,m&&(a.warmLanes|=s),m=a.expirationTimes;for(var y=s;0<y;){var S=31-gn(y),T=1<<S;m[S]=-1,y&=~T}f!==0&&po(a,f,s)}function Vd(){return(st&6)===0?(ru(0),!1):!0}function Ny(){if(Ke!==null){if(ft===0)var a=Ke.return;else a=Ke,Na=jo=null,Fg(a),zs=null,zc=0,a=Ke;for(;a!==null;)uN(a.alternate,a),a=a.return;Ke=null}}function Ks(a,s){var f=a.timeoutHandle;f!==-1&&(a.timeoutHandle=-1,Fq(f)),f=a.cancelPendingCommit,f!==null&&(a.cancelPendingCommit=null,f()),za=0,Ny(),xt=a,Ke=f=Ea(a.current,null),Je=s,ft=0,Xn=null,Ei=!1,Vs=At(a,s),Sy=!1,Ys=Qn=jy=Ro=Ai=Pt=0,Ln=tu=null,Oy=!1,(s&8)!==0&&(s|=s&32);var m=a.entangledLanes;if(m!==0)for(a=a.entanglements,m&=s;0<m;){var y=31-gn(m),S=1<<y;s|=a[y],m&=~S}return La=s,hd(),f}function PN(a,s){qe=null,k.H=Yc,s===Ls||s===wd?(s=XE(),ft=3):s===Rg?(s=XE(),ft=4):ft=s===oy?8:s!==null&&typeof s=="object"&&typeof s.then=="function"?6:1,Xn=s,Ke===null&&(Pt=1,kd(a,pr(s,a.current)))}function kN(){var a=Wn.current;return a===null?!0:(Je&4194048)===Je?br===null:(Je&62914560)===Je||(Je&536870912)!==0?a===br:!1}function $N(){var a=k.H;return k.H=Yc,a===null?Yc:a}function IN(){var a=k.A;return k.A=Sq,a}function Yd(){Pt=4,Ei||(Je&4194048)!==Je&&Wn.current!==null||(Vs=!0),(Ai&134217727)===0&&(Ro&134217727)===0||xt===null||Ti(xt,Je,Qn,!1)}function Cy(a,s,f){var m=st;st|=2;var y=$N(),S=IN();(xt!==a||Je!==s)&&(Gd=null,Ks(a,s)),s=!1;var T=Pt;e:do try{if(ft!==0&&Ke!==null){var P=Ke,G=Xn;switch(ft){case 8:Ny(),T=6;break e;case 3:case 2:case 9:case 6:Wn.current===null&&(s=!0);var te=ft;if(ft=0,Xn=null,Xs(a,P,G,te),f&&Vs){T=0;break e}break;default:te=ft,ft=0,Xn=null,Xs(a,P,G,te)}}_q(),T=Pt;break}catch(ce){PN(a,ce)}while(!0);return s&&a.shellSuspendCounter++,Na=jo=null,st=m,k.H=y,k.A=S,Ke===null&&(xt=null,Je=0,hd()),T}function _q(){for(;Ke!==null;)LN(Ke)}function Eq(a,s){var f=st;st|=2;var m=$N(),y=IN();xt!==a||Je!==s?(Gd=null,Fd=tn()+500,Ks(a,s)):Vs=At(a,s);e:do try{if(ft!==0&&Ke!==null){s=Ke;var S=Xn;t:switch(ft){case 1:ft=0,Xn=null,Xs(a,s,S,1);break;case 2:case 9:if(WE(S)){ft=0,Xn=null,zN(s);break}s=function(){ft!==2&&ft!==9||xt!==a||(ft=7),aa(a)},S.then(s,s);break e;case 3:ft=7;break e;case 4:ft=5;break e;case 7:WE(S)?(ft=0,Xn=null,zN(s)):(ft=0,Xn=null,Xs(a,s,S,7));break;case 5:var T=null;switch(Ke.tag){case 26:T=Ke.memoizedState;case 5:case 27:var P=Ke;if(T?O2(T):P.stateNode.complete){ft=0,Xn=null;var G=P.sibling;if(G!==null)Ke=G;else{var te=P.return;te!==null?(Ke=te,Wd(te)):Ke=null}break t}}ft=0,Xn=null,Xs(a,s,S,5);break;case 6:ft=0,Xn=null,Xs(a,s,S,6);break;case 8:Ny(),Pt=6;break e;default:throw Error(r(462))}}Aq();break}catch(ce){PN(a,ce)}while(!0);return Na=jo=null,k.H=m,k.A=y,st=f,Ke!==null?0:(xt=null,Je=0,hd(),Pt)}function Aq(){for(;Ke!==null&&!Mt();)LN(Ke)}function LN(a){var s=lN(a.alternate,a,La);a.memoizedProps=a.pendingProps,s===null?Wd(a):Ke=s}function zN(a){var s=a,f=s.alternate;switch(s.tag){case 15:case 0:s=nN(f,s,s.pendingProps,s.type,void 0,Je);break;case 11:s=nN(f,s,s.pendingProps,s.type.render,s.ref,Je);break;case 5:Fg(s);default:uN(f,s),s=Ke=IE(s,La),s=lN(f,s,La)}a.memoizedProps=a.pendingProps,s===null?Wd(a):Ke=s}function Xs(a,s,f,m){Na=jo=null,Fg(s),zs=null,zc=0;var y=s.return;try{if(pq(a,y,s,f,Je)){Pt=1,kd(a,pr(f,a.current)),Ke=null;return}}catch(S){if(y!==null)throw Ke=y,S;Pt=1,kd(a,pr(f,a.current)),Ke=null;return}s.flags&32768?(tt||m===1?a=!0:Vs||(Je&536870912)!==0?a=!1:(Ei=a=!0,(m===2||m===9||m===3||m===6)&&(m=Wn.current,m!==null&&m.tag===13&&(m.flags|=16384))),BN(s,a)):Wd(s)}function Wd(a){var s=a;do{if((s.flags&32768)!==0){BN(s,Ei);return}a=s.return;var f=yq(s.alternate,s,La);if(f!==null){Ke=f;return}if(s=s.sibling,s!==null){Ke=s;return}Ke=s=a}while(s!==null);Pt===0&&(Pt=5)}function BN(a,s){do{var f=bq(a.alternate,a);if(f!==null){f.flags&=32767,Ke=f;return}if(f=a.return,f!==null&&(f.flags|=32768,f.subtreeFlags=0,f.deletions=null),!s&&(a=a.sibling,a!==null)){Ke=a;return}Ke=a=f}while(a!==null);Pt=6,Ke=null}function qN(a,s,f,m,y,S,T,P,G){a.cancelPendingCommit=null;do Kd();while(Wt!==0);if((st&6)!==0)throw Error(r(327));if(s!==null){if(s===a.current)throw Error(r(177));if(S=s.lanes|s.childLanes,S|=gg,Tn(a,f,S,T,P,G),a===xt&&(Ke=xt=null,Je=0),Ws=s,Ci=a,za=f,_y=S,Ey=y,TN=m,(s.subtreeFlags&10256)!==0||(s.flags&10256)!==0?(a.callbackNode=null,a.callbackPriority=0,Mq(fo,function(){return VN(),null})):(a.callbackNode=null,a.callbackPriority=0),m=(s.flags&13878)!==0,(s.subtreeFlags&13878)!==0||m){m=k.T,k.T=null,y=H.p,H.p=2,T=st,st|=4;try{xq(a,s,f)}finally{st=T,H.p=y,k.T=m}}Wt=1,UN(),HN(),FN()}}function UN(){if(Wt===1){Wt=0;var a=Ci,s=Ws,f=(s.flags&13878)!==0;if((s.subtreeFlags&13878)!==0||f){f=k.T,k.T=null;var m=H.p;H.p=2;var y=st;st|=4;try{SN(s,a);var S=qy,T=NE(a.containerInfo),P=S.focusedElem,G=S.selectionRange;if(T!==P&&P&&P.ownerDocument&&AE(P.ownerDocument.documentElement,P)){if(G!==null&&dg(P)){var te=G.start,ce=G.end;if(ce===void 0&&(ce=te),"selectionStart"in P)P.selectionStart=te,P.selectionEnd=Math.min(ce,P.value.length);else{var he=P.ownerDocument||document,ae=he&&he.defaultView||window;if(ae.getSelection){var se=ae.getSelection(),Se=P.textContent.length,Me=Math.min(G.start,Se),gt=G.end===void 0?Me:Math.min(G.end,Se);!se.extend&&Me>gt&&(T=gt,gt=Me,Me=T);var J=EE(P,Me),K=EE(P,gt);if(J&&K&&(se.rangeCount!==1||se.anchorNode!==J.node||se.anchorOffset!==J.offset||se.focusNode!==K.node||se.focusOffset!==K.offset)){var ee=he.createRange();ee.setStart(J.node,J.offset),se.removeAllRanges(),Me>gt?(se.addRange(ee),se.extend(K.node,K.offset)):(ee.setEnd(K.node,K.offset),se.addRange(ee))}}}}for(he=[],se=P;se=se.parentNode;)se.nodeType===1&&he.push({element:se,left:se.scrollLeft,top:se.scrollTop});for(typeof P.focus=="function"&&P.focus(),P=0;P<he.length;P++){var de=he[P];de.element.scrollLeft=de.left,de.element.scrollTop=de.top}}sh=!!By,qy=By=null}finally{st=y,H.p=m,k.T=f}}a.current=s,Wt=2}}function HN(){if(Wt===2){Wt=0;var a=Ci,s=Ws,f=(s.flags&8772)!==0;if((s.subtreeFlags&8772)!==0||f){f=k.T,k.T=null;var m=H.p;H.p=2;var y=st;st|=4;try{gN(a,s.alternate,s)}finally{st=y,H.p=m,k.T=f}}Wt=3}}function FN(){if(Wt===4||Wt===3){Wt=0,fr();var a=Ci,s=Ws,f=za,m=TN;(s.subtreeFlags&10256)!==0||(s.flags&10256)!==0?Wt=5:(Wt=0,Ws=Ci=null,GN(a,a.pendingLanes));var y=a.pendingLanes;if(y===0&&(Ni=null),$r(f),s=s.stateNode,On&&typeof On.onCommitFiberRoot=="function")try{On.onCommitFiberRoot(ho,s,void 0,(s.current.flags&128)===128)}catch{}if(m!==null){s=k.T,y=H.p,H.p=2,k.T=null;try{for(var S=a.onRecoverableError,T=0;T<m.length;T++){var P=m[T];S(P.value,{componentStack:P.stack})}}finally{k.T=s,H.p=y}}(za&3)!==0&&Kd(),aa(a),y=a.pendingLanes,(f&261930)!==0&&(y&42)!==0?a===Ay?nu++:(nu=0,Ay=a):nu=0,ru(0)}}function GN(a,s){(a.pooledCacheLanes&=s)===0&&(s=a.pooledCache,s!=null&&(a.pooledCache=null,Ic(s)))}function Kd(){return UN(),HN(),FN(),VN()}function VN(){if(Wt!==5)return!1;var a=Ci,s=_y;_y=0;var f=$r(za),m=k.T,y=H.p;try{H.p=32>f?32:f,k.T=null,f=Ey,Ey=null;var S=Ci,T=za;if(Wt=0,Ws=Ci=null,za=0,(st&6)!==0)throw Error(r(331));var P=st;if(st|=4,AN(S.current),ON(S,S.current,T,f),st=P,ru(0,!1),On&&typeof On.onPostCommitFiberRoot=="function")try{On.onPostCommitFiberRoot(ho,S)}catch{}return!0}finally{H.p=y,k.T=m,GN(a,s)}}function YN(a,s,f){s=pr(f,s),s=iy(a.stateNode,s,2),a=Si(a,s,2),a!==null&&(Rt(a,2),aa(a))}function dt(a,s,f){if(a.tag===3)YN(a,a,f);else for(;s!==null;){if(s.tag===3){YN(s,a,f);break}else if(s.tag===1){var m=s.stateNode;if(typeof s.type.getDerivedStateFromError=="function"||typeof m.componentDidCatch=="function"&&(Ni===null||!Ni.has(m))){a=pr(f,a),f=WA(2),m=Si(s,f,2),m!==null&&(KA(f,m,s,a),Rt(m,2),aa(m));break}}s=s.return}}function Ty(a,s,f){var m=a.pingCache;if(m===null){m=a.pingCache=new jq;var y=new Set;m.set(s,y)}else y=m.get(s),y===void 0&&(y=new Set,m.set(s,y));y.has(f)||(Sy=!0,y.add(f),a=Nq.bind(null,a,s,f),s.then(a,a))}function Nq(a,s,f){var m=a.pingCache;m!==null&&m.delete(s),a.pingedLanes|=a.suspendedLanes&f,a.warmLanes&=~f,xt===a&&(Je&f)===f&&(Pt===4||Pt===3&&(Je&62914560)===Je&&300>tn()-Hd?(st&2)===0&&Ks(a,0):jy|=f,Ys===Je&&(Ys=0)),aa(a)}function WN(a,s){s===0&&(s=yn()),a=xo(a,s),a!==null&&(Rt(a,s),aa(a))}function Cq(a){var s=a.memoizedState,f=0;s!==null&&(f=s.retryLane),WN(a,f)}function Tq(a,s){var f=0;switch(a.tag){case 31:case 13:var m=a.stateNode,y=a.memoizedState;y!==null&&(f=y.retryLane);break;case 19:m=a.stateNode;break;case 22:m=a.stateNode._retryCache;break;default:throw Error(r(314))}m!==null&&m.delete(s),WN(a,f)}function Mq(a,s){return ur(a,s)}var Xd=null,Qs=null,My=!1,Qd=!1,Ry=!1,Mi=0;function aa(a){a!==Qs&&a.next===null&&(Qs===null?Xd=Qs=a:Qs=Qs.next=a),Qd=!0,My||(My=!0,Dq())}function ru(a,s){if(!Ry&&Qd){Ry=!0;do for(var f=!1,m=Xd;m!==null;){if(a!==0){var y=m.pendingLanes;if(y===0)var S=0;else{var T=m.suspendedLanes,P=m.pingedLanes;S=(1<<31-gn(42|a)+1)-1,S&=y&~(T&~P),S=S&201326741?S&201326741|1:S?S|2:0}S!==0&&(f=!0,ZN(m,S))}else S=Je,S=$e(m,m===xt?S:0,m.cancelPendingCommit!==null||m.timeoutHandle!==-1),(S&3)===0||At(m,S)||(f=!0,ZN(m,S));m=m.next}while(f);Ry=!1}}function Rq(){KN()}function KN(){Qd=My=!1;var a=0;Mi!==0&&Hq()&&(a=Mi);for(var s=tn(),f=null,m=Xd;m!==null;){var y=m.next,S=XN(m,s);S===0?(m.next=null,f===null?Xd=y:f.next=y,y===null&&(Qs=f)):(f=m,(a!==0||(S&3)!==0)&&(Qd=!0)),m=y}Wt!==0&&Wt!==5||ru(a),Mi!==0&&(Mi=0)}function XN(a,s){for(var f=a.suspendedLanes,m=a.pingedLanes,y=a.expirationTimes,S=a.pendingLanes&-62914561;0<S;){var T=31-gn(S),P=1<<T,G=y[T];G===-1?((P&f)===0||(P&m)!==0)&&(y[T]=nn(P,s)):G<=s&&(a.expiredLanes|=P),S&=~P}if(s=xt,f=Je,f=$e(a,a===s?f:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),m=a.callbackNode,f===0||a===s&&(ft===2||ft===9)||a.cancelPendingCommit!==null)return m!==null&&m!==null&&Gn(m),a.callbackNode=null,a.callbackPriority=0;if((f&3)===0||At(a,f)){if(s=f&-f,s===a.callbackPriority)return s;switch(m!==null&&Gn(m),$r(f)){case 2:case 8:f=ed;break;case 32:f=fo;break;case 268435456:f=Sa;break;default:f=fo}return m=QN.bind(null,a),f=ur(f,m),a.callbackPriority=s,a.callbackNode=f,s}return m!==null&&m!==null&&Gn(m),a.callbackPriority=2,a.callbackNode=null,2}function QN(a,s){if(Wt!==0&&Wt!==5)return a.callbackNode=null,a.callbackPriority=0,null;var f=a.callbackNode;if(Kd()&&a.callbackNode!==f)return null;var m=Je;return m=$e(a,a===xt?m:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),m===0?null:(RN(a,m,s),XN(a,tn()),a.callbackNode!=null&&a.callbackNode===f?QN.bind(null,a):null)}function ZN(a,s){if(Kd())return null;RN(a,s,!0)}function Dq(){Gq(function(){(st&6)!==0?ur(uo,Rq):KN()})}function Dy(){if(Mi===0){var a=$s;a===0&&(a=ps,ps<<=1,(ps&261888)===0&&(ps=256)),Mi=a}return Mi}function JN(a){return a==null||typeof a=="symbol"||typeof a=="boolean"?null:typeof a=="function"?a:id(""+a)}function e2(a,s){var f=s.ownerDocument.createElement("input");return f.name=s.name,f.value=s.value,a.id&&f.setAttribute("form",a.id),s.parentNode.insertBefore(f,s),a=new FormData(a),f.parentNode.removeChild(f),a}function Pq(a,s,f,m,y){if(s==="submit"&&f&&f.stateNode===y){var S=JN((y[Dn]||null).action),T=m.submitter;T&&(s=(s=T[Dn]||null)?JN(s.formAction):T.getAttribute("formAction"),s!==null&&(S=s,T=null));var P=new cd("action","action",null,m,y);a.push({event:P,listeners:[{instance:null,listener:function(){if(m.defaultPrevented){if(Mi!==0){var G=T?e2(y,T):new FormData(y);Jg(f,{pending:!0,data:G,method:y.method,action:S},null,G)}}else typeof S=="function"&&(P.preventDefault(),G=T?e2(y,T):new FormData(y),Jg(f,{pending:!0,data:G,method:y.method,action:S},S,G))},currentTarget:y}]})}}for(var Py=0;Py<vg.length;Py++){var ky=vg[Py],kq=ky.toLowerCase(),$q=ky[0].toUpperCase()+ky.slice(1);Ir(kq,"on"+$q)}Ir(ME,"onAnimationEnd"),Ir(RE,"onAnimationIteration"),Ir(DE,"onAnimationStart"),Ir("dblclick","onDoubleClick"),Ir("focusin","onFocus"),Ir("focusout","onBlur"),Ir(Z8,"onTransitionRun"),Ir(J8,"onTransitionStart"),Ir(eq,"onTransitionCancel"),Ir(PE,"onTransitionEnd"),Ss("onMouseEnter",["mouseout","mouseover"]),Ss("onMouseLeave",["mouseout","mouseover"]),Ss("onPointerEnter",["pointerout","pointerover"]),Ss("onPointerLeave",["pointerout","pointerover"]),vo("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),vo("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),vo("onBeforeInput",["compositionend","keypress","textInput","paste"]),vo("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),vo("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),vo("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var au="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(" "),Iq=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(au));function t2(a,s){s=(s&4)!==0;for(var f=0;f<a.length;f++){var m=a[f],y=m.event;m=m.listeners;e:{var S=void 0;if(s)for(var T=m.length-1;0<=T;T--){var P=m[T],G=P.instance,te=P.currentTarget;if(P=P.listener,G!==S&&y.isPropagationStopped())break e;S=P,y.currentTarget=te;try{S(y)}catch(ce){dd(ce)}y.currentTarget=null,S=G}else for(T=0;T<m.length;T++){if(P=m[T],G=P.instance,te=P.currentTarget,P=P.listener,G!==S&&y.isPropagationStopped())break e;S=P,y.currentTarget=te;try{S(y)}catch(ce){dd(ce)}y.currentTarget=null,S=G}}}}function Xe(a,s){var f=s[Wv];f===void 0&&(f=s[Wv]=new Set);var m=a+"__bubble";f.has(m)||(n2(s,a,2,!1),f.add(m))}function $y(a,s,f){var m=0;s&&(m|=4),n2(f,a,m,s)}var Zd="_reactListening"+Math.random().toString(36).slice(2);function Iy(a){if(!a[Zd]){a[Zd]=!0,K_.forEach(function(f){f!=="selectionchange"&&(Iq.has(f)||$y(f,!1,a),$y(f,!0,a))});var s=a.nodeType===9?a:a.ownerDocument;s===null||s[Zd]||(s[Zd]=!0,$y("selectionchange",!1,s))}}function n2(a,s,f,m){switch(M2(s)){case 2:var y=fU;break;case 8:y=dU;break;default:y=Zy}f=y.bind(null,s,f,a),y=void 0,!rg||s!=="touchstart"&&s!=="touchmove"&&s!=="wheel"||(y=!0),m?y!==void 0?a.addEventListener(s,f,{capture:!0,passive:y}):a.addEventListener(s,f,!0):y!==void 0?a.addEventListener(s,f,{passive:y}):a.addEventListener(s,f,!1)}function Ly(a,s,f,m,y){var S=m;if((s&1)===0&&(s&2)===0&&m!==null)e:for(;;){if(m===null)return;var T=m.tag;if(T===3||T===4){var P=m.stateNode.containerInfo;if(P===y)break;if(T===4)for(T=m.return;T!==null;){var G=T.tag;if((G===3||G===4)&&T.stateNode.containerInfo===y)return;T=T.return}for(;P!==null;){if(T=bs(P),T===null)return;if(G=T.tag,G===5||G===6||G===26||G===27){m=S=T;continue e}P=P.parentNode}}m=m.return}sE(function(){var te=S,ce=tg(f),he=[];e:{var ae=kE.get(a);if(ae!==void 0){var se=cd,Se=a;switch(a){case"keypress":if(sd(f)===0)break e;case"keydown":case"keyup":se=T8;break;case"focusin":Se="focus",se=sg;break;case"focusout":Se="blur",se=sg;break;case"beforeblur":case"afterblur":se=sg;break;case"click":if(f.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":se=uE;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":se=y8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":se=D8;break;case ME:case RE:case DE:se=w8;break;case PE:se=k8;break;case"scroll":case"scrollend":se=v8;break;case"wheel":se=I8;break;case"copy":case"cut":case"paste":se=j8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":se=dE;break;case"toggle":case"beforetoggle":se=z8}var Me=(s&4)!==0,gt=!Me&&(a==="scroll"||a==="scrollend"),J=Me?ae!==null?ae+"Capture":null:ae;Me=[];for(var K=te,ee;K!==null;){var de=K;if(ee=de.stateNode,de=de.tag,de!==5&&de!==26&&de!==27||ee===null||J===null||(de=Ec(K,J),de!=null&&Me.push(iu(K,de,ee))),gt)break;K=K.return}0<Me.length&&(ae=new se(ae,Se,null,f,ce),he.push({event:ae,listeners:Me}))}}if((s&7)===0){e:{if(ae=a==="mouseover"||a==="pointerover",se=a==="mouseout"||a==="pointerout",ae&&f!==eg&&(Se=f.relatedTarget||f.fromElement)&&(bs(Se)||Se[ys]))break e;if((se||ae)&&(ae=ce.window===ce?ce:(ae=ce.ownerDocument)?ae.defaultView||ae.parentWindow:window,se?(Se=f.relatedTarget||f.toElement,se=te,Se=Se?bs(Se):null,Se!==null&&(gt=o(Se),Me=Se.tag,Se!==gt||Me!==5&&Me!==27&&Me!==6)&&(Se=null)):(se=null,Se=te),se!==Se)){if(Me=uE,de="onMouseLeave",J="onMouseEnter",K="mouse",(a==="pointerout"||a==="pointerover")&&(Me=dE,de="onPointerLeave",J="onPointerEnter",K="pointer"),gt=se==null?ae:_c(se),ee=Se==null?ae:_c(Se),ae=new Me(de,K+"leave",se,f,ce),ae.target=gt,ae.relatedTarget=ee,de=null,bs(ce)===te&&(Me=new Me(J,K+"enter",Se,f,ce),Me.target=ee,Me.relatedTarget=gt,de=Me),gt=de,se&&Se)t:{for(Me=Lq,J=se,K=Se,ee=0,de=J;de;de=Me(de))ee++;de=0;for(var Ae=K;Ae;Ae=Me(Ae))de++;for(;0<ee-de;)J=Me(J),ee--;for(;0<de-ee;)K=Me(K),de--;for(;ee--;){if(J===K||K!==null&&J===K.alternate){Me=J;break t}J=Me(J),K=Me(K)}Me=null}else Me=null;se!==null&&r2(he,ae,se,Me,!1),Se!==null&&gt!==null&&r2(he,gt,Se,Me,!0)}}e:{if(ae=te?_c(te):window,se=ae.nodeName&&ae.nodeName.toLowerCase(),se==="select"||se==="input"&&ae.type==="file")var at=xE;else if(yE(ae))if(wE)at=K8;else{at=Y8;var _e=V8}else se=ae.nodeName,!se||se.toLowerCase()!=="input"||ae.type!=="checkbox"&&ae.type!=="radio"?te&&Jv(te.elementType)&&(at=xE):at=W8;if(at&&(at=at(a,te))){bE(he,at,f,ce);break e}_e&&_e(a,ae,te),a==="focusout"&&te&&ae.type==="number"&&te.memoizedProps.value!=null&&Zv(ae,"number",ae.value)}switch(_e=te?_c(te):window,a){case"focusin":(yE(_e)||_e.contentEditable==="true")&&(Ns=_e,hg=te,Pc=null);break;case"focusout":Pc=hg=Ns=null;break;case"mousedown":mg=!0;break;case"contextmenu":case"mouseup":case"dragend":mg=!1,CE(he,f,ce);break;case"selectionchange":if(Q8)break;case"keydown":case"keyup":CE(he,f,ce)}var He;if(cg)e:{switch(a){case"compositionstart":var et="onCompositionStart";break e;case"compositionend":et="onCompositionEnd";break e;case"compositionupdate":et="onCompositionUpdate";break e}et=void 0}else As?vE(a,f)&&(et="onCompositionEnd"):a==="keydown"&&f.keyCode===229&&(et="onCompositionStart");et&&(hE&&f.locale!=="ko"&&(As||et!=="onCompositionStart"?et==="onCompositionEnd"&&As&&(He=lE()):(pi=ce,ag="value"in pi?pi.value:pi.textContent,As=!0)),_e=Jd(te,et),0<_e.length&&(et=new fE(et,a,null,f,ce),he.push({event:et,listeners:_e}),He?et.data=He:(He=gE(f),He!==null&&(et.data=He)))),(He=q8?U8(a,f):H8(a,f))&&(et=Jd(te,"onBeforeInput"),0<et.length&&(_e=new fE("onBeforeInput","beforeinput",null,f,ce),he.push({event:_e,listeners:et}),_e.data=He)),Pq(he,a,te,f,ce)}t2(he,s)})}function iu(a,s,f){return{instance:a,listener:s,currentTarget:f}}function Jd(a,s){for(var f=s+"Capture",m=[];a!==null;){var y=a,S=y.stateNode;if(y=y.tag,y!==5&&y!==26&&y!==27||S===null||(y=Ec(a,f),y!=null&&m.unshift(iu(a,y,S)),y=Ec(a,s),y!=null&&m.push(iu(a,y,S))),a.tag===3)return m;a=a.return}return[]}function Lq(a){if(a===null)return null;do a=a.return;while(a&&a.tag!==5&&a.tag!==27);return a||null}function r2(a,s,f,m,y){for(var S=s._reactName,T=[];f!==null&&f!==m;){var P=f,G=P.alternate,te=P.stateNode;if(P=P.tag,G!==null&&G===m)break;P!==5&&P!==26&&P!==27||te===null||(G=te,y?(te=Ec(f,S),te!=null&&T.unshift(iu(f,te,G))):y||(te=Ec(f,S),te!=null&&T.push(iu(f,te,G)))),f=f.return}T.length!==0&&a.push({event:s,listeners:T})}var zq=/\r\n?/g,Bq=/\u0000|\uFFFD/g;function a2(a){return(typeof a=="string"?a:""+a).replace(zq,`
49
+ `).replace(Bq,"")}function i2(a,s){return s=a2(s),a2(a)===s}function vt(a,s,f,m,y,S){switch(f){case"children":typeof m=="string"?s==="body"||s==="textarea"&&m===""||Os(a,m):(typeof m=="number"||typeof m=="bigint")&&s!=="body"&&Os(a,""+m);break;case"className":rd(a,"class",m);break;case"tabIndex":rd(a,"tabindex",m);break;case"dir":case"role":case"viewBox":case"width":case"height":rd(a,f,m);break;case"style":iE(a,m,S);break;case"data":if(s!=="object"){rd(a,"data",m);break}case"src":case"href":if(m===""&&(s!=="a"||f!=="href")){a.removeAttribute(f);break}if(m==null||typeof m=="function"||typeof m=="symbol"||typeof m=="boolean"){a.removeAttribute(f);break}m=id(""+m),a.setAttribute(f,m);break;case"action":case"formAction":if(typeof m=="function"){a.setAttribute(f,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof S=="function"&&(f==="formAction"?(s!=="input"&&vt(a,s,"name",y.name,y,null),vt(a,s,"formEncType",y.formEncType,y,null),vt(a,s,"formMethod",y.formMethod,y,null),vt(a,s,"formTarget",y.formTarget,y,null)):(vt(a,s,"encType",y.encType,y,null),vt(a,s,"method",y.method,y,null),vt(a,s,"target",y.target,y,null)));if(m==null||typeof m=="symbol"||typeof m=="boolean"){a.removeAttribute(f);break}m=id(""+m),a.setAttribute(f,m);break;case"onClick":m!=null&&(a.onclick=Oa);break;case"onScroll":m!=null&&Xe("scroll",a);break;case"onScrollEnd":m!=null&&Xe("scrollend",a);break;case"dangerouslySetInnerHTML":if(m!=null){if(typeof m!="object"||!("__html"in m))throw Error(r(61));if(f=m.__html,f!=null){if(y.children!=null)throw Error(r(60));a.innerHTML=f}}break;case"multiple":a.multiple=m&&typeof m!="function"&&typeof m!="symbol";break;case"muted":a.muted=m&&typeof m!="function"&&typeof m!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(m==null||typeof m=="function"||typeof m=="boolean"||typeof m=="symbol"){a.removeAttribute("xlink:href");break}f=id(""+m),a.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",f);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":m!=null&&typeof m!="function"&&typeof m!="symbol"?a.setAttribute(f,""+m):a.removeAttribute(f);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":m&&typeof m!="function"&&typeof m!="symbol"?a.setAttribute(f,""):a.removeAttribute(f);break;case"capture":case"download":m===!0?a.setAttribute(f,""):m!==!1&&m!=null&&typeof m!="function"&&typeof m!="symbol"?a.setAttribute(f,m):a.removeAttribute(f);break;case"cols":case"rows":case"size":case"span":m!=null&&typeof m!="function"&&typeof m!="symbol"&&!isNaN(m)&&1<=m?a.setAttribute(f,m):a.removeAttribute(f);break;case"rowSpan":case"start":m==null||typeof m=="function"||typeof m=="symbol"||isNaN(m)?a.removeAttribute(f):a.setAttribute(f,m);break;case"popover":Xe("beforetoggle",a),Xe("toggle",a),nd(a,"popover",m);break;case"xlinkActuate":ja(a,"http://www.w3.org/1999/xlink","xlink:actuate",m);break;case"xlinkArcrole":ja(a,"http://www.w3.org/1999/xlink","xlink:arcrole",m);break;case"xlinkRole":ja(a,"http://www.w3.org/1999/xlink","xlink:role",m);break;case"xlinkShow":ja(a,"http://www.w3.org/1999/xlink","xlink:show",m);break;case"xlinkTitle":ja(a,"http://www.w3.org/1999/xlink","xlink:title",m);break;case"xlinkType":ja(a,"http://www.w3.org/1999/xlink","xlink:type",m);break;case"xmlBase":ja(a,"http://www.w3.org/XML/1998/namespace","xml:base",m);break;case"xmlLang":ja(a,"http://www.w3.org/XML/1998/namespace","xml:lang",m);break;case"xmlSpace":ja(a,"http://www.w3.org/XML/1998/namespace","xml:space",m);break;case"is":nd(a,"is",m);break;case"innerText":case"textContent":break;default:(!(2<f.length)||f[0]!=="o"&&f[0]!=="O"||f[1]!=="n"&&f[1]!=="N")&&(f=m8.get(f)||f,nd(a,f,m))}}function zy(a,s,f,m,y,S){switch(f){case"style":iE(a,m,S);break;case"dangerouslySetInnerHTML":if(m!=null){if(typeof m!="object"||!("__html"in m))throw Error(r(61));if(f=m.__html,f!=null){if(y.children!=null)throw Error(r(60));a.innerHTML=f}}break;case"children":typeof m=="string"?Os(a,m):(typeof m=="number"||typeof m=="bigint")&&Os(a,""+m);break;case"onScroll":m!=null&&Xe("scroll",a);break;case"onScrollEnd":m!=null&&Xe("scrollend",a);break;case"onClick":m!=null&&(a.onclick=Oa);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!X_.hasOwnProperty(f))e:{if(f[0]==="o"&&f[1]==="n"&&(y=f.endsWith("Capture"),s=f.slice(2,y?f.length-7:void 0),S=a[Dn]||null,S=S!=null?S[f]:null,typeof S=="function"&&a.removeEventListener(s,S,y),typeof m=="function")){typeof S!="function"&&S!==null&&(f in a?a[f]=null:a.hasAttribute(f)&&a.removeAttribute(f)),a.addEventListener(s,m,y);break e}f in a?a[f]=m:m===!0?a.setAttribute(f,""):nd(a,f,m)}}}function hn(a,s,f){switch(s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Xe("error",a),Xe("load",a);var m=!1,y=!1,S;for(S in f)if(f.hasOwnProperty(S)){var T=f[S];if(T!=null)switch(S){case"src":m=!0;break;case"srcSet":y=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,s));default:vt(a,s,S,T,f,null)}}y&&vt(a,s,"srcSet",f.srcSet,f,null),m&&vt(a,s,"src",f.src,f,null);return;case"input":Xe("invalid",a);var P=S=T=y=null,G=null,te=null;for(m in f)if(f.hasOwnProperty(m)){var ce=f[m];if(ce!=null)switch(m){case"name":y=ce;break;case"type":T=ce;break;case"checked":G=ce;break;case"defaultChecked":te=ce;break;case"value":S=ce;break;case"defaultValue":P=ce;break;case"children":case"dangerouslySetInnerHTML":if(ce!=null)throw Error(r(137,s));break;default:vt(a,s,m,ce,f,null)}}tE(a,S,P,G,te,T,y,!1);return;case"select":Xe("invalid",a),m=T=S=null;for(y in f)if(f.hasOwnProperty(y)&&(P=f[y],P!=null))switch(y){case"value":S=P;break;case"defaultValue":T=P;break;case"multiple":m=P;default:vt(a,s,y,P,f,null)}s=S,f=T,a.multiple=!!m,s!=null?js(a,!!m,s,!1):f!=null&&js(a,!!m,f,!0);return;case"textarea":Xe("invalid",a),S=y=m=null;for(T in f)if(f.hasOwnProperty(T)&&(P=f[T],P!=null))switch(T){case"value":m=P;break;case"defaultValue":y=P;break;case"children":S=P;break;case"dangerouslySetInnerHTML":if(P!=null)throw Error(r(91));break;default:vt(a,s,T,P,f,null)}rE(a,m,y,S);return;case"option":for(G in f)if(f.hasOwnProperty(G)&&(m=f[G],m!=null))switch(G){case"selected":a.selected=m&&typeof m!="function"&&typeof m!="symbol";break;default:vt(a,s,G,m,f,null)}return;case"dialog":Xe("beforetoggle",a),Xe("toggle",a),Xe("cancel",a),Xe("close",a);break;case"iframe":case"object":Xe("load",a);break;case"video":case"audio":for(m=0;m<au.length;m++)Xe(au[m],a);break;case"image":Xe("error",a),Xe("load",a);break;case"details":Xe("toggle",a);break;case"embed":case"source":case"link":Xe("error",a),Xe("load",a);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(te in f)if(f.hasOwnProperty(te)&&(m=f[te],m!=null))switch(te){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,s));default:vt(a,s,te,m,f,null)}return;default:if(Jv(s)){for(ce in f)f.hasOwnProperty(ce)&&(m=f[ce],m!==void 0&&zy(a,s,ce,m,f,void 0));return}}for(P in f)f.hasOwnProperty(P)&&(m=f[P],m!=null&&vt(a,s,P,m,f,null))}function qq(a,s,f,m){switch(s){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var y=null,S=null,T=null,P=null,G=null,te=null,ce=null;for(se in f){var he=f[se];if(f.hasOwnProperty(se)&&he!=null)switch(se){case"checked":break;case"value":break;case"defaultValue":G=he;default:m.hasOwnProperty(se)||vt(a,s,se,null,m,he)}}for(var ae in m){var se=m[ae];if(he=f[ae],m.hasOwnProperty(ae)&&(se!=null||he!=null))switch(ae){case"type":S=se;break;case"name":y=se;break;case"checked":te=se;break;case"defaultChecked":ce=se;break;case"value":T=se;break;case"defaultValue":P=se;break;case"children":case"dangerouslySetInnerHTML":if(se!=null)throw Error(r(137,s));break;default:se!==he&&vt(a,s,ae,se,m,he)}}Qv(a,T,P,G,te,ce,S,y);return;case"select":se=T=P=ae=null;for(S in f)if(G=f[S],f.hasOwnProperty(S)&&G!=null)switch(S){case"value":break;case"multiple":se=G;default:m.hasOwnProperty(S)||vt(a,s,S,null,m,G)}for(y in m)if(S=m[y],G=f[y],m.hasOwnProperty(y)&&(S!=null||G!=null))switch(y){case"value":ae=S;break;case"defaultValue":P=S;break;case"multiple":T=S;default:S!==G&&vt(a,s,y,S,m,G)}s=P,f=T,m=se,ae!=null?js(a,!!f,ae,!1):!!m!=!!f&&(s!=null?js(a,!!f,s,!0):js(a,!!f,f?[]:"",!1));return;case"textarea":se=ae=null;for(P in f)if(y=f[P],f.hasOwnProperty(P)&&y!=null&&!m.hasOwnProperty(P))switch(P){case"value":break;case"children":break;default:vt(a,s,P,null,m,y)}for(T in m)if(y=m[T],S=f[T],m.hasOwnProperty(T)&&(y!=null||S!=null))switch(T){case"value":ae=y;break;case"defaultValue":se=y;break;case"children":break;case"dangerouslySetInnerHTML":if(y!=null)throw Error(r(91));break;default:y!==S&&vt(a,s,T,y,m,S)}nE(a,ae,se);return;case"option":for(var Se in f)if(ae=f[Se],f.hasOwnProperty(Se)&&ae!=null&&!m.hasOwnProperty(Se))switch(Se){case"selected":a.selected=!1;break;default:vt(a,s,Se,null,m,ae)}for(G in m)if(ae=m[G],se=f[G],m.hasOwnProperty(G)&&ae!==se&&(ae!=null||se!=null))switch(G){case"selected":a.selected=ae&&typeof ae!="function"&&typeof ae!="symbol";break;default:vt(a,s,G,ae,m,se)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Me in f)ae=f[Me],f.hasOwnProperty(Me)&&ae!=null&&!m.hasOwnProperty(Me)&&vt(a,s,Me,null,m,ae);for(te in m)if(ae=m[te],se=f[te],m.hasOwnProperty(te)&&ae!==se&&(ae!=null||se!=null))switch(te){case"children":case"dangerouslySetInnerHTML":if(ae!=null)throw Error(r(137,s));break;default:vt(a,s,te,ae,m,se)}return;default:if(Jv(s)){for(var gt in f)ae=f[gt],f.hasOwnProperty(gt)&&ae!==void 0&&!m.hasOwnProperty(gt)&&zy(a,s,gt,void 0,m,ae);for(ce in m)ae=m[ce],se=f[ce],!m.hasOwnProperty(ce)||ae===se||ae===void 0&&se===void 0||zy(a,s,ce,ae,m,se);return}}for(var J in f)ae=f[J],f.hasOwnProperty(J)&&ae!=null&&!m.hasOwnProperty(J)&&vt(a,s,J,null,m,ae);for(he in m)ae=m[he],se=f[he],!m.hasOwnProperty(he)||ae===se||ae==null&&se==null||vt(a,s,he,ae,m,se)}function o2(a){switch(a){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function Uq(){if(typeof performance.getEntriesByType=="function"){for(var a=0,s=0,f=performance.getEntriesByType("resource"),m=0;m<f.length;m++){var y=f[m],S=y.transferSize,T=y.initiatorType,P=y.duration;if(S&&P&&o2(T)){for(T=0,P=y.responseEnd,m+=1;m<f.length;m++){var G=f[m],te=G.startTime;if(te>P)break;var ce=G.transferSize,he=G.initiatorType;ce&&o2(he)&&(G=G.responseEnd,T+=ce*(G<P?1:(P-te)/(G-te)))}if(--m,s+=8*(S+T)/(y.duration/1e3),a++,10<a)break}}if(0<a)return s/a/1e6}return navigator.connection&&(a=navigator.connection.downlink,typeof a=="number")?a:5}var By=null,qy=null;function eh(a){return a.nodeType===9?a:a.ownerDocument}function s2(a){switch(a){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function l2(a,s){if(a===0)switch(s){case"svg":return 1;case"math":return 2;default:return 0}return a===1&&s==="foreignObject"?0:a}function Uy(a,s){return a==="textarea"||a==="noscript"||typeof s.children=="string"||typeof s.children=="number"||typeof s.children=="bigint"||typeof s.dangerouslySetInnerHTML=="object"&&s.dangerouslySetInnerHTML!==null&&s.dangerouslySetInnerHTML.__html!=null}var Hy=null;function Hq(){var a=window.event;return a&&a.type==="popstate"?a===Hy?!1:(Hy=a,!0):(Hy=null,!1)}var c2=typeof setTimeout=="function"?setTimeout:void 0,Fq=typeof clearTimeout=="function"?clearTimeout:void 0,u2=typeof Promise=="function"?Promise:void 0,Gq=typeof queueMicrotask=="function"?queueMicrotask:typeof u2<"u"?function(a){return u2.resolve(null).then(a).catch(Vq)}:c2;function Vq(a){setTimeout(function(){throw a})}function Ri(a){return a==="head"}function f2(a,s){var f=s,m=0;do{var y=f.nextSibling;if(a.removeChild(f),y&&y.nodeType===8)if(f=y.data,f==="/$"||f==="/&"){if(m===0){a.removeChild(y),tl(s);return}m--}else if(f==="$"||f==="$?"||f==="$~"||f==="$!"||f==="&")m++;else if(f==="html")ou(a.ownerDocument.documentElement);else if(f==="head"){f=a.ownerDocument.head,ou(f);for(var S=f.firstChild;S;){var T=S.nextSibling,P=S.nodeName;S[Oc]||P==="SCRIPT"||P==="STYLE"||P==="LINK"&&S.rel.toLowerCase()==="stylesheet"||f.removeChild(S),S=T}}else f==="body"&&ou(a.ownerDocument.body);f=y}while(f);tl(s)}function d2(a,s){var f=a;a=0;do{var m=f.nextSibling;if(f.nodeType===1?s?(f._stashedDisplay=f.style.display,f.style.display="none"):(f.style.display=f._stashedDisplay||"",f.getAttribute("style")===""&&f.removeAttribute("style")):f.nodeType===3&&(s?(f._stashedText=f.nodeValue,f.nodeValue=""):f.nodeValue=f._stashedText||""),m&&m.nodeType===8)if(f=m.data,f==="/$"){if(a===0)break;a--}else f!=="$"&&f!=="$?"&&f!=="$~"&&f!=="$!"||a++;f=m}while(f)}function Fy(a){var s=a.firstChild;for(s&&s.nodeType===10&&(s=s.nextSibling);s;){var f=s;switch(s=s.nextSibling,f.nodeName){case"HTML":case"HEAD":case"BODY":Fy(f),Kv(f);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(f.rel.toLowerCase()==="stylesheet")continue}a.removeChild(f)}}function Yq(a,s,f,m){for(;a.nodeType===1;){var y=f;if(a.nodeName.toLowerCase()!==s.toLowerCase()){if(!m&&(a.nodeName!=="INPUT"||a.type!=="hidden"))break}else if(m){if(!a[Oc])switch(s){case"meta":if(!a.hasAttribute("itemprop"))break;return a;case"link":if(S=a.getAttribute("rel"),S==="stylesheet"&&a.hasAttribute("data-precedence"))break;if(S!==y.rel||a.getAttribute("href")!==(y.href==null||y.href===""?null:y.href)||a.getAttribute("crossorigin")!==(y.crossOrigin==null?null:y.crossOrigin)||a.getAttribute("title")!==(y.title==null?null:y.title))break;return a;case"style":if(a.hasAttribute("data-precedence"))break;return a;case"script":if(S=a.getAttribute("src"),(S!==(y.src==null?null:y.src)||a.getAttribute("type")!==(y.type==null?null:y.type)||a.getAttribute("crossorigin")!==(y.crossOrigin==null?null:y.crossOrigin))&&S&&a.hasAttribute("async")&&!a.hasAttribute("itemprop"))break;return a;default:return a}}else if(s==="input"&&a.type==="hidden"){var S=y.name==null?null:""+y.name;if(y.type==="hidden"&&a.getAttribute("name")===S)return a}else return a;if(a=xr(a.nextSibling),a===null)break}return null}function Wq(a,s,f){if(s==="")return null;for(;a.nodeType!==3;)if((a.nodeType!==1||a.nodeName!=="INPUT"||a.type!=="hidden")&&!f||(a=xr(a.nextSibling),a===null))return null;return a}function h2(a,s){for(;a.nodeType!==8;)if((a.nodeType!==1||a.nodeName!=="INPUT"||a.type!=="hidden")&&!s||(a=xr(a.nextSibling),a===null))return null;return a}function Gy(a){return a.data==="$?"||a.data==="$~"}function Vy(a){return a.data==="$!"||a.data==="$?"&&a.ownerDocument.readyState!=="loading"}function Kq(a,s){var f=a.ownerDocument;if(a.data==="$~")a._reactRetry=s;else if(a.data!=="$?"||f.readyState!=="loading")s();else{var m=function(){s(),f.removeEventListener("DOMContentLoaded",m)};f.addEventListener("DOMContentLoaded",m),a._reactRetry=m}}function xr(a){for(;a!=null;a=a.nextSibling){var s=a.nodeType;if(s===1||s===3)break;if(s===8){if(s=a.data,s==="$"||s==="$!"||s==="$?"||s==="$~"||s==="&"||s==="F!"||s==="F")break;if(s==="/$"||s==="/&")return null}}return a}var Yy=null;function m2(a){a=a.nextSibling;for(var s=0;a;){if(a.nodeType===8){var f=a.data;if(f==="/$"||f==="/&"){if(s===0)return xr(a.nextSibling);s--}else f!=="$"&&f!=="$!"&&f!=="$?"&&f!=="$~"&&f!=="&"||s++}a=a.nextSibling}return null}function p2(a){a=a.previousSibling;for(var s=0;a;){if(a.nodeType===8){var f=a.data;if(f==="$"||f==="$!"||f==="$?"||f==="$~"||f==="&"){if(s===0)return a;s--}else f!=="/$"&&f!=="/&"||s++}a=a.previousSibling}return null}function v2(a,s,f){switch(s=eh(f),a){case"html":if(a=s.documentElement,!a)throw Error(r(452));return a;case"head":if(a=s.head,!a)throw Error(r(453));return a;case"body":if(a=s.body,!a)throw Error(r(454));return a;default:throw Error(r(451))}}function ou(a){for(var s=a.attributes;s.length;)a.removeAttributeNode(s[0]);Kv(a)}var wr=new Map,g2=new Set;function th(a){return typeof a.getRootNode=="function"?a.getRootNode():a.nodeType===9?a:a.ownerDocument}var Ba=H.d;H.d={f:Xq,r:Qq,D:Zq,C:Jq,L:eU,m:tU,X:rU,S:nU,M:aU};function Xq(){var a=Ba.f(),s=Vd();return a||s}function Qq(a){var s=xs(a);s!==null&&s.tag===5&&s.type==="form"?PA(s):Ba.r(a)}var Zs=typeof document>"u"?null:document;function y2(a,s,f){var m=Zs;if(m&&typeof s=="string"&&s){var y=hr(s);y='link[rel="'+a+'"][href="'+y+'"]',typeof f=="string"&&(y+='[crossorigin="'+f+'"]'),g2.has(y)||(g2.add(y),a={rel:a,crossOrigin:f,href:s},m.querySelector(y)===null&&(s=m.createElement("link"),hn(s,"link",a),rn(s),m.head.appendChild(s)))}}function Zq(a){Ba.D(a),y2("dns-prefetch",a,null)}function Jq(a,s){Ba.C(a,s),y2("preconnect",a,s)}function eU(a,s,f){Ba.L(a,s,f);var m=Zs;if(m&&a&&s){var y='link[rel="preload"][as="'+hr(s)+'"]';s==="image"&&f&&f.imageSrcSet?(y+='[imagesrcset="'+hr(f.imageSrcSet)+'"]',typeof f.imageSizes=="string"&&(y+='[imagesizes="'+hr(f.imageSizes)+'"]')):y+='[href="'+hr(a)+'"]';var S=y;switch(s){case"style":S=Js(a);break;case"script":S=el(a)}wr.has(S)||(a=p({rel:"preload",href:s==="image"&&f&&f.imageSrcSet?void 0:a,as:s},f),wr.set(S,a),m.querySelector(y)!==null||s==="style"&&m.querySelector(su(S))||s==="script"&&m.querySelector(lu(S))||(s=m.createElement("link"),hn(s,"link",a),rn(s),m.head.appendChild(s)))}}function tU(a,s){Ba.m(a,s);var f=Zs;if(f&&a){var m=s&&typeof s.as=="string"?s.as:"script",y='link[rel="modulepreload"][as="'+hr(m)+'"][href="'+hr(a)+'"]',S=y;switch(m){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":S=el(a)}if(!wr.has(S)&&(a=p({rel:"modulepreload",href:a},s),wr.set(S,a),f.querySelector(y)===null)){switch(m){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(f.querySelector(lu(S)))return}m=f.createElement("link"),hn(m,"link",a),rn(m),f.head.appendChild(m)}}}function nU(a,s,f){Ba.S(a,s,f);var m=Zs;if(m&&a){var y=ws(m).hoistableStyles,S=Js(a);s=s||"default";var T=y.get(S);if(!T){var P={loading:0,preload:null};if(T=m.querySelector(su(S)))P.loading=5;else{a=p({rel:"stylesheet",href:a,"data-precedence":s},f),(f=wr.get(S))&&Wy(a,f);var G=T=m.createElement("link");rn(G),hn(G,"link",a),G._p=new Promise(function(te,ce){G.onload=te,G.onerror=ce}),G.addEventListener("load",function(){P.loading|=1}),G.addEventListener("error",function(){P.loading|=2}),P.loading|=4,nh(T,s,m)}T={type:"stylesheet",instance:T,count:1,state:P},y.set(S,T)}}}function rU(a,s){Ba.X(a,s);var f=Zs;if(f&&a){var m=ws(f).hoistableScripts,y=el(a),S=m.get(y);S||(S=f.querySelector(lu(y)),S||(a=p({src:a,async:!0},s),(s=wr.get(y))&&Ky(a,s),S=f.createElement("script"),rn(S),hn(S,"link",a),f.head.appendChild(S)),S={type:"script",instance:S,count:1,state:null},m.set(y,S))}}function aU(a,s){Ba.M(a,s);var f=Zs;if(f&&a){var m=ws(f).hoistableScripts,y=el(a),S=m.get(y);S||(S=f.querySelector(lu(y)),S||(a=p({src:a,async:!0,type:"module"},s),(s=wr.get(y))&&Ky(a,s),S=f.createElement("script"),rn(S),hn(S,"link",a),f.head.appendChild(S)),S={type:"script",instance:S,count:1,state:null},m.set(y,S))}}function b2(a,s,f,m){var y=(y=fe.current)?th(y):null;if(!y)throw Error(r(446));switch(a){case"meta":case"title":return null;case"style":return typeof f.precedence=="string"&&typeof f.href=="string"?(s=Js(f.href),f=ws(y).hoistableStyles,m=f.get(s),m||(m={type:"style",instance:null,count:0,state:null},f.set(s,m)),m):{type:"void",instance:null,count:0,state:null};case"link":if(f.rel==="stylesheet"&&typeof f.href=="string"&&typeof f.precedence=="string"){a=Js(f.href);var S=ws(y).hoistableStyles,T=S.get(a);if(T||(y=y.ownerDocument||y,T={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},S.set(a,T),(S=y.querySelector(su(a)))&&!S._p&&(T.instance=S,T.state.loading=5),wr.has(a)||(f={rel:"preload",as:"style",href:f.href,crossOrigin:f.crossOrigin,integrity:f.integrity,media:f.media,hrefLang:f.hrefLang,referrerPolicy:f.referrerPolicy},wr.set(a,f),S||iU(y,a,f,T.state))),s&&m===null)throw Error(r(528,""));return T}if(s&&m!==null)throw Error(r(529,""));return null;case"script":return s=f.async,f=f.src,typeof f=="string"&&s&&typeof s!="function"&&typeof s!="symbol"?(s=el(f),f=ws(y).hoistableScripts,m=f.get(s),m||(m={type:"script",instance:null,count:0,state:null},f.set(s,m)),m):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,a))}}function Js(a){return'href="'+hr(a)+'"'}function su(a){return'link[rel="stylesheet"]['+a+"]"}function x2(a){return p({},a,{"data-precedence":a.precedence,precedence:null})}function iU(a,s,f,m){a.querySelector('link[rel="preload"][as="style"]['+s+"]")?m.loading=1:(s=a.createElement("link"),m.preload=s,s.addEventListener("load",function(){return m.loading|=1}),s.addEventListener("error",function(){return m.loading|=2}),hn(s,"link",f),rn(s),a.head.appendChild(s))}function el(a){return'[src="'+hr(a)+'"]'}function lu(a){return"script[async]"+a}function w2(a,s,f){if(s.count++,s.instance===null)switch(s.type){case"style":var m=a.querySelector('style[data-href~="'+hr(f.href)+'"]');if(m)return s.instance=m,rn(m),m;var y=p({},f,{"data-href":f.href,"data-precedence":f.precedence,href:null,precedence:null});return m=(a.ownerDocument||a).createElement("style"),rn(m),hn(m,"style",y),nh(m,f.precedence,a),s.instance=m;case"stylesheet":y=Js(f.href);var S=a.querySelector(su(y));if(S)return s.state.loading|=4,s.instance=S,rn(S),S;m=x2(f),(y=wr.get(y))&&Wy(m,y),S=(a.ownerDocument||a).createElement("link"),rn(S);var T=S;return T._p=new Promise(function(P,G){T.onload=P,T.onerror=G}),hn(S,"link",m),s.state.loading|=4,nh(S,f.precedence,a),s.instance=S;case"script":return S=el(f.src),(y=a.querySelector(lu(S)))?(s.instance=y,rn(y),y):(m=f,(y=wr.get(S))&&(m=p({},f),Ky(m,y)),a=a.ownerDocument||a,y=a.createElement("script"),rn(y),hn(y,"link",m),a.head.appendChild(y),s.instance=y);case"void":return null;default:throw Error(r(443,s.type))}else s.type==="stylesheet"&&(s.state.loading&4)===0&&(m=s.instance,s.state.loading|=4,nh(m,f.precedence,a));return s.instance}function nh(a,s,f){for(var m=f.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),y=m.length?m[m.length-1]:null,S=y,T=0;T<m.length;T++){var P=m[T];if(P.dataset.precedence===s)S=P;else if(S!==y)break}S?S.parentNode.insertBefore(a,S.nextSibling):(s=f.nodeType===9?f.head:f,s.insertBefore(a,s.firstChild))}function Wy(a,s){a.crossOrigin==null&&(a.crossOrigin=s.crossOrigin),a.referrerPolicy==null&&(a.referrerPolicy=s.referrerPolicy),a.title==null&&(a.title=s.title)}function Ky(a,s){a.crossOrigin==null&&(a.crossOrigin=s.crossOrigin),a.referrerPolicy==null&&(a.referrerPolicy=s.referrerPolicy),a.integrity==null&&(a.integrity=s.integrity)}var rh=null;function S2(a,s,f){if(rh===null){var m=new Map,y=rh=new Map;y.set(f,m)}else y=rh,m=y.get(f),m||(m=new Map,y.set(f,m));if(m.has(a))return m;for(m.set(a,null),f=f.getElementsByTagName(a),y=0;y<f.length;y++){var S=f[y];if(!(S[Oc]||S[cn]||a==="link"&&S.getAttribute("rel")==="stylesheet")&&S.namespaceURI!=="http://www.w3.org/2000/svg"){var T=S.getAttribute(s)||"";T=a+T;var P=m.get(T);P?P.push(S):m.set(T,[S])}}return m}function j2(a,s,f){a=a.ownerDocument||a,a.head.insertBefore(f,s==="title"?a.querySelector("head > title"):null)}function oU(a,s,f){if(f===1||s.itemProp!=null)return!1;switch(a){case"meta":case"title":return!0;case"style":if(typeof s.precedence!="string"||typeof s.href!="string"||s.href==="")break;return!0;case"link":if(typeof s.rel!="string"||typeof s.href!="string"||s.href===""||s.onLoad||s.onError)break;switch(s.rel){case"stylesheet":return a=s.disabled,typeof s.precedence=="string"&&a==null;default:return!0}case"script":if(s.async&&typeof s.async!="function"&&typeof s.async!="symbol"&&!s.onLoad&&!s.onError&&s.src&&typeof s.src=="string")return!0}return!1}function O2(a){return!(a.type==="stylesheet"&&(a.state.loading&3)===0)}function sU(a,s,f,m){if(f.type==="stylesheet"&&(typeof m.media!="string"||matchMedia(m.media).matches!==!1)&&(f.state.loading&4)===0){if(f.instance===null){var y=Js(m.href),S=s.querySelector(su(y));if(S){s=S._p,s!==null&&typeof s=="object"&&typeof s.then=="function"&&(a.count++,a=ah.bind(a),s.then(a,a)),f.state.loading|=4,f.instance=S,rn(S);return}S=s.ownerDocument||s,m=x2(m),(y=wr.get(y))&&Wy(m,y),S=S.createElement("link"),rn(S);var T=S;T._p=new Promise(function(P,G){T.onload=P,T.onerror=G}),hn(S,"link",m),f.instance=S}a.stylesheets===null&&(a.stylesheets=new Map),a.stylesheets.set(f,s),(s=f.state.preload)&&(f.state.loading&3)===0&&(a.count++,f=ah.bind(a),s.addEventListener("load",f),s.addEventListener("error",f))}}var Xy=0;function lU(a,s){return a.stylesheets&&a.count===0&&oh(a,a.stylesheets),0<a.count||0<a.imgCount?function(f){var m=setTimeout(function(){if(a.stylesheets&&oh(a,a.stylesheets),a.unsuspend){var S=a.unsuspend;a.unsuspend=null,S()}},6e4+s);0<a.imgBytes&&Xy===0&&(Xy=62500*Uq());var y=setTimeout(function(){if(a.waitingForImages=!1,a.count===0&&(a.stylesheets&&oh(a,a.stylesheets),a.unsuspend)){var S=a.unsuspend;a.unsuspend=null,S()}},(a.imgBytes>Xy?50:800)+s);return a.unsuspend=f,function(){a.unsuspend=null,clearTimeout(m),clearTimeout(y)}}:null}function ah(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)oh(this,this.stylesheets);else if(this.unsuspend){var a=this.unsuspend;this.unsuspend=null,a()}}}var ih=null;function oh(a,s){a.stylesheets=null,a.unsuspend!==null&&(a.count++,ih=new Map,s.forEach(cU,a),ih=null,ah.call(a))}function cU(a,s){if(!(s.state.loading&4)){var f=ih.get(a);if(f)var m=f.get(null);else{f=new Map,ih.set(a,f);for(var y=a.querySelectorAll("link[data-precedence],style[data-precedence]"),S=0;S<y.length;S++){var T=y[S];(T.nodeName==="LINK"||T.getAttribute("media")!=="not all")&&(f.set(T.dataset.precedence,T),m=T)}m&&f.set(null,m)}y=s.instance,T=y.getAttribute("data-precedence"),S=f.get(T)||m,S===m&&f.set(null,y),f.set(T,y),this.count++,m=ah.bind(this),y.addEventListener("load",m),y.addEventListener("error",m),S?S.parentNode.insertBefore(y,S.nextSibling):(a=a.nodeType===9?a.head:a,a.insertBefore(y,a.firstChild)),s.state.loading|=4}}var cu={$$typeof:E,Provider:null,Consumer:null,_currentValue:B,_currentValue2:B,_threadCount:0};function uU(a,s,f,m,y,S,T,P,G){this.tag=1,this.containerInfo=a,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=hi(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=hi(0),this.hiddenUpdates=hi(null),this.identifierPrefix=m,this.onUncaughtError=y,this.onCaughtError=S,this.onRecoverableError=T,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=G,this.incompleteTransitions=new Map}function _2(a,s,f,m,y,S,T,P,G,te,ce,he){return a=new uU(a,s,f,T,G,te,ce,he,P),s=1,S===!0&&(s|=24),S=Yn(3,null,null,s),a.current=S,S.stateNode=a,s=Cg(),s.refCount++,a.pooledCache=s,s.refCount++,S.memoizedState={element:m,isDehydrated:f,cache:s},Dg(S),a}function E2(a){return a?(a=Ms,a):Ms}function A2(a,s,f,m,y,S){y=E2(y),m.context===null?m.context=y:m.pendingContext=y,m=wi(s),m.payload={element:f},S=S===void 0?null:S,S!==null&&(m.callback=S),f=Si(a,m,s),f!==null&&(zn(f,a,s),qc(f,a,s))}function N2(a,s){if(a=a.memoizedState,a!==null&&a.dehydrated!==null){var f=a.retryLane;a.retryLane=f!==0&&f<s?f:s}}function Qy(a,s){N2(a,s),(a=a.alternate)&&N2(a,s)}function C2(a){if(a.tag===13||a.tag===31){var s=xo(a,67108864);s!==null&&zn(s,a,67108864),Qy(a,67108864)}}function T2(a){if(a.tag===13||a.tag===31){var s=Zn();s=gs(s);var f=xo(a,s);f!==null&&zn(f,a,s),Qy(a,s)}}var sh=!0;function fU(a,s,f,m){var y=k.T;k.T=null;var S=H.p;try{H.p=2,Zy(a,s,f,m)}finally{H.p=S,k.T=y}}function dU(a,s,f,m){var y=k.T;k.T=null;var S=H.p;try{H.p=8,Zy(a,s,f,m)}finally{H.p=S,k.T=y}}function Zy(a,s,f,m){if(sh){var y=Jy(m);if(y===null)Ly(a,s,m,lh,f),R2(a,m);else if(mU(y,a,s,f,m))m.stopPropagation();else if(R2(a,m),s&4&&-1<hU.indexOf(a)){for(;y!==null;){var S=xs(y);if(S!==null)switch(S.tag){case 3:if(S=S.stateNode,S.current.memoizedState.isDehydrated){var T=ea(S.pendingLanes);if(T!==0){var P=S;for(P.pendingLanes|=2,P.entangledLanes|=2;T;){var G=1<<31-gn(T);P.entanglements[1]|=G,T&=~G}aa(S),(st&6)===0&&(Fd=tn()+500,ru(0))}}break;case 31:case 13:P=xo(S,2),P!==null&&zn(P,S,2),Vd(),Qy(S,2)}if(S=Jy(m),S===null&&Ly(a,s,m,lh,f),S===y)break;y=S}y!==null&&m.stopPropagation()}else Ly(a,s,m,null,f)}}function Jy(a){return a=tg(a),eb(a)}var lh=null;function eb(a){if(lh=null,a=bs(a),a!==null){var s=o(a);if(s===null)a=null;else{var f=s.tag;if(f===13){if(a=l(s),a!==null)return a;a=null}else if(f===31){if(a=u(s),a!==null)return a;a=null}else if(f===3){if(s.stateNode.current.memoizedState.isDehydrated)return s.tag===3?s.stateNode.containerInfo:null;a=null}else s!==a&&(a=null)}}return lh=a,null}function M2(a){switch(a){case"beforetoggle":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"toggle":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 2;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"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(ms()){case uo:return 2;case ed:return 8;case fo:case Sc:return 32;case Sa:return 268435456;default:return 32}default:return 32}}var tb=!1,Di=null,Pi=null,ki=null,uu=new Map,fu=new Map,$i=[],hU="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".split(" ");function R2(a,s){switch(a){case"focusin":case"focusout":Di=null;break;case"dragenter":case"dragleave":Pi=null;break;case"mouseover":case"mouseout":ki=null;break;case"pointerover":case"pointerout":uu.delete(s.pointerId);break;case"gotpointercapture":case"lostpointercapture":fu.delete(s.pointerId)}}function du(a,s,f,m,y,S){return a===null||a.nativeEvent!==S?(a={blockedOn:s,domEventName:f,eventSystemFlags:m,nativeEvent:S,targetContainers:[y]},s!==null&&(s=xs(s),s!==null&&C2(s)),a):(a.eventSystemFlags|=m,s=a.targetContainers,y!==null&&s.indexOf(y)===-1&&s.push(y),a)}function mU(a,s,f,m,y){switch(s){case"focusin":return Di=du(Di,a,s,f,m,y),!0;case"dragenter":return Pi=du(Pi,a,s,f,m,y),!0;case"mouseover":return ki=du(ki,a,s,f,m,y),!0;case"pointerover":var S=y.pointerId;return uu.set(S,du(uu.get(S)||null,a,s,f,m,y)),!0;case"gotpointercapture":return S=y.pointerId,fu.set(S,du(fu.get(S)||null,a,s,f,m,y)),!0}return!1}function D2(a){var s=bs(a.target);if(s!==null){var f=o(s);if(f!==null){if(s=f.tag,s===13){if(s=l(f),s!==null){a.blockedOn=s,Y_(a.priority,function(){T2(f)});return}}else if(s===31){if(s=u(f),s!==null){a.blockedOn=s,Y_(a.priority,function(){T2(f)});return}}else if(s===3&&f.stateNode.current.memoizedState.isDehydrated){a.blockedOn=f.tag===3?f.stateNode.containerInfo:null;return}}}a.blockedOn=null}function ch(a){if(a.blockedOn!==null)return!1;for(var s=a.targetContainers;0<s.length;){var f=Jy(a.nativeEvent);if(f===null){f=a.nativeEvent;var m=new f.constructor(f.type,f);eg=m,f.target.dispatchEvent(m),eg=null}else return s=xs(f),s!==null&&C2(s),a.blockedOn=f,!1;s.shift()}return!0}function P2(a,s,f){ch(a)&&f.delete(s)}function pU(){tb=!1,Di!==null&&ch(Di)&&(Di=null),Pi!==null&&ch(Pi)&&(Pi=null),ki!==null&&ch(ki)&&(ki=null),uu.forEach(P2),fu.forEach(P2)}function uh(a,s){a.blockedOn===s&&(a.blockedOn=null,tb||(tb=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,pU)))}var fh=null;function k2(a){fh!==a&&(fh=a,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){fh===a&&(fh=null);for(var s=0;s<a.length;s+=3){var f=a[s],m=a[s+1],y=a[s+2];if(typeof m!="function"){if(eb(m||f)===null)continue;break}var S=xs(f);S!==null&&(a.splice(s,3),s-=3,Jg(S,{pending:!0,data:y,method:f.method,action:m},m,y))}}))}function tl(a){function s(G){return uh(G,a)}Di!==null&&uh(Di,a),Pi!==null&&uh(Pi,a),ki!==null&&uh(ki,a),uu.forEach(s),fu.forEach(s);for(var f=0;f<$i.length;f++){var m=$i[f];m.blockedOn===a&&(m.blockedOn=null)}for(;0<$i.length&&(f=$i[0],f.blockedOn===null);)D2(f),f.blockedOn===null&&$i.shift();if(f=(a.ownerDocument||a).$$reactFormReplay,f!=null)for(m=0;m<f.length;m+=3){var y=f[m],S=f[m+1],T=y[Dn]||null;if(typeof S=="function")T||k2(f);else if(T){var P=null;if(S&&S.hasAttribute("formAction")){if(y=S,T=S[Dn]||null)P=T.formAction;else if(eb(y)!==null)continue}else P=T.action;typeof P=="function"?f[m+1]=P:(f.splice(m,3),m-=3),k2(f)}}}function $2(){function a(S){S.canIntercept&&S.info==="react-transition"&&S.intercept({handler:function(){return new Promise(function(T){return y=T})},focusReset:"manual",scroll:"manual"})}function s(){y!==null&&(y(),y=null),m||setTimeout(f,20)}function f(){if(!m&&!navigation.transition){var S=navigation.currentEntry;S&&S.url!=null&&navigation.navigate(S.url,{state:S.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var m=!1,y=null;return navigation.addEventListener("navigate",a),navigation.addEventListener("navigatesuccess",s),navigation.addEventListener("navigateerror",s),setTimeout(f,100),function(){m=!0,navigation.removeEventListener("navigate",a),navigation.removeEventListener("navigatesuccess",s),navigation.removeEventListener("navigateerror",s),y!==null&&(y(),y=null)}}}function nb(a){this._internalRoot=a}dh.prototype.render=nb.prototype.render=function(a){var s=this._internalRoot;if(s===null)throw Error(r(409));var f=s.current,m=Zn();A2(f,m,a,s,null,null)},dh.prototype.unmount=nb.prototype.unmount=function(){var a=this._internalRoot;if(a!==null){this._internalRoot=null;var s=a.containerInfo;A2(a.current,2,null,a,null,null),Vd(),s[ys]=null}};function dh(a){this._internalRoot=a}dh.prototype.unstable_scheduleHydration=function(a){if(a){var s=Yv();a={blockedOn:null,target:a,priority:s};for(var f=0;f<$i.length&&s!==0&&s<$i[f].priority;f++);$i.splice(f,0,a),f===0&&D2(a)}};var I2=t.version;if(I2!=="19.2.3")throw Error(r(527,I2,"19.2.3"));H.findDOMNode=function(a){var s=a._reactInternals;if(s===void 0)throw typeof a.render=="function"?Error(r(188)):(a=Object.keys(a).join(","),Error(r(268,a)));return a=h(s),a=a!==null?v(a):null,a=a===null?null:a.stateNode,a};var vU={bundleType:0,version:"19.2.3",rendererPackageName:"react-dom",currentDispatcherRef:k,reconcilerVersion:"19.2.3"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var hh=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!hh.isDisabled&&hh.supportsFiber)try{ho=hh.inject(vU),On=hh}catch{}}return mu.createRoot=function(a,s){if(!i(a))throw Error(r(299));var f=!1,m="",y=FA,S=GA,T=VA;return s!=null&&(s.unstable_strictMode===!0&&(f=!0),s.identifierPrefix!==void 0&&(m=s.identifierPrefix),s.onUncaughtError!==void 0&&(y=s.onUncaughtError),s.onCaughtError!==void 0&&(S=s.onCaughtError),s.onRecoverableError!==void 0&&(T=s.onRecoverableError)),s=_2(a,1,!1,null,null,f,m,null,y,S,T,$2),a[ys]=s.current,Iy(a),new nb(s)},mu.hydrateRoot=function(a,s,f){if(!i(a))throw Error(r(299));var m=!1,y="",S=FA,T=GA,P=VA,G=null;return f!=null&&(f.unstable_strictMode===!0&&(m=!0),f.identifierPrefix!==void 0&&(y=f.identifierPrefix),f.onUncaughtError!==void 0&&(S=f.onUncaughtError),f.onCaughtError!==void 0&&(T=f.onCaughtError),f.onRecoverableError!==void 0&&(P=f.onRecoverableError),f.formState!==void 0&&(G=f.formState)),s=_2(a,1,!0,s,f??null,m,y,G,S,T,P,$2),s.context=E2(null),f=s.current,m=Zn(),m=gs(m),y=wi(m),y.callback=null,Si(f,y,m),f=m,s.current.lanes=f,Rt(s,f),aa(s),a[ys]=s.current,Iy(a),new dh(s)},mu.version="19.2.3",mu}var Y2;function NU(){if(Y2)return ob.exports;Y2=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),ob.exports=AU(),ob.exports}var CU=NU();/**
50
+ * react-router v7.11.0
51
+ *
52
+ * Copyright (c) Remix Software Inc.
53
+ *
54
+ * This source code is licensed under the MIT license found in the
55
+ * LICENSE.md file in the root directory of this source tree.
56
+ *
57
+ * @license MIT
58
+ */var W2="popstate";function TU(e={}){function t(r,i){let{pathname:o,search:l,hash:u}=r.location;return B1("",{pathname:o,search:l,hash:u},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Bu(i)}return RU(t,n,null,e)}function Tt(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Rr(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function MU(){return Math.random().toString(36).substring(2,10)}function K2(e,t){return{usr:e.state,key:e.key,idx:t}}function B1(e,t,n=null,r){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?Xl(t):t,state:n,key:t&&t.key||r||MU()}}function Bu({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function Xl(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function RU(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:o=!1}=r,l=i.history,u="POP",d=null,h=v();h==null&&(h=0,l.replaceState({...l.state,idx:h},""));function v(){return(l.state||{idx:null}).idx}function p(){u="POP";let x=v(),_=x==null?null:x-h;h=x,d&&d({action:u,location:j.location,delta:_})}function g(x,_){u="PUSH";let A=B1(j.location,x,_);h=v()+1;let E=K2(A,h),C=j.createHref(A);try{l.pushState(E,"",C)}catch(N){if(N instanceof DOMException&&N.name==="DataCloneError")throw N;i.location.assign(C)}o&&d&&d({action:u,location:j.location,delta:1})}function b(x,_){u="REPLACE";let A=B1(j.location,x,_);h=v();let E=K2(A,h),C=j.createHref(A);l.replaceState(E,"",C),o&&d&&d({action:u,location:j.location,delta:0})}function O(x){return DU(x)}let j={get action(){return u},get location(){return e(i,l)},listen(x){if(d)throw new Error("A history only accepts one active listener");return i.addEventListener(W2,p),d=x,()=>{i.removeEventListener(W2,p),d=null}},createHref(x){return t(i,x)},createURL:O,encodeLocation(x){let _=O(x);return{pathname:_.pathname,search:_.search,hash:_.hash}},push:g,replace:b,go(x){return l.go(x)}};return j}function DU(e,t=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),Tt(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:Bu(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function U4(e,t,n="/"){return PU(e,t,n,!1)}function PU(e,t,n,r){let i=typeof t=="string"?Xl(t):t,o=Za(i.pathname||"/",n);if(o==null)return null;let l=H4(e);kU(l);let u=null;for(let d=0;u==null&&d<l.length;++d){let h=VU(o);u=FU(l[d],h,r)}return u}function H4(e,t=[],n=[],r="",i=!1){let o=(l,u,d=i,h)=>{let v={relativePath:h===void 0?l.path||"":h,caseSensitive:l.caseSensitive===!0,childrenIndex:u,route:l};if(v.relativePath.startsWith("/")){if(!v.relativePath.startsWith(r)&&d)return;Tt(v.relativePath.startsWith(r),`Absolute route path "${v.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),v.relativePath=v.relativePath.slice(r.length)}let p=Ya([r,v.relativePath]),g=n.concat(v);l.children&&l.children.length>0&&(Tt(l.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${p}".`),H4(l.children,t,g,p,d)),!(l.path==null&&!l.index)&&t.push({path:p,score:UU(p,l.index),routesMeta:g})};return e.forEach((l,u)=>{var d;if(l.path===""||!((d=l.path)!=null&&d.includes("?")))o(l,u);else for(let h of F4(l.path))o(l,u,!0,h)}),t}function F4(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return i?[o,""]:[o];let l=F4(r.join("/")),u=[];return u.push(...l.map(d=>d===""?o:[o,d].join("/"))),i&&u.push(...l),u.map(d=>e.startsWith("/")&&d===""?"/":d)}function kU(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:HU(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var $U=/^:[\w-]+$/,IU=3,LU=2,zU=1,BU=10,qU=-2,X2=e=>e==="*";function UU(e,t){let n=e.split("/"),r=n.length;return n.some(X2)&&(r+=qU),t&&(r+=LU),n.filter(i=>!X2(i)).reduce((i,o)=>i+($U.test(o)?IU:o===""?zU:BU),r)}function HU(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function FU(e,t,n=!1){let{routesMeta:r}=e,i={},o="/",l=[];for(let u=0;u<r.length;++u){let d=r[u],h=u===r.length-1,v=o==="/"?t:t.slice(o.length)||"/",p=Kh({path:d.relativePath,caseSensitive:d.caseSensitive,end:h},v),g=d.route;if(!p&&h&&n&&!r[r.length-1].route.index&&(p=Kh({path:d.relativePath,caseSensitive:d.caseSensitive,end:!1},v)),!p)return null;Object.assign(i,p.params),l.push({params:i,pathname:Ya([o,p.pathname]),pathnameBase:XU(Ya([o,p.pathnameBase])),route:g}),p.pathnameBase!=="/"&&(o=Ya([o,p.pathnameBase]))}return l}function Kh(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=GU(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let o=i[0],l=o.replace(/(.)\/+$/,"$1"),u=i.slice(1);return{params:r.reduce((h,{paramName:v,isOptional:p},g)=>{if(v==="*"){let O=u[g]||"";l=o.slice(0,o.length-O.length).replace(/(.)\/+$/,"$1")}const b=u[g];return p&&!b?h[v]=void 0:h[v]=(b||"").replace(/%2F/g,"/"),h},{}),pathname:o,pathnameBase:l,pattern:e}}function GU(e,t=!1,n=!0){Rr(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(l,u,d)=>(r.push({paramName:u,isOptional:d!=null}),d?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function VU(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Rr(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function Za(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}var G4=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,YU=e=>G4.test(e);function WU(e,t="/"){let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Xl(e):e,o;if(n)if(YU(n))o=n;else{if(n.includes("//")){let l=n;n=n.replace(/\/\/+/g,"/"),Rr(!1,`Pathnames cannot have embedded double slashes - normalizing ${l} -> ${n}`)}n.startsWith("/")?o=Q2(n.substring(1),"/"):o=Q2(n,t)}else o=t;return{pathname:o,search:QU(r),hash:ZU(i)}}function Q2(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function ub(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function KU(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Pj(e){let t=KU(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function kj(e,t,n,r=!1){let i;typeof e=="string"?i=Xl(e):(i={...e},Tt(!i.pathname||!i.pathname.includes("?"),ub("?","pathname","search",i)),Tt(!i.pathname||!i.pathname.includes("#"),ub("#","pathname","hash",i)),Tt(!i.search||!i.search.includes("#"),ub("#","search","hash",i)));let o=e===""||i.pathname==="",l=o?"/":i.pathname,u;if(l==null)u=n;else{let p=t.length-1;if(!r&&l.startsWith("..")){let g=l.split("/");for(;g[0]==="..";)g.shift(),p-=1;i.pathname=g.join("/")}u=p>=0?t[p]:"/"}let d=WU(i,u),h=l&&l!=="/"&&l.endsWith("/"),v=(o||l===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(h||v)&&(d.pathname+="/"),d}var Ya=e=>e.join("/").replace(/\/\/+/g,"/"),XU=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),QU=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,ZU=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,JU=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function eH(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function tH(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var V4=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Y4(e,t){let n=e;if(typeof n!="string"||!G4.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(V4)try{let o=new URL(window.location.href),l=n.startsWith("//")?new URL(o.protocol+n):new URL(n),u=Za(l.pathname,t);l.origin===o.origin&&u!=null?n=u+l.search+l.hash:i=!0}catch{Rr(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var W4=["POST","PUT","PATCH","DELETE"];new Set(W4);var nH=["GET",...W4];new Set(nH);var Ql=w.createContext(null);Ql.displayName="DataRouter";var Ap=w.createContext(null);Ap.displayName="DataRouterState";var rH=w.createContext(!1),K4=w.createContext({isTransitioning:!1});K4.displayName="ViewTransition";var aH=w.createContext(new Map);aH.displayName="Fetchers";var iH=w.createContext(null);iH.displayName="Await";var cr=w.createContext(null);cr.displayName="Navigation";var Rf=w.createContext(null);Rf.displayName="Location";var Xr=w.createContext({outlet:null,matches:[],isDataRoute:!1});Xr.displayName="Route";var $j=w.createContext(null);$j.displayName="RouteError";var X4="REACT_ROUTER_ERROR",oH="REDIRECT",sH="ROUTE_ERROR_RESPONSE";function lH(e){if(e.startsWith(`${X4}:${oH}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}function cH(e){if(e.startsWith(`${X4}:${sH}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new JU(t.status,t.statusText,t.data)}catch{}}function uH(e,{relative:t}={}){Tt(Zl(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=w.useContext(cr),{hash:i,pathname:o,search:l}=Df(e,{relative:t}),u=o;return n!=="/"&&(u=o==="/"?n:Ya([n,o])),r.createHref({pathname:u,search:l,hash:i})}function Zl(){return w.useContext(Rf)!=null}function ba(){return Tt(Zl(),"useLocation() may be used only in the context of a <Router> component."),w.useContext(Rf).location}var Q4="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Z4(e){w.useContext(cr).static||w.useLayoutEffect(e)}function ns(){let{isDataRoute:e}=w.useContext(Xr);return e?jH():fH()}function fH(){Tt(Zl(),"useNavigate() may be used only in the context of a <Router> component.");let e=w.useContext(Ql),{basename:t,navigator:n}=w.useContext(cr),{matches:r}=w.useContext(Xr),{pathname:i}=ba(),o=JSON.stringify(Pj(r)),l=w.useRef(!1);return Z4(()=>{l.current=!0}),w.useCallback((d,h={})=>{if(Rr(l.current,Q4),!l.current)return;if(typeof d=="number"){n.go(d);return}let v=kj(d,JSON.parse(o),i,h.relative==="path");e==null&&t!=="/"&&(v.pathname=v.pathname==="/"?t:Ya([t,v.pathname])),(h.replace?n.replace:n.push)(v,h.state,h)},[t,n,o,i,e])}w.createContext(null);function J4(){let{matches:e}=w.useContext(Xr),t=e[e.length-1];return t?t.params:{}}function Df(e,{relative:t}={}){let{matches:n}=w.useContext(Xr),{pathname:r}=ba(),i=JSON.stringify(Pj(n));return w.useMemo(()=>kj(e,JSON.parse(i),r,t==="path"),[e,i,r,t])}function dH(e,t){return e$(e,t)}function e$(e,t,n,r,i){var A;Tt(Zl(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=w.useContext(cr),{matches:l}=w.useContext(Xr),u=l[l.length-1],d=u?u.params:{},h=u?u.pathname:"/",v=u?u.pathnameBase:"/",p=u&&u.route;{let E=p&&p.path||"";n$(h,!p||E.endsWith("*")||E.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${h}" (under <Route path="${E}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
59
+
60
+ Please change the parent <Route path="${E}"> to <Route path="${E==="/"?"*":`${E}/*`}">.`)}let g=ba(),b;if(t){let E=typeof t=="string"?Xl(t):t;Tt(v==="/"||((A=E.pathname)==null?void 0:A.startsWith(v)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${v}" but pathname "${E.pathname}" was given in the \`location\` prop.`),b=E}else b=g;let O=b.pathname||"/",j=O;if(v!=="/"){let E=v.replace(/^\//,"").split("/");j="/"+O.replace(/^\//,"").split("/").slice(E.length).join("/")}let x=U4(e,{pathname:j});Rr(p||x!=null,`No routes matched location "${b.pathname}${b.search}${b.hash}" `),Rr(x==null||x[x.length-1].route.element!==void 0||x[x.length-1].route.Component!==void 0||x[x.length-1].route.lazy!==void 0,`Matched leaf route at location "${b.pathname}${b.search}${b.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let _=gH(x&&x.map(E=>Object.assign({},E,{params:Object.assign({},d,E.params),pathname:Ya([v,o.encodeLocation?o.encodeLocation(E.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:E.pathname]),pathnameBase:E.pathnameBase==="/"?v:Ya([v,o.encodeLocation?o.encodeLocation(E.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:E.pathnameBase])})),l,n,r,i);return t&&_?w.createElement(Rf.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...b},navigationType:"POP"}},_):_}function hH(){let e=SH(),t=eH(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},o={padding:"2px 4px",backgroundColor:r},l=null;return console.error("Error handled by React Router default ErrorBoundary:",e),l=w.createElement(w.Fragment,null,w.createElement("p",null,"💿 Hey developer 👋"),w.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",w.createElement("code",{style:o},"ErrorBoundary")," or"," ",w.createElement("code",{style:o},"errorElement")," prop on your route.")),w.createElement(w.Fragment,null,w.createElement("h2",null,"Unexpected Application Error!"),w.createElement("h3",{style:{fontStyle:"italic"}},t),n?w.createElement("pre",{style:i},n):null,l)}var mH=w.createElement(hH,null),t$=class extends w.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const n=cH(e.digest);n&&(e=n)}let t=e!==void 0?w.createElement(Xr.Provider,{value:this.props.routeContext},w.createElement($j.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?w.createElement(pH,{error:e},t):t}};t$.contextType=rH;var fb=new WeakMap;function pH({children:e,error:t}){let{basename:n}=w.useContext(cr);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=lH(t.digest);if(r){let i=fb.get(t);if(i)throw i;let o=Y4(r.location,n);if(V4&&!fb.get(t))if(o.isExternal||r.reloadDocument)window.location.href=o.absoluteURL||o.to;else{const l=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(o.to,{replace:r.replace}));throw fb.set(t,l),l}return w.createElement("meta",{httpEquiv:"refresh",content:`0;url=${o.absoluteURL||o.to}`})}}return e}function vH({routeContext:e,match:t,children:n}){let r=w.useContext(Ql);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),w.createElement(Xr.Provider,{value:e},n)}function gH(e,t=[],n=null,r=null,i=null){if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,l=n==null?void 0:n.errors;if(l!=null){let v=o.findIndex(p=>p.route.id&&(l==null?void 0:l[p.route.id])!==void 0);Tt(v>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(l).join(",")}`),o=o.slice(0,Math.min(o.length,v+1))}let u=!1,d=-1;if(n)for(let v=0;v<o.length;v++){let p=o[v];if((p.route.HydrateFallback||p.route.hydrateFallbackElement)&&(d=v),p.route.id){let{loaderData:g,errors:b}=n,O=p.route.loader&&!g.hasOwnProperty(p.route.id)&&(!b||b[p.route.id]===void 0);if(p.route.lazy||O){u=!0,d>=0?o=o.slice(0,d+1):o=[o[0]];break}}}let h=n&&r?(v,p)=>{var g,b;r(v,{location:n.location,params:((b=(g=n.matches)==null?void 0:g[0])==null?void 0:b.params)??{},unstable_pattern:tH(n.matches),errorInfo:p})}:void 0;return o.reduceRight((v,p,g)=>{let b,O=!1,j=null,x=null;n&&(b=l&&p.route.id?l[p.route.id]:void 0,j=p.route.errorElement||mH,u&&(d<0&&g===0?(n$("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),O=!0,x=null):d===g&&(O=!0,x=p.route.hydrateFallbackElement||null)));let _=t.concat(o.slice(0,g+1)),A=()=>{let E;return b?E=j:O?E=x:p.route.Component?E=w.createElement(p.route.Component,null):p.route.element?E=p.route.element:E=v,w.createElement(vH,{match:p,routeContext:{outlet:v,matches:_,isDataRoute:n!=null},children:E})};return n&&(p.route.ErrorBoundary||p.route.errorElement||g===0)?w.createElement(t$,{location:n.location,revalidation:n.revalidation,component:j,error:b,children:A(),routeContext:{outlet:null,matches:_,isDataRoute:!0},onError:h}):A()},null)}function Ij(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function yH(e){let t=w.useContext(Ql);return Tt(t,Ij(e)),t}function bH(e){let t=w.useContext(Ap);return Tt(t,Ij(e)),t}function xH(e){let t=w.useContext(Xr);return Tt(t,Ij(e)),t}function Lj(e){let t=xH(e),n=t.matches[t.matches.length-1];return Tt(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function wH(){return Lj("useRouteId")}function SH(){var r;let e=w.useContext($j),t=bH("useRouteError"),n=Lj("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function jH(){let{router:e}=yH("useNavigate"),t=Lj("useNavigate"),n=w.useRef(!1);return Z4(()=>{n.current=!0}),w.useCallback(async(i,o={})=>{Rr(n.current,Q4),n.current&&(typeof i=="number"?await e.navigate(i):await e.navigate(i,{fromRouteId:t,...o}))},[e,t])}var Z2={};function n$(e,t,n){!t&&!Z2[e]&&(Z2[e]=!0,Rr(!1,n))}w.memo(OH);function OH({routes:e,future:t,state:n,onError:r}){return e$(e,void 0,n,r,t)}function _H({to:e,replace:t,state:n,relative:r}){Tt(Zl(),"<Navigate> may be used only in the context of a <Router> component.");let{static:i}=w.useContext(cr);Rr(!i,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:o}=w.useContext(Xr),{pathname:l}=ba(),u=ns(),d=kj(e,Pj(o),l,r==="path"),h=JSON.stringify(d);return w.useEffect(()=>{u(JSON.parse(h),{replace:t,state:n,relative:r})},[u,h,r,t,n]),null}function Jn(e){Tt(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function EH({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:o=!1,unstable_useTransitions:l}){Tt(!Zl(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let u=e.replace(/^\/*/,"/"),d=w.useMemo(()=>({basename:u,navigator:i,static:o,unstable_useTransitions:l,future:{}}),[u,i,o,l]);typeof n=="string"&&(n=Xl(n));let{pathname:h="/",search:v="",hash:p="",state:g=null,key:b="default"}=n,O=w.useMemo(()=>{let j=Za(h,u);return j==null?null:{location:{pathname:j,search:v,hash:p,state:g,key:b},navigationType:r}},[u,h,v,p,g,b,r]);return Rr(O!=null,`<Router basename="${u}"> is not able to match the URL "${h}${v}${p}" because it does not start with the basename, so the <Router> won't render anything.`),O==null?null:w.createElement(cr.Provider,{value:d},w.createElement(Rf.Provider,{children:t,value:O}))}function AH({children:e,location:t}){return dH(q1(e),t)}function q1(e,t=[]){let n=[];return w.Children.forEach(e,(r,i)=>{if(!w.isValidElement(r))return;let o=[...t,i];if(r.type===w.Fragment){n.push.apply(n,q1(r.props.children,o));return}Tt(r.type===Jn,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),Tt(!r.props.index||!r.props.children,"An index route cannot have child routes.");let l={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(l.children=q1(r.props.children,o)),n.push(l)}),n}var Uh="get",Hh="application/x-www-form-urlencoded";function Np(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function NH(e){return Np(e)&&e.tagName.toLowerCase()==="button"}function CH(e){return Np(e)&&e.tagName.toLowerCase()==="form"}function TH(e){return Np(e)&&e.tagName.toLowerCase()==="input"}function MH(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function RH(e,t){return e.button===0&&(!t||t==="_self")&&!MH(e)}var ph=null;function DH(){if(ph===null)try{new FormData(document.createElement("form"),0),ph=!1}catch{ph=!0}return ph}var PH=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function db(e){return e!=null&&!PH.has(e)?(Rr(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Hh}"`),null):e}function kH(e,t){let n,r,i,o,l;if(CH(e)){let u=e.getAttribute("action");r=u?Za(u,t):null,n=e.getAttribute("method")||Uh,i=db(e.getAttribute("enctype"))||Hh,o=new FormData(e)}else if(NH(e)||TH(e)&&(e.type==="submit"||e.type==="image")){let u=e.form;if(u==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let d=e.getAttribute("formaction")||u.getAttribute("action");if(r=d?Za(d,t):null,n=e.getAttribute("formmethod")||u.getAttribute("method")||Uh,i=db(e.getAttribute("formenctype"))||db(u.getAttribute("enctype"))||Hh,o=new FormData(u,e),!DH()){let{name:h,type:v,value:p}=e;if(v==="image"){let g=h?`${h}.`:"";o.append(`${g}x`,"0"),o.append(`${g}y`,"0")}else h&&o.append(h,p)}}else{if(Np(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Uh,r=null,i=Hh,l=e}return o&&i==="text/plain"&&(l=o,o=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:o,body:l}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function zj(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function $H(e,t,n){let r=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return r.pathname==="/"?r.pathname=`_root.${n}`:t&&Za(r.pathname,t)==="/"?r.pathname=`${t.replace(/\/$/,"")}/_root.${n}`:r.pathname=`${r.pathname.replace(/\/$/,"")}.${n}`,r}async function IH(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function LH(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function zH(e,t,n){let r=await Promise.all(e.map(async i=>{let o=t.routes[i.route.id];if(o){let l=await IH(o,n);return l.links?l.links():[]}return[]}));return HH(r.flat(1).filter(LH).filter(i=>i.rel==="stylesheet"||i.rel==="preload").map(i=>i.rel==="stylesheet"?{...i,rel:"prefetch",as:"style"}:{...i,rel:"prefetch"}))}function J2(e,t,n,r,i,o){let l=(d,h)=>n[h]?d.route.id!==n[h].route.id:!0,u=(d,h)=>{var v;return n[h].pathname!==d.pathname||((v=n[h].route.path)==null?void 0:v.endsWith("*"))&&n[h].params["*"]!==d.params["*"]};return o==="assets"?t.filter((d,h)=>l(d,h)||u(d,h)):o==="data"?t.filter((d,h)=>{var p;let v=r.routes[d.route.id];if(!v||!v.hasLoader)return!1;if(l(d,h)||u(d,h))return!0;if(d.route.shouldRevalidate){let g=d.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:((p=n[0])==null?void 0:p.params)||{},nextUrl:new URL(e,window.origin),nextParams:d.params,defaultShouldRevalidate:!0});if(typeof g=="boolean")return g}return!0}):[]}function BH(e,t,{includeHydrateFallback:n}={}){return qH(e.map(r=>{let i=t.routes[r.route.id];if(!i)return[];let o=[i.module];return i.clientActionModule&&(o=o.concat(i.clientActionModule)),i.clientLoaderModule&&(o=o.concat(i.clientLoaderModule)),n&&i.hydrateFallbackModule&&(o=o.concat(i.hydrateFallbackModule)),i.imports&&(o=o.concat(i.imports)),o}).flat(1))}function qH(e){return[...new Set(e)]}function UH(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function HH(e,t){let n=new Set;return new Set(t),e.reduce((r,i)=>{let o=JSON.stringify(UH(i));return n.has(o)||(n.add(o),r.push({key:o,link:i})),r},[])}function r$(){let e=w.useContext(Ql);return zj(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function FH(){let e=w.useContext(Ap);return zj(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var Bj=w.createContext(void 0);Bj.displayName="FrameworkContext";function a$(){let e=w.useContext(Bj);return zj(e,"You must render this element inside a <HydratedRouter> element"),e}function GH(e,t){let n=w.useContext(Bj),[r,i]=w.useState(!1),[o,l]=w.useState(!1),{onFocus:u,onBlur:d,onMouseEnter:h,onMouseLeave:v,onTouchStart:p}=t,g=w.useRef(null);w.useEffect(()=>{if(e==="render"&&l(!0),e==="viewport"){let j=_=>{_.forEach(A=>{l(A.isIntersecting)})},x=new IntersectionObserver(j,{threshold:.5});return g.current&&x.observe(g.current),()=>{x.disconnect()}}},[e]),w.useEffect(()=>{if(r){let j=setTimeout(()=>{l(!0)},100);return()=>{clearTimeout(j)}}},[r]);let b=()=>{i(!0)},O=()=>{i(!1),l(!1)};return n?e!=="intent"?[o,g,{}]:[o,g,{onFocus:pu(u,b),onBlur:pu(d,O),onMouseEnter:pu(h,b),onMouseLeave:pu(v,O),onTouchStart:pu(p,b)}]:[!1,g,{}]}function pu(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function VH({page:e,...t}){let{router:n}=r$(),r=w.useMemo(()=>U4(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?w.createElement(WH,{page:e,matches:r,...t}):null}function YH(e){let{manifest:t,routeModules:n}=a$(),[r,i]=w.useState([]);return w.useEffect(()=>{let o=!1;return zH(e,t,n).then(l=>{o||i(l)}),()=>{o=!0}},[e,t,n]),r}function WH({page:e,matches:t,...n}){let r=ba(),{manifest:i,routeModules:o}=a$(),{basename:l}=r$(),{loaderData:u,matches:d}=FH(),h=w.useMemo(()=>J2(e,t,d,i,r,"data"),[e,t,d,i,r]),v=w.useMemo(()=>J2(e,t,d,i,r,"assets"),[e,t,d,i,r]),p=w.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let O=new Set,j=!1;if(t.forEach(_=>{var E;let A=i.routes[_.route.id];!A||!A.hasLoader||(!h.some(C=>C.route.id===_.route.id)&&_.route.id in u&&((E=o[_.route.id])!=null&&E.shouldRevalidate)||A.hasClientLoader?j=!0:O.add(_.route.id))}),O.size===0)return[];let x=$H(e,l,"data");return j&&O.size>0&&x.searchParams.set("_routes",t.filter(_=>O.has(_.route.id)).map(_=>_.route.id).join(",")),[x.pathname+x.search]},[l,u,r,i,h,t,e,o]),g=w.useMemo(()=>BH(v,i),[v,i]),b=YH(v);return w.createElement(w.Fragment,null,p.map(O=>w.createElement("link",{key:O,rel:"prefetch",as:"fetch",href:O,...n})),g.map(O=>w.createElement("link",{key:O,rel:"modulepreload",href:O,...n})),b.map(({key:O,link:j})=>w.createElement("link",{key:O,nonce:n.nonce,...j})))}function KH(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var XH=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{XH&&(window.__reactRouterVersion="7.11.0")}catch{}function QH({basename:e,children:t,unstable_useTransitions:n,window:r}){let i=w.useRef();i.current==null&&(i.current=TU({window:r,v5Compat:!0}));let o=i.current,[l,u]=w.useState({action:o.action,location:o.location}),d=w.useCallback(h=>{n===!1?u(h):w.startTransition(()=>u(h))},[n]);return w.useLayoutEffect(()=>o.listen(d),[o,d]),w.createElement(EH,{basename:e,children:t,location:l.location,navigationType:l.action,navigator:o,unstable_useTransitions:n})}var i$=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Xh=w.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:i,reloadDocument:o,replace:l,state:u,target:d,to:h,preventScrollReset:v,viewTransition:p,unstable_defaultShouldRevalidate:g,...b},O){let{basename:j,unstable_useTransitions:x}=w.useContext(cr),_=typeof h=="string"&&i$.test(h),A=Y4(h,j);h=A.to;let E=uH(h,{relative:i}),[C,N,M]=GH(r,b),R=tF(h,{replace:l,state:u,target:d,preventScrollReset:v,relative:i,viewTransition:p,unstable_defaultShouldRevalidate:g,unstable_useTransitions:x});function D(Y){t&&t(Y),Y.defaultPrevented||R(Y)}let z=w.createElement("a",{...b,...M,href:A.absoluteURL||E,onClick:A.isExternal||o?t:D,ref:KH(O,N),target:d,"data-discover":!_&&n==="render"?"true":void 0});return C&&!_?w.createElement(w.Fragment,null,z,w.createElement(VH,{page:E})):z});Xh.displayName="Link";var ZH=w.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:i=!1,style:o,to:l,viewTransition:u,children:d,...h},v){let p=Df(l,{relative:h.relative}),g=ba(),b=w.useContext(Ap),{navigator:O,basename:j}=w.useContext(cr),x=b!=null&&oF(p)&&u===!0,_=O.encodeLocation?O.encodeLocation(p).pathname:p.pathname,A=g.pathname,E=b&&b.navigation&&b.navigation.location?b.navigation.location.pathname:null;n||(A=A.toLowerCase(),E=E?E.toLowerCase():null,_=_.toLowerCase()),E&&j&&(E=Za(E,j)||E);const C=_!=="/"&&_.endsWith("/")?_.length-1:_.length;let N=A===_||!i&&A.startsWith(_)&&A.charAt(C)==="/",M=E!=null&&(E===_||!i&&E.startsWith(_)&&E.charAt(_.length)==="/"),R={isActive:N,isPending:M,isTransitioning:x},D=N?t:void 0,z;typeof r=="function"?z=r(R):z=[r,N?"active":null,M?"pending":null,x?"transitioning":null].filter(Boolean).join(" ");let Y=typeof o=="function"?o(R):o;return w.createElement(Xh,{...h,"aria-current":D,className:z,ref:v,style:Y,to:l,viewTransition:u},typeof d=="function"?d(R):d)});ZH.displayName="NavLink";var JH=w.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:o,method:l=Uh,action:u,onSubmit:d,relative:h,preventScrollReset:v,viewTransition:p,unstable_defaultShouldRevalidate:g,...b},O)=>{let{unstable_useTransitions:j}=w.useContext(cr),x=aF(),_=iF(u,{relative:h}),A=l.toLowerCase()==="get"?"get":"post",E=typeof u=="string"&&i$.test(u),C=N=>{if(d&&d(N),N.defaultPrevented)return;N.preventDefault();let M=N.nativeEvent.submitter,R=(M==null?void 0:M.getAttribute("formmethod"))||l,D=()=>x(M||N.currentTarget,{fetcherKey:t,method:R,navigate:n,replace:i,state:o,relative:h,preventScrollReset:v,viewTransition:p,unstable_defaultShouldRevalidate:g});j&&n!==!1?w.startTransition(()=>D()):D()};return w.createElement("form",{ref:O,method:A,action:_,onSubmit:r?d:C,...b,"data-discover":!E&&e==="render"?"true":void 0})});JH.displayName="Form";function eF(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function o$(e){let t=w.useContext(Ql);return Tt(t,eF(e)),t}function tF(e,{target:t,replace:n,state:r,preventScrollReset:i,relative:o,viewTransition:l,unstable_defaultShouldRevalidate:u,unstable_useTransitions:d}={}){let h=ns(),v=ba(),p=Df(e,{relative:o});return w.useCallback(g=>{if(RH(g,t)){g.preventDefault();let b=n!==void 0?n:Bu(v)===Bu(p),O=()=>h(e,{replace:b,state:r,preventScrollReset:i,relative:o,viewTransition:l,unstable_defaultShouldRevalidate:u});d?w.startTransition(()=>O()):O()}},[v,h,p,n,r,t,e,i,o,l,u,d])}var nF=0,rF=()=>`__${String(++nF)}__`;function aF(){let{router:e}=o$("useSubmit"),{basename:t}=w.useContext(cr),n=wH(),r=e.fetch,i=e.navigate;return w.useCallback(async(o,l={})=>{let{action:u,method:d,encType:h,formData:v,body:p}=kH(o,t);if(l.navigate===!1){let g=l.fetcherKey||rF();await r(g,n,l.action||u,{unstable_defaultShouldRevalidate:l.unstable_defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:v,body:p,formMethod:l.method||d,formEncType:l.encType||h,flushSync:l.flushSync})}else await i(l.action||u,{unstable_defaultShouldRevalidate:l.unstable_defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:v,body:p,formMethod:l.method||d,formEncType:l.encType||h,replace:l.replace,state:l.state,fromRouteId:n,flushSync:l.flushSync,viewTransition:l.viewTransition})},[r,i,t,n])}function iF(e,{relative:t}={}){let{basename:n}=w.useContext(cr),r=w.useContext(Xr);Tt(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),o={...Df(e||".",{relative:t})},l=ba();if(e==null){o.search=l.search;let u=new URLSearchParams(o.search),d=u.getAll("index");if(d.some(v=>v==="")){u.delete("index"),d.filter(p=>p).forEach(p=>u.append("index",p));let v=u.toString();o.search=v?`?${v}`:""}}return(!e||e===".")&&i.route.index&&(o.search=o.search?o.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(o.pathname=o.pathname==="/"?n:Ya([n,o.pathname])),Bu(o)}function oF(e,{relative:t}={}){let n=w.useContext(K4);Tt(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=o$("useViewTransitionState"),i=Df(e,{relative:t});if(!n.isTransitioning)return!1;let o=Za(n.currentLocation.pathname,r)||n.currentLocation.pathname,l=Za(n.nextLocation.pathname,r)||n.nextLocation.pathname;return Kh(i.pathname,l)!=null||Kh(i.pathname,o)!=null}var Pf=q4();const s$=bt(Pf);/**
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 sF=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),l$=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
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
+ */var lF={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"};/**
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 cF=w.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:o,iconNode:l,...u},d)=>w.createElement("svg",{ref:d,...lF,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:l$("lucide",i),...u},[...l.map(([h,v])=>w.createElement(h,v)),...Array.isArray(o)?o:[o]]));/**
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 Te=(e,t)=>{const n=w.forwardRef(({className:r,...i},o)=>w.createElement(cF,{ref:o,iconNode:t,className:l$(`lucide-${sF(e)}`,r),...i}));return n.displayName=`${e}`,n};/**
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 Cp=Te("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/**
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 uF=Te("ArrowDownToLine",[["path",{d:"M12 17V3",key:"1cwfxf"}],["path",{d:"m6 11 6 6 6-6",key:"12ii2o"}],["path",{d:"M19 21H5",key:"150jfl"}]]);/**
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 vl=Te("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
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 fF=Te("ArrowUpFromLine",[["path",{d:"m18 9-6-6-6 6",key:"kcunyi"}],["path",{d:"M12 3v14",key:"7cf3v8"}],["path",{d:"M5 21h14",key:"11awu3"}]]);/**
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 hb=Te("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"}]]);/**
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 Ja=Te("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
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 rs=Te("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
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 dF=Te("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
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 kf=Te("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
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 hF=Te("ChevronsUpDown",[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]]);/**
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 sr=Te("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"}]]);/**
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 eo=Te("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
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 c$=Te("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
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 Vo=Te("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
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 mF=Te("CodeXml",[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]]);/**
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=Te("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
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 pF=Te("Database",[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]);/**
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 vF=Te("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"}]]);/**
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 qu=Te("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"}]]);/**
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 Uj=Te("FileImage",[["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"}],["circle",{cx:"10",cy:"12",r:"2",key:"737tya"}],["path",{d:"m20 17-1.296-1.296a2.41 2.41 0 0 0-3.408 0L9 22",key:"wt3hpn"}]]);/**
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 gF=Te("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"}]]);/**
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 Hj=Te("File",[["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"}]]);/**
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 yF=Te("Filter",[["polygon",{points:"22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3",key:"1yg77f"}]]);/**
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 u$=Te("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/**
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 Uu=Te("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"}]]);/**
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 bF=Te("Grid3x3",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M3 15h18",key:"5xshup"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]]);/**
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 $f=Te("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]]);/**
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 mb=Te("Image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]]);/**
221
+ * @license lucide-react v0.462.0 - ISC
222
+ *
223
+ * This source code is licensed under the ISC license.
224
+ * See the LICENSE file in the root directory of this source tree.
225
+ */const xF=Te("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
226
+ * @license lucide-react v0.462.0 - ISC
227
+ *
228
+ * This source code is licensed under the ISC license.
229
+ * See the LICENSE file in the root directory of this source tree.
230
+ */const wF=Te("List",[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]]);/**
231
+ * @license lucide-react v0.462.0 - ISC
232
+ *
233
+ * This source code is licensed under the ISC license.
234
+ * See the LICENSE file in the root directory of this source tree.
235
+ */const Ha=Te("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
236
+ * @license lucide-react v0.462.0 - ISC
237
+ *
238
+ * This source code is licensed under the ISC license.
239
+ * See the LICENSE file in the root directory of this source tree.
240
+ */const gl=Te("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
241
+ * @license lucide-react v0.462.0 - ISC
242
+ *
243
+ * This source code is licensed under the ISC license.
244
+ * See the LICENSE file in the root directory of this source tree.
245
+ */const Ki=Te("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
246
+ * @license lucide-react v0.462.0 - ISC
247
+ *
248
+ * This source code is licensed under the ISC license.
249
+ * See the LICENSE file in the root directory of this source tree.
250
+ */const SF=Te("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
251
+ * @license lucide-react v0.462.0 - ISC
252
+ *
253
+ * This source code is licensed under the ISC license.
254
+ * See the LICENSE file in the root directory of this source tree.
255
+ */const jF=Te("OctagonX",[["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"M2.586 16.726A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2h6.624a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586z",key:"2d38gg"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
256
+ * @license lucide-react v0.462.0 - ISC
257
+ *
258
+ * This source code is licensed under the ISC license.
259
+ * See the LICENSE file in the root directory of this source tree.
260
+ */const OF=Te("PanelLeft",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]]);/**
261
+ * @license lucide-react v0.462.0 - ISC
262
+ *
263
+ * This source code is licensed under the ISC license.
264
+ * See the LICENSE file in the root directory of this source tree.
265
+ */const eC=Te("Pen",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]]);/**
266
+ * @license lucide-react v0.462.0 - ISC
267
+ *
268
+ * This source code is licensed under the ISC license.
269
+ * See the LICENSE file in the root directory of this source tree.
270
+ */const Qh=Te("Phone",[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]]);/**
271
+ * @license lucide-react v0.462.0 - ISC
272
+ *
273
+ * This source code is licensed under the ISC license.
274
+ * See the LICENSE file in the root directory of this source tree.
275
+ */const If=Te("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
276
+ * @license lucide-react v0.462.0 - ISC
277
+ *
278
+ * This source code is licensed under the ISC license.
279
+ * See the LICENSE file in the root directory of this source tree.
280
+ */const Fj=Te("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
281
+ * @license lucide-react v0.462.0 - ISC
282
+ *
283
+ * This source code is licensed under the ISC license.
284
+ * See the LICENSE file in the root directory of this source tree.
285
+ */const pb=Te("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
286
+ * @license lucide-react v0.462.0 - ISC
287
+ *
288
+ * This source code is licensed under the ISC license.
289
+ * See the LICENSE file in the root directory of this source tree.
290
+ */const Zh=Te("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]);/**
291
+ * @license lucide-react v0.462.0 - ISC
292
+ *
293
+ * This source code is licensed under the ISC license.
294
+ * See the LICENSE file in the root directory of this source tree.
295
+ */const _F=Te("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
296
+ * @license lucide-react v0.462.0 - ISC
297
+ *
298
+ * This source code is licensed under the ISC license.
299
+ * See the LICENSE file in the root directory of this source tree.
300
+ */const f$=Te("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]);/**
301
+ * @license lucide-react v0.462.0 - ISC
302
+ *
303
+ * This source code is licensed under the ISC license.
304
+ * See the LICENSE file in the root directory of this source tree.
305
+ */const EF=Te("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"}]]);/**
306
+ * @license lucide-react v0.462.0 - ISC
307
+ *
308
+ * This source code is licensed under the ISC license.
309
+ * See the LICENSE file in the root directory of this source tree.
310
+ */const AF=Te("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
311
+ * @license lucide-react v0.462.0 - ISC
312
+ *
313
+ * This source code is licensed under the ISC license.
314
+ * See the LICENSE file in the root directory of this source tree.
315
+ */const Gj=Te("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/**
316
+ * @license lucide-react v0.462.0 - ISC
317
+ *
318
+ * This source code is licensed under the ISC license.
319
+ * See the LICENSE file in the root directory of this source tree.
320
+ */const NF=Te("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"}]]);/**
321
+ * @license lucide-react v0.462.0 - ISC
322
+ *
323
+ * This source code is licensed under the ISC license.
324
+ * See the LICENSE file in the root directory of this source tree.
325
+ */const Hu=Te("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"}]]);/**
326
+ * @license lucide-react v0.462.0 - ISC
327
+ *
328
+ * This source code is licensed under the ISC license.
329
+ * See the LICENSE file in the root directory of this source tree.
330
+ */const CF=Te("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
331
+ * @license lucide-react v0.462.0 - ISC
332
+ *
333
+ * This source code is licensed under the ISC license.
334
+ * See the LICENSE file in the root directory of this source tree.
335
+ */const TF=Te("WandSparkles",[["path",{d:"m21.64 3.64-1.28-1.28a1.21 1.21 0 0 0-1.72 0L2.36 18.64a1.21 1.21 0 0 0 0 1.72l1.28 1.28a1.2 1.2 0 0 0 1.72 0L21.64 5.36a1.2 1.2 0 0 0 0-1.72",key:"ul74o6"}],["path",{d:"m14 7 3 3",key:"1r5n42"}],["path",{d:"M5 6v4",key:"ilb8ba"}],["path",{d:"M19 14v4",key:"blhpug"}],["path",{d:"M10 2v2",key:"7u0qdc"}],["path",{d:"M7 8H3",key:"zfb6yr"}],["path",{d:"M21 16h-4",key:"1cnmox"}],["path",{d:"M11 3H9",key:"1obp7u"}]]);/**
336
+ * @license lucide-react v0.462.0 - ISC
337
+ *
338
+ * This source code is licensed under the ISC license.
339
+ * See the LICENSE file in the root directory of this source tree.
340
+ */const ir=Te("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);function d$(e,t=[]){let n=[];function r(o,l){const u=w.createContext(l);u.displayName=o+"Context";const d=n.length;n=[...n,l];const h=p=>{var _;const{scope:g,children:b,...O}=p,j=((_=g==null?void 0:g[e])==null?void 0:_[d])||u,x=w.useMemo(()=>O,Object.values(O));return c.jsx(j.Provider,{value:x,children:b})};h.displayName=o+"Provider";function v(p,g){var j;const b=((j=g==null?void 0:g[e])==null?void 0:j[d])||u,O=w.useContext(b);if(O)return O;if(l!==void 0)return l;throw new Error(`\`${p}\` must be used within \`${o}\``)}return[h,v]}const i=()=>{const o=n.map(l=>w.createContext(l));return function(u){const d=(u==null?void 0:u[e])||o;return w.useMemo(()=>({[`__scope${e}`]:{...u,[e]:d}}),[u,d])}};return i.scopeName=e,[r,MF(i,...t)]}function MF(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const l=r.reduce((u,{useScope:d,scopeName:h})=>{const p=d(o)[`__scope${h}`];return{...u,...p}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return n.scopeName=t.scopeName,n}function Yr(e){const t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}var Yt=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{};function tC(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Lf(...e){return t=>{let n=!1;const r=e.map(i=>{const o=tC(i,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let i=0;i<r.length;i++){const o=r[i];typeof o=="function"?o():tC(e[i],null)}}}}function Be(...e){return w.useCallback(Lf(...e),e)}var RF=Symbol.for("react.lazy"),Jh=Dj[" use ".trim().toString()];function DF(e){return typeof e=="object"&&e!==null&&"then"in e}function h$(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===RF&&"_payload"in e&&DF(e._payload)}function m$(e){const t=PF(e),n=w.forwardRef((r,i)=>{let{children:o,...l}=r;h$(o)&&typeof Jh=="function"&&(o=Jh(o._payload));const u=w.Children.toArray(o),d=u.find($F);if(d){const h=d.props.children,v=u.map(p=>p===d?w.Children.count(h)>1?w.Children.only(null):w.isValidElement(h)?h.props.children:null:p);return c.jsx(t,{...l,ref:i,children:w.isValidElement(h)?w.cloneElement(h,void 0,v):null})}return c.jsx(t,{...l,ref:i,children:o})});return n.displayName=`${e}.Slot`,n}var as=m$("Slot");function PF(e){const t=w.forwardRef((n,r)=>{let{children:i,...o}=n;if(h$(i)&&typeof Jh=="function"&&(i=Jh(i._payload)),w.isValidElement(i)){const l=LF(i),u=IF(o,i.props);return i.type!==w.Fragment&&(u.ref=r?Lf(r,l):l),w.cloneElement(i,u)}return w.Children.count(i)>1?w.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var kF=Symbol("radix.slottable");function $F(e){return w.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===kF}function IF(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...u)=>{const d=o(...u);return i(...u),d}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function LF(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var zF=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],is=zF.reduce((e,t)=>{const n=m$(`Primitive.${t}`),r=w.forwardRef((i,o)=>{const{asChild:l,...u}=i,d=l?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),c.jsx(d,{...u,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),vb={exports:{}},gb={};/**
341
+ * @license React
342
+ * use-sync-external-store-shim.production.js
343
+ *
344
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
345
+ *
346
+ * This source code is licensed under the MIT license found in the
347
+ * LICENSE file in the root directory of this source tree.
348
+ */var nC;function BF(){if(nC)return gb;nC=1;var e=Ep();function t(p,g){return p===g&&(p!==0||1/p===1/g)||p!==p&&g!==g}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,i=e.useEffect,o=e.useLayoutEffect,l=e.useDebugValue;function u(p,g){var b=g(),O=r({inst:{value:b,getSnapshot:g}}),j=O[0].inst,x=O[1];return o(function(){j.value=b,j.getSnapshot=g,d(j)&&x({inst:j})},[p,b,g]),i(function(){return d(j)&&x({inst:j}),p(function(){d(j)&&x({inst:j})})},[p]),l(b),b}function d(p){var g=p.getSnapshot;p=p.value;try{var b=g();return!n(p,b)}catch{return!0}}function h(p,g){return g()}var v=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?h:u;return gb.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:v,gb}var rC;function qF(){return rC||(rC=1,vb.exports=BF()),vb.exports}var UF=qF();function HF(){return UF.useSyncExternalStore(FF,()=>!0,()=>!1)}function FF(){return()=>{}}var Vj="Avatar",[GF]=d$(Vj),[VF,p$]=GF(Vj),v$=w.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[i,o]=w.useState("idle");return c.jsx(VF,{scope:n,imageLoadingStatus:i,onImageLoadingStatusChange:o,children:c.jsx(is.span,{...r,ref:t})})});v$.displayName=Vj;var g$="AvatarImage",y$=w.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:i=()=>{},...o}=e,l=p$(g$,n),u=YF(r,o),d=Yr(h=>{i(h),l.onImageLoadingStatusChange(h)});return Yt(()=>{u!=="idle"&&d(u)},[u,d]),u==="loaded"?c.jsx(is.img,{...o,ref:t,src:r}):null});y$.displayName=g$;var b$="AvatarFallback",x$=w.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...i}=e,o=p$(b$,n),[l,u]=w.useState(r===void 0);return w.useEffect(()=>{if(r!==void 0){const d=window.setTimeout(()=>u(!0),r);return()=>window.clearTimeout(d)}},[r]),l&&o.imageLoadingStatus!=="loaded"?c.jsx(is.span,{...i,ref:t}):null});x$.displayName=b$;function aC(e,t){return e?t?(e.src!==t&&(e.src=t),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function YF(e,{referrerPolicy:t,crossOrigin:n}){const r=HF(),i=w.useRef(null),o=r?(i.current||(i.current=new window.Image),i.current):null,[l,u]=w.useState(()=>aC(o,e));return Yt(()=>{u(aC(o,e))},[o,e]),Yt(()=>{const d=p=>()=>{u(p)};if(!o)return;const h=d("loaded"),v=d("error");return o.addEventListener("load",h),o.addEventListener("error",v),t&&(o.referrerPolicy=t),typeof n=="string"&&(o.crossOrigin=n),()=>{o.removeEventListener("load",h),o.removeEventListener("error",v)}},[o,n,t]),l}var WF=v$,KF=y$,XF=x$;function w$(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=w$(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function rt(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=w$(e))&&(r&&(r+=" "),r+=t);return r}const QF=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},ZF=(e,t)=>({classGroupId:e,validator:t}),S$=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),em="-",iC=[],JF="arbitrary..",e9=e=>{const t=n9(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:l=>{if(l.startsWith("[")&&l.endsWith("]"))return t9(l);const u=l.split(em),d=u[0]===""&&u.length>1?1:0;return j$(u,d,t)},getConflictingClassGroupIds:(l,u)=>{if(u){const d=r[l],h=n[l];return d?h?QF(h,d):d:h||iC}return n[l]||iC}}},j$=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],o=n.nextPart.get(i);if(o){const h=j$(e,t+1,o);if(h)return h}const l=n.validators;if(l===null)return;const u=t===0?e.join(em):e.slice(t).join(em),d=l.length;for(let h=0;h<d;h++){const v=l[h];if(v.validator(u))return v.classGroupId}},t9=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?JF+r:void 0})(),n9=e=>{const{theme:t,classGroups:n}=e;return r9(n,t)},r9=(e,t)=>{const n=S$();for(const r in e){const i=e[r];Yj(i,n,r,t)}return n},Yj=(e,t,n,r)=>{const i=e.length;for(let o=0;o<i;o++){const l=e[o];a9(l,t,n,r)}},a9=(e,t,n,r)=>{if(typeof e=="string"){i9(e,t,n);return}if(typeof e=="function"){o9(e,t,n,r);return}s9(e,t,n,r)},i9=(e,t,n)=>{const r=e===""?t:O$(t,e);r.classGroupId=n},o9=(e,t,n,r)=>{if(l9(e)){Yj(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(ZF(n,e))},s9=(e,t,n,r)=>{const i=Object.entries(e),o=i.length;for(let l=0;l<o;l++){const[u,d]=i[l];Yj(d,O$(t,u),n,r)}},O$=(e,t)=>{let n=e;const r=t.split(em),i=r.length;for(let o=0;o<i;o++){const l=r[o];let u=n.nextPart.get(l);u||(u=S$(),n.nextPart.set(l,u)),n=u}return n},l9=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,c9=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const i=(o,l)=>{n[o]=l,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(o){let l=n[o];if(l!==void 0)return l;if((l=r[o])!==void 0)return i(o,l),l},set(o,l){o in n?n[o]=l:i(o,l)}}},U1="!",oC=":",u9=[],sC=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),f9=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const o=[];let l=0,u=0,d=0,h;const v=i.length;for(let j=0;j<v;j++){const x=i[j];if(l===0&&u===0){if(x===oC){o.push(i.slice(d,j)),d=j+1;continue}if(x==="/"){h=j;continue}}x==="["?l++:x==="]"?l--:x==="("?u++:x===")"&&u--}const p=o.length===0?i:i.slice(d);let g=p,b=!1;p.endsWith(U1)?(g=p.slice(0,-1),b=!0):p.startsWith(U1)&&(g=p.slice(1),b=!0);const O=h&&h>d?h-d:void 0;return sC(o,b,g,O)};if(t){const i=t+oC,o=r;r=l=>l.startsWith(i)?o(l.slice(i.length)):sC(u9,!1,l,void 0,!0)}if(n){const i=r;r=o=>n({className:o,parseClassName:i})}return r},d9=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let i=[];for(let o=0;o<n.length;o++){const l=n[o],u=l[0]==="[",d=t.has(l);u||d?(i.length>0&&(i.sort(),r.push(...i),i=[]),r.push(l)):i.push(l)}return i.length>0&&(i.sort(),r.push(...i)),r}},h9=e=>({cache:c9(e.cacheSize),parseClassName:f9(e),sortModifiers:d9(e),...e9(e)}),m9=/\s+/,p9=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:o}=t,l=[],u=e.trim().split(m9);let d="";for(let h=u.length-1;h>=0;h-=1){const v=u[h],{isExternal:p,modifiers:g,hasImportantModifier:b,baseClassName:O,maybePostfixModifierPosition:j}=n(v);if(p){d=v+(d.length>0?" "+d:d);continue}let x=!!j,_=r(x?O.substring(0,j):O);if(!_){if(!x){d=v+(d.length>0?" "+d:d);continue}if(_=r(O),!_){d=v+(d.length>0?" "+d:d);continue}x=!1}const A=g.length===0?"":g.length===1?g[0]:o(g).join(":"),E=b?A+U1:A,C=E+_;if(l.indexOf(C)>-1)continue;l.push(C);const N=i(_,x);for(let M=0;M<N.length;++M){const R=N[M];l.push(E+R)}d=v+(d.length>0?" "+d:d)}return d},v9=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=_$(n))&&(i&&(i+=" "),i+=r);return i},_$=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=_$(e[r]))&&(n&&(n+=" "),n+=t);return n},g9=(e,...t)=>{let n,r,i,o;const l=d=>{const h=t.reduce((v,p)=>p(v),e());return n=h9(h),r=n.cache.get,i=n.cache.set,o=u,u(d)},u=d=>{const h=r(d);if(h)return h;const v=p9(d,n);return i(d,v),v};return o=l,(...d)=>o(v9(...d))},y9=[],Kt=e=>{const t=n=>n[e]||y9;return t.isThemeGetter=!0,t},E$=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,A$=/^\((?:(\w[\w-]*):)?(.+)\)$/i,b9=/^\d+\/\d+$/,x9=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,w9=/\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$/,S9=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,j9=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,O9=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,nl=e=>b9.test(e),Ve=e=>!!e&&!Number.isNaN(Number(e)),Li=e=>!!e&&Number.isInteger(Number(e)),yb=e=>e.endsWith("%")&&Ve(e.slice(0,-1)),qa=e=>x9.test(e),_9=()=>!0,E9=e=>w9.test(e)&&!S9.test(e),N$=()=>!1,A9=e=>j9.test(e),N9=e=>O9.test(e),C9=e=>!je(e)&&!Oe(e),T9=e=>Jl(e,M$,N$),je=e=>E$.test(e),Do=e=>Jl(e,R$,E9),bb=e=>Jl(e,k9,Ve),lC=e=>Jl(e,C$,N$),M9=e=>Jl(e,T$,N9),vh=e=>Jl(e,D$,A9),Oe=e=>A$.test(e),vu=e=>ec(e,R$),R9=e=>ec(e,$9),cC=e=>ec(e,C$),D9=e=>ec(e,M$),P9=e=>ec(e,T$),gh=e=>ec(e,D$,!0),Jl=(e,t,n)=>{const r=E$.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},ec=(e,t,n=!1)=>{const r=A$.exec(e);return r?r[1]?t(r[1]):n:!1},C$=e=>e==="position"||e==="percentage",T$=e=>e==="image"||e==="url",M$=e=>e==="length"||e==="size"||e==="bg-size",R$=e=>e==="length",k9=e=>e==="number",$9=e=>e==="family-name",D$=e=>e==="shadow",I9=()=>{const e=Kt("color"),t=Kt("font"),n=Kt("text"),r=Kt("font-weight"),i=Kt("tracking"),o=Kt("leading"),l=Kt("breakpoint"),u=Kt("container"),d=Kt("spacing"),h=Kt("radius"),v=Kt("shadow"),p=Kt("inset-shadow"),g=Kt("text-shadow"),b=Kt("drop-shadow"),O=Kt("blur"),j=Kt("perspective"),x=Kt("aspect"),_=Kt("ease"),A=Kt("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],C=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],N=()=>[...C(),Oe,je],M=()=>["auto","hidden","clip","visible","scroll"],R=()=>["auto","contain","none"],D=()=>[Oe,je,d],z=()=>[nl,"full","auto",...D()],Y=()=>[Li,"none","subgrid",Oe,je],L=()=>["auto",{span:["full",Li,Oe,je]},Li,Oe,je],F=()=>[Li,"auto",Oe,je],W=()=>["auto","min","max","fr",Oe,je],Q=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],X=()=>["start","end","center","stretch","center-safe","end-safe"],k=()=>["auto",...D()],H=()=>[nl,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...D()],B=()=>[e,Oe,je],Z=()=>[...C(),cC,lC,{position:[Oe,je]}],le=()=>["no-repeat",{repeat:["","x","y","space","round"]}],$=()=>["auto","cover","contain",D9,T9,{size:[Oe,je]}],V=()=>[yb,vu,Do],q=()=>["","none","full",h,Oe,je],U=()=>["",Ve,vu,Do],ne=()=>["solid","dashed","dotted","double"],fe=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],ie=()=>[Ve,yb,cC,lC],pe=()=>["","none",O,Oe,je],re=()=>["none",Ve,Oe,je],ve=()=>["none",Ve,Oe,je],ge=()=>[Ve,Oe,je],oe=()=>[nl,"full",...D()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[qa],breakpoint:[qa],color:[_9],container:[qa],"drop-shadow":[qa],ease:["in","out","in-out"],font:[C9],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[qa],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[qa],shadow:[qa],spacing:["px",Ve],text:[qa],"text-shadow":[qa],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",nl,je,Oe,x]}],container:["container"],columns:[{columns:[Ve,je,Oe,u]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:N()}],overflow:[{overflow:M()}],"overflow-x":[{"overflow-x":M()}],"overflow-y":[{"overflow-y":M()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:z()}],"inset-x":[{"inset-x":z()}],"inset-y":[{"inset-y":z()}],start:[{start:z()}],end:[{end:z()}],top:[{top:z()}],right:[{right:z()}],bottom:[{bottom:z()}],left:[{left:z()}],visibility:["visible","invisible","collapse"],z:[{z:[Li,"auto",Oe,je]}],basis:[{basis:[nl,"full","auto",u,...D()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Ve,nl,"auto","initial","none",je]}],grow:[{grow:["",Ve,Oe,je]}],shrink:[{shrink:["",Ve,Oe,je]}],order:[{order:[Li,"first","last","none",Oe,je]}],"grid-cols":[{"grid-cols":Y()}],"col-start-end":[{col:L()}],"col-start":[{"col-start":F()}],"col-end":[{"col-end":F()}],"grid-rows":[{"grid-rows":Y()}],"row-start-end":[{row:L()}],"row-start":[{"row-start":F()}],"row-end":[{"row-end":F()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":W()}],"auto-rows":[{"auto-rows":W()}],gap:[{gap:D()}],"gap-x":[{"gap-x":D()}],"gap-y":[{"gap-y":D()}],"justify-content":[{justify:[...Q(),"normal"]}],"justify-items":[{"justify-items":[...X(),"normal"]}],"justify-self":[{"justify-self":["auto",...X()]}],"align-content":[{content:["normal",...Q()]}],"align-items":[{items:[...X(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...X(),{baseline:["","last"]}]}],"place-content":[{"place-content":Q()}],"place-items":[{"place-items":[...X(),"baseline"]}],"place-self":[{"place-self":["auto",...X()]}],p:[{p:D()}],px:[{px:D()}],py:[{py:D()}],ps:[{ps:D()}],pe:[{pe:D()}],pt:[{pt:D()}],pr:[{pr:D()}],pb:[{pb:D()}],pl:[{pl:D()}],m:[{m:k()}],mx:[{mx:k()}],my:[{my:k()}],ms:[{ms:k()}],me:[{me:k()}],mt:[{mt:k()}],mr:[{mr:k()}],mb:[{mb:k()}],ml:[{ml:k()}],"space-x":[{"space-x":D()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":D()}],"space-y-reverse":["space-y-reverse"],size:[{size:H()}],w:[{w:[u,"screen",...H()]}],"min-w":[{"min-w":[u,"screen","none",...H()]}],"max-w":[{"max-w":[u,"screen","none","prose",{screen:[l]},...H()]}],h:[{h:["screen","lh",...H()]}],"min-h":[{"min-h":["screen","lh","none",...H()]}],"max-h":[{"max-h":["screen","lh",...H()]}],"font-size":[{text:["base",n,vu,Do]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,Oe,bb]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",yb,je]}],"font-family":[{font:[R9,je,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,Oe,je]}],"line-clamp":[{"line-clamp":[Ve,"none",Oe,bb]}],leading:[{leading:[o,...D()]}],"list-image":[{"list-image":["none",Oe,je]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Oe,je]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:B()}],"text-color":[{text:B()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ne(),"wavy"]}],"text-decoration-thickness":[{decoration:[Ve,"from-font","auto",Oe,Do]}],"text-decoration-color":[{decoration:B()}],"underline-offset":[{"underline-offset":[Ve,"auto",Oe,je]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:D()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Oe,je]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Oe,je]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:Z()}],"bg-repeat":[{bg:le()}],"bg-size":[{bg:$()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Li,Oe,je],radial:["",Oe,je],conic:[Li,Oe,je]},P9,M9]}],"bg-color":[{bg:B()}],"gradient-from-pos":[{from:V()}],"gradient-via-pos":[{via:V()}],"gradient-to-pos":[{to:V()}],"gradient-from":[{from:B()}],"gradient-via":[{via:B()}],"gradient-to":[{to:B()}],rounded:[{rounded:q()}],"rounded-s":[{"rounded-s":q()}],"rounded-e":[{"rounded-e":q()}],"rounded-t":[{"rounded-t":q()}],"rounded-r":[{"rounded-r":q()}],"rounded-b":[{"rounded-b":q()}],"rounded-l":[{"rounded-l":q()}],"rounded-ss":[{"rounded-ss":q()}],"rounded-se":[{"rounded-se":q()}],"rounded-ee":[{"rounded-ee":q()}],"rounded-es":[{"rounded-es":q()}],"rounded-tl":[{"rounded-tl":q()}],"rounded-tr":[{"rounded-tr":q()}],"rounded-br":[{"rounded-br":q()}],"rounded-bl":[{"rounded-bl":q()}],"border-w":[{border:U()}],"border-w-x":[{"border-x":U()}],"border-w-y":[{"border-y":U()}],"border-w-s":[{"border-s":U()}],"border-w-e":[{"border-e":U()}],"border-w-t":[{"border-t":U()}],"border-w-r":[{"border-r":U()}],"border-w-b":[{"border-b":U()}],"border-w-l":[{"border-l":U()}],"divide-x":[{"divide-x":U()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":U()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ne(),"hidden","none"]}],"divide-style":[{divide:[...ne(),"hidden","none"]}],"border-color":[{border:B()}],"border-color-x":[{"border-x":B()}],"border-color-y":[{"border-y":B()}],"border-color-s":[{"border-s":B()}],"border-color-e":[{"border-e":B()}],"border-color-t":[{"border-t":B()}],"border-color-r":[{"border-r":B()}],"border-color-b":[{"border-b":B()}],"border-color-l":[{"border-l":B()}],"divide-color":[{divide:B()}],"outline-style":[{outline:[...ne(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Ve,Oe,je]}],"outline-w":[{outline:["",Ve,vu,Do]}],"outline-color":[{outline:B()}],shadow:[{shadow:["","none",v,gh,vh]}],"shadow-color":[{shadow:B()}],"inset-shadow":[{"inset-shadow":["none",p,gh,vh]}],"inset-shadow-color":[{"inset-shadow":B()}],"ring-w":[{ring:U()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:B()}],"ring-offset-w":[{"ring-offset":[Ve,Do]}],"ring-offset-color":[{"ring-offset":B()}],"inset-ring-w":[{"inset-ring":U()}],"inset-ring-color":[{"inset-ring":B()}],"text-shadow":[{"text-shadow":["none",g,gh,vh]}],"text-shadow-color":[{"text-shadow":B()}],opacity:[{opacity:[Ve,Oe,je]}],"mix-blend":[{"mix-blend":[...fe(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":fe()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[Ve]}],"mask-image-linear-from-pos":[{"mask-linear-from":ie()}],"mask-image-linear-to-pos":[{"mask-linear-to":ie()}],"mask-image-linear-from-color":[{"mask-linear-from":B()}],"mask-image-linear-to-color":[{"mask-linear-to":B()}],"mask-image-t-from-pos":[{"mask-t-from":ie()}],"mask-image-t-to-pos":[{"mask-t-to":ie()}],"mask-image-t-from-color":[{"mask-t-from":B()}],"mask-image-t-to-color":[{"mask-t-to":B()}],"mask-image-r-from-pos":[{"mask-r-from":ie()}],"mask-image-r-to-pos":[{"mask-r-to":ie()}],"mask-image-r-from-color":[{"mask-r-from":B()}],"mask-image-r-to-color":[{"mask-r-to":B()}],"mask-image-b-from-pos":[{"mask-b-from":ie()}],"mask-image-b-to-pos":[{"mask-b-to":ie()}],"mask-image-b-from-color":[{"mask-b-from":B()}],"mask-image-b-to-color":[{"mask-b-to":B()}],"mask-image-l-from-pos":[{"mask-l-from":ie()}],"mask-image-l-to-pos":[{"mask-l-to":ie()}],"mask-image-l-from-color":[{"mask-l-from":B()}],"mask-image-l-to-color":[{"mask-l-to":B()}],"mask-image-x-from-pos":[{"mask-x-from":ie()}],"mask-image-x-to-pos":[{"mask-x-to":ie()}],"mask-image-x-from-color":[{"mask-x-from":B()}],"mask-image-x-to-color":[{"mask-x-to":B()}],"mask-image-y-from-pos":[{"mask-y-from":ie()}],"mask-image-y-to-pos":[{"mask-y-to":ie()}],"mask-image-y-from-color":[{"mask-y-from":B()}],"mask-image-y-to-color":[{"mask-y-to":B()}],"mask-image-radial":[{"mask-radial":[Oe,je]}],"mask-image-radial-from-pos":[{"mask-radial-from":ie()}],"mask-image-radial-to-pos":[{"mask-radial-to":ie()}],"mask-image-radial-from-color":[{"mask-radial-from":B()}],"mask-image-radial-to-color":[{"mask-radial-to":B()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":C()}],"mask-image-conic-pos":[{"mask-conic":[Ve]}],"mask-image-conic-from-pos":[{"mask-conic-from":ie()}],"mask-image-conic-to-pos":[{"mask-conic-to":ie()}],"mask-image-conic-from-color":[{"mask-conic-from":B()}],"mask-image-conic-to-color":[{"mask-conic-to":B()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:Z()}],"mask-repeat":[{mask:le()}],"mask-size":[{mask:$()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",Oe,je]}],filter:[{filter:["","none",Oe,je]}],blur:[{blur:pe()}],brightness:[{brightness:[Ve,Oe,je]}],contrast:[{contrast:[Ve,Oe,je]}],"drop-shadow":[{"drop-shadow":["","none",b,gh,vh]}],"drop-shadow-color":[{"drop-shadow":B()}],grayscale:[{grayscale:["",Ve,Oe,je]}],"hue-rotate":[{"hue-rotate":[Ve,Oe,je]}],invert:[{invert:["",Ve,Oe,je]}],saturate:[{saturate:[Ve,Oe,je]}],sepia:[{sepia:["",Ve,Oe,je]}],"backdrop-filter":[{"backdrop-filter":["","none",Oe,je]}],"backdrop-blur":[{"backdrop-blur":pe()}],"backdrop-brightness":[{"backdrop-brightness":[Ve,Oe,je]}],"backdrop-contrast":[{"backdrop-contrast":[Ve,Oe,je]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Ve,Oe,je]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Ve,Oe,je]}],"backdrop-invert":[{"backdrop-invert":["",Ve,Oe,je]}],"backdrop-opacity":[{"backdrop-opacity":[Ve,Oe,je]}],"backdrop-saturate":[{"backdrop-saturate":[Ve,Oe,je]}],"backdrop-sepia":[{"backdrop-sepia":["",Ve,Oe,je]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":D()}],"border-spacing-x":[{"border-spacing-x":D()}],"border-spacing-y":[{"border-spacing-y":D()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",Oe,je]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Ve,"initial",Oe,je]}],ease:[{ease:["linear","initial",_,Oe,je]}],delay:[{delay:[Ve,Oe,je]}],animate:[{animate:["none",A,Oe,je]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[j,Oe,je]}],"perspective-origin":[{"perspective-origin":N()}],rotate:[{rotate:re()}],"rotate-x":[{"rotate-x":re()}],"rotate-y":[{"rotate-y":re()}],"rotate-z":[{"rotate-z":re()}],scale:[{scale:ve()}],"scale-x":[{"scale-x":ve()}],"scale-y":[{"scale-y":ve()}],"scale-z":[{"scale-z":ve()}],"scale-3d":["scale-3d"],skew:[{skew:ge()}],"skew-x":[{"skew-x":ge()}],"skew-y":[{"skew-y":ge()}],transform:[{transform:[Oe,je,"","none","gpu","cpu"]}],"transform-origin":[{origin:N()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:oe()}],"translate-x":[{"translate-x":oe()}],"translate-y":[{"translate-y":oe()}],"translate-z":[{"translate-z":oe()}],"translate-none":["translate-none"],accent:[{accent:B()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:B()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Oe,je]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":D()}],"scroll-mx":[{"scroll-mx":D()}],"scroll-my":[{"scroll-my":D()}],"scroll-ms":[{"scroll-ms":D()}],"scroll-me":[{"scroll-me":D()}],"scroll-mt":[{"scroll-mt":D()}],"scroll-mr":[{"scroll-mr":D()}],"scroll-mb":[{"scroll-mb":D()}],"scroll-ml":[{"scroll-ml":D()}],"scroll-p":[{"scroll-p":D()}],"scroll-px":[{"scroll-px":D()}],"scroll-py":[{"scroll-py":D()}],"scroll-ps":[{"scroll-ps":D()}],"scroll-pe":[{"scroll-pe":D()}],"scroll-pt":[{"scroll-pt":D()}],"scroll-pr":[{"scroll-pr":D()}],"scroll-pb":[{"scroll-pb":D()}],"scroll-pl":[{"scroll-pl":D()}],"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",Oe,je]}],fill:[{fill:["none",...B()]}],"stroke-w":[{stroke:[Ve,vu,Do,bb]}],stroke:[{stroke:["none",...B()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","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-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},L9=g9(I9);function me(...e){return L9(rt(e))}function uC({className:e,...t}){return c.jsx(WF,{className:me("relative flex size-8 shrink-0 overflow-hidden rounded-full",e),"data-slot":"avatar",...t})}function fC({className:e,...t}){return c.jsx(KF,{className:me("aspect-square size-full",e),"data-slot":"avatar-image",...t})}function dC({className:e,...t}){return c.jsx(XF,{className:me("flex size-full items-center justify-center rounded-full bg-muted",e),"data-slot":"avatar-fallback",...t})}function ye(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function z9(e,t){const n=w.createContext(t),r=o=>{const{children:l,...u}=o,d=w.useMemo(()=>u,Object.values(u));return c.jsx(n.Provider,{value:d,children:l})};r.displayName=e+"Provider";function i(o){const l=w.useContext(n);if(l)return l;if(t!==void 0)return t;throw new Error(`\`${o}\` must be used within \`${e}\``)}return[r,i]}function jn(e,t=[]){let n=[];function r(o,l){const u=w.createContext(l),d=n.length;n=[...n,l];const h=p=>{var _;const{scope:g,children:b,...O}=p,j=((_=g==null?void 0:g[e])==null?void 0:_[d])||u,x=w.useMemo(()=>O,Object.values(O));return c.jsx(j.Provider,{value:x,children:b})};h.displayName=o+"Provider";function v(p,g){var j;const b=((j=g==null?void 0:g[e])==null?void 0:j[d])||u,O=w.useContext(b);if(O)return O;if(l!==void 0)return l;throw new Error(`\`${p}\` must be used within \`${o}\``)}return[h,v]}const i=()=>{const o=n.map(l=>w.createContext(l));return function(u){const d=(u==null?void 0:u[e])||o;return w.useMemo(()=>({[`__scope${e}`]:{...u,[e]:d}}),[u,d])}};return i.scopeName=e,[r,B9(i,...t)]}function B9(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const l=r.reduce((u,{useScope:d,scopeName:h})=>{const p=d(o)[`__scope${h}`];return{...u,...p}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return n.scopeName=t.scopeName,n}var q9=Dj[" useInsertionEffect ".trim().toString()]||Yt;function An({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[i,o,l]=U9({defaultProp:t,onChange:n}),u=e!==void 0,d=u?e:i;{const v=w.useRef(e!==void 0);w.useEffect(()=>{const p=v.current;p!==u&&console.warn(`${r} is changing from ${p?"controlled":"uncontrolled"} to ${u?"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.`),v.current=u},[u,r])}const h=w.useCallback(v=>{var p;if(u){const g=H9(v)?v(e):v;g!==e&&((p=l.current)==null||p.call(l,g))}else o(v)},[u,e,o,l]);return[d,h]}function U9({defaultProp:e,onChange:t}){const[n,r]=w.useState(e),i=w.useRef(n),o=w.useRef(t);return q9(()=>{o.current=t},[t]),w.useEffect(()=>{var l;i.current!==n&&((l=o.current)==null||l.call(o,n),i.current=n)},[n,i]),[n,r,o]}function H9(e){return typeof e=="function"}function Ol(e){const t=F9(e),n=w.forwardRef((r,i)=>{const{children:o,...l}=r,u=w.Children.toArray(o),d=u.find(G9);if(d){const h=d.props.children,v=u.map(p=>p===d?w.Children.count(h)>1?w.Children.only(null):w.isValidElement(h)?h.props.children:null:p);return c.jsx(t,{...l,ref:i,children:w.isValidElement(h)?w.cloneElement(h,void 0,v):null})}return c.jsx(t,{...l,ref:i,children:o})});return n.displayName=`${e}.Slot`,n}function F9(e){const t=w.forwardRef((n,r)=>{const{children:i,...o}=n;if(w.isValidElement(i)){const l=Y9(i),u=V9(o,i.props);return i.type!==w.Fragment&&(u.ref=r?Lf(r,l):l),w.cloneElement(i,u)}return w.Children.count(i)>1?w.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var P$=Symbol("radix.slottable");function k$(e){const t=({children:n})=>c.jsx(c.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=P$,t}function G9(e){return w.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===P$}function V9(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...u)=>{const d=o(...u);return i(...u),d}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function Y9(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var W9=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ee=W9.reduce((e,t)=>{const n=Ol(`Primitive.${t}`),r=w.forwardRef((i,o)=>{const{asChild:l,...u}=i,d=l?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),c.jsx(d,{...u,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function $$(e,t){e&&Pf.flushSync(()=>e.dispatchEvent(t))}function Tp(e){const t=e+"CollectionProvider",[n,r]=jn(t),[i,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),l=j=>{const{scope:x,children:_}=j,A=I.useRef(null),E=I.useRef(new Map).current;return c.jsx(i,{scope:x,itemMap:E,collectionRef:A,children:_})};l.displayName=t;const u=e+"CollectionSlot",d=Ol(u),h=I.forwardRef((j,x)=>{const{scope:_,children:A}=j,E=o(u,_),C=Be(x,E.collectionRef);return c.jsx(d,{ref:C,children:A})});h.displayName=u;const v=e+"CollectionItemSlot",p="data-radix-collection-item",g=Ol(v),b=I.forwardRef((j,x)=>{const{scope:_,children:A,...E}=j,C=I.useRef(null),N=Be(x,C),M=o(v,_);return I.useEffect(()=>(M.itemMap.set(C,{ref:C,...E}),()=>void M.itemMap.delete(C))),c.jsx(g,{[p]:"",ref:N,children:A})});b.displayName=v;function O(j){const x=o(e+"CollectionConsumer",j);return I.useCallback(()=>{const A=x.collectionRef.current;if(!A)return[];const E=Array.from(A.querySelectorAll(`[${p}]`));return Array.from(x.itemMap.values()).sort((M,R)=>E.indexOf(M.ref.current)-E.indexOf(R.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:l,Slot:h,ItemSlot:b},O,r]}var K9=w.createContext(void 0);function tc(e){const t=w.useContext(K9);return e||t||"ltr"}function X9(e,t=globalThis==null?void 0:globalThis.document){const n=Yr(e);w.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var Q9="DismissableLayer",H1="dismissableLayer.update",Z9="dismissableLayer.pointerDownOutside",J9="dismissableLayer.focusOutside",hC,I$=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),nc=w.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:l,onDismiss:u,...d}=e,h=w.useContext(I$),[v,p]=w.useState(null),g=(v==null?void 0:v.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,b]=w.useState({}),O=Be(t,R=>p(R)),j=Array.from(h.layers),[x]=[...h.layersWithOutsidePointerEventsDisabled].slice(-1),_=j.indexOf(x),A=v?j.indexOf(v):-1,E=h.layersWithOutsidePointerEventsDisabled.size>0,C=A>=_,N=n7(R=>{const D=R.target,z=[...h.branches].some(Y=>Y.contains(D));!C||z||(i==null||i(R),l==null||l(R),R.defaultPrevented||u==null||u())},g),M=r7(R=>{const D=R.target;[...h.branches].some(Y=>Y.contains(D))||(o==null||o(R),l==null||l(R),R.defaultPrevented||u==null||u())},g);return X9(R=>{A===h.layers.size-1&&(r==null||r(R),!R.defaultPrevented&&u&&(R.preventDefault(),u()))},g),w.useEffect(()=>{if(v)return n&&(h.layersWithOutsidePointerEventsDisabled.size===0&&(hC=g.body.style.pointerEvents,g.body.style.pointerEvents="none"),h.layersWithOutsidePointerEventsDisabled.add(v)),h.layers.add(v),mC(),()=>{n&&h.layersWithOutsidePointerEventsDisabled.size===1&&(g.body.style.pointerEvents=hC)}},[v,g,n,h]),w.useEffect(()=>()=>{v&&(h.layers.delete(v),h.layersWithOutsidePointerEventsDisabled.delete(v),mC())},[v,h]),w.useEffect(()=>{const R=()=>b({});return document.addEventListener(H1,R),()=>document.removeEventListener(H1,R)},[]),c.jsx(Ee.div,{...d,ref:O,style:{pointerEvents:E?C?"auto":"none":void 0,...e.style},onFocusCapture:ye(e.onFocusCapture,M.onFocusCapture),onBlurCapture:ye(e.onBlurCapture,M.onBlurCapture),onPointerDownCapture:ye(e.onPointerDownCapture,N.onPointerDownCapture)})});nc.displayName=Q9;var e7="DismissableLayerBranch",t7=w.forwardRef((e,t)=>{const n=w.useContext(I$),r=w.useRef(null),i=Be(t,r);return w.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),c.jsx(Ee.div,{...e,ref:i})});t7.displayName=e7;function n7(e,t=globalThis==null?void 0:globalThis.document){const n=Yr(e),r=w.useRef(!1),i=w.useRef(()=>{});return w.useEffect(()=>{const o=u=>{if(u.target&&!r.current){let d=function(){L$(Z9,n,h,{discrete:!0})};const h={originalEvent:u};u.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=d,t.addEventListener("click",i.current,{once:!0})):d()}else t.removeEventListener("click",i.current);r.current=!1},l=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(l),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function r7(e,t=globalThis==null?void 0:globalThis.document){const n=Yr(e),r=w.useRef(!1);return w.useEffect(()=>{const i=o=>{o.target&&!r.current&&L$(J9,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function mC(){const e=new CustomEvent(H1);document.dispatchEvent(e)}function L$(e,t,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?$$(i,o):i.dispatchEvent(o)}var xb=0;function Wj(){w.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??pC()),document.body.insertAdjacentElement("beforeend",e[1]??pC()),xb++,()=>{xb===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),xb--}},[])}function pC(){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 wb="focusScope.autoFocusOnMount",Sb="focusScope.autoFocusOnUnmount",vC={bubbles:!1,cancelable:!0},a7="FocusScope",Mp=w.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...l}=e,[u,d]=w.useState(null),h=Yr(i),v=Yr(o),p=w.useRef(null),g=Be(t,j=>d(j)),b=w.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;w.useEffect(()=>{if(r){let j=function(E){if(b.paused||!u)return;const C=E.target;u.contains(C)?p.current=C:qi(p.current,{select:!0})},x=function(E){if(b.paused||!u)return;const C=E.relatedTarget;C!==null&&(u.contains(C)||qi(p.current,{select:!0}))},_=function(E){if(document.activeElement===document.body)for(const N of E)N.removedNodes.length>0&&qi(u)};document.addEventListener("focusin",j),document.addEventListener("focusout",x);const A=new MutationObserver(_);return u&&A.observe(u,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",j),document.removeEventListener("focusout",x),A.disconnect()}}},[r,u,b.paused]),w.useEffect(()=>{if(u){yC.add(b);const j=document.activeElement;if(!u.contains(j)){const _=new CustomEvent(wb,vC);u.addEventListener(wb,h),u.dispatchEvent(_),_.defaultPrevented||(i7(u7(z$(u)),{select:!0}),document.activeElement===j&&qi(u))}return()=>{u.removeEventListener(wb,h),setTimeout(()=>{const _=new CustomEvent(Sb,vC);u.addEventListener(Sb,v),u.dispatchEvent(_),_.defaultPrevented||qi(j??document.body,{select:!0}),u.removeEventListener(Sb,v),yC.remove(b)},0)}}},[u,h,v,b]);const O=w.useCallback(j=>{if(!n&&!r||b.paused)return;const x=j.key==="Tab"&&!j.altKey&&!j.ctrlKey&&!j.metaKey,_=document.activeElement;if(x&&_){const A=j.currentTarget,[E,C]=o7(A);E&&C?!j.shiftKey&&_===C?(j.preventDefault(),n&&qi(E,{select:!0})):j.shiftKey&&_===E&&(j.preventDefault(),n&&qi(C,{select:!0})):_===A&&j.preventDefault()}},[n,r,b.paused]);return c.jsx(Ee.div,{tabIndex:-1,...l,ref:g,onKeyDown:O})});Mp.displayName=a7;function i7(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(qi(r,{select:t}),document.activeElement!==n)return}function o7(e){const t=z$(e),n=gC(t,e),r=gC(t.reverse(),e);return[n,r]}function z$(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function gC(e,t){for(const n of e)if(!s7(n,{upTo:t}))return n}function s7(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 l7(e){return e instanceof HTMLInputElement&&"select"in e}function qi(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&l7(e)&&t&&e.select()}}var yC=c7();function c7(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=bC(e,t),e.unshift(t)},remove(t){var n;e=bC(e,t),(n=e[0])==null||n.resume()}}}function bC(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function u7(e){return e.filter(t=>t.tagName!=="A")}var f7=Dj[" useId ".trim().toString()]||(()=>{}),d7=0;function Nr(e){const[t,n]=w.useState(f7());return Yt(()=>{n(r=>r??String(d7++))},[e]),e||(t?`radix-${t}`:"")}const h7=["top","right","bottom","left"],Xi=Math.min,rr=Math.max,tm=Math.round,yh=Math.floor,ua=e=>({x:e,y:e}),m7={left:"right",right:"left",bottom:"top",top:"bottom"},p7={start:"end",end:"start"};function F1(e,t,n){return rr(e,Xi(t,n))}function ei(e,t){return typeof e=="function"?e(t):e}function ti(e){return e.split("-")[0]}function rc(e){return e.split("-")[1]}function Kj(e){return e==="x"?"y":"x"}function Xj(e){return e==="y"?"height":"width"}const v7=new Set(["top","bottom"]);function sa(e){return v7.has(ti(e))?"y":"x"}function Qj(e){return Kj(sa(e))}function g7(e,t,n){n===void 0&&(n=!1);const r=rc(e),i=Qj(e),o=Xj(i);let l=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(l=nm(l)),[l,nm(l)]}function y7(e){const t=nm(e);return[G1(e),t,G1(t)]}function G1(e){return e.replace(/start|end/g,t=>p7[t])}const xC=["left","right"],wC=["right","left"],b7=["top","bottom"],x7=["bottom","top"];function w7(e,t,n){switch(e){case"top":case"bottom":return n?t?wC:xC:t?xC:wC;case"left":case"right":return t?b7:x7;default:return[]}}function S7(e,t,n,r){const i=rc(e);let o=w7(ti(e),n==="start",r);return i&&(o=o.map(l=>l+"-"+i),t&&(o=o.concat(o.map(G1)))),o}function nm(e){return e.replace(/left|right|bottom|top/g,t=>m7[t])}function j7(e){return{top:0,right:0,bottom:0,left:0,...e}}function B$(e){return typeof e!="number"?j7(e):{top:e,right:e,bottom:e,left:e}}function rm(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function SC(e,t,n){let{reference:r,floating:i}=e;const o=sa(t),l=Qj(t),u=Xj(l),d=ti(t),h=o==="y",v=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,g=r[u]/2-i[u]/2;let b;switch(d){case"top":b={x:v,y:r.y-i.height};break;case"bottom":b={x:v,y:r.y+r.height};break;case"right":b={x:r.x+r.width,y:p};break;case"left":b={x:r.x-i.width,y:p};break;default:b={x:r.x,y:r.y}}switch(rc(t)){case"start":b[l]-=g*(n&&h?-1:1);break;case"end":b[l]+=g*(n&&h?-1:1);break}return b}const O7=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:l}=n,u=o.filter(Boolean),d=await(l.isRTL==null?void 0:l.isRTL(t));let h=await l.getElementRects({reference:e,floating:t,strategy:i}),{x:v,y:p}=SC(h,r,d),g=r,b={},O=0;for(let j=0;j<u.length;j++){const{name:x,fn:_}=u[j],{x:A,y:E,data:C,reset:N}=await _({x:v,y:p,initialPlacement:r,placement:g,strategy:i,middlewareData:b,rects:h,platform:l,elements:{reference:e,floating:t}});v=A??v,p=E??p,b={...b,[x]:{...b[x],...C}},N&&O<=50&&(O++,typeof N=="object"&&(N.placement&&(g=N.placement),N.rects&&(h=N.rects===!0?await l.getElementRects({reference:e,floating:t,strategy:i}):N.rects),{x:v,y:p}=SC(h,g,d)),j=-1)}return{x:v,y:p,placement:g,strategy:i,middlewareData:b}};async function Fu(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:l,elements:u,strategy:d}=e,{boundary:h="clippingAncestors",rootBoundary:v="viewport",elementContext:p="floating",altBoundary:g=!1,padding:b=0}=ei(t,e),O=B$(b),x=u[g?p==="floating"?"reference":"floating":p],_=rm(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(x)))==null||n?x:x.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(u.floating)),boundary:h,rootBoundary:v,strategy:d})),A=p==="floating"?{x:r,y:i,width:l.floating.width,height:l.floating.height}:l.reference,E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u.floating)),C=await(o.isElement==null?void 0:o.isElement(E))?await(o.getScale==null?void 0:o.getScale(E))||{x:1,y:1}:{x:1,y:1},N=rm(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:A,offsetParent:E,strategy:d}):A);return{top:(_.top-N.top+O.top)/C.y,bottom:(N.bottom-_.bottom+O.bottom)/C.y,left:(_.left-N.left+O.left)/C.x,right:(N.right-_.right+O.right)/C.x}}const _7=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:l,elements:u,middlewareData:d}=t,{element:h,padding:v=0}=ei(e,t)||{};if(h==null)return{};const p=B$(v),g={x:n,y:r},b=Qj(i),O=Xj(b),j=await l.getDimensions(h),x=b==="y",_=x?"top":"left",A=x?"bottom":"right",E=x?"clientHeight":"clientWidth",C=o.reference[O]+o.reference[b]-g[b]-o.floating[O],N=g[b]-o.reference[b],M=await(l.getOffsetParent==null?void 0:l.getOffsetParent(h));let R=M?M[E]:0;(!R||!await(l.isElement==null?void 0:l.isElement(M)))&&(R=u.floating[E]||o.floating[O]);const D=C/2-N/2,z=R/2-j[O]/2-1,Y=Xi(p[_],z),L=Xi(p[A],z),F=Y,W=R-j[O]-L,Q=R/2-j[O]/2+D,X=F1(F,Q,W),k=!d.arrow&&rc(i)!=null&&Q!==X&&o.reference[O]/2-(Q<F?Y:L)-j[O]/2<0,H=k?Q<F?Q-F:Q-W:0;return{[b]:g[b]+H,data:{[b]:X,centerOffset:Q-X-H,...k&&{alignmentOffset:H}},reset:k}}}),E7=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:l,initialPlacement:u,platform:d,elements:h}=t,{mainAxis:v=!0,crossAxis:p=!0,fallbackPlacements:g,fallbackStrategy:b="bestFit",fallbackAxisSideDirection:O="none",flipAlignment:j=!0,...x}=ei(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const _=ti(i),A=sa(u),E=ti(u)===u,C=await(d.isRTL==null?void 0:d.isRTL(h.floating)),N=g||(E||!j?[nm(u)]:y7(u)),M=O!=="none";!g&&M&&N.push(...S7(u,j,O,C));const R=[u,...N],D=await Fu(t,x),z=[];let Y=((r=o.flip)==null?void 0:r.overflows)||[];if(v&&z.push(D[_]),p){const Q=g7(i,l,C);z.push(D[Q[0]],D[Q[1]])}if(Y=[...Y,{placement:i,overflows:z}],!z.every(Q=>Q<=0)){var L,F;const Q=(((L=o.flip)==null?void 0:L.index)||0)+1,X=R[Q];if(X&&(!(p==="alignment"?A!==sa(X):!1)||Y.every(B=>sa(B.placement)===A?B.overflows[0]>0:!0)))return{data:{index:Q,overflows:Y},reset:{placement:X}};let k=(F=Y.filter(H=>H.overflows[0]<=0).sort((H,B)=>H.overflows[1]-B.overflows[1])[0])==null?void 0:F.placement;if(!k)switch(b){case"bestFit":{var W;const H=(W=Y.filter(B=>{if(M){const Z=sa(B.placement);return Z===A||Z==="y"}return!0}).map(B=>[B.placement,B.overflows.filter(Z=>Z>0).reduce((Z,le)=>Z+le,0)]).sort((B,Z)=>B[1]-Z[1])[0])==null?void 0:W[0];H&&(k=H);break}case"initialPlacement":k=u;break}if(i!==k)return{reset:{placement:k}}}return{}}}};function jC(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function OC(e){return h7.some(t=>e[t]>=0)}const A7=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...i}=ei(e,t);switch(r){case"referenceHidden":{const o=await Fu(t,{...i,elementContext:"reference"}),l=jC(o,n.reference);return{data:{referenceHiddenOffsets:l,referenceHidden:OC(l)}}}case"escaped":{const o=await Fu(t,{...i,altBoundary:!0}),l=jC(o,n.floating);return{data:{escapedOffsets:l,escaped:OC(l)}}}default:return{}}}}},q$=new Set(["left","top"]);async function N7(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),l=ti(n),u=rc(n),d=sa(n)==="y",h=q$.has(l)?-1:1,v=o&&d?-1:1,p=ei(t,e);let{mainAxis:g,crossAxis:b,alignmentAxis:O}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return u&&typeof O=="number"&&(b=u==="end"?O*-1:O),d?{x:b*v,y:g*h}:{x:g*h,y:b*v}}const C7=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:l,middlewareData:u}=t,d=await N7(t,e);return l===((n=u.offset)==null?void 0:n.placement)&&(r=u.arrow)!=null&&r.alignmentOffset?{}:{x:i+d.x,y:o+d.y,data:{...d,placement:l}}}}},T7=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:o=!0,crossAxis:l=!1,limiter:u={fn:x=>{let{x:_,y:A}=x;return{x:_,y:A}}},...d}=ei(e,t),h={x:n,y:r},v=await Fu(t,d),p=sa(ti(i)),g=Kj(p);let b=h[g],O=h[p];if(o){const x=g==="y"?"top":"left",_=g==="y"?"bottom":"right",A=b+v[x],E=b-v[_];b=F1(A,b,E)}if(l){const x=p==="y"?"top":"left",_=p==="y"?"bottom":"right",A=O+v[x],E=O-v[_];O=F1(A,O,E)}const j=u.fn({...t,[g]:b,[p]:O});return{...j,data:{x:j.x-n,y:j.y-r,enabled:{[g]:o,[p]:l}}}}}},M7=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:o,middlewareData:l}=t,{offset:u=0,mainAxis:d=!0,crossAxis:h=!0}=ei(e,t),v={x:n,y:r},p=sa(i),g=Kj(p);let b=v[g],O=v[p];const j=ei(u,t),x=typeof j=="number"?{mainAxis:j,crossAxis:0}:{mainAxis:0,crossAxis:0,...j};if(d){const E=g==="y"?"height":"width",C=o.reference[g]-o.floating[E]+x.mainAxis,N=o.reference[g]+o.reference[E]-x.mainAxis;b<C?b=C:b>N&&(b=N)}if(h){var _,A;const E=g==="y"?"width":"height",C=q$.has(ti(i)),N=o.reference[p]-o.floating[E]+(C&&((_=l.offset)==null?void 0:_[p])||0)+(C?0:x.crossAxis),M=o.reference[p]+o.reference[E]+(C?0:((A=l.offset)==null?void 0:A[p])||0)-(C?x.crossAxis:0);O<N?O=N:O>M&&(O=M)}return{[g]:b,[p]:O}}}},R7=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:l,elements:u}=t,{apply:d=()=>{},...h}=ei(e,t),v=await Fu(t,h),p=ti(i),g=rc(i),b=sa(i)==="y",{width:O,height:j}=o.floating;let x,_;p==="top"||p==="bottom"?(x=p,_=g===(await(l.isRTL==null?void 0:l.isRTL(u.floating))?"start":"end")?"left":"right"):(_=p,x=g==="end"?"top":"bottom");const A=j-v.top-v.bottom,E=O-v.left-v.right,C=Xi(j-v[x],A),N=Xi(O-v[_],E),M=!t.middlewareData.shift;let R=C,D=N;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=E),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(R=A),M&&!g){const Y=rr(v.left,0),L=rr(v.right,0),F=rr(v.top,0),W=rr(v.bottom,0);b?D=O-2*(Y!==0||L!==0?Y+L:rr(v.left,v.right)):R=j-2*(F!==0||W!==0?F+W:rr(v.top,v.bottom))}await d({...t,availableWidth:D,availableHeight:R});const z=await l.getDimensions(u.floating);return O!==z.width||j!==z.height?{reset:{rects:!0}}:{}}}};function Rp(){return typeof window<"u"}function ac(e){return U$(e)?(e.nodeName||"").toLowerCase():"#document"}function or(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function xa(e){var t;return(t=(U$(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function U$(e){return Rp()?e instanceof Node||e instanceof or(e).Node:!1}function Wr(e){return Rp()?e instanceof Element||e instanceof or(e).Element:!1}function ga(e){return Rp()?e instanceof HTMLElement||e instanceof or(e).HTMLElement:!1}function _C(e){return!Rp()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof or(e).ShadowRoot}const D7=new Set(["inline","contents"]);function zf(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Kr(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!D7.has(i)}const P7=new Set(["table","td","th"]);function k7(e){return P7.has(ac(e))}const $7=[":popover-open",":modal"];function Dp(e){return $7.some(t=>{try{return e.matches(t)}catch{return!1}})}const I7=["transform","translate","scale","rotate","perspective"],L7=["transform","translate","scale","rotate","perspective","filter"],z7=["paint","layout","strict","content"];function Zj(e){const t=Jj(),n=Wr(e)?Kr(e):e;return I7.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||L7.some(r=>(n.willChange||"").includes(r))||z7.some(r=>(n.contain||"").includes(r))}function B7(e){let t=Qi(e);for(;ga(t)&&!_l(t);){if(Zj(t))return t;if(Dp(t))return null;t=Qi(t)}return null}function Jj(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const q7=new Set(["html","body","#document"]);function _l(e){return q7.has(ac(e))}function Kr(e){return or(e).getComputedStyle(e)}function Pp(e){return Wr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Qi(e){if(ac(e)==="html")return e;const t=e.assignedSlot||e.parentNode||_C(e)&&e.host||xa(e);return _C(t)?t.host:t}function H$(e){const t=Qi(e);return _l(t)?e.ownerDocument?e.ownerDocument.body:e.body:ga(t)&&zf(t)?t:H$(t)}function Gu(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=H$(e),o=i===((r=e.ownerDocument)==null?void 0:r.body),l=or(i);if(o){const u=V1(l);return t.concat(l,l.visualViewport||[],zf(i)?i:[],u&&n?Gu(u):[])}return t.concat(i,Gu(i,[],n))}function V1(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function F$(e){const t=Kr(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=ga(e),o=i?e.offsetWidth:n,l=i?e.offsetHeight:r,u=tm(n)!==o||tm(r)!==l;return u&&(n=o,r=l),{width:n,height:r,$:u}}function eO(e){return Wr(e)?e:e.contextElement}function yl(e){const t=eO(e);if(!ga(t))return ua(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=F$(t);let l=(o?tm(n.width):n.width)/r,u=(o?tm(n.height):n.height)/i;return(!l||!Number.isFinite(l))&&(l=1),(!u||!Number.isFinite(u))&&(u=1),{x:l,y:u}}const U7=ua(0);function G$(e){const t=or(e);return!Jj()||!t.visualViewport?U7:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function H7(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==or(e)?!1:t}function Yo(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=eO(e);let l=ua(1);t&&(r?Wr(r)&&(l=yl(r)):l=yl(e));const u=H7(o,n,r)?G$(o):ua(0);let d=(i.left+u.x)/l.x,h=(i.top+u.y)/l.y,v=i.width/l.x,p=i.height/l.y;if(o){const g=or(o),b=r&&Wr(r)?or(r):r;let O=g,j=V1(O);for(;j&&r&&b!==O;){const x=yl(j),_=j.getBoundingClientRect(),A=Kr(j),E=_.left+(j.clientLeft+parseFloat(A.paddingLeft))*x.x,C=_.top+(j.clientTop+parseFloat(A.paddingTop))*x.y;d*=x.x,h*=x.y,v*=x.x,p*=x.y,d+=E,h+=C,O=or(j),j=V1(O)}}return rm({width:v,height:p,x:d,y:h})}function kp(e,t){const n=Pp(e).scrollLeft;return t?t.left+n:Yo(xa(e)).left+n}function V$(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-kp(e,n),i=n.top+t.scrollTop;return{x:r,y:i}}function F7(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o=i==="fixed",l=xa(r),u=t?Dp(t.floating):!1;if(r===l||u&&o)return n;let d={scrollLeft:0,scrollTop:0},h=ua(1);const v=ua(0),p=ga(r);if((p||!p&&!o)&&((ac(r)!=="body"||zf(l))&&(d=Pp(r)),ga(r))){const b=Yo(r);h=yl(r),v.x=b.x+r.clientLeft,v.y=b.y+r.clientTop}const g=l&&!p&&!o?V$(l,d):ua(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-d.scrollLeft*h.x+v.x+g.x,y:n.y*h.y-d.scrollTop*h.y+v.y+g.y}}function G7(e){return Array.from(e.getClientRects())}function V7(e){const t=xa(e),n=Pp(e),r=e.ownerDocument.body,i=rr(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=rr(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let l=-n.scrollLeft+kp(e);const u=-n.scrollTop;return Kr(r).direction==="rtl"&&(l+=rr(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:l,y:u}}const EC=25;function Y7(e,t){const n=or(e),r=xa(e),i=n.visualViewport;let o=r.clientWidth,l=r.clientHeight,u=0,d=0;if(i){o=i.width,l=i.height;const v=Jj();(!v||v&&t==="fixed")&&(u=i.offsetLeft,d=i.offsetTop)}const h=kp(r);if(h<=0){const v=r.ownerDocument,p=v.body,g=getComputedStyle(p),b=v.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,O=Math.abs(r.clientWidth-p.clientWidth-b);O<=EC&&(o-=O)}else h<=EC&&(o+=h);return{width:o,height:l,x:u,y:d}}const W7=new Set(["absolute","fixed"]);function K7(e,t){const n=Yo(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=ga(e)?yl(e):ua(1),l=e.clientWidth*o.x,u=e.clientHeight*o.y,d=i*o.x,h=r*o.y;return{width:l,height:u,x:d,y:h}}function AC(e,t,n){let r;if(t==="viewport")r=Y7(e,n);else if(t==="document")r=V7(xa(e));else if(Wr(t))r=K7(t,n);else{const i=G$(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return rm(r)}function Y$(e,t){const n=Qi(e);return n===t||!Wr(n)||_l(n)?!1:Kr(n).position==="fixed"||Y$(n,t)}function X7(e,t){const n=t.get(e);if(n)return n;let r=Gu(e,[],!1).filter(u=>Wr(u)&&ac(u)!=="body"),i=null;const o=Kr(e).position==="fixed";let l=o?Qi(e):e;for(;Wr(l)&&!_l(l);){const u=Kr(l),d=Zj(l);!d&&u.position==="fixed"&&(i=null),(o?!d&&!i:!d&&u.position==="static"&&!!i&&W7.has(i.position)||zf(l)&&!d&&Y$(e,l))?r=r.filter(v=>v!==l):i=u,l=Qi(l)}return t.set(e,r),r}function Q7(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const l=[...n==="clippingAncestors"?Dp(t)?[]:X7(t,this._c):[].concat(n),r],u=l[0],d=l.reduce((h,v)=>{const p=AC(t,v,i);return h.top=rr(p.top,h.top),h.right=Xi(p.right,h.right),h.bottom=Xi(p.bottom,h.bottom),h.left=rr(p.left,h.left),h},AC(t,u,i));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function Z7(e){const{width:t,height:n}=F$(e);return{width:t,height:n}}function J7(e,t,n){const r=ga(t),i=xa(t),o=n==="fixed",l=Yo(e,!0,o,t);let u={scrollLeft:0,scrollTop:0};const d=ua(0);function h(){d.x=kp(i)}if(r||!r&&!o)if((ac(t)!=="body"||zf(i))&&(u=Pp(t)),r){const b=Yo(t,!0,o,t);d.x=b.x+t.clientLeft,d.y=b.y+t.clientTop}else i&&h();o&&!r&&i&&h();const v=i&&!r&&!o?V$(i,u):ua(0),p=l.left+u.scrollLeft-d.x-v.x,g=l.top+u.scrollTop-d.y-v.y;return{x:p,y:g,width:l.width,height:l.height}}function jb(e){return Kr(e).position==="static"}function NC(e,t){if(!ga(e)||Kr(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return xa(e)===n&&(n=n.ownerDocument.body),n}function W$(e,t){const n=or(e);if(Dp(e))return n;if(!ga(e)){let i=Qi(e);for(;i&&!_l(i);){if(Wr(i)&&!jb(i))return i;i=Qi(i)}return n}let r=NC(e,t);for(;r&&k7(r)&&jb(r);)r=NC(r,t);return r&&_l(r)&&jb(r)&&!Zj(r)?n:r||B7(e)||n}const eG=async function(e){const t=this.getOffsetParent||W$,n=this.getDimensions,r=await n(e.floating);return{reference:J7(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function tG(e){return Kr(e).direction==="rtl"}const nG={convertOffsetParentRelativeRectToViewportRelativeRect:F7,getDocumentElement:xa,getClippingRect:Q7,getOffsetParent:W$,getElementRects:eG,getClientRects:G7,getDimensions:Z7,getScale:yl,isElement:Wr,isRTL:tG};function K$(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function rG(e,t){let n=null,r;const i=xa(e);function o(){var u;clearTimeout(r),(u=n)==null||u.disconnect(),n=null}function l(u,d){u===void 0&&(u=!1),d===void 0&&(d=1),o();const h=e.getBoundingClientRect(),{left:v,top:p,width:g,height:b}=h;if(u||t(),!g||!b)return;const O=yh(p),j=yh(i.clientWidth-(v+g)),x=yh(i.clientHeight-(p+b)),_=yh(v),E={rootMargin:-O+"px "+-j+"px "+-x+"px "+-_+"px",threshold:rr(0,Xi(1,d))||1};let C=!0;function N(M){const R=M[0].intersectionRatio;if(R!==d){if(!C)return l();R?l(!1,R):r=setTimeout(()=>{l(!1,1e-7)},1e3)}R===1&&!K$(h,e.getBoundingClientRect())&&l(),C=!1}try{n=new IntersectionObserver(N,{...E,root:i.ownerDocument})}catch{n=new IntersectionObserver(N,E)}n.observe(e)}return l(!0),o}function aG(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:u=typeof IntersectionObserver=="function",animationFrame:d=!1}=r,h=eO(e),v=i||o?[...h?Gu(h):[],...Gu(t)]:[];v.forEach(_=>{i&&_.addEventListener("scroll",n,{passive:!0}),o&&_.addEventListener("resize",n)});const p=h&&u?rG(h,n):null;let g=-1,b=null;l&&(b=new ResizeObserver(_=>{let[A]=_;A&&A.target===h&&b&&(b.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var E;(E=b)==null||E.observe(t)})),n()}),h&&!d&&b.observe(h),b.observe(t));let O,j=d?Yo(e):null;d&&x();function x(){const _=Yo(e);j&&!K$(j,_)&&n(),j=_,O=requestAnimationFrame(x)}return n(),()=>{var _;v.forEach(A=>{i&&A.removeEventListener("scroll",n),o&&A.removeEventListener("resize",n)}),p==null||p(),(_=b)==null||_.disconnect(),b=null,d&&cancelAnimationFrame(O)}}const iG=C7,oG=T7,sG=E7,lG=R7,cG=A7,CC=_7,uG=M7,fG=(e,t,n)=>{const r=new Map,i={platform:nG,...n},o={...i.platform,_c:r};return O7(e,t,{...i,platform:o})};var dG=typeof document<"u",hG=function(){},Fh=dG?w.useLayoutEffect:hG;function am(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!am(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!am(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function X$(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function TC(e,t){const n=X$(e);return Math.round(t*n)/n}function Ob(e){const t=w.useRef(e);return Fh(()=>{t.current=e}),t}function mG(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:l}={},transform:u=!0,whileElementsMounted:d,open:h}=e,[v,p]=w.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[g,b]=w.useState(r);am(g,r)||b(r);const[O,j]=w.useState(null),[x,_]=w.useState(null),A=w.useCallback(B=>{B!==M.current&&(M.current=B,j(B))},[]),E=w.useCallback(B=>{B!==R.current&&(R.current=B,_(B))},[]),C=o||O,N=l||x,M=w.useRef(null),R=w.useRef(null),D=w.useRef(v),z=d!=null,Y=Ob(d),L=Ob(i),F=Ob(h),W=w.useCallback(()=>{if(!M.current||!R.current)return;const B={placement:t,strategy:n,middleware:g};L.current&&(B.platform=L.current),fG(M.current,R.current,B).then(Z=>{const le={...Z,isPositioned:F.current!==!1};Q.current&&!am(D.current,le)&&(D.current=le,Pf.flushSync(()=>{p(le)}))})},[g,t,n,L,F]);Fh(()=>{h===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,p(B=>({...B,isPositioned:!1})))},[h]);const Q=w.useRef(!1);Fh(()=>(Q.current=!0,()=>{Q.current=!1}),[]),Fh(()=>{if(C&&(M.current=C),N&&(R.current=N),C&&N){if(Y.current)return Y.current(C,N,W);W()}},[C,N,W,Y,z]);const X=w.useMemo(()=>({reference:M,floating:R,setReference:A,setFloating:E}),[A,E]),k=w.useMemo(()=>({reference:C,floating:N}),[C,N]),H=w.useMemo(()=>{const B={position:n,left:0,top:0};if(!k.floating)return B;const Z=TC(k.floating,v.x),le=TC(k.floating,v.y);return u?{...B,transform:"translate("+Z+"px, "+le+"px)",...X$(k.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:Z,top:le}},[n,u,k.floating,v.x,v.y]);return w.useMemo(()=>({...v,update:W,refs:X,elements:k,floatingStyles:H}),[v,W,X,k,H])}const pG=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?CC({element:r.current,padding:i}).fn(n):{}:r?CC({element:r,padding:i}).fn(n):{}}}},vG=(e,t)=>({...iG(e),options:[e,t]}),gG=(e,t)=>({...oG(e),options:[e,t]}),yG=(e,t)=>({...uG(e),options:[e,t]}),bG=(e,t)=>({...sG(e),options:[e,t]}),xG=(e,t)=>({...lG(e),options:[e,t]}),wG=(e,t)=>({...cG(e),options:[e,t]}),SG=(e,t)=>({...pG(e),options:[e,t]});var jG="Arrow",Q$=w.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...o}=e;return c.jsx(Ee.svg,{...o,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:c.jsx("polygon",{points:"0,0 30,0 15,10"})})});Q$.displayName=jG;var OG=Q$;function $p(e){const[t,n]=w.useState(void 0);return Yt(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let l,u;if("borderBoxSize"in o){const d=o.borderBoxSize,h=Array.isArray(d)?d[0]:d;l=h.inlineSize,u=h.blockSize}else l=e.offsetWidth,u=e.offsetHeight;n({width:l,height:u})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var tO="Popper",[Z$,to]=jn(tO),[_G,J$]=Z$(tO),eI=e=>{const{__scopePopper:t,children:n}=e,[r,i]=w.useState(null);return c.jsx(_G,{scope:t,anchor:r,onAnchorChange:i,children:n})};eI.displayName=tO;var tI="PopperAnchor",nI=w.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,o=J$(tI,n),l=w.useRef(null),u=Be(t,l),d=w.useRef(null);return w.useEffect(()=>{const h=d.current;d.current=(r==null?void 0:r.current)||l.current,h!==d.current&&o.onAnchorChange(d.current)}),r?null:c.jsx(Ee.div,{...i,ref:u})});nI.displayName=tI;var nO="PopperContent",[EG,AG]=Z$(nO),rI=w.forwardRef((e,t)=>{var ie,pe,re,ve,ge,oe;const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:o="center",alignOffset:l=0,arrowPadding:u=0,avoidCollisions:d=!0,collisionBoundary:h=[],collisionPadding:v=0,sticky:p="partial",hideWhenDetached:g=!1,updatePositionStrategy:b="optimized",onPlaced:O,...j}=e,x=J$(nO,n),[_,A]=w.useState(null),E=Be(t,ke=>A(ke)),[C,N]=w.useState(null),M=$p(C),R=(M==null?void 0:M.width)??0,D=(M==null?void 0:M.height)??0,z=r+(o!=="center"?"-"+o:""),Y=typeof v=="number"?v:{top:0,right:0,bottom:0,left:0,...v},L=Array.isArray(h)?h:[h],F=L.length>0,W={padding:Y,boundary:L.filter(CG),altBoundary:F},{refs:Q,floatingStyles:X,placement:k,isPositioned:H,middlewareData:B}=mG({strategy:"fixed",placement:z,whileElementsMounted:(...ke)=>aG(...ke,{animationFrame:b==="always"}),elements:{reference:x.anchor},middleware:[vG({mainAxis:i+D,alignmentAxis:l}),d&&gG({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?yG():void 0,...W}),d&&bG({...W}),xG({...W,apply:({elements:ke,rects:we,availableWidth:Ie,availableHeight:Ze})=>{const{width:lt,height:en}=we.reference,mt=ke.floating.style;mt.setProperty("--radix-popper-available-width",`${Ie}px`),mt.setProperty("--radix-popper-available-height",`${Ze}px`),mt.setProperty("--radix-popper-anchor-width",`${lt}px`),mt.setProperty("--radix-popper-anchor-height",`${en}px`)}}),C&&SG({element:C,padding:u}),TG({arrowWidth:R,arrowHeight:D}),g&&wG({strategy:"referenceHidden",...W})]}),[Z,le]=oI(k),$=Yr(O);Yt(()=>{H&&($==null||$())},[H,$]);const V=(ie=B.arrow)==null?void 0:ie.x,q=(pe=B.arrow)==null?void 0:pe.y,U=((re=B.arrow)==null?void 0:re.centerOffset)!==0,[ne,fe]=w.useState();return Yt(()=>{_&&fe(window.getComputedStyle(_).zIndex)},[_]),c.jsx("div",{ref:Q.setFloating,"data-radix-popper-content-wrapper":"",style:{...X,transform:H?X.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ne,"--radix-popper-transform-origin":[(ve=B.transformOrigin)==null?void 0:ve.x,(ge=B.transformOrigin)==null?void 0:ge.y].join(" "),...((oe=B.hide)==null?void 0:oe.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:c.jsx(EG,{scope:n,placedSide:Z,onArrowChange:N,arrowX:V,arrowY:q,shouldHideArrow:U,children:c.jsx(Ee.div,{"data-side":Z,"data-align":le,...j,ref:E,style:{...j.style,animation:H?void 0:"none"}})})})});rI.displayName=nO;var aI="PopperArrow",NG={top:"bottom",right:"left",bottom:"top",left:"right"},iI=w.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,o=AG(aI,r),l=NG[o.placedSide];return c.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[l]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:c.jsx(OG,{...i,ref:n,style:{...i.style,display:"block"}})})});iI.displayName=aI;function CG(e){return e!==null}var TG=e=>({name:"transformOrigin",options:e,fn(t){var x,_,A;const{placement:n,rects:r,middlewareData:i}=t,l=((x=i.arrow)==null?void 0:x.centerOffset)!==0,u=l?0:e.arrowWidth,d=l?0:e.arrowHeight,[h,v]=oI(n),p={start:"0%",center:"50%",end:"100%"}[v],g=(((_=i.arrow)==null?void 0:_.x)??0)+u/2,b=(((A=i.arrow)==null?void 0:A.y)??0)+d/2;let O="",j="";return h==="bottom"?(O=l?p:`${g}px`,j=`${-d}px`):h==="top"?(O=l?p:`${g}px`,j=`${r.floating.height+d}px`):h==="right"?(O=`${-d}px`,j=l?p:`${b}px`):h==="left"&&(O=`${r.floating.width+d}px`,j=l?p:`${b}px`),{data:{x:O,y:j}}}});function oI(e){const[t,n="center"]=e.split("-");return[t,n]}var Ip=eI,Lp=nI,zp=rI,Bp=iI,MG="Portal",ic=w.forwardRef((e,t)=>{var u;const{container:n,...r}=e,[i,o]=w.useState(!1);Yt(()=>o(!0),[]);const l=n||i&&((u=globalThis==null?void 0:globalThis.document)==null?void 0:u.body);return l?s$.createPortal(c.jsx(Ee.div,{...r,ref:t}),l):null});ic.displayName=MG;function RG(e,t){return w.useReducer((n,r)=>t[n][r]??n,e)}var Nn=e=>{const{present:t,children:n}=e,r=DG(t),i=typeof n=="function"?n({present:r.isPresent}):w.Children.only(n),o=Be(r.ref,PG(i));return typeof n=="function"||r.isPresent?w.cloneElement(i,{ref:o}):null};Nn.displayName="Presence";function DG(e){const[t,n]=w.useState(),r=w.useRef(null),i=w.useRef(e),o=w.useRef("none"),l=e?"mounted":"unmounted",[u,d]=RG(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const h=bh(r.current);o.current=u==="mounted"?h:"none"},[u]),Yt(()=>{const h=r.current,v=i.current;if(v!==e){const g=o.current,b=bh(h);e?d("MOUNT"):b==="none"||(h==null?void 0:h.display)==="none"?d("UNMOUNT"):d(v&&g!==b?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,d]),Yt(()=>{if(t){let h;const v=t.ownerDocument.defaultView??window,p=b=>{const j=bh(r.current).includes(CSS.escape(b.animationName));if(b.target===t&&j&&(d("ANIMATION_END"),!i.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",h=v.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},g=b=>{b.target===t&&(o.current=bh(r.current))};return t.addEventListener("animationstart",g),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{v.clearTimeout(h),t.removeEventListener("animationstart",g),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else d("ANIMATION_END")},[t,d]),{isPresent:["mounted","unmountSuspended"].includes(u),ref:w.useCallback(h=>{r.current=h?getComputedStyle(h):null,n(h)},[])}}function bh(e){return(e==null?void 0:e.animationName)||"none"}function PG(e){var r,i;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var _b="rovingFocusGroup.onEntryFocus",kG={bubbles:!1,cancelable:!0},Bf="RovingFocusGroup",[Y1,sI,$G]=Tp(Bf),[IG,oc]=jn(Bf,[$G]),[LG,zG]=IG(Bf),lI=w.forwardRef((e,t)=>c.jsx(Y1.Provider,{scope:e.__scopeRovingFocusGroup,children:c.jsx(Y1.Slot,{scope:e.__scopeRovingFocusGroup,children:c.jsx(BG,{...e,ref:t})})}));lI.displayName=Bf;var BG=w.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:o,currentTabStopId:l,defaultCurrentTabStopId:u,onCurrentTabStopIdChange:d,onEntryFocus:h,preventScrollOnEntryFocus:v=!1,...p}=e,g=w.useRef(null),b=Be(t,g),O=tc(o),[j,x]=An({prop:l,defaultProp:u??null,onChange:d,caller:Bf}),[_,A]=w.useState(!1),E=Yr(h),C=sI(n),N=w.useRef(!1),[M,R]=w.useState(0);return w.useEffect(()=>{const D=g.current;if(D)return D.addEventListener(_b,E),()=>D.removeEventListener(_b,E)},[E]),c.jsx(LG,{scope:n,orientation:r,dir:O,loop:i,currentTabStopId:j,onItemFocus:w.useCallback(D=>x(D),[x]),onItemShiftTab:w.useCallback(()=>A(!0),[]),onFocusableItemAdd:w.useCallback(()=>R(D=>D+1),[]),onFocusableItemRemove:w.useCallback(()=>R(D=>D-1),[]),children:c.jsx(Ee.div,{tabIndex:_||M===0?-1:0,"data-orientation":r,...p,ref:b,style:{outline:"none",...e.style},onMouseDown:ye(e.onMouseDown,()=>{N.current=!0}),onFocus:ye(e.onFocus,D=>{const z=!N.current;if(D.target===D.currentTarget&&z&&!_){const Y=new CustomEvent(_b,kG);if(D.currentTarget.dispatchEvent(Y),!Y.defaultPrevented){const L=C().filter(k=>k.focusable),F=L.find(k=>k.active),W=L.find(k=>k.id===j),X=[F,W,...L].filter(Boolean).map(k=>k.ref.current);fI(X,v)}}N.current=!1}),onBlur:ye(e.onBlur,()=>A(!1))})})}),cI="RovingFocusGroupItem",uI=w.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:o,children:l,...u}=e,d=Nr(),h=o||d,v=zG(cI,n),p=v.currentTabStopId===h,g=sI(n),{onFocusableItemAdd:b,onFocusableItemRemove:O,currentTabStopId:j}=v;return w.useEffect(()=>{if(r)return b(),()=>O()},[r,b,O]),c.jsx(Y1.ItemSlot,{scope:n,id:h,focusable:r,active:i,children:c.jsx(Ee.span,{tabIndex:p?0:-1,"data-orientation":v.orientation,...u,ref:t,onMouseDown:ye(e.onMouseDown,x=>{r?v.onItemFocus(h):x.preventDefault()}),onFocus:ye(e.onFocus,()=>v.onItemFocus(h)),onKeyDown:ye(e.onKeyDown,x=>{if(x.key==="Tab"&&x.shiftKey){v.onItemShiftTab();return}if(x.target!==x.currentTarget)return;const _=HG(x,v.orientation,v.dir);if(_!==void 0){if(x.metaKey||x.ctrlKey||x.altKey||x.shiftKey)return;x.preventDefault();let E=g().filter(C=>C.focusable).map(C=>C.ref.current);if(_==="last")E.reverse();else if(_==="prev"||_==="next"){_==="prev"&&E.reverse();const C=E.indexOf(x.currentTarget);E=v.loop?FG(E,C+1):E.slice(C+1)}setTimeout(()=>fI(E))}}),children:typeof l=="function"?l({isCurrentTabStop:p,hasTabStop:j!=null}):l})})});uI.displayName=cI;var qG={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function UG(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function HG(e,t,n){const r=UG(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return qG[r]}function fI(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function FG(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var rO=lI,aO=uI,GG=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},rl=new WeakMap,xh=new WeakMap,wh={},Eb=0,dI=function(e){return e&&(e.host||dI(e.parentNode))},VG=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=dI(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},YG=function(e,t,n,r){var i=VG(t,Array.isArray(e)?e:[e]);wh[n]||(wh[n]=new WeakMap);var o=wh[n],l=[],u=new Set,d=new Set(i),h=function(p){!p||u.has(p)||(u.add(p),h(p.parentNode))};i.forEach(h);var v=function(p){!p||d.has(p)||Array.prototype.forEach.call(p.children,function(g){if(u.has(g))v(g);else try{var b=g.getAttribute(r),O=b!==null&&b!=="false",j=(rl.get(g)||0)+1,x=(o.get(g)||0)+1;rl.set(g,j),o.set(g,x),l.push(g),j===1&&O&&xh.set(g,!0),x===1&&g.setAttribute(n,"true"),O||g.setAttribute(r,"true")}catch(_){console.error("aria-hidden: cannot operate on ",g,_)}})};return v(t),u.clear(),Eb++,function(){l.forEach(function(p){var g=rl.get(p)-1,b=o.get(p)-1;rl.set(p,g),o.set(p,b),g||(xh.has(p)||p.removeAttribute(r),xh.delete(p)),b||p.removeAttribute(n)}),Eb--,Eb||(rl=new WeakMap,rl=new WeakMap,xh=new WeakMap,wh={})}},iO=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=GG(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live], script"))),YG(r,i,n,"aria-hidden")):function(){return null}},oa=function(){return oa=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},oa.apply(this,arguments)};function hI(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function WG(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Gh="right-scroll-bar-position",Vh="width-before-scroll-bar",KG="with-scroll-bars-hidden",XG="--removed-body-scroll-bar-size";function Ab(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function QG(e,t){var n=w.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var ZG=typeof window<"u"?w.useLayoutEffect:w.useEffect,MC=new WeakMap;function JG(e,t){var n=QG(null,function(r){return e.forEach(function(i){return Ab(i,r)})});return ZG(function(){var r=MC.get(n);if(r){var i=new Set(r),o=new Set(e),l=n.current;i.forEach(function(u){o.has(u)||Ab(u,null)}),o.forEach(function(u){i.has(u)||Ab(u,l)})}MC.set(n,e)},[e]),n}function eV(e){return e}function tV(e,t){t===void 0&&(t=eV);var n=[],r=!1,i={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(o){var l=t(o,r);return n.push(l),function(){n=n.filter(function(u){return u!==l})}},assignSyncMedium:function(o){for(r=!0;n.length;){var l=n;n=[],l.forEach(o)}n={push:function(u){return o(u)},filter:function(){return n}}},assignMedium:function(o){r=!0;var l=[];if(n.length){var u=n;n=[],u.forEach(o),l=n}var d=function(){var v=l;l=[],v.forEach(o)},h=function(){return Promise.resolve().then(d)};h(),n={push:function(v){l.push(v),h()},filter:function(v){return l=l.filter(v),n}}}};return i}function nV(e){e===void 0&&(e={});var t=tV(null);return t.options=oa({async:!0,ssr:!1},e),t}var mI=function(e){var t=e.sideCar,n=hI(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return w.createElement(r,oa({},n))};mI.isSideCarExport=!0;function rV(e,t){return e.useMedium(t),mI}var pI=nV(),Nb=function(){},qp=w.forwardRef(function(e,t){var n=w.useRef(null),r=w.useState({onScrollCapture:Nb,onWheelCapture:Nb,onTouchMoveCapture:Nb}),i=r[0],o=r[1],l=e.forwardProps,u=e.children,d=e.className,h=e.removeScrollBar,v=e.enabled,p=e.shards,g=e.sideCar,b=e.noRelative,O=e.noIsolation,j=e.inert,x=e.allowPinchZoom,_=e.as,A=_===void 0?"div":_,E=e.gapMode,C=hI(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),N=g,M=JG([n,t]),R=oa(oa({},C),i);return w.createElement(w.Fragment,null,v&&w.createElement(N,{sideCar:pI,removeScrollBar:h,shards:p,noRelative:b,noIsolation:O,inert:j,setCallbacks:o,allowPinchZoom:!!x,lockRef:n,gapMode:E}),l?w.cloneElement(w.Children.only(u),oa(oa({},R),{ref:M})):w.createElement(A,oa({},R,{className:d,ref:M}),u))});qp.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};qp.classNames={fullWidth:Vh,zeroRight:Gh};var aV=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function iV(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=aV();return t&&e.setAttribute("nonce",t),e}function oV(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function sV(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var lV=function(){var e=0,t=null;return{add:function(n){e==0&&(t=iV())&&(oV(t,n),sV(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},cV=function(){var e=lV();return function(t,n){w.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},vI=function(){var e=cV(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},uV={left:0,top:0,right:0,gap:0},Cb=function(e){return parseInt(e||"",10)||0},fV=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[Cb(n),Cb(r),Cb(i)]},dV=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return uV;var t=fV(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},hV=vI(),bl="data-scroll-locked",mV=function(e,t,n,r){var i=e.left,o=e.top,l=e.right,u=e.gap;return n===void 0&&(n="margin"),`
349
+ .`.concat(KG,` {
350
+ overflow: hidden `).concat(r,`;
351
+ padding-right: `).concat(u,"px ").concat(r,`;
352
+ }
353
+ body[`).concat(bl,`] {
354
+ overflow: hidden `).concat(r,`;
355
+ overscroll-behavior: contain;
356
+ `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
357
+ padding-left: `.concat(i,`px;
358
+ padding-top: `).concat(o,`px;
359
+ padding-right: `).concat(l,`px;
360
+ margin-left:0;
361
+ margin-top:0;
362
+ margin-right: `).concat(u,"px ").concat(r,`;
363
+ `),n==="padding"&&"padding-right: ".concat(u,"px ").concat(r,";")].filter(Boolean).join(""),`
364
+ }
365
+
366
+ .`).concat(Gh,` {
367
+ right: `).concat(u,"px ").concat(r,`;
368
+ }
369
+
370
+ .`).concat(Vh,` {
371
+ margin-right: `).concat(u,"px ").concat(r,`;
372
+ }
373
+
374
+ .`).concat(Gh," .").concat(Gh,` {
375
+ right: 0 `).concat(r,`;
376
+ }
377
+
378
+ .`).concat(Vh," .").concat(Vh,` {
379
+ margin-right: 0 `).concat(r,`;
380
+ }
381
+
382
+ body[`).concat(bl,`] {
383
+ `).concat(XG,": ").concat(u,`px;
384
+ }
385
+ `)},RC=function(){var e=parseInt(document.body.getAttribute(bl)||"0",10);return isFinite(e)?e:0},pV=function(){w.useEffect(function(){return document.body.setAttribute(bl,(RC()+1).toString()),function(){var e=RC()-1;e<=0?document.body.removeAttribute(bl):document.body.setAttribute(bl,e.toString())}},[])},vV=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r;pV();var o=w.useMemo(function(){return dV(i)},[i]);return w.createElement(hV,{styles:mV(o,!t,i,n?"":"!important")})},W1=!1;if(typeof window<"u")try{var Sh=Object.defineProperty({},"passive",{get:function(){return W1=!0,!0}});window.addEventListener("test",Sh,Sh),window.removeEventListener("test",Sh,Sh)}catch{W1=!1}var al=W1?{passive:!1}:!1,gV=function(e){return e.tagName==="TEXTAREA"},gI=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!gV(e)&&n[t]==="visible")},yV=function(e){return gI(e,"overflowY")},bV=function(e){return gI(e,"overflowX")},DC=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=yI(e,r);if(i){var o=bI(e,r),l=o[1],u=o[2];if(l>u)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},xV=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},wV=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},yI=function(e,t){return e==="v"?yV(t):bV(t)},bI=function(e,t){return e==="v"?xV(t):wV(t)},SV=function(e,t){return e==="h"&&t==="rtl"?-1:1},jV=function(e,t,n,r,i){var o=SV(e,window.getComputedStyle(t).direction),l=o*r,u=n.target,d=t.contains(u),h=!1,v=l>0,p=0,g=0;do{if(!u)break;var b=bI(e,u),O=b[0],j=b[1],x=b[2],_=j-x-o*O;(O||_)&&yI(e,u)&&(p+=_,g+=O);var A=u.parentNode;u=A&&A.nodeType===Node.DOCUMENT_FRAGMENT_NODE?A.host:A}while(!d&&u!==document.body||d&&(t.contains(u)||t===u));return(v&&Math.abs(p)<1||!v&&Math.abs(g)<1)&&(h=!0),h},jh=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},PC=function(e){return[e.deltaX,e.deltaY]},kC=function(e){return e&&"current"in e?e.current:e},OV=function(e,t){return e[0]===t[0]&&e[1]===t[1]},_V=function(e){return`
386
+ .block-interactivity-`.concat(e,` {pointer-events: none;}
387
+ .allow-interactivity-`).concat(e,` {pointer-events: all;}
388
+ `)},EV=0,il=[];function AV(e){var t=w.useRef([]),n=w.useRef([0,0]),r=w.useRef(),i=w.useState(EV++)[0],o=w.useState(vI)[0],l=w.useRef(e);w.useEffect(function(){l.current=e},[e]),w.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var j=WG([e.lockRef.current],(e.shards||[]).map(kC),!0).filter(Boolean);return j.forEach(function(x){return x.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),j.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var u=w.useCallback(function(j,x){if("touches"in j&&j.touches.length===2||j.type==="wheel"&&j.ctrlKey)return!l.current.allowPinchZoom;var _=jh(j),A=n.current,E="deltaX"in j?j.deltaX:A[0]-_[0],C="deltaY"in j?j.deltaY:A[1]-_[1],N,M=j.target,R=Math.abs(E)>Math.abs(C)?"h":"v";if("touches"in j&&R==="h"&&M.type==="range")return!1;var D=window.getSelection(),z=D&&D.anchorNode,Y=z?z===M||z.contains(M):!1;if(Y)return!1;var L=DC(R,M);if(!L)return!0;if(L?N=R:(N=R==="v"?"h":"v",L=DC(R,M)),!L)return!1;if(!r.current&&"changedTouches"in j&&(E||C)&&(r.current=N),!N)return!0;var F=r.current||N;return jV(F,x,j,F==="h"?E:C)},[]),d=w.useCallback(function(j){var x=j;if(!(!il.length||il[il.length-1]!==o)){var _="deltaY"in x?PC(x):jh(x),A=t.current.filter(function(N){return N.name===x.type&&(N.target===x.target||x.target===N.shadowParent)&&OV(N.delta,_)})[0];if(A&&A.should){x.cancelable&&x.preventDefault();return}if(!A){var E=(l.current.shards||[]).map(kC).filter(Boolean).filter(function(N){return N.contains(x.target)}),C=E.length>0?u(x,E[0]):!l.current.noIsolation;C&&x.cancelable&&x.preventDefault()}}},[]),h=w.useCallback(function(j,x,_,A){var E={name:j,delta:x,target:_,should:A,shadowParent:NV(_)};t.current.push(E),setTimeout(function(){t.current=t.current.filter(function(C){return C!==E})},1)},[]),v=w.useCallback(function(j){n.current=jh(j),r.current=void 0},[]),p=w.useCallback(function(j){h(j.type,PC(j),j.target,u(j,e.lockRef.current))},[]),g=w.useCallback(function(j){h(j.type,jh(j),j.target,u(j,e.lockRef.current))},[]);w.useEffect(function(){return il.push(o),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:g}),document.addEventListener("wheel",d,al),document.addEventListener("touchmove",d,al),document.addEventListener("touchstart",v,al),function(){il=il.filter(function(j){return j!==o}),document.removeEventListener("wheel",d,al),document.removeEventListener("touchmove",d,al),document.removeEventListener("touchstart",v,al)}},[]);var b=e.removeScrollBar,O=e.inert;return w.createElement(w.Fragment,null,O?w.createElement(o,{styles:_V(i)}):null,b?w.createElement(vV,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function NV(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const CV=rV(pI,AV);var Up=w.forwardRef(function(e,t){return w.createElement(qp,oa({},e,{ref:t,sideCar:CV}))});Up.classNames=qp.classNames;var K1=["Enter"," "],TV=["ArrowDown","PageUp","Home"],xI=["ArrowUp","PageDown","End"],MV=[...TV,...xI],RV={ltr:[...K1,"ArrowRight"],rtl:[...K1,"ArrowLeft"]},DV={ltr:["ArrowLeft"],rtl:["ArrowRight"]},qf="Menu",[Vu,PV,kV]=Tp(qf),[os,wI]=jn(qf,[kV,to,oc]),Hp=to(),SI=oc(),[$V,ss]=os(qf),[IV,Uf]=os(qf),jI=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:o,modal:l=!0}=e,u=Hp(t),[d,h]=w.useState(null),v=w.useRef(!1),p=Yr(o),g=tc(i);return w.useEffect(()=>{const b=()=>{v.current=!0,document.addEventListener("pointerdown",O,{capture:!0,once:!0}),document.addEventListener("pointermove",O,{capture:!0,once:!0})},O=()=>v.current=!1;return document.addEventListener("keydown",b,{capture:!0}),()=>{document.removeEventListener("keydown",b,{capture:!0}),document.removeEventListener("pointerdown",O,{capture:!0}),document.removeEventListener("pointermove",O,{capture:!0})}},[]),c.jsx(Ip,{...u,children:c.jsx($V,{scope:t,open:n,onOpenChange:p,content:d,onContentChange:h,children:c.jsx(IV,{scope:t,onClose:w.useCallback(()=>p(!1),[p]),isUsingKeyboardRef:v,dir:g,modal:l,children:r})})})};jI.displayName=qf;var LV="MenuAnchor",oO=w.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,i=Hp(n);return c.jsx(Lp,{...i,...r,ref:t})});oO.displayName=LV;var sO="MenuPortal",[zV,OI]=os(sO,{forceMount:void 0}),_I=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:i}=e,o=ss(sO,t);return c.jsx(zV,{scope:t,forceMount:n,children:c.jsx(Nn,{present:n||o.open,children:c.jsx(ic,{asChild:!0,container:i,children:r})})})};_I.displayName=sO;var Cr="MenuContent",[BV,lO]=os(Cr),EI=w.forwardRef((e,t)=>{const n=OI(Cr,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,o=ss(Cr,e.__scopeMenu),l=Uf(Cr,e.__scopeMenu);return c.jsx(Vu.Provider,{scope:e.__scopeMenu,children:c.jsx(Nn,{present:r||o.open,children:c.jsx(Vu.Slot,{scope:e.__scopeMenu,children:l.modal?c.jsx(qV,{...i,ref:t}):c.jsx(UV,{...i,ref:t})})})})}),qV=w.forwardRef((e,t)=>{const n=ss(Cr,e.__scopeMenu),r=w.useRef(null),i=Be(t,r);return w.useEffect(()=>{const o=r.current;if(o)return iO(o)},[]),c.jsx(cO,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:ye(e.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),UV=w.forwardRef((e,t)=>{const n=ss(Cr,e.__scopeMenu);return c.jsx(cO,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),HV=Ol("MenuContent.ScrollLock"),cO=w.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:o,onCloseAutoFocus:l,disableOutsidePointerEvents:u,onEntryFocus:d,onEscapeKeyDown:h,onPointerDownOutside:v,onFocusOutside:p,onInteractOutside:g,onDismiss:b,disableOutsideScroll:O,...j}=e,x=ss(Cr,n),_=Uf(Cr,n),A=Hp(n),E=SI(n),C=PV(n),[N,M]=w.useState(null),R=w.useRef(null),D=Be(t,R,x.onContentChange),z=w.useRef(0),Y=w.useRef(""),L=w.useRef(0),F=w.useRef(null),W=w.useRef("right"),Q=w.useRef(0),X=O?Up:w.Fragment,k=O?{as:HV,allowPinchZoom:!0}:void 0,H=Z=>{var ie,pe;const le=Y.current+Z,$=C().filter(re=>!re.disabled),V=document.activeElement,q=(ie=$.find(re=>re.ref.current===V))==null?void 0:ie.textValue,U=$.map(re=>re.textValue),ne=tY(U,le,q),fe=(pe=$.find(re=>re.textValue===ne))==null?void 0:pe.ref.current;(function re(ve){Y.current=ve,window.clearTimeout(z.current),ve!==""&&(z.current=window.setTimeout(()=>re(""),1e3))})(le),fe&&setTimeout(()=>fe.focus())};w.useEffect(()=>()=>window.clearTimeout(z.current),[]),Wj();const B=w.useCallback(Z=>{var $,V;return W.current===(($=F.current)==null?void 0:$.side)&&rY(Z,(V=F.current)==null?void 0:V.area)},[]);return c.jsx(BV,{scope:n,searchRef:Y,onItemEnter:w.useCallback(Z=>{B(Z)&&Z.preventDefault()},[B]),onItemLeave:w.useCallback(Z=>{var le;B(Z)||((le=R.current)==null||le.focus(),M(null))},[B]),onTriggerLeave:w.useCallback(Z=>{B(Z)&&Z.preventDefault()},[B]),pointerGraceTimerRef:L,onPointerGraceIntentChange:w.useCallback(Z=>{F.current=Z},[]),children:c.jsx(X,{...k,children:c.jsx(Mp,{asChild:!0,trapped:i,onMountAutoFocus:ye(o,Z=>{var le;Z.preventDefault(),(le=R.current)==null||le.focus({preventScroll:!0})}),onUnmountAutoFocus:l,children:c.jsx(nc,{asChild:!0,disableOutsidePointerEvents:u,onEscapeKeyDown:h,onPointerDownOutside:v,onFocusOutside:p,onInteractOutside:g,onDismiss:b,children:c.jsx(rO,{asChild:!0,...E,dir:_.dir,orientation:"vertical",loop:r,currentTabStopId:N,onCurrentTabStopIdChange:M,onEntryFocus:ye(d,Z=>{_.isUsingKeyboardRef.current||Z.preventDefault()}),preventScrollOnEntryFocus:!0,children:c.jsx(zp,{role:"menu","aria-orientation":"vertical","data-state":UI(x.open),"data-radix-menu-content":"",dir:_.dir,...A,...j,ref:D,style:{outline:"none",...j.style},onKeyDown:ye(j.onKeyDown,Z=>{const $=Z.target.closest("[data-radix-menu-content]")===Z.currentTarget,V=Z.ctrlKey||Z.altKey||Z.metaKey,q=Z.key.length===1;$&&(Z.key==="Tab"&&Z.preventDefault(),!V&&q&&H(Z.key));const U=R.current;if(Z.target!==U||!MV.includes(Z.key))return;Z.preventDefault();const fe=C().filter(ie=>!ie.disabled).map(ie=>ie.ref.current);xI.includes(Z.key)&&fe.reverse(),JV(fe)}),onBlur:ye(e.onBlur,Z=>{Z.currentTarget.contains(Z.target)||(window.clearTimeout(z.current),Y.current="")}),onPointerMove:ye(e.onPointerMove,Yu(Z=>{const le=Z.target,$=Q.current!==Z.clientX;if(Z.currentTarget.contains(le)&&$){const V=Z.clientX>Q.current?"right":"left";W.current=V,Q.current=Z.clientX}}))})})})})})})});EI.displayName=Cr;var FV="MenuGroup",uO=w.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return c.jsx(Ee.div,{role:"group",...r,ref:t})});uO.displayName=FV;var GV="MenuLabel",AI=w.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return c.jsx(Ee.div,{...r,ref:t})});AI.displayName=GV;var im="MenuItem",$C="menu.itemSelect",Fp=w.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...i}=e,o=w.useRef(null),l=Uf(im,e.__scopeMenu),u=lO(im,e.__scopeMenu),d=Be(t,o),h=w.useRef(!1),v=()=>{const p=o.current;if(!n&&p){const g=new CustomEvent($C,{bubbles:!0,cancelable:!0});p.addEventListener($C,b=>r==null?void 0:r(b),{once:!0}),$$(p,g),g.defaultPrevented?h.current=!1:l.onClose()}};return c.jsx(NI,{...i,ref:d,disabled:n,onClick:ye(e.onClick,v),onPointerDown:p=>{var g;(g=e.onPointerDown)==null||g.call(e,p),h.current=!0},onPointerUp:ye(e.onPointerUp,p=>{var g;h.current||(g=p.currentTarget)==null||g.click()}),onKeyDown:ye(e.onKeyDown,p=>{const g=u.searchRef.current!=="";n||g&&p.key===" "||K1.includes(p.key)&&(p.currentTarget.click(),p.preventDefault())})})});Fp.displayName=im;var NI=w.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:i,...o}=e,l=lO(im,n),u=SI(n),d=w.useRef(null),h=Be(t,d),[v,p]=w.useState(!1),[g,b]=w.useState("");return w.useEffect(()=>{const O=d.current;O&&b((O.textContent??"").trim())},[o.children]),c.jsx(Vu.ItemSlot,{scope:n,disabled:r,textValue:i??g,children:c.jsx(aO,{asChild:!0,...u,focusable:!r,children:c.jsx(Ee.div,{role:"menuitem","data-highlighted":v?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...o,ref:h,onPointerMove:ye(e.onPointerMove,Yu(O=>{r?l.onItemLeave(O):(l.onItemEnter(O),O.defaultPrevented||O.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:ye(e.onPointerLeave,Yu(O=>l.onItemLeave(O))),onFocus:ye(e.onFocus,()=>p(!0)),onBlur:ye(e.onBlur,()=>p(!1))})})})}),VV="MenuCheckboxItem",CI=w.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...i}=e;return c.jsx(PI,{scope:e.__scopeMenu,checked:n,children:c.jsx(Fp,{role:"menuitemcheckbox","aria-checked":om(n)?"mixed":n,...i,ref:t,"data-state":dO(n),onSelect:ye(i.onSelect,()=>r==null?void 0:r(om(n)?!0:!n),{checkForDefaultPrevented:!1})})})});CI.displayName=VV;var TI="MenuRadioGroup",[YV,WV]=os(TI,{value:void 0,onValueChange:()=>{}}),MI=w.forwardRef((e,t)=>{const{value:n,onValueChange:r,...i}=e,o=Yr(r);return c.jsx(YV,{scope:e.__scopeMenu,value:n,onValueChange:o,children:c.jsx(uO,{...i,ref:t})})});MI.displayName=TI;var RI="MenuRadioItem",DI=w.forwardRef((e,t)=>{const{value:n,...r}=e,i=WV(RI,e.__scopeMenu),o=n===i.value;return c.jsx(PI,{scope:e.__scopeMenu,checked:o,children:c.jsx(Fp,{role:"menuitemradio","aria-checked":o,...r,ref:t,"data-state":dO(o),onSelect:ye(r.onSelect,()=>{var l;return(l=i.onValueChange)==null?void 0:l.call(i,n)},{checkForDefaultPrevented:!1})})})});DI.displayName=RI;var fO="MenuItemIndicator",[PI,KV]=os(fO,{checked:!1}),kI=w.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...i}=e,o=KV(fO,n);return c.jsx(Nn,{present:r||om(o.checked)||o.checked===!0,children:c.jsx(Ee.span,{...i,ref:t,"data-state":dO(o.checked)})})});kI.displayName=fO;var XV="MenuSeparator",$I=w.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return c.jsx(Ee.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});$I.displayName=XV;var QV="MenuArrow",II=w.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,i=Hp(n);return c.jsx(Bp,{...i,...r,ref:t})});II.displayName=QV;var ZV="MenuSub",[Xge,LI]=os(ZV),Nu="MenuSubTrigger",zI=w.forwardRef((e,t)=>{const n=ss(Nu,e.__scopeMenu),r=Uf(Nu,e.__scopeMenu),i=LI(Nu,e.__scopeMenu),o=lO(Nu,e.__scopeMenu),l=w.useRef(null),{pointerGraceTimerRef:u,onPointerGraceIntentChange:d}=o,h={__scopeMenu:e.__scopeMenu},v=w.useCallback(()=>{l.current&&window.clearTimeout(l.current),l.current=null},[]);return w.useEffect(()=>v,[v]),w.useEffect(()=>{const p=u.current;return()=>{window.clearTimeout(p),d(null)}},[u,d]),c.jsx(oO,{asChild:!0,...h,children:c.jsx(NI,{id:i.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":i.contentId,"data-state":UI(n.open),...e,ref:Lf(t,i.onTriggerChange),onClick:p=>{var g;(g=e.onClick)==null||g.call(e,p),!(e.disabled||p.defaultPrevented)&&(p.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:ye(e.onPointerMove,Yu(p=>{o.onItemEnter(p),!p.defaultPrevented&&!e.disabled&&!n.open&&!l.current&&(o.onPointerGraceIntentChange(null),l.current=window.setTimeout(()=>{n.onOpenChange(!0),v()},100))})),onPointerLeave:ye(e.onPointerLeave,Yu(p=>{var b,O;v();const g=(b=n.content)==null?void 0:b.getBoundingClientRect();if(g){const j=(O=n.content)==null?void 0:O.dataset.side,x=j==="right",_=x?-5:5,A=g[x?"left":"right"],E=g[x?"right":"left"];o.onPointerGraceIntentChange({area:[{x:p.clientX+_,y:p.clientY},{x:A,y:g.top},{x:E,y:g.top},{x:E,y:g.bottom},{x:A,y:g.bottom}],side:j}),window.clearTimeout(u.current),u.current=window.setTimeout(()=>o.onPointerGraceIntentChange(null),300)}else{if(o.onTriggerLeave(p),p.defaultPrevented)return;o.onPointerGraceIntentChange(null)}})),onKeyDown:ye(e.onKeyDown,p=>{var b;const g=o.searchRef.current!=="";e.disabled||g&&p.key===" "||RV[r.dir].includes(p.key)&&(n.onOpenChange(!0),(b=n.content)==null||b.focus(),p.preventDefault())})})})});zI.displayName=Nu;var BI="MenuSubContent",qI=w.forwardRef((e,t)=>{const n=OI(Cr,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,o=ss(Cr,e.__scopeMenu),l=Uf(Cr,e.__scopeMenu),u=LI(BI,e.__scopeMenu),d=w.useRef(null),h=Be(t,d);return c.jsx(Vu.Provider,{scope:e.__scopeMenu,children:c.jsx(Nn,{present:r||o.open,children:c.jsx(Vu.Slot,{scope:e.__scopeMenu,children:c.jsx(cO,{id:u.contentId,"aria-labelledby":u.triggerId,...i,ref:h,align:"start",side:l.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:v=>{var p;l.isUsingKeyboardRef.current&&((p=d.current)==null||p.focus()),v.preventDefault()},onCloseAutoFocus:v=>v.preventDefault(),onFocusOutside:ye(e.onFocusOutside,v=>{v.target!==u.trigger&&o.onOpenChange(!1)}),onEscapeKeyDown:ye(e.onEscapeKeyDown,v=>{l.onClose(),v.preventDefault()}),onKeyDown:ye(e.onKeyDown,v=>{var b;const p=v.currentTarget.contains(v.target),g=DV[l.dir].includes(v.key);p&&g&&(o.onOpenChange(!1),(b=u.trigger)==null||b.focus(),v.preventDefault())})})})})})});qI.displayName=BI;function UI(e){return e?"open":"closed"}function om(e){return e==="indeterminate"}function dO(e){return om(e)?"indeterminate":e?"checked":"unchecked"}function JV(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function eY(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function tY(e,t,n){const i=t.length>1&&Array.from(t).every(h=>h===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let l=eY(e,Math.max(o,0));i.length===1&&(l=l.filter(h=>h!==n));const d=l.find(h=>h.toLowerCase().startsWith(i.toLowerCase()));return d!==n?d:void 0}function nY(e,t){const{x:n,y:r}=e;let i=!1;for(let o=0,l=t.length-1;o<t.length;l=o++){const u=t[o],d=t[l],h=u.x,v=u.y,p=d.x,g=d.y;v>r!=g>r&&n<(p-h)*(r-v)/(g-v)+h&&(i=!i)}return i}function rY(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return nY(n,t)}function Yu(e){return t=>t.pointerType==="mouse"?e(t):void 0}var aY=jI,iY=oO,oY=_I,sY=EI,lY=uO,cY=AI,uY=Fp,fY=CI,dY=MI,hY=DI,mY=kI,pY=$I,vY=II,gY=zI,yY=qI,Gp="DropdownMenu",[bY]=jn(Gp,[wI]),Cn=wI(),[xY,HI]=bY(Gp),FI=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:o,onOpenChange:l,modal:u=!0}=e,d=Cn(t),h=w.useRef(null),[v,p]=An({prop:i,defaultProp:o??!1,onChange:l,caller:Gp});return c.jsx(xY,{scope:t,triggerId:Nr(),triggerRef:h,contentId:Nr(),open:v,onOpenChange:p,onOpenToggle:w.useCallback(()=>p(g=>!g),[p]),modal:u,children:c.jsx(aY,{...d,open:v,onOpenChange:p,dir:r,modal:u,children:n})})};FI.displayName=Gp;var GI="DropdownMenuTrigger",VI=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,o=HI(GI,n),l=Cn(n);return c.jsx(iY,{asChild:!0,...l,children:c.jsx(Ee.button,{type:"button",id:o.triggerId,"aria-haspopup":"menu","aria-expanded":o.open,"aria-controls":o.open?o.contentId:void 0,"data-state":o.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...i,ref:Lf(t,o.triggerRef),onPointerDown:ye(e.onPointerDown,u=>{!r&&u.button===0&&u.ctrlKey===!1&&(o.onOpenToggle(),o.open||u.preventDefault())}),onKeyDown:ye(e.onKeyDown,u=>{r||(["Enter"," "].includes(u.key)&&o.onOpenToggle(),u.key==="ArrowDown"&&o.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(u.key)&&u.preventDefault())})})})});VI.displayName=GI;var wY="DropdownMenuPortal",YI=e=>{const{__scopeDropdownMenu:t,...n}=e,r=Cn(t);return c.jsx(oY,{...r,...n})};YI.displayName=wY;var WI="DropdownMenuContent",KI=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=HI(WI,n),o=Cn(n),l=w.useRef(!1);return c.jsx(sY,{id:i.contentId,"aria-labelledby":i.triggerId,...o,...r,ref:t,onCloseAutoFocus:ye(e.onCloseAutoFocus,u=>{var d;l.current||(d=i.triggerRef.current)==null||d.focus(),l.current=!1,u.preventDefault()}),onInteractOutside:ye(e.onInteractOutside,u=>{const d=u.detail.originalEvent,h=d.button===0&&d.ctrlKey===!0,v=d.button===2||h;(!i.modal||v)&&(l.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});KI.displayName=WI;var SY="DropdownMenuGroup",jY=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(lY,{...i,...r,ref:t})});jY.displayName=SY;var OY="DropdownMenuLabel",XI=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(cY,{...i,...r,ref:t})});XI.displayName=OY;var _Y="DropdownMenuItem",QI=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(uY,{...i,...r,ref:t})});QI.displayName=_Y;var EY="DropdownMenuCheckboxItem",ZI=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(fY,{...i,...r,ref:t})});ZI.displayName=EY;var AY="DropdownMenuRadioGroup",NY=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(dY,{...i,...r,ref:t})});NY.displayName=AY;var CY="DropdownMenuRadioItem",TY=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(hY,{...i,...r,ref:t})});TY.displayName=CY;var MY="DropdownMenuItemIndicator",JI=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(mY,{...i,...r,ref:t})});JI.displayName=MY;var RY="DropdownMenuSeparator",e3=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(pY,{...i,...r,ref:t})});e3.displayName=RY;var DY="DropdownMenuArrow",PY=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(vY,{...i,...r,ref:t})});PY.displayName=DY;var kY="DropdownMenuSubTrigger",$Y=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(gY,{...i,...r,ref:t})});$Y.displayName=kY;var IY="DropdownMenuSubContent",LY=w.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Cn(n);return c.jsx(yY,{...i,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});LY.displayName=IY;var zY=FI,BY=VI,qY=YI,UY=KI,HY=XI,FY=QI,GY=ZI,VY=JI,YY=e3;function t3({...e}){return c.jsx(zY,{"data-slot":"dropdown-menu",...e})}function n3({...e}){return c.jsx(BY,{"data-slot":"dropdown-menu-trigger",...e})}function r3({className:e,sideOffset:t=4,...n}){return c.jsx(qY,{children:c.jsx(UY,{className:me("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 z-50 max-h-[--radix-dropdown-menu-content-available-height] min-w-[8rem] origin-[--radix-dropdown-menu-content-transform-origin] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=closed]:animate-out data-[state=open]:animate-in",e),"data-slot":"dropdown-menu-content",sideOffset:t,...n})})}function IC({className:e,inset:t,variant:n="default",...r}){return c.jsx(FY,{className:me("data-[variant=destructive]:*:[svg]:!text-destructive relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[inset]:pl-8 data-[variant=destructive]:text-destructive data-[disabled]:opacity-50 data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0",e),"data-inset":t,"data-slot":"dropdown-menu-item","data-variant":n,...r})}function WY({className:e,children:t,checked:n,...r}){return c.jsxs(GY,{checked:n,className:me("relative flex cursor-default select-none items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0",e),"data-slot":"dropdown-menu-checkbox-item",...r,children:[c.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:c.jsx(VY,{children:c.jsx(Ja,{className:"size-4"})})}),t]})}function a3({className:e,inset:t,...n}){return c.jsx(HY,{className:me("px-2 py-1.5 font-medium text-sm data-[inset]:pl-8",e),"data-inset":t,"data-slot":"dropdown-menu-label",...n})}function X1({className:e,...t}){return c.jsx(YY,{className:me("-mx-1 my-1 h-px bg-border",e),"data-slot":"dropdown-menu-separator",...t})}const LC=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,zC=rt,sc=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return zC(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:i,defaultVariants:o}=t,l=Object.keys(i).map(h=>{const v=n==null?void 0:n[h],p=o==null?void 0:o[h];if(v===null)return null;const g=LC(v)||LC(p);return i[h][g]}),u=n&&Object.entries(n).reduce((h,v)=>{let[p,g]=v;return g===void 0||(h[p]=g),h},{}),d=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((h,v)=>{let{class:p,className:g,...b}=v;return Object.entries(b).every(O=>{let[j,x]=O;return Array.isArray(x)?x.includes({...o,...u}[j]):{...o,...u}[j]===x})?[...h,p,g]:h},[]);return zC(e,l,d,n==null?void 0:n.class,n==null?void 0:n.className)},hO=sc("inline-flex shrink-0 items-center justify-center gap-2 whitespace-nowrap rounded-md font-medium text-sm outline-none transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}});function Ce({className:e,variant:t,size:n,asChild:r=!1,...i}){const o=r?as:"button";return c.jsx(o,{className:me(hO({variant:t,size:n,className:e})),"data-slot":"button",...i})}const ls=w.forwardRef(({className:e,type:t,...n},r)=>c.jsx("input",{className:me("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:font-medium file:text-foreground file:text-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,type:t,...n}));ls.displayName="Input";var KY="Separator",BC="horizontal",XY=["horizontal","vertical"],i3=w.forwardRef((e,t)=>{const{decorative:n,orientation:r=BC,...i}=e,o=QY(r)?r:BC,u=n?{role:"none"}:{"aria-orientation":o==="vertical"?o:void 0,role:"separator"};return c.jsx(is.div,{"data-orientation":o,...u,...i,ref:t})});i3.displayName=KY;function QY(e){return XY.includes(e)}var ZY=i3;function Bt({className:e,orientation:t="horizontal",decorative:n=!0,...r}){return c.jsx(ZY,{className:me("shrink-0 bg-border data-[orientation=horizontal]:h-px data-[orientation=vertical]:h-full data-[orientation=horizontal]:w-full data-[orientation=vertical]:w-px",e),"data-slot":"separator",decorative:n,orientation:t,...r})}var Vp="Dialog",[o3,s3]=jn(Vp),[JY,Qr]=o3(Vp),l3=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:l=!0}=e,u=w.useRef(null),d=w.useRef(null),[h,v]=An({prop:r,defaultProp:i??!1,onChange:o,caller:Vp});return c.jsx(JY,{scope:t,triggerRef:u,contentRef:d,contentId:Nr(),titleId:Nr(),descriptionId:Nr(),open:h,onOpenChange:v,onOpenToggle:w.useCallback(()=>v(p=>!p),[v]),modal:l,children:n})};l3.displayName=Vp;var c3="DialogTrigger",u3=w.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Qr(c3,n),o=Be(t,i.triggerRef);return c.jsx(Ee.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":vO(i.open),...r,ref:o,onClick:ye(e.onClick,i.onOpenToggle)})});u3.displayName=c3;var mO="DialogPortal",[eW,f3]=o3(mO,{forceMount:void 0}),d3=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:i}=e,o=Qr(mO,t);return c.jsx(eW,{scope:t,forceMount:n,children:w.Children.map(r,l=>c.jsx(Nn,{present:n||o.open,children:c.jsx(ic,{asChild:!0,container:i,children:l})}))})};d3.displayName=mO;var sm="DialogOverlay",h3=w.forwardRef((e,t)=>{const n=f3(sm,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=Qr(sm,e.__scopeDialog);return o.modal?c.jsx(Nn,{present:r||o.open,children:c.jsx(nW,{...i,ref:t})}):null});h3.displayName=sm;var tW=Ol("DialogOverlay.RemoveScroll"),nW=w.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Qr(sm,n);return c.jsx(Up,{as:tW,allowPinchZoom:!0,shards:[i.contentRef],children:c.jsx(Ee.div,{"data-state":vO(i.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Wo="DialogContent",m3=w.forwardRef((e,t)=>{const n=f3(Wo,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=Qr(Wo,e.__scopeDialog);return c.jsx(Nn,{present:r||o.open,children:o.modal?c.jsx(rW,{...i,ref:t}):c.jsx(aW,{...i,ref:t})})});m3.displayName=Wo;var rW=w.forwardRef((e,t)=>{const n=Qr(Wo,e.__scopeDialog),r=w.useRef(null),i=Be(t,n.contentRef,r);return w.useEffect(()=>{const o=r.current;if(o)return iO(o)},[]),c.jsx(p3,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ye(e.onCloseAutoFocus,o=>{var l;o.preventDefault(),(l=n.triggerRef.current)==null||l.focus()}),onPointerDownOutside:ye(e.onPointerDownOutside,o=>{const l=o.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0;(l.button===2||u)&&o.preventDefault()}),onFocusOutside:ye(e.onFocusOutside,o=>o.preventDefault())})}),aW=w.forwardRef((e,t)=>{const n=Qr(Wo,e.__scopeDialog),r=w.useRef(!1),i=w.useRef(!1);return c.jsx(p3,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var l,u;(l=e.onCloseAutoFocus)==null||l.call(e,o),o.defaultPrevented||(r.current||(u=n.triggerRef.current)==null||u.focus(),o.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:o=>{var d,h;(d=e.onInteractOutside)==null||d.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const l=o.target;((h=n.triggerRef.current)==null?void 0:h.contains(l))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}})}),p3=w.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,...l}=e,u=Qr(Wo,n),d=w.useRef(null),h=Be(t,d);return Wj(),c.jsxs(c.Fragment,{children:[c.jsx(Mp,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o,children:c.jsx(nc,{role:"dialog",id:u.contentId,"aria-describedby":u.descriptionId,"aria-labelledby":u.titleId,"data-state":vO(u.open),...l,ref:h,onDismiss:()=>u.onOpenChange(!1)})}),c.jsxs(c.Fragment,{children:[c.jsx(oW,{titleId:u.titleId}),c.jsx(lW,{contentRef:d,descriptionId:u.descriptionId})]})]})}),pO="DialogTitle",v3=w.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Qr(pO,n);return c.jsx(Ee.h2,{id:i.titleId,...r,ref:t})});v3.displayName=pO;var g3="DialogDescription",y3=w.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Qr(g3,n);return c.jsx(Ee.p,{id:i.descriptionId,...r,ref:t})});y3.displayName=g3;var b3="DialogClose",x3=w.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Qr(b3,n);return c.jsx(Ee.button,{type:"button",...r,ref:t,onClick:ye(e.onClick,()=>i.onOpenChange(!1))})});x3.displayName=b3;function vO(e){return e?"open":"closed"}var w3="DialogTitleWarning",[iW,S3]=z9(w3,{contentName:Wo,titleName:pO,docsSlug:"dialog"}),oW=({titleId:e})=>{const t=S3(w3),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
389
+
390
+ If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
391
+
392
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return w.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},sW="DialogDescriptionWarning",lW=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${S3(sW).contentName}}.`;return w.useEffect(()=>{var o;const i=(o=e.current)==null?void 0:o.getAttribute("aria-describedby");t&&i&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},gO=l3,cW=u3,yO=d3,bO=h3,xO=m3,wO=v3,SO=y3,Yp=x3;function uW({...e}){return c.jsx(gO,{"data-slot":"sheet",...e})}function fW({...e}){return c.jsx(yO,{"data-slot":"sheet-portal",...e})}function dW({className:e,...t}){return c.jsx(bO,{className:me("data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=open]:animate-in",e),"data-slot":"sheet-overlay",...t})}function hW({className:e,children:t,side:n="right",...r}){return c.jsxs(fW,{children:[c.jsx(dW,{}),c.jsxs(xO,{className:me("fixed z-50 flex flex-col gap-4 bg-background shadow-lg transition ease-in-out data-[state=closed]:animate-out data-[state=open]:animate-in data-[state=closed]:duration-300 data-[state=open]:duration-500",n==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",n==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",n==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",n==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",e),"data-slot":"sheet-content",...r,children:[t,c.jsxs(Yp,{className:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[c.jsx(ir,{className:"size-4"}),c.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function mW({className:e,...t}){return c.jsx("div",{className:me("flex flex-col gap-1.5 p-4",e),"data-slot":"sheet-header",...t})}function pW({className:e,...t}){return c.jsx(wO,{className:me("font-semibold text-foreground",e),"data-slot":"sheet-title",...t})}function vW({className:e,...t}){return c.jsx(SO,{className:me("text-muted-foreground text-sm",e),"data-slot":"sheet-description",...t})}function Ne({className:e,...t}){return c.jsx("div",{className:me("animate-pulse rounded-md bg-accent",e),"data-slot":"skeleton",...t})}var j3=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"}),gW="VisuallyHidden",O3=w.forwardRef((e,t)=>c.jsx(Ee.span,{...e,ref:t,style:{...j3,...e.style}}));O3.displayName=gW;var yW=O3,[Wp]=jn("Tooltip",[to]),Kp=to(),_3="TooltipProvider",bW=700,Q1="tooltip.open",[xW,jO]=Wp(_3),E3=e=>{const{__scopeTooltip:t,delayDuration:n=bW,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:o}=e,l=w.useRef(!0),u=w.useRef(!1),d=w.useRef(0);return w.useEffect(()=>{const h=d.current;return()=>window.clearTimeout(h)},[]),c.jsx(xW,{scope:t,isOpenDelayedRef:l,delayDuration:n,onOpen:w.useCallback(()=>{window.clearTimeout(d.current),l.current=!1},[]),onClose:w.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>l.current=!0,r)},[r]),isPointerInTransitRef:u,onPointerInTransitChange:w.useCallback(h=>{u.current=h},[]),disableHoverableContent:i,children:o})};E3.displayName=_3;var Wu="Tooltip",[wW,Hf]=Wp(Wu),A3=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:o,disableHoverableContent:l,delayDuration:u}=e,d=jO(Wu,e.__scopeTooltip),h=Kp(t),[v,p]=w.useState(null),g=Nr(),b=w.useRef(0),O=l??d.disableHoverableContent,j=u??d.delayDuration,x=w.useRef(!1),[_,A]=An({prop:r,defaultProp:i??!1,onChange:R=>{R?(d.onOpen(),document.dispatchEvent(new CustomEvent(Q1))):d.onClose(),o==null||o(R)},caller:Wu}),E=w.useMemo(()=>_?x.current?"delayed-open":"instant-open":"closed",[_]),C=w.useCallback(()=>{window.clearTimeout(b.current),b.current=0,x.current=!1,A(!0)},[A]),N=w.useCallback(()=>{window.clearTimeout(b.current),b.current=0,A(!1)},[A]),M=w.useCallback(()=>{window.clearTimeout(b.current),b.current=window.setTimeout(()=>{x.current=!0,A(!0),b.current=0},j)},[j,A]);return w.useEffect(()=>()=>{b.current&&(window.clearTimeout(b.current),b.current=0)},[]),c.jsx(Ip,{...h,children:c.jsx(wW,{scope:t,contentId:g,open:_,stateAttribute:E,trigger:v,onTriggerChange:p,onTriggerEnter:w.useCallback(()=>{d.isOpenDelayedRef.current?M():C()},[d.isOpenDelayedRef,M,C]),onTriggerLeave:w.useCallback(()=>{O?N():(window.clearTimeout(b.current),b.current=0)},[N,O]),onOpen:C,onClose:N,disableHoverableContent:O,children:n})})};A3.displayName=Wu;var Z1="TooltipTrigger",N3=w.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Hf(Z1,n),o=jO(Z1,n),l=Kp(n),u=w.useRef(null),d=Be(t,u,i.onTriggerChange),h=w.useRef(!1),v=w.useRef(!1),p=w.useCallback(()=>h.current=!1,[]);return w.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),c.jsx(Lp,{asChild:!0,...l,children:c.jsx(Ee.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:d,onPointerMove:ye(e.onPointerMove,g=>{g.pointerType!=="touch"&&!v.current&&!o.isPointerInTransitRef.current&&(i.onTriggerEnter(),v.current=!0)}),onPointerLeave:ye(e.onPointerLeave,()=>{i.onTriggerLeave(),v.current=!1}),onPointerDown:ye(e.onPointerDown,()=>{i.open&&i.onClose(),h.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:ye(e.onFocus,()=>{h.current||i.onOpen()}),onBlur:ye(e.onBlur,i.onClose),onClick:ye(e.onClick,i.onClose)})})});N3.displayName=Z1;var OO="TooltipPortal",[SW,jW]=Wp(OO,{forceMount:void 0}),C3=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,o=Hf(OO,t);return c.jsx(SW,{scope:t,forceMount:n,children:c.jsx(Nn,{present:n||o.open,children:c.jsx(ic,{asChild:!0,container:i,children:r})})})};C3.displayName=OO;var El="TooltipContent",T3=w.forwardRef((e,t)=>{const n=jW(El,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...o}=e,l=Hf(El,e.__scopeTooltip);return c.jsx(Nn,{present:r||l.open,children:l.disableHoverableContent?c.jsx(M3,{side:i,...o,ref:t}):c.jsx(OW,{side:i,...o,ref:t})})}),OW=w.forwardRef((e,t)=>{const n=Hf(El,e.__scopeTooltip),r=jO(El,e.__scopeTooltip),i=w.useRef(null),o=Be(t,i),[l,u]=w.useState(null),{trigger:d,onClose:h}=n,v=i.current,{onPointerInTransitChange:p}=r,g=w.useCallback(()=>{u(null),p(!1)},[p]),b=w.useCallback((O,j)=>{const x=O.currentTarget,_={x:O.clientX,y:O.clientY},A=NW(_,x.getBoundingClientRect()),E=CW(_,A),C=TW(j.getBoundingClientRect()),N=RW([...E,...C]);u(N),p(!0)},[p]);return w.useEffect(()=>()=>g(),[g]),w.useEffect(()=>{if(d&&v){const O=x=>b(x,v),j=x=>b(x,d);return d.addEventListener("pointerleave",O),v.addEventListener("pointerleave",j),()=>{d.removeEventListener("pointerleave",O),v.removeEventListener("pointerleave",j)}}},[d,v,b,g]),w.useEffect(()=>{if(l){const O=j=>{const x=j.target,_={x:j.clientX,y:j.clientY},A=(d==null?void 0:d.contains(x))||(v==null?void 0:v.contains(x)),E=!MW(_,l);A?g():E&&(g(),h())};return document.addEventListener("pointermove",O),()=>document.removeEventListener("pointermove",O)}},[d,v,l,h,g]),c.jsx(M3,{...e,ref:o})}),[_W,EW]=Wp(Wu,{isInside:!1}),AW=k$("TooltipContent"),M3=w.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:o,onPointerDownOutside:l,...u}=e,d=Hf(El,n),h=Kp(n),{onClose:v}=d;return w.useEffect(()=>(document.addEventListener(Q1,v),()=>document.removeEventListener(Q1,v)),[v]),w.useEffect(()=>{if(d.trigger){const p=g=>{const b=g.target;b!=null&&b.contains(d.trigger)&&v()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[d.trigger,v]),c.jsx(nc,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:l,onFocusOutside:p=>p.preventDefault(),onDismiss:v,children:c.jsxs(zp,{"data-state":d.stateAttribute,...h,...u,ref:t,style:{...u.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:[c.jsx(AW,{children:r}),c.jsx(_W,{scope:n,isInside:!0,children:c.jsx(yW,{id:d.contentId,role:"tooltip",children:i||r})})]})})});T3.displayName=El;var R3="TooltipArrow",D3=w.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Kp(n);return EW(R3,n).isInside?null:c.jsx(Bp,{...i,...r,ref:t})});D3.displayName=R3;function NW(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function CW(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function TW(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function MW(e,t){const{x:n,y:r}=e;let i=!1;for(let o=0,l=t.length-1;o<t.length;l=o++){const u=t[o],d=t[l],h=u.x,v=u.y,p=d.x,g=d.y;v>r!=g>r&&n<(p-h)*(r-v)/(g-v)+h&&(i=!i)}return i}function RW(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),DW(t)}function DW(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const o=t[t.length-1],l=t[t.length-2];if((o.x-l.x)*(i.y-l.y)>=(o.y-l.y)*(i.x-l.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const o=n[n.length-1],l=n[n.length-2];if((o.x-l.x)*(i.y-l.y)>=(o.y-l.y)*(i.x-l.x))n.pop();else break}n.push(i)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var PW=E3,kW=A3,$W=N3,IW=C3,LW=T3,zW=D3;function P3({delayDuration:e=0,...t}){return c.jsx(PW,{"data-slot":"tooltip-provider",delayDuration:e,...t})}function Xp({...e}){return c.jsx(P3,{children:c.jsx(kW,{"data-slot":"tooltip",...e})})}function Qp({...e}){return c.jsx($W,{"data-slot":"tooltip-trigger",...e})}function Zp({className:e,sideOffset:t=0,children:n,...r}){return c.jsx(IW,{children:c.jsxs(LW,{className:me("fade-in-0 zoom-in-95 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 z-50 w-fit origin-[--radix-tooltip-content-transform-origin] animate-in text-balance rounded-md bg-foreground px-3 py-1.5 text-background text-xs data-[state=closed]:animate-out",e),"data-slot":"tooltip-content",sideOffset:t,...r,children:[n,c.jsx(zW,{className:"z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground"})]})})}const Tb=768;function BW(){const[e,t]=w.useState(void 0);return w.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Tb-1}px)`),r=()=>{t(window.innerWidth<Tb)};return n.addEventListener("change",r),t(window.innerWidth<Tb),()=>n.removeEventListener("change",r)},[]),!!e}const qW="sidebar_state",UW=3600*24*7,HW="16rem",FW="18rem",GW="3rem",VW="b",k3=w.createContext(null);function lc(){const e=w.useContext(k3);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const $3=w.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:i,children:o,...l},u)=>{const d=BW(),[h,v]=w.useState(!1),[p,g]=w.useState(e),b=t??p,O=w.useCallback(A=>{const E=typeof A=="function"?A(b):A;n?n(E):g(E),document.cookie=`${qW}=${E}; path=/; max-age=${UW}`},[n,b]),j=w.useCallback(()=>d?v(A=>!A):O(A=>!A),[d,O]);w.useEffect(()=>{const A=E=>{E.key===VW&&(E.metaKey||E.ctrlKey)&&(E.preventDefault(),j())};return window.addEventListener("keydown",A),()=>window.removeEventListener("keydown",A)},[j]);const x=b?"expanded":"collapsed",_=w.useMemo(()=>({state:x,open:b,setOpen:O,isMobile:d,openMobile:h,setOpenMobile:v,toggleSidebar:j}),[x,b,O,d,h,j]);return c.jsx(k3.Provider,{value:_,children:c.jsx(P3,{delayDuration:0,children:c.jsx("div",{className:me("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",r),ref:u,style:{"--sidebar-width":HW,"--sidebar-width-icon":GW,...i},...l,children:o})})})});$3.displayName="SidebarProvider";const Yh=w.forwardRef(({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:i,...o},l)=>{const{isMobile:u,state:d,openMobile:h,setOpenMobile:v}=lc();return n==="none"?c.jsx("div",{className:me("flex h-full w-[calc(var(--sidebar-width)-var(--sidebar-width-icon)+1px)]! flex-col bg-sidebar text-sidebar-foreground",r),ref:l,...o,children:i}):u?c.jsx(uW,{onOpenChange:v,open:h,...o,children:c.jsxs(hW,{className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden","data-mobile":"true","data-sidebar":"sidebar",side:e,style:{"--sidebar-width":FW},children:[c.jsxs(mW,{className:"sr-only",children:[c.jsx(pW,{children:"Sidebar"}),c.jsx(vW,{children:"Displays the mobile sidebar."})]}),c.jsx("div",{className:"flex h-full w-full flex-col",children:i})]})}):c.jsxs("div",{className:"group peer hidden text-sidebar-foreground md:block","data-collapsible":d==="collapsed"?n:"","data-side":e,"data-state":d,"data-variant":t,ref:l,children:[c.jsx("div",{className:me("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),c.jsx("div",{className:me("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",r),...o,children:c.jsx("div",{className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow","data-sidebar":"sidebar",children:i})})]})});Yh.displayName="Sidebar";const I3=w.forwardRef(({className:e,onClick:t,...n},r)=>{const{toggleSidebar:i}=lc();return c.jsxs(Ce,{className:me("h-7 w-7",e),"data-sidebar":"trigger",onClick:o=>{t==null||t(o),i()},ref:r,size:"icon",variant:"ghost",...n,children:[c.jsx(OF,{}),c.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})});I3.displayName="SidebarTrigger";const YW=w.forwardRef(({className:e,...t},n)=>{const{toggleSidebar:r}=lc();return c.jsx("button",{"aria-label":"Toggle Sidebar",className:me("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:hover:bg-sidebar group-data-[collapsible=offcanvas]:after:left-full","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),"data-sidebar":"rail",onClick:r,ref:n,tabIndex:-1,title:"Toggle Sidebar",...t})});YW.displayName="SidebarRail";const L3=w.forwardRef(({className:e,...t},n)=>c.jsx("main",{className:me("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",e),ref:n,...t}));L3.displayName="SidebarInset";const z3=w.forwardRef(({className:e,...t},n)=>c.jsx(ls,{className:me("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),"data-sidebar":"input",ref:n,...t}));z3.displayName="SidebarInput";const J1=w.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:me("flex flex-col gap-2 p-2",e),"data-sidebar":"header",ref:n,...t}));J1.displayName="SidebarHeader";const B3=w.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:me("flex flex-col gap-2 p-2",e),"data-sidebar":"footer",ref:n,...t}));B3.displayName="SidebarFooter";const WW=w.forwardRef(({className:e,...t},n)=>c.jsx(Bt,{className:me("mx-2 w-auto bg-sidebar-border",e),"data-sidebar":"separator",ref:n,...t}));WW.displayName="SidebarSeparator";const eS=w.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:me("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),"data-sidebar":"content",ref:n,...t}));eS.displayName="SidebarContent";const tS=w.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:me("relative flex w-full min-w-0 flex-col p-2",e),"data-sidebar":"group",ref:n,...t}));tS.displayName="SidebarGroup";const KW=w.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const i=t?as:"div";return c.jsx(i,{className:me("flex h-8 shrink-0 items-center rounded-md px-2 font-medium text-sidebar-foreground/70 text-xs outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),"data-sidebar":"group-label",ref:r,...n})});KW.displayName="SidebarGroupLabel";const XW=w.forwardRef(({className:e,asChild:t=!1,...n},r)=>{const i=t?as:"button";return c.jsx(i,{className:me("absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),"data-sidebar":"group-action",ref:r,...n})});XW.displayName="SidebarGroupAction";const nS=w.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:me("w-full text-sm",e),"data-sidebar":"group-content",ref:n,...t}));nS.displayName="SidebarGroupContent";const lm=w.forwardRef(({className:e,...t},n)=>c.jsx("ul",{className:me("flex w-full min-w-0 flex-col gap-1",e),"data-sidebar":"menu",ref:n,...t}));lm.displayName="SidebarMenu";const cm=w.forwardRef(({className:e,...t},n)=>c.jsx("li",{className:me("group/menu-item relative",e),"data-sidebar":"menu-item",ref:n,...t}));cm.displayName="SidebarMenuItem";const QW=sc("peer/menu-button group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"group-data-[collapsible=icon]:!p-0 h-12 text-sm"}},defaultVariants:{variant:"default",size:"default"}}),um=w.forwardRef(({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:i,className:o,...l},u)=>{const d=e?as:"button",{isMobile:h,state:v}=lc(),p=c.jsx(d,{className:me(QW({variant:n,size:r}),o),"data-active":t,"data-sidebar":"menu-button","data-size":r,ref:u,...l});return i?(typeof i=="string"&&(i={children:i}),c.jsxs(Xp,{children:[c.jsx(Qp,{asChild:!0,children:p}),c.jsx(Zp,{align:"center",hidden:v!=="collapsed"||h,side:"right",...i})]})):p});um.displayName="SidebarMenuButton";const ZW=w.forwardRef(({className:e,asChild:t=!1,showOnHover:n=!1,...r},i)=>{const o=t?as:"button";return c.jsx(o,{className:me("absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",n&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",e),"data-sidebar":"menu-action",ref:i,...r})});ZW.displayName="SidebarMenuAction";const JW=w.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:me("pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 font-medium text-sidebar-foreground text-xs tabular-nums","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),"data-sidebar":"menu-badge",ref:n,...t}));JW.displayName="SidebarMenuBadge";const eK=w.forwardRef(({className:e,showIcon:t=!1,...n},r)=>{const i=w.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return c.jsxs("div",{className:me("flex h-8 items-center gap-2 rounded-md px-2",e),"data-sidebar":"menu-skeleton",ref:r,...n,children:[t&&c.jsx(Ne,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),c.jsx(Ne,{className:"h-4 max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":i}})]})});eK.displayName="SidebarMenuSkeleton";const tK=w.forwardRef(({className:e,...t},n)=>c.jsx("ul",{className:me("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-sidebar-border border-l px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),"data-sidebar":"menu-sub",ref:n,...t}));tK.displayName="SidebarMenuSub";const nK=w.forwardRef(({...e},t)=>c.jsx("li",{ref:t,...e}));nK.displayName="SidebarMenuSubItem";const rK=w.forwardRef(({asChild:e=!1,size:t="md",isActive:n,className:r,...i},o)=>{const l=e?as:"a";return c.jsx(l,{className:me("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",r),"data-active":n,"data-sidebar":"menu-sub-button","data-size":t,ref:o,...i})});rK.displayName="SidebarMenuSubButton";const aK={theme:"system",setTheme:()=>null},q3=w.createContext(aK),U3=()=>{const e=w.useContext(q3);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e};function iK({user:e}){const{isMobile:t}=lc(),{theme:n,setTheme:r}=U3(),[i,o]=w.useState(null),[l,u]=w.useState(0);w.useEffect(()=>{(async()=>{try{const g=sessionStorage.getItem("wraps-auth-token");if(!g){console.log("No auth token found yet, will retry..."),l<5&&setTimeout(()=>{u(O=>O+1)},200);return}console.log("Fetching user info from /api/user");const b=await fetch(`/api/user?token=${g}`);if(console.log("User API response status:",b.status),b.ok){const O=await b.json();console.log("User info received:",O),o(O)}else{const O=await b.text();console.error("Failed to fetch user info:",b.status,O)}}catch(g){console.error("Error fetching user info:",g)}})().catch(g=>{console.error("Failed to fetch user info:",g)})},[l]);const d=()=>{window.confirm("Are you sure you want to close the console?")&&window.close()},h=(i==null?void 0:i.accountAlias)||(i==null?void 0:i.accountId)||"Loading...",v=(i==null?void 0:i.region)||"...";return c.jsx(lm,{children:c.jsx(cm,{children:c.jsxs(t3,{children:[c.jsx(n3,{asChild:!0,children:c.jsxs(um,{className:"data-[state=open]:bg-sidebar-accent data-[state=open]:text-sidebar-accent-foreground md:h-8 md:p-0",size:"lg",children:[c.jsxs(uC,{className:"h-8 w-8 rounded-lg",children:[c.jsx(fC,{alt:h,src:e.avatar}),c.jsx(dC,{className:"rounded-lg bg-orange-500 text-white",children:"AWS"})]}),c.jsxs("div",{className:"grid flex-1 text-left text-sm leading-tight",children:[c.jsx("span",{className:"truncate font-medium",children:h}),c.jsx("span",{className:"truncate text-xs",children:v})]}),c.jsx(hF,{className:"ml-auto size-4"})]})}),c.jsxs(r3,{align:"end",className:"w-(--radix-dropdown-menu-trigger-width) min-w-56 rounded-lg",side:t?"bottom":"right",sideOffset:4,children:[c.jsx(a3,{className:"p-0 font-normal",children:c.jsxs("div",{className:"flex items-center gap-2 px-1 py-1.5 text-left text-sm",children:[c.jsxs(uC,{className:"h-8 w-8 rounded-lg",children:[c.jsx(fC,{alt:h,src:e.avatar}),c.jsx(dC,{className:"rounded-lg bg-orange-500 text-white",children:"AWS"})]}),c.jsxs("div",{className:"grid flex-1 text-left text-sm leading-tight",children:[c.jsx("span",{className:"truncate font-medium",children:h}),c.jsx("span",{className:"truncate text-xs",children:v}),(i==null?void 0:i.accountId)&&i.accountId!==i.accountAlias&&c.jsx("span",{className:"truncate font-mono text-[10px] text-muted-foreground",children:i.accountId})]})]})}),c.jsx(X1,{}),c.jsxs(IC,{onClick:()=>r(n==="dark"?"light":"dark"),children:[n==="dark"?c.jsx(EF,{}):c.jsx(SF,{}),n==="dark"?"Light Mode":"Dark Mode"]}),c.jsx(X1,{}),c.jsxs(IC,{onClick:d,children:[c.jsx(ir,{}),"Close Console"]})]})]})})})}const zi={user:{name:"Wraps Console",email:"admin@wraps.dev",avatar:"/avatars/wraps.jpg"},navMain:[{title:"Dashboard",url:"/",icon:Cp,isActive:!0,isDashboard:!0},{title:"Email",url:"#",icon:gl,isActive:!1,subItems:[{title:"Emails",icon:gl,url:"/email"},{title:"Metrics",icon:hb,url:"/email/metrics"},{title:"Settings",icon:pb,url:"/email/settings"}]},{title:"SMS",url:"#",icon:Ki,isActive:!1,subItems:[{title:"Messages",icon:Ki,url:"/sms"},{title:"Metrics",icon:hb,url:"/sms/metrics"},{title:"Settings",icon:pb,url:"/sms/settings"}]},{title:"CDN",url:"#",icon:$f,isActive:!1,subItems:[{title:"Library",icon:u$,url:"/cdn"},{title:"Metrics",icon:hb,url:"/cdn/metrics"},{title:"Settings",icon:pb,url:"/cdn/settings"}]}]};function oK({...e}){const t=ba(),n=ns(),{setOpen:r,state:i}=lc(),{theme:o}=U3(),l=w.useCallback(()=>t.pathname==="/"?zi.navMain[0]:t.pathname.startsWith("/email")?zi.navMain[1]:t.pathname.startsWith("/sms")?zi.navMain[2]:t.pathname.startsWith("/cdn")?zi.navMain[3]:zi.navMain[0],[t.pathname]),[u,d]=w.useState(l());return w.useEffect(()=>{d(l())},[l]),c.jsxs(Yh,{className:"overflow-hidden *:data-[sidebar=sidebar]:flex-row",collapsible:"icon",...e,children:[c.jsxs(Yh,{className:"w-[calc(var(--sidebar-width-icon)+1px)]! border-r",collapsible:"none",children:[c.jsx(J1,{children:c.jsx(lm,{children:c.jsx(cm,{children:c.jsx(um,{asChild:!0,className:"md:h-8 md:p-0",onClick:()=>{d(zi.navMain[0]),r(!1)},size:"lg",children:c.jsxs(Xh,{to:"/",children:[c.jsx("div",{className:"flex aspect-square size-8 items-center justify-center rounded-lg",children:c.jsx("img",{alt:"Wraps",className:"size-8 object-contain",src:o==="dark"?"/wraps-dark.png":"/wraps-light.png"})}),c.jsxs("div",{className:"grid flex-1 text-left text-sm leading-tight",children:[c.jsx("span",{className:"truncate font-semibold",children:"Wraps"}),c.jsx("span",{className:"truncate text-xs",children:"Console"})]})]})})})})}),c.jsx(eS,{children:c.jsx(tS,{children:c.jsx(nS,{className:"px-1.5 md:px-0",children:c.jsx(lm,{children:zi.navMain.filter(h=>!h.isDashboard).map(h=>c.jsx(cm,{children:c.jsxs(um,{className:"px-2.5 md:px-2",isActive:(u==null?void 0:u.title)===h.title,onClick:()=>{d(h),r(!0),h.subItems&&h.subItems.length>0&&n(h.subItems[0].url)},tooltip:{children:h.title,hidden:!1},children:[c.jsx(h.icon,{}),c.jsx("span",{children:h.title})]})},h.title))})})})}),c.jsx(B3,{children:c.jsx(iK,{user:zi.user})})]}),i==="expanded"&&c.jsx(Yh,{className:"hidden flex-1 md:flex",collapsible:"none",children:u&&!u.isDashboard&&u.subItems?c.jsxs(c.Fragment,{children:[c.jsxs(J1,{className:"gap-3.5 border-b p-4",children:[c.jsx("div",{className:"flex w-full items-center justify-between",children:c.jsxs("div",{className:"flex items-center gap-2 font-medium text-base text-foreground",children:[c.jsx(u.icon,{className:"size-4"}),u.title]})}),c.jsx(z3,{placeholder:"Search..."})]}),c.jsx(eS,{children:c.jsx(tS,{className:"px-0",children:c.jsx(nS,{children:u.subItems.map(h=>{const v=t.pathname===h.url||h.url==="/email"&&t.pathname.startsWith("/email/")&&t.pathname!=="/email/metrics"&&t.pathname!=="/email/settings"||h.url==="/sms"&&t.pathname.startsWith("/sms/")&&t.pathname!=="/sms/metrics"&&t.pathname!=="/sms/settings"||h.url==="/cdn"&&t.pathname.startsWith("/cdn/")&&t.pathname!=="/cdn/metrics"&&t.pathname!=="/cdn/settings";return c.jsxs(Xh,{className:`flex items-center gap-3 border-b p-4 text-sm leading-tight transition-colors last:border-b-0 hover:bg-sidebar-accent hover:text-sidebar-accent-foreground ${v?"bg-sidebar-accent font-semibold text-sidebar-accent-foreground":""}`,to:h.url,children:[c.jsx(h.icon,{className:"size-4 shrink-0"}),c.jsx("span",{className:"font-medium",children:h.title})]},h.title)})})})})]}):c.jsx("div",{className:"flex h-full items-center justify-center p-8 text-center",children:c.jsxs("div",{className:"text-muted-foreground",children:[c.jsx(Cp,{className:"mx-auto mb-4 size-12 opacity-50"}),c.jsx("p",{className:"text-sm",children:"Select a product to view options"})]})})})]})}function sK(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const lK=e=>{switch(e){case"success":return fK;case"info":return hK;case"warning":return dK;case"error":return mK;default:return null}},cK=Array(12).fill(0),uK=({visible:e,className:t})=>I.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},I.createElement("div",{className:"sonner-spinner"},cK.map((n,r)=>I.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),fK=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},I.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"})),dK=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},I.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"})),hK=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},I.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"})),mK=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},I.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"})),pK=I.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"},I.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),I.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),vK=()=>{const[e,t]=I.useState(document.hidden);return I.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let rS=1;class gK{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:r,...i}=t,o=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:rS++,l=this.toasts.find(d=>d.id===o),u=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),l?this.toasts=this.toasts.map(d=>d.id===o?(this.publish({...d,...t,id:o,title:r}),{...d,...t,id:o,dismissible:u,title:r}):d):this.addToast({title:r,...i,dismissible:u,id:o}),o},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const i=Promise.resolve(t instanceof Function?t():t);let o=r!==void 0,l;const u=i.then(async h=>{if(l=["resolve",h],I.isValidElement(h))o=!1,this.create({id:r,type:"default",message:h});else if(bK(h)&&!h.ok){o=!1;const p=typeof n.error=="function"?await n.error(`HTTP error! status: ${h.status}`):n.error,g=typeof n.description=="function"?await n.description(`HTTP error! status: ${h.status}`):n.description,O=typeof p=="object"&&!I.isValidElement(p)?p:{message:p};this.create({id:r,type:"error",description:g,...O})}else if(h instanceof Error){o=!1;const p=typeof n.error=="function"?await n.error(h):n.error,g=typeof n.description=="function"?await n.description(h):n.description,O=typeof p=="object"&&!I.isValidElement(p)?p:{message:p};this.create({id:r,type:"error",description:g,...O})}else if(n.success!==void 0){o=!1;const p=typeof n.success=="function"?await n.success(h):n.success,g=typeof n.description=="function"?await n.description(h):n.description,O=typeof p=="object"&&!I.isValidElement(p)?p:{message:p};this.create({id:r,type:"success",description:g,...O})}}).catch(async h=>{if(l=["reject",h],n.error!==void 0){o=!1;const v=typeof n.error=="function"?await n.error(h):n.error,p=typeof n.description=="function"?await n.description(h):n.description,b=typeof v=="object"&&!I.isValidElement(v)?v:{message:v};this.create({id:r,type:"error",description:p,...b})}}).finally(()=>{o&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),d=()=>new Promise((h,v)=>u.then(()=>l[0]==="reject"?v(l[1]):h(l[1])).catch(v));return typeof r!="string"&&typeof r!="number"?{unwrap:d}:Object.assign(r,{unwrap:d})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||rS++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const Bn=new gK,yK=(e,t)=>{const n=(t==null?void 0:t.id)||rS++;return Bn.addToast({title:e,...t,id:n}),n},bK=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",xK=yK,wK=()=>Bn.toasts,SK=()=>Bn.getActiveToasts(),jt=Object.assign(xK,{success:Bn.success,info:Bn.info,warning:Bn.warning,error:Bn.error,custom:Bn.custom,message:Bn.message,promise:Bn.promise,dismiss:Bn.dismiss,loading:Bn.loading},{getHistory:wK,getToasts:SK});sK("[data-sonner-toaster][dir=ltr],html[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%)}[data-sonner-toaster][dir=rtl],html[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%)}[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:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[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);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[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 rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [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)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [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;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left: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);background:var(--normal-bg);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-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[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}[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}[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,0)) translateX(var(--swipe-amount-x,0));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{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{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{from{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-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--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-sonner-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-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-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, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-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-sonner-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]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[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]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[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]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[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]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[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:first-child{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)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{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%)}");function Oh(e){return e.label!==void 0}const jK=3,OK="24px",_K="16px",qC=4e3,EK=356,AK=14,NK=45,CK=200;function ia(...e){return e.filter(Boolean).join(" ")}function TK(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const MK=e=>{var t,n,r,i,o,l,u,d,h;const{invert:v,toast:p,unstyled:g,interacting:b,setHeights:O,visibleToasts:j,heights:x,index:_,toasts:A,expanded:E,removeToast:C,defaultRichColors:N,closeButton:M,style:R,cancelButtonStyle:D,actionButtonStyle:z,className:Y="",descriptionClassName:L="",duration:F,position:W,gap:Q,expandByDefault:X,classNames:k,icons:H,closeButtonAriaLabel:B="Close toast"}=e,[Z,le]=I.useState(null),[$,V]=I.useState(null),[q,U]=I.useState(!1),[ne,fe]=I.useState(!1),[ie,pe]=I.useState(!1),[re,ve]=I.useState(!1),[ge,oe]=I.useState(!1),[ke,we]=I.useState(0),[Ie,Ze]=I.useState(0),lt=I.useRef(p.duration||F||qC),en=I.useRef(null),mt=I.useRef(null),ur=_===0,Gn=_+1<=j,Mt=p.type,fr=p.dismissible!==!1,tn=p.className||"",ms=p.descriptionClassName||"",uo=I.useMemo(()=>x.findIndex($e=>$e.toastId===p.id)||0,[x,p.id]),ed=I.useMemo(()=>{var $e;return($e=p.closeButton)!=null?$e:M},[p.closeButton,M]),fo=I.useMemo(()=>p.duration||F||qC,[p.duration,F]),Sc=I.useRef(0),Sa=I.useRef(0),td=I.useRef(0),di=I.useRef(null),[ho,On]=W.split("-"),kr=I.useMemo(()=>x.reduce(($e,At,nn)=>nn>=uo?$e:$e+At.height,0),[x,uo]),gn=vK(),Vv=p.invert||v,jc=Mt==="loading";Sa.current=I.useMemo(()=>uo*Q+kr,[uo,kr]),I.useEffect(()=>{lt.current=fo},[fo]),I.useEffect(()=>{U(!0)},[]),I.useEffect(()=>{const $e=mt.current;if($e){const At=$e.getBoundingClientRect().height;return Ze(At),O(nn=>[{toastId:p.id,height:At,position:p.position},...nn]),()=>O(nn=>nn.filter(yn=>yn.toastId!==p.id))}},[O,p.id]),I.useLayoutEffect(()=>{if(!q)return;const $e=mt.current,At=$e.style.height;$e.style.height="auto";const nn=$e.getBoundingClientRect().height;$e.style.height=At,Ze(nn),O(yn=>yn.find(Rt=>Rt.toastId===p.id)?yn.map(Rt=>Rt.toastId===p.id?{...Rt,height:nn}:Rt):[{toastId:p.id,height:nn,position:p.position},...yn])},[q,p.title,p.description,O,p.id,p.jsx,p.action,p.cancel]);const Jr=I.useCallback(()=>{fe(!0),we(Sa.current),O($e=>$e.filter(At=>At.toastId!==p.id)),setTimeout(()=>{C(p)},CK)},[p,C,O,Sa]);I.useEffect(()=>{if(p.promise&&Mt==="loading"||p.duration===1/0||p.type==="loading")return;let $e;return E||b||gn?(()=>{if(td.current<Sc.current){const yn=new Date().getTime()-Sc.current;lt.current=lt.current-yn}td.current=new Date().getTime()})():(()=>{lt.current!==1/0&&(Sc.current=new Date().getTime(),$e=setTimeout(()=>{p.onAutoClose==null||p.onAutoClose.call(p,p),Jr()},lt.current))})(),()=>clearTimeout($e)},[E,b,p,Mt,gn,Jr]),I.useEffect(()=>{p.delete&&(Jr(),p.onDismiss==null||p.onDismiss.call(p,p))},[Jr,p.delete]);function ps(){var $e;if(H!=null&&H.loading){var At;return I.createElement("div",{className:ia(k==null?void 0:k.loader,p==null||(At=p.classNames)==null?void 0:At.loader,"sonner-loader"),"data-visible":Mt==="loading"},H.loading)}return I.createElement(uK,{className:ia(k==null?void 0:k.loader,p==null||($e=p.classNames)==null?void 0:$e.loader),visible:Mt==="loading"})}const vs=p.icon||(H==null?void 0:H[Mt])||lK(Mt);var mo,ea;return I.createElement("li",{tabIndex:0,ref:mt,className:ia(Y,tn,k==null?void 0:k.toast,p==null||(t=p.classNames)==null?void 0:t.toast,k==null?void 0:k.default,k==null?void 0:k[Mt],p==null||(n=p.classNames)==null?void 0:n[Mt]),"data-sonner-toast":"","data-rich-colors":(mo=p.richColors)!=null?mo:N,"data-styled":!(p.jsx||p.unstyled||g),"data-mounted":q,"data-promise":!!p.promise,"data-swiped":ge,"data-removed":ne,"data-visible":Gn,"data-y-position":ho,"data-x-position":On,"data-index":_,"data-front":ur,"data-swiping":ie,"data-dismissible":fr,"data-type":Mt,"data-invert":Vv,"data-swipe-out":re,"data-swipe-direction":$,"data-expanded":!!(E||X&&q),"data-testid":p.testId,style:{"--index":_,"--toasts-before":_,"--z-index":A.length-_,"--offset":`${ne?ke:Sa.current}px`,"--initial-height":X?"auto":`${Ie}px`,...R,...p.style},onDragEnd:()=>{pe(!1),le(null),di.current=null},onPointerDown:$e=>{$e.button!==2&&(jc||!fr||(en.current=new Date,we(Sa.current),$e.target.setPointerCapture($e.pointerId),$e.target.tagName!=="BUTTON"&&(pe(!0),di.current={x:$e.clientX,y:$e.clientY})))},onPointerUp:()=>{var $e,At,nn;if(re||!fr)return;di.current=null;const yn=Number((($e=mt.current)==null?void 0:$e.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),hi=Number(((At=mt.current)==null?void 0:At.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Rt=new Date().getTime()-((nn=en.current)==null?void 0:nn.getTime()),Tn=Z==="x"?yn:hi,po=Math.abs(Tn)/Rt;if(Math.abs(Tn)>=NK||po>.11){we(Sa.current),p.onDismiss==null||p.onDismiss.call(p,p),V(Z==="x"?yn>0?"right":"left":hi>0?"down":"up"),Jr(),ve(!0);return}else{var Mn,Rn;(Mn=mt.current)==null||Mn.style.setProperty("--swipe-amount-x","0px"),(Rn=mt.current)==null||Rn.style.setProperty("--swipe-amount-y","0px")}oe(!1),pe(!1),le(null)},onPointerMove:$e=>{var At,nn,yn;if(!di.current||!fr||((At=window.getSelection())==null?void 0:At.toString().length)>0)return;const Rt=$e.clientY-di.current.y,Tn=$e.clientX-di.current.x;var po;const Mn=(po=e.swipeDirections)!=null?po:TK(W);!Z&&(Math.abs(Tn)>1||Math.abs(Rt)>1)&&le(Math.abs(Tn)>Math.abs(Rt)?"x":"y");let Rn={x:0,y:0};const gs=$r=>1/(1.5+Math.abs($r)/20);if(Z==="y"){if(Mn.includes("top")||Mn.includes("bottom"))if(Mn.includes("top")&&Rt<0||Mn.includes("bottom")&&Rt>0)Rn.y=Rt;else{const $r=Rt*gs(Rt);Rn.y=Math.abs($r)<Math.abs(Rt)?$r:Rt}}else if(Z==="x"&&(Mn.includes("left")||Mn.includes("right")))if(Mn.includes("left")&&Tn<0||Mn.includes("right")&&Tn>0)Rn.x=Tn;else{const $r=Tn*gs(Tn);Rn.x=Math.abs($r)<Math.abs(Tn)?$r:Tn}(Math.abs(Rn.x)>0||Math.abs(Rn.y)>0)&&oe(!0),(nn=mt.current)==null||nn.style.setProperty("--swipe-amount-x",`${Rn.x}px`),(yn=mt.current)==null||yn.style.setProperty("--swipe-amount-y",`${Rn.y}px`)}},ed&&!p.jsx&&Mt!=="loading"?I.createElement("button",{"aria-label":B,"data-disabled":jc,"data-close-button":!0,onClick:jc||!fr?()=>{}:()=>{Jr(),p.onDismiss==null||p.onDismiss.call(p,p)},className:ia(k==null?void 0:k.closeButton,p==null||(r=p.classNames)==null?void 0:r.closeButton)},(ea=H==null?void 0:H.close)!=null?ea:pK):null,(Mt||p.icon||p.promise)&&p.icon!==null&&((H==null?void 0:H[Mt])!==null||p.icon)?I.createElement("div",{"data-icon":"",className:ia(k==null?void 0:k.icon,p==null||(i=p.classNames)==null?void 0:i.icon)},p.promise||p.type==="loading"&&!p.icon?p.icon||ps():null,p.type!=="loading"?vs:null):null,I.createElement("div",{"data-content":"",className:ia(k==null?void 0:k.content,p==null||(o=p.classNames)==null?void 0:o.content)},I.createElement("div",{"data-title":"",className:ia(k==null?void 0:k.title,p==null||(l=p.classNames)==null?void 0:l.title)},p.jsx?p.jsx:typeof p.title=="function"?p.title():p.title),p.description?I.createElement("div",{"data-description":"",className:ia(L,ms,k==null?void 0:k.description,p==null||(u=p.classNames)==null?void 0:u.description)},typeof p.description=="function"?p.description():p.description):null),I.isValidElement(p.cancel)?p.cancel:p.cancel&&Oh(p.cancel)?I.createElement("button",{"data-button":!0,"data-cancel":!0,style:p.cancelButtonStyle||D,onClick:$e=>{Oh(p.cancel)&&fr&&(p.cancel.onClick==null||p.cancel.onClick.call(p.cancel,$e),Jr())},className:ia(k==null?void 0:k.cancelButton,p==null||(d=p.classNames)==null?void 0:d.cancelButton)},p.cancel.label):null,I.isValidElement(p.action)?p.action:p.action&&Oh(p.action)?I.createElement("button",{"data-button":!0,"data-action":!0,style:p.actionButtonStyle||z,onClick:$e=>{Oh(p.action)&&(p.action.onClick==null||p.action.onClick.call(p.action,$e),!$e.defaultPrevented&&Jr())},className:ia(k==null?void 0:k.actionButton,p==null||(h=p.classNames)==null?void 0:h.actionButton)},p.action.label):null)};function UC(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function RK(e,t){const n={};return[e,t].forEach((r,i)=>{const o=i===1,l=o?"--mobile-offset":"--offset",u=o?_K:OK;function d(h){["top","right","bottom","left"].forEach(v=>{n[`${l}-${v}`]=typeof h=="number"?`${h}px`:h})}typeof r=="number"||typeof r=="string"?d(r):typeof r=="object"?["top","right","bottom","left"].forEach(h=>{r[h]===void 0?n[`${l}-${h}`]=u:n[`${l}-${h}`]=typeof r[h]=="number"?`${r[h]}px`:r[h]}):d(u)}),n}const DK=I.forwardRef(function(t,n){const{id:r,invert:i,position:o="bottom-right",hotkey:l=["altKey","KeyT"],expand:u,closeButton:d,className:h,offset:v,mobileOffset:p,theme:g="light",richColors:b,duration:O,style:j,visibleToasts:x=jK,toastOptions:_,dir:A=UC(),gap:E=AK,icons:C,containerAriaLabel:N="Notifications"}=t,[M,R]=I.useState([]),D=I.useMemo(()=>r?M.filter(q=>q.toasterId===r):M.filter(q=>!q.toasterId),[M,r]),z=I.useMemo(()=>Array.from(new Set([o].concat(D.filter(q=>q.position).map(q=>q.position)))),[D,o]),[Y,L]=I.useState([]),[F,W]=I.useState(!1),[Q,X]=I.useState(!1),[k,H]=I.useState(g!=="system"?g:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),B=I.useRef(null),Z=l.join("+").replace(/Key/g,"").replace(/Digit/g,""),le=I.useRef(null),$=I.useRef(!1),V=I.useCallback(q=>{R(U=>{var ne;return(ne=U.find(fe=>fe.id===q.id))!=null&&ne.delete||Bn.dismiss(q.id),U.filter(({id:fe})=>fe!==q.id)})},[]);return I.useEffect(()=>Bn.subscribe(q=>{if(q.dismiss){requestAnimationFrame(()=>{R(U=>U.map(ne=>ne.id===q.id?{...ne,delete:!0}:ne))});return}setTimeout(()=>{s$.flushSync(()=>{R(U=>{const ne=U.findIndex(fe=>fe.id===q.id);return ne!==-1?[...U.slice(0,ne),{...U[ne],...q},...U.slice(ne+1)]:[q,...U]})})})}),[M]),I.useEffect(()=>{if(g!=="system"){H(g);return}if(g==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?H("dark"):H("light")),typeof window>"u")return;const q=window.matchMedia("(prefers-color-scheme: dark)");try{q.addEventListener("change",({matches:U})=>{H(U?"dark":"light")})}catch{q.addListener(({matches:ne})=>{try{H(ne?"dark":"light")}catch(fe){console.error(fe)}})}},[g]),I.useEffect(()=>{M.length<=1&&W(!1)},[M]),I.useEffect(()=>{const q=U=>{var ne;if(l.every(pe=>U[pe]||U.code===pe)){var ie;W(!0),(ie=B.current)==null||ie.focus()}U.code==="Escape"&&(document.activeElement===B.current||(ne=B.current)!=null&&ne.contains(document.activeElement))&&W(!1)};return document.addEventListener("keydown",q),()=>document.removeEventListener("keydown",q)},[l]),I.useEffect(()=>{if(B.current)return()=>{le.current&&(le.current.focus({preventScroll:!0}),le.current=null,$.current=!1)}},[B.current]),I.createElement("section",{ref:n,"aria-label":`${N} ${Z}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},z.map((q,U)=>{var ne;const[fe,ie]=q.split("-");return D.length?I.createElement("ol",{key:q,dir:A==="auto"?UC():A,tabIndex:-1,ref:B,className:h,"data-sonner-toaster":!0,"data-sonner-theme":k,"data-y-position":fe,"data-x-position":ie,style:{"--front-toast-height":`${((ne=Y[0])==null?void 0:ne.height)||0}px`,"--width":`${EK}px`,"--gap":`${E}px`,...j,...RK(v,p)},onBlur:pe=>{$.current&&!pe.currentTarget.contains(pe.relatedTarget)&&($.current=!1,le.current&&(le.current.focus({preventScroll:!0}),le.current=null))},onFocus:pe=>{pe.target instanceof HTMLElement&&pe.target.dataset.dismissible==="false"||$.current||($.current=!0,le.current=pe.relatedTarget)},onMouseEnter:()=>W(!0),onMouseMove:()=>W(!0),onMouseLeave:()=>{Q||W(!1)},onDragEnd:()=>W(!1),onPointerDown:pe=>{pe.target instanceof HTMLElement&&pe.target.dataset.dismissible==="false"||X(!0)},onPointerUp:()=>X(!1)},D.filter(pe=>!pe.position&&U===0||pe.position===q).map((pe,re)=>{var ve,ge;return I.createElement(MK,{key:pe.id,icons:C,index:re,toast:pe,defaultRichColors:b,duration:(ve=_==null?void 0:_.duration)!=null?ve:O,className:_==null?void 0:_.className,descriptionClassName:_==null?void 0:_.descriptionClassName,invert:i,visibleToasts:x,closeButton:(ge=_==null?void 0:_.closeButton)!=null?ge:d,interacting:Q,position:q,style:_==null?void 0:_.style,unstyled:_==null?void 0:_.unstyled,classNames:_==null?void 0:_.classNames,cancelButtonStyle:_==null?void 0:_.cancelButtonStyle,actionButtonStyle:_==null?void 0:_.actionButtonStyle,closeButtonAriaLabel:_==null?void 0:_.closeButtonAriaLabel,removeToast:V,toasts:D.filter(oe=>oe.position==pe.position),heights:Y.filter(oe=>oe.position==pe.position),setHeights:L,expandByDefault:u,gap:E,expanded:F,swipeDirections:t.swipeDirections})})):null}))});function Fi({value:e,className:t,variant:n="outline",size:r="icon",label:i}){const[o,l]=w.useState("idle"),u=async d=>{d.stopPropagation(),l("copying");try{await Promise.all([navigator.clipboard.writeText(e),new Promise(h=>setTimeout(h,150))]),l("copied"),jt.success("Copied to clipboard"),setTimeout(()=>l("idle"),2e3)}catch{l("idle"),jt.error("Failed to copy to clipboard")}};return c.jsxs(Ce,{className:me("transition-all",o==="copied"&&"text-green-500",t),onClick:u,size:r,variant:n,disabled:o==="copying",children:[o==="copying"?c.jsx(Ha,{className:me("animate-spin",i?"mr-2 h-4 w-4":"h-4 w-4")}):o==="copied"?c.jsx(Ja,{className:me(i?"mr-2 h-4 w-4":"h-4 w-4")}):c.jsx(qj,{className:me(i?"mr-2 h-4 w-4":"h-4 w-4")}),i]})}function H3({onDelete:e,className:t,variant:n="outline",size:r="icon",label:i}){const[o,l]=w.useState(!1),u=async d=>{d.stopPropagation(),l(!0);try{await Promise.all([e(),new Promise(h=>setTimeout(h,150))])}finally{l(!1)}};return c.jsxs(Ce,{className:me("text-destructive hover:text-destructive transition-all",t),onClick:u,size:r,variant:n,disabled:o,children:[o?c.jsx(Ha,{className:me("animate-spin",i?"mr-1.5 h-4 w-4":"h-4 w-4")}):c.jsx(AF,{className:me(i?"mr-1.5 h-4 w-4":"h-4 w-4")}),i]})}const F3=6048e5,PK=864e5,_h=43200,HC=1440,FC=Symbol.for("constructDateFrom");function ni(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&FC in e?e[FC](t):e instanceof Date?new e.constructor(t):new Date(t)}function sn(e,t){return ni(t||e,e)}let kK={};function Ff(){return kK}function Ku(e,t){var u,d,h,v;const n=Ff(),r=(t==null?void 0:t.weekStartsOn)??((d=(u=t==null?void 0:t.locale)==null?void 0:u.options)==null?void 0:d.weekStartsOn)??n.weekStartsOn??((v=(h=n.locale)==null?void 0:h.options)==null?void 0:v.weekStartsOn)??0,i=sn(e,t==null?void 0:t.in),o=i.getDay(),l=(o<r?7:0)+o-r;return i.setDate(i.getDate()-l),i.setHours(0,0,0,0),i}function fm(e,t){return Ku(e,{...t,weekStartsOn:1})}function G3(e,t){const n=sn(e,t==null?void 0:t.in),r=n.getFullYear(),i=ni(n,0);i.setFullYear(r+1,0,4),i.setHours(0,0,0,0);const o=fm(i),l=ni(n,0);l.setFullYear(r,0,4),l.setHours(0,0,0,0);const u=fm(l);return n.getTime()>=o.getTime()?r+1:n.getTime()>=u.getTime()?r:r-1}function dm(e){const t=sn(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function Jp(e,...t){const n=ni.bind(null,e||t.find(r=>typeof r=="object"));return t.map(n)}function GC(e,t){const n=sn(e,t==null?void 0:t.in);return n.setHours(0,0,0,0),n}function $K(e,t,n){const[r,i]=Jp(n==null?void 0:n.in,e,t),o=GC(r),l=GC(i),u=+o-dm(o),d=+l-dm(l);return Math.round((u-d)/PK)}function IK(e,t){const n=G3(e,t),r=ni(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),fm(r)}function Wh(e,t){const n=+sn(e)-+sn(t);return n<0?-1:n>0?1:n}function LK(e){return ni(e,Date.now())}function zK(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function BK(e){return!(!zK(e)&&typeof e!="number"||isNaN(+sn(e)))}function qK(e,t,n){const[r,i]=Jp(n==null?void 0:n.in,e,t),o=r.getFullYear()-i.getFullYear(),l=r.getMonth()-i.getMonth();return o*12+l}function UK(e){return t=>{const r=(e?Math[e]:Math.trunc)(t);return r===0?0:r}}function HK(e,t){return+sn(e)-+sn(t)}function FK(e,t){const n=sn(e,t==null?void 0:t.in);return n.setHours(23,59,59,999),n}function GK(e,t){const n=sn(e,t==null?void 0:t.in),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function VK(e,t){const n=sn(e,t==null?void 0:t.in);return+FK(n,t)==+GK(n,t)}function YK(e,t,n){const[r,i,o]=Jp(n==null?void 0:n.in,e,e,t),l=Wh(i,o),u=Math.abs(qK(i,o));if(u<1)return 0;i.getMonth()===1&&i.getDate()>27&&i.setDate(30),i.setMonth(i.getMonth()-l*u);let d=Wh(i,o)===-l;VK(r)&&u===1&&Wh(r,o)===1&&(d=!1);const h=l*(u-+d);return h===0?0:h}function WK(e,t,n){const r=HK(e,t)/1e3;return UK(n==null?void 0:n.roundingMethod)(r)}function KK(e,t){const n=sn(e,t==null?void 0:t.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}const XK={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},QK=(e,t,n)=>{let r;const i=XK[e];return typeof i=="string"?r=i:t===1?r=i.one:r=i.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function Mb(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const ZK={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},JK={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},eX={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},tX={date:Mb({formats:ZK,defaultWidth:"full"}),time:Mb({formats:JK,defaultWidth:"full"}),dateTime:Mb({formats:eX,defaultWidth:"full"})},nX={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},rX=(e,t,n,r)=>nX[e];function gu(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const l=e.defaultFormattingWidth||e.defaultWidth,u=n!=null&&n.width?String(n.width):l;i=e.formattingValues[u]||e.formattingValues[l]}else{const l=e.defaultWidth,u=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[u]||e.values[l]}const o=e.argumentCallback?e.argumentCallback(t):t;return i[o]}}const aX={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},iX={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},oX={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},sX={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},lX={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},cX={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},uX=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},fX={ordinalNumber:uX,era:gu({values:aX,defaultWidth:"wide"}),quarter:gu({values:iX,defaultWidth:"wide",argumentCallback:e=>e-1}),month:gu({values:oX,defaultWidth:"wide"}),day:gu({values:sX,defaultWidth:"wide"}),dayPeriod:gu({values:lX,defaultWidth:"wide",formattingValues:cX,defaultFormattingWidth:"wide"})};function yu(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;const l=o[0],u=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],d=Array.isArray(u)?hX(u,p=>p.test(l)):dX(u,p=>p.test(l));let h;h=e.valueCallback?e.valueCallback(d):d,h=n.valueCallback?n.valueCallback(h):h;const v=t.slice(l.length);return{value:h,rest:v}}}function dX(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function hX(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function mX(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],o=t.match(e.parsePattern);if(!o)return null;let l=e.valueCallback?e.valueCallback(o[0]):o[0];l=n.valueCallback?n.valueCallback(l):l;const u=t.slice(i.length);return{value:l,rest:u}}}const pX=/^(\d+)(th|st|nd|rd)?/i,vX=/\d+/i,gX={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},yX={any:[/^b/i,/^(a|c)/i]},bX={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},xX={any:[/1/i,/2/i,/3/i,/4/i]},wX={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},SX={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},jX={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},OX={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},_X={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},EX={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},AX={ordinalNumber:mX({matchPattern:pX,parsePattern:vX,valueCallback:e=>parseInt(e,10)}),era:yu({matchPatterns:gX,defaultMatchWidth:"wide",parsePatterns:yX,defaultParseWidth:"any"}),quarter:yu({matchPatterns:bX,defaultMatchWidth:"wide",parsePatterns:xX,defaultParseWidth:"any",valueCallback:e=>e+1}),month:yu({matchPatterns:wX,defaultMatchWidth:"wide",parsePatterns:SX,defaultParseWidth:"any"}),day:yu({matchPatterns:jX,defaultMatchWidth:"wide",parsePatterns:OX,defaultParseWidth:"any"}),dayPeriod:yu({matchPatterns:_X,defaultMatchWidth:"any",parsePatterns:EX,defaultParseWidth:"any"})},V3={code:"en-US",formatDistance:QK,formatLong:tX,formatRelative:rX,localize:fX,match:AX,options:{weekStartsOn:0,firstWeekContainsDate:1}};function NX(e,t){const n=sn(e,t==null?void 0:t.in);return $K(n,KK(n))+1}function CX(e,t){const n=sn(e,t==null?void 0:t.in),r=+fm(n)-+IK(n);return Math.round(r/F3)+1}function Y3(e,t){var v,p,g,b;const n=sn(e,t==null?void 0:t.in),r=n.getFullYear(),i=Ff(),o=(t==null?void 0:t.firstWeekContainsDate)??((p=(v=t==null?void 0:t.locale)==null?void 0:v.options)==null?void 0:p.firstWeekContainsDate)??i.firstWeekContainsDate??((b=(g=i.locale)==null?void 0:g.options)==null?void 0:b.firstWeekContainsDate)??1,l=ni((t==null?void 0:t.in)||e,0);l.setFullYear(r+1,0,o),l.setHours(0,0,0,0);const u=Ku(l,t),d=ni((t==null?void 0:t.in)||e,0);d.setFullYear(r,0,o),d.setHours(0,0,0,0);const h=Ku(d,t);return+n>=+u?r+1:+n>=+h?r:r-1}function TX(e,t){var u,d,h,v;const n=Ff(),r=(t==null?void 0:t.firstWeekContainsDate)??((d=(u=t==null?void 0:t.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??n.firstWeekContainsDate??((v=(h=n.locale)==null?void 0:h.options)==null?void 0:v.firstWeekContainsDate)??1,i=Y3(e,t),o=ni((t==null?void 0:t.in)||e,0);return o.setFullYear(i,0,r),o.setHours(0,0,0,0),Ku(o,t)}function MX(e,t){const n=sn(e,t==null?void 0:t.in),r=+Ku(n,t)-+TX(n,t);return Math.round(r/F3)+1}function ht(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Bi={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return ht(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):ht(n+1,2)},d(e,t){return ht(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return ht(e.getHours()%12||12,t.length)},H(e,t){return ht(e.getHours(),t.length)},m(e,t){return ht(e.getMinutes(),t.length)},s(e,t){return ht(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),i=Math.trunc(r*Math.pow(10,n-3));return ht(i,t.length)}},ol={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},VC={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return Bi.y(e,t)},Y:function(e,t,n,r){const i=Y3(e,r),o=i>0?i:1-i;if(t==="YY"){const l=o%100;return ht(l,2)}return t==="Yo"?n.ordinalNumber(o,{unit:"year"}):ht(o,t.length)},R:function(e,t){const n=G3(e);return ht(n,t.length)},u:function(e,t){const n=e.getFullYear();return ht(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return ht(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return ht(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Bi.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return ht(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const i=MX(e,r);return t==="wo"?n.ordinalNumber(i,{unit:"week"}):ht(i,t.length)},I:function(e,t,n){const r=CX(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):ht(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Bi.d(e,t)},D:function(e,t,n){const r=NX(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):ht(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const i=e.getDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return ht(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const i=e.getDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return ht(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),i=r===0?7:r;switch(t){case"i":return String(i);case"ii":return ht(i,t.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const i=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let i;switch(r===12?i=ol.noon:r===0?i=ol.midnight:i=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let i;switch(r>=17?i=ol.evening:r>=12?i=ol.afternoon:r>=4?i=ol.morning:i=ol.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Bi.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Bi.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):ht(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):ht(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Bi.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Bi.s(e,t)},S:function(e,t){return Bi.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return WC(r);case"XXXX":case"XX":return ko(r);case"XXXXX":case"XXX":default:return ko(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return WC(r);case"xxxx":case"xx":return ko(r);case"xxxxx":case"xxx":default:return ko(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+YC(r,":");case"OOOO":default:return"GMT"+ko(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+YC(r,":");case"zzzz":default:return"GMT"+ko(r,":")}},t:function(e,t,n){const r=Math.trunc(+e/1e3);return ht(r,t.length)},T:function(e,t,n){return ht(+e,t.length)}};function YC(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Math.trunc(r/60),o=r%60;return o===0?n+String(i):n+String(i)+t+ht(o,2)}function WC(e,t){return e%60===0?(e>0?"-":"+")+ht(Math.abs(e)/60,2):ko(e,t)}function ko(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=ht(Math.trunc(r/60),2),o=ht(r%60,2);return n+i+t+o}const KC=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},W3=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},RX=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return KC(e,t);let o;switch(r){case"P":o=t.dateTime({width:"short"});break;case"PP":o=t.dateTime({width:"medium"});break;case"PPP":o=t.dateTime({width:"long"});break;case"PPPP":default:o=t.dateTime({width:"full"});break}return o.replace("{{date}}",KC(r,t)).replace("{{time}}",W3(i,t))},DX={p:W3,P:RX},PX=/^D+$/,kX=/^Y+$/,$X=["D","DD","YY","YYYY"];function IX(e){return PX.test(e)}function LX(e){return kX.test(e)}function zX(e,t,n){const r=BX(e,t,n);if(console.warn(r),$X.includes(e))throw new RangeError(r)}function BX(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const qX=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,UX=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,HX=/^'([^]*?)'?$/,FX=/''/g,GX=/[a-zA-Z]/;function aS(e,t,n){var v,p,g,b;const r=Ff(),i=r.locale??V3,o=r.firstWeekContainsDate??((p=(v=r.locale)==null?void 0:v.options)==null?void 0:p.firstWeekContainsDate)??1,l=r.weekStartsOn??((b=(g=r.locale)==null?void 0:g.options)==null?void 0:b.weekStartsOn)??0,u=sn(e,n==null?void 0:n.in);if(!BK(u))throw new RangeError("Invalid time value");let d=t.match(UX).map(O=>{const j=O[0];if(j==="p"||j==="P"){const x=DX[j];return x(O,i.formatLong)}return O}).join("").match(qX).map(O=>{if(O==="''")return{isToken:!1,value:"'"};const j=O[0];if(j==="'")return{isToken:!1,value:VX(O)};if(VC[j])return{isToken:!0,value:O};if(j.match(GX))throw new RangeError("Format string contains an unescaped latin alphabet character `"+j+"`");return{isToken:!1,value:O}});i.localize.preprocessor&&(d=i.localize.preprocessor(u,d));const h={firstWeekContainsDate:o,weekStartsOn:l,locale:i};return d.map(O=>{if(!O.isToken)return O.value;const j=O.value;(LX(j)||IX(j))&&zX(j,t,String(e));const x=VC[j[0]];return x(u,j,i.localize,h)}).join("")}function VX(e){const t=e.match(HX);return t?t[1].replace(FX,"'"):e}function YX(e,t,n){const r=Ff(),i=(n==null?void 0:n.locale)??r.locale??V3,o=2520,l=Wh(e,t);if(isNaN(l))throw new RangeError("Invalid time value");const u=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:l}),[d,h]=Jp(n==null?void 0:n.in,...l>0?[t,e]:[e,t]),v=WK(h,d),p=(dm(h)-dm(d))/1e3,g=Math.round((v-p)/60);let b;if(g<2)return n!=null&&n.includeSeconds?v<5?i.formatDistance("lessThanXSeconds",5,u):v<10?i.formatDistance("lessThanXSeconds",10,u):v<20?i.formatDistance("lessThanXSeconds",20,u):v<40?i.formatDistance("halfAMinute",0,u):v<60?i.formatDistance("lessThanXMinutes",1,u):i.formatDistance("xMinutes",1,u):g===0?i.formatDistance("lessThanXMinutes",1,u):i.formatDistance("xMinutes",g,u);if(g<45)return i.formatDistance("xMinutes",g,u);if(g<90)return i.formatDistance("aboutXHours",1,u);if(g<HC){const O=Math.round(g/60);return i.formatDistance("aboutXHours",O,u)}else{if(g<o)return i.formatDistance("xDays",1,u);if(g<_h){const O=Math.round(g/HC);return i.formatDistance("xDays",O,u)}else if(g<_h*2)return b=Math.round(g/_h),i.formatDistance("aboutXMonths",b,u)}if(b=YK(h,d),b<12){const O=Math.round(g/_h);return i.formatDistance("xMonths",O,u)}else{const O=b%12,j=Math.trunc(b/12);return O<3?i.formatDistance("aboutXYears",j,u):O<9?i.formatDistance("overXYears",j,u):i.formatDistance("almostXYears",j+1,u)}}function WX(e,t){return YX(e,LK(e),t)}const KX=sc("inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden whitespace-nowrap rounded-full border px-2 py-0.5 font-medium text-xs transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"border-transparent bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"border-transparent bg-destructive text-white focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/90",outline:"text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground"}},defaultVariants:{variant:"default"}});function Ge({className:e,variant:t,asChild:n=!1,...r}){const i=n?as:"span";return c.jsx(i,{className:me(KX({variant:t}),e),"data-slot":"badge",...r})}function _O({...e}){return c.jsx(gO,{"data-slot":"dialog",...e})}function XX({...e}){return c.jsx(yO,{"data-slot":"dialog-portal",...e})}function QX({className:e,...t}){return c.jsx(bO,{className:me("data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=open]:animate-in",e),"data-slot":"dialog-overlay",...t})}function EO({className:e,children:t,showCloseButton:n=!0,...r}){return c.jsxs(XX,{"data-slot":"dialog-portal",children:[c.jsx(QX,{}),c.jsxs(xO,{className:me("data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200 data-[state=closed]:animate-out data-[state=open]:animate-in sm:max-w-lg",e),"data-slot":"dialog-content",...r,children:[t,n&&c.jsxs(Yp,{className:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0","data-slot":"dialog-close",children:[c.jsx(ir,{}),c.jsx("span",{className:"sr-only",children:"Close"})]})]})]})}function K3({className:e,...t}){return c.jsx("div",{className:me("flex flex-col gap-2 text-center sm:text-left",e),"data-slot":"dialog-header",...t})}function X3({className:e,...t}){return c.jsx("div",{className:me("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",e),"data-slot":"dialog-footer",...t})}function Q3({className:e,...t}){return c.jsx(wO,{className:me("font-semibold text-lg leading-none",e),"data-slot":"dialog-title",...t})}function ZX({className:e,...t}){return c.jsx(SO,{className:me("text-muted-foreground text-sm",e),"data-slot":"dialog-description",...t})}function ev({starred:e,onToggle:t,className:n,variant:r="ghost",size:i="icon",label:o}){const[l,u]=w.useState(!1),d=async h=>{h.stopPropagation(),u(!0);try{await Promise.all([t(),new Promise(v=>setTimeout(v,150))])}finally{u(!1)}};return c.jsxs(Ce,{className:me("transition-all",n),onClick:d,size:i,variant:r,disabled:l,children:[l?c.jsx(Ha,{className:me("animate-spin",o?"mr-1.5 h-4 w-4":"h-4 w-4")}):c.jsx(f$,{className:me("transition-colors",o?"mr-1.5 h-4 w-4":"h-4 w-4",e?"fill-yellow-500 text-yellow-500":"text-muted-foreground")}),o,!o&&c.jsx("span",{className:"sr-only",children:e?"Unstar":"Star"})]})}function JX(e){return e===0?"0 B":e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(2)} KB`:`${(e/(1024*1024)).toFixed(2)} MB`}function Z3(e){var t;return((t=e.split(".").pop())==null?void 0:t.toLowerCase())||""}function eQ(e,t){if(e!=null&&e.startsWith("image/"))return!0;const n=t?Z3(t):"";return["jpg","jpeg","png","gif","webp","avif","svg","bmp","ico"].includes(n)}function tQ({file:e,onClose:t,onToggleStar:n,onDelete:r}){const i=e.key.split("/").pop()||e.key,o=Z3(i),l=eQ(e.contentType,i),u=()=>{const d=document.createElement("a");d.href=e.url,d.download=i,d.target="_blank",d.click()};return c.jsx(_O,{onOpenChange:d=>!d&&t(),open:!0,children:c.jsx(EO,{className:"max-h-[90vh] max-w-4xl overflow-y-auto [&>button]:hidden",children:c.jsxs("div",{className:"space-y-6",children:[c.jsxs("div",{className:"flex items-start justify-between",children:[c.jsxs("div",{className:"flex-1",children:[c.jsx("h2",{className:"font-bold text-2xl",children:i}),e.key!==i&&c.jsx("p",{className:"mt-1 text-muted-foreground text-sm",children:e.key})]}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(ev,{starred:e.starred,onToggle:()=>n(e.key,!e.starred),variant:"outline"}),c.jsx(H3,{onDelete:()=>r(e.key)}),c.jsx(Ce,{onClick:t,size:"icon",variant:"outline",children:c.jsx(ir,{className:"h-4 w-4"})})]})]}),c.jsx("div",{className:"aspect-video overflow-hidden rounded-lg bg-muted",children:l&&e.url.startsWith("https://")?c.jsx("img",{alt:i,className:"h-full w-full object-contain",src:e.url}):c.jsxs("div",{className:"flex h-full w-full flex-col items-center justify-center gap-2",children:[l?c.jsx(Uj,{className:"h-16 w-16 text-muted-foreground/50"}):c.jsx(Hj,{className:"h-16 w-16 text-muted-foreground/50"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Preview not available"})]})}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx(Fi,{className:"flex-1",label:"Copy CDN URL",size:"default",value:e.url,variant:"default"}),c.jsxs(Ce,{className:"flex-1 gap-2 bg-transparent",onClick:()=>window.open(e.url,"_blank"),variant:"outline",children:[c.jsx(qu,{className:"h-4 w-4"}),"Open in New Tab"]}),c.jsxs(Ce,{className:"flex-1 gap-2 bg-transparent",onClick:u,variant:"outline",children:[c.jsx(vF,{className:"h-4 w-4"}),"Download"]})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"grid grid-cols-2 gap-6",children:[c.jsx("div",{className:"space-y-4",children:c.jsxs("div",{children:[c.jsx("h3",{className:"mb-2 font-semibold text-sm",children:"File Information"}),c.jsxs("dl",{className:"space-y-2 text-sm",children:[c.jsxs("div",{className:"flex justify-between",children:[c.jsx("dt",{className:"text-muted-foreground",children:"Format"}),c.jsx("dd",{className:"font-medium",children:c.jsx(Ge,{variant:"secondary",children:o.toUpperCase()})})]}),c.jsxs("div",{className:"flex justify-between",children:[c.jsx("dt",{className:"text-muted-foreground",children:"Size"}),c.jsx("dd",{className:"font-medium",children:JX(e.size)})]}),c.jsxs("div",{className:"flex justify-between",children:[c.jsx("dt",{className:"text-muted-foreground",children:"Content Type"}),c.jsx("dd",{className:"font-medium",children:e.contentType||"Unknown"})]})]})]})}),c.jsx("div",{className:"space-y-4",children:c.jsxs("div",{children:[c.jsx("h3",{className:"mb-2 font-semibold text-sm",children:"Metadata"}),c.jsxs("dl",{className:"space-y-2 text-sm",children:[c.jsxs("div",{className:"flex justify-between",children:[c.jsx("dt",{className:"text-muted-foreground",children:"Last Modified"}),c.jsx("dd",{className:"font-medium",children:aS(new Date(e.lastModified),"MMM d, yyyy 'at' h:mm a")})]}),c.jsxs("div",{className:"flex justify-between",children:[c.jsx("dt",{className:"text-muted-foreground",children:"Starred"}),c.jsx("dd",{className:"font-medium",children:e.starred?"Yes":"No"})]}),e.tags.length>0&&c.jsxs("div",{children:[c.jsx("dt",{className:"mb-1 text-muted-foreground",children:"Tags"}),c.jsx("dd",{className:"flex flex-wrap gap-1",children:e.tags.filter(d=>d.key!=="starred").map(d=>c.jsxs(Ge,{variant:"secondary",children:[d.key,": ",d.value]},d.key))})]})]})]})})]}),c.jsx(Bt,{}),c.jsxs("div",{children:[c.jsx("h3",{className:"mb-2 font-semibold text-sm",children:"CDN URL"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("code",{className:"flex-1 break-all rounded bg-muted px-3 py-2 text-sm",children:e.url}),c.jsx(Fi,{size:"sm",value:e.url})]})]})]})})})}function Re({className:e,...t}){return c.jsx("div",{className:me("flex flex-col gap-6 rounded-xl border bg-card py-6 text-card-foreground shadow-sm",e),"data-slot":"card",...t})}function De({className:e,...t}){return c.jsx("div",{className:me("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),"data-slot":"card-header",...t})}function Ue({className:e,...t}){return c.jsx("div",{className:me("font-semibold leading-none",e),"data-slot":"card-title",...t})}function We({className:e,...t}){return c.jsx("div",{className:me("text-muted-foreground text-sm",e),"data-slot":"card-description",...t})}function ze({className:e,...t}){return c.jsx("div",{className:me("px-6",e),"data-slot":"card-content",...t})}function nQ({className:e,...t}){return c.jsx("div",{className:me("flex items-center px-6 [.border-t]:pt-6",e),"data-slot":"card-footer",...t})}function tv(e){const t=w.useRef({value:e,previous:e});return w.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var nv="Checkbox",[rQ]=jn(nv),[aQ,AO]=rQ(nv);function iQ(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:i,disabled:o,form:l,name:u,onCheckedChange:d,required:h,value:v="on",internal_do_not_use_render:p}=e,[g,b]=An({prop:n,defaultProp:i??!1,onChange:d,caller:nv}),[O,j]=w.useState(null),[x,_]=w.useState(null),A=w.useRef(!1),E=O?!!l||!!O.closest("form"):!0,C={checked:g,disabled:o,setChecked:b,control:O,setControl:j,name:u,form:l,value:v,hasConsumerStoppedPropagationRef:A,required:h,defaultChecked:Vi(i)?!1:i,isFormControl:E,bubbleInput:x,setBubbleInput:_};return c.jsx(aQ,{scope:t,...C,children:oQ(p)?p(C):r})}var J3="CheckboxTrigger",e5=w.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},i)=>{const{control:o,value:l,disabled:u,checked:d,required:h,setControl:v,setChecked:p,hasConsumerStoppedPropagationRef:g,isFormControl:b,bubbleInput:O}=AO(J3,e),j=Be(i,v),x=w.useRef(d);return w.useEffect(()=>{const _=o==null?void 0:o.form;if(_){const A=()=>p(x.current);return _.addEventListener("reset",A),()=>_.removeEventListener("reset",A)}},[o,p]),c.jsx(Ee.button,{type:"button",role:"checkbox","aria-checked":Vi(d)?"mixed":d,"aria-required":h,"data-state":o5(d),"data-disabled":u?"":void 0,disabled:u,value:l,...r,ref:j,onKeyDown:ye(t,_=>{_.key==="Enter"&&_.preventDefault()}),onClick:ye(n,_=>{p(A=>Vi(A)?!0:!A),O&&b&&(g.current=_.isPropagationStopped(),g.current||_.stopPropagation())})})});e5.displayName=J3;var t5=w.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:o,required:l,disabled:u,value:d,onCheckedChange:h,form:v,...p}=e;return c.jsx(iQ,{__scopeCheckbox:n,checked:i,defaultChecked:o,disabled:u,required:l,onCheckedChange:h,name:r,form:v,value:d,internal_do_not_use_render:({isFormControl:g})=>c.jsxs(c.Fragment,{children:[c.jsx(e5,{...p,ref:t,__scopeCheckbox:n}),g&&c.jsx(i5,{__scopeCheckbox:n})]})})});t5.displayName=nv;var n5="CheckboxIndicator",r5=w.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...i}=e,o=AO(n5,n);return c.jsx(Nn,{present:r||Vi(o.checked)||o.checked===!0,children:c.jsx(Ee.span,{"data-state":o5(o.checked),"data-disabled":o.disabled?"":void 0,...i,ref:t,style:{pointerEvents:"none",...e.style}})})});r5.displayName=n5;var a5="CheckboxBubbleInput",i5=w.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:i,checked:o,defaultChecked:l,required:u,disabled:d,name:h,value:v,form:p,bubbleInput:g,setBubbleInput:b}=AO(a5,e),O=Be(n,b),j=tv(o),x=$p(r);w.useEffect(()=>{const A=g;if(!A)return;const E=window.HTMLInputElement.prototype,N=Object.getOwnPropertyDescriptor(E,"checked").set,M=!i.current;if(j!==o&&N){const R=new Event("click",{bubbles:M});A.indeterminate=Vi(o),N.call(A,Vi(o)?!1:o),A.dispatchEvent(R)}},[g,j,o,i]);const _=w.useRef(Vi(o)?!1:o);return c.jsx(Ee.input,{type:"checkbox","aria-hidden":!0,defaultChecked:l??_.current,required:u,disabled:d,name:h,value:v,form:p,...t,tabIndex:-1,ref:O,style:{...t.style,...x,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});i5.displayName=a5;function oQ(e){return typeof e=="function"}function Vi(e){return e==="indeterminate"}function o5(e){return Vi(e)?"indeterminate":e?"checked":"unchecked"}function iS({className:e,...t}){return c.jsx(t5,{className:me("peer size-4 shrink-0 rounded-[4px] border border-input shadow-xs outline-none transition-shadow focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[state=checked]:border-primary data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:bg-input/30 dark:data-[state=checked]:bg-primary dark:aria-invalid:ring-destructive/40",e),"data-slot":"checkbox",...t,children:c.jsx(r5,{className:"grid place-content-center text-current transition-none","data-slot":"checkbox-indicator",children:c.jsx(Ja,{className:"size-3.5"})})})}function sQ(e){return e===0?"0 B":e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(0)} KB`:`${(e/(1024*1024)).toFixed(2)} MB`}function s5(e){var t;return((t=e.split(".").pop())==null?void 0:t.toLowerCase())||""}function lQ(e,t){if(e!=null&&e.startsWith("image/"))return!0;const n=t?s5(t):"";return["jpg","jpeg","png","gif","webp","avif","svg","bmp","ico"].includes(n)}function cQ({files:e,selectedFiles:t,onSelectFile:n,onToggleStar:r,onFileClick:i}){const o=(l,u)=>{l.stopPropagation(),window.open(u,"_blank")};return c.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-5 xl:grid-cols-6",children:e.map(l=>{const u=l.key.split("/").pop()||l.key,d=s5(u),h=lQ(l.contentType,u),v=t.includes(l.key);return c.jsxs("div",{className:"group relative cursor-pointer overflow-hidden rounded-xl bg-muted shadow-sm transition-shadow hover:shadow-md",onClick:()=>i(l),children:[c.jsx("div",{className:"flex aspect-square items-center justify-center",children:h&&l.url.startsWith("https://")?c.jsx("img",{alt:u,className:"h-full w-full object-cover",src:l.url}):c.jsx("div",{className:"flex h-full w-full items-center justify-center",children:h?c.jsx(Uj,{className:"h-12 w-12 text-muted-foreground/50"}):c.jsx(Hj,{className:"h-12 w-12 text-muted-foreground/50"})})}),c.jsx(ev,{starred:l.starred,onToggle:()=>r(l.key,!l.starred),className:"absolute top-2 right-2 rounded-full bg-background/80 hover:bg-background/90"}),c.jsxs(Re,{className:"gap-2 rounded-t-none border-none py-3 shadow-none",children:[c.jsxs(De,{className:"gap-1 px-3 py-0",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("div",{onClick:p=>p.stopPropagation(),children:c.jsx(iS,{checked:v,onCheckedChange:()=>n(l.key)})}),c.jsx(Ue,{className:"min-w-0 flex-1 truncate text-sm",children:u})]}),c.jsxs(We,{className:"flex items-center gap-2 pl-6",children:[c.jsx(Ge,{variant:"outline",className:"rounded-sm text-[10px]",children:d.toUpperCase()}),c.jsx("span",{className:"text-xs",children:sQ(l.size)})]})]}),c.jsxs(nQ,{className:"justify-end gap-1 px-3 py-0 opacity-0 transition-opacity group-hover:opacity-100",children:[c.jsx(Fi,{className:"h-7 px-2",label:"Copy",size:"sm",value:l.url,variant:"ghost"}),c.jsxs(Ce,{size:"sm",variant:"ghost",className:"h-7 px-2",onClick:p=>o(p,l.url),children:[c.jsx(qu,{className:"mr-1 h-3 w-3"}),"Open"]})]})]})]},l.key)})})}var Rb,rv="HoverCard",[l5]=jn(rv,[to]),av=to(),[uQ,iv]=l5(rv),c5=e=>{const{__scopeHoverCard:t,children:n,open:r,defaultOpen:i,onOpenChange:o,openDelay:l=700,closeDelay:u=300}=e,d=av(t),h=w.useRef(0),v=w.useRef(0),p=w.useRef(!1),g=w.useRef(!1),[b,O]=An({prop:r,defaultProp:i??!1,onChange:o,caller:rv}),j=w.useCallback(()=>{clearTimeout(v.current),h.current=window.setTimeout(()=>O(!0),l)},[l,O]),x=w.useCallback(()=>{clearTimeout(h.current),!p.current&&!g.current&&(v.current=window.setTimeout(()=>O(!1),u))},[u,O]),_=w.useCallback(()=>O(!1),[O]);return w.useEffect(()=>()=>{clearTimeout(h.current),clearTimeout(v.current)},[]),c.jsx(uQ,{scope:t,open:b,onOpenChange:O,onOpen:j,onClose:x,onDismiss:_,hasSelectionRef:p,isPointerDownOnContentRef:g,children:c.jsx(Ip,{...d,children:n})})};c5.displayName=rv;var u5="HoverCardTrigger",f5=w.forwardRef((e,t)=>{const{__scopeHoverCard:n,...r}=e,i=iv(u5,n),o=av(n);return c.jsx(Lp,{asChild:!0,...o,children:c.jsx(Ee.a,{"data-state":i.open?"open":"closed",...r,ref:t,onPointerEnter:ye(e.onPointerEnter,mm(i.onOpen)),onPointerLeave:ye(e.onPointerLeave,mm(i.onClose)),onFocus:ye(e.onFocus,i.onOpen),onBlur:ye(e.onBlur,i.onClose),onTouchStart:ye(e.onTouchStart,l=>l.preventDefault())})})});f5.displayName=u5;var NO="HoverCardPortal",[fQ,dQ]=l5(NO,{forceMount:void 0}),d5=e=>{const{__scopeHoverCard:t,forceMount:n,children:r,container:i}=e,o=iv(NO,t);return c.jsx(fQ,{scope:t,forceMount:n,children:c.jsx(Nn,{present:n||o.open,children:c.jsx(ic,{asChild:!0,container:i,children:r})})})};d5.displayName=NO;var hm="HoverCardContent",h5=w.forwardRef((e,t)=>{const n=dQ(hm,e.__scopeHoverCard),{forceMount:r=n.forceMount,...i}=e,o=iv(hm,e.__scopeHoverCard);return c.jsx(Nn,{present:r||o.open,children:c.jsx(hQ,{"data-state":o.open?"open":"closed",...i,onPointerEnter:ye(e.onPointerEnter,mm(o.onOpen)),onPointerLeave:ye(e.onPointerLeave,mm(o.onClose)),ref:t})})});h5.displayName=hm;var hQ=w.forwardRef((e,t)=>{const{__scopeHoverCard:n,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:l,...u}=e,d=iv(hm,n),h=av(n),v=w.useRef(null),p=Be(t,v),[g,b]=w.useState(!1);return w.useEffect(()=>{if(g){const O=document.body;return Rb=O.style.userSelect||O.style.webkitUserSelect,O.style.userSelect="none",O.style.webkitUserSelect="none",()=>{O.style.userSelect=Rb,O.style.webkitUserSelect=Rb}}},[g]),w.useEffect(()=>{if(v.current){const O=()=>{b(!1),d.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var x;((x=document.getSelection())==null?void 0:x.toString())!==""&&(d.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",O),()=>{document.removeEventListener("pointerup",O),d.hasSelectionRef.current=!1,d.isPointerDownOnContentRef.current=!1}}},[d.isPointerDownOnContentRef,d.hasSelectionRef]),w.useEffect(()=>{v.current&&vQ(v.current).forEach(j=>j.setAttribute("tabindex","-1"))}),c.jsx(nc,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:l,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:ye(o,O=>{O.preventDefault()}),onDismiss:d.onDismiss,children:c.jsx(zp,{...h,...u,onPointerDown:ye(u.onPointerDown,O=>{O.currentTarget.contains(O.target)&&b(!0),d.hasSelectionRef.current=!1,d.isPointerDownOnContentRef.current=!0}),ref:p,style:{...u.style,userSelect:g?"text":void 0,WebkitUserSelect:g?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),mQ="HoverCardArrow",pQ=w.forwardRef((e,t)=>{const{__scopeHoverCard:n,...r}=e,i=av(n);return c.jsx(Bp,{...i,...r,ref:t})});pQ.displayName=mQ;function mm(e){return t=>t.pointerType==="touch"?void 0:e()}function vQ(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}var gQ=c5,yQ=f5,bQ=d5,xQ=h5;function wQ({...e}){return c.jsx(gQ,{"data-slot":"hover-card",...e})}function SQ({...e}){return c.jsx(yQ,{"data-slot":"hover-card-trigger",...e})}function jQ({className:e,align:t="center",sideOffset:n=4,...r}){return c.jsx(bQ,{"data-slot":"hover-card-portal",children:c.jsx(xQ,{align:t,className:me("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 z-50 w-64 origin-[--radix-hover-card-content-transform-origin] rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-hidden data-[state=closed]:animate-out data-[state=open]:animate-in",e),"data-slot":"hover-card-content",sideOffset:n,...r})})}function CO({className:e,...t}){return c.jsx("div",{className:"relative w-full overflow-x-auto","data-slot":"table-container",children:c.jsx("table",{className:me("w-full caption-bottom text-sm",e),"data-slot":"table",...t})})}function TO({className:e,...t}){return c.jsx("thead",{className:me("[&_tr]:border-b",e),"data-slot":"table-header",...t})}function MO({className:e,...t}){return c.jsx("tbody",{className:me("[&_tr:last-child]:border-0",e),"data-slot":"table-body",...t})}function la({className:e,...t}){return c.jsx("tr",{className:me("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",e),"data-slot":"table-row",...t})}function pn({className:e,...t}){return c.jsx("th",{className:me("h-10 whitespace-nowrap px-2 text-left align-middle font-medium text-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),"data-slot":"table-head",...t})}function Lt({className:e,...t}){return c.jsx("td",{className:me("whitespace-nowrap p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),"data-slot":"table-cell",...t})}function OQ(e){return e===0?"0 B":e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(0)} KB`:`${(e/(1024*1024)).toFixed(2)} MB`}function m5(e){var t;return((t=e.split(".").pop())==null?void 0:t.toLowerCase())||""}function _Q(e,t){if(e!=null&&e.startsWith("image/"))return!0;const n=t?m5(t):"";return["jpg","jpeg","png","gif","webp","avif","svg","bmp","ico"].includes(n)}function EQ({files:e,selectedFiles:t,onSelectFile:n,onSelectAll:r,onToggleStar:i,onFileClick:o}){const l=(u,d)=>{u.stopPropagation(),window.open(d,"_blank")};return c.jsx("div",{className:"overflow-hidden rounded-lg border border-border",children:c.jsxs(CO,{children:[c.jsx(TO,{children:c.jsxs(la,{className:"bg-muted/50",children:[c.jsx(pn,{className:"w-12",children:c.jsx(iS,{checked:t.length===e.length&&e.length>0,onCheckedChange:r})}),c.jsx(pn,{className:"w-12"}),c.jsx(pn,{children:"Name"}),c.jsx(pn,{children:"Format"}),c.jsx(pn,{children:"Size"}),c.jsx(pn,{children:"Modified"}),c.jsx(pn,{className:"w-24",children:"Actions"})]})}),c.jsx(MO,{children:e.map(u=>{const d=u.key.split("/").pop()||u.key,h=m5(d),v=_Q(u.contentType,d);return c.jsxs(la,{className:"cursor-pointer hover:bg-muted/50",onClick:()=>o(u),children:[c.jsx(Lt,{onClick:p=>p.stopPropagation(),children:c.jsx(iS,{checked:t.includes(u.key),onCheckedChange:()=>n(u.key)})}),c.jsx(Lt,{onClick:p=>p.stopPropagation(),children:c.jsx(ev,{className:"h-8 w-8",starred:u.starred,onToggle:()=>i(u.key,!u.starred)})}),c.jsx(Lt,{children:c.jsxs("div",{className:"flex items-center gap-3",children:[v&&u.url.startsWith("https://")?c.jsxs(wQ,{closeDelay:200,openDelay:100,children:[c.jsx(SQ,{asChild:!0,children:c.jsx("div",{className:"h-10 w-14 shrink-0 cursor-pointer overflow-hidden rounded border bg-muted",children:c.jsx("img",{alt:d,className:"h-full w-full object-cover",src:u.url})})}),c.jsxs(jQ,{align:"start",className:"w-auto p-3",side:"right",children:[c.jsx("img",{alt:d,className:"max-h-[min(400px,40vh)] max-w-[min(400px,25vw)] rounded object-contain",src:u.url}),c.jsx("p",{className:"mt-2 max-w-[min(400px,25vw)] truncate text-center text-muted-foreground text-sm",children:d})]})]}):c.jsx("div",{className:"flex h-10 w-14 shrink-0 items-center justify-center overflow-hidden rounded border bg-muted",children:v?c.jsx(Uj,{className:"h-4 w-4 text-muted-foreground"}):c.jsx(Hj,{className:"h-4 w-4 text-muted-foreground"})}),c.jsx("span",{className:"truncate font-medium",children:d})]})}),c.jsx(Lt,{children:c.jsx(Ge,{variant:"secondary",children:h.toUpperCase()})}),c.jsx(Lt,{className:"text-muted-foreground",children:OQ(u.size)}),c.jsx(Lt,{className:"text-muted-foreground text-xs",children:WX(new Date(u.lastModified),{addSuffix:!0})}),c.jsx(Lt,{onClick:p=>p.stopPropagation(),children:c.jsxs("div",{className:"flex gap-1",children:[c.jsx(Fi,{className:"h-8 w-8",size:"icon",value:u.url,variant:"ghost"}),c.jsx(Ce,{className:"h-8 w-8",onClick:p=>l(p,u.url),size:"icon",variant:"ghost",children:c.jsx(qu,{className:"h-3.5 w-3.5"})})]})})]},u.key)})})]})})}function Db({className:e,...t}){return c.jsx("div",{"data-slot":"input-group",role:"group",className:me("group/input-group border-input dark:bg-input/30 relative flex w-full items-center rounded-md border shadow-xs transition-[color,box-shadow] outline-none","h-9 min-w-0 has-[>textarea]:h-auto","has-[>[data-align=inline-start]]:[&>input]:pl-2","has-[>[data-align=inline-end]]:[&>input]:pr-2","has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>[data-align=block-start]]:[&>input]:pb-3","has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-end]]:[&>input]:pt-3","has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot=input-group-control]:focus-visible]:ring-[3px]","has-[[data-slot][aria-invalid=true]]:ring-destructive/20 has-[[data-slot][aria-invalid=true]]:border-destructive dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40",e),...t})}const AQ=sc("text-muted-foreground flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium select-none [&>svg:not([class*='size-'])]:size-4 [&>kbd]:rounded-[calc(var(--radius)-5px)] group-data-[disabled=true]/input-group:opacity-50",{variants:{align:{"inline-start":"order-first pl-3 has-[>button]:ml-[-0.45rem] has-[>kbd]:ml-[-0.35rem]","inline-end":"order-last pr-3 has-[>button]:mr-[-0.45rem] has-[>kbd]:mr-[-0.35rem]","block-start":"order-first w-full justify-start px-3 pt-3 [.border-b]:pb-3 group-has-[>input]/input-group:pt-2.5","block-end":"order-last w-full justify-start px-3 pb-3 [.border-t]:pt-3 group-has-[>input]/input-group:pb-2.5"}},defaultVariants:{align:"inline-start"}});function sl({className:e,align:t="inline-start",...n}){return c.jsx("div",{role:"group","data-slot":"input-group-addon","data-align":t,className:me(AQ({align:t}),e),onClick:r=>{var i,o;r.target.closest("button")||(o=(i=r.currentTarget.parentElement)==null?void 0:i.querySelector("input"))==null||o.focus()},...n})}function Pb({className:e,...t}){return c.jsx("span",{className:me("text-muted-foreground flex items-center gap-2 text-sm [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4",e),...t})}function kb({className:e,...t}){return c.jsx(ls,{"data-slot":"input-group-control",className:me("flex-1 rounded-none border-0 bg-transparent shadow-none focus-visible:ring-0 dark:bg-transparent",e),...t})}const NQ=sc("relative grid w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[1rem_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current"}},defaultVariants:{variant:"default"}});function qn({className:e,variant:t,...n}){return c.jsx("div",{className:me(NQ({variant:t}),e),"data-slot":"alert",role:"alert",...n})}function Zi({className:e,...t}){return c.jsx("div",{className:me("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",e),"data-slot":"alert-title",...t})}function Un({className:e,...t}){return c.jsx("div",{className:me("col-start-2 grid justify-items-start gap-1 text-muted-foreground text-sm [&_p]:leading-relaxed",e),"data-slot":"alert-description",...t})}var ov="Tabs",[CQ]=jn(ov,[oc]),p5=oc(),[TQ,RO]=CQ(ov),v5=w.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:i,defaultValue:o,orientation:l="horizontal",dir:u,activationMode:d="automatic",...h}=e,v=tc(u),[p,g]=An({prop:r,onChange:i,defaultProp:o??"",caller:ov});return c.jsx(TQ,{scope:n,baseId:Nr(),value:p,onValueChange:g,orientation:l,dir:v,activationMode:d,children:c.jsx(Ee.div,{dir:v,"data-orientation":l,...h,ref:t})})});v5.displayName=ov;var g5="TabsList",y5=w.forwardRef((e,t)=>{const{__scopeTabs:n,loop:r=!0,...i}=e,o=RO(g5,n),l=p5(n);return c.jsx(rO,{asChild:!0,...l,orientation:o.orientation,dir:o.dir,loop:r,children:c.jsx(Ee.div,{role:"tablist","aria-orientation":o.orientation,...i,ref:t})})});y5.displayName=g5;var b5="TabsTrigger",x5=w.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,disabled:i=!1,...o}=e,l=RO(b5,n),u=p5(n),d=j5(l.baseId,r),h=O5(l.baseId,r),v=r===l.value;return c.jsx(aO,{asChild:!0,...u,focusable:!i,active:v,children:c.jsx(Ee.button,{type:"button",role:"tab","aria-selected":v,"aria-controls":h,"data-state":v?"active":"inactive","data-disabled":i?"":void 0,disabled:i,id:d,...o,ref:t,onMouseDown:ye(e.onMouseDown,p=>{!i&&p.button===0&&p.ctrlKey===!1?l.onValueChange(r):p.preventDefault()}),onKeyDown:ye(e.onKeyDown,p=>{[" ","Enter"].includes(p.key)&&l.onValueChange(r)}),onFocus:ye(e.onFocus,()=>{const p=l.activationMode!=="manual";!v&&!i&&p&&l.onValueChange(r)})})})});x5.displayName=b5;var w5="TabsContent",S5=w.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,forceMount:i,children:o,...l}=e,u=RO(w5,n),d=j5(u.baseId,r),h=O5(u.baseId,r),v=r===u.value,p=w.useRef(v);return w.useEffect(()=>{const g=requestAnimationFrame(()=>p.current=!1);return()=>cancelAnimationFrame(g)},[]),c.jsx(Nn,{present:i||v,children:({present:g})=>c.jsx(Ee.div,{"data-state":v?"active":"inactive","data-orientation":u.orientation,role:"tabpanel","aria-labelledby":d,hidden:!g,id:h,tabIndex:0,...l,ref:t,style:{...e.style,animationDuration:p.current?"0s":void 0},children:g&&o})})});S5.displayName=w5;function j5(e,t){return`${e}-trigger-${t}`}function O5(e,t){return`${e}-content-${t}`}var MQ=v5,RQ=y5,DQ=x5,PQ=S5;function _5({className:e,...t}){return c.jsx(MQ,{className:me("flex flex-col gap-2",e),"data-slot":"tabs",...t})}function E5({className:e,...t}){return c.jsx(RQ,{className:me("inline-flex h-9 w-fit items-center justify-center rounded-lg bg-muted p-[3px] text-muted-foreground",e),"data-slot":"tabs-list",...t})}function Du({className:e,...t}){return c.jsx(DQ,{className:me("inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 whitespace-nowrap rounded-md border border-transparent px-2 py-1 font-medium text-foreground text-sm transition-[color,box-shadow] focus-visible:border-ring focus-visible:outline-1 focus-visible:outline-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:shadow-sm dark:text-muted-foreground dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 dark:data-[state=active]:text-foreground [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0",e),"data-slot":"tabs-trigger",...t})}function Pu({className:e,...t}){return c.jsx(PQ,{className:me("flex-1 outline-none",e),"data-slot":"tabs-content",...t})}function kQ({messageId:e,archivingEnabled:t}){const[n,r]=w.useState(null),[i,o]=w.useState(!0),[l,u]=w.useState(null);return w.useEffect(()=>{async function d(){if(!t){o(!1);return}try{o(!0),u(null);const h=sessionStorage.getItem("wraps-auth-token");if(!h)throw new Error("Authentication token not found");const v=encodeURIComponent(e),p=await fetch(`/api/emails/${v}/archive?token=${h}`);if(!p.ok){if(p.status===404){r(null),o(!1);return}throw new Error(`Failed to fetch archived email: ${p.statusText}`)}const g=await p.json();r({...g,timestamp:new Date(g.timestamp)})}catch(h){const v=h instanceof Error?h.message:"Unknown error";u(v),console.error("Error fetching archived email:",h)}finally{o(!1)}}d()},[e,t]),t?i?c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Archive"}),c.jsx(We,{children:"Loading archived email content..."})]}),c.jsx(ze,{className:"space-y-4",children:c.jsx(Ne,{className:"h-[400px] w-full"})})]}):l?c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Archive"}),c.jsx(We,{children:"Failed to load archived email"})]}),c.jsx(ze,{children:c.jsx(qn,{variant:"destructive",children:c.jsx(Un,{children:l})})})]}):n?c.jsxs(Re,{children:[c.jsx(De,{children:c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx(Ue,{children:"Email Archive"}),c.jsx(We,{children:"Full email content stored in AWS SES Mail Manager"})]}),n.attachments.length>0&&c.jsxs(Ge,{variant:"secondary",children:[n.attachments.length," attachment",n.attachments.length>1?"s":""]})]})}),c.jsxs(ze,{children:[c.jsxs(_5,{className:"w-full",defaultValue:"rendered",children:[c.jsxs(E5,{className:"grid w-full grid-cols-3",children:[c.jsxs(Du,{className:"gap-2",value:"rendered",children:[c.jsx(Uu,{className:"h-4 w-4"}),"Rendered Email"]}),c.jsxs(Du,{className:"gap-2",value:"text",children:[c.jsx(gF,{className:"h-4 w-4"}),"Plain Text"]}),c.jsxs(Du,{className:"gap-2",value:"html",children:[c.jsx(mF,{className:"h-4 w-4"}),"HTML Source"]})]}),c.jsxs(Pu,{className:"space-y-4",value:"rendered",children:[n.html?c.jsx("div",{className:"rounded-md border",children:c.jsx("iframe",{className:"h-[600px] w-full rounded-md",sandbox:"allow-same-origin",srcDoc:n.html,title:"Email preview"})}):c.jsx(qn,{children:c.jsx(Un,{children:"No HTML content available for this email. View the plain text tab instead."})}),n.attachments.length>0&&c.jsxs("div",{className:"space-y-2",children:[c.jsx("div",{className:"font-medium text-sm",children:"Attachments"}),c.jsx("div",{className:"space-y-2",children:n.attachments.map((d,h)=>c.jsx("div",{className:"flex items-center justify-between rounded-md border p-3",children:c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"font-mono text-sm",children:d.filename||`Attachment ${h+1}`}),c.jsxs("div",{className:"text-muted-foreground text-xs",children:[d.contentType," •"," ",(d.size/1024).toFixed(2)," KB"]})]})},d.filename||`attachment-${h}`))})]})]}),c.jsx(Pu,{className:"space-y-4",value:"text",children:n.text?c.jsx("div",{className:"rounded-md border bg-muted p-4",children:c.jsx("pre",{className:"whitespace-pre-wrap font-mono text-sm",children:n.text})}):c.jsx(qn,{children:c.jsx(Un,{children:"No plain text content available for this email."})})}),c.jsx(Pu,{className:"space-y-4",value:"html",children:n.html?c.jsx("div",{className:"rounded-md border bg-muted p-4",children:c.jsx("pre",{className:"overflow-x-auto whitespace-pre-wrap font-mono text-xs",children:n.html})}):c.jsx(qn,{children:c.jsx(Un,{children:"No HTML content available for this email."})})})]}),n.metadata&&c.jsxs("div",{className:"mt-6 space-y-3 rounded-md border p-4",children:[c.jsx("div",{className:"font-medium text-sm",children:"SMTP Metadata"}),c.jsxs("div",{className:"grid gap-3 md:grid-cols-2",children:[n.metadata.senderIp&&c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-xs",children:"Sender IP"}),c.jsx("div",{className:"font-mono text-sm",children:n.metadata.senderIp})]}),n.metadata.tlsProtocol&&c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-xs",children:"TLS Protocol"}),c.jsx("div",{className:"font-mono text-sm",children:n.metadata.tlsProtocol})]}),n.metadata.senderHostname&&c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-xs",children:"Sender Hostname"}),c.jsx("div",{className:"font-mono text-sm",children:n.metadata.senderHostname})]})]})]})]})]}):c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Archive"}),c.jsx(We,{children:"Email content not available"})]}),c.jsx(ze,{children:c.jsx(qn,{children:c.jsx(Un,{children:"This email was not archived. It may have been sent before email archiving was enabled for this deployment."})})})]}):c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Archive"}),c.jsx(We,{children:"Enable email archiving to view full email content"})]}),c.jsx(ze,{children:c.jsx(qn,{children:c.jsxs(Un,{children:["Email archiving is not enabled for this deployment. Run"," ",c.jsx("code",{className:"rounded bg-muted px-1.5 py-0.5 font-mono text-xs",children:"wraps upgrade"})," ","to enable archiving and view full email content with HTML rendering."]})})})]})}const $Q={sent:gl,delivered:Ja,bounced:ir,complained:ir,opened:gl,clicked:gl,failed:ir},IQ={sent:"text-blue-500",delivered:"text-green-500",bounced:"text-red-500",complained:"text-red-500",opened:"text-purple-500",clicked:"text-indigo-500",failed:"text-red-500"},LQ={delivered:"default",sent:"secondary",bounced:"destructive",complained:"destructive",failed:"destructive",opened:"default",clicked:"default"};function zQ(){const{id:e}=J4(),t=ns(),[n,r]=w.useState(null),[i,o]=w.useState(!0),[l,u]=w.useState(null),[d,h]=w.useState(!1);w.useEffect(()=>{async function g(){var b,O,j;try{o(!0),u(null);const x=sessionStorage.getItem("wraps-auth-token");if(!x)throw new Error("Authentication token not found");try{const N=await fetch(`/api/settings/deployment?token=${x}`);if(N.ok){const M=await N.json();h(M.archivingEnabled??!1)}}catch(N){console.warn("Failed to fetch deployment config:",N)}const _=encodeURIComponent(e||"");console.log("Fetching email with ID:",e),console.log("Encoded ID:",_),console.log("Full URL:",`/api/emails/${_}?token=${x.substring(0,8)}...`);const A=await fetch(`/api/emails/${_}?token=${x}`);if(!A.ok){let N="Failed to fetch email details";try{N=(await A.json()).error||N}catch{N=`${A.status}: ${A.statusText}`}throw new Error(N)}const E=A.headers.get("content-type");if(!(E!=null&&E.includes("application/json"))){const N=await A.text();throw console.error("Non-JSON response:",N),new Error("Server returned non-JSON response")}const C=await A.json();console.log("Email data received:",{id:C.id,hasHtmlBody:!!C.htmlBody,hasTextBody:!!C.textBody,htmlBodyLength:((b=C.htmlBody)==null?void 0:b.length)||0,textBodyLength:((O=C.textBody)==null?void 0:O.length)||0,events:((j=C.events)==null?void 0:j.length)||0}),r(C)}catch(x){const _=x instanceof Error?x.message:"Unknown error";u(_),console.error("Error fetching email details:",x)}finally{o(!1)}}e&&g()},[e]);const v=g=>new Date(g).toLocaleString("en-US",{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",hour12:!0}),p=g=>new Date(g).toLocaleString("en-US",{weekday:"short",month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit",hour12:!0});return i?c.jsx("div",{className:"flex h-[600px] items-center justify-center",children:c.jsx("div",{className:"text-muted-foreground",children:"Loading email details..."})}):l?c.jsxs("div",{className:"space-y-4",children:[c.jsxs(Ce,{onClick:()=>t("/email"),size:"sm",variant:"ghost",children:[c.jsx(vl,{className:"mr-2 h-4 w-4"}),"Back to emails"]}),c.jsx("div",{className:"rounded-md border border-destructive bg-destructive/10 p-4 text-destructive text-sm",children:l})]}):n?c.jsxs("div",{className:"space-y-6",children:[c.jsx("div",{className:"flex items-center gap-4",children:c.jsxs(Ce,{onClick:()=>t("/email"),size:"sm",variant:"ghost",children:[c.jsx(vl,{className:"mr-2 h-4 w-4"}),"Back"]})}),c.jsx(Re,{children:c.jsxs(De,{className:"space-y-1.5",children:[c.jsxs(Ue,{className:"flex flex-row items-center gap-2 text-xl",children:[c.jsx("span",{className:"text-xl",children:n.subject||"(no subject)"}),c.jsx(Ge,{className:"shrink-0",variant:LQ[n.status],children:n.status.charAt(0).toUpperCase()+n.status.slice(1)})]}),c.jsxs("div",{className:"flex min-w-0 items-center gap-2",children:[c.jsx("code",{className:"min-w-0 truncate rounded bg-muted px-2 py-0.5 font-mono text-muted-foreground text-xs",children:n.messageId}),c.jsx(Fi,{className:"h-6 w-6 shrink-0",size:"sm",value:n.messageId,variant:"ghost"})]}),c.jsxs("div",{className:"flex flex-col gap-3 pt-2 sm:flex-row sm:flex-wrap",children:[c.jsxs(Db,{className:"w-full cursor-text! sm:w-auto sm:min-w-[518px]",children:[c.jsx(sl,{align:"inline-start",children:c.jsx(Pb,{children:"From"})}),c.jsx(kb,{className:"min-w-0 cursor-text! truncate font-mono text-sm *:select-all",disabled:!0,readOnly:!0,value:n.from}),c.jsx(sl,{align:"inline-end",children:c.jsx(Fi,{className:"h-6 w-6",size:"sm",value:n.from,variant:"ghost"})})]}),c.jsxs(Db,{className:"w-full cursor-text! sm:w-auto sm:min-w-[518px]",children:[c.jsx(sl,{align:"inline-start",children:c.jsx(Pb,{children:"To"})}),c.jsx(kb,{className:"min-w-0 cursor-text! truncate font-mono text-sm *:select-all",disabled:!0,readOnly:!0,value:n.to.length>0?n.to.join(", "):"(no recipients)"}),c.jsx(sl,{align:"inline-end",children:c.jsx(Fi,{className:"h-6 w-6",size:"sm",value:n.to.join(", "),variant:"ghost"})})]}),n.replyTo&&c.jsxs(Db,{className:"w-full sm:w-auto sm:max-w-md",children:[c.jsx(sl,{align:"inline-start",children:c.jsx(Pb,{children:"Reply-To"})}),c.jsx(kb,{className:"min-w-0 truncate font-mono text-sm",readOnly:!0,value:n.replyTo}),c.jsx(sl,{align:"inline-end",children:c.jsx(Fi,{className:"h-6 w-6",size:"sm",value:n.replyTo,variant:"ghost"})})]})]})]})}),d&&c.jsx(kQ,{archivingEnabled:d,messageId:n.messageId}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Events"}),c.jsx(We,{children:"Lifecycle of this email from send to delivery"})]}),c.jsx(ze,{children:c.jsx("div",{className:"space-y-4",children:n.events.length===0?c.jsx("div",{className:"text-muted-foreground text-sm",children:"No events recorded yet"}):n.events.map((g,b)=>{const O=$Q[g.type]||Vo,j=b===n.events.length-1;return c.jsx("div",{children:c.jsxs("div",{className:"flex gap-4",children:[c.jsxs("div",{className:"flex flex-col items-center",children:[c.jsx("div",{className:`rounded-full border-2 border-background bg-muted p-2 ${IQ[g.type]}`,children:c.jsx(O,{className:"h-4 w-4"})}),!j&&c.jsx("div",{className:"my-1 w-px flex-1 bg-border"})]}),c.jsxs("div",{className:"flex-1 pb-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("div",{className:"font-medium capitalize",children:g.type}),c.jsx("div",{className:"text-muted-foreground text-sm",children:v(g.timestamp)})]}),c.jsx("div",{className:"text-muted-foreground text-sm",children:p(g.timestamp)}),g.metadata&&Object.keys(g.metadata).length>0&&c.jsx("div",{className:"mt-2 rounded-md border bg-muted/50 p-2 font-mono text-xs",children:c.jsx("pre",{className:"overflow-x-auto",children:JSON.stringify(g.metadata,null,2)})})]})]})},`${g.type}-${g.timestamp}`)})})})]})]}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs(Ce,{onClick:()=>t("/email"),size:"sm",variant:"ghost",children:[c.jsx(vl,{className:"mr-2 h-4 w-4"}),"Back to emails"]}),c.jsx("div",{className:"rounded-md border p-4 text-muted-foreground text-sm",children:"Email not found"})]})}function pm(e,[t,n]){return Math.min(n,Math.max(t,e))}var BQ=[" ","Enter","ArrowUp","ArrowDown"],qQ=[" ","Enter"],Ko="Select",[sv,lv,UQ]=Tp(Ko),[cc]=jn(Ko,[UQ,to]),cv=to(),[HQ,no]=cc(Ko),[FQ,GQ]=cc(Ko),A5=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:o,value:l,defaultValue:u,onValueChange:d,dir:h,name:v,autoComplete:p,disabled:g,required:b,form:O}=e,j=cv(t),[x,_]=w.useState(null),[A,E]=w.useState(null),[C,N]=w.useState(!1),M=tc(h),[R,D]=An({prop:r,defaultProp:i??!1,onChange:o,caller:Ko}),[z,Y]=An({prop:l,defaultProp:u,onChange:d,caller:Ko}),L=w.useRef(null),F=x?O||!!x.closest("form"):!0,[W,Q]=w.useState(new Set),X=Array.from(W).map(k=>k.props.value).join(";");return c.jsx(Ip,{...j,children:c.jsxs(HQ,{required:b,scope:t,trigger:x,onTriggerChange:_,valueNode:A,onValueNodeChange:E,valueNodeHasChildren:C,onValueNodeHasChildrenChange:N,contentId:Nr(),value:z,onValueChange:Y,open:R,onOpenChange:D,dir:M,triggerPointerDownPosRef:L,disabled:g,children:[c.jsx(sv.Provider,{scope:t,children:c.jsx(FQ,{scope:e.__scopeSelect,onNativeOptionAdd:w.useCallback(k=>{Q(H=>new Set(H).add(k))},[]),onNativeOptionRemove:w.useCallback(k=>{Q(H=>{const B=new Set(H);return B.delete(k),B})},[]),children:n})}),F?c.jsxs(K5,{"aria-hidden":!0,required:b,tabIndex:-1,name:v,autoComplete:p,value:z,onChange:k=>Y(k.target.value),disabled:g,form:O,children:[z===void 0?c.jsx("option",{value:""}):null,Array.from(W)]},X):null]})})};A5.displayName=Ko;var N5="SelectTrigger",C5=w.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...i}=e,o=cv(n),l=no(N5,n),u=l.disabled||r,d=Be(t,l.onTriggerChange),h=lv(n),v=w.useRef("touch"),[p,g,b]=Q5(j=>{const x=h().filter(E=>!E.disabled),_=x.find(E=>E.value===l.value),A=Z5(x,j,_);A!==void 0&&l.onValueChange(A.value)}),O=j=>{u||(l.onOpenChange(!0),b()),j&&(l.triggerPointerDownPosRef.current={x:Math.round(j.pageX),y:Math.round(j.pageY)})};return c.jsx(Lp,{asChild:!0,...o,children:c.jsx(Ee.button,{type:"button",role:"combobox","aria-controls":l.contentId,"aria-expanded":l.open,"aria-required":l.required,"aria-autocomplete":"none",dir:l.dir,"data-state":l.open?"open":"closed",disabled:u,"data-disabled":u?"":void 0,"data-placeholder":X5(l.value)?"":void 0,...i,ref:d,onClick:ye(i.onClick,j=>{j.currentTarget.focus(),v.current!=="mouse"&&O(j)}),onPointerDown:ye(i.onPointerDown,j=>{v.current=j.pointerType;const x=j.target;x.hasPointerCapture(j.pointerId)&&x.releasePointerCapture(j.pointerId),j.button===0&&j.ctrlKey===!1&&j.pointerType==="mouse"&&(O(j),j.preventDefault())}),onKeyDown:ye(i.onKeyDown,j=>{const x=p.current!=="";!(j.ctrlKey||j.altKey||j.metaKey)&&j.key.length===1&&g(j.key),!(x&&j.key===" ")&&BQ.includes(j.key)&&(O(),j.preventDefault())})})})});C5.displayName=N5;var T5="SelectValue",M5=w.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,children:o,placeholder:l="",...u}=e,d=no(T5,n),{onValueNodeHasChildrenChange:h}=d,v=o!==void 0,p=Be(t,d.onValueNodeChange);return Yt(()=>{h(v)},[h,v]),c.jsx(Ee.span,{...u,ref:p,style:{pointerEvents:"none"},children:X5(d.value)?c.jsx(c.Fragment,{children:l}):o})});M5.displayName=T5;var VQ="SelectIcon",R5=w.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...i}=e;return c.jsx(Ee.span,{"aria-hidden":!0,...i,ref:t,children:r||"▼"})});R5.displayName=VQ;var YQ="SelectPortal",D5=e=>c.jsx(ic,{asChild:!0,...e});D5.displayName=YQ;var Xo="SelectContent",P5=w.forwardRef((e,t)=>{const n=no(Xo,e.__scopeSelect),[r,i]=w.useState();if(Yt(()=>{i(new DocumentFragment)},[]),!n.open){const o=r;return o?Pf.createPortal(c.jsx(k5,{scope:e.__scopeSelect,children:c.jsx(sv.Slot,{scope:e.__scopeSelect,children:c.jsx("div",{children:e.children})})}),o):null}return c.jsx($5,{...e,ref:t})});P5.displayName=Xo;var qr=10,[k5,ro]=cc(Xo),WQ="SelectContentImpl",KQ=Ol("SelectContent.RemoveScroll"),$5=w.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:o,onPointerDownOutside:l,side:u,sideOffset:d,align:h,alignOffset:v,arrowPadding:p,collisionBoundary:g,collisionPadding:b,sticky:O,hideWhenDetached:j,avoidCollisions:x,..._}=e,A=no(Xo,n),[E,C]=w.useState(null),[N,M]=w.useState(null),R=Be(t,ie=>C(ie)),[D,z]=w.useState(null),[Y,L]=w.useState(null),F=lv(n),[W,Q]=w.useState(!1),X=w.useRef(!1);w.useEffect(()=>{if(E)return iO(E)},[E]),Wj();const k=w.useCallback(ie=>{const[pe,...re]=F().map(oe=>oe.ref.current),[ve]=re.slice(-1),ge=document.activeElement;for(const oe of ie)if(oe===ge||(oe==null||oe.scrollIntoView({block:"nearest"}),oe===pe&&N&&(N.scrollTop=0),oe===ve&&N&&(N.scrollTop=N.scrollHeight),oe==null||oe.focus(),document.activeElement!==ge))return},[F,N]),H=w.useCallback(()=>k([D,E]),[k,D,E]);w.useEffect(()=>{W&&H()},[W,H]);const{onOpenChange:B,triggerPointerDownPosRef:Z}=A;w.useEffect(()=>{if(E){let ie={x:0,y:0};const pe=ve=>{var ge,oe;ie={x:Math.abs(Math.round(ve.pageX)-(((ge=Z.current)==null?void 0:ge.x)??0)),y:Math.abs(Math.round(ve.pageY)-(((oe=Z.current)==null?void 0:oe.y)??0))}},re=ve=>{ie.x<=10&&ie.y<=10?ve.preventDefault():E.contains(ve.target)||B(!1),document.removeEventListener("pointermove",pe),Z.current=null};return Z.current!==null&&(document.addEventListener("pointermove",pe),document.addEventListener("pointerup",re,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",pe),document.removeEventListener("pointerup",re,{capture:!0})}}},[E,B,Z]),w.useEffect(()=>{const ie=()=>B(!1);return window.addEventListener("blur",ie),window.addEventListener("resize",ie),()=>{window.removeEventListener("blur",ie),window.removeEventListener("resize",ie)}},[B]);const[le,$]=Q5(ie=>{const pe=F().filter(ge=>!ge.disabled),re=pe.find(ge=>ge.ref.current===document.activeElement),ve=Z5(pe,ie,re);ve&&setTimeout(()=>ve.ref.current.focus())}),V=w.useCallback((ie,pe,re)=>{const ve=!X.current&&!re;(A.value!==void 0&&A.value===pe||ve)&&(z(ie),ve&&(X.current=!0))},[A.value]),q=w.useCallback(()=>E==null?void 0:E.focus(),[E]),U=w.useCallback((ie,pe,re)=>{const ve=!X.current&&!re;(A.value!==void 0&&A.value===pe||ve)&&L(ie)},[A.value]),ne=r==="popper"?oS:I5,fe=ne===oS?{side:u,sideOffset:d,align:h,alignOffset:v,arrowPadding:p,collisionBoundary:g,collisionPadding:b,sticky:O,hideWhenDetached:j,avoidCollisions:x}:{};return c.jsx(k5,{scope:n,content:E,viewport:N,onViewportChange:M,itemRefCallback:V,selectedItem:D,onItemLeave:q,itemTextRefCallback:U,focusSelectedItem:H,selectedItemText:Y,position:r,isPositioned:W,searchRef:le,children:c.jsx(Up,{as:KQ,allowPinchZoom:!0,children:c.jsx(Mp,{asChild:!0,trapped:A.open,onMountAutoFocus:ie=>{ie.preventDefault()},onUnmountAutoFocus:ye(i,ie=>{var pe;(pe=A.trigger)==null||pe.focus({preventScroll:!0}),ie.preventDefault()}),children:c.jsx(nc,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:l,onFocusOutside:ie=>ie.preventDefault(),onDismiss:()=>A.onOpenChange(!1),children:c.jsx(ne,{role:"listbox",id:A.contentId,"data-state":A.open?"open":"closed",dir:A.dir,onContextMenu:ie=>ie.preventDefault(),..._,...fe,onPlaced:()=>Q(!0),ref:R,style:{display:"flex",flexDirection:"column",outline:"none",..._.style},onKeyDown:ye(_.onKeyDown,ie=>{const pe=ie.ctrlKey||ie.altKey||ie.metaKey;if(ie.key==="Tab"&&ie.preventDefault(),!pe&&ie.key.length===1&&$(ie.key),["ArrowUp","ArrowDown","Home","End"].includes(ie.key)){let ve=F().filter(ge=>!ge.disabled).map(ge=>ge.ref.current);if(["ArrowUp","End"].includes(ie.key)&&(ve=ve.slice().reverse()),["ArrowUp","ArrowDown"].includes(ie.key)){const ge=ie.target,oe=ve.indexOf(ge);ve=ve.slice(oe+1)}setTimeout(()=>k(ve)),ie.preventDefault()}})})})})})})});$5.displayName=WQ;var XQ="SelectItemAlignedPosition",I5=w.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...i}=e,o=no(Xo,n),l=ro(Xo,n),[u,d]=w.useState(null),[h,v]=w.useState(null),p=Be(t,R=>v(R)),g=lv(n),b=w.useRef(!1),O=w.useRef(!0),{viewport:j,selectedItem:x,selectedItemText:_,focusSelectedItem:A}=l,E=w.useCallback(()=>{if(o.trigger&&o.valueNode&&u&&h&&j&&x&&_){const R=o.trigger.getBoundingClientRect(),D=h.getBoundingClientRect(),z=o.valueNode.getBoundingClientRect(),Y=_.getBoundingClientRect();if(o.dir!=="rtl"){const ge=Y.left-D.left,oe=z.left-ge,ke=R.left-oe,we=R.width+ke,Ie=Math.max(we,D.width),Ze=window.innerWidth-qr,lt=pm(oe,[qr,Math.max(qr,Ze-Ie)]);u.style.minWidth=we+"px",u.style.left=lt+"px"}else{const ge=D.right-Y.right,oe=window.innerWidth-z.right-ge,ke=window.innerWidth-R.right-oe,we=R.width+ke,Ie=Math.max(we,D.width),Ze=window.innerWidth-qr,lt=pm(oe,[qr,Math.max(qr,Ze-Ie)]);u.style.minWidth=we+"px",u.style.right=lt+"px"}const L=g(),F=window.innerHeight-qr*2,W=j.scrollHeight,Q=window.getComputedStyle(h),X=parseInt(Q.borderTopWidth,10),k=parseInt(Q.paddingTop,10),H=parseInt(Q.borderBottomWidth,10),B=parseInt(Q.paddingBottom,10),Z=X+k+W+B+H,le=Math.min(x.offsetHeight*5,Z),$=window.getComputedStyle(j),V=parseInt($.paddingTop,10),q=parseInt($.paddingBottom,10),U=R.top+R.height/2-qr,ne=F-U,fe=x.offsetHeight/2,ie=x.offsetTop+fe,pe=X+k+ie,re=Z-pe;if(pe<=U){const ge=L.length>0&&x===L[L.length-1].ref.current;u.style.bottom="0px";const oe=h.clientHeight-j.offsetTop-j.offsetHeight,ke=Math.max(ne,fe+(ge?q:0)+oe+H),we=pe+ke;u.style.height=we+"px"}else{const ge=L.length>0&&x===L[0].ref.current;u.style.top="0px";const ke=Math.max(U,X+j.offsetTop+(ge?V:0)+fe)+re;u.style.height=ke+"px",j.scrollTop=pe-U+j.offsetTop}u.style.margin=`${qr}px 0`,u.style.minHeight=le+"px",u.style.maxHeight=F+"px",r==null||r(),requestAnimationFrame(()=>b.current=!0)}},[g,o.trigger,o.valueNode,u,h,j,x,_,o.dir,r]);Yt(()=>E(),[E]);const[C,N]=w.useState();Yt(()=>{h&&N(window.getComputedStyle(h).zIndex)},[h]);const M=w.useCallback(R=>{R&&O.current===!0&&(E(),A==null||A(),O.current=!1)},[E,A]);return c.jsx(ZQ,{scope:n,contentWrapper:u,shouldExpandOnScrollRef:b,onScrollButtonChange:M,children:c.jsx("div",{ref:d,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:C},children:c.jsx(Ee.div,{...i,ref:p,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}})})})});I5.displayName=XQ;var QQ="SelectPopperPosition",oS=w.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:i=qr,...o}=e,l=cv(n);return c.jsx(zp,{...l,...o,ref:t,align:r,collisionPadding:i,style:{boxSizing:"border-box",...o.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});oS.displayName=QQ;var[ZQ,DO]=cc(Xo,{}),sS="SelectViewport",L5=w.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...i}=e,o=ro(sS,n),l=DO(sS,n),u=Be(t,o.onViewportChange),d=w.useRef(0);return c.jsxs(c.Fragment,{children:[c.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),c.jsx(sv.Slot,{scope:n,children:c.jsx(Ee.div,{"data-radix-select-viewport":"",role:"presentation",...i,ref:u,style:{position:"relative",flex:1,overflow:"hidden auto",...i.style},onScroll:ye(i.onScroll,h=>{const v=h.currentTarget,{contentWrapper:p,shouldExpandOnScrollRef:g}=l;if(g!=null&&g.current&&p){const b=Math.abs(d.current-v.scrollTop);if(b>0){const O=window.innerHeight-qr*2,j=parseFloat(p.style.minHeight),x=parseFloat(p.style.height),_=Math.max(j,x);if(_<O){const A=_+b,E=Math.min(O,A),C=A-E;p.style.height=E+"px",p.style.bottom==="0px"&&(v.scrollTop=C>0?C:0,p.style.justifyContent="flex-end")}}}d.current=v.scrollTop})})})]})});L5.displayName=sS;var z5="SelectGroup",[JQ,eZ]=cc(z5),tZ=w.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=Nr();return c.jsx(JQ,{scope:n,id:i,children:c.jsx(Ee.div,{role:"group","aria-labelledby":i,...r,ref:t})})});tZ.displayName=z5;var B5="SelectLabel",nZ=w.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=eZ(B5,n);return c.jsx(Ee.div,{id:i.id,...r,ref:t})});nZ.displayName=B5;var vm="SelectItem",[rZ,q5]=cc(vm),U5=w.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:i=!1,textValue:o,...l}=e,u=no(vm,n),d=ro(vm,n),h=u.value===r,[v,p]=w.useState(o??""),[g,b]=w.useState(!1),O=Be(t,A=>{var E;return(E=d.itemRefCallback)==null?void 0:E.call(d,A,r,i)}),j=Nr(),x=w.useRef("touch"),_=()=>{i||(u.onValueChange(r),u.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return c.jsx(rZ,{scope:n,value:r,disabled:i,textId:j,isSelected:h,onItemTextChange:w.useCallback(A=>{p(E=>E||((A==null?void 0:A.textContent)??"").trim())},[]),children:c.jsx(sv.ItemSlot,{scope:n,value:r,disabled:i,textValue:v,children:c.jsx(Ee.div,{role:"option","aria-labelledby":j,"data-highlighted":g?"":void 0,"aria-selected":h&&g,"data-state":h?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1,...l,ref:O,onFocus:ye(l.onFocus,()=>b(!0)),onBlur:ye(l.onBlur,()=>b(!1)),onClick:ye(l.onClick,()=>{x.current!=="mouse"&&_()}),onPointerUp:ye(l.onPointerUp,()=>{x.current==="mouse"&&_()}),onPointerDown:ye(l.onPointerDown,A=>{x.current=A.pointerType}),onPointerMove:ye(l.onPointerMove,A=>{var E;x.current=A.pointerType,i?(E=d.onItemLeave)==null||E.call(d):x.current==="mouse"&&A.currentTarget.focus({preventScroll:!0})}),onPointerLeave:ye(l.onPointerLeave,A=>{var E;A.currentTarget===document.activeElement&&((E=d.onItemLeave)==null||E.call(d))}),onKeyDown:ye(l.onKeyDown,A=>{var C;((C=d.searchRef)==null?void 0:C.current)!==""&&A.key===" "||(qQ.includes(A.key)&&_(),A.key===" "&&A.preventDefault())})})})})});U5.displayName=vm;var Cu="SelectItemText",H5=w.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,...o}=e,l=no(Cu,n),u=ro(Cu,n),d=q5(Cu,n),h=GQ(Cu,n),[v,p]=w.useState(null),g=Be(t,_=>p(_),d.onItemTextChange,_=>{var A;return(A=u.itemTextRefCallback)==null?void 0:A.call(u,_,d.value,d.disabled)}),b=v==null?void 0:v.textContent,O=w.useMemo(()=>c.jsx("option",{value:d.value,disabled:d.disabled,children:b},d.value),[d.disabled,d.value,b]),{onNativeOptionAdd:j,onNativeOptionRemove:x}=h;return Yt(()=>(j(O),()=>x(O)),[j,x,O]),c.jsxs(c.Fragment,{children:[c.jsx(Ee.span,{id:d.textId,...o,ref:g}),d.isSelected&&l.valueNode&&!l.valueNodeHasChildren?Pf.createPortal(o.children,l.valueNode):null]})});H5.displayName=Cu;var F5="SelectItemIndicator",G5=w.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return q5(F5,n).isSelected?c.jsx(Ee.span,{"aria-hidden":!0,...r,ref:t}):null});G5.displayName=F5;var lS="SelectScrollUpButton",V5=w.forwardRef((e,t)=>{const n=ro(lS,e.__scopeSelect),r=DO(lS,e.__scopeSelect),[i,o]=w.useState(!1),l=Be(t,r.onScrollButtonChange);return Yt(()=>{if(n.viewport&&n.isPositioned){let u=function(){const h=d.scrollTop>0;o(h)};const d=n.viewport;return u(),d.addEventListener("scroll",u),()=>d.removeEventListener("scroll",u)}},[n.viewport,n.isPositioned]),i?c.jsx(W5,{...e,ref:l,onAutoScroll:()=>{const{viewport:u,selectedItem:d}=n;u&&d&&(u.scrollTop=u.scrollTop-d.offsetHeight)}}):null});V5.displayName=lS;var cS="SelectScrollDownButton",Y5=w.forwardRef((e,t)=>{const n=ro(cS,e.__scopeSelect),r=DO(cS,e.__scopeSelect),[i,o]=w.useState(!1),l=Be(t,r.onScrollButtonChange);return Yt(()=>{if(n.viewport&&n.isPositioned){let u=function(){const h=d.scrollHeight-d.clientHeight,v=Math.ceil(d.scrollTop)<h;o(v)};const d=n.viewport;return u(),d.addEventListener("scroll",u),()=>d.removeEventListener("scroll",u)}},[n.viewport,n.isPositioned]),i?c.jsx(W5,{...e,ref:l,onAutoScroll:()=>{const{viewport:u,selectedItem:d}=n;u&&d&&(u.scrollTop=u.scrollTop+d.offsetHeight)}}):null});Y5.displayName=cS;var W5=w.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...i}=e,o=ro("SelectScrollButton",n),l=w.useRef(null),u=lv(n),d=w.useCallback(()=>{l.current!==null&&(window.clearInterval(l.current),l.current=null)},[]);return w.useEffect(()=>()=>d(),[d]),Yt(()=>{var v;const h=u().find(p=>p.ref.current===document.activeElement);(v=h==null?void 0:h.ref.current)==null||v.scrollIntoView({block:"nearest"})},[u]),c.jsx(Ee.div,{"aria-hidden":!0,...i,ref:t,style:{flexShrink:0,...i.style},onPointerDown:ye(i.onPointerDown,()=>{l.current===null&&(l.current=window.setInterval(r,50))}),onPointerMove:ye(i.onPointerMove,()=>{var h;(h=o.onItemLeave)==null||h.call(o),l.current===null&&(l.current=window.setInterval(r,50))}),onPointerLeave:ye(i.onPointerLeave,()=>{d()})})}),aZ="SelectSeparator",iZ=w.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return c.jsx(Ee.div,{"aria-hidden":!0,...r,ref:t})});iZ.displayName=aZ;var uS="SelectArrow",oZ=w.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=cv(n),o=no(uS,n),l=ro(uS,n);return o.open&&l.position==="popper"?c.jsx(Bp,{...i,...r,ref:t}):null});oZ.displayName=uS;var sZ="SelectBubbleInput",K5=w.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const i=w.useRef(null),o=Be(r,i),l=tv(t);return w.useEffect(()=>{const u=i.current;if(!u)return;const d=window.HTMLSelectElement.prototype,v=Object.getOwnPropertyDescriptor(d,"value").set;if(l!==t&&v){const p=new Event("change",{bubbles:!0});v.call(u,t),u.dispatchEvent(p)}},[l,t]),c.jsx(Ee.select,{...n,style:{...j3,...n.style},ref:o,defaultValue:t})});K5.displayName=sZ;function X5(e){return e===""||e===void 0}function Q5(e){const t=Yr(e),n=w.useRef(""),r=w.useRef(0),i=w.useCallback(l=>{const u=n.current+l;t(u),(function d(h){n.current=h,window.clearTimeout(r.current),h!==""&&(r.current=window.setTimeout(()=>d(""),1e3))})(u)},[t]),o=w.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return w.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,o]}function Z5(e,t,n){const i=t.length>1&&Array.from(t).every(h=>h===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let l=lZ(e,Math.max(o,0));i.length===1&&(l=l.filter(h=>h!==n));const d=l.find(h=>h.textValue.toLowerCase().startsWith(i.toLowerCase()));return d!==n?d:void 0}function lZ(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var cZ=A5,uZ=C5,fZ=M5,dZ=R5,hZ=D5,mZ=P5,pZ=L5,vZ=U5,gZ=H5,yZ=G5,bZ=V5,xZ=Y5;function fa({...e}){return c.jsx(cZ,{"data-slot":"select",...e})}function da({...e}){return c.jsx(fZ,{"data-slot":"select-value",...e})}function ha({className:e,size:t="default",children:n,...r}){return c.jsxs(uZ,{className:me("flex w-fit items-center justify-between gap-2 whitespace-nowrap rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-xs outline-none transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[size=default]:h-9 data-[size=sm]:h-8 data-[placeholder]:text-muted-foreground *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 dark:bg-input/30 dark:aria-invalid:ring-destructive/40 dark:hover:bg-input/50 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0",e),"data-size":t,"data-slot":"select-trigger",...r,children:[n,c.jsx(dZ,{asChild:!0,children:c.jsx(rs,{className:"size-4 opacity-50"})})]})}function ma({className:e,children:t,position:n="popper",align:r="center",...i}){return c.jsx(hZ,{children:c.jsxs(mZ,{align:r,className:me("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 relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] origin-[--radix-select-content-transform-origin] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=closed]:animate-out data-[state=open]:animate-in",n==="popper"&&"data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=bottom]:translate-y-1 data-[side=top]:-translate-y-1",e),"data-slot":"select-content",position:n,...i,children:[c.jsx(wZ,{}),c.jsx(pZ,{className:me("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),c.jsx(SZ,{})]})})}function Fe({className:e,children:t,...n}){return c.jsxs(vZ,{className:me("relative flex w-full cursor-default select-none items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",e),"data-slot":"select-item",...n,children:[c.jsx("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:c.jsx(yZ,{children:c.jsx(Ja,{className:"size-4"})})}),c.jsx(gZ,{children:t})]})}function wZ({className:e,...t}){return c.jsx(bZ,{className:me("flex cursor-default items-center justify-center py-1",e),"data-slot":"select-scroll-up-button",...t,children:c.jsx(kf,{className:"size-4"})})}function SZ({className:e,...t}){return c.jsx(xZ,{className:me("flex cursor-default items-center justify-center py-1",e),"data-slot":"select-scroll-down-button",...t,children:c.jsx(rs,{className:"size-4"})})}const $b={clicked:{variant:"default",description:"Recipient clicked a link in the email",className:"bg-purple-500/10 text-purple-700 dark:text-purple-400 hover:bg-purple-500/20 border-purple-500/20"},opened:{variant:"default",description:"Recipient opened the email",className:"bg-blue-500/10 text-blue-700 dark:text-blue-400 hover:bg-blue-500/20 border-blue-500/20"},delivered:{variant:"default",description:"Email was successfully delivered to recipient's mailbox",className:"bg-green-500/10 text-green-700 dark:text-green-400 hover:bg-green-500/20 border-green-500/20"},sent:{variant:"secondary",description:"Email was sent but delivery not yet confirmed",className:"bg-gray-500/10 text-gray-700 dark:text-gray-400 hover:bg-gray-500/20 border-gray-500/20"},bounced:{variant:"default",description:"Email bounced - recipient's mailbox may not exist or be full",className:"bg-orange-500/10 text-orange-700 dark:text-orange-400 hover:bg-orange-500/20 border-orange-500/20"},complained:{variant:"default",description:"Recipient marked this email as spam",className:"bg-red-500/10 text-red-700 dark:text-red-400 hover:bg-red-500/20 border-red-500/20"},failed:{variant:"default",description:"Email failed to send due to an error",className:"bg-red-500/10 text-red-700 dark:text-red-400 hover:bg-red-500/20 border-red-500/20"}};function jZ(){const e=ns(),[t,n]=w.useState(""),[r,i]=w.useState("15"),[o,l]=w.useState("all"),[u,d]=w.useState("sending"),[h,v]=w.useState([]),[p,g]=w.useState(!0),[b,O]=w.useState(null);w.useEffect(()=>{async function _(){try{g(!0),O(null);let A=sessionStorage.getItem("wraps-auth-token");if(A||(A=new URLSearchParams(window.location.search).get("token"),A&&sessionStorage.setItem("wraps-auth-token",A)),!A)throw new Error("Authentication token not found. Please use the URL provided by 'wraps console' command.");const E=Number.parseInt(r,10),C=Date.now()-E*24*60*60*1e3,N=Date.now(),M=await fetch(`/api/emails?startTime=${C}&endTime=${N}&limit=100&token=${A}`);if(!M.ok){let D="Failed to fetch email logs";try{D=(await M.json()).error||D}catch{D=`${M.status}: ${M.statusText}`}throw new Error(D)}const R=await M.json();v(R.logs.map(D=>({id:D.messageId,to:D.to,from:D.from,subject:D.subject,status:D.status,timestamp:D.sentAt,messageId:D.messageId})))}catch(A){const E=A instanceof Error?A.message:"Unknown error";O(E),console.error("Error fetching email logs:",A)}finally{g(!1)}}_()},[r]);const j=h.filter(_=>{if(t){const A=t.toLowerCase(),E=_.to.some(N=>N.toLowerCase().includes(A)),C=_.subject.toLowerCase().includes(A);if(!(E||C))return!1}return!(o!=="all"&&_.status!==o)}),x=_=>{const A=new Date(_),C=Math.floor((new Date().getTime()-A.getTime())/(1e3*60*60*24));return C===0?"Today":C===1?"Yesterday":C<7?`${C} days ago`:A.toLocaleDateString()};return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Emails"}),c.jsx(We,{children:"View and manage your email sending history"})]}),c.jsx(ze,{children:c.jsxs(_5,{onValueChange:d,value:u,children:[c.jsxs(E5,{children:[c.jsx(Du,{value:"sending",children:"Sending"}),c.jsx(Du,{value:"receiving",children:"Receiving"})]}),c.jsxs(Pu,{className:"space-y-4",value:"sending",children:[b&&c.jsx("div",{className:"rounded-md border border-destructive bg-destructive/10 p-4 text-destructive text-sm",children:b}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsxs("div",{className:"relative flex-1",children:[c.jsx(Fj,{className:"absolute top-2.5 left-2.5 h-4 w-4 text-muted-foreground"}),c.jsx(ls,{className:"pl-8",onChange:_=>n(_.target.value),placeholder:"Search...",value:t})]}),c.jsxs(fa,{onValueChange:i,value:r,children:[c.jsx(ha,{className:"w-[180px]",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"1",children:"Last 24 hours"}),c.jsx(Fe,{value:"7",children:"Last 7 days"}),c.jsx(Fe,{value:"15",children:"Last 15 days"}),c.jsx(Fe,{value:"30",children:"Last 30 days"}),c.jsx(Fe,{value:"90",children:"Last 90 days"})]})]}),c.jsxs(fa,{onValueChange:l,value:o,children:[c.jsx(ha,{className:"w-[180px]",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"all",children:"All Statuses"}),c.jsx(Fe,{value:"clicked",children:"Clicked"}),c.jsx(Fe,{value:"opened",children:"Opened"}),c.jsx(Fe,{value:"delivered",children:"Delivered"}),c.jsx(Fe,{value:"sent",children:"Sent"}),c.jsx(Fe,{value:"bounced",children:"Bounced"}),c.jsx(Fe,{value:"complained",children:"Complained"}),c.jsx(Fe,{value:"failed",children:"Failed"})]})]}),c.jsxs(Ce,{size:"icon",variant:"outline",children:[c.jsx("span",{className:"sr-only",children:"Download"}),"↓"]})]}),c.jsx("div",{className:"rounded-md border",children:c.jsxs(CO,{children:[c.jsx(TO,{children:c.jsxs(la,{children:[c.jsx(pn,{children:"To"}),c.jsx(pn,{children:"Status"}),c.jsx(pn,{children:"Subject"}),c.jsx(pn,{children:"Sent"}),c.jsx(pn,{className:"w-[50px]"})]})}),c.jsx(MO,{children:p?c.jsx(la,{children:c.jsx(Lt,{className:"h-24 text-center text-muted-foreground",colSpan:5,children:"Loading email logs..."})}):j.length===0?c.jsx(la,{children:c.jsx(Lt,{className:"h-24 text-center text-muted-foreground",colSpan:5,children:"No emails found"})}):j.map(_=>{var A,E,C;return c.jsxs(la,{className:"cursor-pointer hover:bg-muted/50",onClick:()=>e(`/email/${_.id}`),children:[c.jsx(Lt,{className:"font-mono text-sm",children:_.to.length>0?c.jsxs(c.Fragment,{children:[_.to[0],_.to.length>1&&c.jsxs("span",{className:"ml-1 text-muted-foreground text-xs",children:["+",_.to.length-1," more"]})]}):c.jsx("span",{className:"text-muted-foreground",children:"(no recipients)"})}),c.jsx(Lt,{children:c.jsxs(Xp,{children:[c.jsx(Qp,{asChild:!0,children:c.jsx(Ge,{className:(A=$b[_.status])==null?void 0:A.className,variant:((E=$b[_.status])==null?void 0:E.variant)??"default",children:_.status.charAt(0).toUpperCase()+_.status.slice(1)})}),c.jsx(Zp,{children:c.jsx("p",{children:((C=$b[_.status])==null?void 0:C.description)??"Unknown status"})})]})}),c.jsx(Lt,{className:"max-w-[400px] truncate",children:_.subject}),c.jsx(Lt,{className:"text-muted-foreground",children:x(_.timestamp)}),c.jsx(Lt,{children:c.jsxs(Ce,{onClick:N=>{N.stopPropagation()},size:"icon",variant:"ghost",children:[c.jsx("span",{className:"sr-only",children:"More options"}),"⋯"]})})]},_.id)})})]})}),j.length>0&&!p&&c.jsx("div",{className:"flex items-center justify-between text-muted-foreground text-sm",children:c.jsxs("div",{children:["Showing ",j.length," of ",h.length," emails"]})})]}),c.jsx(Pu,{value:"receiving",children:c.jsx("div",{className:"flex h-[400px] items-center justify-center text-muted-foreground",children:"Receiving emails coming soon"})})]})})]})}var Ib,XC;function Fn(){if(XC)return Ib;XC=1;var e=Array.isArray;return Ib=e,Ib}var Lb,QC;function J5(){if(QC)return Lb;QC=1;var e=typeof mh=="object"&&mh&&mh.Object===Object&&mh;return Lb=e,Lb}var zb,ZC;function wa(){if(ZC)return zb;ZC=1;var e=J5(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return zb=n,zb}var Bb,JC;function Gf(){if(JC)return Bb;JC=1;var e=wa(),t=e.Symbol;return Bb=t,Bb}var qb,eT;function OZ(){if(eT)return qb;eT=1;var e=Gf(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function o(l){var u=n.call(l,i),d=l[i];try{l[i]=void 0;var h=!0}catch{}var v=r.call(l);return h&&(u?l[i]=d:delete l[i]),v}return qb=o,qb}var Ub,tT;function _Z(){if(tT)return Ub;tT=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return Ub=n,Ub}var Hb,nT;function li(){if(nT)return Hb;nT=1;var e=Gf(),t=OZ(),n=_Z(),r="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function l(u){return u==null?u===void 0?i:r:o&&o in Object(u)?t(u):n(u)}return Hb=l,Hb}var Fb,rT;function ci(){if(rT)return Fb;rT=1;function e(t){return t!=null&&typeof t=="object"}return Fb=e,Fb}var Gb,aT;function uc(){if(aT)return Gb;aT=1;var e=li(),t=ci(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return Gb=r,Gb}var Vb,iT;function PO(){if(iT)return Vb;iT=1;var e=Fn(),t=uc(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,l){if(e(o))return!1;var u=typeof o;return u=="number"||u=="symbol"||u=="boolean"||o==null||t(o)?!0:r.test(o)||!n.test(o)||l!=null&&o in Object(l)}return Vb=i,Vb}var Yb,oT;function ao(){if(oT)return Yb;oT=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return Yb=e,Yb}var Wb,sT;function kO(){if(sT)return Wb;sT=1;var e=li(),t=ao(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function l(u){if(!t(u))return!1;var d=e(u);return d==r||d==i||d==n||d==o}return Wb=l,Wb}var Kb,lT;function EZ(){if(lT)return Kb;lT=1;var e=wa(),t=e["__core-js_shared__"];return Kb=t,Kb}var Xb,cT;function AZ(){if(cT)return Xb;cT=1;var e=EZ(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return Xb=n,Xb}var Qb,uT;function eL(){if(uT)return Qb;uT=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch{}try{return r+""}catch{}}return""}return Qb=n,Qb}var Zb,fT;function NZ(){if(fT)return Zb;fT=1;var e=kO(),t=AZ(),n=ao(),r=eL(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,l=Function.prototype,u=Object.prototype,d=l.toString,h=u.hasOwnProperty,v=RegExp("^"+d.call(h).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function p(g){if(!n(g)||t(g))return!1;var b=e(g)?v:o;return b.test(r(g))}return Zb=p,Zb}var Jb,dT;function CZ(){if(dT)return Jb;dT=1;function e(t,n){return t==null?void 0:t[n]}return Jb=e,Jb}var ex,hT;function cs(){if(hT)return ex;hT=1;var e=NZ(),t=CZ();function n(r,i){var o=t(r,i);return e(o)?o:void 0}return ex=n,ex}var tx,mT;function uv(){if(mT)return tx;mT=1;var e=cs(),t=e(Object,"create");return tx=t,tx}var nx,pT;function TZ(){if(pT)return nx;pT=1;var e=uv();function t(){this.__data__=e?e(null):{},this.size=0}return nx=t,nx}var rx,vT;function MZ(){if(vT)return rx;vT=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return rx=e,rx}var ax,gT;function RZ(){if(gT)return ax;gT=1;var e=uv(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(o){var l=this.__data__;if(e){var u=l[o];return u===t?void 0:u}return r.call(l,o)?l[o]:void 0}return ax=i,ax}var ix,yT;function DZ(){if(yT)return ix;yT=1;var e=uv(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var o=this.__data__;return e?o[i]!==void 0:n.call(o,i)}return ix=r,ix}var ox,bT;function PZ(){if(bT)return ox;bT=1;var e=uv(),t="__lodash_hash_undefined__";function n(r,i){var o=this.__data__;return this.size+=this.has(r)?0:1,o[r]=e&&i===void 0?t:i,this}return ox=n,ox}var sx,xT;function kZ(){if(xT)return sx;xT=1;var e=TZ(),t=MZ(),n=RZ(),r=DZ(),i=PZ();function o(l){var u=-1,d=l==null?0:l.length;for(this.clear();++u<d;){var h=l[u];this.set(h[0],h[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,sx=o,sx}var lx,wT;function $Z(){if(wT)return lx;wT=1;function e(){this.__data__=[],this.size=0}return lx=e,lx}var cx,ST;function $O(){if(ST)return cx;ST=1;function e(t,n){return t===n||t!==t&&n!==n}return cx=e,cx}var ux,jT;function fv(){if(jT)return ux;jT=1;var e=$O();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return ux=t,ux}var fx,OT;function IZ(){if(OT)return fx;OT=1;var e=fv(),t=Array.prototype,n=t.splice;function r(i){var o=this.__data__,l=e(o,i);if(l<0)return!1;var u=o.length-1;return l==u?o.pop():n.call(o,l,1),--this.size,!0}return fx=r,fx}var dx,_T;function LZ(){if(_T)return dx;_T=1;var e=fv();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return dx=t,dx}var hx,ET;function zZ(){if(ET)return hx;ET=1;var e=fv();function t(n){return e(this.__data__,n)>-1}return hx=t,hx}var mx,AT;function BZ(){if(AT)return mx;AT=1;var e=fv();function t(n,r){var i=this.__data__,o=e(i,n);return o<0?(++this.size,i.push([n,r])):i[o][1]=r,this}return mx=t,mx}var px,NT;function dv(){if(NT)return px;NT=1;var e=$Z(),t=IZ(),n=LZ(),r=zZ(),i=BZ();function o(l){var u=-1,d=l==null?0:l.length;for(this.clear();++u<d;){var h=l[u];this.set(h[0],h[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,px=o,px}var vx,CT;function IO(){if(CT)return vx;CT=1;var e=cs(),t=wa(),n=e(t,"Map");return vx=n,vx}var gx,TT;function qZ(){if(TT)return gx;TT=1;var e=kZ(),t=dv(),n=IO();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return gx=r,gx}var yx,MT;function UZ(){if(MT)return yx;MT=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return yx=e,yx}var bx,RT;function hv(){if(RT)return bx;RT=1;var e=UZ();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return bx=t,bx}var xx,DT;function HZ(){if(DT)return xx;DT=1;var e=hv();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return xx=t,xx}var wx,PT;function FZ(){if(PT)return wx;PT=1;var e=hv();function t(n){return e(this,n).get(n)}return wx=t,wx}var Sx,kT;function GZ(){if(kT)return Sx;kT=1;var e=hv();function t(n){return e(this,n).has(n)}return Sx=t,Sx}var jx,$T;function VZ(){if($T)return jx;$T=1;var e=hv();function t(n,r){var i=e(this,n),o=i.size;return i.set(n,r),this.size+=i.size==o?0:1,this}return jx=t,jx}var Ox,IT;function LO(){if(IT)return Ox;IT=1;var e=qZ(),t=HZ(),n=FZ(),r=GZ(),i=VZ();function o(l){var u=-1,d=l==null?0:l.length;for(this.clear();++u<d;){var h=l[u];this.set(h[0],h[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Ox=o,Ox}var _x,LT;function tL(){if(LT)return _x;LT=1;var e=LO(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var l=arguments,u=i?i.apply(this,l):l[0],d=o.cache;if(d.has(u))return d.get(u);var h=r.apply(this,l);return o.cache=d.set(u,h)||d,h};return o.cache=new(n.Cache||e),o}return n.Cache=e,_x=n,_x}var Ex,zT;function YZ(){if(zT)return Ex;zT=1;var e=tL(),t=500;function n(r){var i=e(r,function(l){return o.size===t&&o.clear(),l}),o=i.cache;return i}return Ex=n,Ex}var Ax,BT;function WZ(){if(BT)return Ax;BT=1;var e=YZ(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(l,u,d,h){o.push(d?h.replace(n,"$1"):u||l)}),o});return Ax=r,Ax}var Nx,qT;function zO(){if(qT)return Nx;qT=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=Array(i);++r<i;)o[r]=n(t[r],r,t);return o}return Nx=e,Nx}var Cx,UT;function KZ(){if(UT)return Cx;UT=1;var e=Gf(),t=zO(),n=Fn(),r=uc(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function l(u){if(typeof u=="string")return u;if(n(u))return t(u,l)+"";if(r(u))return o?o.call(u):"";var d=u+"";return d=="0"&&1/u==-1/0?"-0":d}return Cx=l,Cx}var Tx,HT;function nL(){if(HT)return Tx;HT=1;var e=KZ();function t(n){return n==null?"":e(n)}return Tx=t,Tx}var Mx,FT;function rL(){if(FT)return Mx;FT=1;var e=Fn(),t=PO(),n=WZ(),r=nL();function i(o,l){return e(o)?o:t(o,l)?[o]:n(r(o))}return Mx=i,Mx}var Rx,GT;function mv(){if(GT)return Rx;GT=1;var e=uc();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return Rx=t,Rx}var Dx,VT;function BO(){if(VT)return Dx;VT=1;var e=rL(),t=mv();function n(r,i){i=e(i,r);for(var o=0,l=i.length;r!=null&&o<l;)r=r[t(i[o++])];return o&&o==l?r:void 0}return Dx=n,Dx}var Px,YT;function aL(){if(YT)return Px;YT=1;var e=BO();function t(n,r,i){var o=n==null?void 0:e(n,r);return o===void 0?i:o}return Px=t,Px}var XZ=aL();const Tr=bt(XZ);var kx,WT;function QZ(){if(WT)return kx;WT=1;function e(t){return t==null}return kx=e,kx}var ZZ=QZ();const Qe=bt(ZZ);var $x,KT;function JZ(){if(KT)return $x;KT=1;var e=li(),t=Fn(),n=ci(),r="[object String]";function i(o){return typeof o=="string"||!t(o)&&n(o)&&e(o)==r}return $x=i,$x}var eJ=JZ();const Qo=bt(eJ);var tJ=kO();const Ye=bt(tJ);var nJ=ao();const fc=bt(nJ);var Ix={exports:{}},ct={};/**
393
+ * @license React
394
+ * react-is.production.min.js
395
+ *
396
+ * Copyright (c) Facebook, Inc. and its affiliates.
397
+ *
398
+ * This source code is licensed under the MIT license found in the
399
+ * LICENSE file in the root directory of this source tree.
400
+ */var XT;function rJ(){if(XT)return ct;XT=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),l=Symbol.for("react.context"),u=Symbol.for("react.server_context"),d=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),v=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),O;O=Symbol.for("react.module.reference");function j(x){if(typeof x=="object"&&x!==null){var _=x.$$typeof;switch(_){case e:switch(x=x.type,x){case n:case i:case r:case h:case v:return x;default:switch(x=x&&x.$$typeof,x){case u:case l:case d:case g:case p:case o:return x;default:return _}}case t:return _}}}return ct.ContextConsumer=l,ct.ContextProvider=o,ct.Element=e,ct.ForwardRef=d,ct.Fragment=n,ct.Lazy=g,ct.Memo=p,ct.Portal=t,ct.Profiler=i,ct.StrictMode=r,ct.Suspense=h,ct.SuspenseList=v,ct.isAsyncMode=function(){return!1},ct.isConcurrentMode=function(){return!1},ct.isContextConsumer=function(x){return j(x)===l},ct.isContextProvider=function(x){return j(x)===o},ct.isElement=function(x){return typeof x=="object"&&x!==null&&x.$$typeof===e},ct.isForwardRef=function(x){return j(x)===d},ct.isFragment=function(x){return j(x)===n},ct.isLazy=function(x){return j(x)===g},ct.isMemo=function(x){return j(x)===p},ct.isPortal=function(x){return j(x)===t},ct.isProfiler=function(x){return j(x)===i},ct.isStrictMode=function(x){return j(x)===r},ct.isSuspense=function(x){return j(x)===h},ct.isSuspenseList=function(x){return j(x)===v},ct.isValidElementType=function(x){return typeof x=="string"||typeof x=="function"||x===n||x===i||x===r||x===h||x===v||x===b||typeof x=="object"&&x!==null&&(x.$$typeof===g||x.$$typeof===p||x.$$typeof===o||x.$$typeof===l||x.$$typeof===d||x.$$typeof===O||x.getModuleId!==void 0)},ct.typeOf=j,ct}var QT;function aJ(){return QT||(QT=1,Ix.exports=rJ()),Ix.exports}var iJ=aJ(),Lx,ZT;function iL(){if(ZT)return Lx;ZT=1;var e=li(),t=ci(),n="[object Number]";function r(i){return typeof i=="number"||t(i)&&e(i)==n}return Lx=r,Lx}var zx,JT;function oJ(){if(JT)return zx;JT=1;var e=iL();function t(n){return e(n)&&n!=+n}return zx=t,zx}var sJ=oJ();const Vf=bt(sJ);var lJ=iL();const cJ=bt(lJ);var Vr=function(t){return t===0?0:t>0?1:-1},zo=function(t){return Qo(t)&&t.indexOf("%")===t.length-1},be=function(t){return cJ(t)&&!Vf(t)},uJ=function(t){return Qe(t)},Zt=function(t){return be(t)||Qo(t)},fJ=0,Yf=function(t){var n=++fJ;return"".concat(t||"").concat(n)},Zo=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!be(t)&&!Qo(t))return r;var o;if(zo(t)){var l=t.indexOf("%");o=n*parseFloat(t.slice(0,l))/100}else o=+t;return Vf(o)&&(o=r),i&&o>n&&(o=n),o},Hi=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},dJ=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},i=0;i<n;i++)if(!r[t[i]])r[t[i]]=!0;else return!0;return!1},Fr=function(t,n){return be(t)&&be(n)?function(r){return t+r*(n-t)}:function(){return n}};function gm(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):Tr(r,t))===n})}var hJ=function(t,n){return be(t)&&be(n)?t-n:Qo(t)&&Qo(n)?t.localeCompare(n):t instanceof Date&&n instanceof Date?t.getTime()-n.getTime():String(t).localeCompare(String(n))};function xl(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function fS(e){"@babel/helpers - typeof";return fS=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},fS(e)}var mJ=["viewBox","children"],pJ=["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","colorRendering","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"],eM=["points","pathLength"],Bx={svg:mJ,polygon:eM,polyline:eM},qO=["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","onDragCapture","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"],ym=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(w.isValidElement(t)&&(r=t.props),!fc(r))return null;var i={};return Object.keys(r).forEach(function(o){qO.includes(o)&&(i[o]=n||function(l){return r[o](r,l)})}),i},vJ=function(t,n,r){return function(i){return t(n,r,i),null}},bm=function(t,n,r){if(!fc(t)||fS(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(o){var l=t[o];qO.includes(o)&&typeof l=="function"&&(i||(i={}),i[o]=vJ(l,n,r))}),i},gJ=["children"],yJ=["children"];function tM(e,t){if(e==null)return{};var n=bJ(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function bJ(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}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)}var nM={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"},Wa=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},rM=null,qx=null,UO=function e(t){if(t===rM&&Array.isArray(qx))return qx;var n=[];return w.Children.forEach(t,function(r){Qe(r)||(iJ.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),qx=n,rM=t,n};function Mr(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(i){return Wa(i)}):r=[Wa(t)],UO(e).forEach(function(i){var o=Tr(i,"type.displayName")||Tr(i,"type.name");r.indexOf(o)!==-1&&n.push(i)}),n}function nr(e,t){var n=Mr(e,t);return n&&n[0]}var aM=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,i=n.height;return!(!be(r)||r<=0||!be(i)||i<=0)},xJ=["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"],wJ=function(t){return t&&t.type&&Qo(t.type)&&xJ.indexOf(t.type)>=0},SJ=function(t){return t&&dS(t)==="object"&&"clipDot"in t},jJ=function(t,n,r,i){var o,l=(o=Bx==null?void 0:Bx[i])!==null&&o!==void 0?o:[];return n.startsWith("data-")||!Ye(t)&&(i&&l.includes(n)||pJ.includes(n))||r&&qO.includes(n)},nt=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(w.isValidElement(t)&&(i=t.props),!fc(i))return null;var o={};return Object.keys(i).forEach(function(l){var u;jJ((u=i)===null||u===void 0?void 0:u[l],l,n,r)&&(o[l]=i[l])}),o},hS=function e(t,n){if(t===n)return!0;var r=w.Children.count(t);if(r!==w.Children.count(n))return!1;if(r===0)return!0;if(r===1)return iM(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i<r;i++){var o=t[i],l=n[i];if(Array.isArray(o)||Array.isArray(l)){if(!e(o,l))return!1}else if(!iM(o,l))return!1}return!0},iM=function(t,n){if(Qe(t)&&Qe(n))return!0;if(!Qe(t)&&!Qe(n)){var r=t.props||{},i=r.children,o=tM(r,gJ),l=n.props||{},u=l.children,d=tM(l,yJ);return i&&u?xl(o,d)&&hS(i,u):!i&&!u?xl(o,d):!1}return!1},oM=function(t,n){var r=[],i={};return UO(t).forEach(function(o,l){if(wJ(o))r.push(o);else if(o){var u=Wa(o.type),d=n[u]||{},h=d.handler,v=d.once;if(h&&(!v||!i[u])){var p=h(o,u,l);r.push(p),i[u]=!0}}}),r},OJ=function(t){var n=t&&t.type;return n&&nM[n]?nM[n]:null},_J=function(t,n){return UO(n).indexOf(t)},EJ=["children","width","height","viewBox","className","style","title","desc"];function mS(){return mS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mS.apply(this,arguments)}function AJ(e,t){if(e==null)return{};var n=NJ(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function NJ(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function pS(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,o=e.className,l=e.style,u=e.title,d=e.desc,h=AJ(e,EJ),v=i||{width:n,height:r,x:0,y:0},p=rt("recharts-surface",o);return I.createElement("svg",mS({},nt(h,!0,"svg"),{className:p,width:n,height:r,style:l,viewBox:"".concat(v.x," ").concat(v.y," ").concat(v.width," ").concat(v.height)}),I.createElement("title",null,u),I.createElement("desc",null,d),t)}var CJ=["children","className"];function vS(){return vS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vS.apply(this,arguments)}function TJ(e,t){if(e==null)return{};var n=MJ(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function MJ(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var zt=I.forwardRef(function(e,t){var n=e.children,r=e.className,i=TJ(e,CJ),o=rt("recharts-layer",r);return I.createElement("g",vS({className:o},nt(i,!0),{ref:t}),n)}),Ka=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o]},Ux,sM;function RJ(){if(sM)return Ux;sM=1;function e(t,n,r){var i=-1,o=t.length;n<0&&(n=-n>o?0:o+n),r=r>o?o:r,r<0&&(r+=o),o=n>r?0:r-n>>>0,n>>>=0;for(var l=Array(o);++i<o;)l[i]=t[i+n];return l}return Ux=e,Ux}var Hx,lM;function DJ(){if(lM)return Hx;lM=1;var e=RJ();function t(n,r,i){var o=n.length;return i=i===void 0?o:i,!r&&i>=o?n:e(n,r,i)}return Hx=t,Hx}var Fx,cM;function oL(){if(cM)return Fx;cM=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",l="\\u200d",u=RegExp("["+l+e+i+o+"]");function d(h){return u.test(h)}return Fx=d,Fx}var Gx,uM;function PJ(){if(uM)return Gx;uM=1;function e(t){return t.split("")}return Gx=e,Gx}var Vx,fM;function kJ(){if(fM)return Vx;fM=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",l="["+e+"]",u="["+i+"]",d="\\ud83c[\\udffb-\\udfff]",h="(?:"+u+"|"+d+")",v="[^"+e+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",b="\\u200d",O=h+"?",j="["+o+"]?",x="(?:"+b+"(?:"+[v,p,g].join("|")+")"+j+O+")*",_=j+O+x,A="(?:"+[v+u+"?",u,p,g,l].join("|")+")",E=RegExp(d+"(?="+d+")|"+A+_,"g");function C(N){return N.match(E)||[]}return Vx=C,Vx}var Yx,dM;function $J(){if(dM)return Yx;dM=1;var e=PJ(),t=oL(),n=kJ();function r(i){return t(i)?n(i):e(i)}return Yx=r,Yx}var Wx,hM;function IJ(){if(hM)return Wx;hM=1;var e=DJ(),t=oL(),n=$J(),r=nL();function i(o){return function(l){l=r(l);var u=t(l)?n(l):void 0,d=u?u[0]:l.charAt(0),h=u?e(u,1).join(""):l.slice(1);return d[o]()+h}}return Wx=i,Wx}var Kx,mM;function LJ(){if(mM)return Kx;mM=1;var e=IJ(),t=e("toUpperCase");return Kx=t,Kx}var zJ=LJ();const pv=bt(zJ);function St(e){return function(){return e}}const sL=Math.cos,xm=Math.sin,Zr=Math.sqrt,wm=Math.PI,vv=2*wm,gS=Math.PI,yS=2*gS,$o=1e-6,BJ=yS-$o;function lL(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function qJ(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return lL;const n=10**t;return function(r){this._+=r[0];for(let i=1,o=r.length;i<o;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class UJ{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?lL:qJ(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,o,l){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+l}`}arcTo(t,n,r,i,o){if(t=+t,n=+n,r=+r,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let l=this._x1,u=this._y1,d=r-t,h=i-n,v=l-t,p=u-n,g=v*v+p*p;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(g>$o)if(!(Math.abs(p*d-h*v)>$o)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let b=r-l,O=i-u,j=d*d+h*h,x=b*b+O*O,_=Math.sqrt(j),A=Math.sqrt(g),E=o*Math.tan((gS-Math.acos((j+g-x)/(2*_*A)))/2),C=E/A,N=E/_;Math.abs(C-1)>$o&&this._append`L${t+C*v},${n+C*p}`,this._append`A${o},${o},0,0,${+(p*b>v*O)},${this._x1=t+N*d},${this._y1=n+N*h}`}}arc(t,n,r,i,o,l){if(t=+t,n=+n,r=+r,l=!!l,r<0)throw new Error(`negative radius: ${r}`);let u=r*Math.cos(i),d=r*Math.sin(i),h=t+u,v=n+d,p=1^l,g=l?i-o:o-i;this._x1===null?this._append`M${h},${v}`:(Math.abs(this._x1-h)>$o||Math.abs(this._y1-v)>$o)&&this._append`L${h},${v}`,r&&(g<0&&(g=g%yS+yS),g>BJ?this._append`A${r},${r},0,1,${p},${t-u},${n-d}A${r},${r},0,1,${p},${this._x1=h},${this._y1=v}`:g>$o&&this._append`A${r},${r},0,${+(g>=gS)},${p},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function HO(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new UJ(t)}function FO(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function cL(e){this._context=e}cL.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 gv(e){return new cL(e)}function uL(e){return e[0]}function fL(e){return e[1]}function dL(e,t){var n=St(!0),r=null,i=gv,o=null,l=HO(u);e=typeof e=="function"?e:e===void 0?uL:St(e),t=typeof t=="function"?t:t===void 0?fL:St(t);function u(d){var h,v=(d=FO(d)).length,p,g=!1,b;for(r==null&&(o=i(b=l())),h=0;h<=v;++h)!(h<v&&n(p=d[h],h,d))===g&&((g=!g)?o.lineStart():o.lineEnd()),g&&o.point(+e(p,h,d),+t(p,h,d));if(b)return o=null,b+""||null}return u.x=function(d){return arguments.length?(e=typeof d=="function"?d:St(+d),u):e},u.y=function(d){return arguments.length?(t=typeof d=="function"?d:St(+d),u):t},u.defined=function(d){return arguments.length?(n=typeof d=="function"?d:St(!!d),u):n},u.curve=function(d){return arguments.length?(i=d,r!=null&&(o=i(r)),u):i},u.context=function(d){return arguments.length?(d==null?r=o=null:o=i(r=d),u):r},u}function Eh(e,t,n){var r=null,i=St(!0),o=null,l=gv,u=null,d=HO(h);e=typeof e=="function"?e:e===void 0?uL:St(+e),t=typeof t=="function"?t:St(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?fL:St(+n);function h(p){var g,b,O,j=(p=FO(p)).length,x,_=!1,A,E=new Array(j),C=new Array(j);for(o==null&&(u=l(A=d())),g=0;g<=j;++g){if(!(g<j&&i(x=p[g],g,p))===_)if(_=!_)b=g,u.areaStart(),u.lineStart();else{for(u.lineEnd(),u.lineStart(),O=g-1;O>=b;--O)u.point(E[O],C[O]);u.lineEnd(),u.areaEnd()}_&&(E[g]=+e(x,g,p),C[g]=+t(x,g,p),u.point(r?+r(x,g,p):E[g],n?+n(x,g,p):C[g]))}if(A)return u=null,A+""||null}function v(){return dL().defined(i).curve(l).context(o)}return h.x=function(p){return arguments.length?(e=typeof p=="function"?p:St(+p),r=null,h):e},h.x0=function(p){return arguments.length?(e=typeof p=="function"?p:St(+p),h):e},h.x1=function(p){return arguments.length?(r=p==null?null:typeof p=="function"?p:St(+p),h):r},h.y=function(p){return arguments.length?(t=typeof p=="function"?p:St(+p),n=null,h):t},h.y0=function(p){return arguments.length?(t=typeof p=="function"?p:St(+p),h):t},h.y1=function(p){return arguments.length?(n=p==null?null:typeof p=="function"?p:St(+p),h):n},h.lineX0=h.lineY0=function(){return v().x(e).y(t)},h.lineY1=function(){return v().x(e).y(n)},h.lineX1=function(){return v().x(r).y(t)},h.defined=function(p){return arguments.length?(i=typeof p=="function"?p:St(!!p),h):i},h.curve=function(p){return arguments.length?(l=p,o!=null&&(u=l(o)),h):l},h.context=function(p){return arguments.length?(p==null?o=u=null:u=l(o=p),h):o},h}class hL{constructor(t,n){this._context=t,this._x=n}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,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function HJ(e){return new hL(e,!0)}function FJ(e){return new hL(e,!1)}const GO={draw(e,t){const n=Zr(t/wm);e.moveTo(n,0),e.arc(0,0,n,0,vv)}},GJ={draw(e,t){const n=Zr(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},mL=Zr(1/3),VJ=mL*2,YJ={draw(e,t){const n=Zr(t/VJ),r=n*mL;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},WJ={draw(e,t){const n=Zr(t),r=-n/2;e.rect(r,r,n,n)}},KJ=.8908130915292852,pL=xm(wm/10)/xm(7*wm/10),XJ=xm(vv/10)*pL,QJ=-sL(vv/10)*pL,ZJ={draw(e,t){const n=Zr(t*KJ),r=XJ*n,i=QJ*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const l=vv*o/5,u=sL(l),d=xm(l);e.lineTo(d*n,-u*n),e.lineTo(u*r-d*i,d*r+u*i)}e.closePath()}},Xx=Zr(3),JJ={draw(e,t){const n=-Zr(t/(Xx*3));e.moveTo(0,n*2),e.lineTo(-Xx*n,-n),e.lineTo(Xx*n,-n),e.closePath()}},Sr=-.5,jr=Zr(3)/2,bS=1/Zr(12),eee=(bS/2+1)*3,tee={draw(e,t){const n=Zr(t/eee),r=n/2,i=n*bS,o=r,l=n*bS+n,u=-o,d=l;e.moveTo(r,i),e.lineTo(o,l),e.lineTo(u,d),e.lineTo(Sr*r-jr*i,jr*r+Sr*i),e.lineTo(Sr*o-jr*l,jr*o+Sr*l),e.lineTo(Sr*u-jr*d,jr*u+Sr*d),e.lineTo(Sr*r+jr*i,Sr*i-jr*r),e.lineTo(Sr*o+jr*l,Sr*l-jr*o),e.lineTo(Sr*u+jr*d,Sr*d-jr*u),e.closePath()}};function nee(e,t){let n=null,r=HO(i);e=typeof e=="function"?e:St(e||GO),t=typeof t=="function"?t:St(t===void 0?64:+t);function i(){let o;if(n||(n=o=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:St(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:St(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function Sm(){}function jm(e,t,n){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+n)/6)}function vL(e){this._context=e}vL.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:jm(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:jm(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ree(e){return new vL(e)}function gL(e){this._context=e}gL.prototype={areaStart:Sm,areaEnd:Sm,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:jm(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function aee(e){return new gL(e)}function yL(e){this._context=e}yL.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 n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:jm(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function iee(e){return new yL(e)}function bL(e){this._context=e}bL.prototype={areaStart:Sm,areaEnd:Sm,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 oee(e){return new bL(e)}function pM(e){return e<0?-1:1}function vM(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),l=(n-e._y1)/(i||r<0&&-0),u=(o*i+l*r)/(r+i);return(pM(o)+pM(l))*Math.min(Math.abs(o),Math.abs(l),.5*Math.abs(u))||0}function gM(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function Qx(e,t,n){var r=e._x0,i=e._y0,o=e._x1,l=e._y1,u=(o-r)/3;e._context.bezierCurveTo(r+u,i+u*t,o-u,l-u*n,o,l)}function Om(e){this._context=e}Om.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:Qx(this,this._t0,gM(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 n=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,Qx(this,gM(this,n=vM(this,e,t)),n);break;default:Qx(this,this._t0,n=vM(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function xL(e){this._context=new wL(e)}(xL.prototype=Object.create(Om.prototype)).point=function(e,t){Om.prototype.point.call(this,t,e)};function wL(e){this._context=e}wL.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,n,r,i,o){this._context.bezierCurveTo(t,e,r,n,o,i)}};function see(e){return new Om(e)}function lee(e){return new xL(e)}function SL(e){this._context=e}SL.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,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=yM(e),i=yM(t),o=0,l=1;l<n;++o,++l)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],e[l],t[l]);(this._line||this._line!==0&&n===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 yM(e){var t,n=e.length-1,r,i=new Array(n),o=new Array(n),l=new Array(n);for(i[0]=0,o[0]=2,l[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,l[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,l[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,l[t]-=r*l[t-1];for(i[n-1]=l[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(l[t]-i[t+1])/o[t];for(o[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)o[t]=2*e[t+1]-i[t+1];return[i,o]}function cee(e){return new SL(e)}function yv(e,t){this._context=e,this._t=t}yv.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;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function uee(e){return new yv(e,.5)}function fee(e){return new yv(e,0)}function dee(e){return new yv(e,1)}function Al(e,t){if((l=e.length)>1)for(var n=1,r,i,o=e[t[0]],l,u=o.length;n<l;++n)for(i=o,o=e[t[n]],r=0;r<u;++r)o[r][1]+=o[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function xS(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function hee(e,t){return e[t]}function mee(e){const t=[];return t.key=e,t}function pee(){var e=St([]),t=xS,n=Al,r=hee;function i(o){var l=Array.from(e.apply(this,arguments),mee),u,d=l.length,h=-1,v;for(const p of o)for(u=0,++h;u<d;++u)(l[u][h]=[0,+r(p,l[u].key,h,o)]).data=p;for(u=0,v=FO(t(l));u<d;++u)l[v[u]].index=u;return n(l,v),l}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:St(Array.from(o)),i):e},i.value=function(o){return arguments.length?(r=typeof o=="function"?o:St(+o),i):r},i.order=function(o){return arguments.length?(t=o==null?xS:typeof o=="function"?o:St(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(n=o??Al,i):n},i}function vee(e,t){if((r=e.length)>0){for(var n,r,i=0,o=e[0].length,l;i<o;++i){for(l=n=0;n<r;++n)l+=e[n][i][1]||0;if(l)for(n=0;n<r;++n)e[n][i][1]/=l}Al(e,t)}}function gee(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,o=r.length;n<o;++n){for(var l=0,u=0;l<i;++l)u+=e[l][n][1]||0;r[n][1]+=r[n][0]=-u/2}Al(e,t)}}function yee(e,t){if(!(!((l=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,l;r<o;++r){for(var u=0,d=0,h=0;u<l;++u){for(var v=e[t[u]],p=v[r][1]||0,g=v[r-1][1]||0,b=(p-g)/2,O=0;O<u;++O){var j=e[t[O]],x=j[r][1]||0,_=j[r-1][1]||0;b+=x-_}d+=p,h+=b*p}i[r-1][1]+=i[r-1][0]=n,d&&(n-=h/d)}i[r-1][1]+=i[r-1][0]=n,Al(e,t)}}function Xu(e){"@babel/helpers - typeof";return Xu=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},Xu(e)}var bee=["type","size","sizeType"];function wS(){return wS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wS.apply(this,arguments)}function bM(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function xM(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?bM(Object(n),!0).forEach(function(r){xee(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bM(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function xee(e,t,n){return t=wee(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wee(e){var t=See(e,"string");return Xu(t)=="symbol"?t:t+""}function See(e,t){if(Xu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Xu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function jee(e,t){if(e==null)return{};var n=Oee(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Oee(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var jL={symbolCircle:GO,symbolCross:GJ,symbolDiamond:YJ,symbolSquare:WJ,symbolStar:ZJ,symbolTriangle:JJ,symbolWye:tee},_ee=Math.PI/180,Eee=function(t){var n="symbol".concat(pv(t));return jL[n]||GO},Aee=function(t,n,r){if(n==="area")return t;switch(r){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*_ee;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}},Nee=function(t,n){jL["symbol".concat(pv(t))]=n},VO=function(t){var n=t.type,r=n===void 0?"circle":n,i=t.size,o=i===void 0?64:i,l=t.sizeType,u=l===void 0?"area":l,d=jee(t,bee),h=xM(xM({},d),{},{type:r,size:o,sizeType:u}),v=function(){var x=Eee(r),_=nee().type(x).size(Aee(o,u,r));return _()},p=h.className,g=h.cx,b=h.cy,O=nt(h,!0);return g===+g&&b===+b&&o===+o?I.createElement("path",wS({},O,{className:rt("recharts-symbols",p),transform:"translate(".concat(g,", ").concat(b,")"),d:v()})):null};VO.registerSymbol=Nee;function Nl(e){"@babel/helpers - typeof";return Nl=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},Nl(e)}function SS(){return SS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},SS.apply(this,arguments)}function wM(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Cee(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wM(Object(n),!0).forEach(function(r){Qu(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wM(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tee(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Mee(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,_L(r.key),r)}}function Ree(e,t,n){return t&&Mee(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Dee(e,t,n){return t=_m(t),Pee(e,OL()?Reflect.construct(t,n||[],_m(e).constructor):t.apply(e,n))}function Pee(e,t){if(t&&(Nl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return kee(e)}function kee(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function OL(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(OL=function(){return!!e})()}function _m(e){return _m=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},_m(e)}function $ee(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&&jS(e,t)}function jS(e,t){return jS=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},jS(e,t)}function Qu(e,t,n){return t=_L(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _L(e){var t=Iee(e,"string");return Nl(t)=="symbol"?t:t+""}function Iee(e,t){if(Nl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Nl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Or=32,YO=(function(e){function t(){return Tee(this,t),Dee(this,t,arguments)}return $ee(t,e),Ree(t,[{key:"renderIcon",value:function(r){var i=this.props.inactiveColor,o=Or/2,l=Or/6,u=Or/3,d=r.inactive?i:r.color;if(r.type==="plainline")return I.createElement("line",{strokeWidth:4,fill:"none",stroke:d,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:o,x2:Or,y2:o,className:"recharts-legend-icon"});if(r.type==="line")return I.createElement("path",{strokeWidth:4,fill:"none",stroke:d,d:"M0,".concat(o,"h").concat(u,`
401
+ A`).concat(l,",").concat(l,",0,1,1,").concat(2*u,",").concat(o,`
402
+ H`).concat(Or,"M").concat(2*u,",").concat(o,`
403
+ A`).concat(l,",").concat(l,",0,1,1,").concat(u,",").concat(o),className:"recharts-legend-icon"});if(r.type==="rect")return I.createElement("path",{stroke:"none",fill:d,d:"M0,".concat(Or/8,"h").concat(Or,"v").concat(Or*3/4,"h").concat(-Or,"z"),className:"recharts-legend-icon"});if(I.isValidElement(r.legendIcon)){var h=Cee({},r);return delete h.legendIcon,I.cloneElement(r.legendIcon,h)}return I.createElement(VO,{fill:d,cx:o,cy:o,size:Or,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,i=this.props,o=i.payload,l=i.iconSize,u=i.layout,d=i.formatter,h=i.inactiveColor,v={x:0,y:0,width:Or,height:Or},p={display:u==="horizontal"?"inline-block":"block",marginRight:10},g={display:"inline-block",verticalAlign:"middle",marginRight:4};return o.map(function(b,O){var j=b.formatter||d,x=rt(Qu(Qu({"recharts-legend-item":!0},"legend-item-".concat(O),!0),"inactive",b.inactive));if(b.type==="none")return null;var _=Ye(b.value)?null:b.value;Ka(!Ye(b.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 A=b.inactive?h:b.color;return I.createElement("li",SS({className:x,style:p,key:"legend-item-".concat(O)},bm(r.props,b,O)),I.createElement(pS,{width:l,height:l,viewBox:v,style:g},r.renderIcon(b)),I.createElement("span",{className:"recharts-legend-item-text",style:{color:A}},j?j(_,b,O):_))})}},{key:"render",value:function(){var r=this.props,i=r.payload,o=r.layout,l=r.align;if(!i||!i.length)return null;var u={padding:0,margin:0,textAlign:o==="horizontal"?l:"left"};return I.createElement("ul",{className:"recharts-default-legend",style:u},this.renderItems())}}])})(w.PureComponent);Qu(YO,"displayName","Legend");Qu(YO,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var Zx,SM;function Lee(){if(SM)return Zx;SM=1;var e=dv();function t(){this.__data__=new e,this.size=0}return Zx=t,Zx}var Jx,jM;function zee(){if(jM)return Jx;jM=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return Jx=e,Jx}var e0,OM;function Bee(){if(OM)return e0;OM=1;function e(t){return this.__data__.get(t)}return e0=e,e0}var t0,_M;function qee(){if(_M)return t0;_M=1;function e(t){return this.__data__.has(t)}return t0=e,t0}var n0,EM;function Uee(){if(EM)return n0;EM=1;var e=dv(),t=IO(),n=LO(),r=200;function i(o,l){var u=this.__data__;if(u instanceof e){var d=u.__data__;if(!t||d.length<r-1)return d.push([o,l]),this.size=++u.size,this;u=this.__data__=new n(d)}return u.set(o,l),this.size=u.size,this}return n0=i,n0}var r0,AM;function EL(){if(AM)return r0;AM=1;var e=dv(),t=Lee(),n=zee(),r=Bee(),i=qee(),o=Uee();function l(u){var d=this.__data__=new e(u);this.size=d.size}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=r,l.prototype.has=i,l.prototype.set=o,r0=l,r0}var a0,NM;function Hee(){if(NM)return a0;NM=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return a0=t,a0}var i0,CM;function Fee(){if(CM)return i0;CM=1;function e(t){return this.__data__.has(t)}return i0=e,i0}var o0,TM;function AL(){if(TM)return o0;TM=1;var e=LO(),t=Hee(),n=Fee();function r(i){var o=-1,l=i==null?0:i.length;for(this.__data__=new e;++o<l;)this.add(i[o])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,o0=r,o0}var s0,MM;function NL(){if(MM)return s0;MM=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(n(t[r],r,t))return!0;return!1}return s0=e,s0}var l0,RM;function CL(){if(RM)return l0;RM=1;function e(t,n){return t.has(n)}return l0=e,l0}var c0,DM;function TL(){if(DM)return c0;DM=1;var e=AL(),t=NL(),n=CL(),r=1,i=2;function o(l,u,d,h,v,p){var g=d&r,b=l.length,O=u.length;if(b!=O&&!(g&&O>b))return!1;var j=p.get(l),x=p.get(u);if(j&&x)return j==u&&x==l;var _=-1,A=!0,E=d&i?new e:void 0;for(p.set(l,u),p.set(u,l);++_<b;){var C=l[_],N=u[_];if(h)var M=g?h(N,C,_,u,l,p):h(C,N,_,l,u,p);if(M!==void 0){if(M)continue;A=!1;break}if(E){if(!t(u,function(R,D){if(!n(E,D)&&(C===R||v(C,R,d,h,p)))return E.push(D)})){A=!1;break}}else if(!(C===N||v(C,N,d,h,p))){A=!1;break}}return p.delete(l),p.delete(u),A}return c0=o,c0}var u0,PM;function Gee(){if(PM)return u0;PM=1;var e=wa(),t=e.Uint8Array;return u0=t,u0}var f0,kM;function Vee(){if(kM)return f0;kM=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,o){r[++n]=[o,i]}),r}return f0=e,f0}var d0,$M;function WO(){if($M)return d0;$M=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return d0=e,d0}var h0,IM;function Yee(){if(IM)return h0;IM=1;var e=Gf(),t=Gee(),n=$O(),r=TL(),i=Vee(),o=WO(),l=1,u=2,d="[object Boolean]",h="[object Date]",v="[object Error]",p="[object Map]",g="[object Number]",b="[object RegExp]",O="[object Set]",j="[object String]",x="[object Symbol]",_="[object ArrayBuffer]",A="[object DataView]",E=e?e.prototype:void 0,C=E?E.valueOf:void 0;function N(M,R,D,z,Y,L,F){switch(D){case A:if(M.byteLength!=R.byteLength||M.byteOffset!=R.byteOffset)return!1;M=M.buffer,R=R.buffer;case _:return!(M.byteLength!=R.byteLength||!L(new t(M),new t(R)));case d:case h:case g:return n(+M,+R);case v:return M.name==R.name&&M.message==R.message;case b:case j:return M==R+"";case p:var W=i;case O:var Q=z&l;if(W||(W=o),M.size!=R.size&&!Q)return!1;var X=F.get(M);if(X)return X==R;z|=u,F.set(M,R);var k=r(W(M),W(R),z,Y,L,F);return F.delete(M),k;case x:if(C)return C.call(M)==C.call(R)}return!1}return h0=N,h0}var m0,LM;function ML(){if(LM)return m0;LM=1;function e(t,n){for(var r=-1,i=n.length,o=t.length;++r<i;)t[o+r]=n[r];return t}return m0=e,m0}var p0,zM;function Wee(){if(zM)return p0;zM=1;var e=ML(),t=Fn();function n(r,i,o){var l=i(r);return t(r)?l:e(l,o(r))}return p0=n,p0}var v0,BM;function Kee(){if(BM)return v0;BM=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=0,l=[];++r<i;){var u=t[r];n(u,r,t)&&(l[o++]=u)}return l}return v0=e,v0}var g0,qM;function Xee(){if(qM)return g0;qM=1;function e(){return[]}return g0=e,g0}var y0,UM;function Qee(){if(UM)return y0;UM=1;var e=Kee(),t=Xee(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(l){return l==null?[]:(l=Object(l),e(i(l),function(u){return r.call(l,u)}))}:t;return y0=o,y0}var b0,HM;function Zee(){if(HM)return b0;HM=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return b0=e,b0}var x0,FM;function Jee(){if(FM)return x0;FM=1;var e=li(),t=ci(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return x0=r,x0}var w0,GM;function KO(){if(GM)return w0;GM=1;var e=Jee(),t=ci(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(l){return t(l)&&r.call(l,"callee")&&!i.call(l,"callee")};return w0=o,w0}var Tu={exports:{}},S0,VM;function ete(){if(VM)return S0;VM=1;function e(){return!1}return S0=e,S0}Tu.exports;var YM;function RL(){return YM||(YM=1,(function(e,t){var n=wa(),r=ete(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,l=o&&o.exports===i,u=l?n.Buffer:void 0,d=u?u.isBuffer:void 0,h=d||r;e.exports=h})(Tu,Tu.exports)),Tu.exports}var j0,WM;function XO(){if(WM)return j0;WM=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var o=typeof r;return i=i??e,!!i&&(o=="number"||o!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return j0=n,j0}var O0,KM;function QO(){if(KM)return O0;KM=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return O0=t,O0}var _0,XM;function tte(){if(XM)return _0;XM=1;var e=li(),t=QO(),n=ci(),r="[object Arguments]",i="[object Array]",o="[object Boolean]",l="[object Date]",u="[object Error]",d="[object Function]",h="[object Map]",v="[object Number]",p="[object Object]",g="[object RegExp]",b="[object Set]",O="[object String]",j="[object WeakMap]",x="[object ArrayBuffer]",_="[object DataView]",A="[object Float32Array]",E="[object Float64Array]",C="[object Int8Array]",N="[object Int16Array]",M="[object Int32Array]",R="[object Uint8Array]",D="[object Uint8ClampedArray]",z="[object Uint16Array]",Y="[object Uint32Array]",L={};L[A]=L[E]=L[C]=L[N]=L[M]=L[R]=L[D]=L[z]=L[Y]=!0,L[r]=L[i]=L[x]=L[o]=L[_]=L[l]=L[u]=L[d]=L[h]=L[v]=L[p]=L[g]=L[b]=L[O]=L[j]=!1;function F(W){return n(W)&&t(W.length)&&!!L[e(W)]}return _0=F,_0}var E0,QM;function DL(){if(QM)return E0;QM=1;function e(t){return function(n){return t(n)}}return E0=e,E0}var Mu={exports:{}};Mu.exports;var ZM;function nte(){return ZM||(ZM=1,(function(e,t){var n=J5(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,l=o&&n.process,u=(function(){try{var d=i&&i.require&&i.require("util").types;return d||l&&l.binding&&l.binding("util")}catch{}})();e.exports=u})(Mu,Mu.exports)),Mu.exports}var A0,JM;function PL(){if(JM)return A0;JM=1;var e=tte(),t=DL(),n=nte(),r=n&&n.isTypedArray,i=r?t(r):e;return A0=i,A0}var N0,eR;function rte(){if(eR)return N0;eR=1;var e=Zee(),t=KO(),n=Fn(),r=RL(),i=XO(),o=PL(),l=Object.prototype,u=l.hasOwnProperty;function d(h,v){var p=n(h),g=!p&&t(h),b=!p&&!g&&r(h),O=!p&&!g&&!b&&o(h),j=p||g||b||O,x=j?e(h.length,String):[],_=x.length;for(var A in h)(v||u.call(h,A))&&!(j&&(A=="length"||b&&(A=="offset"||A=="parent")||O&&(A=="buffer"||A=="byteLength"||A=="byteOffset")||i(A,_)))&&x.push(A);return x}return N0=d,N0}var C0,tR;function ate(){if(tR)return C0;tR=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return C0=t,C0}var T0,nR;function kL(){if(nR)return T0;nR=1;function e(t,n){return function(r){return t(n(r))}}return T0=e,T0}var M0,rR;function ite(){if(rR)return M0;rR=1;var e=kL(),t=e(Object.keys,Object);return M0=t,M0}var R0,aR;function ote(){if(aR)return R0;aR=1;var e=ate(),t=ite(),n=Object.prototype,r=n.hasOwnProperty;function i(o){if(!e(o))return t(o);var l=[];for(var u in Object(o))r.call(o,u)&&u!="constructor"&&l.push(u);return l}return R0=i,R0}var D0,iR;function Wf(){if(iR)return D0;iR=1;var e=kO(),t=QO();function n(r){return r!=null&&t(r.length)&&!e(r)}return D0=n,D0}var P0,oR;function bv(){if(oR)return P0;oR=1;var e=rte(),t=ote(),n=Wf();function r(i){return n(i)?e(i):t(i)}return P0=r,P0}var k0,sR;function ste(){if(sR)return k0;sR=1;var e=Wee(),t=Qee(),n=bv();function r(i){return e(i,n,t)}return k0=r,k0}var $0,lR;function lte(){if(lR)return $0;lR=1;var e=ste(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(o,l,u,d,h,v){var p=u&t,g=e(o),b=g.length,O=e(l),j=O.length;if(b!=j&&!p)return!1;for(var x=b;x--;){var _=g[x];if(!(p?_ in l:r.call(l,_)))return!1}var A=v.get(o),E=v.get(l);if(A&&E)return A==l&&E==o;var C=!0;v.set(o,l),v.set(l,o);for(var N=p;++x<b;){_=g[x];var M=o[_],R=l[_];if(d)var D=p?d(R,M,_,l,o,v):d(M,R,_,o,l,v);if(!(D===void 0?M===R||h(M,R,u,d,v):D)){C=!1;break}N||(N=_=="constructor")}if(C&&!N){var z=o.constructor,Y=l.constructor;z!=Y&&"constructor"in o&&"constructor"in l&&!(typeof z=="function"&&z instanceof z&&typeof Y=="function"&&Y instanceof Y)&&(C=!1)}return v.delete(o),v.delete(l),C}return $0=i,$0}var I0,cR;function cte(){if(cR)return I0;cR=1;var e=cs(),t=wa(),n=e(t,"DataView");return I0=n,I0}var L0,uR;function ute(){if(uR)return L0;uR=1;var e=cs(),t=wa(),n=e(t,"Promise");return L0=n,L0}var z0,fR;function $L(){if(fR)return z0;fR=1;var e=cs(),t=wa(),n=e(t,"Set");return z0=n,z0}var B0,dR;function fte(){if(dR)return B0;dR=1;var e=cs(),t=wa(),n=e(t,"WeakMap");return B0=n,B0}var q0,hR;function dte(){if(hR)return q0;hR=1;var e=cte(),t=IO(),n=ute(),r=$L(),i=fte(),o=li(),l=eL(),u="[object Map]",d="[object Object]",h="[object Promise]",v="[object Set]",p="[object WeakMap]",g="[object DataView]",b=l(e),O=l(t),j=l(n),x=l(r),_=l(i),A=o;return(e&&A(new e(new ArrayBuffer(1)))!=g||t&&A(new t)!=u||n&&A(n.resolve())!=h||r&&A(new r)!=v||i&&A(new i)!=p)&&(A=function(E){var C=o(E),N=C==d?E.constructor:void 0,M=N?l(N):"";if(M)switch(M){case b:return g;case O:return u;case j:return h;case x:return v;case _:return p}return C}),q0=A,q0}var U0,mR;function hte(){if(mR)return U0;mR=1;var e=EL(),t=TL(),n=Yee(),r=lte(),i=dte(),o=Fn(),l=RL(),u=PL(),d=1,h="[object Arguments]",v="[object Array]",p="[object Object]",g=Object.prototype,b=g.hasOwnProperty;function O(j,x,_,A,E,C){var N=o(j),M=o(x),R=N?v:i(j),D=M?v:i(x);R=R==h?p:R,D=D==h?p:D;var z=R==p,Y=D==p,L=R==D;if(L&&l(j)){if(!l(x))return!1;N=!0,z=!1}if(L&&!z)return C||(C=new e),N||u(j)?t(j,x,_,A,E,C):n(j,x,R,_,A,E,C);if(!(_&d)){var F=z&&b.call(j,"__wrapped__"),W=Y&&b.call(x,"__wrapped__");if(F||W){var Q=F?j.value():j,X=W?x.value():x;return C||(C=new e),E(Q,X,_,A,C)}}return L?(C||(C=new e),r(j,x,_,A,E,C)):!1}return U0=O,U0}var H0,pR;function ZO(){if(pR)return H0;pR=1;var e=hte(),t=ci();function n(r,i,o,l,u){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,o,l,n,u)}return H0=n,H0}var F0,vR;function mte(){if(vR)return F0;vR=1;var e=EL(),t=ZO(),n=1,r=2;function i(o,l,u,d){var h=u.length,v=h,p=!d;if(o==null)return!v;for(o=Object(o);h--;){var g=u[h];if(p&&g[2]?g[1]!==o[g[0]]:!(g[0]in o))return!1}for(;++h<v;){g=u[h];var b=g[0],O=o[b],j=g[1];if(p&&g[2]){if(O===void 0&&!(b in o))return!1}else{var x=new e;if(d)var _=d(O,j,b,o,l,x);if(!(_===void 0?t(j,O,n|r,d,x):_))return!1}}return!0}return F0=i,F0}var G0,gR;function IL(){if(gR)return G0;gR=1;var e=ao();function t(n){return n===n&&!e(n)}return G0=t,G0}var V0,yR;function pte(){if(yR)return V0;yR=1;var e=IL(),t=bv();function n(r){for(var i=t(r),o=i.length;o--;){var l=i[o],u=r[l];i[o]=[l,u,e(u)]}return i}return V0=n,V0}var Y0,bR;function LL(){if(bR)return Y0;bR=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return Y0=e,Y0}var W0,xR;function vte(){if(xR)return W0;xR=1;var e=mte(),t=pte(),n=LL();function r(i){var o=t(i);return o.length==1&&o[0][2]?n(o[0][0],o[0][1]):function(l){return l===i||e(l,i,o)}}return W0=r,W0}var K0,wR;function gte(){if(wR)return K0;wR=1;function e(t,n){return t!=null&&n in Object(t)}return K0=e,K0}var X0,SR;function yte(){if(SR)return X0;SR=1;var e=rL(),t=KO(),n=Fn(),r=XO(),i=QO(),o=mv();function l(u,d,h){d=e(d,u);for(var v=-1,p=d.length,g=!1;++v<p;){var b=o(d[v]);if(!(g=u!=null&&h(u,b)))break;u=u[b]}return g||++v!=p?g:(p=u==null?0:u.length,!!p&&i(p)&&r(b,p)&&(n(u)||t(u)))}return X0=l,X0}var Q0,jR;function bte(){if(jR)return Q0;jR=1;var e=gte(),t=yte();function n(r,i){return r!=null&&t(r,i,e)}return Q0=n,Q0}var Z0,OR;function xte(){if(OR)return Z0;OR=1;var e=ZO(),t=aL(),n=bte(),r=PO(),i=IL(),o=LL(),l=mv(),u=1,d=2;function h(v,p){return r(v)&&i(p)?o(l(v),p):function(g){var b=t(g,v);return b===void 0&&b===p?n(g,v):e(p,b,u|d)}}return Z0=h,Z0}var J0,_R;function dc(){if(_R)return J0;_R=1;function e(t){return t}return J0=e,J0}var ew,ER;function wte(){if(ER)return ew;ER=1;function e(t){return function(n){return n==null?void 0:n[t]}}return ew=e,ew}var tw,AR;function Ste(){if(AR)return tw;AR=1;var e=BO();function t(n){return function(r){return e(r,n)}}return tw=t,tw}var nw,NR;function jte(){if(NR)return nw;NR=1;var e=wte(),t=Ste(),n=PO(),r=mv();function i(o){return n(o)?e(r(o)):t(o)}return nw=i,nw}var rw,CR;function io(){if(CR)return rw;CR=1;var e=vte(),t=xte(),n=dc(),r=Fn(),i=jte();function o(l){return typeof l=="function"?l:l==null?n:typeof l=="object"?r(l)?t(l[0],l[1]):e(l):i(l)}return rw=o,rw}var aw,TR;function zL(){if(TR)return aw;TR=1;function e(t,n,r,i){for(var o=t.length,l=r+(i?1:-1);i?l--:++l<o;)if(n(t[l],l,t))return l;return-1}return aw=e,aw}var iw,MR;function Ote(){if(MR)return iw;MR=1;function e(t){return t!==t}return iw=e,iw}var ow,RR;function _te(){if(RR)return ow;RR=1;function e(t,n,r){for(var i=r-1,o=t.length;++i<o;)if(t[i]===n)return i;return-1}return ow=e,ow}var sw,DR;function Ete(){if(DR)return sw;DR=1;var e=zL(),t=Ote(),n=_te();function r(i,o,l){return o===o?n(i,o,l):e(i,t,l)}return sw=r,sw}var lw,PR;function Ate(){if(PR)return lw;PR=1;var e=Ete();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return lw=t,lw}var cw,kR;function Nte(){if(kR)return cw;kR=1;function e(t,n,r){for(var i=-1,o=t==null?0:t.length;++i<o;)if(r(n,t[i]))return!0;return!1}return cw=e,cw}var uw,$R;function Cte(){if($R)return uw;$R=1;function e(){}return uw=e,uw}var fw,IR;function Tte(){if(IR)return fw;IR=1;var e=$L(),t=Cte(),n=WO(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(o){return new e(o)}:t;return fw=i,fw}var dw,LR;function Mte(){if(LR)return dw;LR=1;var e=AL(),t=Ate(),n=Nte(),r=CL(),i=Tte(),o=WO(),l=200;function u(d,h,v){var p=-1,g=t,b=d.length,O=!0,j=[],x=j;if(v)O=!1,g=n;else if(b>=l){var _=h?null:i(d);if(_)return o(_);O=!1,g=r,x=new e}else x=h?[]:j;e:for(;++p<b;){var A=d[p],E=h?h(A):A;if(A=v||A!==0?A:0,O&&E===E){for(var C=x.length;C--;)if(x[C]===E)continue e;h&&x.push(E),j.push(A)}else g(x,E,v)||(x!==j&&x.push(E),j.push(A))}return j}return dw=u,dw}var hw,zR;function Rte(){if(zR)return hw;zR=1;var e=io(),t=Mte();function n(r,i){return r&&r.length?t(r,e(i,2)):[]}return hw=n,hw}var Dte=Rte();const BR=bt(Dte);function BL(e,t,n){return t===!0?BR(e,n):Ye(t)?BR(e,t):e}function Cl(e){"@babel/helpers - typeof";return Cl=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},Cl(e)}var Pte=["ref"];function qR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ua(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?qR(Object(n),!0).forEach(function(r){xv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function kte(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function UR(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,UL(r.key),r)}}function $te(e,t,n){return t&&UR(e.prototype,t),n&&UR(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ite(e,t,n){return t=Em(t),Lte(e,qL()?Reflect.construct(t,n||[],Em(e).constructor):t.apply(e,n))}function Lte(e,t){if(t&&(Cl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zte(e)}function zte(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function qL(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(qL=function(){return!!e})()}function Em(e){return Em=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Em(e)}function Bte(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&&OS(e,t)}function OS(e,t){return OS=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},OS(e,t)}function xv(e,t,n){return t=UL(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function UL(e){var t=qte(e,"string");return Cl(t)=="symbol"?t:t+""}function qte(e,t){if(Cl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Cl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Ute(e,t){if(e==null)return{};var n=Hte(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Hte(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Fte(e){return e.value}function Gte(e,t){if(I.isValidElement(e))return I.cloneElement(e,t);if(typeof e=="function")return I.createElement(e,t);t.ref;var n=Ute(t,Pte);return I.createElement(YO,n)}var HR=1,Xa=(function(e){function t(){var n;kte(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=Ite(this,t,[].concat(i)),xv(n,"lastBoundingBox",{width:-1,height:-1}),n}return Bte(t,e),$te(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();return r.height=this.wrapperNode.offsetHeight,r.width=this.wrapperNode.offsetWidth,r}return null}},{key:"updateBBox",value:function(){var r=this.props.onBBoxUpdate,i=this.getBBox();i?(Math.abs(i.width-this.lastBoundingBox.width)>HR||Math.abs(i.height-this.lastBoundingBox.height)>HR)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,r&&r(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,r&&r(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?Ua({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var i=this.props,o=i.layout,l=i.align,u=i.verticalAlign,d=i.margin,h=i.chartWidth,v=i.chartHeight,p,g;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(l==="center"&&o==="vertical"){var b=this.getBBoxSnapshot();p={left:((h||0)-b.width)/2}}else p=l==="right"?{right:d&&d.right||0}:{left:d&&d.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(u==="middle"){var O=this.getBBoxSnapshot();g={top:((v||0)-O.height)/2}}else g=u==="bottom"?{bottom:d&&d.bottom||0}:{top:d&&d.top||0};return Ua(Ua({},p),g)}},{key:"render",value:function(){var r=this,i=this.props,o=i.content,l=i.width,u=i.height,d=i.wrapperStyle,h=i.payloadUniqBy,v=i.payload,p=Ua(Ua({position:"absolute",width:l||"auto",height:u||"auto"},this.getDefaultPosition(d)),d);return I.createElement("div",{className:"recharts-legend-wrapper",style:p,ref:function(b){r.wrapperNode=b}},Gte(o,Ua(Ua({},this.props),{},{payload:BL(v,h,Fte)})))}}],[{key:"getWithHeight",value:function(r,i){var o=Ua(Ua({},this.defaultProps),r.props),l=o.layout;return l==="vertical"&&be(r.props.height)?{height:r.props.height}:l==="horizontal"?{width:r.props.width||i}:null}}])})(w.PureComponent);xv(Xa,"displayName","Legend");xv(Xa,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var mw,FR;function Vte(){if(FR)return mw;FR=1;var e=Gf(),t=KO(),n=Fn(),r=e?e.isConcatSpreadable:void 0;function i(o){return n(o)||t(o)||!!(r&&o&&o[r])}return mw=i,mw}var pw,GR;function HL(){if(GR)return pw;GR=1;var e=ML(),t=Vte();function n(r,i,o,l,u){var d=-1,h=r.length;for(o||(o=t),u||(u=[]);++d<h;){var v=r[d];i>0&&o(v)?i>1?n(v,i-1,o,l,u):e(u,v):l||(u[u.length]=v)}return u}return pw=n,pw}var vw,VR;function Yte(){if(VR)return vw;VR=1;function e(t){return function(n,r,i){for(var o=-1,l=Object(n),u=i(n),d=u.length;d--;){var h=u[t?d:++o];if(r(l[h],h,l)===!1)break}return n}}return vw=e,vw}var gw,YR;function Wte(){if(YR)return gw;YR=1;var e=Yte(),t=e();return gw=t,gw}var yw,WR;function FL(){if(WR)return yw;WR=1;var e=Wte(),t=bv();function n(r,i){return r&&e(r,i,t)}return yw=n,yw}var bw,KR;function Kte(){if(KR)return bw;KR=1;var e=Wf();function t(n,r){return function(i,o){if(i==null)return i;if(!e(i))return n(i,o);for(var l=i.length,u=r?l:-1,d=Object(i);(r?u--:++u<l)&&o(d[u],u,d)!==!1;);return i}}return bw=t,bw}var xw,XR;function JO(){if(XR)return xw;XR=1;var e=FL(),t=Kte(),n=t(e);return xw=n,xw}var ww,QR;function GL(){if(QR)return ww;QR=1;var e=JO(),t=Wf();function n(r,i){var o=-1,l=t(r)?Array(r.length):[];return e(r,function(u,d,h){l[++o]=i(u,d,h)}),l}return ww=n,ww}var Sw,ZR;function Xte(){if(ZR)return Sw;ZR=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return Sw=e,Sw}var jw,JR;function Qte(){if(JR)return jw;JR=1;var e=uc();function t(n,r){if(n!==r){var i=n!==void 0,o=n===null,l=n===n,u=e(n),d=r!==void 0,h=r===null,v=r===r,p=e(r);if(!h&&!p&&!u&&n>r||u&&d&&v&&!h&&!p||o&&d&&v||!i&&v||!l)return 1;if(!o&&!u&&!p&&n<r||p&&i&&l&&!o&&!u||h&&i&&l||!d&&l||!v)return-1}return 0}return jw=t,jw}var Ow,eD;function Zte(){if(eD)return Ow;eD=1;var e=Qte();function t(n,r,i){for(var o=-1,l=n.criteria,u=r.criteria,d=l.length,h=i.length;++o<d;){var v=e(l[o],u[o]);if(v){if(o>=h)return v;var p=i[o];return v*(p=="desc"?-1:1)}}return n.index-r.index}return Ow=t,Ow}var _w,tD;function Jte(){if(tD)return _w;tD=1;var e=zO(),t=BO(),n=io(),r=GL(),i=Xte(),o=DL(),l=Zte(),u=dc(),d=Fn();function h(v,p,g){p.length?p=e(p,function(j){return d(j)?function(x){return t(x,j.length===1?j[0]:j)}:j}):p=[u];var b=-1;p=e(p,o(n));var O=r(v,function(j,x,_){var A=e(p,function(E){return E(j)});return{criteria:A,index:++b,value:j}});return i(O,function(j,x){return l(j,x,g)})}return _w=h,_w}var Ew,nD;function ene(){if(nD)return Ew;nD=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return Ew=e,Ew}var Aw,rD;function tne(){if(rD)return Aw;rD=1;var e=ene(),t=Math.max;function n(r,i,o){return i=t(i===void 0?r.length-1:i,0),function(){for(var l=arguments,u=-1,d=t(l.length-i,0),h=Array(d);++u<d;)h[u]=l[i+u];u=-1;for(var v=Array(i+1);++u<i;)v[u]=l[u];return v[i]=o(h),e(r,this,v)}}return Aw=n,Aw}var Nw,aD;function nne(){if(aD)return Nw;aD=1;function e(t){return function(){return t}}return Nw=e,Nw}var Cw,iD;function VL(){if(iD)return Cw;iD=1;var e=cs(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch{}})();return Cw=t,Cw}var Tw,oD;function rne(){if(oD)return Tw;oD=1;var e=nne(),t=VL(),n=dc(),r=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:n;return Tw=r,Tw}var Mw,sD;function ane(){if(sD)return Mw;sD=1;var e=800,t=16,n=Date.now;function r(i){var o=0,l=0;return function(){var u=n(),d=t-(u-l);if(l=u,d>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return Mw=r,Mw}var Rw,lD;function ine(){if(lD)return Rw;lD=1;var e=rne(),t=ane(),n=t(e);return Rw=n,Rw}var Dw,cD;function one(){if(cD)return Dw;cD=1;var e=dc(),t=tne(),n=ine();function r(i,o){return n(t(i,o,e),i+"")}return Dw=r,Dw}var Pw,uD;function wv(){if(uD)return Pw;uD=1;var e=$O(),t=Wf(),n=XO(),r=ao();function i(o,l,u){if(!r(u))return!1;var d=typeof l;return(d=="number"?t(u)&&n(l,u.length):d=="string"&&l in u)?e(u[l],o):!1}return Pw=i,Pw}var kw,fD;function sne(){if(fD)return kw;fD=1;var e=HL(),t=Jte(),n=one(),r=wv(),i=n(function(o,l){if(o==null)return[];var u=l.length;return u>1&&r(o,l[0],l[1])?l=[]:u>2&&r(l[0],l[1],l[2])&&(l=[l[0]]),t(o,e(l,1),[])});return kw=i,kw}var lne=sne();const e_=bt(lne);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 _S(){return _S=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_S.apply(this,arguments)}function cne(e,t){return hne(e)||dne(e,t)||fne(e,t)||une()}function une(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
404
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fne(e,t){if(e){if(typeof e=="string")return dD(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return dD(e,t)}}function dD(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function dne(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function hne(e){if(Array.isArray(e))return e}function hD(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function $w(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?hD(Object(n),!0).forEach(function(r){mne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mne(e,t,n){return t=pne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pne(e){var t=vne(e,"string");return Zu(t)=="symbol"?t:t+""}function vne(e,t){if(Zu(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Zu(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function gne(e){return Array.isArray(e)&&Zt(e[0])&&Zt(e[1])?e.join(" ~ "):e}var yne=function(t){var n=t.separator,r=n===void 0?" : ":n,i=t.contentStyle,o=i===void 0?{}:i,l=t.itemStyle,u=l===void 0?{}:l,d=t.labelStyle,h=d===void 0?{}:d,v=t.payload,p=t.formatter,g=t.itemSorter,b=t.wrapperClassName,O=t.labelClassName,j=t.label,x=t.labelFormatter,_=t.accessibilityLayer,A=_===void 0?!1:_,E=function(){if(v&&v.length){var F={padding:0,margin:0},W=(g?e_(v,g):v).map(function(Q,X){if(Q.type==="none")return null;var k=$w({display:"block",paddingTop:4,paddingBottom:4,color:Q.color||"#000"},u),H=Q.formatter||p||gne,B=Q.value,Z=Q.name,le=B,$=Z;if(H&&le!=null&&$!=null){var V=H(B,Z,Q,X,v);if(Array.isArray(V)){var q=cne(V,2);le=q[0],$=q[1]}else le=V}return I.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(X),style:k},Zt($)?I.createElement("span",{className:"recharts-tooltip-item-name"},$):null,Zt($)?I.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,I.createElement("span",{className:"recharts-tooltip-item-value"},le),I.createElement("span",{className:"recharts-tooltip-item-unit"},Q.unit||""))});return I.createElement("ul",{className:"recharts-tooltip-item-list",style:F},W)}return null},C=$w({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},o),N=$w({margin:0},h),M=!Qe(j),R=M?j:"",D=rt("recharts-default-tooltip",b),z=rt("recharts-tooltip-label",O);M&&x&&v!==void 0&&v!==null&&(R=x(j,v));var Y=A?{role:"status","aria-live":"assertive"}:{};return I.createElement("div",_S({className:D,style:C},Y),I.createElement("p",{className:z,style:N},I.isValidElement(R)?R:"".concat(R)),E())};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 Ah(e,t,n){return t=bne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bne(e){var t=xne(e,"string");return Ju(t)=="symbol"?t:t+""}function xne(e,t){if(Ju(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ju(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var bu="recharts-tooltip-wrapper",wne={visibility:"hidden"};function Sne(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return rt(bu,Ah(Ah(Ah(Ah({},"".concat(bu,"-right"),be(n)&&t&&be(t.x)&&n>=t.x),"".concat(bu,"-left"),be(n)&&t&&be(t.x)&&n<t.x),"".concat(bu,"-bottom"),be(r)&&t&&be(t.y)&&r>=t.y),"".concat(bu,"-top"),be(r)&&t&&be(t.y)&&r<t.y))}function mD(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,i=e.offsetTopLeft,o=e.position,l=e.reverseDirection,u=e.tooltipDimension,d=e.viewBox,h=e.viewBoxDimension;if(o&&be(o[r]))return o[r];var v=n[r]-u-i,p=n[r]+i;if(t[r])return l[r]?v:p;if(l[r]){var g=v,b=d[r];return g<b?Math.max(p,d[r]):Math.max(v,d[r])}var O=p+u,j=d[r]+h;return O>j?Math.max(v,d[r]):Math.max(p,d[r])}function jne(e){var t=e.translateX,n=e.translateY,r=e.useTranslate3d;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function One(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,o=e.reverseDirection,l=e.tooltipBox,u=e.useTranslate3d,d=e.viewBox,h,v,p;return l.height>0&&l.width>0&&n?(v=mD({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:l.width,viewBox:d,viewBoxDimension:d.width}),p=mD({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:l.height,viewBox:d,viewBoxDimension:d.height}),h=jne({translateX:v,translateY:p,useTranslate3d:u})):h=wne,{cssProperties:h,cssClasses:Sne({translateX:v,translateY:p,coordinate:n})}}function Tl(e){"@babel/helpers - typeof";return Tl=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},Tl(e)}function pD(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vD(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pD(Object(n),!0).forEach(function(r){AS(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function _ne(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ene(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,WL(r.key),r)}}function Ane(e,t,n){return t&&Ene(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Nne(e,t,n){return t=Am(t),Cne(e,YL()?Reflect.construct(t,n||[],Am(e).constructor):t.apply(e,n))}function Cne(e,t){if(t&&(Tl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Tne(e)}function Tne(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function YL(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(YL=function(){return!!e})()}function Am(e){return Am=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Am(e)}function Mne(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&&ES(e,t)}function ES(e,t){return ES=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},ES(e,t)}function AS(e,t,n){return t=WL(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function WL(e){var t=Rne(e,"string");return Tl(t)=="symbol"?t:t+""}function Rne(e,t){if(Tl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Tl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var gD=1,Dne=(function(e){function t(){var n;_ne(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=Nne(this,t,[].concat(i)),AS(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),AS(n,"handleKeyDown",function(l){if(l.key==="Escape"){var u,d,h,v;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(u=(d=n.props.coordinate)===null||d===void 0?void 0:d.x)!==null&&u!==void 0?u:0,y:(h=(v=n.props.coordinate)===null||v===void 0?void 0:v.y)!==null&&h!==void 0?h:0}})}}),n}return Mne(t,e),Ane(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>gD||Math.abs(r.height-this.state.lastBoundingBox.height)>gD)&&this.setState({lastBoundingBox:{width:r.width,height:r.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 r,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.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 r=this,i=this.props,o=i.active,l=i.allowEscapeViewBox,u=i.animationDuration,d=i.animationEasing,h=i.children,v=i.coordinate,p=i.hasPayload,g=i.isAnimationActive,b=i.offset,O=i.position,j=i.reverseDirection,x=i.useTranslate3d,_=i.viewBox,A=i.wrapperStyle,E=One({allowEscapeViewBox:l,coordinate:v,offsetTopLeft:b,position:O,reverseDirection:j,tooltipBox:this.state.lastBoundingBox,useTranslate3d:x,viewBox:_}),C=E.cssClasses,N=E.cssProperties,M=vD(vD({transition:g&&o?"transform ".concat(u,"ms ").concat(d):void 0},N),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&p?"visible":"hidden",position:"absolute",top:0,left:0},A);return I.createElement("div",{tabIndex:-1,className:C,style:M,ref:function(D){r.wrapperNode=D}},h)}}])})(w.PureComponent),Pne=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},hc={isSsr:Pne()};function Ml(e){"@babel/helpers - typeof";return Ml=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},Ml(e)}function yD(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function bD(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?yD(Object(n),!0).forEach(function(r){t_(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function kne(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $ne(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,XL(r.key),r)}}function Ine(e,t,n){return t&&$ne(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Lne(e,t,n){return t=Nm(t),zne(e,KL()?Reflect.construct(t,n||[],Nm(e).constructor):t.apply(e,n))}function zne(e,t){if(t&&(Ml(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Bne(e)}function Bne(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function KL(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(KL=function(){return!!e})()}function Nm(e){return Nm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Nm(e)}function qne(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&&NS(e,t)}function NS(e,t){return NS=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},NS(e,t)}function t_(e,t,n){return t=XL(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function XL(e){var t=Une(e,"string");return Ml(t)=="symbol"?t:t+""}function Une(e,t){if(Ml(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ml(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Hne(e){return e.dataKey}function Fne(e,t){return I.isValidElement(e)?I.cloneElement(e,t):typeof e=="function"?I.createElement(e,t):I.createElement(yne,t)}var _r=(function(e){function t(){return kne(this,t),Lne(this,t,arguments)}return qne(t,e),Ine(t,[{key:"render",value:function(){var r=this,i=this.props,o=i.active,l=i.allowEscapeViewBox,u=i.animationDuration,d=i.animationEasing,h=i.content,v=i.coordinate,p=i.filterNull,g=i.isAnimationActive,b=i.offset,O=i.payload,j=i.payloadUniqBy,x=i.position,_=i.reverseDirection,A=i.useTranslate3d,E=i.viewBox,C=i.wrapperStyle,N=O??[];p&&N.length&&(N=BL(O.filter(function(R){return R.value!=null&&(R.hide!==!0||r.props.includeHidden)}),j,Hne));var M=N.length>0;return I.createElement(Dne,{allowEscapeViewBox:l,animationDuration:u,animationEasing:d,isAnimationActive:g,active:o,coordinate:v,hasPayload:M,offset:b,position:x,reverseDirection:_,useTranslate3d:A,viewBox:E,wrapperStyle:C},Fne(h,bD(bD({},this.props),{},{payload:N})))}}])})(w.PureComponent);t_(_r,"displayName","Tooltip");t_(_r,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!hc.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 Iw,xD;function Gne(){if(xD)return Iw;xD=1;var e=wa(),t=function(){return e.Date.now()};return Iw=t,Iw}var Lw,wD;function Vne(){if(wD)return Lw;wD=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return Lw=t,Lw}var zw,SD;function Yne(){if(SD)return zw;SD=1;var e=Vne(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return zw=n,zw}var Bw,jD;function QL(){if(jD)return Bw;jD=1;var e=Yne(),t=ao(),n=uc(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,l=/^0o[0-7]+$/i,u=parseInt;function d(h){if(typeof h=="number")return h;if(n(h))return r;if(t(h)){var v=typeof h.valueOf=="function"?h.valueOf():h;h=t(v)?v+"":v}if(typeof h!="string")return h===0?h:+h;h=e(h);var p=o.test(h);return p||l.test(h)?u(h.slice(2),p?2:8):i.test(h)?r:+h}return Bw=d,Bw}var qw,OD;function Wne(){if(OD)return qw;OD=1;var e=ao(),t=Gne(),n=QL(),r="Expected a function",i=Math.max,o=Math.min;function l(u,d,h){var v,p,g,b,O,j,x=0,_=!1,A=!1,E=!0;if(typeof u!="function")throw new TypeError(r);d=n(d)||0,e(h)&&(_=!!h.leading,A="maxWait"in h,g=A?i(n(h.maxWait)||0,d):g,E="trailing"in h?!!h.trailing:E);function C(W){var Q=v,X=p;return v=p=void 0,x=W,b=u.apply(X,Q),b}function N(W){return x=W,O=setTimeout(D,d),_?C(W):b}function M(W){var Q=W-j,X=W-x,k=d-Q;return A?o(k,g-X):k}function R(W){var Q=W-j,X=W-x;return j===void 0||Q>=d||Q<0||A&&X>=g}function D(){var W=t();if(R(W))return z(W);O=setTimeout(D,M(W))}function z(W){return O=void 0,E&&v?C(W):(v=p=void 0,b)}function Y(){O!==void 0&&clearTimeout(O),x=0,v=j=p=O=void 0}function L(){return O===void 0?b:z(t())}function F(){var W=t(),Q=R(W);if(v=arguments,p=this,j=W,Q){if(O===void 0)return N(j);if(A)return clearTimeout(O),O=setTimeout(D,d),C(j)}return O===void 0&&(O=setTimeout(D,d)),b}return F.cancel=Y,F.flush=L,F}return qw=l,qw}var Uw,_D;function Kne(){if(_D)return Uw;_D=1;var e=Wne(),t=ao(),n="Expected a function";function r(i,o,l){var u=!0,d=!0;if(typeof i!="function")throw new TypeError(n);return t(l)&&(u="leading"in l?!!l.leading:u,d="trailing"in l?!!l.trailing:d),e(i,o,{leading:u,maxWait:o,trailing:d})}return Uw=r,Uw}var Xne=Kne();const ZL=bt(Xne);function ef(e){"@babel/helpers - typeof";return ef=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},ef(e)}function ED(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Nh(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ED(Object(n),!0).forEach(function(r){Qne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ED(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Qne(e,t,n){return t=Zne(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zne(e){var t=Jne(e,"string");return ef(t)=="symbol"?t:t+""}function Jne(e,t){if(ef(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ef(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ere(e,t){return are(e)||rre(e,t)||nre(e,t)||tre()}function tre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
405
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function nre(e,t){if(e){if(typeof e=="string")return AD(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return AD(e,t)}}function AD(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function rre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function are(e){if(Array.isArray(e))return e}var n_=w.forwardRef(function(e,t){var n=e.aspect,r=e.initialDimension,i=r===void 0?{width:-1,height:-1}:r,o=e.width,l=o===void 0?"100%":o,u=e.height,d=u===void 0?"100%":u,h=e.minWidth,v=h===void 0?0:h,p=e.minHeight,g=e.maxHeight,b=e.children,O=e.debounce,j=O===void 0?0:O,x=e.id,_=e.className,A=e.onResize,E=e.style,C=E===void 0?{}:E,N=w.useRef(null),M=w.useRef();M.current=A,w.useImperativeHandle(t,function(){return Object.defineProperty(N.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),N.current},configurable:!0})});var R=w.useState({containerWidth:i.width,containerHeight:i.height}),D=ere(R,2),z=D[0],Y=D[1],L=w.useCallback(function(W,Q){Y(function(X){var k=Math.round(W),H=Math.round(Q);return X.containerWidth===k&&X.containerHeight===H?X:{containerWidth:k,containerHeight:H}})},[]);w.useEffect(function(){var W=function(Z){var le,$=Z[0].contentRect,V=$.width,q=$.height;L(V,q),(le=M.current)===null||le===void 0||le.call(M,V,q)};j>0&&(W=ZL(W,j,{trailing:!0,leading:!1}));var Q=new ResizeObserver(W),X=N.current.getBoundingClientRect(),k=X.width,H=X.height;return L(k,H),Q.observe(N.current),function(){Q.disconnect()}},[L,j]);var F=w.useMemo(function(){var W=z.containerWidth,Q=z.containerHeight;if(W<0||Q<0)return null;Ka(zo(l)||zo(d),`The width(%s) and height(%s) are both fixed numbers,
406
+ maybe you don't need to use a ResponsiveContainer.`,l,d),Ka(!n||n>0,"The aspect(%s) must be greater than zero.",n);var X=zo(l)?W:l,k=zo(d)?Q:d;n&&n>0&&(X?k=X/n:k&&(X=k*n),g&&k>g&&(k=g)),Ka(X>0||k>0,`The width(%s) and height(%s) of chart should be greater than 0,
407
+ please check the style of container, or the props width(%s) and height(%s),
408
+ or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
409
+ height and width.`,X,k,l,d,v,p,n);var H=!Array.isArray(b)&&Wa(b.type).endsWith("Chart");return I.Children.map(b,function(B){return I.isValidElement(B)?w.cloneElement(B,Nh({width:X,height:k},H?{style:Nh({height:"100%",width:"100%",maxHeight:k,maxWidth:X},B.props.style)}:{})):B})},[n,b,d,g,p,v,z,l]);return I.createElement("div",{id:x?"".concat(x):void 0,className:rt("recharts-responsive-container",_),style:Nh(Nh({},C),{},{width:l,height:d,minWidth:v,minHeight:p,maxHeight:g}),ref:N},F)}),JL=function(t){return null};JL.displayName="Cell";function tf(e){"@babel/helpers - typeof";return tf=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},tf(e)}function ND(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function CS(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ND(Object(n),!0).forEach(function(r){ire(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ND(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ire(e,t,n){return t=ore(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ore(e){var t=sre(e,"string");return tf(t)=="symbol"?t:t+""}function sre(e,t){if(tf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(tf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ll={widthCache:{},cacheCount:0},lre=2e3,cre={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},CD="recharts_measurement_span";function ure(e){var t=CS({},e);return Object.keys(t).forEach(function(n){t[n]||delete t[n]}),t}var ku=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||hc.isSsr)return{width:0,height:0};var r=ure(n),i=JSON.stringify({text:t,copyStyle:r});if(ll.widthCache[i])return ll.widthCache[i];try{var o=document.getElementById(CD);o||(o=document.createElement("span"),o.setAttribute("id",CD),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var l=CS(CS({},cre),r);Object.assign(o.style,l),o.textContent="".concat(t);var u=o.getBoundingClientRect(),d={width:u.width,height:u.height};return ll.widthCache[i]=d,++ll.cacheCount>lre&&(ll.cacheCount=0,ll.widthCache={}),d}catch{return{width:0,height:0}}},fre=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function nf(e){"@babel/helpers - typeof";return nf=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},nf(e)}function Cm(e,t){return pre(e)||mre(e,t)||hre(e,t)||dre()}function dre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
410
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function hre(e,t){if(e){if(typeof e=="string")return TD(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return TD(e,t)}}function TD(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function mre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;d=!1}else for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function pre(e){if(Array.isArray(e))return e}function vre(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function MD(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,yre(r.key),r)}}function gre(e,t,n){return t&&MD(e.prototype,t),n&&MD(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function yre(e){var t=bre(e,"string");return nf(t)=="symbol"?t:t+""}function bre(e,t){if(nf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(nf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var RD=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,DD=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,xre=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,wre=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,ez={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},Sre=Object.keys(ez),dl="NaN";function jre(e,t){return e*ez[t]}var Ch=(function(){function e(t,n){vre(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=""),n!==""&&!xre.test(n)&&(this.num=NaN,this.unit=""),Sre.includes(n)&&(this.num=jre(t,n),this.unit="px")}return gre(e,[{key:"add",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num+n.num,this.unit)}},{key:"subtract",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num-n.num,this.unit)}},{key:"multiply",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num*n.num,this.unit||n.unit)}},{key:"divide",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num/n.num,this.unit||n.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(n){var r,i=(r=wre.exec(n))!==null&&r!==void 0?r:[],o=Cm(i,3),l=o[1],u=o[2];return new e(parseFloat(l),u??"")}}])})();function tz(e){if(e.includes(dl))return dl;for(var t=e;t.includes("*")||t.includes("/");){var n,r=(n=RD.exec(t))!==null&&n!==void 0?n:[],i=Cm(r,4),o=i[1],l=i[2],u=i[3],d=Ch.parse(o??""),h=Ch.parse(u??""),v=l==="*"?d.multiply(h):d.divide(h);if(v.isNaN())return dl;t=t.replace(RD,v.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var p,g=(p=DD.exec(t))!==null&&p!==void 0?p:[],b=Cm(g,4),O=b[1],j=b[2],x=b[3],_=Ch.parse(O??""),A=Ch.parse(x??""),E=j==="+"?_.add(A):_.subtract(A);if(E.isNaN())return dl;t=t.replace(DD,E.toString())}return t}var PD=/\(([^()]*)\)/;function Ore(e){for(var t=e;t.includes("(");){var n=PD.exec(t),r=Cm(n,2),i=r[1];t=t.replace(PD,tz(i))}return t}function _re(e){var t=e.replace(/\s+/g,"");return t=Ore(t),t=tz(t),t}function Ere(e){try{return _re(e)}catch{return dl}}function Hw(e){var t=Ere(e.slice(5,-1));return t===dl?"":t}var Are=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],Nre=["dx","dy","angle","className","breakAll"];function TS(){return TS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},TS.apply(this,arguments)}function kD(e,t){if(e==null)return{};var n=Cre(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Cre(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function $D(e,t){return Dre(e)||Rre(e,t)||Mre(e,t)||Tre()}function Tre(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
411
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Mre(e,t){if(e){if(typeof e=="string")return ID(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ID(e,t)}}function ID(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Rre(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;d=!1}else for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function Dre(e){if(Array.isArray(e))return e}var nz=/[ \f\n\r\t\v\u2028\u2029]+/,rz=function(t){var n=t.children,r=t.breakAll,i=t.style;try{var o=[];Qe(n)||(r?o=n.toString().split(""):o=n.toString().split(nz));var l=o.map(function(d){return{word:d,width:ku(d,i).width}}),u=r?0:ku(" ",i).width;return{wordsWithComputedWidth:l,spaceWidth:u}}catch{return null}},Pre=function(t,n,r,i,o){var l=t.maxLines,u=t.children,d=t.style,h=t.breakAll,v=be(l),p=u,g=function(){var X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return X.reduce(function(k,H){var B=H.word,Z=H.width,le=k[k.length-1];if(le&&(i==null||o||le.width+Z+r<Number(i)))le.words.push(B),le.width+=Z+r;else{var $={words:[B],width:Z};k.push($)}return k},[])},b=g(n),O=function(X){return X.reduce(function(k,H){return k.width>H.width?k:H})};if(!v)return b;for(var j="…",x=function(X){var k=p.slice(0,X),H=rz({breakAll:h,style:d,children:k+j}).wordsWithComputedWidth,B=g(H),Z=B.length>l||O(B).width>Number(i);return[Z,B]},_=0,A=p.length-1,E=0,C;_<=A&&E<=p.length-1;){var N=Math.floor((_+A)/2),M=N-1,R=x(M),D=$D(R,2),z=D[0],Y=D[1],L=x(N),F=$D(L,1),W=F[0];if(!z&&!W&&(_=N+1),z&&W&&(A=N-1),!z&&W){C=Y;break}E++}return C||b},LD=function(t){var n=Qe(t)?[]:t.toString().split(nz);return[{words:n}]},kre=function(t){var n=t.width,r=t.scaleToFit,i=t.children,o=t.style,l=t.breakAll,u=t.maxLines;if((n||r)&&!hc.isSsr){var d,h,v=rz({breakAll:l,children:i,style:o});if(v){var p=v.wordsWithComputedWidth,g=v.spaceWidth;d=p,h=g}else return LD(i);return Pre({breakAll:l,children:i,maxLines:u,style:o},d,h,n,r)}return LD(i)},zD="#808080",Tm=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,l=t.lineHeight,u=l===void 0?"1em":l,d=t.capHeight,h=d===void 0?"0.71em":d,v=t.scaleToFit,p=v===void 0?!1:v,g=t.textAnchor,b=g===void 0?"start":g,O=t.verticalAnchor,j=O===void 0?"end":O,x=t.fill,_=x===void 0?zD:x,A=kD(t,Are),E=w.useMemo(function(){return kre({breakAll:A.breakAll,children:A.children,maxLines:A.maxLines,scaleToFit:p,style:A.style,width:A.width})},[A.breakAll,A.children,A.maxLines,p,A.style,A.width]),C=A.dx,N=A.dy,M=A.angle,R=A.className,D=A.breakAll,z=kD(A,Nre);if(!Zt(r)||!Zt(o))return null;var Y=r+(be(C)?C:0),L=o+(be(N)?N:0),F;switch(j){case"start":F=Hw("calc(".concat(h,")"));break;case"middle":F=Hw("calc(".concat((E.length-1)/2," * -").concat(u," + (").concat(h," / 2))"));break;default:F=Hw("calc(".concat(E.length-1," * -").concat(u,")"));break}var W=[];if(p){var Q=E[0].width,X=A.width;W.push("scale(".concat((be(X)?X/Q:1)/Q,")"))}return M&&W.push("rotate(".concat(M,", ").concat(Y,", ").concat(L,")")),W.length&&(z.transform=W.join(" ")),I.createElement("text",TS({},nt(z,!0),{x:Y,y:L,className:rt("recharts-text",R),textAnchor:b,fill:_.includes("url")?zD:_}),E.map(function(k,H){var B=k.words.join(D?"":" ");return I.createElement("tspan",{x:Y,dy:H===0?F:u,key:"".concat(B,"-").concat(H)},B)}))};function Yi(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function $re(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function r_(e){let t,n,r;e.length!==2?(t=Yi,n=(u,d)=>Yi(e(u),d),r=(u,d)=>e(u)-d):(t=e===Yi||e===$re?e:Ire,n=e,r=e);function i(u,d,h=0,v=u.length){if(h<v){if(t(d,d)!==0)return v;do{const p=h+v>>>1;n(u[p],d)<0?h=p+1:v=p}while(h<v)}return h}function o(u,d,h=0,v=u.length){if(h<v){if(t(d,d)!==0)return v;do{const p=h+v>>>1;n(u[p],d)<=0?h=p+1:v=p}while(h<v)}return h}function l(u,d,h=0,v=u.length){const p=i(u,d,h,v-1);return p>h&&r(u[p-1],d)>-r(u[p],d)?p-1:p}return{left:i,center:l,right:o}}function Ire(){return 0}function az(e){return e===null?NaN:+e}function*Lre(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const zre=r_(Yi),Kf=zre.right;r_(az).center;class BD extends Map{constructor(t,n=Ure){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(qD(this,t))}has(t){return super.has(qD(this,t))}set(t,n){return super.set(Bre(this,t),n)}delete(t){return super.delete(qre(this,t))}}function qD({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function Bre({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function qre({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function Ure(e){return e!==null&&typeof e=="object"?e.valueOf():e}function Hre(e=Yi){if(e===Yi)return iz;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function iz(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const Fre=Math.sqrt(50),Gre=Math.sqrt(10),Vre=Math.sqrt(2);function Mm(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),l=o>=Fre?10:o>=Gre?5:o>=Vre?2:1;let u,d,h;return i<0?(h=Math.pow(10,-i)/l,u=Math.round(e*h),d=Math.round(t*h),u/h<e&&++u,d/h>t&&--d,h=-h):(h=Math.pow(10,i)*l,u=Math.round(e/h),d=Math.round(t/h),u*h<e&&++u,d*h>t&&--d),d<u&&.5<=n&&n<2?Mm(e,t,n*2):[u,d,h]}function MS(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,l]=r?Mm(t,e,n):Mm(e,t,n);if(!(o>=i))return[];const u=o-i+1,d=new Array(u);if(r)if(l<0)for(let h=0;h<u;++h)d[h]=(o-h)/-l;else for(let h=0;h<u;++h)d[h]=(o-h)*l;else if(l<0)for(let h=0;h<u;++h)d[h]=(i+h)/-l;else for(let h=0;h<u;++h)d[h]=(i+h)*l;return d}function RS(e,t,n){return t=+t,e=+e,n=+n,Mm(e,t,n)[2]}function DS(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?RS(t,e,n):RS(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function UD(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function HD(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function oz(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?iz:Hre(i);r>n;){if(r-n>600){const d=r-n+1,h=t-n+1,v=Math.log(d),p=.5*Math.exp(2*v/3),g=.5*Math.sqrt(v*p*(d-p)/d)*(h-d/2<0?-1:1),b=Math.max(n,Math.floor(t-h*p/d+g)),O=Math.min(r,Math.floor(t+(d-h)*p/d+g));oz(e,t,b,O,i)}const o=e[t];let l=n,u=r;for(xu(e,n,t),i(e[r],o)>0&&xu(e,n,r);l<u;){for(xu(e,l,u),++l,--u;i(e[l],o)<0;)++l;for(;i(e[u],o)>0;)--u}i(e[n],o)===0?xu(e,n,u):(++u,xu(e,u,r)),u<=t&&(n=u+1),t<=u&&(r=u-1)}return e}function xu(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function Yre(e,t,n){if(e=Float64Array.from(Lre(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return HD(e);if(t>=1)return UD(e);var r,i=(r-1)*t,o=Math.floor(i),l=UD(oz(e,o).subarray(0,o+1)),u=HD(e.subarray(o+1));return l+(u-l)*(i-o)}}function Wre(e,t,n=az){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,o=Math.floor(i),l=+n(e[o],o,e),u=+n(e[o+1],o+1,e);return l+(u-l)*(i-o)}}function Kre(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r<i;)o[r]=e+r*n;return o}function Pr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function ui(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}const PS=Symbol("implicit");function a_(){var e=new BD,t=[],n=[],r=PS;function i(o){let l=e.get(o);if(l===void 0){if(r!==PS)return r;e.set(o,l=t.push(o)-1)}return n[l%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new BD;for(const l of o)e.has(l)||e.set(l,t.push(l)-1);return i},i.range=function(o){return arguments.length?(n=Array.from(o),i):n.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return a_(t,n).unknown(r)},Pr.apply(i,arguments),i}function rf(){var e=a_().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,l,u=!1,d=0,h=0,v=.5;delete e.unknown;function p(){var g=t().length,b=i<r,O=b?i:r,j=b?r:i;o=(j-O)/Math.max(1,g-d+h*2),u&&(o=Math.floor(o)),O+=(j-O-o*(g-d))*v,l=o*(1-d),u&&(O=Math.round(O),l=Math.round(l));var x=Kre(g).map(function(_){return O+o*_});return n(b?x.reverse():x)}return e.domain=function(g){return arguments.length?(t(g),p()):t()},e.range=function(g){return arguments.length?([r,i]=g,r=+r,i=+i,p()):[r,i]},e.rangeRound=function(g){return[r,i]=g,r=+r,i=+i,u=!0,p()},e.bandwidth=function(){return l},e.step=function(){return o},e.round=function(g){return arguments.length?(u=!!g,p()):u},e.padding=function(g){return arguments.length?(d=Math.min(1,h=+g),p()):d},e.paddingInner=function(g){return arguments.length?(d=Math.min(1,g),p()):d},e.paddingOuter=function(g){return arguments.length?(h=+g,p()):h},e.align=function(g){return arguments.length?(v=Math.max(0,Math.min(1,g)),p()):v},e.copy=function(){return rf(t(),[r,i]).round(u).paddingInner(d).paddingOuter(h).align(v)},Pr.apply(p(),arguments)}function sz(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return sz(t())},e}function $u(){return sz(rf.apply(null,arguments).paddingInner(1))}function i_(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function lz(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Xf(){}var af=.7,Rm=1/af,wl="\\s*([+-]?\\d+)\\s*",of="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",pa="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Xre=/^#([0-9a-f]{3,8})$/,Qre=new RegExp(`^rgb\\(${wl},${wl},${wl}\\)$`),Zre=new RegExp(`^rgb\\(${pa},${pa},${pa}\\)$`),Jre=new RegExp(`^rgba\\(${wl},${wl},${wl},${of}\\)$`),eae=new RegExp(`^rgba\\(${pa},${pa},${pa},${of}\\)$`),tae=new RegExp(`^hsl\\(${of},${pa},${pa}\\)$`),nae=new RegExp(`^hsla\\(${of},${pa},${pa},${of}\\)$`),FD={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};i_(Xf,sf,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:GD,formatHex:GD,formatHex8:rae,formatHsl:aae,formatRgb:VD,toString:VD});function GD(){return this.rgb().formatHex()}function rae(){return this.rgb().formatHex8()}function aae(){return cz(this).formatHsl()}function VD(){return this.rgb().formatRgb()}function sf(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=Xre.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?YD(t):n===3?new Hn(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Th(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Th(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=Qre.exec(e))?new Hn(t[1],t[2],t[3],1):(t=Zre.exec(e))?new Hn(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Jre.exec(e))?Th(t[1],t[2],t[3],t[4]):(t=eae.exec(e))?Th(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=tae.exec(e))?XD(t[1],t[2]/100,t[3]/100,1):(t=nae.exec(e))?XD(t[1],t[2]/100,t[3]/100,t[4]):FD.hasOwnProperty(e)?YD(FD[e]):e==="transparent"?new Hn(NaN,NaN,NaN,0):null}function YD(e){return new Hn(e>>16&255,e>>8&255,e&255,1)}function Th(e,t,n,r){return r<=0&&(e=t=n=NaN),new Hn(e,t,n,r)}function iae(e){return e instanceof Xf||(e=sf(e)),e?(e=e.rgb(),new Hn(e.r,e.g,e.b,e.opacity)):new Hn}function kS(e,t,n,r){return arguments.length===1?iae(e):new Hn(e,t,n,r??1)}function Hn(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}i_(Hn,kS,lz(Xf,{brighter(e){return e=e==null?Rm:Math.pow(Rm,e),new Hn(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?af:Math.pow(af,e),new Hn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Hn(Fo(this.r),Fo(this.g),Fo(this.b),Dm(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:WD,formatHex:WD,formatHex8:oae,formatRgb:KD,toString:KD}));function WD(){return`#${Bo(this.r)}${Bo(this.g)}${Bo(this.b)}`}function oae(){return`#${Bo(this.r)}${Bo(this.g)}${Bo(this.b)}${Bo((isNaN(this.opacity)?1:this.opacity)*255)}`}function KD(){const e=Dm(this.opacity);return`${e===1?"rgb(":"rgba("}${Fo(this.r)}, ${Fo(this.g)}, ${Fo(this.b)}${e===1?")":`, ${e})`}`}function Dm(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Fo(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Bo(e){return e=Fo(e),(e<16?"0":"")+e.toString(16)}function XD(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Gr(e,t,n,r)}function cz(e){if(e instanceof Gr)return new Gr(e.h,e.s,e.l,e.opacity);if(e instanceof Xf||(e=sf(e)),!e)return new Gr;if(e instanceof Gr)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),l=NaN,u=o-i,d=(o+i)/2;return u?(t===o?l=(n-r)/u+(n<r)*6:n===o?l=(r-t)/u+2:l=(t-n)/u+4,u/=d<.5?o+i:2-o-i,l*=60):u=d>0&&d<1?0:l,new Gr(l,u,d,e.opacity)}function sae(e,t,n,r){return arguments.length===1?cz(e):new Gr(e,t,n,r??1)}function Gr(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}i_(Gr,sae,lz(Xf,{brighter(e){return e=e==null?Rm:Math.pow(Rm,e),new Gr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?af:Math.pow(af,e),new Gr(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,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new Hn(Fw(e>=240?e-240:e+120,i,r),Fw(e,i,r),Fw(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Gr(QD(this.h),Mh(this.s),Mh(this.l),Dm(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=Dm(this.opacity);return`${e===1?"hsl(":"hsla("}${QD(this.h)}, ${Mh(this.s)*100}%, ${Mh(this.l)*100}%${e===1?")":`, ${e})`}`}}));function QD(e){return e=(e||0)%360,e<0?e+360:e}function Mh(e){return Math.max(0,Math.min(1,e||0))}function Fw(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const o_=e=>()=>e;function lae(e,t){return function(n){return e+n*t}}function cae(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function uae(e){return(e=+e)==1?uz:function(t,n){return n-t?cae(t,n,e):o_(isNaN(t)?n:t)}}function uz(e,t){var n=t-e;return n?lae(e,n):o_(isNaN(e)?t:e)}const ZD=(function e(t){var n=uae(t);function r(i,o){var l=n((i=kS(i)).r,(o=kS(o)).r),u=n(i.g,o.g),d=n(i.b,o.b),h=uz(i.opacity,o.opacity);return function(v){return i.r=l(v),i.g=u(v),i.b=d(v),i.opacity=h(v),i+""}}return r.gamma=e,r})(1);function fae(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function dae(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function hae(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),l;for(l=0;l<r;++l)i[l]=mc(e[l],t[l]);for(;l<n;++l)o[l]=t[l];return function(u){for(l=0;l<r;++l)o[l]=i[l](u);return o}}function mae(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Pm(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function pae(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=mc(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var $S=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Gw=new RegExp($S.source,"g");function vae(e){return function(){return e}}function gae(e){return function(t){return e(t)+""}}function yae(e,t){var n=$S.lastIndex=Gw.lastIndex=0,r,i,o,l=-1,u=[],d=[];for(e=e+"",t=t+"";(r=$S.exec(e))&&(i=Gw.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),u[l]?u[l]+=o:u[++l]=o),(r=r[0])===(i=i[0])?u[l]?u[l]+=i:u[++l]=i:(u[++l]=null,d.push({i:l,x:Pm(r,i)})),n=Gw.lastIndex;return n<t.length&&(o=t.slice(n),u[l]?u[l]+=o:u[++l]=o),u.length<2?d[0]?gae(d[0].x):vae(t):(t=d.length,function(h){for(var v=0,p;v<t;++v)u[(p=d[v]).i]=p.x(h);return u.join("")})}function mc(e,t){var n=typeof t,r;return t==null||n==="boolean"?o_(t):(n==="number"?Pm:n==="string"?(r=sf(t))?(t=r,ZD):yae:t instanceof sf?ZD:t instanceof Date?mae:dae(t)?fae:Array.isArray(t)?hae:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?pae:Pm)(e,t)}function s_(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function bae(e,t){t===void 0&&(t=e,e=mc);for(var n=0,r=t.length-1,i=t[0],o=new Array(r<0?0:r);n<r;)o[n]=e(i,i=t[++n]);return function(l){var u=Math.max(0,Math.min(r-1,Math.floor(l*=r)));return o[u](l-u)}}function xae(e){return function(){return e}}function km(e){return+e}var JD=[0,1];function En(e){return e}function IS(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:xae(isNaN(t)?NaN:.5)}function wae(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function Sae(e,t,n){var r=e[0],i=e[1],o=t[0],l=t[1];return i<r?(r=IS(i,r),o=n(l,o)):(r=IS(r,i),o=n(o,l)),function(u){return o(r(u))}}function jae(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),l=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++l<r;)i[l]=IS(e[l],e[l+1]),o[l]=n(t[l],t[l+1]);return function(u){var d=Kf(e,u,1,r)-1;return o[d](i[d](u))}}function Qf(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Sv(){var e=JD,t=JD,n=mc,r,i,o,l=En,u,d,h;function v(){var g=Math.min(e.length,t.length);return l!==En&&(l=wae(e[0],e[g-1])),u=g>2?jae:Sae,d=h=null,p}function p(g){return g==null||isNaN(g=+g)?o:(d||(d=u(e.map(r),t,n)))(r(l(g)))}return p.invert=function(g){return l(i((h||(h=u(t,e.map(r),Pm)))(g)))},p.domain=function(g){return arguments.length?(e=Array.from(g,km),v()):e.slice()},p.range=function(g){return arguments.length?(t=Array.from(g),v()):t.slice()},p.rangeRound=function(g){return t=Array.from(g),n=s_,v()},p.clamp=function(g){return arguments.length?(l=g?!0:En,v()):l!==En},p.interpolate=function(g){return arguments.length?(n=g,v()):n},p.unknown=function(g){return arguments.length?(o=g,p):o},function(g,b){return r=g,i=b,v()}}function l_(){return Sv()(En,En)}function Oae(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function $m(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Rl(e){return e=$m(Math.abs(e)),e?e[1]:NaN}function _ae(e,t){return function(n,r){for(var i=n.length,o=[],l=0,u=e[0],d=0;i>0&&u>0&&(d+u+1>r&&(u=Math.max(1,r-d)),o.push(n.substring(i-=u,i+u)),!((d+=u+1)>r));)u=e[l=(l+1)%e.length];return o.reverse().join(t)}}function Eae(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var Aae=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function lf(e){if(!(t=Aae.exec(e)))throw new Error("invalid format: "+e);var t;return new c_({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]})}lf.prototype=c_.prototype;function c_(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+""}c_.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 Nae(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var fz;function Cae(e,t){var n=$m(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(fz=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,l=r.length;return o===l?r:o>l?r+new Array(o-l+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+$m(e,Math.max(0,t+o-1))[0]}function eP(e,t){var n=$m(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const tP={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:Oae,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)=>eP(e*100,t),r:eP,s:Cae,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function nP(e){return e}var rP=Array.prototype.map,aP=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Tae(e){var t=e.grouping===void 0||e.thousands===void 0?nP:_ae(rP.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?nP:Eae(rP.call(e.numerals,String)),l=e.percent===void 0?"%":e.percent+"",u=e.minus===void 0?"−":e.minus+"",d=e.nan===void 0?"NaN":e.nan+"";function h(p){p=lf(p);var g=p.fill,b=p.align,O=p.sign,j=p.symbol,x=p.zero,_=p.width,A=p.comma,E=p.precision,C=p.trim,N=p.type;N==="n"?(A=!0,N="g"):tP[N]||(E===void 0&&(E=12),C=!0,N="g"),(x||g==="0"&&b==="=")&&(x=!0,g="0",b="=");var M=j==="$"?n:j==="#"&&/[boxX]/.test(N)?"0"+N.toLowerCase():"",R=j==="$"?r:/[%p]/.test(N)?l:"",D=tP[N],z=/[defgprs%]/.test(N);E=E===void 0?6:/[gprs]/.test(N)?Math.max(1,Math.min(21,E)):Math.max(0,Math.min(20,E));function Y(L){var F=M,W=R,Q,X,k;if(N==="c")W=D(L)+W,L="";else{L=+L;var H=L<0||1/L<0;if(L=isNaN(L)?d:D(Math.abs(L),E),C&&(L=Nae(L)),H&&+L==0&&O!=="+"&&(H=!1),F=(H?O==="("?O:u:O==="-"||O==="("?"":O)+F,W=(N==="s"?aP[8+fz/3]:"")+W+(H&&O==="("?")":""),z){for(Q=-1,X=L.length;++Q<X;)if(k=L.charCodeAt(Q),48>k||k>57){W=(k===46?i+L.slice(Q+1):L.slice(Q))+W,L=L.slice(0,Q);break}}}A&&!x&&(L=t(L,1/0));var B=F.length+L.length+W.length,Z=B<_?new Array(_-B+1).join(g):"";switch(A&&x&&(L=t(Z+L,Z.length?_-W.length:1/0),Z=""),b){case"<":L=F+L+W+Z;break;case"=":L=F+Z+L+W;break;case"^":L=Z.slice(0,B=Z.length>>1)+F+L+W+Z.slice(B);break;default:L=Z+F+L+W;break}return o(L)}return Y.toString=function(){return p+""},Y}function v(p,g){var b=h((p=lf(p),p.type="f",p)),O=Math.max(-8,Math.min(8,Math.floor(Rl(g)/3)))*3,j=Math.pow(10,-O),x=aP[8+O/3];return function(_){return b(j*_)+x}}return{format:h,formatPrefix:v}}var Rh,u_,dz;Mae({thousands:",",grouping:[3],currency:["$",""]});function Mae(e){return Rh=Tae(e),u_=Rh.format,dz=Rh.formatPrefix,Rh}function Rae(e){return Math.max(0,-Rl(Math.abs(e)))}function Dae(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Rl(t)/3)))*3-Rl(Math.abs(e)))}function Pae(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Rl(t)-Rl(e))+1}function hz(e,t,n,r){var i=DS(e,t,n),o;switch(r=lf(r??",f"),r.type){case"s":{var l=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=Dae(i,l))&&(r.precision=o),dz(r,l)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=Pae(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=Rae(i))&&(r.precision=o-(r.type==="%")*2);break}}return u_(r)}function oo(e){var t=e.domain;return e.ticks=function(n){var r=t();return MS(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return hz(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,l=r[i],u=r[o],d,h,v=10;for(u<l&&(h=l,l=u,u=h,h=i,i=o,o=h);v-- >0;){if(h=RS(l,u,n),h===d)return r[i]=l,r[o]=u,t(r);if(h>0)l=Math.floor(l/h)*h,u=Math.ceil(u/h)*h;else if(h<0)l=Math.ceil(l*h)/h,u=Math.floor(u*h)/h;else break;d=h}return e},e}function Im(){var e=l_();return e.copy=function(){return Qf(e,Im())},Pr.apply(e,arguments),oo(e)}function mz(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,km),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return mz(e).unknown(t)},e=arguments.length?Array.from(e,km):[0,1],oo(n)}function pz(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],l;return o<i&&(l=n,n=r,r=l,l=i,i=o,o=l),e[n]=t.floor(i),e[r]=t.ceil(o),e}function iP(e){return Math.log(e)}function oP(e){return Math.exp(e)}function kae(e){return-Math.log(-e)}function $ae(e){return-Math.exp(-e)}function Iae(e){return isFinite(e)?+("1e"+e):e<0?0:e}function Lae(e){return e===10?Iae:e===Math.E?Math.exp:t=>Math.pow(e,t)}function zae(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 sP(e){return(t,n)=>-e(-t,n)}function f_(e){const t=e(iP,oP),n=t.domain;let r=10,i,o;function l(){return i=zae(r),o=Lae(r),n()[0]<0?(i=sP(i),o=sP(o),e(kae,$ae)):e(iP,oP),t}return t.base=function(u){return arguments.length?(r=+u,l()):r},t.domain=function(u){return arguments.length?(n(u),l()):n()},t.ticks=u=>{const d=n();let h=d[0],v=d[d.length-1];const p=v<h;p&&([h,v]=[v,h]);let g=i(h),b=i(v),O,j;const x=u==null?10:+u;let _=[];if(!(r%1)&&b-g<x){if(g=Math.floor(g),b=Math.ceil(b),h>0){for(;g<=b;++g)for(O=1;O<r;++O)if(j=g<0?O/o(-g):O*o(g),!(j<h)){if(j>v)break;_.push(j)}}else for(;g<=b;++g)for(O=r-1;O>=1;--O)if(j=g>0?O/o(-g):O*o(g),!(j<h)){if(j>v)break;_.push(j)}_.length*2<x&&(_=MS(h,v,x))}else _=MS(g,b,Math.min(b-g,x)).map(o);return p?_.reverse():_},t.tickFormat=(u,d)=>{if(u==null&&(u=10),d==null&&(d=r===10?"s":","),typeof d!="function"&&(!(r%1)&&(d=lf(d)).precision==null&&(d.trim=!0),d=u_(d)),u===1/0)return d;const h=Math.max(1,r*u/t.ticks().length);return v=>{let p=v/o(Math.round(i(v)));return p*r<r-.5&&(p*=r),p<=h?d(v):""}},t.nice=()=>n(pz(n(),{floor:u=>o(Math.floor(i(u))),ceil:u=>o(Math.ceil(i(u)))})),t}function vz(){const e=f_(Sv()).domain([1,10]);return e.copy=()=>Qf(e,vz()).base(e.base()),Pr.apply(e,arguments),e}function lP(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function cP(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function d_(e){var t=1,n=e(lP(t),cP(t));return n.constant=function(r){return arguments.length?e(lP(t=+r),cP(t)):t},oo(n)}function gz(){var e=d_(Sv());return e.copy=function(){return Qf(e,gz()).constant(e.constant())},Pr.apply(e,arguments)}function uP(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function Bae(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function qae(e){return e<0?-e*e:e*e}function h_(e){var t=e(En,En),n=1;function r(){return n===1?e(En,En):n===.5?e(Bae,qae):e(uP(n),uP(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},oo(t)}function m_(){var e=h_(Sv());return e.copy=function(){return Qf(e,m_()).exponent(e.exponent())},Pr.apply(e,arguments),e}function Uae(){return m_.apply(null,arguments).exponent(.5)}function fP(e){return Math.sign(e)*e*e}function Hae(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function yz(){var e=l_(),t=[0,1],n=!1,r;function i(o){var l=Hae(e(o));return isNaN(l)?r:n?Math.round(l):l}return i.invert=function(o){return e.invert(fP(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,km)).map(fP)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return yz(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},Pr.apply(i,arguments),oo(i)}function bz(){var e=[],t=[],n=[],r;function i(){var l=0,u=Math.max(1,t.length);for(n=new Array(u-1);++l<u;)n[l-1]=Wre(e,l/u);return o}function o(l){return l==null||isNaN(l=+l)?r:t[Kf(n,l)]}return o.invertExtent=function(l){var u=t.indexOf(l);return u<0?[NaN,NaN]:[u>0?n[u-1]:e[0],u<n.length?n[u]:e[e.length-1]]},o.domain=function(l){if(!arguments.length)return e.slice();e=[];for(let u of l)u!=null&&!isNaN(u=+u)&&e.push(u);return e.sort(Yi),i()},o.range=function(l){return arguments.length?(t=Array.from(l),i()):t.slice()},o.unknown=function(l){return arguments.length?(r=l,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return bz().domain(e).range(t).unknown(r)},Pr.apply(o,arguments)}function xz(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function l(d){return d!=null&&d<=d?i[Kf(r,d,0,n)]:o}function u(){var d=-1;for(r=new Array(n);++d<n;)r[d]=((d+1)*t-(d-n)*e)/(n+1);return l}return l.domain=function(d){return arguments.length?([e,t]=d,e=+e,t=+t,u()):[e,t]},l.range=function(d){return arguments.length?(n=(i=Array.from(d)).length-1,u()):i.slice()},l.invertExtent=function(d){var h=i.indexOf(d);return h<0?[NaN,NaN]:h<1?[e,r[0]]:h>=n?[r[n-1],t]:[r[h-1],r[h]]},l.unknown=function(d){return arguments.length&&(o=d),l},l.thresholds=function(){return r.slice()},l.copy=function(){return xz().domain([e,t]).range(i).unknown(o)},Pr.apply(oo(l),arguments)}function wz(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[Kf(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var l=t.indexOf(o);return[e[l-1],e[l]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return wz().domain(e).range(t).unknown(n)},Pr.apply(i,arguments)}const Vw=new Date,Yw=new Date;function Jt(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const l=i(o),u=i.ceil(o);return o-l<u-o?l:u},i.offset=(o,l)=>(t(o=new Date(+o),l==null?1:Math.floor(l)),o),i.range=(o,l,u)=>{const d=[];if(o=i.ceil(o),u=u==null?1:Math.floor(u),!(o<l)||!(u>0))return d;let h;do d.push(h=new Date(+o)),t(o,u),e(o);while(h<o&&o<l);return d},i.filter=o=>Jt(l=>{if(l>=l)for(;e(l),!o(l);)l.setTime(l-1)},(l,u)=>{if(l>=l)if(u<0)for(;++u<=0;)for(;t(l,-1),!o(l););else for(;--u>=0;)for(;t(l,1),!o(l););}),n&&(i.count=(o,l)=>(Vw.setTime(+o),Yw.setTime(+l),e(Vw),e(Yw),Math.floor(n(Vw,Yw))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?l=>r(l)%o===0:l=>i.count(0,l)%o===0):i)),i}const Lm=Jt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Lm.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Jt(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Lm);Lm.range;const Fa=1e3,Ar=Fa*60,Ga=Ar*60,ri=Ga*24,p_=ri*7,dP=ri*30,Ww=ri*365,qo=Jt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Fa)},(e,t)=>(t-e)/Fa,e=>e.getUTCSeconds());qo.range;const v_=Jt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Fa)},(e,t)=>{e.setTime(+e+t*Ar)},(e,t)=>(t-e)/Ar,e=>e.getMinutes());v_.range;const g_=Jt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Ar)},(e,t)=>(t-e)/Ar,e=>e.getUTCMinutes());g_.range;const y_=Jt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Fa-e.getMinutes()*Ar)},(e,t)=>{e.setTime(+e+t*Ga)},(e,t)=>(t-e)/Ga,e=>e.getHours());y_.range;const b_=Jt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Ga)},(e,t)=>(t-e)/Ga,e=>e.getUTCHours());b_.range;const Zf=Jt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Ar)/ri,e=>e.getDate()-1);Zf.range;const jv=Jt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ri,e=>e.getUTCDate()-1);jv.range;const Sz=Jt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ri,e=>Math.floor(e/ri));Sz.range;function us(e){return Jt(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Ar)/p_)}const Ov=us(0),zm=us(1),Fae=us(2),Gae=us(3),Dl=us(4),Vae=us(5),Yae=us(6);Ov.range;zm.range;Fae.range;Gae.range;Dl.range;Vae.range;Yae.range;function fs(e){return Jt(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/p_)}const _v=fs(0),Bm=fs(1),Wae=fs(2),Kae=fs(3),Pl=fs(4),Xae=fs(5),Qae=fs(6);_v.range;Bm.range;Wae.range;Kae.range;Pl.range;Xae.range;Qae.range;const x_=Jt(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());x_.range;const w_=Jt(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());w_.range;const ai=Jt(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());ai.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Jt(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});ai.range;const ii=Jt(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());ii.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Jt(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});ii.range;function jz(e,t,n,r,i,o){const l=[[qo,1,Fa],[qo,5,5*Fa],[qo,15,15*Fa],[qo,30,30*Fa],[o,1,Ar],[o,5,5*Ar],[o,15,15*Ar],[o,30,30*Ar],[i,1,Ga],[i,3,3*Ga],[i,6,6*Ga],[i,12,12*Ga],[r,1,ri],[r,2,2*ri],[n,1,p_],[t,1,dP],[t,3,3*dP],[e,1,Ww]];function u(h,v,p){const g=v<h;g&&([h,v]=[v,h]);const b=p&&typeof p.range=="function"?p:d(h,v,p),O=b?b.range(h,+v+1):[];return g?O.reverse():O}function d(h,v,p){const g=Math.abs(v-h)/p,b=r_(([,,x])=>x).right(l,g);if(b===l.length)return e.every(DS(h/Ww,v/Ww,p));if(b===0)return Lm.every(Math.max(DS(h,v,p),1));const[O,j]=l[g/l[b-1][2]<l[b][2]/g?b-1:b];return O.every(j)}return[u,d]}const[Zae,Jae]=jz(ii,w_,_v,Sz,b_,g_),[eie,tie]=jz(ai,x_,Ov,Zf,y_,v_);function Kw(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 Xw(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 wu(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function nie(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,l=e.shortDays,u=e.months,d=e.shortMonths,h=Su(i),v=ju(i),p=Su(o),g=ju(o),b=Su(l),O=ju(l),j=Su(u),x=ju(u),_=Su(d),A=ju(d),E={a:H,A:B,b:Z,B:le,c:null,d:yP,e:yP,f:_ie,g:kie,G:Iie,H:Sie,I:jie,j:Oie,L:Oz,m:Eie,M:Aie,p:$,q:V,Q:wP,s:SP,S:Nie,u:Cie,U:Tie,V:Mie,w:Rie,W:Die,x:null,X:null,y:Pie,Y:$ie,Z:Lie,"%":xP},C={a:q,A:U,b:ne,B:fe,c:null,d:bP,e:bP,f:Uie,g:Zie,G:eoe,H:zie,I:Bie,j:qie,L:Ez,m:Hie,M:Fie,p:ie,q:pe,Q:wP,s:SP,S:Gie,u:Vie,U:Yie,V:Wie,w:Kie,W:Xie,x:null,X:null,y:Qie,Y:Jie,Z:toe,"%":xP},N={a:Y,A:L,b:F,B:W,c:Q,d:vP,e:vP,f:yie,g:pP,G:mP,H:gP,I:gP,j:mie,L:gie,m:hie,M:pie,p:z,q:die,Q:xie,s:wie,S:vie,u:sie,U:lie,V:cie,w:oie,W:uie,x:X,X:k,y:pP,Y:mP,Z:fie,"%":bie};E.x=M(n,E),E.X=M(r,E),E.c=M(t,E),C.x=M(n,C),C.X=M(r,C),C.c=M(t,C);function M(re,ve){return function(ge){var oe=[],ke=-1,we=0,Ie=re.length,Ze,lt,en;for(ge instanceof Date||(ge=new Date(+ge));++ke<Ie;)re.charCodeAt(ke)===37&&(oe.push(re.slice(we,ke)),(lt=hP[Ze=re.charAt(++ke)])!=null?Ze=re.charAt(++ke):lt=Ze==="e"?" ":"0",(en=ve[Ze])&&(Ze=en(ge,lt)),oe.push(Ze),we=ke+1);return oe.push(re.slice(we,ke)),oe.join("")}}function R(re,ve){return function(ge){var oe=wu(1900,void 0,1),ke=D(oe,re,ge+="",0),we,Ie;if(ke!=ge.length)return null;if("Q"in oe)return new Date(oe.Q);if("s"in oe)return new Date(oe.s*1e3+("L"in oe?oe.L:0));if(ve&&!("Z"in oe)&&(oe.Z=0),"p"in oe&&(oe.H=oe.H%12+oe.p*12),oe.m===void 0&&(oe.m="q"in oe?oe.q:0),"V"in oe){if(oe.V<1||oe.V>53)return null;"w"in oe||(oe.w=1),"Z"in oe?(we=Xw(wu(oe.y,0,1)),Ie=we.getUTCDay(),we=Ie>4||Ie===0?Bm.ceil(we):Bm(we),we=jv.offset(we,(oe.V-1)*7),oe.y=we.getUTCFullYear(),oe.m=we.getUTCMonth(),oe.d=we.getUTCDate()+(oe.w+6)%7):(we=Kw(wu(oe.y,0,1)),Ie=we.getDay(),we=Ie>4||Ie===0?zm.ceil(we):zm(we),we=Zf.offset(we,(oe.V-1)*7),oe.y=we.getFullYear(),oe.m=we.getMonth(),oe.d=we.getDate()+(oe.w+6)%7)}else("W"in oe||"U"in oe)&&("w"in oe||(oe.w="u"in oe?oe.u%7:"W"in oe?1:0),Ie="Z"in oe?Xw(wu(oe.y,0,1)).getUTCDay():Kw(wu(oe.y,0,1)).getDay(),oe.m=0,oe.d="W"in oe?(oe.w+6)%7+oe.W*7-(Ie+5)%7:oe.w+oe.U*7-(Ie+6)%7);return"Z"in oe?(oe.H+=oe.Z/100|0,oe.M+=oe.Z%100,Xw(oe)):Kw(oe)}}function D(re,ve,ge,oe){for(var ke=0,we=ve.length,Ie=ge.length,Ze,lt;ke<we;){if(oe>=Ie)return-1;if(Ze=ve.charCodeAt(ke++),Ze===37){if(Ze=ve.charAt(ke++),lt=N[Ze in hP?ve.charAt(ke++):Ze],!lt||(oe=lt(re,ge,oe))<0)return-1}else if(Ze!=ge.charCodeAt(oe++))return-1}return oe}function z(re,ve,ge){var oe=h.exec(ve.slice(ge));return oe?(re.p=v.get(oe[0].toLowerCase()),ge+oe[0].length):-1}function Y(re,ve,ge){var oe=b.exec(ve.slice(ge));return oe?(re.w=O.get(oe[0].toLowerCase()),ge+oe[0].length):-1}function L(re,ve,ge){var oe=p.exec(ve.slice(ge));return oe?(re.w=g.get(oe[0].toLowerCase()),ge+oe[0].length):-1}function F(re,ve,ge){var oe=_.exec(ve.slice(ge));return oe?(re.m=A.get(oe[0].toLowerCase()),ge+oe[0].length):-1}function W(re,ve,ge){var oe=j.exec(ve.slice(ge));return oe?(re.m=x.get(oe[0].toLowerCase()),ge+oe[0].length):-1}function Q(re,ve,ge){return D(re,t,ve,ge)}function X(re,ve,ge){return D(re,n,ve,ge)}function k(re,ve,ge){return D(re,r,ve,ge)}function H(re){return l[re.getDay()]}function B(re){return o[re.getDay()]}function Z(re){return d[re.getMonth()]}function le(re){return u[re.getMonth()]}function $(re){return i[+(re.getHours()>=12)]}function V(re){return 1+~~(re.getMonth()/3)}function q(re){return l[re.getUTCDay()]}function U(re){return o[re.getUTCDay()]}function ne(re){return d[re.getUTCMonth()]}function fe(re){return u[re.getUTCMonth()]}function ie(re){return i[+(re.getUTCHours()>=12)]}function pe(re){return 1+~~(re.getUTCMonth()/3)}return{format:function(re){var ve=M(re+="",E);return ve.toString=function(){return re},ve},parse:function(re){var ve=R(re+="",!1);return ve.toString=function(){return re},ve},utcFormat:function(re){var ve=M(re+="",C);return ve.toString=function(){return re},ve},utcParse:function(re){var ve=R(re+="",!0);return ve.toString=function(){return re},ve}}}var hP={"-":"",_:" ",0:"0"},ln=/^\s*\d+/,rie=/^%/,aie=/[\\^$*+?|[\]().{}]/g;function ot(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function iie(e){return e.replace(aie,"\\$&")}function Su(e){return new RegExp("^(?:"+e.map(iie).join("|")+")","i")}function ju(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function oie(e,t,n){var r=ln.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function sie(e,t,n){var r=ln.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function lie(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function cie(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function uie(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function mP(e,t,n){var r=ln.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function pP(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function fie(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function die(e,t,n){var r=ln.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function hie(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function vP(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function mie(e,t,n){var r=ln.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function gP(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function pie(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function vie(e,t,n){var r=ln.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function gie(e,t,n){var r=ln.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function yie(e,t,n){var r=ln.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function bie(e,t,n){var r=rie.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function xie(e,t,n){var r=ln.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function wie(e,t,n){var r=ln.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function yP(e,t){return ot(e.getDate(),t,2)}function Sie(e,t){return ot(e.getHours(),t,2)}function jie(e,t){return ot(e.getHours()%12||12,t,2)}function Oie(e,t){return ot(1+Zf.count(ai(e),e),t,3)}function Oz(e,t){return ot(e.getMilliseconds(),t,3)}function _ie(e,t){return Oz(e,t)+"000"}function Eie(e,t){return ot(e.getMonth()+1,t,2)}function Aie(e,t){return ot(e.getMinutes(),t,2)}function Nie(e,t){return ot(e.getSeconds(),t,2)}function Cie(e){var t=e.getDay();return t===0?7:t}function Tie(e,t){return ot(Ov.count(ai(e)-1,e),t,2)}function _z(e){var t=e.getDay();return t>=4||t===0?Dl(e):Dl.ceil(e)}function Mie(e,t){return e=_z(e),ot(Dl.count(ai(e),e)+(ai(e).getDay()===4),t,2)}function Rie(e){return e.getDay()}function Die(e,t){return ot(zm.count(ai(e)-1,e),t,2)}function Pie(e,t){return ot(e.getFullYear()%100,t,2)}function kie(e,t){return e=_z(e),ot(e.getFullYear()%100,t,2)}function $ie(e,t){return ot(e.getFullYear()%1e4,t,4)}function Iie(e,t){var n=e.getDay();return e=n>=4||n===0?Dl(e):Dl.ceil(e),ot(e.getFullYear()%1e4,t,4)}function Lie(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ot(t/60|0,"0",2)+ot(t%60,"0",2)}function bP(e,t){return ot(e.getUTCDate(),t,2)}function zie(e,t){return ot(e.getUTCHours(),t,2)}function Bie(e,t){return ot(e.getUTCHours()%12||12,t,2)}function qie(e,t){return ot(1+jv.count(ii(e),e),t,3)}function Ez(e,t){return ot(e.getUTCMilliseconds(),t,3)}function Uie(e,t){return Ez(e,t)+"000"}function Hie(e,t){return ot(e.getUTCMonth()+1,t,2)}function Fie(e,t){return ot(e.getUTCMinutes(),t,2)}function Gie(e,t){return ot(e.getUTCSeconds(),t,2)}function Vie(e){var t=e.getUTCDay();return t===0?7:t}function Yie(e,t){return ot(_v.count(ii(e)-1,e),t,2)}function Az(e){var t=e.getUTCDay();return t>=4||t===0?Pl(e):Pl.ceil(e)}function Wie(e,t){return e=Az(e),ot(Pl.count(ii(e),e)+(ii(e).getUTCDay()===4),t,2)}function Kie(e){return e.getUTCDay()}function Xie(e,t){return ot(Bm.count(ii(e)-1,e),t,2)}function Qie(e,t){return ot(e.getUTCFullYear()%100,t,2)}function Zie(e,t){return e=Az(e),ot(e.getUTCFullYear()%100,t,2)}function Jie(e,t){return ot(e.getUTCFullYear()%1e4,t,4)}function eoe(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Pl(e):Pl.ceil(e),ot(e.getUTCFullYear()%1e4,t,4)}function toe(){return"+0000"}function xP(){return"%"}function wP(e){return+e}function SP(e){return Math.floor(+e/1e3)}var cl,Nz,Cz;noe({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 noe(e){return cl=nie(e),Nz=cl.format,cl.parse,Cz=cl.utcFormat,cl.utcParse,cl}function roe(e){return new Date(e)}function aoe(e){return e instanceof Date?+e:+new Date(+e)}function S_(e,t,n,r,i,o,l,u,d,h){var v=l_(),p=v.invert,g=v.domain,b=h(".%L"),O=h(":%S"),j=h("%I:%M"),x=h("%I %p"),_=h("%a %d"),A=h("%b %d"),E=h("%B"),C=h("%Y");function N(M){return(d(M)<M?b:u(M)<M?O:l(M)<M?j:o(M)<M?x:r(M)<M?i(M)<M?_:A:n(M)<M?E:C)(M)}return v.invert=function(M){return new Date(p(M))},v.domain=function(M){return arguments.length?g(Array.from(M,aoe)):g().map(roe)},v.ticks=function(M){var R=g();return e(R[0],R[R.length-1],M??10)},v.tickFormat=function(M,R){return R==null?N:h(R)},v.nice=function(M){var R=g();return(!M||typeof M.range!="function")&&(M=t(R[0],R[R.length-1],M??10)),M?g(pz(R,M)):v},v.copy=function(){return Qf(v,S_(e,t,n,r,i,o,l,u,d,h))},v}function ioe(){return Pr.apply(S_(eie,tie,ai,x_,Ov,Zf,y_,v_,qo,Nz).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function ooe(){return Pr.apply(S_(Zae,Jae,ii,w_,_v,jv,b_,g_,qo,Cz).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Ev(){var e=0,t=1,n,r,i,o,l=En,u=!1,d;function h(p){return p==null||isNaN(p=+p)?d:l(i===0?.5:(p=(o(p)-n)*i,u?Math.max(0,Math.min(1,p)):p))}h.domain=function(p){return arguments.length?([e,t]=p,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),h):[e,t]},h.clamp=function(p){return arguments.length?(u=!!p,h):u},h.interpolator=function(p){return arguments.length?(l=p,h):l};function v(p){return function(g){var b,O;return arguments.length?([b,O]=g,l=p(b,O),h):[l(0),l(1)]}}return h.range=v(mc),h.rangeRound=v(s_),h.unknown=function(p){return arguments.length?(d=p,h):d},function(p){return o=p,n=p(e),r=p(t),i=n===r?0:1/(r-n),h}}function so(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function Tz(){var e=oo(Ev()(En));return e.copy=function(){return so(e,Tz())},ui.apply(e,arguments)}function Mz(){var e=f_(Ev()).domain([1,10]);return e.copy=function(){return so(e,Mz()).base(e.base())},ui.apply(e,arguments)}function Rz(){var e=d_(Ev());return e.copy=function(){return so(e,Rz()).constant(e.constant())},ui.apply(e,arguments)}function j_(){var e=h_(Ev());return e.copy=function(){return so(e,j_()).exponent(e.exponent())},ui.apply(e,arguments)}function soe(){return j_.apply(null,arguments).exponent(.5)}function Dz(){var e=[],t=En;function n(r){if(r!=null&&!isNaN(r=+r))return t((Kf(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(Yi),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>Yre(e,o/r))},n.copy=function(){return Dz(t).domain(e)},ui.apply(n,arguments)}function Av(){var e=0,t=.5,n=1,r=1,i,o,l,u,d,h=En,v,p=!1,g;function b(j){return isNaN(j=+j)?g:(j=.5+((j=+v(j))-o)*(r*j<r*o?u:d),h(p?Math.max(0,Math.min(1,j)):j))}b.domain=function(j){return arguments.length?([e,t,n]=j,i=v(e=+e),o=v(t=+t),l=v(n=+n),u=i===o?0:.5/(o-i),d=o===l?0:.5/(l-o),r=o<i?-1:1,b):[e,t,n]},b.clamp=function(j){return arguments.length?(p=!!j,b):p},b.interpolator=function(j){return arguments.length?(h=j,b):h};function O(j){return function(x){var _,A,E;return arguments.length?([_,A,E]=x,h=bae(j,[_,A,E]),b):[h(0),h(.5),h(1)]}}return b.range=O(mc),b.rangeRound=O(s_),b.unknown=function(j){return arguments.length?(g=j,b):g},function(j){return v=j,i=j(e),o=j(t),l=j(n),u=i===o?0:.5/(o-i),d=o===l?0:.5/(l-o),r=o<i?-1:1,b}}function Pz(){var e=oo(Av()(En));return e.copy=function(){return so(e,Pz())},ui.apply(e,arguments)}function kz(){var e=f_(Av()).domain([.1,1,10]);return e.copy=function(){return so(e,kz()).base(e.base())},ui.apply(e,arguments)}function $z(){var e=d_(Av());return e.copy=function(){return so(e,$z()).constant(e.constant())},ui.apply(e,arguments)}function O_(){var e=h_(Av());return e.copy=function(){return so(e,O_()).exponent(e.exponent())},ui.apply(e,arguments)}function loe(){return O_.apply(null,arguments).exponent(.5)}const jP=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:rf,scaleDiverging:Pz,scaleDivergingLog:kz,scaleDivergingPow:O_,scaleDivergingSqrt:loe,scaleDivergingSymlog:$z,scaleIdentity:mz,scaleImplicit:PS,scaleLinear:Im,scaleLog:vz,scaleOrdinal:a_,scalePoint:$u,scalePow:m_,scaleQuantile:bz,scaleQuantize:xz,scaleRadial:yz,scaleSequential:Tz,scaleSequentialLog:Mz,scaleSequentialPow:j_,scaleSequentialQuantile:Dz,scaleSequentialSqrt:soe,scaleSequentialSymlog:Rz,scaleSqrt:Uae,scaleSymlog:gz,scaleThreshold:wz,scaleTime:ioe,scaleUtc:ooe,tickFormat:hz},Symbol.toStringTag,{value:"Module"}));var Qw,OP;function Iz(){if(OP)return Qw;OP=1;var e=uc();function t(n,r,i){for(var o=-1,l=n.length;++o<l;){var u=n[o],d=r(u);if(d!=null&&(h===void 0?d===d&&!e(d):i(d,h)))var h=d,v=u}return v}return Qw=t,Qw}var Zw,_P;function coe(){if(_P)return Zw;_P=1;function e(t,n){return t>n}return Zw=e,Zw}var Jw,EP;function uoe(){if(EP)return Jw;EP=1;var e=Iz(),t=coe(),n=dc();function r(i){return i&&i.length?e(i,n,t):void 0}return Jw=r,Jw}var foe=uoe();const Nv=bt(foe);var e1,AP;function doe(){if(AP)return e1;AP=1;function e(t,n){return t<n}return e1=e,e1}var t1,NP;function hoe(){if(NP)return t1;NP=1;var e=Iz(),t=doe(),n=dc();function r(i){return i&&i.length?e(i,n,t):void 0}return t1=r,t1}var moe=hoe();const Cv=bt(moe);var n1,CP;function poe(){if(CP)return n1;CP=1;var e=zO(),t=io(),n=GL(),r=Fn();function i(o,l){var u=r(o)?e:n;return u(o,t(l,3))}return n1=i,n1}var r1,TP;function voe(){if(TP)return r1;TP=1;var e=HL(),t=poe();function n(r,i){return e(t(r,i),1)}return r1=n,r1}var goe=voe();const yoe=bt(goe);var a1,MP;function boe(){if(MP)return a1;MP=1;var e=ZO();function t(n,r){return e(n,r)}return a1=t,a1}var xoe=boe();const Tv=bt(xoe);var pc=1e9,woe={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},E_,Ct=!0,Dr="[DecimalError] ",Go=Dr+"Invalid argument: ",__=Dr+"Exponent out of range: ",vc=Math.floor,Io=Math.pow,Soe=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,ar,on=1e7,Et=7,Lz=9007199254740991,qm=vc(Lz/Et),xe={};xe.absoluteValue=xe.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};xe.comparedTo=xe.cmp=function(e){var t,n,r,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1};xe.decimalPlaces=xe.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*Et;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};xe.dividedBy=xe.div=function(e){return Qa(this,new this.constructor(e))};xe.dividedToIntegerBy=xe.idiv=function(e){var t=this,n=t.constructor;return wt(Qa(t,new n(e),0,1),n.precision)};xe.equals=xe.eq=function(e){return!this.cmp(e)};xe.exponent=function(){return Vt(this)};xe.greaterThan=xe.gt=function(e){return this.cmp(e)>0};xe.greaterThanOrEqualTo=xe.gte=function(e){return this.cmp(e)>=0};xe.isInteger=xe.isint=function(){return this.e>this.d.length-2};xe.isNegative=xe.isneg=function(){return this.s<0};xe.isPositive=xe.ispos=function(){return this.s>0};xe.isZero=function(){return this.s===0};xe.lessThan=xe.lt=function(e){return this.cmp(e)<0};xe.lessThanOrEqualTo=xe.lte=function(e){return this.cmp(e)<1};xe.logarithm=xe.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(ar))throw Error(Dr+"NaN");if(n.s<1)throw Error(Dr+(n.s?"NaN":"-Infinity"));return n.eq(ar)?new r(0):(Ct=!1,t=Qa(cf(n,o),cf(e,o),o),Ct=!0,wt(t,i))};xe.minus=xe.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?qz(t,e):zz(t,(e.s=-e.s,e))};xe.modulo=xe.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(Dr+"NaN");return n.s?(Ct=!1,t=Qa(n,e,0,1).times(e),Ct=!0,n.minus(t)):wt(new r(n),i)};xe.naturalExponential=xe.exp=function(){return Bz(this)};xe.naturalLogarithm=xe.ln=function(){return cf(this)};xe.negated=xe.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};xe.plus=xe.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?zz(t,e):qz(t,(e.s=-e.s,e))};xe.precision=xe.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Go+e);if(t=Vt(i)+1,r=i.d.length-1,n=r*Et+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n};xe.squareRoot=xe.sqrt=function(){var e,t,n,r,i,o,l,u=this,d=u.constructor;if(u.s<1){if(!u.s)return new d(0);throw Error(Dr+"NaN")}for(e=Vt(u),Ct=!1,i=Math.sqrt(+u),i==0||i==1/0?(t=ca(u.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=vc((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),r=new d(t)):r=new d(i.toString()),n=d.precision,i=l=n+3;;)if(o=r,r=o.plus(Qa(u,o,l+2)).times(.5),ca(o.d).slice(0,l)===(t=ca(r.d)).slice(0,l)){if(t=t.slice(l-3,l+1),i==l&&t=="4999"){if(wt(o,n+1,0),o.times(o).eq(u)){r=o;break}}else if(t!="9999")break;l+=4}return Ct=!0,wt(r,n)};xe.times=xe.mul=function(e){var t,n,r,i,o,l,u,d,h,v=this,p=v.constructor,g=v.d,b=(e=new p(e)).d;if(!v.s||!e.s)return new p(0);for(e.s*=v.s,n=v.e+e.e,d=g.length,h=b.length,d<h&&(o=g,g=b,b=o,l=d,d=h,h=l),o=[],l=d+h,r=l;r--;)o.push(0);for(r=h;--r>=0;){for(t=0,i=d+r;i>r;)u=o[i]+b[r]*g[i-r-1]+t,o[i--]=u%on|0,t=u/on|0;o[i]=(o[i]+t)%on|0}for(;!o[--l];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,Ct?wt(e,p.precision):e};xe.toDecimalPlaces=xe.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(ya(e,0,pc),t===void 0?t=r.rounding:ya(t,0,8),wt(n,e+Vt(n)+1,t))};xe.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=Jo(r,!0):(ya(e,0,pc),t===void 0?t=i.rounding:ya(t,0,8),r=wt(new i(r),e+1,t),n=Jo(r,!0,e+1)),n};xe.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?Jo(i):(ya(e,0,pc),t===void 0?t=o.rounding:ya(t,0,8),r=wt(new o(i),e+Vt(i)+1,t),n=Jo(r.abs(),!1,e+Vt(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};xe.toInteger=xe.toint=function(){var e=this,t=e.constructor;return wt(new t(e),Vt(e)+1,t.rounding)};xe.toNumber=function(){return+this};xe.toPower=xe.pow=function(e){var t,n,r,i,o,l,u=this,d=u.constructor,h=12,v=+(e=new d(e));if(!e.s)return new d(ar);if(u=new d(u),!u.s){if(e.s<1)throw Error(Dr+"Infinity");return u}if(u.eq(ar))return u;if(r=d.precision,e.eq(ar))return wt(u,r);if(t=e.e,n=e.d.length-1,l=t>=n,o=u.s,l){if((n=v<0?-v:v)<=Lz){for(i=new d(ar),t=Math.ceil(r/Et+4),Ct=!1;n%2&&(i=i.times(u),DP(i.d,t)),n=vc(n/2),n!==0;)u=u.times(u),DP(u.d,t);return Ct=!0,e.s<0?new d(ar).div(i):wt(i,r)}}else if(o<0)throw Error(Dr+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,u.s=1,Ct=!1,i=e.times(cf(u,r+h)),Ct=!0,i=Bz(i),i.s=o,i};xe.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=Vt(i),r=Jo(i,n<=o.toExpNeg||n>=o.toExpPos)):(ya(e,1,pc),t===void 0?t=o.rounding:ya(t,0,8),i=wt(new o(i),e,t),n=Vt(i),r=Jo(i,e<=n||n<=o.toExpNeg,e)),r};xe.toSignificantDigits=xe.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(ya(e,1,pc),t===void 0?t=r.rounding:ya(t,0,8)),wt(new r(n),e,t)};xe.toString=xe.valueOf=xe.val=xe.toJSON=xe[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=Vt(e),n=e.constructor;return Jo(e,t<=n.toExpNeg||t>=n.toExpPos)};function zz(e,t){var n,r,i,o,l,u,d,h,v=e.constructor,p=v.precision;if(!e.s||!t.s)return t.s||(t=new v(e)),Ct?wt(t,p):t;if(d=e.d,h=t.d,l=e.e,i=t.e,d=d.slice(),o=l-i,o){for(o<0?(r=d,o=-o,u=h.length):(r=h,i=l,u=d.length),l=Math.ceil(p/Et),u=l>u?l+1:u+1,o>u&&(o=u,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(u=d.length,o=h.length,u-o<0&&(o=u,r=h,h=d,d=r),n=0;o;)n=(d[--o]=d[o]+h[o]+n)/on|0,d[o]%=on;for(n&&(d.unshift(n),++i),u=d.length;d[--u]==0;)d.pop();return t.d=d,t.e=i,Ct?wt(t,p):t}function ya(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Go+e)}function ca(e){var t,n,r,i=e.length-1,o="",l=e[0];if(i>0){for(o+=l,t=1;t<i;t++)r=e[t]+"",n=Et-r.length,n&&(o+=Ui(n)),o+=r;l=e[t],r=l+"",n=Et-r.length,n&&(o+=Ui(n))}else if(l===0)return"0";for(;l%10===0;)l/=10;return o+l}var Qa=(function(){function e(r,i){var o,l=0,u=r.length;for(r=r.slice();u--;)o=r[u]*i+l,r[u]=o%on|0,l=o/on|0;return l&&r.unshift(l),r}function t(r,i,o,l){var u,d;if(o!=l)d=o>l?1:-1;else for(u=d=0;u<o;u++)if(r[u]!=i[u]){d=r[u]>i[u]?1:-1;break}return d}function n(r,i,o){for(var l=0;o--;)r[o]-=l,l=r[o]<i[o]?1:0,r[o]=l*on+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,l){var u,d,h,v,p,g,b,O,j,x,_,A,E,C,N,M,R,D,z=r.constructor,Y=r.s==i.s?1:-1,L=r.d,F=i.d;if(!r.s)return new z(r);if(!i.s)throw Error(Dr+"Division by zero");for(d=r.e-i.e,R=F.length,N=L.length,b=new z(Y),O=b.d=[],h=0;F[h]==(L[h]||0);)++h;if(F[h]>(L[h]||0)&&--d,o==null?A=o=z.precision:l?A=o+(Vt(r)-Vt(i))+1:A=o,A<0)return new z(0);if(A=A/Et+2|0,h=0,R==1)for(v=0,F=F[0],A++;(h<N||v)&&A--;h++)E=v*on+(L[h]||0),O[h]=E/F|0,v=E%F|0;else{for(v=on/(F[0]+1)|0,v>1&&(F=e(F,v),L=e(L,v),R=F.length,N=L.length),C=R,j=L.slice(0,R),x=j.length;x<R;)j[x++]=0;D=F.slice(),D.unshift(0),M=F[0],F[1]>=on/2&&++M;do v=0,u=t(F,j,R,x),u<0?(_=j[0],R!=x&&(_=_*on+(j[1]||0)),v=_/M|0,v>1?(v>=on&&(v=on-1),p=e(F,v),g=p.length,x=j.length,u=t(p,j,g,x),u==1&&(v--,n(p,R<g?D:F,g))):(v==0&&(u=v=1),p=F.slice()),g=p.length,g<x&&p.unshift(0),n(j,p,x),u==-1&&(x=j.length,u=t(F,j,R,x),u<1&&(v++,n(j,R<x?D:F,x))),x=j.length):u===0&&(v++,j=[0]),O[h++]=v,u&&j[0]?j[x++]=L[C]||0:(j=[L[C]],x=1);while((C++<N||j[0]!==void 0)&&A--)}return O[0]||O.shift(),b.e=d,wt(b,l?o+Vt(b)+1:o)}})();function Bz(e,t){var n,r,i,o,l,u,d=0,h=0,v=e.constructor,p=v.precision;if(Vt(e)>16)throw Error(__+Vt(e));if(!e.s)return new v(ar);for(Ct=!1,u=p,l=new v(.03125);e.abs().gte(.1);)e=e.times(l),h+=5;for(r=Math.log(Io(2,h))/Math.LN10*2+5|0,u+=r,n=i=o=new v(ar),v.precision=u;;){if(i=wt(i.times(e),u),n=n.times(++d),l=o.plus(Qa(i,n,u)),ca(l.d).slice(0,u)===ca(o.d).slice(0,u)){for(;h--;)o=wt(o.times(o),u);return v.precision=p,t==null?(Ct=!0,wt(o,p)):o}o=l}}function Vt(e){for(var t=e.e*Et,n=e.d[0];n>=10;n/=10)t++;return t}function i1(e,t,n){if(t>e.LN10.sd())throw Ct=!0,n&&(e.precision=n),Error(Dr+"LN10 precision limit exceeded");return wt(new e(e.LN10),t)}function Ui(e){for(var t="";e--;)t+="0";return t}function cf(e,t){var n,r,i,o,l,u,d,h,v,p=1,g=10,b=e,O=b.d,j=b.constructor,x=j.precision;if(b.s<1)throw Error(Dr+(b.s?"NaN":"-Infinity"));if(b.eq(ar))return new j(0);if(t==null?(Ct=!1,h=x):h=t,b.eq(10))return t==null&&(Ct=!0),i1(j,h);if(h+=g,j.precision=h,n=ca(O),r=n.charAt(0),o=Vt(b),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)b=b.times(e),n=ca(b.d),r=n.charAt(0),p++;o=Vt(b),r>1?(b=new j("0."+n),o++):b=new j(r+"."+n.slice(1))}else return d=i1(j,h+2,x).times(o+""),b=cf(new j(r+"."+n.slice(1)),h-g).plus(d),j.precision=x,t==null?(Ct=!0,wt(b,x)):b;for(u=l=b=Qa(b.minus(ar),b.plus(ar),h),v=wt(b.times(b),h),i=3;;){if(l=wt(l.times(v),h),d=u.plus(Qa(l,new j(i),h)),ca(d.d).slice(0,h)===ca(u.d).slice(0,h))return u=u.times(2),o!==0&&(u=u.plus(i1(j,h+2,x).times(o+""))),u=Qa(u,new j(p),h),j.precision=x,t==null?(Ct=!0,wt(u,x)):u;u=d,i+=2}}function RP(e,t){var n,r,i;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=vc(n/Et),e.d=[],r=(n+1)%Et,n<0&&(r+=Et),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=Et;r<i;)e.d.push(+t.slice(r,r+=Et));t=t.slice(r),r=Et-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),Ct&&(e.e>qm||e.e<-qm))throw Error(__+n)}else e.s=0,e.e=0,e.d=[0];return e}function wt(e,t,n){var r,i,o,l,u,d,h,v,p=e.d;for(l=1,o=p[0];o>=10;o/=10)l++;if(r=t-l,r<0)r+=Et,i=t,h=p[v=0];else{if(v=Math.ceil((r+1)/Et),o=p.length,v>=o)return e;for(h=o=p[v],l=1;o>=10;o/=10)l++;r%=Et,i=r-Et+l}if(n!==void 0&&(o=Io(10,l-i-1),u=h/o%10|0,d=t<0||p[v+1]!==void 0||h%o,d=n<4?(u||d)&&(n==0||n==(e.s<0?3:2)):u>5||u==5&&(n==4||d||n==6&&(r>0?i>0?h/Io(10,l-i):0:p[v-1])%10&1||n==(e.s<0?8:7))),t<1||!p[0])return d?(o=Vt(e),p.length=1,t=t-o-1,p[0]=Io(10,(Et-t%Et)%Et),e.e=vc(-t/Et)||0):(p.length=1,p[0]=e.e=e.s=0),e;if(r==0?(p.length=v,o=1,v--):(p.length=v+1,o=Io(10,Et-r),p[v]=i>0?(h/Io(10,l-i)%Io(10,i)|0)*o:0),d)for(;;)if(v==0){(p[0]+=o)==on&&(p[0]=1,++e.e);break}else{if(p[v]+=o,p[v]!=on)break;p[v--]=0,o=1}for(r=p.length;p[--r]===0;)p.pop();if(Ct&&(e.e>qm||e.e<-qm))throw Error(__+Vt(e));return e}function qz(e,t){var n,r,i,o,l,u,d,h,v,p,g=e.constructor,b=g.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new g(e),Ct?wt(t,b):t;if(d=e.d,p=t.d,r=t.e,h=e.e,d=d.slice(),l=h-r,l){for(v=l<0,v?(n=d,l=-l,u=p.length):(n=p,r=h,u=d.length),i=Math.max(Math.ceil(b/Et),u)+2,l>i&&(l=i,n.length=1),n.reverse(),i=l;i--;)n.push(0);n.reverse()}else{for(i=d.length,u=p.length,v=i<u,v&&(u=i),i=0;i<u;i++)if(d[i]!=p[i]){v=d[i]<p[i];break}l=0}for(v&&(n=d,d=p,p=n,t.s=-t.s),u=d.length,i=p.length-u;i>0;--i)d[u++]=0;for(i=p.length;i>l;){if(d[--i]<p[i]){for(o=i;o&&d[--o]===0;)d[o]=on-1;--d[o],d[i]+=on}d[i]-=p[i]}for(;d[--u]===0;)d.pop();for(;d[0]===0;d.shift())--r;return d[0]?(t.d=d,t.e=r,Ct?wt(t,b):t):new g(0)}function Jo(e,t,n){var r,i=Vt(e),o=ca(e.d),l=o.length;return t?(n&&(r=n-l)>0?o=o.charAt(0)+"."+o.slice(1)+Ui(r):l>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+Ui(-i-1)+o,n&&(r=n-l)>0&&(o+=Ui(r))):i>=l?(o+=Ui(i+1-l),n&&(r=n-i-1)>0&&(o=o+"."+Ui(r))):((r=i+1)<l&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-l)>0&&(i+1===l&&(o+="."),o+=Ui(r))),e.s<0?"-"+o:o}function DP(e,t){if(e.length>t)return e.length=t,!0}function Uz(e){var t,n,r;function i(o){var l=this;if(!(l instanceof i))return new i(o);if(l.constructor=i,o instanceof i){l.s=o.s,l.e=o.e,l.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Go+o);if(o>0)l.s=1;else if(o<0)o=-o,l.s=-1;else{l.s=0,l.e=0,l.d=[0];return}if(o===~~o&&o<1e7){l.e=0,l.d=[o];return}return RP(l,o.toString())}else if(typeof o!="string")throw Error(Go+o);if(o.charCodeAt(0)===45?(o=o.slice(1),l.s=-1):l.s=1,Soe.test(o))RP(l,o);else throw Error(Go+o)}if(i.prototype=xe,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=Uz,i.config=i.set=joe,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function joe(e){if(!e||typeof e!="object")throw Error(Dr+"Object expected");var t,n,r,i=["precision",1,pc,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(vc(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(Go+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Go+n+": "+r);return this}var E_=Uz(woe);ar=new E_(1);const yt=E_;function Ooe(e){return Noe(e)||Aoe(e)||Eoe(e)||_oe()}function _oe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
412
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Eoe(e,t){if(e){if(typeof e=="string")return LS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return LS(e,t)}}function Aoe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Noe(e){if(Array.isArray(e))return LS(e)}function LS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Coe=function(t){return t},Hz={},Fz=function(t){return t===Hz},PP=function(t){return function n(){return arguments.length===0||arguments.length===1&&Fz(arguments.length<=0?void 0:arguments[0])?n:t.apply(void 0,arguments)}},Toe=function e(t,n){return t===1?n:PP(function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];var l=i.filter(function(u){return u!==Hz}).length;return l>=t?n.apply(void 0,i):e(t-l,PP(function(){for(var u=arguments.length,d=new Array(u),h=0;h<u;h++)d[h]=arguments[h];var v=i.map(function(p){return Fz(p)?d.shift():p});return n.apply(void 0,Ooe(v).concat(d))}))})},Mv=function(t){return Toe(t.length,t)},zS=function(t,n){for(var r=[],i=t;i<n;++i)r[i-t]=i;return r},Moe=Mv(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(n){return t[n]}).map(e)}),Roe=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return Coe;var i=n.reverse(),o=i[0],l=i.slice(1);return function(){return l.reduce(function(u,d){return d(u)},o.apply(void 0,arguments))}},BS=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},Gz=function(t){var n=null,r=null;return function(){for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];return n&&o.every(function(u,d){return u===n[d]})||(n=o,r=t.apply(void 0,o)),r}};function Doe(e){var t;return e===0?t=1:t=Math.floor(new yt(e).abs().log(10).toNumber())+1,t}function Poe(e,t,n){for(var r=new yt(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}var koe=Mv(function(e,t,n){var r=+e,i=+t;return r+n*(i-r)}),$oe=Mv(function(e,t,n){var r=t-+e;return r=r||1/0,(n-e)/r}),Ioe=Mv(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});const Rv={rangeStep:Poe,getDigitCount:Doe,interpolateNumber:koe,uninterpolateNumber:$oe,uninterpolateTruncation:Ioe};function qS(e){return Boe(e)||zoe(e)||Vz(e)||Loe()}function Loe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
413
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zoe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Boe(e){if(Array.isArray(e))return US(e)}function uf(e,t){return Hoe(e)||Uoe(e,t)||Vz(e,t)||qoe()}function qoe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
414
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Vz(e,t){if(e){if(typeof e=="string")return US(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return US(e,t)}}function US(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Uoe(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,o=void 0;try{for(var l=e[Symbol.iterator](),u;!(r=(u=l.next()).done)&&(n.push(u.value),!(t&&n.length===t));r=!0);}catch(d){i=!0,o=d}finally{try{!r&&l.return!=null&&l.return()}finally{if(i)throw o}}return n}}function Hoe(e){if(Array.isArray(e))return e}function Yz(e){var t=uf(e,2),n=t[0],r=t[1],i=n,o=r;return n>r&&(i=r,o=n),[i,o]}function Wz(e,t,n){if(e.lte(0))return new yt(0);var r=Rv.getDigitCount(e.toNumber()),i=new yt(10).pow(r),o=e.div(i),l=r!==1?.05:.1,u=new yt(Math.ceil(o.div(l).toNumber())).add(n).mul(l),d=u.mul(i);return t?d:new yt(Math.ceil(d))}function Foe(e,t,n){var r=1,i=new yt(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new yt(10).pow(Rv.getDigitCount(e)-1),i=new yt(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new yt(Math.floor(e)))}else e===0?i=new yt(Math.floor((t-1)/2)):n||(i=new yt(Math.floor(e)));var l=Math.floor((t-1)/2),u=Roe(Moe(function(d){return i.add(new yt(d-l).mul(r)).toNumber()}),zS);return u(0,t)}function Kz(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new yt(0),tickMin:new yt(0),tickMax:new yt(0)};var o=Wz(new yt(t).sub(e).div(n-1),r,i),l;e<=0&&t>=0?l=new yt(0):(l=new yt(e).add(t).div(2),l=l.sub(new yt(l).mod(o)));var u=Math.ceil(l.sub(e).div(o).toNumber()),d=Math.ceil(new yt(t).sub(l).div(o).toNumber()),h=u+d+1;return h>n?Kz(e,t,n,r,i+1):(h<n&&(d=t>0?d+(n-h):d,u=t>0?u:u+(n-h)),{step:o,tickMin:l.sub(new yt(u).mul(o)),tickMax:l.add(new yt(d).mul(o))})}function Goe(e){var t=uf(e,2),n=t[0],r=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,l=Math.max(i,2),u=Yz([n,r]),d=uf(u,2),h=d[0],v=d[1];if(h===-1/0||v===1/0){var p=v===1/0?[h].concat(qS(zS(0,i-1).map(function(){return 1/0}))):[].concat(qS(zS(0,i-1).map(function(){return-1/0})),[v]);return n>r?BS(p):p}if(h===v)return Foe(h,i,o);var g=Kz(h,v,l,o),b=g.step,O=g.tickMin,j=g.tickMax,x=Rv.rangeStep(O,j.add(new yt(.1).mul(b)),b);return n>r?BS(x):x}function Voe(e,t){var n=uf(e,2),r=n[0],i=n[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,l=Yz([r,i]),u=uf(l,2),d=u[0],h=u[1];if(d===-1/0||h===1/0)return[r,i];if(d===h)return[d];var v=Math.max(t,2),p=Wz(new yt(h).sub(d).div(v-1),o,0),g=[].concat(qS(Rv.rangeStep(new yt(d),new yt(h).sub(new yt(.99).mul(p)),p)),[h]);return r>i?BS(g):g}var Yoe=Gz(Goe),Woe=Gz(Voe),Koe="Invariant failed";function es(e,t){throw new Error(Koe)}var Xoe=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function kl(e){"@babel/helpers - typeof";return kl=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},kl(e)}function Um(){return Um=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Um.apply(this,arguments)}function Qoe(e,t){return tse(e)||ese(e,t)||Joe(e,t)||Zoe()}function Zoe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
415
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Joe(e,t){if(e){if(typeof e=="string")return kP(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return kP(e,t)}}function kP(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function ese(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function tse(e){if(Array.isArray(e))return e}function nse(e,t){if(e==null)return{};var n=rse(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function rse(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ase(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ise(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Zz(r.key),r)}}function ose(e,t,n){return t&&ise(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function sse(e,t,n){return t=Hm(t),lse(e,Xz()?Reflect.construct(t,n||[],Hm(e).constructor):t.apply(e,n))}function lse(e,t){if(t&&(kl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return cse(e)}function cse(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Xz(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Xz=function(){return!!e})()}function Hm(e){return Hm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Hm(e)}function use(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&&HS(e,t)}function HS(e,t){return HS=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},HS(e,t)}function Qz(e,t,n){return t=Zz(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zz(e){var t=fse(e,"string");return kl(t)=="symbol"?t:t+""}function fse(e,t){if(kl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(kl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Jf=(function(e){function t(){return ase(this,t),sse(this,t,arguments)}return use(t,e),ose(t,[{key:"render",value:function(){var r=this.props,i=r.offset,o=r.layout,l=r.width,u=r.dataKey,d=r.data,h=r.dataPointFormatter,v=r.xAxis,p=r.yAxis,g=nse(r,Xoe),b=nt(g,!1);this.props.direction==="x"&&v.type!=="number"&&es();var O=d.map(function(j){var x=h(j,u),_=x.x,A=x.y,E=x.value,C=x.errorVal;if(!C)return null;var N=[],M,R;if(Array.isArray(C)){var D=Qoe(C,2);M=D[0],R=D[1]}else M=R=C;if(o==="vertical"){var z=v.scale,Y=A+i,L=Y+l,F=Y-l,W=z(E-M),Q=z(E+R);N.push({x1:Q,y1:L,x2:Q,y2:F}),N.push({x1:W,y1:Y,x2:Q,y2:Y}),N.push({x1:W,y1:L,x2:W,y2:F})}else if(o==="horizontal"){var X=p.scale,k=_+i,H=k-l,B=k+l,Z=X(E-M),le=X(E+R);N.push({x1:H,y1:le,x2:B,y2:le}),N.push({x1:k,y1:Z,x2:k,y2:le}),N.push({x1:H,y1:Z,x2:B,y2:Z})}return I.createElement(zt,Um({className:"recharts-errorBar",key:"bar-".concat(N.map(function($){return"".concat($.x1,"-").concat($.x2,"-").concat($.y1,"-").concat($.y2)}))},b),N.map(function($){return I.createElement("line",Um({},$,{key:"line-".concat($.x1,"-").concat($.x2,"-").concat($.y1,"-").concat($.y2)}))}))});return I.createElement(zt,{className:"recharts-errorBars"},O)}}])})(I.Component);Qz(Jf,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});Qz(Jf,"displayName","ErrorBar");function ff(e){"@babel/helpers - typeof";return ff=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},ff(e)}function $P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Po(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$P(Object(n),!0).forEach(function(r){dse(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$P(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function dse(e,t,n){return t=hse(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hse(e){var t=mse(e,"string");return ff(t)=="symbol"?t:t+""}function mse(e,t){if(ff(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ff(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Jz=function(t){var n=t.children,r=t.formattedGraphicalItems,i=t.legendWidth,o=t.legendContent,l=nr(n,Xa);if(!l)return null;var u=Xa.defaultProps,d=u!==void 0?Po(Po({},u),l.props):{},h;return l.props&&l.props.payload?h=l.props&&l.props.payload:o==="children"?h=(r||[]).reduce(function(v,p){var g=p.item,b=p.props,O=b.sectors||b.data||[];return v.concat(O.map(function(j){return{type:l.props.iconType||g.props.legendType,value:j.name,color:j.fill,payload:j}}))},[]):h=(r||[]).map(function(v){var p=v.item,g=p.type.defaultProps,b=g!==void 0?Po(Po({},g),p.props):{},O=b.dataKey,j=b.name,x=b.legendType,_=b.hide;return{inactive:_,dataKey:O,type:d.iconType||x||"square",color:A_(p),value:j||O,payload:b}}),Po(Po(Po({},d),Xa.getWithHeight(l,i)),{},{payload:h,item:l})};function df(e){"@babel/helpers - typeof";return df=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},df(e)}function IP(e){return yse(e)||gse(e)||vse(e)||pse()}function pse(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
416
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vse(e,t){if(e){if(typeof e=="string")return FS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return FS(e,t)}}function gse(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function yse(e){if(Array.isArray(e))return FS(e)}function FS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function LP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function kt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?LP(Object(n),!0).forEach(function(r){Sl(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):LP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Sl(e,t,n){return t=bse(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bse(e){var t=xse(e,"string");return df(t)=="symbol"?t:t+""}function xse(e,t){if(df(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(df(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function lr(e,t,n){return Qe(e)||Qe(t)?n:Zt(t)?Tr(e,t,n):Ye(t)?t(e):n}function Iu(e,t,n,r){var i=yoe(e,function(u){return lr(u,t)});if(n==="number"){var o=i.filter(function(u){return be(u)||parseFloat(u)});return o.length?[Cv(o),Nv(o)]:[1/0,-1/0]}var l=r?i.filter(function(u){return!Qe(u)}):i;return l.map(function(u){return Zt(u)||u instanceof Date?u:""})}var wse=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,l=-1,u=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(u<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var d=o.range,h=0;h<u;h++){var v=h>0?i[h-1].coordinate:i[u-1].coordinate,p=i[h].coordinate,g=h>=u-1?i[0].coordinate:i[h+1].coordinate,b=void 0;if(Vr(p-v)!==Vr(g-p)){var O=[];if(Vr(g-p)===Vr(d[1]-d[0])){b=g;var j=p+d[1]-d[0];O[0]=Math.min(j,(j+v)/2),O[1]=Math.max(j,(j+v)/2)}else{b=v;var x=g+d[1]-d[0];O[0]=Math.min(p,(x+p)/2),O[1]=Math.max(p,(x+p)/2)}var _=[Math.min(p,(b+p)/2),Math.max(p,(b+p)/2)];if(t>_[0]&&t<=_[1]||t>=O[0]&&t<=O[1]){l=i[h].index;break}}else{var A=Math.min(v,g),E=Math.max(v,g);if(t>(A+p)/2&&t<=(E+p)/2){l=i[h].index;break}}}else for(var C=0;C<u;C++)if(C===0&&t<=(r[C].coordinate+r[C+1].coordinate)/2||C>0&&C<u-1&&t>(r[C].coordinate+r[C-1].coordinate)/2&&t<=(r[C].coordinate+r[C+1].coordinate)/2||C===u-1&&t>(r[C].coordinate+r[C-1].coordinate)/2){l=r[C].index;break}return l},A_=function(t){var n,r=t,i=r.type.displayName,o=(n=t.type)!==null&&n!==void 0&&n.defaultProps?kt(kt({},t.type.defaultProps),t.props):t.props,l=o.stroke,u=o.fill,d;switch(i){case"Line":d=l;break;case"Area":case"Radar":d=l&&l!=="none"?l:u;break;default:d=u;break}return d},Sse=function(t){var n=t.barSize,r=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var l={},u=Object.keys(o),d=0,h=u.length;d<h;d++)for(var v=o[u[d]].stackGroups,p=Object.keys(v),g=0,b=p.length;g<b;g++){var O=v[p[g]],j=O.items,x=O.cateAxisId,_=j.filter(function(R){return Wa(R.type).indexOf("Bar")>=0});if(_&&_.length){var A=_[0].type.defaultProps,E=A!==void 0?kt(kt({},A),_[0].props):_[0].props,C=E.barSize,N=E[x];l[N]||(l[N]=[]);var M=Qe(C)?n:C;l[N].push({item:_[0],stackList:_.slice(1),barSize:Qe(M)?void 0:Zo(M,r,0)})}}return l},jse=function(t){var n=t.barGap,r=t.barCategoryGap,i=t.bandSize,o=t.sizeList,l=o===void 0?[]:o,u=t.maxBarSize,d=l.length;if(d<1)return null;var h=Zo(n,i,0,!0),v,p=[];if(l[0].barSize===+l[0].barSize){var g=!1,b=i/d,O=l.reduce(function(C,N){return C+N.barSize||0},0);O+=(d-1)*h,O>=i&&(O-=(d-1)*h,h=0),O>=i&&b>0&&(g=!0,b*=.9,O=d*b);var j=(i-O)/2>>0,x={offset:j-h,size:0};v=l.reduce(function(C,N){var M={item:N.item,position:{offset:x.offset+x.size+h,size:g?b:N.barSize}},R=[].concat(IP(C),[M]);return x=R[R.length-1].position,N.stackList&&N.stackList.length&&N.stackList.forEach(function(D){R.push({item:D,position:x})}),R},p)}else{var _=Zo(r,i,0,!0);i-2*_-(d-1)*h<=0&&(h=0);var A=(i-2*_-(d-1)*h)/d;A>1&&(A>>=0);var E=u===+u?Math.min(A,u):A;v=l.reduce(function(C,N,M){var R=[].concat(IP(C),[{item:N.item,position:{offset:_+(A+h)*M+(A-E)/2,size:E}}]);return N.stackList&&N.stackList.length&&N.stackList.forEach(function(D){R.push({item:D,position:R[R.length-1].position})}),R},p)}return v},Ose=function(t,n,r,i){var o=r.children,l=r.width,u=r.margin,d=l-(u.left||0)-(u.right||0),h=Jz({children:o,legendWidth:d});if(h){var v=i||{},p=v.width,g=v.height,b=h.align,O=h.verticalAlign,j=h.layout;if((j==="vertical"||j==="horizontal"&&O==="middle")&&b!=="center"&&be(t[b]))return kt(kt({},t),{},Sl({},b,t[b]+(p||0)));if((j==="horizontal"||j==="vertical"&&b==="center")&&O!=="middle"&&be(t[O]))return kt(kt({},t),{},Sl({},O,t[O]+(g||0)))}return t},_se=function(t,n,r){return Qe(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},eB=function(t,n,r,i,o){var l=n.props.children,u=Mr(l,Jf).filter(function(h){return _se(i,o,h.props.direction)});if(u&&u.length){var d=u.map(function(h){return h.props.dataKey});return t.reduce(function(h,v){var p=lr(v,r);if(Qe(p))return h;var g=Array.isArray(p)?[Cv(p),Nv(p)]:[p,p],b=d.reduce(function(O,j){var x=lr(v,j,0),_=g[0]-Math.abs(Array.isArray(x)?x[0]:x),A=g[1]+Math.abs(Array.isArray(x)?x[1]:x);return[Math.min(_,O[0]),Math.max(A,O[1])]},[1/0,-1/0]);return[Math.min(b[0],h[0]),Math.max(b[1],h[1])]},[1/0,-1/0])}return null},Ese=function(t,n,r,i,o){var l=n.map(function(u){return eB(t,u,r,o,i)}).filter(function(u){return!Qe(u)});return l&&l.length?l.reduce(function(u,d){return[Math.min(u[0],d[0]),Math.max(u[1],d[1])]},[1/0,-1/0]):null},tB=function(t,n,r,i,o){var l=n.map(function(d){var h=d.props.dataKey;return r==="number"&&h&&eB(t,d,h,i)||Iu(t,h,r,o)});if(r==="number")return l.reduce(function(d,h){return[Math.min(d[0],h[0]),Math.max(d[1],h[1])]},[1/0,-1/0]);var u={};return l.reduce(function(d,h){for(var v=0,p=h.length;v<p;v++)u[h[v]]||(u[h[v]]=!0,d.push(h[v]));return d},[])},nB=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},rB=function(t,n,r,i){if(i)return t.map(function(d){return d.coordinate});var o,l,u=t.map(function(d){return d.coordinate===n&&(o=!0),d.coordinate===r&&(l=!0),d.coordinate});return o||u.push(n),l||u.push(r),u},Va=function(t,n,r){if(!t)return null;var i=t.scale,o=t.duplicateDomain,l=t.type,u=t.range,d=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,h=(n||r)&&l==="category"&&i.bandwidth?i.bandwidth()/d:0;if(h=t.axisType==="angleAxis"&&(u==null?void 0:u.length)>=2?Vr(u[0]-u[1])*2*h:h,n&&(t.ticks||t.niceTicks)){var v=(t.ticks||t.niceTicks).map(function(p){var g=o?o.indexOf(p):p;return{coordinate:i(g)+h,value:p,offset:h}});return v.filter(function(p){return!Vf(p.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(p,g){return{coordinate:i(p)+h,value:p,index:g,offset:h}}):i.ticks&&!r?i.ticks(t.tickCount).map(function(p){return{coordinate:i(p)+h,value:p,offset:h}}):i.domain().map(function(p,g){return{coordinate:i(p)+h,value:o?o[p]:p,index:g,offset:h}})},o1=new WeakMap,Dh=function(t,n){if(typeof n!="function")return t;o1.has(t)||o1.set(t,new WeakMap);var r=o1.get(t);if(r.has(n))return r.get(n);var i=function(){t.apply(void 0,arguments),n.apply(void 0,arguments)};return r.set(n,i),i},Ase=function(t,n,r){var i=t.scale,o=t.type,l=t.layout,u=t.axisType;if(i==="auto")return l==="radial"&&u==="radiusAxis"?{scale:rf(),realScaleType:"band"}:l==="radial"&&u==="angleAxis"?{scale:Im(),realScaleType:"linear"}:o==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:$u(),realScaleType:"point"}:o==="category"?{scale:rf(),realScaleType:"band"}:{scale:Im(),realScaleType:"linear"};if(Qo(i)){var d="scale".concat(pv(i));return{scale:(jP[d]||$u)(),realScaleType:jP[d]?d:"point"}}return Ye(i)?{scale:i}:{scale:$u(),realScaleType:"point"}},zP=1e-4,Nse=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,i=t.range(),o=Math.min(i[0],i[1])-zP,l=Math.max(i[0],i[1])+zP,u=t(n[0]),d=t(n[r-1]);(u<o||u>l||d<o||d>l)&&t.domain([n[0],n[r-1]])}},Cse=function(t,n){if(!t)return null;for(var r=0,i=t.length;r<i;r++)if(t[r].item===n)return t[r].position;return null},Tse=function(t,n){if(!n||n.length!==2||!be(n[0])||!be(n[1]))return t;var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]),o=[t[0],t[1]];return(!be(t[0])||t[0]<r)&&(o[0]=r),(!be(t[1])||t[1]>i)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]<r&&(o[1]=r),o},Mse=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,l=0,u=0;u<n;++u){var d=Vf(t[u][r][1])?t[u][r][0]:t[u][r][1];d>=0?(t[u][r][0]=o,t[u][r][1]=o+d,o=t[u][r][1]):(t[u][r][0]=l,t[u][r][1]=l+d,l=t[u][r][1])}},Rse=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,l=0;l<n;++l){var u=Vf(t[l][r][1])?t[l][r][0]:t[l][r][1];u>=0?(t[l][r][0]=o,t[l][r][1]=o+u,o=t[l][r][1]):(t[l][r][0]=0,t[l][r][1]=0)}},Dse={sign:Mse,expand:vee,none:Al,silhouette:gee,wiggle:yee,positive:Rse},Pse=function(t,n,r){var i=n.map(function(u){return u.props.dataKey}),o=Dse[r],l=pee().keys(i).value(function(u,d){return+lr(u,d,0)}).order(xS).offset(o);return l(t)},kse=function(t,n,r,i,o,l){if(!t)return null;var u=l?n.reverse():n,d={},h=u.reduce(function(p,g){var b,O=(b=g.type)!==null&&b!==void 0&&b.defaultProps?kt(kt({},g.type.defaultProps),g.props):g.props,j=O.stackId,x=O.hide;if(x)return p;var _=O[r],A=p[_]||{hasStack:!1,stackGroups:{}};if(Zt(j)){var E=A.stackGroups[j]||{numericAxisId:r,cateAxisId:i,items:[]};E.items.push(g),A.hasStack=!0,A.stackGroups[j]=E}else A.stackGroups[Yf("_stackId_")]={numericAxisId:r,cateAxisId:i,items:[g]};return kt(kt({},p),{},Sl({},_,A))},d),v={};return Object.keys(h).reduce(function(p,g){var b=h[g];if(b.hasStack){var O={};b.stackGroups=Object.keys(b.stackGroups).reduce(function(j,x){var _=b.stackGroups[x];return kt(kt({},j),{},Sl({},x,{numericAxisId:r,cateAxisId:i,items:_.items,stackedData:Pse(t,_.items,o)}))},O)}return kt(kt({},p),{},Sl({},g,b))},v)},$se=function(t,n){var r=n.realScaleType,i=n.type,o=n.tickCount,l=n.originalDomain,u=n.allowDecimals,d=r||n.scale;if(d!=="auto"&&d!=="linear")return null;if(o&&i==="number"&&l&&(l[0]==="auto"||l[1]==="auto")){var h=t.domain();if(!h.length)return null;var v=Yoe(h,o,u);return t.domain([Cv(v),Nv(v)]),{niceTicks:v}}if(o&&i==="number"){var p=t.domain(),g=Woe(p,o,u);return{niceTicks:g}}return null};function BP(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,o=e.index,l=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Qe(i[t.dataKey])){var u=gm(n,"value",i[t.dataKey]);if(u)return u.coordinate+r/2}return n[o]?n[o].coordinate+r/2:null}var d=lr(i,Qe(l)?t.dataKey:l);return Qe(d)?null:t.scale(d)}var qP=function(t){var n=t.axis,r=t.ticks,i=t.offset,o=t.bandSize,l=t.entry,u=t.index;if(n.type==="category")return r[u]?r[u].coordinate+i:null;var d=lr(l,n.dataKey,n.domain[u]);return Qe(d)?null:n.scale(d)-o/2+i},Ise=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var i=Math.min(r[0],r[1]),o=Math.max(r[0],r[1]);return i<=0&&o>=0?0:o<0?o:i}return r[0]},Lse=function(t,n){var r,i=(r=t.type)!==null&&r!==void 0&&r.defaultProps?kt(kt({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(Zt(o)){var l=n[o];if(l){var u=l.items.indexOf(t);return u>=0?l.stackedData[u]:null}}return null},zse=function(t){return t.reduce(function(n,r){return[Cv(r.concat([n[0]]).filter(be)),Nv(r.concat([n[1]]).filter(be))]},[1/0,-1/0])},aB=function(t,n,r){return Object.keys(t).reduce(function(i,o){var l=t[o],u=l.stackedData,d=u.reduce(function(h,v){var p=zse(v.slice(n,r+1));return[Math.min(h[0],p[0]),Math.max(h[1],p[1])]},[1/0,-1/0]);return[Math.min(d[0],i[0]),Math.max(d[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},UP=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,HP=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,GS=function(t,n,r){if(Ye(t))return t(n,r);if(!Array.isArray(t))return n;var i=[];if(be(t[0]))i[0]=r?t[0]:Math.min(t[0],n[0]);else if(UP.test(t[0])){var o=+UP.exec(t[0])[1];i[0]=n[0]-o}else Ye(t[0])?i[0]=t[0](n[0]):i[0]=n[0];if(be(t[1]))i[1]=r?t[1]:Math.max(t[1],n[1]);else if(HP.test(t[1])){var l=+HP.exec(t[1])[1];i[1]=n[1]+l}else Ye(t[1])?i[1]=t[1](n[1]):i[1]=n[1];return i},Fm=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!r||i>0)return i}if(t&&n&&n.length>=2){for(var o=e_(n,function(p){return p.coordinate}),l=1/0,u=1,d=o.length;u<d;u++){var h=o[u],v=o[u-1];l=Math.min((h.coordinate||0)-(v.coordinate||0),l)}return l===1/0?0:l}return r?void 0:0},FP=function(t,n,r){return!t||!t.length||Tv(t,Tr(r,"type.defaultProps.domain"))?n:t},iB=function(t,n){var r=t.type.defaultProps?kt(kt({},t.type.defaultProps),t.props):t.props,i=r.dataKey,o=r.name,l=r.unit,u=r.formatter,d=r.tooltipType,h=r.chartType,v=r.hide;return kt(kt({},nt(t,!1)),{},{dataKey:i,unit:l,formatter:u,name:o||i,color:A_(t),value:lr(n,i),type:d,payload:n,chartType:h,hide:v})};function hf(e){"@babel/helpers - typeof";return hf=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},hf(e)}function GP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function VP(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?GP(Object(n),!0).forEach(function(r){Bse(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):GP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Bse(e,t,n){return t=qse(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qse(e){var t=Use(e,"string");return hf(t)=="symbol"?t:t+""}function Use(e,t){if(hf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(hf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Gm=Math.PI/180,Hse=function(t){return t*180/Math.PI},vn=function(t,n,r,i){return{x:t+Math.cos(-Gm*i)*r,y:n+Math.sin(-Gm*i)*r}},Fse=function(t,n){var r=t.x,i=t.y,o=n.x,l=n.y;return Math.sqrt(Math.pow(r-o,2)+Math.pow(i-l,2))},Gse=function(t,n){var r=t.x,i=t.y,o=n.cx,l=n.cy,u=Fse({x:r,y:i},{x:o,y:l});if(u<=0)return{radius:u};var d=(r-o)/u,h=Math.acos(d);return i>l&&(h=2*Math.PI-h),{radius:u,angle:Hse(h),angleInRadian:h}},Vse=function(t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),o=Math.floor(r/360),l=Math.min(i,o);return{startAngle:n-l*360,endAngle:r-l*360}},Yse=function(t,n){var r=n.startAngle,i=n.endAngle,o=Math.floor(r/360),l=Math.floor(i/360),u=Math.min(o,l);return t+u*360},YP=function(t,n){var r=t.x,i=t.y,o=Gse({x:r,y:i},n),l=o.radius,u=o.angle,d=n.innerRadius,h=n.outerRadius;if(l<d||l>h)return!1;if(l===0)return!0;var v=Vse(n),p=v.startAngle,g=v.endAngle,b=u,O;if(p<=g){for(;b>g;)b-=360;for(;b<p;)b+=360;O=b>=p&&b<=g}else{for(;b>p;)b-=360;for(;b<g;)b+=360;O=b>=g&&b<=p}return O?VP(VP({},n),{},{radius:l,angle:Yse(b,n)}):null};function mf(e){"@babel/helpers - typeof";return mf=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},mf(e)}var Wse=["offset"];function Kse(e){return Jse(e)||Zse(e)||Qse(e)||Xse()}function Xse(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
417
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Qse(e,t){if(e){if(typeof e=="string")return VS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return VS(e,t)}}function Zse(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Jse(e){if(Array.isArray(e))return VS(e)}function VS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function ele(e,t){if(e==null)return{};var n=tle(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function tle(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function WP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WP(Object(n),!0).forEach(function(r){nle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nle(e,t,n){return t=rle(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rle(e){var t=ale(e,"string");return mf(t)=="symbol"?t:t+""}function ale(e,t){if(mf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(mf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function pf(){return pf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},pf.apply(this,arguments)}var ile=function(t){var n=t.value,r=t.formatter,i=Qe(t.children)?n:t.children;return Ye(r)?r(i):i},ole=function(t,n){var r=Vr(n-t),i=Math.min(Math.abs(n-t),360);return r*i},sle=function(t,n,r){var i=t.position,o=t.viewBox,l=t.offset,u=t.className,d=o,h=d.cx,v=d.cy,p=d.innerRadius,g=d.outerRadius,b=d.startAngle,O=d.endAngle,j=d.clockWise,x=(p+g)/2,_=ole(b,O),A=_>=0?1:-1,E,C;i==="insideStart"?(E=b+A*l,C=j):i==="insideEnd"?(E=O-A*l,C=!j):i==="end"&&(E=O+A*l,C=j),C=_<=0?C:!C;var N=vn(h,v,x,E),M=vn(h,v,x,E+(C?1:-1)*359),R="M".concat(N.x,",").concat(N.y,`
418
+ A`).concat(x,",").concat(x,",0,1,").concat(C?0:1,`,
419
+ `).concat(M.x,",").concat(M.y),D=Qe(t.id)?Yf("recharts-radial-line-"):t.id;return I.createElement("text",pf({},r,{dominantBaseline:"central",className:rt("recharts-radial-bar-label",u)}),I.createElement("defs",null,I.createElement("path",{id:D,d:R})),I.createElement("textPath",{xlinkHref:"#".concat(D)},n))},lle=function(t){var n=t.viewBox,r=t.offset,i=t.position,o=n,l=o.cx,u=o.cy,d=o.innerRadius,h=o.outerRadius,v=o.startAngle,p=o.endAngle,g=(v+p)/2;if(i==="outside"){var b=vn(l,u,h+r,g),O=b.x,j=b.y;return{x:O,y:j,textAnchor:O>=l?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:l,y:u,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:l,y:u,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:l,y:u,textAnchor:"middle",verticalAnchor:"end"};var x=(d+h)/2,_=vn(l,u,x,g),A=_.x,E=_.y;return{x:A,y:E,textAnchor:"middle",verticalAnchor:"middle"}},cle=function(t){var n=t.viewBox,r=t.parentViewBox,i=t.offset,o=t.position,l=n,u=l.x,d=l.y,h=l.width,v=l.height,p=v>=0?1:-1,g=p*i,b=p>0?"end":"start",O=p>0?"start":"end",j=h>=0?1:-1,x=j*i,_=j>0?"end":"start",A=j>0?"start":"end";if(o==="top"){var E={x:u+h/2,y:d-p*i,textAnchor:"middle",verticalAnchor:b};return Qt(Qt({},E),r?{height:Math.max(d-r.y,0),width:h}:{})}if(o==="bottom"){var C={x:u+h/2,y:d+v+g,textAnchor:"middle",verticalAnchor:O};return Qt(Qt({},C),r?{height:Math.max(r.y+r.height-(d+v),0),width:h}:{})}if(o==="left"){var N={x:u-x,y:d+v/2,textAnchor:_,verticalAnchor:"middle"};return Qt(Qt({},N),r?{width:Math.max(N.x-r.x,0),height:v}:{})}if(o==="right"){var M={x:u+h+x,y:d+v/2,textAnchor:A,verticalAnchor:"middle"};return Qt(Qt({},M),r?{width:Math.max(r.x+r.width-M.x,0),height:v}:{})}var R=r?{width:h,height:v}:{};return o==="insideLeft"?Qt({x:u+x,y:d+v/2,textAnchor:A,verticalAnchor:"middle"},R):o==="insideRight"?Qt({x:u+h-x,y:d+v/2,textAnchor:_,verticalAnchor:"middle"},R):o==="insideTop"?Qt({x:u+h/2,y:d+g,textAnchor:"middle",verticalAnchor:O},R):o==="insideBottom"?Qt({x:u+h/2,y:d+v-g,textAnchor:"middle",verticalAnchor:b},R):o==="insideTopLeft"?Qt({x:u+x,y:d+g,textAnchor:A,verticalAnchor:O},R):o==="insideTopRight"?Qt({x:u+h-x,y:d+g,textAnchor:_,verticalAnchor:O},R):o==="insideBottomLeft"?Qt({x:u+x,y:d+v-g,textAnchor:A,verticalAnchor:b},R):o==="insideBottomRight"?Qt({x:u+h-x,y:d+v-g,textAnchor:_,verticalAnchor:b},R):fc(o)&&(be(o.x)||zo(o.x))&&(be(o.y)||zo(o.y))?Qt({x:u+Zo(o.x,h),y:d+Zo(o.y,v),textAnchor:"end",verticalAnchor:"end"},R):Qt({x:u+h/2,y:d+v/2,textAnchor:"middle",verticalAnchor:"middle"},R)},ule=function(t){return"cx"in t&&be(t.cx)};function wn(e){var t=e.offset,n=t===void 0?5:t,r=ele(e,Wse),i=Qt({offset:n},r),o=i.viewBox,l=i.position,u=i.value,d=i.children,h=i.content,v=i.className,p=v===void 0?"":v,g=i.textBreakAll;if(!o||Qe(u)&&Qe(d)&&!w.isValidElement(h)&&!Ye(h))return null;if(w.isValidElement(h))return w.cloneElement(h,i);var b;if(Ye(h)){if(b=w.createElement(h,i),w.isValidElement(b))return b}else b=ile(i);var O=ule(o),j=nt(i,!0);if(O&&(l==="insideStart"||l==="insideEnd"||l==="end"))return sle(i,b,j);var x=O?lle(i):cle(i);return I.createElement(Tm,pf({className:rt("recharts-label",p)},j,x,{breakAll:g}),b)}wn.displayName="Label";var oB=function(t){var n=t.cx,r=t.cy,i=t.angle,o=t.startAngle,l=t.endAngle,u=t.r,d=t.radius,h=t.innerRadius,v=t.outerRadius,p=t.x,g=t.y,b=t.top,O=t.left,j=t.width,x=t.height,_=t.clockWise,A=t.labelViewBox;if(A)return A;if(be(j)&&be(x)){if(be(p)&&be(g))return{x:p,y:g,width:j,height:x};if(be(b)&&be(O))return{x:b,y:O,width:j,height:x}}return be(p)&&be(g)?{x:p,y:g,width:0,height:0}:be(n)&&be(r)?{cx:n,cy:r,startAngle:o||i||0,endAngle:l||i||0,innerRadius:h||0,outerRadius:v||d||u||0,clockWise:_}:t.viewBox?t.viewBox:{}},fle=function(t,n){return t?t===!0?I.createElement(wn,{key:"label-implicit",viewBox:n}):Zt(t)?I.createElement(wn,{key:"label-implicit",viewBox:n,value:t}):w.isValidElement(t)?t.type===wn?w.cloneElement(t,{key:"label-implicit",viewBox:n}):I.createElement(wn,{key:"label-implicit",content:t,viewBox:n}):Ye(t)?I.createElement(wn,{key:"label-implicit",content:t,viewBox:n}):fc(t)?I.createElement(wn,pf({viewBox:n},t,{key:"label-implicit"})):null:null},dle=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&r&&!t.label)return null;var i=t.children,o=oB(t),l=Mr(i,wn).map(function(d,h){return w.cloneElement(d,{viewBox:n||o,key:"label-".concat(h)})});if(!r)return l;var u=fle(t.label,n||o);return[u].concat(Kse(l))};wn.parseViewBox=oB;wn.renderCallByParent=dle;var s1,KP;function hle(){if(KP)return s1;KP=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return s1=e,s1}var mle=hle();const ple=bt(mle);function vf(e){"@babel/helpers - typeof";return vf=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},vf(e)}var vle=["valueAccessor"],gle=["data","dataKey","clockWise","id","textBreakAll"];function yle(e){return Sle(e)||wle(e)||xle(e)||ble()}function ble(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
420
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xle(e,t){if(e){if(typeof e=="string")return YS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return YS(e,t)}}function wle(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Sle(e){if(Array.isArray(e))return YS(e)}function YS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Vm(){return Vm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vm.apply(this,arguments)}function XP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function QP(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?XP(Object(n),!0).forEach(function(r){jle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):XP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function jle(e,t,n){return t=Ole(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ole(e){var t=_le(e,"string");return vf(t)=="symbol"?t:t+""}function _le(e,t){if(vf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(vf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ZP(e,t){if(e==null)return{};var n=Ele(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ele(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Ale=function(t){return Array.isArray(t.value)?ple(t.value):t.value};function Wi(e){var t=e.valueAccessor,n=t===void 0?Ale:t,r=ZP(e,vle),i=r.data,o=r.dataKey,l=r.clockWise,u=r.id,d=r.textBreakAll,h=ZP(r,gle);return!i||!i.length?null:I.createElement(zt,{className:"recharts-label-list"},i.map(function(v,p){var g=Qe(o)?n(v,p):lr(v&&v.payload,o),b=Qe(u)?{}:{id:"".concat(u,"-").concat(p)};return I.createElement(wn,Vm({},nt(v,!0),h,b,{parentViewBox:v.parentViewBox,value:g,textBreakAll:d,viewBox:wn.parseViewBox(Qe(l)?v:QP(QP({},v),{},{clockWise:l})),key:"label-".concat(p),index:p}))}))}Wi.displayName="LabelList";function Nle(e,t){return e?e===!0?I.createElement(Wi,{key:"labelList-implicit",data:t}):I.isValidElement(e)||Ye(e)?I.createElement(Wi,{key:"labelList-implicit",data:t,content:e}):fc(e)?I.createElement(Wi,Vm({data:t},e,{key:"labelList-implicit"})):null:null}function Cle(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=Mr(r,Wi).map(function(l,u){return w.cloneElement(l,{data:t,key:"labelList-".concat(u)})});if(!n)return i;var o=Nle(e.label,t);return[o].concat(yle(i))}Wi.renderCallByParent=Cle;function gf(e){"@babel/helpers - typeof";return gf=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},gf(e)}function WS(){return WS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},WS.apply(this,arguments)}function JP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ek(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?JP(Object(n),!0).forEach(function(r){Tle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tle(e,t,n){return t=Mle(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mle(e){var t=Rle(e,"string");return gf(t)=="symbol"?t:t+""}function Rle(e,t){if(gf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(gf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Dle=function(t,n){var r=Vr(n-t),i=Math.min(Math.abs(n-t),359.999);return r*i},Ph=function(t){var n=t.cx,r=t.cy,i=t.radius,o=t.angle,l=t.sign,u=t.isExternal,d=t.cornerRadius,h=t.cornerIsExternal,v=d*(u?1:-1)+i,p=Math.asin(d/v)/Gm,g=h?o:o+l*p,b=vn(n,r,v,g),O=vn(n,r,i,g),j=h?o-l*p:o,x=vn(n,r,v*Math.cos(p*Gm),j);return{center:b,circleTangency:O,lineTangency:x,theta:p}},sB=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,o=t.outerRadius,l=t.startAngle,u=t.endAngle,d=Dle(l,u),h=l+d,v=vn(n,r,o,l),p=vn(n,r,o,h),g="M ".concat(v.x,",").concat(v.y,`
421
+ A `).concat(o,",").concat(o,`,0,
422
+ `).concat(+(Math.abs(d)>180),",").concat(+(l>h),`,
423
+ `).concat(p.x,",").concat(p.y,`
424
+ `);if(i>0){var b=vn(n,r,i,l),O=vn(n,r,i,h);g+="L ".concat(O.x,",").concat(O.y,`
425
+ A `).concat(i,",").concat(i,`,0,
426
+ `).concat(+(Math.abs(d)>180),",").concat(+(l<=h),`,
427
+ `).concat(b.x,",").concat(b.y," Z")}else g+="L ".concat(n,",").concat(r," Z");return g},Ple=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,o=t.outerRadius,l=t.cornerRadius,u=t.forceCornerRadius,d=t.cornerIsExternal,h=t.startAngle,v=t.endAngle,p=Vr(v-h),g=Ph({cx:n,cy:r,radius:o,angle:h,sign:p,cornerRadius:l,cornerIsExternal:d}),b=g.circleTangency,O=g.lineTangency,j=g.theta,x=Ph({cx:n,cy:r,radius:o,angle:v,sign:-p,cornerRadius:l,cornerIsExternal:d}),_=x.circleTangency,A=x.lineTangency,E=x.theta,C=d?Math.abs(h-v):Math.abs(h-v)-j-E;if(C<0)return u?"M ".concat(O.x,",").concat(O.y,`
428
+ a`).concat(l,",").concat(l,",0,0,1,").concat(l*2,`,0
429
+ a`).concat(l,",").concat(l,",0,0,1,").concat(-l*2,`,0
430
+ `):sB({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:h,endAngle:v});var N="M ".concat(O.x,",").concat(O.y,`
431
+ A`).concat(l,",").concat(l,",0,0,").concat(+(p<0),",").concat(b.x,",").concat(b.y,`
432
+ A`).concat(o,",").concat(o,",0,").concat(+(C>180),",").concat(+(p<0),",").concat(_.x,",").concat(_.y,`
433
+ A`).concat(l,",").concat(l,",0,0,").concat(+(p<0),",").concat(A.x,",").concat(A.y,`
434
+ `);if(i>0){var M=Ph({cx:n,cy:r,radius:i,angle:h,sign:p,isExternal:!0,cornerRadius:l,cornerIsExternal:d}),R=M.circleTangency,D=M.lineTangency,z=M.theta,Y=Ph({cx:n,cy:r,radius:i,angle:v,sign:-p,isExternal:!0,cornerRadius:l,cornerIsExternal:d}),L=Y.circleTangency,F=Y.lineTangency,W=Y.theta,Q=d?Math.abs(h-v):Math.abs(h-v)-z-W;if(Q<0&&l===0)return"".concat(N,"L").concat(n,",").concat(r,"Z");N+="L".concat(F.x,",").concat(F.y,`
435
+ A`).concat(l,",").concat(l,",0,0,").concat(+(p<0),",").concat(L.x,",").concat(L.y,`
436
+ A`).concat(i,",").concat(i,",0,").concat(+(Q>180),",").concat(+(p>0),",").concat(R.x,",").concat(R.y,`
437
+ A`).concat(l,",").concat(l,",0,0,").concat(+(p<0),",").concat(D.x,",").concat(D.y,"Z")}else N+="L".concat(n,",").concat(r,"Z");return N},kle={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},lB=function(t){var n=ek(ek({},kle),t),r=n.cx,i=n.cy,o=n.innerRadius,l=n.outerRadius,u=n.cornerRadius,d=n.forceCornerRadius,h=n.cornerIsExternal,v=n.startAngle,p=n.endAngle,g=n.className;if(l<o||v===p)return null;var b=rt("recharts-sector",g),O=l-o,j=Zo(u,O,0,!0),x;return j>0&&Math.abs(v-p)<360?x=Ple({cx:r,cy:i,innerRadius:o,outerRadius:l,cornerRadius:Math.min(j,O/2),forceCornerRadius:d,cornerIsExternal:h,startAngle:v,endAngle:p}):x=sB({cx:r,cy:i,innerRadius:o,outerRadius:l,startAngle:v,endAngle:p}),I.createElement("path",WS({},nt(n,!0),{className:b,d:x,role:"img"}))};function yf(e){"@babel/helpers - typeof";return yf=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},yf(e)}function KS(){return KS=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},KS.apply(this,arguments)}function tk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function nk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?tk(Object(n),!0).forEach(function(r){$le(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $le(e,t,n){return t=Ile(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ile(e){var t=Lle(e,"string");return yf(t)=="symbol"?t:t+""}function Lle(e,t){if(yf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var rk={curveBasisClosed:aee,curveBasisOpen:iee,curveBasis:ree,curveBumpX:HJ,curveBumpY:FJ,curveLinearClosed:oee,curveLinear:gv,curveMonotoneX:see,curveMonotoneY:lee,curveNatural:cee,curveStep:uee,curveStepAfter:dee,curveStepBefore:fee},kh=function(t){return t.x===+t.x&&t.y===+t.y},Ou=function(t){return t.x},_u=function(t){return t.y},zle=function(t,n){if(Ye(t))return t;var r="curve".concat(pv(t));return(r==="curveMonotone"||r==="curveBump")&&n?rk["".concat(r).concat(n==="vertical"?"Y":"X")]:rk[r]||gv},Ble=function(t){var n=t.type,r=n===void 0?"linear":n,i=t.points,o=i===void 0?[]:i,l=t.baseLine,u=t.layout,d=t.connectNulls,h=d===void 0?!1:d,v=zle(r,u),p=h?o.filter(function(j){return kh(j)}):o,g;if(Array.isArray(l)){var b=h?l.filter(function(j){return kh(j)}):l,O=p.map(function(j,x){return nk(nk({},j),{},{base:b[x]})});return u==="vertical"?g=Eh().y(_u).x1(Ou).x0(function(j){return j.base.x}):g=Eh().x(Ou).y1(_u).y0(function(j){return j.base.y}),g.defined(kh).curve(v),g(O)}return u==="vertical"&&be(l)?g=Eh().y(_u).x1(Ou).x0(l):be(l)?g=Eh().x(Ou).y1(_u).y0(l):g=dL().x(Ou).y(_u),g.defined(kh).curve(v),g(p)},XS=function(t){var n=t.className,r=t.points,i=t.path,o=t.pathRef;if((!r||!r.length)&&!i)return null;var l=r&&r.length?Ble(t):i;return w.createElement("path",KS({},nt(t,!1),ym(t),{className:rt("recharts-curve",n),d:l,ref:o}))},l1={exports:{}},c1,ak;function qle(){if(ak)return c1;ak=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return c1=e,c1}var u1,ik;function Ule(){if(ik)return u1;ik=1;var e=qle();function t(){}function n(){}return n.resetWarningCache=t,u1=function(){function r(l,u,d,h,v,p){if(p!==e){var g=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 g.name="Invariant Violation",g}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},u1}var ok;function Hle(){return ok||(ok=1,l1.exports=Ule()()),l1.exports}var Fle=Hle();const ut=bt(Fle),{getOwnPropertyNames:Gle,getOwnPropertySymbols:Vle}=Object,{hasOwnProperty:Yle}=Object.prototype;function f1(e,t){return function(r,i,o){return e(r,i,o)&&t(r,i,o)}}function $h(e){return function(n,r,i){if(!n||!r||typeof n!="object"||typeof r!="object")return e(n,r,i);const{cache:o}=i,l=o.get(n),u=o.get(r);if(l&&u)return l===r&&u===n;o.set(n,r),o.set(r,n);const d=e(n,r,i);return o.delete(n),o.delete(r),d}}function Wle(e){return e!=null?e[Symbol.toStringTag]:void 0}function sk(e){return Gle(e).concat(Vle(e))}const Kle=Object.hasOwn||((e,t)=>Yle.call(e,t));function ds(e,t){return e===t||!e&&!t&&e!==e&&t!==t}const Xle="__v",Qle="__o",Zle="_owner",{getOwnPropertyDescriptor:lk,keys:ck}=Object;function Jle(e,t){return e.byteLength===t.byteLength&&Ym(new Uint8Array(e),new Uint8Array(t))}function ece(e,t,n){let r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function tce(e,t){return e.byteLength===t.byteLength&&Ym(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function nce(e,t){return ds(e.getTime(),t.getTime())}function rce(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function ace(e,t){return e===t}function uk(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const i=new Array(r),o=e.entries();let l,u,d=0;for(;(l=o.next())&&!l.done;){const h=t.entries();let v=!1,p=0;for(;(u=h.next())&&!u.done;){if(i[p]){p++;continue}const g=l.value,b=u.value;if(n.equals(g[0],b[0],d,p,e,t,n)&&n.equals(g[1],b[1],g[0],b[0],e,t,n)){v=i[p]=!0;break}p++}if(!v)return!1;d++}return!0}const ice=ds;function oce(e,t,n){const r=ck(e);let i=r.length;if(ck(t).length!==i)return!1;for(;i-- >0;)if(!cB(e,t,n,r[i]))return!1;return!0}function Eu(e,t,n){const r=sk(e);let i=r.length;if(sk(t).length!==i)return!1;let o,l,u;for(;i-- >0;)if(o=r[i],!cB(e,t,n,o)||(l=lk(e,o),u=lk(t,o),(l||u)&&(!l||!u||l.configurable!==u.configurable||l.enumerable!==u.enumerable||l.writable!==u.writable)))return!1;return!0}function sce(e,t){return ds(e.valueOf(),t.valueOf())}function lce(e,t){return e.source===t.source&&e.flags===t.flags}function fk(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const i=new Array(r),o=e.values();let l,u;for(;(l=o.next())&&!l.done;){const d=t.values();let h=!1,v=0;for(;(u=d.next())&&!u.done;){if(!i[v]&&n.equals(l.value,u.value,l.value,u.value,e,t,n)){h=i[v]=!0;break}v++}if(!h)return!1}return!0}function Ym(e,t){let n=e.byteLength;if(t.byteLength!==n||e.byteOffset!==t.byteOffset)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function cce(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 cB(e,t,n,r){return(r===Zle||r===Qle||r===Xle)&&(e.$$typeof||t.$$typeof)?!0:Kle(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}const uce="[object ArrayBuffer]",fce="[object Arguments]",dce="[object Boolean]",hce="[object DataView]",mce="[object Date]",pce="[object Error]",vce="[object Map]",gce="[object Number]",yce="[object Object]",bce="[object RegExp]",xce="[object Set]",wce="[object String]",Sce={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},jce="[object URL]",Oce=Object.prototype.toString;function _ce({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:r,areErrorsEqual:i,areFunctionsEqual:o,areMapsEqual:l,areNumbersEqual:u,areObjectsEqual:d,arePrimitiveWrappersEqual:h,areRegExpsEqual:v,areSetsEqual:p,areTypedArraysEqual:g,areUrlsEqual:b,unknownTagComparators:O}){return function(x,_,A){if(x===_)return!0;if(x==null||_==null)return!1;const E=typeof x;if(E!==typeof _)return!1;if(E!=="object")return E==="number"?u(x,_,A):E==="function"?o(x,_,A):!1;const C=x.constructor;if(C!==_.constructor)return!1;if(C===Object)return d(x,_,A);if(Array.isArray(x))return t(x,_,A);if(C===Date)return r(x,_,A);if(C===RegExp)return v(x,_,A);if(C===Map)return l(x,_,A);if(C===Set)return p(x,_,A);const N=Oce.call(x);if(N===mce)return r(x,_,A);if(N===bce)return v(x,_,A);if(N===vce)return l(x,_,A);if(N===xce)return p(x,_,A);if(N===yce)return typeof x.then!="function"&&typeof _.then!="function"&&d(x,_,A);if(N===jce)return b(x,_,A);if(N===pce)return i(x,_,A);if(N===fce)return d(x,_,A);if(Sce[N])return g(x,_,A);if(N===uce)return e(x,_,A);if(N===hce)return n(x,_,A);if(N===dce||N===gce||N===wce)return h(x,_,A);if(O){let M=O[N];if(!M){const R=Wle(x);R&&(M=O[R])}if(M)return M(x,_,A)}return!1}}function Ece({circular:e,createCustomConfig:t,strict:n}){let r={areArrayBuffersEqual:Jle,areArraysEqual:n?Eu:ece,areDataViewsEqual:tce,areDatesEqual:nce,areErrorsEqual:rce,areFunctionsEqual:ace,areMapsEqual:n?f1(uk,Eu):uk,areNumbersEqual:ice,areObjectsEqual:n?Eu:oce,arePrimitiveWrappersEqual:sce,areRegExpsEqual:lce,areSetsEqual:n?f1(fk,Eu):fk,areTypedArraysEqual:n?f1(Ym,Eu):Ym,areUrlsEqual:cce,unknownTagComparators:void 0};if(t&&(r=Object.assign({},r,t(r))),e){const i=$h(r.areArraysEqual),o=$h(r.areMapsEqual),l=$h(r.areObjectsEqual),u=$h(r.areSetsEqual);r=Object.assign({},r,{areArraysEqual:i,areMapsEqual:o,areObjectsEqual:l,areSetsEqual:u})}return r}function Ace(e){return function(t,n,r,i,o,l,u){return e(t,n,u)}}function Nce({circular:e,comparator:t,createState:n,equals:r,strict:i}){if(n)return function(u,d){const{cache:h=e?new WeakMap:void 0,meta:v}=n();return t(u,d,{cache:h,equals:r,meta:v,strict:i})};if(e)return function(u,d){return t(u,d,{cache:new WeakMap,equals:r,meta:void 0,strict:i})};const o={cache:void 0,equals:r,meta:void 0,strict:i};return function(u,d){return t(u,d,o)}}const Cce=lo();lo({strict:!0});lo({circular:!0});lo({circular:!0,strict:!0});lo({createInternalComparator:()=>ds});lo({strict:!0,createInternalComparator:()=>ds});lo({circular:!0,createInternalComparator:()=>ds});lo({circular:!0,createInternalComparator:()=>ds,strict:!0});function lo(e={}){const{circular:t=!1,createInternalComparator:n,createState:r,strict:i=!1}=e,o=Ece(e),l=_ce(o),u=n?n(l):Ace(l);return Nce({circular:t,comparator:l,createState:r,equals:u,strict:i})}function Tce(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function dk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function i(o){n<0&&(n=o),o-n>t?(e(o),n=-1):Tce(i)};requestAnimationFrame(r)}function QS(e){"@babel/helpers - typeof";return QS=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},QS(e)}function Mce(e){return kce(e)||Pce(e)||Dce(e)||Rce()}function Rce(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
438
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Dce(e,t){if(e){if(typeof e=="string")return hk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return hk(e,t)}}function hk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Pce(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function kce(e){if(Array.isArray(e))return e}function $ce(){var e={},t=function(){return null},n=!1,r=function i(o){if(!n){if(Array.isArray(o)){if(!o.length)return;var l=o,u=Mce(l),d=u[0],h=u.slice(1);if(typeof d=="number"){dk(i.bind(null,h),d);return}i(d),dk(i.bind(null,h));return}QS(o)==="object"&&(e=o,t(e)),typeof o=="function"&&o()}};return{stop:function(){n=!0},start:function(o){n=!1,r(o)},subscribe:function(o){return t=o,function(){t=function(){return null}}}}}function bf(e){"@babel/helpers - typeof";return bf=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},bf(e)}function mk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function pk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?mk(Object(n),!0).forEach(function(r){uB(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uB(e,t,n){return t=Ice(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ice(e){var t=Lce(e,"string");return bf(t)==="symbol"?t:String(t)}function Lce(e,t){if(bf(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bf(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zce=function(t,n){return[Object.keys(t),Object.keys(n)].reduce(function(r,i){return r.filter(function(o){return i.includes(o)})})},Bce=function(t){return t},qce=function(t){return t.replace(/([A-Z])/g,function(n){return"-".concat(n.toLowerCase())})},Lu=function(t,n){return Object.keys(n).reduce(function(r,i){return pk(pk({},r),{},uB({},i,t(i,n[i])))},{})},vk=function(t,n,r){return t.map(function(i){return"".concat(qce(i)," ").concat(n,"ms ").concat(r)}).join(",")};function Uce(e,t){return Gce(e)||Fce(e,t)||fB(e,t)||Hce()}function Hce(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
439
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Fce(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function Gce(e){if(Array.isArray(e))return e}function Vce(e){return Kce(e)||Wce(e)||fB(e)||Yce()}function Yce(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
440
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function fB(e,t){if(e){if(typeof e=="string")return ZS(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ZS(e,t)}}function Wce(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Kce(e){if(Array.isArray(e))return ZS(e)}function ZS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Wm=1e-4,dB=function(t,n){return[0,3*t,3*n-6*t,3*t-3*n+1]},hB=function(t,n){return t.map(function(r,i){return r*Math.pow(n,i)}).reduce(function(r,i){return r+i})},gk=function(t,n){return function(r){var i=dB(t,n);return hB(i,r)}},Xce=function(t,n){return function(r){var i=dB(t,n),o=[].concat(Vce(i.map(function(l,u){return l*u}).slice(1)),[0]);return hB(o,r)}},yk=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0],o=n[1],l=n[2],u=n[3];if(n.length===1)switch(n[0]){case"linear":i=0,o=0,l=1,u=1;break;case"ease":i=.25,o=.1,l=.25,u=1;break;case"ease-in":i=.42,o=0,l=1,u=1;break;case"ease-out":i=.42,o=0,l=.58,u=1;break;case"ease-in-out":i=0,o=0,l=.58,u=1;break;default:{var d=n[0].split("(");if(d[0]==="cubic-bezier"&&d[1].split(")")[0].split(",").length===4){var h=d[1].split(")")[0].split(",").map(function(x){return parseFloat(x)}),v=Uce(h,4);i=v[0],o=v[1],l=v[2],u=v[3]}}}var p=gk(i,l),g=gk(o,u),b=Xce(i,l),O=function(_){return _>1?1:_<0?0:_},j=function(_){for(var A=_>1?1:_,E=A,C=0;C<8;++C){var N=p(E)-A,M=b(E);if(Math.abs(N-A)<Wm||M<Wm)return g(E);E=O(E-N/M)}return g(E)};return j.isStepper=!1,j},Qce=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,i=t.damping,o=i===void 0?8:i,l=t.dt,u=l===void 0?17:l,d=function(v,p,g){var b=-(v-p)*r,O=g*o,j=g+(b-O)*u/1e3,x=g*u/1e3+v;return Math.abs(x-p)<Wm&&Math.abs(j)<Wm?[p,0]:[x,j]};return d.isStepper=!0,d.dt=u,d},Zce=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0];if(typeof i=="string")switch(i){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return yk(i);case"spring":return Qce();default:if(i.split("(")[0]==="cubic-bezier")return yk(i)}return typeof i=="function"?i:null};function xf(e){"@babel/helpers - typeof";return xf=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},xf(e)}function bk(e){return tue(e)||eue(e)||mB(e)||Jce()}function Jce(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
441
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function eue(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function tue(e){if(Array.isArray(e))return ej(e)}function xk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function mn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xk(Object(n),!0).forEach(function(r){JS(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function JS(e,t,n){return t=nue(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nue(e){var t=rue(e,"string");return xf(t)==="symbol"?t:String(t)}function rue(e,t){if(xf(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(xf(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function aue(e,t){return sue(e)||oue(e,t)||mB(e,t)||iue()}function iue(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
442
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function mB(e,t){if(e){if(typeof e=="string")return ej(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ej(e,t)}}function ej(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function oue(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function sue(e){if(Array.isArray(e))return e}var Km=function(t,n,r){return t+(n-t)*r},tj=function(t){var n=t.from,r=t.to;return n!==r},lue=function e(t,n,r){var i=Lu(function(o,l){if(tj(l)){var u=t(l.from,l.to,l.velocity),d=aue(u,2),h=d[0],v=d[1];return mn(mn({},l),{},{from:h,velocity:v})}return l},n);return r<1?Lu(function(o,l){return tj(l)?mn(mn({},l),{},{velocity:Km(l.velocity,i[o].velocity,r),from:Km(l.from,i[o].from,r)}):l},n):e(t,i,r-1)};const cue=(function(e,t,n,r,i){var o=zce(e,t),l=o.reduce(function(x,_){return mn(mn({},x),{},JS({},_,[e[_],t[_]]))},{}),u=o.reduce(function(x,_){return mn(mn({},x),{},JS({},_,{from:e[_],velocity:0,to:t[_]}))},{}),d=-1,h,v,p=function(){return null},g=function(){return Lu(function(_,A){return A.from},u)},b=function(){return!Object.values(u).filter(tj).length},O=function(_){h||(h=_);var A=_-h,E=A/n.dt;u=lue(n,u,E),i(mn(mn(mn({},e),t),g())),h=_,b()||(d=requestAnimationFrame(p))},j=function(_){v||(v=_);var A=(_-v)/r,E=Lu(function(N,M){return Km.apply(void 0,bk(M).concat([n(A)]))},l);if(i(mn(mn(mn({},e),t),E)),A<1)d=requestAnimationFrame(p);else{var C=Lu(function(N,M){return Km.apply(void 0,bk(M).concat([n(1)]))},l);i(mn(mn(mn({},e),t),C))}};return p=n.isStepper?O:j,function(){return requestAnimationFrame(p),function(){cancelAnimationFrame(d)}}});function $l(e){"@babel/helpers - typeof";return $l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$l(e)}var uue=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function fue(e,t){if(e==null)return{};var n=due(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function due(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function d1(e){return vue(e)||pue(e)||mue(e)||hue()}function hue(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
443
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function mue(e,t){if(e){if(typeof e=="string")return nj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return nj(e,t)}}function pue(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function vue(e){if(Array.isArray(e))return nj(e)}function nj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function wk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Br(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wk(Object(n),!0).forEach(function(r){Ru(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ru(e,t,n){return t=pB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yue(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,pB(r.key),r)}}function bue(e,t,n){return t&&yue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function pB(e){var t=xue(e,"string");return $l(t)==="symbol"?t:String(t)}function xue(e,t){if($l(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if($l(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function wue(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&&rj(e,t)}function rj(e,t){return rj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},rj(e,t)}function Sue(e){var t=jue();return function(){var r=Xm(e),i;if(t){var o=Xm(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return aj(this,i)}}function aj(e,t){if(t&&($l(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return ij(e)}function ij(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function jue(){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 Xm(e){return Xm=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Xm(e)}var oi=(function(e){wue(n,e);var t=Sue(n);function n(r,i){var o;gue(this,n),o=t.call(this,r,i);var l=o.props,u=l.isActive,d=l.attributeName,h=l.from,v=l.to,p=l.steps,g=l.children,b=l.duration;if(o.handleStyleChange=o.handleStyleChange.bind(ij(o)),o.changeStyle=o.changeStyle.bind(ij(o)),!u||b<=0)return o.state={style:{}},typeof g=="function"&&(o.state={style:v}),aj(o);if(p&&p.length)o.state={style:p[0].style};else if(h){if(typeof g=="function")return o.state={style:h},aj(o);o.state={style:d?Ru({},d,h):h}}else o.state={style:{}};return o}return bue(n,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,l=i.canBegin;this.mounted=!0,!(!o||!l)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,l=o.isActive,u=o.canBegin,d=o.attributeName,h=o.shouldReAnimate,v=o.to,p=o.from,g=this.state.style;if(u){if(!l){var b={style:d?Ru({},d,v):v};this.state&&g&&(d&&g[d]!==v||!d&&g!==v)&&this.setState(b);return}if(!(Cce(i.to,v)&&i.canBegin&&i.isActive)){var O=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var j=O||h?p:i.to;if(this.state&&g){var x={style:d?Ru({},d,j):j};(d&&g[d]!==j||!d&&g!==j)&&this.setState(x)}this.runAnimation(Br(Br({},this.props),{},{from:j,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 o=this,l=i.from,u=i.to,d=i.duration,h=i.easing,v=i.begin,p=i.onAnimationEnd,g=i.onAnimationStart,b=cue(l,u,Zce(h),d,this.changeStyle),O=function(){o.stopJSAnimation=b()};this.manager.start([g,v,O,d,p])}},{key:"runStepAnimation",value:function(i){var o=this,l=i.steps,u=i.begin,d=i.onAnimationStart,h=l[0],v=h.style,p=h.duration,g=p===void 0?0:p,b=function(j,x,_){if(_===0)return j;var A=x.duration,E=x.easing,C=E===void 0?"ease":E,N=x.style,M=x.properties,R=x.onAnimationEnd,D=_>0?l[_-1]:x,z=M||Object.keys(N);if(typeof C=="function"||C==="spring")return[].concat(d1(j),[o.runJSAnimation.bind(o,{from:D.style,to:N,duration:A,easing:C}),A]);var Y=vk(z,A,C),L=Br(Br(Br({},D.style),N),{},{transition:Y});return[].concat(d1(j),[L,A,R]).filter(Bce)};return this.manager.start([d].concat(d1(l.reduce(b,[v,Math.max(g,u)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=$ce());var o=i.begin,l=i.duration,u=i.attributeName,d=i.to,h=i.easing,v=i.onAnimationStart,p=i.onAnimationEnd,g=i.steps,b=i.children,O=this.manager;if(this.unSubscribe=O.subscribe(this.handleStyleChange),typeof h=="function"||typeof b=="function"||h==="spring"){this.runJSAnimation(i);return}if(g.length>1){this.runStepAnimation(i);return}var j=u?Ru({},u,d):d,x=vk(Object.keys(j),l,h);O.start([v,o,Br(Br({},j),{},{transition:x}),l,p])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var l=i.duration;i.attributeName,i.easing;var u=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var d=fue(i,uue),h=w.Children.count(o),v=this.state.style;if(typeof o=="function")return o(v);if(!u||h===0||l<=0)return o;var p=function(b){var O=b.props,j=O.style,x=j===void 0?{}:j,_=O.className,A=w.cloneElement(b,Br(Br({},d),{},{style:Br(Br({},x),v),className:_}));return A};return h===1?p(w.Children.only(o)):I.createElement("div",null,w.Children.map(o,function(g){return p(g)}))}}]),n})(w.PureComponent);oi.displayName="Animate";oi.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};oi.propTypes={from:ut.oneOfType([ut.object,ut.string]),to:ut.oneOfType([ut.object,ut.string]),attributeName:ut.string,duration:ut.number,begin:ut.number,easing:ut.oneOfType([ut.string,ut.func]),steps:ut.arrayOf(ut.shape({duration:ut.number.isRequired,style:ut.object.isRequired,easing:ut.oneOfType([ut.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),ut.func]),properties:ut.arrayOf("string"),onAnimationEnd:ut.func})),children:ut.oneOfType([ut.node,ut.func]),isActive:ut.bool,canBegin:ut.bool,onAnimationEnd:ut.func,shouldReAnimate:ut.bool,onAnimationStart:ut.func,onAnimationReStart:ut.func};function wf(e){"@babel/helpers - typeof";return wf=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},wf(e)}function Qm(){return Qm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qm.apply(this,arguments)}function Oue(e,t){return Nue(e)||Aue(e,t)||Eue(e,t)||_ue()}function _ue(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
444
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Eue(e,t){if(e){if(typeof e=="string")return Sk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Sk(e,t)}}function Sk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Aue(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function Nue(e){if(Array.isArray(e))return e}function jk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ok(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jk(Object(n),!0).forEach(function(r){Cue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Cue(e,t,n){return t=Tue(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Tue(e){var t=Mue(e,"string");return wf(t)=="symbol"?t:t+""}function Mue(e,t){if(wf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(wf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var _k=function(t,n,r,i,o){var l=Math.min(Math.abs(r)/2,Math.abs(i)/2),u=i>=0?1:-1,d=r>=0?1:-1,h=i>=0&&r>=0||i<0&&r<0?1:0,v;if(l>0&&o instanceof Array){for(var p=[0,0,0,0],g=0,b=4;g<b;g++)p[g]=o[g]>l?l:o[g];v="M".concat(t,",").concat(n+u*p[0]),p[0]>0&&(v+="A ".concat(p[0],",").concat(p[0],",0,0,").concat(h,",").concat(t+d*p[0],",").concat(n)),v+="L ".concat(t+r-d*p[1],",").concat(n),p[1]>0&&(v+="A ".concat(p[1],",").concat(p[1],",0,0,").concat(h,`,
445
+ `).concat(t+r,",").concat(n+u*p[1])),v+="L ".concat(t+r,",").concat(n+i-u*p[2]),p[2]>0&&(v+="A ".concat(p[2],",").concat(p[2],",0,0,").concat(h,`,
446
+ `).concat(t+r-d*p[2],",").concat(n+i)),v+="L ".concat(t+d*p[3],",").concat(n+i),p[3]>0&&(v+="A ".concat(p[3],",").concat(p[3],",0,0,").concat(h,`,
447
+ `).concat(t,",").concat(n+i-u*p[3])),v+="Z"}else if(l>0&&o===+o&&o>0){var O=Math.min(l,o);v="M ".concat(t,",").concat(n+u*O,`
448
+ A `).concat(O,",").concat(O,",0,0,").concat(h,",").concat(t+d*O,",").concat(n,`
449
+ L `).concat(t+r-d*O,",").concat(n,`
450
+ A `).concat(O,",").concat(O,",0,0,").concat(h,",").concat(t+r,",").concat(n+u*O,`
451
+ L `).concat(t+r,",").concat(n+i-u*O,`
452
+ A `).concat(O,",").concat(O,",0,0,").concat(h,",").concat(t+r-d*O,",").concat(n+i,`
453
+ L `).concat(t+d*O,",").concat(n+i,`
454
+ A `).concat(O,",").concat(O,",0,0,").concat(h,",").concat(t,",").concat(n+i-u*O," Z")}else v="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(i," h ").concat(-r," Z");return v},Rue=function(t,n){if(!t||!n)return!1;var r=t.x,i=t.y,o=n.x,l=n.y,u=n.width,d=n.height;if(Math.abs(u)>0&&Math.abs(d)>0){var h=Math.min(o,o+u),v=Math.max(o,o+u),p=Math.min(l,l+d),g=Math.max(l,l+d);return r>=h&&r<=v&&i>=p&&i<=g}return!1},Due={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},N_=function(t){var n=Ok(Ok({},Due),t),r=w.useRef(),i=w.useState(-1),o=Oue(i,2),l=o[0],u=o[1];w.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var C=r.current.getTotalLength();C&&u(C)}catch{}},[]);var d=n.x,h=n.y,v=n.width,p=n.height,g=n.radius,b=n.className,O=n.animationEasing,j=n.animationDuration,x=n.animationBegin,_=n.isAnimationActive,A=n.isUpdateAnimationActive;if(d!==+d||h!==+h||v!==+v||p!==+p||v===0||p===0)return null;var E=rt("recharts-rectangle",b);return A?I.createElement(oi,{canBegin:l>0,from:{width:v,height:p,x:d,y:h},to:{width:v,height:p,x:d,y:h},duration:j,animationEasing:O,isActive:A},function(C){var N=C.width,M=C.height,R=C.x,D=C.y;return I.createElement(oi,{canBegin:l>0,from:"0px ".concat(l===-1?1:l,"px"),to:"".concat(l,"px 0px"),attributeName:"strokeDasharray",begin:x,duration:j,isActive:_,easing:O},I.createElement("path",Qm({},nt(n,!0),{className:E,d:_k(R,D,N,M,g),ref:r})))}):I.createElement("path",Qm({},nt(n,!0),{className:E,d:_k(d,h,v,p,g)}))};function oj(){return oj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},oj.apply(this,arguments)}var C_=function(t){var n=t.cx,r=t.cy,i=t.r,o=t.className,l=rt("recharts-dot",o);return n===+n&&r===+r&&i===+i?w.createElement("circle",oj({},nt(t,!1),ym(t),{className:l,cx:n,cy:r,r:i})):null};function Sf(e){"@babel/helpers - typeof";return Sf=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},Sf(e)}var Pue=["x","y","top","left","width","height","className"];function sj(){return sj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},sj.apply(this,arguments)}function Ek(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function kue(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ek(Object(n),!0).forEach(function(r){$ue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ek(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $ue(e,t,n){return t=Iue(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Iue(e){var t=Lue(e,"string");return Sf(t)=="symbol"?t:t+""}function Lue(e,t){if(Sf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Sf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function zue(e,t){if(e==null)return{};var n=Bue(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Bue(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var que=function(t,n,r,i,o,l){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(l,",").concat(n,"h").concat(r)},Uue=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,l=t.top,u=l===void 0?0:l,d=t.left,h=d===void 0?0:d,v=t.width,p=v===void 0?0:v,g=t.height,b=g===void 0?0:g,O=t.className,j=zue(t,Pue),x=kue({x:r,y:o,top:u,left:h,width:p,height:b},j);return!be(r)||!be(o)||!be(p)||!be(b)||!be(u)||!be(h)?null:I.createElement("path",sj({},nt(x,!0),{className:rt("recharts-cross",O),d:que(r,o,p,b,u,h)}))},h1,Ak;function Hue(){if(Ak)return h1;Ak=1;var e=kL(),t=e(Object.getPrototypeOf,Object);return h1=t,h1}var m1,Nk;function Fue(){if(Nk)return m1;Nk=1;var e=li(),t=Hue(),n=ci(),r="[object Object]",i=Function.prototype,o=Object.prototype,l=i.toString,u=o.hasOwnProperty,d=l.call(Object);function h(v){if(!n(v)||e(v)!=r)return!1;var p=t(v);if(p===null)return!0;var g=u.call(p,"constructor")&&p.constructor;return typeof g=="function"&&g instanceof g&&l.call(g)==d}return m1=h,m1}var Gue=Fue();const Vue=bt(Gue);var p1,Ck;function Yue(){if(Ck)return p1;Ck=1;var e=li(),t=ci(),n="[object Boolean]";function r(i){return i===!0||i===!1||t(i)&&e(i)==n}return p1=r,p1}var Wue=Yue();const Kue=bt(Wue);function jf(e){"@babel/helpers - typeof";return jf=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},jf(e)}function Zm(){return Zm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zm.apply(this,arguments)}function Xue(e,t){return efe(e)||Jue(e,t)||Zue(e,t)||Que()}function Que(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
455
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Zue(e,t){if(e){if(typeof e=="string")return Tk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Tk(e,t)}}function Tk(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Jue(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function efe(e){if(Array.isArray(e))return e}function Mk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Rk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Mk(Object(n),!0).forEach(function(r){tfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tfe(e,t,n){return t=nfe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nfe(e){var t=rfe(e,"string");return jf(t)=="symbol"?t:t+""}function rfe(e,t){if(jf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(jf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Dk=function(t,n,r,i,o){var l=r-i,u;return u="M ".concat(t,",").concat(n),u+="L ".concat(t+r,",").concat(n),u+="L ".concat(t+r-l/2,",").concat(n+o),u+="L ".concat(t+r-l/2-i,",").concat(n+o),u+="L ".concat(t,",").concat(n," Z"),u},afe={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},ife=function(t){var n=Rk(Rk({},afe),t),r=w.useRef(),i=w.useState(-1),o=Xue(i,2),l=o[0],u=o[1];w.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var E=r.current.getTotalLength();E&&u(E)}catch{}},[]);var d=n.x,h=n.y,v=n.upperWidth,p=n.lowerWidth,g=n.height,b=n.className,O=n.animationEasing,j=n.animationDuration,x=n.animationBegin,_=n.isUpdateAnimationActive;if(d!==+d||h!==+h||v!==+v||p!==+p||g!==+g||v===0&&p===0||g===0)return null;var A=rt("recharts-trapezoid",b);return _?I.createElement(oi,{canBegin:l>0,from:{upperWidth:0,lowerWidth:0,height:g,x:d,y:h},to:{upperWidth:v,lowerWidth:p,height:g,x:d,y:h},duration:j,animationEasing:O,isActive:_},function(E){var C=E.upperWidth,N=E.lowerWidth,M=E.height,R=E.x,D=E.y;return I.createElement(oi,{canBegin:l>0,from:"0px ".concat(l===-1?1:l,"px"),to:"".concat(l,"px 0px"),attributeName:"strokeDasharray",begin:x,duration:j,easing:O},I.createElement("path",Zm({},nt(n,!0),{className:A,d:Dk(R,D,C,N,M),ref:r})))}):I.createElement("g",null,I.createElement("path",Zm({},nt(n,!0),{className:A,d:Dk(d,h,v,p,g)})))},ofe=["option","shapeType","propTransformer","activeClassName","isActive"];function Of(e){"@babel/helpers - typeof";return Of=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},Of(e)}function sfe(e,t){if(e==null)return{};var n=lfe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function lfe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Pk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Jm(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Pk(Object(n),!0).forEach(function(r){cfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function cfe(e,t,n){return t=ufe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ufe(e){var t=ffe(e,"string");return Of(t)=="symbol"?t:t+""}function ffe(e,t){if(Of(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Of(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dfe(e,t){return Jm(Jm({},t),e)}function hfe(e,t){return e==="symbols"}function kk(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return I.createElement(N_,n);case"trapezoid":return I.createElement(ife,n);case"sector":return I.createElement(lB,n);case"symbols":if(hfe(t))return I.createElement(VO,n);break;default:return null}}function mfe(e){return w.isValidElement(e)?e.props:e}function pfe(e){var t=e.option,n=e.shapeType,r=e.propTransformer,i=r===void 0?dfe:r,o=e.activeClassName,l=o===void 0?"recharts-active-shape":o,u=e.isActive,d=sfe(e,ofe),h;if(w.isValidElement(t))h=w.cloneElement(t,Jm(Jm({},d),mfe(t)));else if(Ye(t))h=t(d);else if(Vue(t)&&!Kue(t)){var v=i(t,d);h=I.createElement(kk,{shapeType:n,elementProps:v})}else{var p=d;h=I.createElement(kk,{shapeType:n,elementProps:p})}return u?I.createElement(zt,{className:l},h):h}function Dv(e,t){return t!=null&&"trapezoids"in e.props}function Pv(e,t){return t!=null&&"sectors"in e.props}function _f(e,t){return t!=null&&"points"in e.props}function vfe(e,t){var n,r,i=e.x===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.x)||e.x===t.x,o=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return i&&o}function gfe(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function yfe(e,t){var n=e.x===t.x,r=e.y===t.y,i=e.z===t.z;return n&&r&&i}function bfe(e,t){var n;return Dv(e,t)?n=vfe:Pv(e,t)?n=gfe:_f(e,t)&&(n=yfe),n}function xfe(e,t){var n;return Dv(e,t)?n="trapezoids":Pv(e,t)?n="sectors":_f(e,t)&&(n="points"),n}function wfe(e,t){if(Dv(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}if(Pv(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}return _f(e,t)?t.payload:{}}function Sfe(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,i=xfe(n,t),o=wfe(n,t),l=r.filter(function(d,h){var v=Tv(o,d),p=n.props[i].filter(function(O){var j=bfe(n,t);return j(O,t)}),g=n.props[i].indexOf(p[p.length-1]),b=h===g;return v&&b}),u=r.indexOf(l[l.length-1]);return u}var v1,$k;function jfe(){if($k)return v1;$k=1;var e=Math.ceil,t=Math.max;function n(r,i,o,l){for(var u=-1,d=t(e((i-r)/(o||1)),0),h=Array(d);d--;)h[l?d:++u]=r,r+=o;return h}return v1=n,v1}var g1,Ik;function vB(){if(Ik)return g1;Ik=1;var e=QL(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*n}return i===i?i:0}return g1=r,g1}var y1,Lk;function Ofe(){if(Lk)return y1;Lk=1;var e=jfe(),t=wv(),n=vB();function r(i){return function(o,l,u){return u&&typeof u!="number"&&t(o,l,u)&&(l=u=void 0),o=n(o),l===void 0?(l=o,o=0):l=n(l),u=u===void 0?o<l?1:-1:n(u),e(o,l,u,i)}}return y1=r,y1}var b1,zk;function _fe(){if(zk)return b1;zk=1;var e=Ofe(),t=e();return b1=t,b1}var Efe=_fe();const ep=bt(Efe);function Ef(e){"@babel/helpers - typeof";return Ef=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},Ef(e)}function Bk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Bk(Object(n),!0).forEach(function(r){gB(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gB(e,t,n){return t=Afe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Afe(e){var t=Nfe(e,"string");return Ef(t)=="symbol"?t:t+""}function Nfe(e,t){if(Ef(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ef(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Cfe=["Webkit","Moz","O","ms"],Tfe=function(t,n){var r=t.replace(/(\w)/,function(o){return o.toUpperCase()}),i=Cfe.reduce(function(o,l){return qk(qk({},o),{},gB({},l+r,n))},{});return i[t]=n,i};function Il(e){"@babel/helpers - typeof";return Il=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Il(e)}function tp(){return tp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},tp.apply(this,arguments)}function Uk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function x1(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Uk(Object(n),!0).forEach(function(r){tr(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Uk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Mfe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Hk(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,bB(r.key),r)}}function Rfe(e,t,n){return t&&Hk(e.prototype,t),n&&Hk(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Dfe(e,t,n){return t=np(t),Pfe(e,yB()?Reflect.construct(t,n||[],np(e).constructor):t.apply(e,n))}function Pfe(e,t){if(t&&(Il(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return kfe(e)}function kfe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yB=function(){return!!e})()}function np(e){return np=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},np(e)}function $fe(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&&lj(e,t)}function lj(e,t){return lj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},lj(e,t)}function tr(e,t,n){return t=bB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bB(e){var t=Ife(e,"string");return Il(t)=="symbol"?t:t+""}function Ife(e,t){if(Il(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Il(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Lfe=function(t){var n=t.data,r=t.startIndex,i=t.endIndex,o=t.x,l=t.width,u=t.travellerWidth;if(!n||!n.length)return{};var d=n.length,h=$u().domain(ep(0,d)).range([o,o+l-u]),v=h.domain().map(function(p){return h(p)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:h(r),endX:h(i),scale:h,scaleValues:v}},Fk=function(t){return t.changedTouches&&!!t.changedTouches.length},Ll=(function(e){function t(n){var r;return Mfe(this,t),r=Dfe(this,t,[n]),tr(r,"handleDrag",function(i){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(i):r.state.isSlideMoving&&r.handleSlideDrag(i)}),tr(r,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&r.handleDrag(i.changedTouches[0])}),tr(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=r.props,o=i.endIndex,l=i.onDragEnd,u=i.startIndex;l==null||l({endIndex:o,startIndex:u})}),r.detachDragEndListener()}),tr(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),tr(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),tr(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),tr(r,"handleSlideDragStart",function(i){var o=Fk(i)?i.changedTouches[0]:i;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return $fe(t,e),Rfe(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var i=r.startX,o=r.endX,l=this.state.scaleValues,u=this.props,d=u.gap,h=u.data,v=h.length-1,p=Math.min(i,o),g=Math.max(i,o),b=t.getIndexInRange(l,p),O=t.getIndexInRange(l,g);return{startIndex:b-b%d,endIndex:O===v?v:O-O%d}}},{key:"getTextOfTick",value:function(r){var i=this.props,o=i.data,l=i.tickFormatter,u=i.dataKey,d=lr(o[r],u,r);return Ye(l)?l(d,r):d}},{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(r){var i=this.state,o=i.slideMoveStartX,l=i.startX,u=i.endX,d=this.props,h=d.x,v=d.width,p=d.travellerWidth,g=d.startIndex,b=d.endIndex,O=d.onChange,j=r.pageX-o;j>0?j=Math.min(j,h+v-p-u,h+v-p-l):j<0&&(j=Math.max(j,h-l,h-u));var x=this.getIndex({startX:l+j,endX:u+j});(x.startIndex!==g||x.endIndex!==b)&&O&&O(x),this.setState({startX:l+j,endX:u+j,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,i){var o=Fk(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var i=this.state,o=i.brushMoveStartX,l=i.movingTravellerId,u=i.endX,d=i.startX,h=this.state[l],v=this.props,p=v.x,g=v.width,b=v.travellerWidth,O=v.onChange,j=v.gap,x=v.data,_={startX:this.state.startX,endX:this.state.endX},A=r.pageX-o;A>0?A=Math.min(A,p+g-b-h):A<0&&(A=Math.max(A,p-h)),_[l]=h+A;var E=this.getIndex(_),C=E.startIndex,N=E.endIndex,M=function(){var D=x.length-1;return l==="startX"&&(u>d?C%j===0:N%j===0)||u<d&&N===D||l==="endX"&&(u>d?N%j===0:C%j===0)||u>d&&N===D};this.setState(tr(tr({},l,h+A),"brushMoveStartX",r.pageX),function(){O&&M()&&O(E)})}},{key:"handleTravellerMoveKeyboard",value:function(r,i){var o=this,l=this.state,u=l.scaleValues,d=l.startX,h=l.endX,v=this.state[i],p=u.indexOf(v);if(p!==-1){var g=p+r;if(!(g===-1||g>=u.length)){var b=u[g];i==="startX"&&b>=h||i==="endX"&&b<=d||this.setState(tr({},i,b),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,i=r.x,o=r.y,l=r.width,u=r.height,d=r.fill,h=r.stroke;return I.createElement("rect",{stroke:h,fill:d,x:i,y:o,width:l,height:u})}},{key:"renderPanorama",value:function(){var r=this.props,i=r.x,o=r.y,l=r.width,u=r.height,d=r.data,h=r.children,v=r.padding,p=w.Children.only(h);return p?I.cloneElement(p,{x:i,y:o,width:l,height:u,margin:v,compact:!0,data:d}):null}},{key:"renderTravellerLayer",value:function(r,i){var o,l,u=this,d=this.props,h=d.y,v=d.travellerWidth,p=d.height,g=d.traveller,b=d.ariaLabel,O=d.data,j=d.startIndex,x=d.endIndex,_=Math.max(r,this.props.x),A=x1(x1({},nt(this.props,!1)),{},{x:_,y:h,width:v,height:p}),E=b||"Min value: ".concat((o=O[j])===null||o===void 0?void 0:o.name,", Max value: ").concat((l=O[x])===null||l===void 0?void 0:l.name);return I.createElement(zt,{tabIndex:0,role:"slider","aria-label":E,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(N){["ArrowLeft","ArrowRight"].includes(N.key)&&(N.preventDefault(),N.stopPropagation(),u.handleTravellerMoveKeyboard(N.key==="ArrowRight"?1:-1,i))},onFocus:function(){u.setState({isTravellerFocused:!0})},onBlur:function(){u.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(g,A))}},{key:"renderSlide",value:function(r,i){var o=this.props,l=o.y,u=o.height,d=o.stroke,h=o.travellerWidth,v=Math.min(r,i)+h,p=Math.max(Math.abs(i-r)-h,0);return I.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:d,fillOpacity:.2,x:v,y:l,width:p,height:u})}},{key:"renderText",value:function(){var r=this.props,i=r.startIndex,o=r.endIndex,l=r.y,u=r.height,d=r.travellerWidth,h=r.stroke,v=this.state,p=v.startX,g=v.endX,b=5,O={pointerEvents:"none",fill:h};return I.createElement(zt,{className:"recharts-brush-texts"},I.createElement(Tm,tp({textAnchor:"end",verticalAnchor:"middle",x:Math.min(p,g)-b,y:l+u/2},O),this.getTextOfTick(i)),I.createElement(Tm,tp({textAnchor:"start",verticalAnchor:"middle",x:Math.max(p,g)+d+b,y:l+u/2},O),this.getTextOfTick(o)))}},{key:"render",value:function(){var r=this.props,i=r.data,o=r.className,l=r.children,u=r.x,d=r.y,h=r.width,v=r.height,p=r.alwaysShowText,g=this.state,b=g.startX,O=g.endX,j=g.isTextActive,x=g.isSlideMoving,_=g.isTravellerMoving,A=g.isTravellerFocused;if(!i||!i.length||!be(u)||!be(d)||!be(h)||!be(v)||h<=0||v<=0)return null;var E=rt("recharts-brush",o),C=I.Children.count(l)===1,N=Tfe("userSelect","none");return I.createElement(zt,{className:E,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:N},this.renderBackground(),C&&this.renderPanorama(),this.renderSlide(b,O),this.renderTravellerLayer(b,"startX"),this.renderTravellerLayer(O,"endX"),(j||x||_||A||p)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var i=r.x,o=r.y,l=r.width,u=r.height,d=r.stroke,h=Math.floor(o+u/2)-1;return I.createElement(I.Fragment,null,I.createElement("rect",{x:i,y:o,width:l,height:u,fill:d,stroke:"none"}),I.createElement("line",{x1:i+1,y1:h,x2:i+l-1,y2:h,fill:"none",stroke:"#fff"}),I.createElement("line",{x1:i+1,y1:h+2,x2:i+l-1,y2:h+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,i){var o;return I.isValidElement(r)?o=I.cloneElement(r,i):Ye(r)?o=r(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(r,i){var o=r.data,l=r.width,u=r.x,d=r.travellerWidth,h=r.updateId,v=r.startIndex,p=r.endIndex;if(o!==i.prevData||h!==i.prevUpdateId)return x1({prevData:o,prevTravellerWidth:d,prevUpdateId:h,prevX:u,prevWidth:l},o&&o.length?Lfe({data:o,width:l,x:u,travellerWidth:d,startIndex:v,endIndex:p}):{scale:null,scaleValues:null});if(i.scale&&(l!==i.prevWidth||u!==i.prevX||d!==i.prevTravellerWidth)){i.scale.range([u,u+l-d]);var g=i.scale.domain().map(function(b){return i.scale(b)});return{prevData:o,prevTravellerWidth:d,prevUpdateId:h,prevX:u,prevWidth:l,startX:i.scale(r.startIndex),endX:i.scale(r.endIndex),scaleValues:g}}return null}},{key:"getIndexInRange",value:function(r,i){for(var o=r.length,l=0,u=o-1;u-l>1;){var d=Math.floor((l+u)/2);r[d]>i?u=d:l=d}return i>=r[u]?u:l}}])})(w.PureComponent);tr(Ll,"displayName","Brush");tr(Ll,"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 w1,Gk;function zfe(){if(Gk)return w1;Gk=1;var e=JO();function t(n,r){var i;return e(n,function(o,l,u){return i=r(o,l,u),!i}),!!i}return w1=t,w1}var S1,Vk;function Bfe(){if(Vk)return S1;Vk=1;var e=NL(),t=io(),n=zfe(),r=Fn(),i=wv();function o(l,u,d){var h=r(l)?e:n;return d&&i(l,u,d)&&(u=void 0),h(l,t(u,3))}return S1=o,S1}var qfe=Bfe();const Ufe=bt(qfe);var va=function(t,n){var r=t.alwaysShow,i=t.ifOverflow;return r&&(i="extendDomain"),i===n},j1,Yk;function Hfe(){if(Yk)return j1;Yk=1;var e=VL();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return j1=t,j1}var O1,Wk;function Ffe(){if(Wk)return O1;Wk=1;var e=Hfe(),t=FL(),n=io();function r(i,o){var l={};return o=n(o,3),t(i,function(u,d,h){e(l,d,o(u,d,h))}),l}return O1=r,O1}var Gfe=Ffe();const Vfe=bt(Gfe);var _1,Kk;function Yfe(){if(Kk)return _1;Kk=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(!n(t[r],r,t))return!1;return!0}return _1=e,_1}var E1,Xk;function Wfe(){if(Xk)return E1;Xk=1;var e=JO();function t(n,r){var i=!0;return e(n,function(o,l,u){return i=!!r(o,l,u),i}),i}return E1=t,E1}var A1,Qk;function Kfe(){if(Qk)return A1;Qk=1;var e=Yfe(),t=Wfe(),n=io(),r=Fn(),i=wv();function o(l,u,d){var h=r(l)?e:t;return d&&i(l,u,d)&&(u=void 0),h(l,n(u,3))}return A1=o,A1}var Xfe=Kfe();const xB=bt(Xfe);var Qfe=["x","y"];function Af(e){"@babel/helpers - typeof";return Af=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},Af(e)}function cj(){return cj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},cj.apply(this,arguments)}function Zk(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Au(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Zk(Object(n),!0).forEach(function(r){Zfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Zfe(e,t,n){return t=Jfe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Jfe(e){var t=ede(e,"string");return Af(t)=="symbol"?t:t+""}function ede(e,t){if(Af(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Af(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function tde(e,t){if(e==null)return{};var n=nde(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function nde(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function rde(e,t){var n=e.x,r=e.y,i=tde(e,Qfe),o="".concat(n),l=parseInt(o,10),u="".concat(r),d=parseInt(u,10),h="".concat(t.height||i.height),v=parseInt(h,10),p="".concat(t.width||i.width),g=parseInt(p,10);return Au(Au(Au(Au(Au({},t),i),l?{x:l}:{}),d?{y:d}:{}),{},{height:v,width:g,name:t.name,radius:t.radius})}function Jk(e){return I.createElement(pfe,cj({shapeType:"rectangle",propTransformer:rde,activeClassName:"recharts-active-bar"},e))}var ade=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,i){if(typeof t=="number")return t;var o=be(r)||uJ(r);return o?t(r,i):(o||es(),n)}},ide=["value","background"],wB;function zl(e){"@babel/helpers - typeof";return zl=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},zl(e)}function ode(e,t){if(e==null)return{};var n=sde(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function sde(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function rp(){return rp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},rp.apply(this,arguments)}function e4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Gt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?e4(Object(n),!0).forEach(function(r){Gi(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):e4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function t4(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,jB(r.key),r)}}function cde(e,t,n){return t&&t4(e.prototype,t),n&&t4(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function ude(e,t,n){return t=ap(t),fde(e,SB()?Reflect.construct(t,n||[],ap(e).constructor):t.apply(e,n))}function fde(e,t){if(t&&(zl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return dde(e)}function dde(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function SB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(SB=function(){return!!e})()}function ap(e){return ap=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ap(e)}function hde(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&&uj(e,t)}function uj(e,t){return uj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},uj(e,t)}function Gi(e,t,n){return t=jB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jB(e){var t=mde(e,"string");return zl(t)=="symbol"?t:t+""}function mde(e,t){if(zl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(zl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ji=(function(e){function t(){var n;lde(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=ude(this,t,[].concat(i)),Gi(n,"state",{isAnimationFinished:!1}),Gi(n,"id",Yf("recharts-bar-")),Gi(n,"handleAnimationEnd",function(){var l=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),l&&l()}),Gi(n,"handleAnimationStart",function(){var l=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),l&&l()}),n}return hde(t,e),cde(t,[{key:"renderRectanglesStatically",value:function(r){var i=this,o=this.props,l=o.shape,u=o.dataKey,d=o.activeIndex,h=o.activeBar,v=nt(this.props,!1);return r&&r.map(function(p,g){var b=g===d,O=b?h:l,j=Gt(Gt(Gt({},v),p),{},{isActive:b,option:O,index:g,dataKey:u,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return I.createElement(zt,rp({className:"recharts-bar-rectangle"},bm(i.props,p,g),{key:"rectangle-".concat(p==null?void 0:p.x,"-").concat(p==null?void 0:p.y,"-").concat(p==null?void 0:p.value,"-").concat(g)}),I.createElement(Jk,j))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,i=this.props,o=i.data,l=i.layout,u=i.isAnimationActive,d=i.animationBegin,h=i.animationDuration,v=i.animationEasing,p=i.animationId,g=this.state.prevData;return I.createElement(oi,{begin:d,duration:h,isActive:u,easing:v,from:{t:0},to:{t:1},key:"bar-".concat(p),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(b){var O=b.t,j=o.map(function(x,_){var A=g&&g[_];if(A){var E=Fr(A.x,x.x),C=Fr(A.y,x.y),N=Fr(A.width,x.width),M=Fr(A.height,x.height);return Gt(Gt({},x),{},{x:E(O),y:C(O),width:N(O),height:M(O)})}if(l==="horizontal"){var R=Fr(0,x.height),D=R(O);return Gt(Gt({},x),{},{y:x.y+x.height-D,height:D})}var z=Fr(0,x.width),Y=z(O);return Gt(Gt({},x),{},{width:Y})});return I.createElement(zt,null,r.renderRectanglesStatically(j))})}},{key:"renderRectangles",value:function(){var r=this.props,i=r.data,o=r.isAnimationActive,l=this.state.prevData;return o&&i&&i.length&&(!l||!Tv(l,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var r=this,i=this.props,o=i.data,l=i.dataKey,u=i.activeIndex,d=nt(this.props.background,!1);return o.map(function(h,v){h.value;var p=h.background,g=ode(h,ide);if(!p)return null;var b=Gt(Gt(Gt(Gt(Gt({},g),{},{fill:"#eee"},p),d),bm(r.props,h,v)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:l,index:v,className:"recharts-bar-background-rectangle"});return I.createElement(Jk,rp({key:"background-bar-".concat(v),option:r.props.background,isActive:v===u},b))})}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,l=o.data,u=o.xAxis,d=o.yAxis,h=o.layout,v=o.children,p=Mr(v,Jf);if(!p)return null;var g=h==="vertical"?l[0].height/2:l[0].width/2,b=function(x,_){var A=Array.isArray(x.value)?x.value[1]:x.value;return{x:x.x,y:x.y,value:A,errorVal:lr(x,_)}},O={clipPath:r?"url(#clipPath-".concat(i,")"):null};return I.createElement(zt,O,p.map(function(j){return I.cloneElement(j,{key:"error-bar-".concat(i,"-").concat(j.props.dataKey),data:l,xAxis:u,yAxis:d,layout:h,offset:g,dataPointFormatter:b})}))}},{key:"render",value:function(){var r=this.props,i=r.hide,o=r.data,l=r.className,u=r.xAxis,d=r.yAxis,h=r.left,v=r.top,p=r.width,g=r.height,b=r.isAnimationActive,O=r.background,j=r.id;if(i||!o||!o.length)return null;var x=this.state.isAnimationFinished,_=rt("recharts-bar",l),A=u&&u.allowDataOverflow,E=d&&d.allowDataOverflow,C=A||E,N=Qe(j)?this.id:j;return I.createElement(zt,{className:_},A||E?I.createElement("defs",null,I.createElement("clipPath",{id:"clipPath-".concat(N)},I.createElement("rect",{x:A?h:h-p/2,y:E?v:v-g/2,width:A?p:p*2,height:E?g:g*2}))):null,I.createElement(zt,{className:"recharts-bar-rectangles",clipPath:C?"url(#clipPath-".concat(N,")"):null},O?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(C,N),(!b||x)&&Wi.renderCallByParent(this.props,o))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curData:r.data,prevData:i.curData}:r.data!==i.curData?{curData:r.data}:null}}])})(w.PureComponent);wB=Ji;Gi(Ji,"displayName","Bar");Gi(Ji,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!hc.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});Gi(Ji,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,i=e.bandSize,o=e.xAxis,l=e.yAxis,u=e.xAxisTicks,d=e.yAxisTicks,h=e.stackedData,v=e.dataStartIndex,p=e.displayedData,g=e.offset,b=Cse(r,n);if(!b)return null;var O=t.layout,j=n.type.defaultProps,x=j!==void 0?Gt(Gt({},j),n.props):n.props,_=x.dataKey,A=x.children,E=x.minPointSize,C=O==="horizontal"?l:o,N=h?C.scale.domain():null,M=Ise({numericAxis:C}),R=Mr(A,JL),D=p.map(function(z,Y){var L,F,W,Q,X,k;h?L=Tse(h[v+Y],N):(L=lr(z,_),Array.isArray(L)||(L=[M,L]));var H=ade(E,wB.defaultProps.minPointSize)(L[1],Y);if(O==="horizontal"){var B,Z=[l.scale(L[0]),l.scale(L[1])],le=Z[0],$=Z[1];F=qP({axis:o,ticks:u,bandSize:i,offset:b.offset,entry:z,index:Y}),W=(B=$??le)!==null&&B!==void 0?B:void 0,Q=b.size;var V=le-$;if(X=Number.isNaN(V)?0:V,k={x:F,y:l.y,width:Q,height:l.height},Math.abs(H)>0&&Math.abs(X)<Math.abs(H)){var q=Vr(X||H)*(Math.abs(H)-Math.abs(X));W-=q,X+=q}}else{var U=[o.scale(L[0]),o.scale(L[1])],ne=U[0],fe=U[1];if(F=ne,W=qP({axis:l,ticks:d,bandSize:i,offset:b.offset,entry:z,index:Y}),Q=fe-ne,X=b.size,k={x:o.x,y:W,width:o.width,height:X},Math.abs(H)>0&&Math.abs(Q)<Math.abs(H)){var ie=Vr(Q||H)*(Math.abs(H)-Math.abs(Q));Q+=ie}}return Gt(Gt(Gt({},z),{},{x:F,y:W,width:Q,height:X,value:h?L:L[1],payload:z,background:k},R&&R[Y]&&R[Y].props),{},{tooltipPayload:[iB(n,z)],tooltipPosition:{x:F+Q/2,y:W+X/2}})});return Gt({data:D,layout:O},g)});function Nf(e){"@babel/helpers - typeof";return Nf=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},Nf(e)}function pde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n4(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,OB(r.key),r)}}function vde(e,t,n){return t&&n4(e.prototype,t),n&&n4(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function r4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ur(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?r4(Object(n),!0).forEach(function(r){kv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function kv(e,t,n){return t=OB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OB(e){var t=gde(e,"string");return Nf(t)=="symbol"?t:t+""}function gde(e,t){if(Nf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Nf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var _B=function(t,n,r,i,o){var l=t.width,u=t.height,d=t.layout,h=t.children,v=Object.keys(n),p={left:r.left,leftMirror:r.left,right:l-r.right,rightMirror:l-r.right,top:r.top,topMirror:r.top,bottom:u-r.bottom,bottomMirror:u-r.bottom},g=!!nr(h,Ji);return v.reduce(function(b,O){var j=n[O],x=j.orientation,_=j.domain,A=j.padding,E=A===void 0?{}:A,C=j.mirror,N=j.reversed,M="".concat(x).concat(C?"Mirror":""),R,D,z,Y,L;if(j.type==="number"&&(j.padding==="gap"||j.padding==="no-gap")){var F=_[1]-_[0],W=1/0,Q=j.categoricalDomain.sort(hJ);if(Q.forEach(function(U,ne){ne>0&&(W=Math.min((U||0)-(Q[ne-1]||0),W))}),Number.isFinite(W)){var X=W/F,k=j.layout==="vertical"?r.height:r.width;if(j.padding==="gap"&&(R=X*k/2),j.padding==="no-gap"){var H=Zo(t.barCategoryGap,X*k),B=X*k/2;R=B-H-(B-H)/k*H}}}i==="xAxis"?D=[r.left+(E.left||0)+(R||0),r.left+r.width-(E.right||0)-(R||0)]:i==="yAxis"?D=d==="horizontal"?[r.top+r.height-(E.bottom||0),r.top+(E.top||0)]:[r.top+(E.top||0)+(R||0),r.top+r.height-(E.bottom||0)-(R||0)]:D=j.range,N&&(D=[D[1],D[0]]);var Z=Ase(j,o,g),le=Z.scale,$=Z.realScaleType;le.domain(_).range(D),Nse(le);var V=$se(le,Ur(Ur({},j),{},{realScaleType:$}));i==="xAxis"?(L=x==="top"&&!C||x==="bottom"&&C,z=r.left,Y=p[M]-L*j.height):i==="yAxis"&&(L=x==="left"&&!C||x==="right"&&C,z=p[M]-L*j.width,Y=r.top);var q=Ur(Ur(Ur({},j),V),{},{realScaleType:$,x:z,y:Y,scale:le,width:i==="xAxis"?r.width:j.width,height:i==="yAxis"?r.height:j.height});return q.bandSize=Fm(q,V),!j.hide&&i==="xAxis"?p[M]+=(L?-1:1)*q.height:j.hide||(p[M]+=(L?-1:1)*q.width),Ur(Ur({},b),{},kv({},O,q))},{})},EB=function(t,n){var r=t.x,i=t.y,o=n.x,l=n.y;return{x:Math.min(r,o),y:Math.min(i,l),width:Math.abs(o-r),height:Math.abs(l-i)}},yde=function(t){var n=t.x1,r=t.y1,i=t.x2,o=t.y2;return EB({x:n,y:r},{x:i,y:o})},AB=(function(){function e(t){pde(this,e),this.scale=t}return vde(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(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.bandAware,o=r.position;if(n!==void 0){if(o)switch(o){case"start":return this.scale(n);case"middle":{var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+l}case"end":{var u=this.bandwidth?this.bandwidth():0;return this.scale(n)+u}default:return this.scale(n)}if(i){var d=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+d}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),i=r[0],o=r[r.length-1];return i<=o?n>=i&&n<=o:n>=o&&n<=i}}],[{key:"create",value:function(n){return new e(n)}}])})();kv(AB,"EPS",1e-4);var T_=function(t){var n=Object.keys(t).reduce(function(r,i){return Ur(Ur({},r),{},kv({},i,AB.create(t[i])))},{});return Ur(Ur({},n),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l=o.bandAware,u=o.position;return Vfe(i,function(d,h){return n[h].apply(d,{bandAware:l,position:u})})},isInRange:function(i){return xB(i,function(o,l){return n[l].isInRange(o)})}})};function bde(e){return(e%180+180)%180}var xde=function(t){var n=t.width,r=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=bde(i),l=o*Math.PI/180,u=Math.atan(r/n),d=l>u&&l<Math.PI-u?r/Math.sin(l):n/Math.cos(l);return Math.abs(d)},N1,a4;function wde(){if(a4)return N1;a4=1;var e=io(),t=Wf(),n=bv();function r(i){return function(o,l,u){var d=Object(o);if(!t(o)){var h=e(l,3);o=n(o),l=function(p){return h(d[p],p,d)}}var v=i(o,l,u);return v>-1?d[h?o[v]:v]:void 0}}return N1=r,N1}var C1,i4;function Sde(){if(i4)return C1;i4=1;var e=vB();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return C1=t,C1}var T1,o4;function jde(){if(o4)return T1;o4=1;var e=zL(),t=io(),n=Sde(),r=Math.max;function i(o,l,u){var d=o==null?0:o.length;if(!d)return-1;var h=u==null?0:n(u);return h<0&&(h=r(d+h,0)),e(o,t(l,3),h)}return T1=i,T1}var M1,s4;function Ode(){if(s4)return M1;s4=1;var e=wde(),t=jde(),n=e(t);return M1=n,M1}var _de=Ode();const Ede=bt(_de);var Ade=tL();const Nde=bt(Ade);var Cde=Nde(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("")}),M_=w.createContext(void 0),R_=w.createContext(void 0),NB=w.createContext(void 0),CB=w.createContext({}),TB=w.createContext(void 0),MB=w.createContext(0),RB=w.createContext(0),l4=function(t){var n=t.state,r=n.xAxisMap,i=n.yAxisMap,o=n.offset,l=t.clipPathId,u=t.children,d=t.width,h=t.height,v=Cde(o);return I.createElement(M_.Provider,{value:r},I.createElement(R_.Provider,{value:i},I.createElement(CB.Provider,{value:o},I.createElement(NB.Provider,{value:v},I.createElement(TB.Provider,{value:l},I.createElement(MB.Provider,{value:h},I.createElement(RB.Provider,{value:d},u)))))))},Tde=function(){return w.useContext(TB)},DB=function(t){var n=w.useContext(M_);n==null&&es();var r=n[t];return r==null&&es(),r},Mde=function(){var t=w.useContext(M_);return Hi(t)},Rde=function(){var t=w.useContext(R_),n=Ede(t,function(r){return xB(r.domain,Number.isFinite)});return n||Hi(t)},PB=function(t){var n=w.useContext(R_);n==null&&es();var r=n[t];return r==null&&es(),r},Dde=function(){var t=w.useContext(NB);return t},Pde=function(){return w.useContext(CB)},D_=function(){return w.useContext(RB)},P_=function(){return w.useContext(MB)};function Bl(e){"@babel/helpers - typeof";return Bl=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},Bl(e)}function kde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $de(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,$B(r.key),r)}}function Ide(e,t,n){return t&&$de(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Lde(e,t,n){return t=ip(t),zde(e,kB()?Reflect.construct(t,n||[],ip(e).constructor):t.apply(e,n))}function zde(e,t){if(t&&(Bl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Bde(e)}function Bde(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function kB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(kB=function(){return!!e})()}function ip(e){return ip=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ip(e)}function qde(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&&fj(e,t)}function fj(e,t){return fj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},fj(e,t)}function c4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function u4(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?c4(Object(n),!0).forEach(function(r){k_(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function k_(e,t,n){return t=$B(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $B(e){var t=Ude(e,"string");return Bl(t)=="symbol"?t:t+""}function Ude(e,t){if(Bl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Bl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Hde(e,t){return Yde(e)||Vde(e,t)||Gde(e,t)||Fde()}function Fde(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
456
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Gde(e,t){if(e){if(typeof e=="string")return f4(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return f4(e,t)}}function f4(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Vde(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function Yde(e){if(Array.isArray(e))return e}function dj(){return dj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},dj.apply(this,arguments)}var Wde=function(t,n){var r;return I.isValidElement(t)?r=I.cloneElement(t,n):Ye(t)?r=t(n):r=I.createElement("line",dj({},n,{className:"recharts-reference-line-line"})),r},Kde=function(t,n,r,i,o,l,u,d,h){var v=o.x,p=o.y,g=o.width,b=o.height;if(r){var O=h.y,j=t.y.apply(O,{position:l});if(va(h,"discard")&&!t.y.isInRange(j))return null;var x=[{x:v+g,y:j},{x:v,y:j}];return d==="left"?x.reverse():x}if(n){var _=h.x,A=t.x.apply(_,{position:l});if(va(h,"discard")&&!t.x.isInRange(A))return null;var E=[{x:A,y:p+b},{x:A,y:p}];return u==="top"?E.reverse():E}if(i){var C=h.segment,N=C.map(function(M){return t.apply(M,{position:l})});return va(h,"discard")&&Ufe(N,function(M){return!t.isInRange(M)})?null:N}return null};function Xde(e){var t=e.x,n=e.y,r=e.segment,i=e.xAxisId,o=e.yAxisId,l=e.shape,u=e.className,d=e.alwaysShow,h=Tde(),v=DB(i),p=PB(o),g=Dde();if(!h||!g)return null;Ka(d===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var b=T_({x:v.scale,y:p.scale}),O=Zt(t),j=Zt(n),x=r&&r.length===2,_=Kde(b,O,j,x,g,e.position,v.orientation,p.orientation,e);if(!_)return null;var A=Hde(_,2),E=A[0],C=E.x,N=E.y,M=A[1],R=M.x,D=M.y,z=va(e,"hidden")?"url(#".concat(h,")"):void 0,Y=u4(u4({clipPath:z},nt(e,!0)),{},{x1:C,y1:N,x2:R,y2:D});return I.createElement(zt,{className:rt("recharts-reference-line",u)},Wde(l,Y),wn.renderCallByParent(e,yde({x1:C,y1:N,x2:R,y2:D})))}var $_=(function(e){function t(){return kde(this,t),Lde(this,t,arguments)}return qde(t,e),Ide(t,[{key:"render",value:function(){return I.createElement(Xde,this.props)}}])})(I.Component);k_($_,"displayName","ReferenceLine");k_($_,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function hj(){return hj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hj.apply(this,arguments)}function ql(e){"@babel/helpers - typeof";return ql=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},ql(e)}function d4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function h4(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?d4(Object(n),!0).forEach(function(r){$v(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Qde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zde(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,LB(r.key),r)}}function Jde(e,t,n){return t&&Zde(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function ehe(e,t,n){return t=op(t),the(e,IB()?Reflect.construct(t,n||[],op(e).constructor):t.apply(e,n))}function the(e,t){if(t&&(ql(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return nhe(e)}function nhe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function IB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(IB=function(){return!!e})()}function op(e){return op=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},op(e)}function rhe(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&&mj(e,t)}function mj(e,t){return mj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},mj(e,t)}function $v(e,t,n){return t=LB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function LB(e){var t=ahe(e,"string");return ql(t)=="symbol"?t:t+""}function ahe(e,t){if(ql(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ql(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var ihe=function(t){var n=t.x,r=t.y,i=t.xAxis,o=t.yAxis,l=T_({x:i.scale,y:o.scale}),u=l.apply({x:n,y:r},{bandAware:!0});return va(t,"discard")&&!l.isInRange(u)?null:u},Iv=(function(e){function t(){return Qde(this,t),ehe(this,t,arguments)}return rhe(t,e),Jde(t,[{key:"render",value:function(){var r=this.props,i=r.x,o=r.y,l=r.r,u=r.alwaysShow,d=r.clipPathId,h=Zt(i),v=Zt(o);if(Ka(u===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!h||!v)return null;var p=ihe(this.props);if(!p)return null;var g=p.x,b=p.y,O=this.props,j=O.shape,x=O.className,_=va(this.props,"hidden")?"url(#".concat(d,")"):void 0,A=h4(h4({clipPath:_},nt(this.props,!0)),{},{cx:g,cy:b});return I.createElement(zt,{className:rt("recharts-reference-dot",x)},t.renderDot(j,A),wn.renderCallByParent(this.props,{x:g-l,y:b-l,width:2*l,height:2*l}))}}])})(I.Component);$v(Iv,"displayName","ReferenceDot");$v(Iv,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});$v(Iv,"renderDot",function(e,t){var n;return I.isValidElement(e)?n=I.cloneElement(e,t):Ye(e)?n=e(t):n=I.createElement(C_,hj({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),n});function pj(){return pj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},pj.apply(this,arguments)}function Ul(e){"@babel/helpers - typeof";return Ul=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},Ul(e)}function m4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function p4(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?m4(Object(n),!0).forEach(function(r){Lv(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ohe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function she(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,BB(r.key),r)}}function lhe(e,t,n){return t&&she(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function che(e,t,n){return t=sp(t),uhe(e,zB()?Reflect.construct(t,n||[],sp(e).constructor):t.apply(e,n))}function uhe(e,t){if(t&&(Ul(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return fhe(e)}function fhe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function zB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(zB=function(){return!!e})()}function sp(e){return sp=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},sp(e)}function dhe(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&&vj(e,t)}function vj(e,t){return vj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},vj(e,t)}function Lv(e,t,n){return t=BB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BB(e){var t=hhe(e,"string");return Ul(t)=="symbol"?t:t+""}function hhe(e,t){if(Ul(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ul(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var mhe=function(t,n,r,i,o){var l=o.x1,u=o.x2,d=o.y1,h=o.y2,v=o.xAxis,p=o.yAxis;if(!v||!p)return null;var g=T_({x:v.scale,y:p.scale}),b={x:t?g.x.apply(l,{position:"start"}):g.x.rangeMin,y:r?g.y.apply(d,{position:"start"}):g.y.rangeMin},O={x:n?g.x.apply(u,{position:"end"}):g.x.rangeMax,y:i?g.y.apply(h,{position:"end"}):g.y.rangeMax};return va(o,"discard")&&(!g.isInRange(b)||!g.isInRange(O))?null:EB(b,O)},zv=(function(e){function t(){return ohe(this,t),che(this,t,arguments)}return dhe(t,e),lhe(t,[{key:"render",value:function(){var r=this.props,i=r.x1,o=r.x2,l=r.y1,u=r.y2,d=r.className,h=r.alwaysShow,v=r.clipPathId;Ka(h===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var p=Zt(i),g=Zt(o),b=Zt(l),O=Zt(u),j=this.props.shape;if(!p&&!g&&!b&&!O&&!j)return null;var x=mhe(p,g,b,O,this.props);if(!x&&!j)return null;var _=va(this.props,"hidden")?"url(#".concat(v,")"):void 0;return I.createElement(zt,{className:rt("recharts-reference-area",d)},t.renderRect(j,p4(p4({clipPath:_},nt(this.props,!0)),x)),wn.renderCallByParent(this.props,x))}}])})(I.Component);Lv(zv,"displayName","ReferenceArea");Lv(zv,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});Lv(zv,"renderRect",function(e,t){var n;return I.isValidElement(e)?n=I.cloneElement(e,t):Ye(e)?n=e(t):n=I.createElement(N_,pj({},t,{className:"recharts-reference-area-rect"})),n});function qB(e,t,n){if(t<1)return[];if(t===1&&n===void 0)return e;for(var r=[],i=0;i<e.length;i+=t)r.push(e[i]);return r}function phe(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return xde(r,n)}function vhe(e,t,n){var r=n==="width",i=e.x,o=e.y,l=e.width,u=e.height;return t===1?{start:r?i:o,end:r?i+l:o+u}:{start:r?i+l:o+u,end:r?i:o}}function lp(e,t,n,r,i){if(e*t<e*r||e*t>e*i)return!1;var o=n();return e*(t-e*o/2-r)>=0&&e*(t+e*o/2-i)<=0}function ghe(e,t){return qB(e,t+1)}function yhe(e,t,n,r,i){for(var o=(r||[]).slice(),l=t.start,u=t.end,d=0,h=1,v=l,p=function(){var O=r==null?void 0:r[d];if(O===void 0)return{v:qB(r,h)};var j=d,x,_=function(){return x===void 0&&(x=n(O,j)),x},A=O.coordinate,E=d===0||lp(e,A,_,v,u);E||(d=0,v=l,h+=1),E&&(v=A+e*(_()/2+i),d+=h)},g;h<=o.length;)if(g=p(),g)return g.v;return[]}function Cf(e){"@babel/helpers - typeof";return Cf=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},Cf(e)}function v4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function xn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?v4(Object(n),!0).forEach(function(r){bhe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):v4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function bhe(e,t,n){return t=xhe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xhe(e){var t=whe(e,"string");return Cf(t)=="symbol"?t:t+""}function whe(e,t){if(Cf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Cf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function She(e,t,n,r,i){for(var o=(r||[]).slice(),l=o.length,u=t.start,d=t.end,h=function(g){var b=o[g],O,j=function(){return O===void 0&&(O=n(b,g)),O};if(g===l-1){var x=e*(b.coordinate+e*j()/2-d);o[g]=b=xn(xn({},b),{},{tickCoord:x>0?b.coordinate-x*e:b.coordinate})}else o[g]=b=xn(xn({},b),{},{tickCoord:b.coordinate});var _=lp(e,b.tickCoord,j,u,d);_&&(d=b.tickCoord-e*(j()/2+i),o[g]=xn(xn({},b),{},{isShow:!0}))},v=l-1;v>=0;v--)h(v);return o}function jhe(e,t,n,r,i,o){var l=(r||[]).slice(),u=l.length,d=t.start,h=t.end;if(o){var v=r[u-1],p=n(v,u-1),g=e*(v.coordinate+e*p/2-h);l[u-1]=v=xn(xn({},v),{},{tickCoord:g>0?v.coordinate-g*e:v.coordinate});var b=lp(e,v.tickCoord,function(){return p},d,h);b&&(h=v.tickCoord-e*(p/2+i),l[u-1]=xn(xn({},v),{},{isShow:!0}))}for(var O=o?u-1:u,j=function(A){var E=l[A],C,N=function(){return C===void 0&&(C=n(E,A)),C};if(A===0){var M=e*(E.coordinate-e*N()/2-d);l[A]=E=xn(xn({},E),{},{tickCoord:M<0?E.coordinate-M*e:E.coordinate})}else l[A]=E=xn(xn({},E),{},{tickCoord:E.coordinate});var R=lp(e,E.tickCoord,N,d,h);R&&(d=E.tickCoord+e*(N()/2+i),l[A]=xn(xn({},E),{},{isShow:!0}))},x=0;x<O;x++)j(x);return l}function I_(e,t,n){var r=e.tick,i=e.ticks,o=e.viewBox,l=e.minTickGap,u=e.orientation,d=e.interval,h=e.tickFormatter,v=e.unit,p=e.angle;if(!i||!i.length||!r)return[];if(be(d)||hc.isSsr)return ghe(i,typeof d=="number"&&be(d)?d:0);var g=[],b=u==="top"||u==="bottom"?"width":"height",O=v&&b==="width"?ku(v,{fontSize:t,letterSpacing:n}):{width:0,height:0},j=function(E,C){var N=Ye(h)?h(E.value,C):E.value;return b==="width"?phe(ku(N,{fontSize:t,letterSpacing:n}),O,p):ku(N,{fontSize:t,letterSpacing:n})[b]},x=i.length>=2?Vr(i[1].coordinate-i[0].coordinate):1,_=vhe(o,x,b);return d==="equidistantPreserveStart"?yhe(x,_,j,i,l):(d==="preserveStart"||d==="preserveStartEnd"?g=jhe(x,_,j,i,l,d==="preserveStartEnd"):g=She(x,_,j,i,l),g.filter(function(A){return A.isShow}))}var Ohe=["viewBox"],_he=["viewBox"],Ehe=["ticks"];function Hl(e){"@babel/helpers - typeof";return Hl=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},Hl(e)}function hl(){return hl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hl.apply(this,arguments)}function g4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Xt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?g4(Object(n),!0).forEach(function(r){L_(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function R1(e,t){if(e==null)return{};var n=Ahe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ahe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Nhe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function y4(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,HB(r.key),r)}}function Che(e,t,n){return t&&y4(e.prototype,t),n&&y4(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function The(e,t,n){return t=cp(t),Mhe(e,UB()?Reflect.construct(t,n||[],cp(e).constructor):t.apply(e,n))}function Mhe(e,t){if(t&&(Hl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Rhe(e)}function Rhe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(UB=function(){return!!e})()}function cp(e){return cp=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},cp(e)}function Dhe(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&&gj(e,t)}function gj(e,t){return gj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},gj(e,t)}function L_(e,t,n){return t=HB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function HB(e){var t=Phe(e,"string");return Hl(t)=="symbol"?t:t+""}function Phe(e,t){if(Hl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Hl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var gc=(function(e){function t(n){var r;return Nhe(this,t),r=The(this,t,[n]),r.state={fontSize:"",letterSpacing:""},r}return Dhe(t,e),Che(t,[{key:"shouldComponentUpdate",value:function(r,i){var o=r.viewBox,l=R1(r,Ohe),u=this.props,d=u.viewBox,h=R1(u,_he);return!xl(o,d)||!xl(l,h)||!xl(i,this.state)}},{key:"componentDidMount",value:function(){var r=this.layerReference;if(r){var i=r.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];i&&this.setState({fontSize:window.getComputedStyle(i).fontSize,letterSpacing:window.getComputedStyle(i).letterSpacing})}}},{key:"getTickLineCoord",value:function(r){var i=this.props,o=i.x,l=i.y,u=i.width,d=i.height,h=i.orientation,v=i.tickSize,p=i.mirror,g=i.tickMargin,b,O,j,x,_,A,E=p?-1:1,C=r.tickSize||v,N=be(r.tickCoord)?r.tickCoord:r.coordinate;switch(h){case"top":b=O=r.coordinate,x=l+ +!p*d,j=x-E*C,A=j-E*g,_=N;break;case"left":j=x=r.coordinate,O=o+ +!p*u,b=O-E*C,_=b-E*g,A=N;break;case"right":j=x=r.coordinate,O=o+ +p*u,b=O+E*C,_=b+E*g,A=N;break;default:b=O=r.coordinate,x=l+ +p*d,j=x+E*C,A=j+E*g,_=N;break}return{line:{x1:b,y1:j,x2:O,y2:x},tick:{x:_,y:A}}}},{key:"getTickTextAnchor",value:function(){var r=this.props,i=r.orientation,o=r.mirror,l;switch(i){case"left":l=o?"start":"end";break;case"right":l=o?"end":"start";break;default:l="middle";break}return l}},{key:"getTickVerticalAnchor",value:function(){var r=this.props,i=r.orientation,o=r.mirror,l="end";switch(i){case"left":case"right":l="middle";break;case"top":l=o?"start":"end";break;default:l=o?"end":"start";break}return l}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.x,o=r.y,l=r.width,u=r.height,d=r.orientation,h=r.mirror,v=r.axisLine,p=Xt(Xt(Xt({},nt(this.props,!1)),nt(v,!1)),{},{fill:"none"});if(d==="top"||d==="bottom"){var g=+(d==="top"&&!h||d==="bottom"&&h);p=Xt(Xt({},p),{},{x1:i,y1:o+g*u,x2:i+l,y2:o+g*u})}else{var b=+(d==="left"&&!h||d==="right"&&h);p=Xt(Xt({},p),{},{x1:i+b*l,y1:o,x2:i+b*l,y2:o+u})}return I.createElement("line",hl({},p,{className:rt("recharts-cartesian-axis-line",Tr(v,"className"))}))}},{key:"renderTicks",value:function(r,i,o){var l=this,u=this.props,d=u.tickLine,h=u.stroke,v=u.tick,p=u.tickFormatter,g=u.unit,b=I_(Xt(Xt({},this.props),{},{ticks:r}),i,o),O=this.getTickTextAnchor(),j=this.getTickVerticalAnchor(),x=nt(this.props,!1),_=nt(v,!1),A=Xt(Xt({},x),{},{fill:"none"},nt(d,!1)),E=b.map(function(C,N){var M=l.getTickLineCoord(C),R=M.line,D=M.tick,z=Xt(Xt(Xt(Xt({textAnchor:O,verticalAnchor:j},x),{},{stroke:"none",fill:h},_),D),{},{index:N,payload:C,visibleTicksCount:b.length,tickFormatter:p});return I.createElement(zt,hl({className:"recharts-cartesian-axis-tick",key:"tick-".concat(C.value,"-").concat(C.coordinate,"-").concat(C.tickCoord)},bm(l.props,C,N)),d&&I.createElement("line",hl({},A,R,{className:rt("recharts-cartesian-axis-tick-line",Tr(d,"className"))})),v&&t.renderTickItem(v,z,"".concat(Ye(p)?p(C.value,N):C.value).concat(g||"")))});return I.createElement("g",{className:"recharts-cartesian-axis-ticks"},E)}},{key:"render",value:function(){var r=this,i=this.props,o=i.axisLine,l=i.width,u=i.height,d=i.ticksGenerator,h=i.className,v=i.hide;if(v)return null;var p=this.props,g=p.ticks,b=R1(p,Ehe),O=g;return Ye(d)&&(O=g&&g.length>0?d(this.props):d(b)),l<=0||u<=0||!O||!O.length?null:I.createElement(zt,{className:rt("recharts-cartesian-axis",h),ref:function(x){r.layerReference=x}},o&&this.renderAxisLine(),this.renderTicks(O,this.state.fontSize,this.state.letterSpacing),wn.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,i,o){var l,u=rt(i.className,"recharts-cartesian-axis-tick-value");return I.isValidElement(r)?l=I.cloneElement(r,Xt(Xt({},i),{},{className:u})):Ye(r)?l=r(Xt(Xt({},i),{},{className:u})):l=I.createElement(Tm,hl({},i,{className:"recharts-cartesian-axis-tick-value"}),o),l}}])})(w.Component);L_(gc,"displayName","CartesianAxis");L_(gc,"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"});var khe=["x1","y1","x2","y2","key"],$he=["offset"];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)}function b4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Sn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?b4(Object(n),!0).forEach(function(r){Ihe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ihe(e,t,n){return t=Lhe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lhe(e){var t=zhe(e,"string");return ts(t)=="symbol"?t:t+""}function zhe(e,t){if(ts(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ts(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Uo(){return Uo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Uo.apply(this,arguments)}function x4(e,t){if(e==null)return{};var n=Bhe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Bhe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var qhe=function(t){var n=t.fill;if(!n||n==="none")return null;var r=t.fillOpacity,i=t.x,o=t.y,l=t.width,u=t.height,d=t.ry;return I.createElement("rect",{x:i,y:o,ry:d,width:l,height:u,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function FB(e,t){var n;if(I.isValidElement(e))n=I.cloneElement(e,t);else if(Ye(e))n=e(t);else{var r=t.x1,i=t.y1,o=t.x2,l=t.y2,u=t.key,d=x4(t,khe),h=nt(d,!1);h.offset;var v=x4(h,$he);n=I.createElement("line",Uo({},v,{x1:r,y1:i,x2:o,y2:l,fill:"none",key:u}))}return n}function Uhe(e){var t=e.x,n=e.width,r=e.horizontal,i=r===void 0?!0:r,o=e.horizontalPoints;if(!i||!o||!o.length)return null;var l=o.map(function(u,d){var h=Sn(Sn({},e),{},{x1:t,y1:u,x2:t+n,y2:u,key:"line-".concat(d),index:d});return FB(i,h)});return I.createElement("g",{className:"recharts-cartesian-grid-horizontal"},l)}function Hhe(e){var t=e.y,n=e.height,r=e.vertical,i=r===void 0?!0:r,o=e.verticalPoints;if(!i||!o||!o.length)return null;var l=o.map(function(u,d){var h=Sn(Sn({},e),{},{x1:u,y1:t,x2:u,y2:t+n,key:"line-".concat(d),index:d});return FB(i,h)});return I.createElement("g",{className:"recharts-cartesian-grid-vertical"},l)}function Fhe(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,i=e.y,o=e.width,l=e.height,u=e.horizontalPoints,d=e.horizontal,h=d===void 0?!0:d;if(!h||!t||!t.length)return null;var v=u.map(function(g){return Math.round(g+i-i)}).sort(function(g,b){return g-b});i!==v[0]&&v.unshift(0);var p=v.map(function(g,b){var O=!v[b+1],j=O?i+l-g:v[b+1]-g;if(j<=0)return null;var x=b%t.length;return I.createElement("rect",{key:"react-".concat(b),y:g,x:r,height:j,width:o,stroke:"none",fill:t[x],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return I.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},p)}function Ghe(e){var t=e.vertical,n=t===void 0?!0:t,r=e.verticalFill,i=e.fillOpacity,o=e.x,l=e.y,u=e.width,d=e.height,h=e.verticalPoints;if(!n||!r||!r.length)return null;var v=h.map(function(g){return Math.round(g+o-o)}).sort(function(g,b){return g-b});o!==v[0]&&v.unshift(0);var p=v.map(function(g,b){var O=!v[b+1],j=O?o+u-g:v[b+1]-g;if(j<=0)return null;var x=b%r.length;return I.createElement("rect",{key:"react-".concat(b),x:g,y:l,width:j,height:d,stroke:"none",fill:r[x],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return I.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},p)}var Vhe=function(t,n){var r=t.xAxis,i=t.width,o=t.height,l=t.offset;return rB(I_(Sn(Sn(Sn({},gc.defaultProps),r),{},{ticks:Va(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),l.left,l.left+l.width,n)},Yhe=function(t,n){var r=t.yAxis,i=t.width,o=t.height,l=t.offset;return rB(I_(Sn(Sn(Sn({},gc.defaultProps),r),{},{ticks:Va(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),l.top,l.top+l.height,n)},ul={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function Bv(e){var t,n,r,i,o,l,u=D_(),d=P_(),h=Pde(),v=Sn(Sn({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:ul.stroke,fill:(n=e.fill)!==null&&n!==void 0?n:ul.fill,horizontal:(r=e.horizontal)!==null&&r!==void 0?r:ul.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:ul.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:ul.vertical,verticalFill:(l=e.verticalFill)!==null&&l!==void 0?l:ul.verticalFill,x:be(e.x)?e.x:h.left,y:be(e.y)?e.y:h.top,width:be(e.width)?e.width:h.width,height:be(e.height)?e.height:h.height}),p=v.x,g=v.y,b=v.width,O=v.height,j=v.syncWithTicks,x=v.horizontalValues,_=v.verticalValues,A=Mde(),E=Rde();if(!be(b)||b<=0||!be(O)||O<=0||!be(p)||p!==+p||!be(g)||g!==+g)return null;var C=v.verticalCoordinatesGenerator||Vhe,N=v.horizontalCoordinatesGenerator||Yhe,M=v.horizontalPoints,R=v.verticalPoints;if((!M||!M.length)&&Ye(N)){var D=x&&x.length,z=N({yAxis:E?Sn(Sn({},E),{},{ticks:D?x:E.ticks}):void 0,width:u,height:d,offset:h},D?!0:j);Ka(Array.isArray(z),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(ts(z),"]")),Array.isArray(z)&&(M=z)}if((!R||!R.length)&&Ye(C)){var Y=_&&_.length,L=C({xAxis:A?Sn(Sn({},A),{},{ticks:Y?_:A.ticks}):void 0,width:u,height:d,offset:h},Y?!0:j);Ka(Array.isArray(L),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(ts(L),"]")),Array.isArray(L)&&(R=L)}return I.createElement("g",{className:"recharts-cartesian-grid"},I.createElement(qhe,{fill:v.fill,fillOpacity:v.fillOpacity,x:v.x,y:v.y,width:v.width,height:v.height,ry:v.ry}),I.createElement(Uhe,Uo({},v,{offset:h,horizontalPoints:M,xAxis:A,yAxis:E})),I.createElement(Hhe,Uo({},v,{offset:h,verticalPoints:R,xAxis:A,yAxis:E})),I.createElement(Fhe,Uo({},v,{horizontalPoints:M})),I.createElement(Ghe,Uo({},v,{verticalPoints:R})))}Bv.displayName="CartesianGrid";var Whe=["type","layout","connectNulls","ref"],Khe=["key"];function Fl(e){"@babel/helpers - typeof";return Fl=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},Fl(e)}function w4(e,t){if(e==null)return{};var n=Xhe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Xhe(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function zu(){return zu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},zu.apply(this,arguments)}function S4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function er(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?S4(Object(n),!0).forEach(function(r){Hr(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function fl(e){return eme(e)||Jhe(e)||Zhe(e)||Qhe()}function Qhe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
457
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Zhe(e,t){if(e){if(typeof e=="string")return yj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return yj(e,t)}}function Jhe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function eme(e){if(Array.isArray(e))return yj(e)}function yj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function tme(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j4(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,VB(r.key),r)}}function nme(e,t,n){return t&&j4(e.prototype,t),n&&j4(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function rme(e,t,n){return t=up(t),ame(e,GB()?Reflect.construct(t,n||[],up(e).constructor):t.apply(e,n))}function ame(e,t){if(t&&(Fl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return ime(e)}function ime(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function GB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(GB=function(){return!!e})()}function up(e){return up=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},up(e)}function ome(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&&bj(e,t)}function bj(e,t){return bj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},bj(e,t)}function Hr(e,t,n){return t=VB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function VB(e){var t=sme(e,"string");return Fl(t)=="symbol"?t:t+""}function sme(e,t){if(Fl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Fl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Er=(function(e){function t(){var n;tme(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=rme(this,t,[].concat(i)),Hr(n,"state",{isAnimationFinished:!0,totalLength:0}),Hr(n,"generateSimpleStrokeDasharray",function(l,u){return"".concat(u,"px ").concat(l-u,"px")}),Hr(n,"getStrokeDasharray",function(l,u,d){var h=d.reduce(function(_,A){return _+A});if(!h)return n.generateSimpleStrokeDasharray(u,l);for(var v=Math.floor(l/h),p=l%h,g=u-l,b=[],O=0,j=0;O<d.length;j+=d[O],++O)if(j+d[O]>p){b=[].concat(fl(d.slice(0,O)),[p-j]);break}var x=b.length%2===0?[0,g]:[g];return[].concat(fl(t.repeat(d,v)),fl(b),x).map(function(_){return"".concat(_,"px")}).join(", ")}),Hr(n,"id",Yf("recharts-line-")),Hr(n,"pathRef",function(l){n.mainCurve=l}),Hr(n,"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),Hr(n,"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return ome(t,e),nme(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();this.setState({totalLength:r})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();r!==this.state.totalLength&&this.setState({totalLength:r})}}},{key:"getTotalLength",value:function(){var r=this.mainCurve;try{return r&&r.getTotalLength&&r.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,l=o.points,u=o.xAxis,d=o.yAxis,h=o.layout,v=o.children,p=Mr(v,Jf);if(!p)return null;var g=function(j,x){return{x:j.x,y:j.y,value:j.value,errorVal:lr(j.payload,x)}},b={clipPath:r?"url(#clipPath-".concat(i,")"):null};return I.createElement(zt,b,p.map(function(O){return I.cloneElement(O,{key:"bar-".concat(O.props.dataKey),data:l,xAxis:u,yAxis:d,layout:h,dataPointFormatter:g})}))}},{key:"renderDots",value:function(r,i,o){var l=this.props.isAnimationActive;if(l&&!this.state.isAnimationFinished)return null;var u=this.props,d=u.dot,h=u.points,v=u.dataKey,p=nt(this.props,!1),g=nt(d,!0),b=h.map(function(j,x){var _=er(er(er({key:"dot-".concat(x),r:3},p),g),{},{index:x,cx:j.x,cy:j.y,value:j.value,dataKey:v,payload:j.payload,points:h});return t.renderDotItem(d,_)}),O={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return I.createElement(zt,zu({className:"recharts-line-dots",key:"dots"},O),b)}},{key:"renderCurveStatically",value:function(r,i,o,l){var u=this.props,d=u.type,h=u.layout,v=u.connectNulls;u.ref;var p=w4(u,Whe),g=er(er(er({},nt(p,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:r},l),{},{type:d,layout:h,connectNulls:v});return I.createElement(XS,zu({},g,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(r,i){var o=this,l=this.props,u=l.points,d=l.strokeDasharray,h=l.isAnimationActive,v=l.animationBegin,p=l.animationDuration,g=l.animationEasing,b=l.animationId,O=l.animateNewValues,j=l.width,x=l.height,_=this.state,A=_.prevPoints,E=_.totalLength;return I.createElement(oi,{begin:v,duration:p,isActive:h,easing:g,from:{t:0},to:{t:1},key:"line-".concat(b),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(C){var N=C.t;if(A){var M=A.length/u.length,R=u.map(function(F,W){var Q=Math.floor(W*M);if(A[Q]){var X=A[Q],k=Fr(X.x,F.x),H=Fr(X.y,F.y);return er(er({},F),{},{x:k(N),y:H(N)})}if(O){var B=Fr(j*2,F.x),Z=Fr(x/2,F.y);return er(er({},F),{},{x:B(N),y:Z(N)})}return er(er({},F),{},{x:F.x,y:F.y})});return o.renderCurveStatically(R,r,i)}var D=Fr(0,E),z=D(N),Y;if(d){var L="".concat(d).split(/[,\s]+/gim).map(function(F){return parseFloat(F)});Y=o.getStrokeDasharray(z,E,L)}else Y=o.generateSimpleStrokeDasharray(E,z);return o.renderCurveStatically(u,r,i,{strokeDasharray:Y})})}},{key:"renderCurve",value:function(r,i){var o=this.props,l=o.points,u=o.isAnimationActive,d=this.state,h=d.prevPoints,v=d.totalLength;return u&&l&&l.length&&(!h&&v>0||!Tv(h,l))?this.renderCurveWithAnimation(r,i):this.renderCurveStatically(l,r,i)}},{key:"render",value:function(){var r,i=this.props,o=i.hide,l=i.dot,u=i.points,d=i.className,h=i.xAxis,v=i.yAxis,p=i.top,g=i.left,b=i.width,O=i.height,j=i.isAnimationActive,x=i.id;if(o||!u||!u.length)return null;var _=this.state.isAnimationFinished,A=u.length===1,E=rt("recharts-line",d),C=h&&h.allowDataOverflow,N=v&&v.allowDataOverflow,M=C||N,R=Qe(x)?this.id:x,D=(r=nt(l,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},z=D.r,Y=z===void 0?3:z,L=D.strokeWidth,F=L===void 0?2:L,W=SJ(l)?l:{},Q=W.clipDot,X=Q===void 0?!0:Q,k=Y*2+F;return I.createElement(zt,{className:E},C||N?I.createElement("defs",null,I.createElement("clipPath",{id:"clipPath-".concat(R)},I.createElement("rect",{x:C?g:g-b/2,y:N?p:p-O/2,width:C?b:b*2,height:N?O:O*2})),!X&&I.createElement("clipPath",{id:"clipPath-dots-".concat(R)},I.createElement("rect",{x:g-k/2,y:p-k/2,width:b+k,height:O+k}))):null,!A&&this.renderCurve(M,R),this.renderErrorBar(M,R),(A||l)&&this.renderDots(M,X,R),(!j||_)&&Wi.renderCallByParent(this.props,u))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,prevPoints:i.curPoints}:r.points!==i.curPoints?{curPoints:r.points}:null}},{key:"repeat",value:function(r,i){for(var o=r.length%2!==0?[].concat(fl(r),[0]):r,l=[],u=0;u<i;++u)l=[].concat(fl(l),fl(o));return l}},{key:"renderDotItem",value:function(r,i){var o;if(I.isValidElement(r))o=I.cloneElement(r,i);else if(Ye(r))o=r(i);else{var l=i.key,u=w4(i,Khe),d=rt("recharts-line-dot",typeof r!="boolean"?r.className:"");o=I.createElement(C_,zu({key:l},u,{className:d}))}return o}}])})(w.PureComponent);Hr(Er,"displayName","Line");Hr(Er,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!hc.isSsr,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1});Hr(Er,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,i=e.xAxisTicks,o=e.yAxisTicks,l=e.dataKey,u=e.bandSize,d=e.displayedData,h=e.offset,v=t.layout,p=d.map(function(g,b){var O=lr(g,l);return v==="horizontal"?{x:BP({axis:n,ticks:i,bandSize:u,entry:g,index:b}),y:Qe(O)?null:r.scale(O),value:O,payload:g}:{x:Qe(O)?null:n.scale(O),y:BP({axis:r,ticks:o,bandSize:u,entry:g,index:b}),value:O,payload:g}});return er({points:p,layout:v},h)});function Gl(e){"@babel/helpers - typeof";return Gl=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},Gl(e)}function lme(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cme(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,KB(r.key),r)}}function ume(e,t,n){return t&&cme(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function fme(e,t,n){return t=fp(t),dme(e,YB()?Reflect.construct(t,n||[],fp(e).constructor):t.apply(e,n))}function dme(e,t){if(t&&(Gl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return hme(e)}function hme(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function YB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(YB=function(){return!!e})()}function fp(e){return fp=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},fp(e)}function mme(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&&xj(e,t)}function xj(e,t){return xj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},xj(e,t)}function WB(e,t,n){return t=KB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function KB(e){var t=pme(e,"string");return Gl(t)=="symbol"?t:t+""}function pme(e,t){if(Gl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Gl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function wj(){return wj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wj.apply(this,arguments)}function vme(e){var t=e.xAxisId,n=D_(),r=P_(),i=DB(t);return i==null?null:w.createElement(gc,wj({},i,{className:rt("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(l){return Va(l,!0)}}))}var hs=(function(e){function t(){return lme(this,t),fme(this,t,arguments)}return mme(t,e),ume(t,[{key:"render",value:function(){return w.createElement(vme,this.props)}}])})(w.Component);WB(hs,"displayName","XAxis");WB(hs,"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 Vl(e){"@babel/helpers - typeof";return Vl=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},Vl(e)}function gme(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yme(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,ZB(r.key),r)}}function bme(e,t,n){return t&&yme(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function xme(e,t,n){return t=dp(t),wme(e,XB()?Reflect.construct(t,n||[],dp(e).constructor):t.apply(e,n))}function wme(e,t){if(t&&(Vl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Sme(e)}function Sme(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function XB(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(XB=function(){return!!e})()}function dp(e){return dp=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},dp(e)}function jme(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&&Sj(e,t)}function Sj(e,t){return Sj=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Sj(e,t)}function QB(e,t,n){return t=ZB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ZB(e){var t=Ome(e,"string");return Vl(t)=="symbol"?t:t+""}function Ome(e,t){if(Vl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Vl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function jj(){return jj=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jj.apply(this,arguments)}var _me=function(t){var n=t.yAxisId,r=D_(),i=P_(),o=PB(n);return o==null?null:w.createElement(gc,jj({},o,{className:rt("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:r,height:i},ticksGenerator:function(u){return Va(u,!0)}}))},si=(function(e){function t(){return gme(this,t),xme(this,t,arguments)}return jme(t,e),bme(t,[{key:"render",value:function(){return w.createElement(_me,this.props)}}])})(w.Component);QB(si,"displayName","YAxis");QB(si,"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 O4(e){return Cme(e)||Nme(e)||Ame(e)||Eme()}function Eme(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
458
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ame(e,t){if(e){if(typeof e=="string")return Oj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Oj(e,t)}}function Nme(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Cme(e){if(Array.isArray(e))return Oj(e)}function Oj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var _j=function(t,n,r,i,o){var l=Mr(t,$_),u=Mr(t,Iv),d=[].concat(O4(l),O4(u)),h=Mr(t,zv),v="".concat(i,"Id"),p=i[0],g=n;if(d.length&&(g=d.reduce(function(j,x){if(x.props[v]===r&&va(x.props,"extendDomain")&&be(x.props[p])){var _=x.props[p];return[Math.min(j[0],_),Math.max(j[1],_)]}return j},g)),h.length){var b="".concat(p,"1"),O="".concat(p,"2");g=h.reduce(function(j,x){if(x.props[v]===r&&va(x.props,"extendDomain")&&be(x.props[b])&&be(x.props[O])){var _=x.props[b],A=x.props[O];return[Math.min(j[0],_,A),Math.max(j[1],_,A)]}return j},g)}return o&&o.length&&(g=o.reduce(function(j,x){return be(x)?[Math.min(j[0],x),Math.max(j[1],x)]:j},g)),g},D1={exports:{}},_4;function Tme(){return _4||(_4=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(d,h,v){this.fn=d,this.context=h,this.once=v||!1}function o(d,h,v,p,g){if(typeof v!="function")throw new TypeError("The listener must be a function");var b=new i(v,p||d,g),O=n?n+h:h;return d._events[O]?d._events[O].fn?d._events[O]=[d._events[O],b]:d._events[O].push(b):(d._events[O]=b,d._eventsCount++),d}function l(d,h){--d._eventsCount===0?d._events=new r:delete d._events[h]}function u(){this._events=new r,this._eventsCount=0}u.prototype.eventNames=function(){var h=[],v,p;if(this._eventsCount===0)return h;for(p in v=this._events)t.call(v,p)&&h.push(n?p.slice(1):p);return Object.getOwnPropertySymbols?h.concat(Object.getOwnPropertySymbols(v)):h},u.prototype.listeners=function(h){var v=n?n+h:h,p=this._events[v];if(!p)return[];if(p.fn)return[p.fn];for(var g=0,b=p.length,O=new Array(b);g<b;g++)O[g]=p[g].fn;return O},u.prototype.listenerCount=function(h){var v=n?n+h:h,p=this._events[v];return p?p.fn?1:p.length:0},u.prototype.emit=function(h,v,p,g,b,O){var j=n?n+h:h;if(!this._events[j])return!1;var x=this._events[j],_=arguments.length,A,E;if(x.fn){switch(x.once&&this.removeListener(h,x.fn,void 0,!0),_){case 1:return x.fn.call(x.context),!0;case 2:return x.fn.call(x.context,v),!0;case 3:return x.fn.call(x.context,v,p),!0;case 4:return x.fn.call(x.context,v,p,g),!0;case 5:return x.fn.call(x.context,v,p,g,b),!0;case 6:return x.fn.call(x.context,v,p,g,b,O),!0}for(E=1,A=new Array(_-1);E<_;E++)A[E-1]=arguments[E];x.fn.apply(x.context,A)}else{var C=x.length,N;for(E=0;E<C;E++)switch(x[E].once&&this.removeListener(h,x[E].fn,void 0,!0),_){case 1:x[E].fn.call(x[E].context);break;case 2:x[E].fn.call(x[E].context,v);break;case 3:x[E].fn.call(x[E].context,v,p);break;case 4:x[E].fn.call(x[E].context,v,p,g);break;default:if(!A)for(N=1,A=new Array(_-1);N<_;N++)A[N-1]=arguments[N];x[E].fn.apply(x[E].context,A)}}return!0},u.prototype.on=function(h,v,p){return o(this,h,v,p,!1)},u.prototype.once=function(h,v,p){return o(this,h,v,p,!0)},u.prototype.removeListener=function(h,v,p,g){var b=n?n+h:h;if(!this._events[b])return this;if(!v)return l(this,b),this;var O=this._events[b];if(O.fn)O.fn===v&&(!g||O.once)&&(!p||O.context===p)&&l(this,b);else{for(var j=0,x=[],_=O.length;j<_;j++)(O[j].fn!==v||g&&!O[j].once||p&&O[j].context!==p)&&x.push(O[j]);x.length?this._events[b]=x.length===1?x[0]:x:l(this,b)}return this},u.prototype.removeAllListeners=function(h){var v;return h?(v=n?n+h:h,this._events[v]&&l(this,v)):(this._events=new r,this._eventsCount=0),this},u.prototype.off=u.prototype.removeListener,u.prototype.addListener=u.prototype.on,u.prefixed=n,u.EventEmitter=u,e.exports=u})(D1)),D1.exports}var Mme=Tme();const Rme=bt(Mme);var P1=new Rme,k1="recharts.syncMouseEvents";function Tf(e){"@babel/helpers - typeof";return Tf=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},Tf(e)}function Dme(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Pme(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,JB(r.key),r)}}function kme(e,t,n){return t&&Pme(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function $1(e,t,n){return t=JB(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function JB(e){var t=$me(e,"string");return Tf(t)=="symbol"?t:t+""}function $me(e,t){if(Tf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Tf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ime=(function(){function e(){Dme(this,e),$1(this,"activeIndex",0),$1(this,"coordinateList",[]),$1(this,"layout","horizontal")}return kme(e,[{key:"setDetails",value:function(n){var r,i=n.coordinateList,o=i===void 0?null:i,l=n.container,u=l===void 0?null:l,d=n.layout,h=d===void 0?null:d,v=n.offset,p=v===void 0?null:v,g=n.mouseHandlerCallback,b=g===void 0?null:g;this.coordinateList=(r=o??this.coordinateList)!==null&&r!==void 0?r:[],this.container=u??this.container,this.layout=h??this.layout,this.offset=p??this.offset,this.mouseHandlerCallback=b??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(n){if(this.coordinateList.length!==0)switch(n.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(n){this.activeIndex=n}},{key:"spoofMouse",value:function(){var n,r;if(this.layout==="horizontal"&&this.coordinateList.length!==0){var i=this.container.getBoundingClientRect(),o=i.x,l=i.y,u=i.height,d=this.coordinateList[this.activeIndex].coordinate,h=((n=window)===null||n===void 0?void 0:n.scrollX)||0,v=((r=window)===null||r===void 0?void 0:r.scrollY)||0,p=o+d+h,g=l+this.offset.top+u/2+v;this.mouseHandlerCallback({pageX:p,pageY:g})}}}])})();function Lme(e,t,n){if(n==="number"&&t===!0&&Array.isArray(e)){var r=e==null?void 0:e[0],i=e==null?void 0:e[1];if(r&&i&&be(r)&&be(i))return!0}return!1}function zme(e,t,n,r){var i=r/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-i:n.left+.5,y:e==="horizontal"?n.top+.5:t.y-i,width:e==="horizontal"?r:n.width-1,height:e==="horizontal"?n.height-1:r}}function e6(e){var t=e.cx,n=e.cy,r=e.radius,i=e.startAngle,o=e.endAngle,l=vn(t,n,r,i),u=vn(t,n,r,o);return{points:[l,u],cx:t,cy:n,radius:r,startAngle:i,endAngle:o}}function Bme(e,t,n){var r,i,o,l;if(e==="horizontal")r=t.x,o=r,i=n.top,l=n.top+n.height;else if(e==="vertical")i=t.y,l=i,r=n.left,o=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var u=t.cx,d=t.cy,h=t.innerRadius,v=t.outerRadius,p=t.angle,g=vn(u,d,h,p),b=vn(u,d,v,p);r=g.x,i=g.y,o=b.x,l=b.y}else return e6(t);return[{x:r,y:i},{x:o,y:l}]}function Mf(e){"@babel/helpers - typeof";return Mf=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},Mf(e)}function E4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ih(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?E4(Object(n),!0).forEach(function(r){qme(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qme(e,t,n){return t=Ume(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ume(e){var t=Hme(e,"string");return Mf(t)=="symbol"?t:t+""}function Hme(e,t){if(Mf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Mf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Fme(e){var t,n,r=e.element,i=e.tooltipEventType,o=e.isActive,l=e.activeCoordinate,u=e.activePayload,d=e.offset,h=e.activeTooltipIndex,v=e.tooltipAxisBandSize,p=e.layout,g=e.chartName,b=(t=r.props.cursor)!==null&&t!==void 0?t:(n=r.type.defaultProps)===null||n===void 0?void 0:n.cursor;if(!r||!b||!o||!l||g!=="ScatterChart"&&i!=="axis")return null;var O,j=XS;if(g==="ScatterChart")O=l,j=Uue;else if(g==="BarChart")O=zme(p,l,d,v),j=N_;else if(p==="radial"){var x=e6(l),_=x.cx,A=x.cy,E=x.radius,C=x.startAngle,N=x.endAngle;O={cx:_,cy:A,startAngle:C,endAngle:N,innerRadius:E,outerRadius:E},j=lB}else O={points:Bme(p,l,d)},j=XS;var M=Ih(Ih(Ih(Ih({stroke:"#ccc",pointerEvents:"none"},d),O),nt(b,!1)),{},{payload:u,payloadIndex:h,className:rt("recharts-tooltip-cursor",b.className)});return w.isValidElement(b)?w.cloneElement(b,M):w.createElement(j,M)}var Gme=["item"],Vme=["children","className","width","height","style","compact","title","desc"];function Yl(e){"@babel/helpers - typeof";return Yl=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},Yl(e)}function ml(){return ml=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ml.apply(this,arguments)}function A4(e,t){return Kme(e)||Wme(e,t)||n6(e,t)||Yme()}function Yme(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
459
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wme(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,l,u=[],d=!0,h=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(d=(r=o.call(n)).done)&&(u.push(r.value),u.length!==t);d=!0);}catch(v){h=!0,i=v}finally{try{if(!d&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(h)throw i}}return u}}function Kme(e){if(Array.isArray(e))return e}function N4(e,t){if(e==null)return{};var n=Xme(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Xme(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Qme(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zme(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r6(r.key),r)}}function Jme(e,t,n){return t&&Zme(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function epe(e,t,n){return t=hp(t),tpe(e,t6()?Reflect.construct(t,n||[],hp(e).constructor):t.apply(e,n))}function tpe(e,t){if(t&&(Yl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return npe(e)}function npe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function t6(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(t6=function(){return!!e})()}function hp(e){return hp=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},hp(e)}function rpe(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&&Ej(e,t)}function Ej(e,t){return Ej=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Ej(e,t)}function Wl(e){return ope(e)||ipe(e)||n6(e)||ape()}function ape(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
460
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function n6(e,t){if(e){if(typeof e=="string")return Aj(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Aj(e,t)}}function ipe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function ope(e){if(Array.isArray(e))return Aj(e)}function Aj(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function C4(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ue(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?C4(Object(n),!0).forEach(function(r){Pe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C4(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Pe(e,t,n){return t=r6(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r6(e){var t=spe(e,"string");return Yl(t)=="symbol"?t:t+""}function spe(e,t){if(Yl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Yl(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var lpe={xAxis:["bottom","top"],yAxis:["left","right"]},cpe={width:"100%",height:"100%"},a6={x:0,y:0};function Lh(e){return e}var upe=function(t,n){return n==="horizontal"?t.x:n==="vertical"?t.y:n==="centric"?t.angle:t.radius},fpe=function(t,n,r,i){var o=n.find(function(v){return v&&v.index===r});if(o){if(t==="horizontal")return{x:o.coordinate,y:i.y};if(t==="vertical")return{x:i.x,y:o.coordinate};if(t==="centric"){var l=o.coordinate,u=i.radius;return ue(ue(ue({},i),vn(i.cx,i.cy,u,l)),{},{angle:l,radius:u})}var d=o.coordinate,h=i.angle;return ue(ue(ue({},i),vn(i.cx,i.cy,d,h)),{},{angle:h,radius:d})}return a6},qv=function(t,n){var r=n.graphicalItems,i=n.dataStartIndex,o=n.dataEndIndex,l=(r??[]).reduce(function(u,d){var h=d.props.data;return h&&h.length?[].concat(Wl(u),Wl(h)):u},[]);return l.length>0?l:t&&t.length&&be(i)&&be(o)?t.slice(i,o+1):[]};function i6(e){return e==="number"?[0,"auto"]:void 0}var Nj=function(t,n,r,i){var o=t.graphicalItems,l=t.tooltipAxis,u=qv(n,t);return r<0||!o||!o.length||r>=u.length?null:o.reduce(function(d,h){var v,p=(v=h.props.data)!==null&&v!==void 0?v:n;p&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=r&&(p=p.slice(t.dataStartIndex,t.dataEndIndex+1));var g;if(l.dataKey&&!l.allowDuplicatedCategory){var b=p===void 0?u:p;g=gm(b,l.dataKey,i)}else g=p&&p[r]||u[r];return g?[].concat(Wl(d),[iB(h,g)]):d},[])},T4=function(t,n,r,i){var o=i||{x:t.chartX,y:t.chartY},l=upe(o,r),u=t.orderedTooltipTicks,d=t.tooltipAxis,h=t.tooltipTicks,v=wse(l,u,h,d);if(v>=0&&h){var p=h[v]&&h[v].value,g=Nj(t,n,v,p),b=fpe(r,u,v,o);return{activeTooltipIndex:v,activeLabel:p,activePayload:g,activeCoordinate:b}}return null},dpe=function(t,n){var r=n.axes,i=n.graphicalItems,o=n.axisType,l=n.axisIdKey,u=n.stackGroups,d=n.dataStartIndex,h=n.dataEndIndex,v=t.layout,p=t.children,g=t.stackOffset,b=nB(v,o);return r.reduce(function(O,j){var x,_=j.type.defaultProps!==void 0?ue(ue({},j.type.defaultProps),j.props):j.props,A=_.type,E=_.dataKey,C=_.allowDataOverflow,N=_.allowDuplicatedCategory,M=_.scale,R=_.ticks,D=_.includeHidden,z=_[l];if(O[z])return O;var Y=qv(t.data,{graphicalItems:i.filter(function(V){var q,U=l in V.props?V.props[l]:(q=V.type.defaultProps)===null||q===void 0?void 0:q[l];return U===z}),dataStartIndex:d,dataEndIndex:h}),L=Y.length,F,W,Q;Lme(_.domain,C,A)&&(F=GS(_.domain,null,C),b&&(A==="number"||M!=="auto")&&(Q=Iu(Y,E,"category")));var X=i6(A);if(!F||F.length===0){var k,H=(k=_.domain)!==null&&k!==void 0?k:X;if(E){if(F=Iu(Y,E,A),A==="category"&&b){var B=dJ(F);N&&B?(W=F,F=ep(0,L)):N||(F=FP(H,F,j).reduce(function(V,q){return V.indexOf(q)>=0?V:[].concat(Wl(V),[q])},[]))}else if(A==="category")N?F=F.filter(function(V){return V!==""&&!Qe(V)}):F=FP(H,F,j).reduce(function(V,q){return V.indexOf(q)>=0||q===""||Qe(q)?V:[].concat(Wl(V),[q])},[]);else if(A==="number"){var Z=Ese(Y,i.filter(function(V){var q,U,ne=l in V.props?V.props[l]:(q=V.type.defaultProps)===null||q===void 0?void 0:q[l],fe="hide"in V.props?V.props.hide:(U=V.type.defaultProps)===null||U===void 0?void 0:U.hide;return ne===z&&(D||!fe)}),E,o,v);Z&&(F=Z)}b&&(A==="number"||M!=="auto")&&(Q=Iu(Y,E,"category"))}else b?F=ep(0,L):u&&u[z]&&u[z].hasStack&&A==="number"?F=g==="expand"?[0,1]:aB(u[z].stackGroups,d,h):F=tB(Y,i.filter(function(V){var q=l in V.props?V.props[l]:V.type.defaultProps[l],U="hide"in V.props?V.props.hide:V.type.defaultProps.hide;return q===z&&(D||!U)}),A,v,!0);if(A==="number")F=_j(p,F,z,o,R),H&&(F=GS(H,F,C));else if(A==="category"&&H){var le=H,$=F.every(function(V){return le.indexOf(V)>=0});$&&(F=le)}}return ue(ue({},O),{},Pe({},z,ue(ue({},_),{},{axisType:o,domain:F,categoricalDomain:Q,duplicateDomain:W,originalDomain:(x=_.domain)!==null&&x!==void 0?x:X,isCategorical:b,layout:v})))},{})},hpe=function(t,n){var r=n.graphicalItems,i=n.Axis,o=n.axisType,l=n.axisIdKey,u=n.stackGroups,d=n.dataStartIndex,h=n.dataEndIndex,v=t.layout,p=t.children,g=qv(t.data,{graphicalItems:r,dataStartIndex:d,dataEndIndex:h}),b=g.length,O=nB(v,o),j=-1;return r.reduce(function(x,_){var A=_.type.defaultProps!==void 0?ue(ue({},_.type.defaultProps),_.props):_.props,E=A[l],C=i6("number");if(!x[E]){j++;var N;return O?N=ep(0,b):u&&u[E]&&u[E].hasStack?(N=aB(u[E].stackGroups,d,h),N=_j(p,N,E,o)):(N=GS(C,tB(g,r.filter(function(M){var R,D,z=l in M.props?M.props[l]:(R=M.type.defaultProps)===null||R===void 0?void 0:R[l],Y="hide"in M.props?M.props.hide:(D=M.type.defaultProps)===null||D===void 0?void 0:D.hide;return z===E&&!Y}),"number",v),i.defaultProps.allowDataOverflow),N=_j(p,N,E,o)),ue(ue({},x),{},Pe({},E,ue(ue({axisType:o},i.defaultProps),{},{hide:!0,orientation:Tr(lpe,"".concat(o,".").concat(j%2),null),domain:N,originalDomain:C,isCategorical:O,layout:v})))}return x},{})},mpe=function(t,n){var r=n.axisType,i=r===void 0?"xAxis":r,o=n.AxisComp,l=n.graphicalItems,u=n.stackGroups,d=n.dataStartIndex,h=n.dataEndIndex,v=t.children,p="".concat(i,"Id"),g=Mr(v,o),b={};return g&&g.length?b=dpe(t,{axes:g,graphicalItems:l,axisType:i,axisIdKey:p,stackGroups:u,dataStartIndex:d,dataEndIndex:h}):l&&l.length&&(b=hpe(t,{Axis:o,graphicalItems:l,axisType:i,axisIdKey:p,stackGroups:u,dataStartIndex:d,dataEndIndex:h})),b},ppe=function(t){var n=Hi(t),r=Va(n,!1,!0);return{tooltipTicks:r,orderedTooltipTicks:e_(r,function(i){return i.coordinate}),tooltipAxis:n,tooltipAxisBandSize:Fm(n,r)}},M4=function(t){var n=t.children,r=t.defaultShowTooltip,i=nr(n,Ll),o=0,l=0;return t.data&&t.data.length!==0&&(l=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(o=i.props.startIndex),i.props.endIndex>=0&&(l=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:l,activeTooltipIndex:-1,isTooltipActive:!!r}},vpe=function(t){return!t||!t.length?!1:t.some(function(n){var r=Wa(n&&n.type);return r&&r.indexOf("Bar")>=0})},R4=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"}},gpe=function(t,n){var r=t.props,i=t.graphicalItems,o=t.xAxisMap,l=o===void 0?{}:o,u=t.yAxisMap,d=u===void 0?{}:u,h=r.width,v=r.height,p=r.children,g=r.margin||{},b=nr(p,Ll),O=nr(p,Xa),j=Object.keys(d).reduce(function(N,M){var R=d[M],D=R.orientation;return!R.mirror&&!R.hide?ue(ue({},N),{},Pe({},D,N[D]+R.width)):N},{left:g.left||0,right:g.right||0}),x=Object.keys(l).reduce(function(N,M){var R=l[M],D=R.orientation;return!R.mirror&&!R.hide?ue(ue({},N),{},Pe({},D,Tr(N,"".concat(D))+R.height)):N},{top:g.top||0,bottom:g.bottom||0}),_=ue(ue({},x),j),A=_.bottom;b&&(_.bottom+=b.props.height||Ll.defaultProps.height),O&&n&&(_=Ose(_,i,r,n));var E=h-_.left-_.right,C=v-_.top-_.bottom;return ue(ue({brushBottom:A},_),{},{width:Math.max(E,0),height:Math.max(C,0)})},ype=function(t,n){if(n==="xAxis")return t[n].width;if(n==="yAxis")return t[n].height},o6=function(t){var n=t.chartName,r=t.GraphicalChild,i=t.defaultTooltipEventType,o=i===void 0?"axis":i,l=t.validateTooltipEventTypes,u=l===void 0?["axis"]:l,d=t.axisComponents,h=t.legendContent,v=t.formatAxisMap,p=t.defaultProps,g=function(_,A){var E=A.graphicalItems,C=A.stackGroups,N=A.offset,M=A.updateId,R=A.dataStartIndex,D=A.dataEndIndex,z=_.barSize,Y=_.layout,L=_.barGap,F=_.barCategoryGap,W=_.maxBarSize,Q=R4(Y),X=Q.numericAxisName,k=Q.cateAxisName,H=vpe(E),B=[];return E.forEach(function(Z,le){var $=qv(_.data,{graphicalItems:[Z],dataStartIndex:R,dataEndIndex:D}),V=Z.type.defaultProps!==void 0?ue(ue({},Z.type.defaultProps),Z.props):Z.props,q=V.dataKey,U=V.maxBarSize,ne=V["".concat(X,"Id")],fe=V["".concat(k,"Id")],ie={},pe=d.reduce(function(Gn,Mt){var fr=A["".concat(Mt.axisType,"Map")],tn=V["".concat(Mt.axisType,"Id")];fr&&fr[tn]||Mt.axisType==="zAxis"||es();var ms=fr[tn];return ue(ue({},Gn),{},Pe(Pe({},Mt.axisType,ms),"".concat(Mt.axisType,"Ticks"),Va(ms)))},ie),re=pe[k],ve=pe["".concat(k,"Ticks")],ge=C&&C[ne]&&C[ne].hasStack&&Lse(Z,C[ne].stackGroups),oe=Wa(Z.type).indexOf("Bar")>=0,ke=Fm(re,ve),we=[],Ie=H&&Sse({barSize:z,stackGroups:C,totalSize:ype(pe,k)});if(oe){var Ze,lt,en=Qe(U)?W:U,mt=(Ze=(lt=Fm(re,ve,!0))!==null&&lt!==void 0?lt:en)!==null&&Ze!==void 0?Ze:0;we=jse({barGap:L,barCategoryGap:F,bandSize:mt!==ke?mt:ke,sizeList:Ie[fe],maxBarSize:en}),mt!==ke&&(we=we.map(function(Gn){return ue(ue({},Gn),{},{position:ue(ue({},Gn.position),{},{offset:Gn.position.offset-mt/2})})}))}var ur=Z&&Z.type&&Z.type.getComposedData;ur&&B.push({props:ue(ue({},ur(ue(ue({},pe),{},{displayedData:$,props:_,dataKey:q,item:Z,bandSize:ke,barPosition:we,offset:N,stackedData:ge,layout:Y,dataStartIndex:R,dataEndIndex:D}))),{},Pe(Pe(Pe({key:Z.key||"item-".concat(le)},X,pe[X]),k,pe[k]),"animationId",M)),childIndex:_J(Z,_.children),item:Z})}),B},b=function(_,A){var E=_.props,C=_.dataStartIndex,N=_.dataEndIndex,M=_.updateId;if(!aM({props:E}))return null;var R=E.children,D=E.layout,z=E.stackOffset,Y=E.data,L=E.reverseStackOrder,F=R4(D),W=F.numericAxisName,Q=F.cateAxisName,X=Mr(R,r),k=kse(Y,X,"".concat(W,"Id"),"".concat(Q,"Id"),z,L),H=d.reduce(function(V,q){var U="".concat(q.axisType,"Map");return ue(ue({},V),{},Pe({},U,mpe(E,ue(ue({},q),{},{graphicalItems:X,stackGroups:q.axisType===W&&k,dataStartIndex:C,dataEndIndex:N}))))},{}),B=gpe(ue(ue({},H),{},{props:E,graphicalItems:X}),A==null?void 0:A.legendBBox);Object.keys(H).forEach(function(V){H[V]=v(E,H[V],B,V.replace("Map",""),n)});var Z=H["".concat(Q,"Map")],le=ppe(Z),$=g(E,ue(ue({},H),{},{dataStartIndex:C,dataEndIndex:N,updateId:M,graphicalItems:X,stackGroups:k,offset:B}));return ue(ue({formattedGraphicalItems:$,graphicalItems:X,offset:B,stackGroups:k},le),H)},O=(function(x){function _(A){var E,C,N;return Qme(this,_),N=epe(this,_,[A]),Pe(N,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),Pe(N,"accessibilityManager",new Ime),Pe(N,"handleLegendBBoxUpdate",function(M){if(M){var R=N.state,D=R.dataStartIndex,z=R.dataEndIndex,Y=R.updateId;N.setState(ue({legendBBox:M},b({props:N.props,dataStartIndex:D,dataEndIndex:z,updateId:Y},ue(ue({},N.state),{},{legendBBox:M}))))}}),Pe(N,"handleReceiveSyncEvent",function(M,R,D){if(N.props.syncId===M){if(D===N.eventEmitterSymbol&&typeof N.props.syncMethod!="function")return;N.applySyncEvent(R)}}),Pe(N,"handleBrushChange",function(M){var R=M.startIndex,D=M.endIndex;if(R!==N.state.dataStartIndex||D!==N.state.dataEndIndex){var z=N.state.updateId;N.setState(function(){return ue({dataStartIndex:R,dataEndIndex:D},b({props:N.props,dataStartIndex:R,dataEndIndex:D,updateId:z},N.state))}),N.triggerSyncEvent({dataStartIndex:R,dataEndIndex:D})}}),Pe(N,"handleMouseEnter",function(M){var R=N.getMouseInfo(M);if(R){var D=ue(ue({},R),{},{isTooltipActive:!0});N.setState(D),N.triggerSyncEvent(D);var z=N.props.onMouseEnter;Ye(z)&&z(D,M)}}),Pe(N,"triggeredAfterMouseMove",function(M){var R=N.getMouseInfo(M),D=R?ue(ue({},R),{},{isTooltipActive:!0}):{isTooltipActive:!1};N.setState(D),N.triggerSyncEvent(D);var z=N.props.onMouseMove;Ye(z)&&z(D,M)}),Pe(N,"handleItemMouseEnter",function(M){N.setState(function(){return{isTooltipActive:!0,activeItem:M,activePayload:M.tooltipPayload,activeCoordinate:M.tooltipPosition||{x:M.cx,y:M.cy}}})}),Pe(N,"handleItemMouseLeave",function(){N.setState(function(){return{isTooltipActive:!1}})}),Pe(N,"handleMouseMove",function(M){M.persist(),N.throttleTriggeredAfterMouseMove(M)}),Pe(N,"handleMouseLeave",function(M){N.throttleTriggeredAfterMouseMove.cancel();var R={isTooltipActive:!1};N.setState(R),N.triggerSyncEvent(R);var D=N.props.onMouseLeave;Ye(D)&&D(R,M)}),Pe(N,"handleOuterEvent",function(M){var R=OJ(M),D=Tr(N.props,"".concat(R));if(R&&Ye(D)){var z,Y;/.*touch.*/i.test(R)?Y=N.getMouseInfo(M.changedTouches[0]):Y=N.getMouseInfo(M),D((z=Y)!==null&&z!==void 0?z:{},M)}}),Pe(N,"handleClick",function(M){var R=N.getMouseInfo(M);if(R){var D=ue(ue({},R),{},{isTooltipActive:!0});N.setState(D),N.triggerSyncEvent(D);var z=N.props.onClick;Ye(z)&&z(D,M)}}),Pe(N,"handleMouseDown",function(M){var R=N.props.onMouseDown;if(Ye(R)){var D=N.getMouseInfo(M);R(D,M)}}),Pe(N,"handleMouseUp",function(M){var R=N.props.onMouseUp;if(Ye(R)){var D=N.getMouseInfo(M);R(D,M)}}),Pe(N,"handleTouchMove",function(M){M.changedTouches!=null&&M.changedTouches.length>0&&N.throttleTriggeredAfterMouseMove(M.changedTouches[0])}),Pe(N,"handleTouchStart",function(M){M.changedTouches!=null&&M.changedTouches.length>0&&N.handleMouseDown(M.changedTouches[0])}),Pe(N,"handleTouchEnd",function(M){M.changedTouches!=null&&M.changedTouches.length>0&&N.handleMouseUp(M.changedTouches[0])}),Pe(N,"handleDoubleClick",function(M){var R=N.props.onDoubleClick;if(Ye(R)){var D=N.getMouseInfo(M);R(D,M)}}),Pe(N,"handleContextMenu",function(M){var R=N.props.onContextMenu;if(Ye(R)){var D=N.getMouseInfo(M);R(D,M)}}),Pe(N,"triggerSyncEvent",function(M){N.props.syncId!==void 0&&P1.emit(k1,N.props.syncId,M,N.eventEmitterSymbol)}),Pe(N,"applySyncEvent",function(M){var R=N.props,D=R.layout,z=R.syncMethod,Y=N.state.updateId,L=M.dataStartIndex,F=M.dataEndIndex;if(M.dataStartIndex!==void 0||M.dataEndIndex!==void 0)N.setState(ue({dataStartIndex:L,dataEndIndex:F},b({props:N.props,dataStartIndex:L,dataEndIndex:F,updateId:Y},N.state)));else if(M.activeTooltipIndex!==void 0){var W=M.chartX,Q=M.chartY,X=M.activeTooltipIndex,k=N.state,H=k.offset,B=k.tooltipTicks;if(!H)return;if(typeof z=="function")X=z(B,M);else if(z==="value"){X=-1;for(var Z=0;Z<B.length;Z++)if(B[Z].value===M.activeLabel){X=Z;break}}var le=ue(ue({},H),{},{x:H.left,y:H.top}),$=Math.min(W,le.x+le.width),V=Math.min(Q,le.y+le.height),q=B[X]&&B[X].value,U=Nj(N.state,N.props.data,X),ne=B[X]?{x:D==="horizontal"?B[X].coordinate:$,y:D==="horizontal"?V:B[X].coordinate}:a6;N.setState(ue(ue({},M),{},{activeLabel:q,activeCoordinate:ne,activePayload:U,activeTooltipIndex:X}))}else N.setState(M)}),Pe(N,"renderCursor",function(M){var R,D=N.state,z=D.isTooltipActive,Y=D.activeCoordinate,L=D.activePayload,F=D.offset,W=D.activeTooltipIndex,Q=D.tooltipAxisBandSize,X=N.getTooltipEventType(),k=(R=M.props.active)!==null&&R!==void 0?R:z,H=N.props.layout,B=M.key||"_recharts-cursor";return I.createElement(Fme,{key:B,activeCoordinate:Y,activePayload:L,activeTooltipIndex:W,chartName:n,element:M,isActive:k,layout:H,offset:F,tooltipAxisBandSize:Q,tooltipEventType:X})}),Pe(N,"renderPolarAxis",function(M,R,D){var z=Tr(M,"type.axisType"),Y=Tr(N.state,"".concat(z,"Map")),L=M.type.defaultProps,F=L!==void 0?ue(ue({},L),M.props):M.props,W=Y&&Y[F["".concat(z,"Id")]];return w.cloneElement(M,ue(ue({},W),{},{className:rt(z,W.className),key:M.key||"".concat(R,"-").concat(D),ticks:Va(W,!0)}))}),Pe(N,"renderPolarGrid",function(M){var R=M.props,D=R.radialLines,z=R.polarAngles,Y=R.polarRadius,L=N.state,F=L.radiusAxisMap,W=L.angleAxisMap,Q=Hi(F),X=Hi(W),k=X.cx,H=X.cy,B=X.innerRadius,Z=X.outerRadius;return w.cloneElement(M,{polarAngles:Array.isArray(z)?z:Va(X,!0).map(function(le){return le.coordinate}),polarRadius:Array.isArray(Y)?Y:Va(Q,!0).map(function(le){return le.coordinate}),cx:k,cy:H,innerRadius:B,outerRadius:Z,key:M.key||"polar-grid",radialLines:D})}),Pe(N,"renderLegend",function(){var M=N.state.formattedGraphicalItems,R=N.props,D=R.children,z=R.width,Y=R.height,L=N.props.margin||{},F=z-(L.left||0)-(L.right||0),W=Jz({children:D,formattedGraphicalItems:M,legendWidth:F,legendContent:h});if(!W)return null;var Q=W.item,X=N4(W,Gme);return w.cloneElement(Q,ue(ue({},X),{},{chartWidth:z,chartHeight:Y,margin:L,onBBoxUpdate:N.handleLegendBBoxUpdate}))}),Pe(N,"renderTooltip",function(){var M,R=N.props,D=R.children,z=R.accessibilityLayer,Y=nr(D,_r);if(!Y)return null;var L=N.state,F=L.isTooltipActive,W=L.activeCoordinate,Q=L.activePayload,X=L.activeLabel,k=L.offset,H=(M=Y.props.active)!==null&&M!==void 0?M:F;return w.cloneElement(Y,{viewBox:ue(ue({},k),{},{x:k.left,y:k.top}),active:H,label:X,payload:H?Q:[],coordinate:W,accessibilityLayer:z})}),Pe(N,"renderBrush",function(M){var R=N.props,D=R.margin,z=R.data,Y=N.state,L=Y.offset,F=Y.dataStartIndex,W=Y.dataEndIndex,Q=Y.updateId;return w.cloneElement(M,{key:M.key||"_recharts-brush",onChange:Dh(N.handleBrushChange,M.props.onChange),data:z,x:be(M.props.x)?M.props.x:L.left,y:be(M.props.y)?M.props.y:L.top+L.height+L.brushBottom-(D.bottom||0),width:be(M.props.width)?M.props.width:L.width,startIndex:F,endIndex:W,updateId:"brush-".concat(Q)})}),Pe(N,"renderReferenceElement",function(M,R,D){if(!M)return null;var z=N,Y=z.clipPathId,L=N.state,F=L.xAxisMap,W=L.yAxisMap,Q=L.offset,X=M.type.defaultProps||{},k=M.props,H=k.xAxisId,B=H===void 0?X.xAxisId:H,Z=k.yAxisId,le=Z===void 0?X.yAxisId:Z;return w.cloneElement(M,{key:M.key||"".concat(R,"-").concat(D),xAxis:F[B],yAxis:W[le],viewBox:{x:Q.left,y:Q.top,width:Q.width,height:Q.height},clipPathId:Y})}),Pe(N,"renderActivePoints",function(M){var R=M.item,D=M.activePoint,z=M.basePoint,Y=M.childIndex,L=M.isRange,F=[],W=R.props.key,Q=R.item.type.defaultProps!==void 0?ue(ue({},R.item.type.defaultProps),R.item.props):R.item.props,X=Q.activeDot,k=Q.dataKey,H=ue(ue({index:Y,dataKey:k,cx:D.x,cy:D.y,r:4,fill:A_(R.item),strokeWidth:2,stroke:"#fff",payload:D.payload,value:D.value},nt(X,!1)),ym(X));return F.push(_.renderActiveDot(X,H,"".concat(W,"-activePoint-").concat(Y))),z?F.push(_.renderActiveDot(X,ue(ue({},H),{},{cx:z.x,cy:z.y}),"".concat(W,"-basePoint-").concat(Y))):L&&F.push(null),F}),Pe(N,"renderGraphicChild",function(M,R,D){var z=N.filterFormatItem(M,R,D);if(!z)return null;var Y=N.getTooltipEventType(),L=N.state,F=L.isTooltipActive,W=L.tooltipAxis,Q=L.activeTooltipIndex,X=L.activeLabel,k=N.props.children,H=nr(k,_r),B=z.props,Z=B.points,le=B.isRange,$=B.baseLine,V=z.item.type.defaultProps!==void 0?ue(ue({},z.item.type.defaultProps),z.item.props):z.item.props,q=V.activeDot,U=V.hide,ne=V.activeBar,fe=V.activeShape,ie=!!(!U&&F&&H&&(q||ne||fe)),pe={};Y!=="axis"&&H&&H.props.trigger==="click"?pe={onClick:Dh(N.handleItemMouseEnter,M.props.onClick)}:Y!=="axis"&&(pe={onMouseLeave:Dh(N.handleItemMouseLeave,M.props.onMouseLeave),onMouseEnter:Dh(N.handleItemMouseEnter,M.props.onMouseEnter)});var re=w.cloneElement(M,ue(ue({},z.props),pe));function ve(Mt){return typeof W.dataKey=="function"?W.dataKey(Mt.payload):null}if(ie)if(Q>=0){var ge,oe;if(W.dataKey&&!W.allowDuplicatedCategory){var ke=typeof W.dataKey=="function"?ve:"payload.".concat(W.dataKey.toString());ge=gm(Z,ke,X),oe=le&&$&&gm($,ke,X)}else ge=Z==null?void 0:Z[Q],oe=le&&$&&$[Q];if(fe||ne){var we=M.props.activeIndex!==void 0?M.props.activeIndex:Q;return[w.cloneElement(M,ue(ue(ue({},z.props),pe),{},{activeIndex:we})),null,null]}if(!Qe(ge))return[re].concat(Wl(N.renderActivePoints({item:z,activePoint:ge,basePoint:oe,childIndex:Q,isRange:le})))}else{var Ie,Ze=(Ie=N.getItemByXY(N.state.activeCoordinate))!==null&&Ie!==void 0?Ie:{graphicalItem:re},lt=Ze.graphicalItem,en=lt.item,mt=en===void 0?M:en,ur=lt.childIndex,Gn=ue(ue(ue({},z.props),pe),{},{activeIndex:ur});return[w.cloneElement(mt,Gn),null,null]}return le?[re,null,null]:[re,null]}),Pe(N,"renderCustomized",function(M,R,D){return w.cloneElement(M,ue(ue({key:"recharts-customized-".concat(D)},N.props),N.state))}),Pe(N,"renderMap",{CartesianGrid:{handler:Lh,once:!0},ReferenceArea:{handler:N.renderReferenceElement},ReferenceLine:{handler:Lh},ReferenceDot:{handler:N.renderReferenceElement},XAxis:{handler:Lh},YAxis:{handler:Lh},Brush:{handler:N.renderBrush,once:!0},Bar:{handler:N.renderGraphicChild},Line:{handler:N.renderGraphicChild},Area:{handler:N.renderGraphicChild},Radar:{handler:N.renderGraphicChild},RadialBar:{handler:N.renderGraphicChild},Scatter:{handler:N.renderGraphicChild},Pie:{handler:N.renderGraphicChild},Funnel:{handler:N.renderGraphicChild},Tooltip:{handler:N.renderCursor,once:!0},PolarGrid:{handler:N.renderPolarGrid,once:!0},PolarAngleAxis:{handler:N.renderPolarAxis},PolarRadiusAxis:{handler:N.renderPolarAxis},Customized:{handler:N.renderCustomized}}),N.clipPathId="".concat((E=A.id)!==null&&E!==void 0?E:Yf("recharts"),"-clip"),N.throttleTriggeredAfterMouseMove=ZL(N.triggeredAfterMouseMove,(C=A.throttleDelay)!==null&&C!==void 0?C:1e3/60),N.state={},N}return rpe(_,x),Jme(_,[{key:"componentDidMount",value:function(){var E,C;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(E=this.props.margin.left)!==null&&E!==void 0?E:0,top:(C=this.props.margin.top)!==null&&C!==void 0?C:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var E=this.props,C=E.children,N=E.data,M=E.height,R=E.layout,D=nr(C,_r);if(D){var z=D.props.defaultIndex;if(!(typeof z!="number"||z<0||z>this.state.tooltipTicks.length-1)){var Y=this.state.tooltipTicks[z]&&this.state.tooltipTicks[z].value,L=Nj(this.state,N,z,Y),F=this.state.tooltipTicks[z].coordinate,W=(this.state.offset.top+M)/2,Q=R==="horizontal",X=Q?{x:F,y:W}:{y:F,x:W},k=this.state.formattedGraphicalItems.find(function(B){var Z=B.item;return Z.type.name==="Scatter"});k&&(X=ue(ue({},X),k.props.points[z].tooltipPosition),L=k.props.points[z].tooltipPayload);var H={activeTooltipIndex:z,isTooltipActive:!0,activeLabel:Y,activePayload:L,activeCoordinate:X};this.setState(H),this.renderCursor(D),this.accessibilityManager.setIndex(z)}}}},{key:"getSnapshotBeforeUpdate",value:function(E,C){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==C.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==E.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==E.margin){var N,M;this.accessibilityManager.setDetails({offset:{left:(N=this.props.margin.left)!==null&&N!==void 0?N:0,top:(M=this.props.margin.top)!==null&&M!==void 0?M:0}})}return null}},{key:"componentDidUpdate",value:function(E){hS([nr(E.children,_r)],[nr(this.props.children,_r)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var E=nr(this.props.children,_r);if(E&&typeof E.props.shared=="boolean"){var C=E.props.shared?"axis":"item";return u.indexOf(C)>=0?C:o}return o}},{key:"getMouseInfo",value:function(E){if(!this.container)return null;var C=this.container,N=C.getBoundingClientRect(),M=fre(N),R={chartX:Math.round(E.pageX-M.left),chartY:Math.round(E.pageY-M.top)},D=N.width/C.offsetWidth||1,z=this.inRange(R.chartX,R.chartY,D);if(!z)return null;var Y=this.state,L=Y.xAxisMap,F=Y.yAxisMap,W=this.getTooltipEventType(),Q=T4(this.state,this.props.data,this.props.layout,z);if(W!=="axis"&&L&&F){var X=Hi(L).scale,k=Hi(F).scale,H=X&&X.invert?X.invert(R.chartX):null,B=k&&k.invert?k.invert(R.chartY):null;return ue(ue({},R),{},{xValue:H,yValue:B},Q)}return Q?ue(ue({},R),Q):null}},{key:"inRange",value:function(E,C){var N=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,M=this.props.layout,R=E/N,D=C/N;if(M==="horizontal"||M==="vertical"){var z=this.state.offset,Y=R>=z.left&&R<=z.left+z.width&&D>=z.top&&D<=z.top+z.height;return Y?{x:R,y:D}:null}var L=this.state,F=L.angleAxisMap,W=L.radiusAxisMap;if(F&&W){var Q=Hi(F);return YP({x:R,y:D},Q)}return null}},{key:"parseEventsOfWrapper",value:function(){var E=this.props.children,C=this.getTooltipEventType(),N=nr(E,_r),M={};N&&C==="axis"&&(N.props.trigger==="click"?M={onClick:this.handleClick}:M={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 R=ym(this.props,this.handleOuterEvent);return ue(ue({},R),M)}},{key:"addListener",value:function(){P1.on(k1,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){P1.removeListener(k1,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(E,C,N){for(var M=this.state.formattedGraphicalItems,R=0,D=M.length;R<D;R++){var z=M[R];if(z.item===E||z.props.key===E.key||C===Wa(z.item.type)&&N===z.childIndex)return z}return null}},{key:"renderClipPath",value:function(){var E=this.clipPathId,C=this.state.offset,N=C.left,M=C.top,R=C.height,D=C.width;return I.createElement("defs",null,I.createElement("clipPath",{id:E},I.createElement("rect",{x:N,y:M,height:R,width:D})))}},{key:"getXScales",value:function(){var E=this.state.xAxisMap;return E?Object.entries(E).reduce(function(C,N){var M=A4(N,2),R=M[0],D=M[1];return ue(ue({},C),{},Pe({},R,D.scale))},{}):null}},{key:"getYScales",value:function(){var E=this.state.yAxisMap;return E?Object.entries(E).reduce(function(C,N){var M=A4(N,2),R=M[0],D=M[1];return ue(ue({},C),{},Pe({},R,D.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(E){var C;return(C=this.state.xAxisMap)===null||C===void 0||(C=C[E])===null||C===void 0?void 0:C.scale}},{key:"getYScaleByAxisId",value:function(E){var C;return(C=this.state.yAxisMap)===null||C===void 0||(C=C[E])===null||C===void 0?void 0:C.scale}},{key:"getItemByXY",value:function(E){var C=this.state,N=C.formattedGraphicalItems,M=C.activeItem;if(N&&N.length)for(var R=0,D=N.length;R<D;R++){var z=N[R],Y=z.props,L=z.item,F=L.type.defaultProps!==void 0?ue(ue({},L.type.defaultProps),L.props):L.props,W=Wa(L.type);if(W==="Bar"){var Q=(Y.data||[]).find(function(B){return Rue(E,B)});if(Q)return{graphicalItem:z,payload:Q}}else if(W==="RadialBar"){var X=(Y.data||[]).find(function(B){return YP(E,B)});if(X)return{graphicalItem:z,payload:X}}else if(Dv(z,M)||Pv(z,M)||_f(z,M)){var k=Sfe({graphicalItem:z,activeTooltipItem:M,itemData:F.data}),H=F.activeIndex===void 0?k:F.activeIndex;return{graphicalItem:ue(ue({},z),{},{childIndex:H}),payload:_f(z,M)?F.data[k]:z.props.data[k]}}}return null}},{key:"render",value:function(){var E=this;if(!aM(this))return null;var C=this.props,N=C.children,M=C.className,R=C.width,D=C.height,z=C.style,Y=C.compact,L=C.title,F=C.desc,W=N4(C,Vme),Q=nt(W,!1);if(Y)return I.createElement(l4,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},I.createElement(pS,ml({},Q,{width:R,height:D,title:L,desc:F}),this.renderClipPath(),oM(N,this.renderMap)));if(this.props.accessibilityLayer){var X,k;Q.tabIndex=(X=this.props.tabIndex)!==null&&X!==void 0?X:0,Q.role=(k=this.props.role)!==null&&k!==void 0?k:"application",Q.onKeyDown=function(B){E.accessibilityManager.keyboardEvent(B)},Q.onFocus=function(){E.accessibilityManager.focus()}}var H=this.parseEventsOfWrapper();return I.createElement(l4,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},I.createElement("div",ml({className:rt("recharts-wrapper",M),style:ue({position:"relative",cursor:"default",width:R,height:D},z)},H,{ref:function(Z){E.container=Z}}),I.createElement(pS,ml({},Q,{width:R,height:D,title:L,desc:F,style:cpe}),this.renderClipPath(),oM(N,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])})(w.Component);Pe(O,"displayName",n),Pe(O,"defaultProps",ue({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},p)),Pe(O,"getDerivedStateFromProps",function(x,_){var A=x.dataKey,E=x.data,C=x.children,N=x.width,M=x.height,R=x.layout,D=x.stackOffset,z=x.margin,Y=_.dataStartIndex,L=_.dataEndIndex;if(_.updateId===void 0){var F=M4(x);return ue(ue(ue({},F),{},{updateId:0},b(ue(ue({props:x},F),{},{updateId:0}),_)),{},{prevDataKey:A,prevData:E,prevWidth:N,prevHeight:M,prevLayout:R,prevStackOffset:D,prevMargin:z,prevChildren:C})}if(A!==_.prevDataKey||E!==_.prevData||N!==_.prevWidth||M!==_.prevHeight||R!==_.prevLayout||D!==_.prevStackOffset||!xl(z,_.prevMargin)){var W=M4(x),Q={chartX:_.chartX,chartY:_.chartY,isTooltipActive:_.isTooltipActive},X=ue(ue({},T4(_,E,R)),{},{updateId:_.updateId+1}),k=ue(ue(ue({},W),Q),X);return ue(ue(ue({},k),b(ue({props:x},k),_)),{},{prevDataKey:A,prevData:E,prevWidth:N,prevHeight:M,prevLayout:R,prevStackOffset:D,prevMargin:z,prevChildren:C})}if(!hS(C,_.prevChildren)){var H,B,Z,le,$=nr(C,Ll),V=$&&(H=(B=$.props)===null||B===void 0?void 0:B.startIndex)!==null&&H!==void 0?H:Y,q=$&&(Z=(le=$.props)===null||le===void 0?void 0:le.endIndex)!==null&&Z!==void 0?Z:L,U=V!==Y||q!==L,ne=!Qe(E),fe=ne&&!U?_.updateId:_.updateId+1;return ue(ue({updateId:fe},b(ue(ue({props:x},_),{},{updateId:fe,dataStartIndex:V,dataEndIndex:q}),_)),{},{prevChildren:C,dataStartIndex:V,dataEndIndex:q})}return null}),Pe(O,"renderActiveDot",function(x,_,A){var E;return w.isValidElement(x)?E=w.cloneElement(x,_):Ye(x)?E=x(_):E=I.createElement(C_,_),I.createElement(zt,{className:"recharts-active-dot",key:A},E)});var j=w.forwardRef(function(_,A){return I.createElement(O,ml({},_,{ref:A}))});return j.displayName=O.displayName,j},s6=o6({chartName:"LineChart",GraphicalChild:Er,axisComponents:[{axisType:"xAxis",AxisComp:hs},{axisType:"yAxis",AxisComp:si}],formatAxisMap:_B}),bpe=o6({chartName:"BarChart",GraphicalChild:Ji,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:hs},{axisType:"yAxis",AxisComp:si}],formatAxisMap:_B});function xpe({data:e}){const t=wpe(e);return t.length===0?c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Metrics"}),c.jsx(We,{children:"Performance over the last 24 hours"})]}),c.jsx(ze,{children:c.jsx("div",{className:"flex h-[400px] items-center justify-center text-muted-foreground",children:"No metrics data available yet"})})]}):c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Email Metrics"}),c.jsx(We,{children:"Performance over the last 24 hours"})]}),c.jsx(ze,{children:c.jsx(n_,{height:400,width:"100%",children:c.jsxs(s6,{data:t,children:[c.jsx(Bv,{className:"stroke-muted",strokeDasharray:"3 3"}),c.jsx(hs,{className:"text-xs",dataKey:"timestamp",tickFormatter:n=>aS(new Date(n),"HH:mm")}),c.jsx(si,{className:"text-xs"}),c.jsx(_r,{contentStyle:{backgroundColor:"hsl(var(--popover))",border:"1px solid hsl(var(--border))"},labelFormatter:n=>aS(new Date(n),"MMM d, HH:mm")}),c.jsx(Xa,{}),c.jsx(Er,{dataKey:"sends",name:"Sends",stroke:"hsl(var(--primary))",strokeWidth:2,type:"monotone"}),c.jsx(Er,{dataKey:"deliveries",name:"Deliveries",stroke:"#82ca9d",strokeWidth:2,type:"monotone"}),c.jsx(Er,{dataKey:"opens",name:"Opens",stroke:"#8884d8",strokeWidth:2,type:"monotone"}),c.jsx(Er,{dataKey:"clicks",name:"Clicks",stroke:"#ffc658",strokeWidth:2,type:"monotone"}),c.jsx(Er,{dataKey:"bounces",name:"Bounces",stroke:"#ff7300",strokeWidth:2,type:"monotone"}),c.jsx(Er,{dataKey:"complaints",name:"Complaints",stroke:"hsl(var(--destructive))",strokeWidth:2,type:"monotone"})]})})})]})}function wpe(e){const t=new Map;[...e.sends,...e.bounces,...e.complaints,...e.deliveries,...e.opens,...e.clicks].forEach(n=>{t.has(n.timestamp)||t.set(n.timestamp,{timestamp:n.timestamp,sends:0,bounces:0,complaints:0,deliveries:0,opens:0,clicks:0})});for(const n of e.sends)t.get(n.timestamp).sends=n.value;for(const n of e.bounces)t.get(n.timestamp).bounces=n.value;for(const n of e.complaints)t.get(n.timestamp).complaints=n.value;for(const n of e.deliveries)t.get(n.timestamp).deliveries=n.value;for(const n of e.opens)t.get(n.timestamp).opens=n.value;for(const n of e.clicks)t.get(n.timestamp).clicks=n.value;return Array.from(t.values()).sort((n,r)=>n.timestamp-r.timestamp)}var z_="Progress",B_=100,[Spe]=d$(z_),[jpe,Ope]=Spe(z_),l6=w.forwardRef((e,t)=>{const{__scopeProgress:n,value:r=null,max:i,getValueLabel:o=_pe,...l}=e;(i||i===0)&&!D4(i)&&console.error(Epe(`${i}`,"Progress"));const u=D4(i)?i:B_;r!==null&&!P4(r,u)&&console.error(Ape(`${r}`,"Progress"));const d=P4(r,u)?r:null,h=mp(d)?o(d,u):void 0;return c.jsx(jpe,{scope:n,value:d,max:u,children:c.jsx(is.div,{"aria-valuemax":u,"aria-valuemin":0,"aria-valuenow":mp(d)?d:void 0,"aria-valuetext":h,role:"progressbar","data-state":f6(d,u),"data-value":d??void 0,"data-max":u,...l,ref:t})})});l6.displayName=z_;var c6="ProgressIndicator",u6=w.forwardRef((e,t)=>{const{__scopeProgress:n,...r}=e,i=Ope(c6,n);return c.jsx(is.div,{"data-state":f6(i.value,i.max),"data-value":i.value??void 0,"data-max":i.max,...r,ref:t})});u6.displayName=c6;function _pe(e,t){return`${Math.round(e/t*100)}%`}function f6(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function mp(e){return typeof e=="number"}function D4(e){return mp(e)&&!isNaN(e)&&e>0}function P4(e,t){return mp(e)&&!isNaN(e)&&e<=t&&e>=0}function Epe(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${B_}\`.`}function Ape(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
461
+ - a positive number
462
+ - less than the value passed to \`max\` (or ${B_} if no \`max\` prop is set)
463
+ - \`null\` or \`undefined\` if the progress is indeterminate.
464
+
465
+ Defaulting to \`null\`.`}var Npe=l6,Cpe=u6;function Uv({className:e,value:t,...n}){return c.jsx(Npe,{className:me("relative h-2 w-full overflow-hidden rounded-full bg-primary/20",e),"data-slot":"progress",...n,children:c.jsx(Cpe,{className:"h-full w-full flex-1 bg-primary transition-all","data-slot":"progress-indicator",style:{transform:`translateX(-${100-(t||0)}%)`}})})}function Tpe({quota:e}){const t=e.sentLast24Hours/e.max24HourSend*100,n=t>90?"destructive":t>70?"warning":"default";return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center justify-between",children:["SES Quota",c.jsxs(Ge,{variant:n==="destructive"?"destructive":"secondary",children:[t.toFixed(1),"% used"]})]}),c.jsx(We,{children:"24-hour sending limits"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{children:[c.jsxs("div",{className:"mb-2 flex justify-between text-sm",children:[c.jsx("span",{className:"text-muted-foreground",children:"Emails sent"}),c.jsxs("span",{className:"font-medium",children:[e.sentLast24Hours.toLocaleString()," /"," ",e.max24HourSend.toLocaleString()]})]}),c.jsx(Uv,{className:"h-2",value:t})]}),c.jsxs("div",{className:"flex items-center justify-between border-t pt-2",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Max send rate"}),c.jsxs("span",{className:"font-medium text-sm",children:[e.maxSendRate," emails/sec"]})]})]})]})}function Mpe(){const[e,t]=w.useState("1"),[n,r]=w.useState(null),[i,o]=w.useState(!0),[l,u]=w.useState(null);if(w.useEffect(()=>{async function A(){try{o(!0),u(null);let E=sessionStorage.getItem("wraps-auth-token");if(E||(E=new URLSearchParams(window.location.search).get("token"),E&&sessionStorage.setItem("wraps-auth-token",E)),!E)throw new Error("Authentication token not found. Please use the URL provided by 'wraps console' command.");const C=Number.parseInt(e,10),N=Date.now()-C*24*60*60*1e3,M=Date.now(),R=await fetch(`/api/metrics?startTime=${N}&endTime=${M}&token=${E}`);if(!R.ok){let z="Failed to fetch email metrics";try{z=(await R.json()).error||z}catch{z=`${R.status}: ${R.statusText}`}throw new Error(z)}const D=await R.json();r(D)}catch(E){const C=E instanceof Error?E.message:"Unknown error";u(C),console.error("Error fetching email metrics:",E)}finally{o(!1)}}A()},[e]),l)return c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"Email Metrics"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"View detailed metrics and analytics for your email campaigns"})]}),c.jsx("div",{className:"mt-4 rounded-md border border-destructive bg-destructive/10 p-4 text-destructive text-sm",children:l})]});if(i||!n)return c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"Email Metrics"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"View detailed metrics and analytics for your email campaigns"})]}),c.jsx("div",{className:"mt-4 flex h-[400px] items-center justify-center text-muted-foreground",children:"Loading metrics..."})]});const d=n.metrics.sends.reduce((A,E)=>A+E.value,0)||0,h=n.metrics.deliveries.reduce((A,E)=>A+E.value,0)||0,v=n.metrics.bounces.reduce((A,E)=>A+E.value,0)||0,p=n.metrics.complaints.reduce((A,E)=>A+E.value,0)||0,g=n.metrics.opens.reduce((A,E)=>A+E.value,0)||0,b=n.metrics.clicks.reduce((A,E)=>A+E.value,0)||0,O=d>0?h/d*100:0,j=h>0?g/h*100:0,x=g>0?b/g*100:0,_=[{title:"Emails Sent",value:d.toLocaleString(),description:`${e==="1"?"Last 24 hours":`Last ${e} days`}`,icon:gl},{title:"Delivery Rate",value:`${O.toFixed(1)}%`,description:`${h.toLocaleString()} delivered`,icon:Gj},{title:"Open Rate",value:`${j.toFixed(1)}%`,description:`${g.toLocaleString()} opened`,icon:Cp},{title:"Click Rate",value:`${x.toFixed(1)}%`,description:`${b.toLocaleString()} clicked`,icon:CF}];return c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"Email Metrics"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"View detailed metrics and analytics for your email campaigns"})]}),c.jsxs(fa,{onValueChange:t,value:e,children:[c.jsx(ha,{className:"w-[180px]",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"1",children:"Last 24 hours"}),c.jsx(Fe,{value:"7",children:"Last 7 days"}),c.jsx(Fe,{value:"15",children:"Last 15 days"}),c.jsx(Fe,{value:"30",children:"Last 30 days"}),c.jsx(Fe,{value:"90",children:"Last 90 days"})]})]})]}),c.jsx("div",{className:"grid gap-4 md:grid-cols-2 lg:grid-cols-4",children:_.map(A=>c.jsxs(Re,{children:[c.jsxs(De,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[c.jsx(Ue,{className:"font-medium text-sm",children:A.title}),c.jsx(A.icon,{className:"h-4 w-4 text-muted-foreground"})]}),c.jsxs(ze,{children:[c.jsx("div",{className:"font-bold text-2xl",children:A.value}),c.jsx("p",{className:"text-muted-foreground text-xs",children:A.description})]})]},A.title))}),c.jsx(Tpe,{quota:n.quota}),c.jsx(xpe,{data:n.metrics}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Metrics Summary"}),c.jsx(We,{children:"Detailed breakdown of your email performance"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Total Emails Sent"}),c.jsx(Ge,{variant:"outline",children:d.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Successfully Delivered"}),c.jsx(Ge,{variant:"default",children:h.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Opened"}),c.jsx(Ge,{variant:"default",children:g.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Clicked"}),c.jsx(Ge,{variant:"default",children:b.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Bounced"}),c.jsx(Ge,{variant:"destructive",children:v.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Complaints"}),c.jsx(Ge,{variant:"destructive",children:p.toLocaleString()})]})]})]})]})}var d6="AlertDialog",[Rpe]=jn(d6,[s3]),fi=s3(),h6=e=>{const{__scopeAlertDialog:t,...n}=e,r=fi(t);return c.jsx(gO,{...r,...n,modal:!0})};h6.displayName=d6;var Dpe="AlertDialogTrigger",Ppe=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,i=fi(n);return c.jsx(cW,{...i,...r,ref:t})});Ppe.displayName=Dpe;var kpe="AlertDialogPortal",m6=e=>{const{__scopeAlertDialog:t,...n}=e,r=fi(t);return c.jsx(yO,{...r,...n})};m6.displayName=kpe;var $pe="AlertDialogOverlay",p6=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,i=fi(n);return c.jsx(bO,{...i,...r,ref:t})});p6.displayName=$pe;var jl="AlertDialogContent",[Ipe,Lpe]=Rpe(jl),zpe=k$("AlertDialogContent"),v6=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,children:r,...i}=e,o=fi(n),l=w.useRef(null),u=Be(t,l),d=w.useRef(null);return c.jsx(iW,{contentName:jl,titleName:g6,docsSlug:"alert-dialog",children:c.jsx(Ipe,{scope:n,cancelRef:d,children:c.jsxs(xO,{role:"alertdialog",...o,...i,ref:u,onOpenAutoFocus:ye(i.onOpenAutoFocus,h=>{var v;h.preventDefault(),(v=d.current)==null||v.focus({preventScroll:!0})}),onPointerDownOutside:h=>h.preventDefault(),onInteractOutside:h=>h.preventDefault(),children:[c.jsx(zpe,{children:r}),c.jsx(qpe,{contentRef:l})]})})})});v6.displayName=jl;var g6="AlertDialogTitle",y6=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,i=fi(n);return c.jsx(wO,{...i,...r,ref:t})});y6.displayName=g6;var b6="AlertDialogDescription",x6=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,i=fi(n);return c.jsx(SO,{...i,...r,ref:t})});x6.displayName=b6;var Bpe="AlertDialogAction",w6=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,i=fi(n);return c.jsx(Yp,{...i,...r,ref:t})});w6.displayName=Bpe;var S6="AlertDialogCancel",j6=w.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,{cancelRef:i}=Lpe(S6,n),o=fi(n),l=Be(t,i);return c.jsx(Yp,{...o,...r,ref:l})});j6.displayName=S6;var qpe=({contentRef:e})=>{const t=`\`${jl}\` requires a description for the component to be accessible for screen reader users.
466
+
467
+ You can add a description to the \`${jl}\` by passing a \`${b6}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
468
+
469
+ Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${jl}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
470
+
471
+ For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return w.useEffect(()=>{var r;document.getElementById((r=e.current)==null?void 0:r.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},Upe=h6,Hpe=m6,Fpe=p6,Gpe=v6,Vpe=w6,Ype=j6,Wpe=y6,Kpe=x6;function pp({...e}){return c.jsx(Upe,{"data-slot":"alert-dialog",...e})}function Xpe({...e}){return c.jsx(Hpe,{"data-slot":"alert-dialog-portal",...e})}function Qpe({className:e,...t}){return c.jsx(Fpe,{className:me("data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=open]:animate-in",e),"data-slot":"alert-dialog-overlay",...t})}function vp({className:e,...t}){return c.jsxs(Xpe,{children:[c.jsx(Qpe,{}),c.jsx(Gpe,{className:me("data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200 data-[state=closed]:animate-out data-[state=open]:animate-in sm:max-w-lg",e),"data-slot":"alert-dialog-content",...t})]})}function gp({className:e,...t}){return c.jsx("div",{className:me("flex flex-col gap-2 text-center sm:text-left",e),"data-slot":"alert-dialog-header",...t})}function yp({className:e,...t}){return c.jsx("div",{className:me("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",e),"data-slot":"alert-dialog-footer",...t})}function bp({className:e,...t}){return c.jsx(Wpe,{className:me("font-semibold text-lg",e),"data-slot":"alert-dialog-title",...t})}function xp({className:e,...t}){return c.jsx(Kpe,{className:me("text-muted-foreground text-sm",e),"data-slot":"alert-dialog-description",...t})}function wp({className:e,...t}){return c.jsx(Vpe,{className:me(hO(),e),...t})}function Sp({className:e,...t}){return c.jsx(Ype,{className:me(hO({variant:"outline"}),e),...t})}var Hv="Collapsible",[Zpe]=jn(Hv),[Jpe,q_]=Zpe(Hv),O6=w.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:o,onOpenChange:l,...u}=e,[d,h]=An({prop:r,defaultProp:i??!1,onChange:l,caller:Hv});return c.jsx(Jpe,{scope:n,disabled:o,contentId:Nr(),open:d,onOpenToggle:w.useCallback(()=>h(v=>!v),[h]),children:c.jsx(Ee.div,{"data-state":H_(d),"data-disabled":o?"":void 0,...u,ref:t})})});O6.displayName=Hv;var _6="CollapsibleTrigger",E6=w.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,i=q_(_6,n);return c.jsx(Ee.button,{type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":H_(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled,...r,ref:t,onClick:ye(e.onClick,i.onOpenToggle)})});E6.displayName=_6;var U_="CollapsibleContent",A6=w.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=q_(U_,e.__scopeCollapsible);return c.jsx(Nn,{present:n||i.open,children:({present:o})=>c.jsx(eve,{...r,ref:t,present:o})})});A6.displayName=U_;var eve=w.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:i,...o}=e,l=q_(U_,n),[u,d]=w.useState(r),h=w.useRef(null),v=Be(t,h),p=w.useRef(0),g=p.current,b=w.useRef(0),O=b.current,j=l.open||u,x=w.useRef(j),_=w.useRef(void 0);return w.useEffect(()=>{const A=requestAnimationFrame(()=>x.current=!1);return()=>cancelAnimationFrame(A)},[]),Yt(()=>{const A=h.current;if(A){_.current=_.current||{transitionDuration:A.style.transitionDuration,animationName:A.style.animationName},A.style.transitionDuration="0s",A.style.animationName="none";const E=A.getBoundingClientRect();p.current=E.height,b.current=E.width,x.current||(A.style.transitionDuration=_.current.transitionDuration,A.style.animationName=_.current.animationName),d(r)}},[l.open,r]),c.jsx(Ee.div,{"data-state":H_(l.open),"data-disabled":l.disabled?"":void 0,id:l.contentId,hidden:!j,...o,ref:v,style:{"--radix-collapsible-content-height":g?`${g}px`:void 0,"--radix-collapsible-content-width":O?`${O}px`:void 0,...e.style},children:j&&i})});function H_(e){return e?"open":"closed"}var tve=O6;const yc=tve,bc=E6,xc=A6;var nve="Label",N6=w.forwardRef((e,t)=>c.jsx(is.label,{...e,ref:t,onMouseDown:n=>{var i;n.target.closest("button, input, select, textarea")||((i=e.onMouseDown)==null||i.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));N6.displayName=nve;var rve=N6;function Lo({className:e,...t}){return c.jsx(rve,{className:me("flex select-none items-center gap-2 font-medium text-sm leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-50 group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50",e),"data-slot":"label",...t})}async function ave(){const e=sessionStorage.getItem("wraps-auth-token");if(!e)throw new Error("Authentication token not found");const t=await fetch(`/api/settings?token=${e}`);if(!t.ok)throw new Error(`Failed to fetch settings: ${t.statusText}`);return await t.json()}const C6="wraps-dns-verification",ive=1e3*60*60;function T6(){try{const e=localStorage.getItem(C6);return e?JSON.parse(e):{}}catch{return{}}}function jp(e){try{localStorage.setItem(C6,JSON.stringify(e))}catch(t){console.error("Failed to save DNS verification cache:",t)}}function M6(e){return e?Date.now()-e.lastChecked<ive:!1}async function k4(e,t){var i;console.log("[DNS Verify] verifyTrackingDomain called",{domain:e,expectedTarget:t});const n=T6(),r=`${e}->${t}`;if((i=n.trackingDomain)!=null&&i[r]&&M6(n.trackingDomain[r]))return console.log("[DNS Verify] Returning cached result"),n.trackingDomain[r];try{const l=`/api/settings/verify-tracking-domain?token=${sessionStorage.getItem("wraps-auth-token")}&domain=${encodeURIComponent(e)}&expectedTarget=${encodeURIComponent(t)}`;console.log("[DNS Verify] Fetching:",l);const u=await fetch(l);if(console.log("[DNS Verify] Response status:",u.status),!u.ok)throw new Error(`HTTP ${u.status}: ${u.statusText}`);const d=await u.json();console.log("[DNS Verify] Response data:",d);const h={verified:d.verified,lastChecked:Date.now(),error:d.error};return n.trackingDomain||(n.trackingDomain={}),n.trackingDomain[r]=h,jp(n),h}catch(o){console.error("Tracking domain verification request failed:",o);const l={verified:!1,lastChecked:Date.now(),error:o instanceof Error?o.message:"Failed to verify"};return n.trackingDomain||(n.trackingDomain={}),n.trackingDomain[r]=l,jp(n),l}}async function $4(e){var r;console.log("[DNS Verify] verifyDmarc called",{domain:e});const t=T6(),n=`_dmarc.${e}`;if((r=t.dmarc)!=null&&r[n]&&M6(t.dmarc[n]))return console.log("[DNS Verify] Returning cached DMARC result"),t.dmarc[n];try{const o=`/api/settings/verify-dmarc?token=${sessionStorage.getItem("wraps-auth-token")}&domain=${encodeURIComponent(e)}`;console.log("[DNS Verify] Fetching:",o);const l=await fetch(o);if(console.log("[DNS Verify] Response status:",l.status),!l.ok)throw new Error(`HTTP ${l.status}: ${l.statusText}`);const u=await l.json();console.log("[DNS Verify] Response data:",u);const d={verified:u.verified,lastChecked:Date.now(),error:u.error};return t.dmarc||(t.dmarc={}),t.dmarc[n]=d,jp(t),d}catch(i){console.error("DMARC verification request failed:",i);const o={verified:!1,lastChecked:Date.now(),error:i instanceof Error?i.message:"Failed to verify"};return t.dmarc||(t.dmarc={}),t.dmarc[n]=o,jp(t),o}}function F_({status:e}){const t={SUCCESS:{icon:eo,label:"Verified",variant:"default",className:"bg-green-500/10 text-green-700 dark:text-green-400 border-green-500/20"},PENDING:{icon:Vo,label:"Pending",variant:"secondary",className:"bg-yellow-500/10 text-yellow-700 dark:text-yellow-400 border-yellow-500/20"},FAILED:{icon:c$,label:"Failed",variant:"destructive",className:"bg-red-500/10 text-red-700 dark:text-red-400 border-red-500/20"},TEMPORARY_FAILURE:{icon:sr,label:"Temporary Failure",variant:"secondary",className:"bg-orange-500/10 text-orange-700 dark:text-orange-400 border-orange-500/20"},NOT_STARTED:{icon:Vo,label:"Not Started",variant:"outline",className:"bg-gray-500/10 text-gray-700 dark:text-gray-400 border-gray-500/20"}},{icon:n,label:r,className:i}=t[e];return c.jsxs(Ge,{className:i,variant:"outline",children:[c.jsx(n,{className:"mr-1 h-3 w-3"}),r]})}function Kl({text:e}){const t=async()=>{await navigator.clipboard.writeText(e),jt.success("Copied to clipboard",{description:"DNS record value copied successfully"})};return c.jsx(Ce,{onClick:t,size:"sm",variant:"ghost",children:c.jsx(qj,{className:"h-3 w-3"})})}function ove({identity:e}){const t=e==null?void 0:e.dkimAttributes,n=(t==null?void 0:t.status)==="SUCCESS",[r,i]=w.useState(!n);return t?c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:"DKIM Authentication"}),c.jsxs("p",{className:"text-muted-foreground text-sm",children:[t.signingEnabled?"Enabled":"Disabled",t.signingKeyLength&&` · ${t.signingKeyLength}`]})]}),c.jsx(F_,{status:t.status})]}),t.tokens&&t.tokens.length>0&&c.jsxs(yc,{onOpenChange:i,open:r,children:[c.jsx(bc,{asChild:!0,children:c.jsxs(Ce,{className:"h-auto w-full justify-between p-0",size:"sm",variant:"ghost",children:[c.jsx("p",{className:"font-medium text-sm",children:"DNS Records (CNAME)"}),r?c.jsx(kf,{className:"h-4 w-4"}):c.jsx(rs,{className:"h-4 w-4"})]})}),c.jsx(xc,{className:"mt-2 space-y-2",children:t.tokens.map(o=>c.jsxs("div",{className:"rounded-md border bg-muted/50 p-3",children:[c.jsxs("div",{className:"mb-1 flex items-center justify-between",children:[c.jsxs("p",{className:"font-mono text-xs",children:[o,"._domainkey.",e.identityName]}),c.jsx(Kl,{text:`${o}._domainkey.${e.identityName}`})]}),c.jsxs("p",{className:"font-mono text-muted-foreground text-xs",children:["CNAME → ",o,".dkim.amazonses.com"]})]},o))})]})]}):c.jsx("div",{className:"space-y-4",children:c.jsx("div",{className:"flex items-center justify-between",children:c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:"DKIM Authentication"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Not configured"})]})})})}function sve({identity:e}){const t=e==null?void 0:e.mailFromAttributes,n=(t==null?void 0:t.mailFromDomainStatus)==="SUCCESS",[r,i]=w.useState(!n);return c.jsx("div",{className:"space-y-4",children:t!=null&&t.mailFromDomain?c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:"Mail-From Domain"}),c.jsxs("p",{className:"text-muted-foreground text-sm",children:[t.mailFromDomain,t.behaviorOnMxFailure&&` · ${t.behaviorOnMxFailure==="USE_DEFAULT_VALUE"?"Fallback enabled":"Reject on failure"}`]})]}),t.mailFromDomainStatus&&c.jsx(F_,{status:t.mailFromDomainStatus})]}),c.jsxs(yc,{onOpenChange:i,open:r,children:[c.jsx(bc,{asChild:!0,children:c.jsxs(Ce,{className:"h-auto w-full justify-between p-0",size:"sm",variant:"ghost",children:[c.jsx("p",{className:"font-medium text-sm",children:"DNS Record (MX)"}),r?c.jsx(kf,{className:"h-4 w-4"}):c.jsx(rs,{className:"h-4 w-4"})]})}),c.jsx(xc,{className:"mt-2",children:c.jsx("div",{className:"rounded-md border bg-muted/50 p-3",children:c.jsxs("div",{className:"space-y-1",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("p",{className:"font-mono text-xs",children:["MX ",t.mailFromDomain]}),c.jsx(Kl,{text:`10 feedback-smtp.${e==null?void 0:e.identityName.split(".")[0]}.amazonses.com`})]}),c.jsxs("p",{className:"font-mono text-muted-foreground text-xs",children:["Priority 10 → feedback-smtp.",e==null?void 0:e.identityName.split(".")[0],".amazonses.com"]})]})})})]})]}):c.jsx("div",{className:"flex items-center justify-between",children:c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:"Mail-From Domain"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Using default amazonses.com domain"})]})})})}function lve({identity:e}){const[t,n]=w.useState(null),[r,i]=w.useState(!1),[o,l]=w.useState(!(t!=null&&t.verified));w.useEffect(()=>{e!=null&&e.identityName&&$4(e.identityName).then(n)},[e==null?void 0:e.identityName]),w.useEffect(()=>{t&&l(!t.verified)},[t]);const u=async()=>{if(e!=null&&e.identityName){i(!0);try{const d=await $4(e.identityName);n(d),d.verified?jt.success("DMARC record verified",{description:"DNS TXT record found and configured correctly"}):(console.error("DMARC verification failed:",d.error),jt.error("Verification failed",{description:d.error||"DMARC record not found"}))}catch(d){console.error("DMARC verification error:",d),jt.error("Verification error",{description:d instanceof Error?d.message:"Unknown error"})}finally{i(!1)}}};return c.jsxs("div",{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:"DMARC Policy"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:t!=null&&t.verified?"Configured":"Recommended for better deliverability"})]}),c.jsxs("div",{className:"flex items-center gap-2",children:[(t==null?void 0:t.verified)&&c.jsxs(Ge,{className:"border-green-500/20 bg-green-500/10 text-green-700 dark:text-green-400",variant:"outline",children:[c.jsx(eo,{className:"mr-1 h-3 w-3"}),"Verified by Wraps"]}),c.jsx(Ce,{className:"h-8 w-8 p-0",disabled:r,onClick:u,size:"sm",variant:"ghost",children:c.jsx(If,{className:`h-4 w-4 ${r?"animate-spin":""}`})})]})]}),c.jsxs(yc,{onOpenChange:l,open:o,children:[c.jsx(bc,{asChild:!0,children:c.jsxs(Ce,{className:"h-auto w-full justify-between p-0",size:"sm",variant:"ghost",children:[c.jsx("p",{className:"font-medium text-sm",children:"DNS Record (TXT)"}),o?c.jsx(kf,{className:"h-4 w-4"}):c.jsx(rs,{className:"h-4 w-4"})]})}),c.jsx(xc,{className:"mt-2",children:c.jsxs("div",{className:"rounded-md border bg-muted/50 p-3",children:[c.jsxs("div",{className:"mb-2 flex items-center justify-between",children:[c.jsxs("p",{className:"font-mono text-xs",children:["_dmarc.",(e==null?void 0:e.identityName)||"yourdomain.com"]}),c.jsx(Kl,{text:`_dmarc.${(e==null?void 0:e.identityName)||"yourdomain.com"}`})]}),c.jsxs("div",{className:"flex items-start justify-between gap-2",children:[c.jsxs("p",{className:"font-mono text-muted-foreground text-xs",children:["v=DMARC1; p=quarantine; rua=mailto:dmarc@",(e==null?void 0:e.identityName)||"yourdomain.com"]}),c.jsx(Kl,{text:`v=DMARC1; p=quarantine; rua=mailto:dmarc@${(e==null?void 0:e.identityName)||"yourdomain.com"}`})]})]})})]})]})}function cve({configSet:e,region:t,onRefresh:n}){const r=e==null?void 0:e.trackingOptions,[i,o]=w.useState(null),[l,u]=w.useState(!1),[d,h]=w.useState(!1),[v,p]=w.useState(""),[g,b]=w.useState(!1),[O,j]=w.useState(!(i!=null&&i.verified));w.useEffect(()=>{if(r!=null&&r.customRedirectDomain&&t){const E=`r.${t}.awstrack.me`;k4(r.customRedirectDomain,E).then(o)}},[r==null?void 0:r.customRedirectDomain,t]),w.useEffect(()=>{i&&j(!i.verified)},[i]);const x=async()=>{if(r!=null&&r.customRedirectDomain&&t){u(!0);try{const E=`r.${t}.awstrack.me`,C=await k4(r.customRedirectDomain,E);o(C),C.verified?jt.success("Tracking domain verified",{description:"DNS records are configured correctly"}):(console.error("Tracking domain verification failed:",C.error),jt.error("Verification failed",{description:C.error||"DNS records not found"}))}catch(E){console.error("Tracking domain verification error:",E),jt.error("Verification error",{description:E instanceof Error?E.message:"Unknown error"})}finally{u(!1)}}},_=()=>{p((r==null?void 0:r.customRedirectDomain)||""),h(!0)},A=async()=>{if(!v.trim()){jt.error("Invalid domain",{description:"Please enter a valid domain name"});return}b(!0);try{const E=sessionStorage.getItem("wraps-auth-token"),C=await fetch(`/api/settings/config-set/tracking-domain?token=${E}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({domain:v})});if(!C.ok){const N=await C.json();throw new Error(N.error||`Failed to update: ${C.statusText}`)}h(!1),jt.success("Tracking domain updated",{description:"Don't forget to configure the DNS records"}),n&&await n()}catch(E){console.error("Failed to update tracking domain:",E),jt.error("Failed to update tracking domain",{description:E instanceof Error?E.message:"Unknown error"})}finally{b(!1)}};return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Tracking Domain"}),c.jsx(We,{children:"Custom domain for open and click tracking links"})]}),c.jsx(ze,{className:"space-y-4",children:r!=null&&r.customRedirectDomain?c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex-1",children:[c.jsx("p",{className:"font-medium",children:r.customRedirectDomain}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Custom Tracking Domain"})]}),c.jsxs("div",{className:"flex items-center gap-2",children:[(i==null?void 0:i.verified)&&c.jsxs(Ge,{className:"border-green-500/20 bg-green-500/10 text-green-700 dark:text-green-400",variant:"outline",children:[c.jsx(eo,{className:"mr-1 h-3 w-3"}),"Verified by Wraps"]}),c.jsx(Ge,{variant:"outline",children:r.httpsPolicy==="REQUIRE"?"HTTPS Only":"HTTPS Optional"}),c.jsx(Ce,{className:"h-8 w-8 p-0",disabled:l,onClick:x,size:"sm",variant:"ghost",children:c.jsx(If,{className:`h-4 w-4 ${l?"animate-spin":""}`})}),c.jsx(Ce,{className:"h-8 w-8 p-0",onClick:_,size:"sm",variant:"ghost",children:c.jsx(eC,{className:"h-4 w-4"})})]})]}),c.jsxs(yc,{onOpenChange:j,open:O,children:[c.jsx(bc,{asChild:!0,children:c.jsxs(Ce,{className:"h-auto w-full justify-between p-0",size:"sm",variant:"ghost",children:[c.jsx("p",{className:"font-medium text-sm",children:"Required DNS Record (CNAME)"}),O?c.jsx(kf,{className:"h-4 w-4"}):c.jsx(rs,{className:"h-4 w-4"})]})}),c.jsx(xc,{className:"mt-2",children:c.jsxs("div",{className:"rounded-md border bg-muted/50 p-3",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("p",{className:"font-mono text-xs",children:r.customRedirectDomain}),c.jsx(Kl,{text:r.customRedirectDomain})]}),c.jsxs("div",{className:"mt-1 flex items-start justify-between gap-2",children:[c.jsxs("p",{className:"font-mono text-muted-foreground text-xs",children:["CNAME → r.",(e==null?void 0:e.name)||"region",".awstrack.me"]}),c.jsx(Kl,{text:`r.${(e==null?void 0:e.name)||"region"}.awstrack.me`})]})]})})]})]}):c.jsxs("div",{className:"space-y-4",children:[c.jsx("p",{className:"text-muted-foreground text-sm",children:"No custom tracking domain configured. Using default awstrack.me domain."}),c.jsxs(Ce,{onClick:_,size:"sm",variant:"outline",children:[c.jsx(eC,{className:"mr-2 h-4 w-4"}),"Configure Tracking Domain"]})]})}),c.jsx(_O,{onOpenChange:h,open:d,children:c.jsxs(EO,{children:[c.jsxs(K3,{children:[c.jsx(Q3,{children:"Update Tracking Domain"}),c.jsx(ZX,{children:"Enter the custom domain you want to use for email tracking links. You'll need to configure DNS records after saving."})]}),c.jsx("div",{className:"space-y-4 py-4",children:c.jsxs("div",{className:"space-y-2",children:[c.jsx(Lo,{htmlFor:"domain",children:"Tracking Domain"}),c.jsx(ls,{disabled:g,id:"domain",onChange:E=>p(E.target.value),placeholder:"track.example.com",value:v}),c.jsx("p",{className:"text-muted-foreground text-xs",children:"Example: track.yourdomain.com or email.yourdomain.com"})]})}),c.jsxs(X3,{children:[c.jsx(Ce,{disabled:g,onClick:()=>h(!1),variant:"outline",children:"Cancel"}),c.jsx(Ce,{disabled:g,onClick:A,children:g?"Updating...":"Update Domain"})]})]})})]})}function uve({configSet:e,onRefresh:t}){var v,p;const[n,r]=w.useState(!1),[i,o]=w.useState(!1),[l,u]=w.useState(!1);if(!e)return c.jsx(Re,{children:c.jsxs(De,{children:[c.jsx(Ue,{children:"Configuration Set"}),c.jsx(We,{children:"No configuration set found"})]})});const d=async()=>{var g;u(!0);try{const b=sessionStorage.getItem("wraps-auth-token"),O=!((g=e.sendingOptions)!=null&&g.sendingEnabled),j=await fetch(`/api/settings/config-set/sending?token=${b}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({enabled:O})});if(!j.ok)throw new Error(`Failed to update: ${j.statusText}`);r(!1),jt.success(O?"Email sending enabled":"Email sending disabled"),t&&await t()}catch(b){console.error("Failed to toggle sending:",b),jt.error("Failed to update setting",{description:b instanceof Error?b.message:"Unknown error"})}finally{u(!1)}},h=async()=>{var g;u(!0);try{const b=sessionStorage.getItem("wraps-auth-token"),O=!((g=e.reputationOptions)!=null&&g.reputationMetricsEnabled),j=await fetch(`/api/settings/config-set/reputation?token=${b}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({enabled:O})});if(!j.ok)throw new Error(`Failed to update: ${j.statusText}`);o(!1),jt.success(O?"Reputation metrics enabled":"Reputation metrics disabled"),t&&await t()}catch(b){console.error("Failed to toggle reputation:",b),jt.error("Failed to update setting",{description:b instanceof Error?b.message:"Unknown error"})}finally{u(!1)}};return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Configuration Set"}),c.jsx(We,{children:"Email sending and tracking configuration"})]}),c.jsxs(ze,{className:"space-y-6",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:e.name}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Configuration Set Name"})]}),c.jsx(Bt,{}),e.sendingOptions&&c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex-1 space-y-0.5",children:[c.jsx("p",{className:"font-medium text-sm",children:"Email Sending"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.sendingOptions.sendingEnabled?"Emails can be sent":"Email sending is disabled"})]}),c.jsx(Ce,{onClick:()=>r(!0),size:"sm",variant:e.sendingOptions.sendingEnabled?"destructive":"default",children:e.sendingOptions.sendingEnabled?"Disable":"Enable"})]}),c.jsx(pp,{onOpenChange:r,open:n,children:c.jsxs(vp,{children:[c.jsxs(gp,{children:[c.jsx(bp,{children:e.sendingOptions.sendingEnabled?"Disable email sending?":"Enable email sending?"}),c.jsx(xp,{children:e.sendingOptions.sendingEnabled?"All outgoing emails will be blocked until you re-enable sending. Emails in the queue will not be sent.":"This will allow emails to be sent through this configuration set. Make sure your domain is verified before enabling."})]}),c.jsxs(yp,{children:[c.jsx(Sp,{disabled:l,children:"Cancel"}),c.jsx(wp,{disabled:l,onClick:d,children:l?"Updating...":e.sendingOptions.sendingEnabled?"Disable sending":"Enable sending"})]})]})})]}),e.reputationOptions&&c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex-1 space-y-0.5",children:[c.jsx("p",{className:"font-medium text-sm",children:"Reputation Metrics"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.reputationOptions.reputationMetricsEnabled?"Tracking bounce and complaint rates":"Reputation tracking disabled"})]}),c.jsx(Ce,{onClick:()=>o(!0),size:"sm",variant:"outline",children:e.reputationOptions.reputationMetricsEnabled?"Disable":"Enable"})]}),c.jsx(pp,{onOpenChange:o,open:i,children:c.jsxs(vp,{children:[c.jsxs(gp,{children:[c.jsx(bp,{children:e.reputationOptions.reputationMetricsEnabled?"Disable reputation metrics?":"Enable reputation metrics?"}),c.jsx(xp,{children:e.reputationOptions.reputationMetricsEnabled?"You will stop collecting bounce and complaint rate data. Historical data will be preserved but no new metrics will be tracked.":"This will start tracking bounce and complaint rates for your sending domain. This helps monitor your email reputation and deliverability."})]}),c.jsxs(yp,{children:[c.jsx(Sp,{disabled:l,children:"Cancel"}),c.jsx(wp,{disabled:l,onClick:h,children:l?"Updating...":e.reputationOptions.reputationMetricsEnabled?"Disable metrics":"Enable metrics"})]})]})})]}),((v=e.deliveryOptions)==null?void 0:v.tlsPolicy)&&c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"space-y-0.5",children:[c.jsx("p",{className:"font-medium text-sm",children:"TLS Encryption"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.deliveryOptions.tlsPolicy==="REQUIRE"?"Required for all connections":"Optional (opportunistic)"})]}),c.jsx(Ge,{variant:"outline",children:e.deliveryOptions.tlsPolicy==="REQUIRE"?"Required":"Optional"})]}),e.suppressionOptions&&c.jsxs("div",{className:"space-y-2",children:[c.jsxs("div",{className:"space-y-0.5",children:[c.jsx("p",{className:"font-medium text-sm",children:"Suppression List"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Automatically suppress emails to addresses that bounced or complained"})]}),e.suppressionOptions.suppressedReasons&&e.suppressionOptions.suppressedReasons.length>0?c.jsx("div",{className:"flex gap-2",children:e.suppressionOptions.suppressedReasons.map(g=>c.jsx(Ge,{variant:"secondary",children:g},g))}):c.jsx("p",{className:"text-muted-foreground text-sm",children:"Not configured"})]}),((p=e.deliveryOptions)==null?void 0:p.sendingPoolName)&&c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"IP Pool"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.deliveryOptions.sendingPoolName})]})]})]})}function fve(){var u,d;const[e,t]=w.useState(null),[n,r]=w.useState(!0),[i,o]=w.useState(null),l=w.useCallback(async()=>{try{r(!0);const h=await ave();t(h),o(null)}catch(h){console.error("Failed to fetch email settings:",h),o(h instanceof Error?h.message:"Failed to load settings")}finally{r(!1)}},[]);return w.useEffect(()=>{l()},[l]),n?c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"Email Settings"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"Configure your email settings and preferences"})]}),c.jsxs("div",{className:"mt-6 grid gap-6 md:grid-cols-2",children:[c.jsxs(Re,{className:"md:row-span-2",children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-48"}),c.jsx(Ne,{className:"mt-2 h-4 w-64"})]}),c.jsxs(ze,{className:"space-y-6",children:[c.jsxs("div",{className:"space-y-2",children:[c.jsx(Ne,{className:"h-4 w-32"}),c.jsx(Ne,{className:"h-4 w-24"})]}),c.jsx(Ne,{className:"h-px w-full"}),c.jsxs("div",{className:"space-y-2",children:[c.jsx(Ne,{className:"h-4 w-40"}),c.jsx(Ne,{className:"h-4 w-28"})]}),c.jsx(Ne,{className:"h-px w-full"}),c.jsxs("div",{className:"space-y-2",children:[c.jsx(Ne,{className:"h-4 w-36"}),c.jsx(Ne,{className:"h-4 w-32"})]}),c.jsx(Ne,{className:"h-px w-full"}),c.jsxs("div",{className:"space-y-2",children:[c.jsx(Ne,{className:"h-4 w-32"}),c.jsx(Ne,{className:"h-4 w-44"})]})]})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-48"}),c.jsx(Ne,{className:"mt-2 h-4 w-64"})]}),c.jsx(ze,{children:c.jsx(Ne,{className:"h-20 w-full"})})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-48"}),c.jsx(Ne,{className:"mt-2 h-4 w-64"})]}),c.jsx(ze,{children:c.jsx(Ne,{className:"h-20 w-full"})})]})]})]}):i?c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"Email Settings"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"Configure your email settings and preferences"})]}),c.jsxs(qn,{className:"mt-6",variant:"destructive",children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Error Loading Settings"}),c.jsx(Un,{children:i})]})]}):c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"Email Settings"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"Configure your email settings and preferences"})]}),c.jsxs("div",{className:"mt-6 grid gap-6 md:grid-cols-2",children:[c.jsxs(Re,{className:"md:row-span-2",children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Sending Domain"}),c.jsx(We,{children:"Email domain configuration and authentication"})]}),c.jsxs(ze,{className:"space-y-6",children:[c.jsx("div",{className:"space-y-4",children:c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex-1",children:[c.jsx("p",{className:"font-medium",children:(u=e==null?void 0:e.identity)==null?void 0:u.identityName}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Domain Identity"})]}),c.jsx(F_,{status:((d=e==null?void 0:e.identity)==null?void 0:d.verificationStatus)||"NOT_STARTED"})]})}),c.jsx(Bt,{}),c.jsx(ove,{identity:e==null?void 0:e.identity}),c.jsx(Bt,{}),c.jsx(sve,{identity:e==null?void 0:e.identity}),c.jsx(Bt,{}),c.jsx(lve,{identity:e==null?void 0:e.identity})]})]}),c.jsx(uve,{configSet:e==null?void 0:e.configurationSet,onRefresh:l}),c.jsx(cve,{configSet:e==null?void 0:e.configurationSet,onRefresh:l,region:e==null?void 0:e.region})]})]})}const dve={sent:Ki,delivered:Ja,failed:ir,queued:Vo,blocked:ir,carrier_unreachable:Qh,invalid:ir,opted_out:ir,ttl_expired:Vo},hve={sent:"text-blue-500",delivered:"text-green-500",failed:"text-red-500",queued:"text-gray-500",blocked:"text-orange-500",carrier_unreachable:"text-red-500",invalid:"text-red-500",opted_out:"text-yellow-500",ttl_expired:"text-gray-500"},mve={delivered:"default",sent:"secondary",queued:"secondary",failed:"destructive",blocked:"destructive",invalid:"destructive",opted_out:"default"};function pve(){const{id:e}=J4(),t=ns(),[n,r]=w.useState(null),[i,o]=w.useState(!0),[l,u]=w.useState(null);w.useEffect(()=>{async function p(){try{o(!0),u(null);const g=sessionStorage.getItem("wraps-auth-token");if(!g)throw new Error("Authentication token not found");const b=encodeURIComponent(e||""),O=await fetch(`/api/sms/${b}?token=${g}`);if(!O.ok){let _="Failed to fetch SMS details";try{_=(await O.json()).error||_}catch{_=`${O.status}: ${O.statusText}`}throw new Error(_)}const j=O.headers.get("content-type");if(!(j!=null&&j.includes("application/json"))){const _=await O.text();throw console.error("Non-JSON response:",_),new Error("Server returned non-JSON response")}const x=await O.json();r(x)}catch(g){const b=g instanceof Error?g.message:"Unknown error";u(b),console.error("Error fetching SMS details:",g)}finally{o(!1)}}e&&p()},[e]);const d=p=>new Date(p).toLocaleString("en-US",{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",hour12:!0}),h=p=>new Date(p).toLocaleString("en-US",{weekday:"short",month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit",hour12:!0}),v=p=>p.startsWith("+1")&&p.length===12?`(${p.slice(2,5)}) ${p.slice(5,8)}-${p.slice(8)}`:p;return i?c.jsx("div",{className:"flex h-[600px] items-center justify-center",children:c.jsx("div",{className:"text-muted-foreground",children:"Loading SMS details..."})}):l?c.jsxs("div",{className:"space-y-4",children:[c.jsxs(Ce,{onClick:()=>t("/sms"),size:"sm",variant:"ghost",children:[c.jsx(vl,{className:"mr-2 h-4 w-4"}),"Back to messages"]}),c.jsx("div",{className:"rounded-md border border-destructive bg-destructive/10 p-4 text-destructive text-sm",children:l})]}):n?c.jsxs("div",{className:"space-y-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs(Ce,{onClick:()=>t("/sms"),size:"sm",variant:"ghost",children:[c.jsx(vl,{className:"mr-2 h-4 w-4"}),"Back to messages"]}),c.jsx(Ge,{variant:mve[n.status],children:n.status.charAt(0).toUpperCase()+n.status.slice(1).replace("_"," ")})]}),c.jsxs(Re,{children:[c.jsx(De,{children:c.jsx("div",{className:"flex items-start justify-between",children:c.jsxs("div",{className:"space-y-1.5",children:[c.jsxs(Ue,{className:"flex items-center gap-2 text-2xl",children:[c.jsx(Ki,{className:"h-6 w-6"}),"SMS Message"]}),c.jsx(We,{className:"font-mono text-xs",children:n.messageId})]})})}),c.jsx(ze,{className:"space-y-4",children:c.jsxs("div",{className:"grid gap-4 md:grid-cols-2",children:[c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-sm",children:"FROM"}),c.jsx("div",{className:"font-mono text-sm",children:v(n.from)})]}),c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-sm",children:"TO"}),c.jsx("div",{className:"font-mono text-sm",children:v(n.to)})]}),c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-sm",children:"SEGMENTS"}),c.jsx("div",{className:"font-mono text-sm",children:n.segments})]}),c.jsxs("div",{className:"space-y-1",children:[c.jsx("div",{className:"text-muted-foreground text-sm",children:"ID"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-xs",children:n.id}),c.jsx(Ce,{className:"h-6 w-6",onClick:()=>navigator.clipboard.writeText(n.id),size:"icon",variant:"ghost",children:c.jsx("span",{className:"sr-only",children:"Copy ID"})})]})]})]})})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Message Content"}),c.jsx(We,{children:"The SMS message body"})]}),c.jsx(ze,{children:c.jsx("div",{className:"rounded-md border bg-muted/50 p-4",children:c.jsx("p",{className:"whitespace-pre-wrap text-sm",children:n.body})})})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Message Events"}),c.jsx(We,{children:"Lifecycle of this message from send to delivery"})]}),c.jsx(ze,{children:c.jsx("div",{className:"space-y-4",children:n.events.length===0?c.jsx("div",{className:"text-muted-foreground text-sm",children:"No events recorded yet"}):n.events.map((p,g)=>{const b=dve[p.type]||Vo,O=g===n.events.length-1;return c.jsx("div",{children:c.jsxs("div",{className:"flex gap-4",children:[c.jsxs("div",{className:"flex flex-col items-center",children:[c.jsx("div",{className:`rounded-full border-2 border-background bg-muted p-2 ${hve[p.type]}`,children:c.jsx(b,{className:"h-4 w-4"})}),!O&&c.jsx("div",{className:"my-1 w-px flex-1 bg-border"})]}),c.jsxs("div",{className:"flex-1 pb-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("div",{className:"font-medium capitalize",children:p.type.replace("_"," ")}),c.jsx("div",{className:"text-muted-foreground text-sm",children:d(p.timestamp)})]}),c.jsx("div",{className:"text-muted-foreground text-sm",children:h(p.timestamp)}),p.metadata&&Object.keys(p.metadata).length>0&&c.jsx("div",{className:"mt-2 rounded-md border bg-muted/50 p-2 font-mono text-xs",children:c.jsx("pre",{className:"overflow-x-auto",children:JSON.stringify(p.metadata,null,2)})})]})]})},`${p.type}-${p.timestamp}`)})})})]})]}):c.jsxs("div",{className:"space-y-4",children:[c.jsxs(Ce,{onClick:()=>t("/sms"),size:"sm",variant:"ghost",children:[c.jsx(vl,{className:"mr-2 h-4 w-4"}),"Back to messages"]}),c.jsx("div",{className:"rounded-md border p-4 text-muted-foreground text-sm",children:"SMS message not found"})]})}const I1={delivered:{variant:"default",description:"Message was delivered to recipient's device",className:"bg-green-500/10 text-green-700 dark:text-green-400 hover:bg-green-500/20 border-green-500/20"},sent:{variant:"secondary",description:"Message was sent but delivery not yet confirmed",className:"bg-blue-500/10 text-blue-700 dark:text-blue-400 hover:bg-blue-500/20 border-blue-500/20"},queued:{variant:"secondary",description:"Message is queued for delivery",className:"bg-gray-500/10 text-gray-700 dark:text-gray-400 hover:bg-gray-500/20 border-gray-500/20"},failed:{variant:"destructive",description:"Message failed to deliver",className:"bg-red-500/10 text-red-700 dark:text-red-400 hover:bg-red-500/20 border-red-500/20"},blocked:{variant:"destructive",description:"Message was blocked by carrier or filter",className:"bg-orange-500/10 text-orange-700 dark:text-orange-400 hover:bg-orange-500/20 border-orange-500/20"},invalid:{variant:"destructive",description:"Invalid phone number or message format",className:"bg-red-500/10 text-red-700 dark:text-red-400 hover:bg-red-500/20 border-red-500/20"},opted_out:{variant:"default",description:"Recipient has opted out of receiving messages",className:"bg-yellow-500/10 text-yellow-700 dark:text-yellow-400 hover:bg-yellow-500/20 border-yellow-500/20"}};function vve(){const e=ns(),[t,n]=w.useState(""),[r,i]=w.useState("15"),[o,l]=w.useState("all"),[u,d]=w.useState([]),[h,v]=w.useState(!0),[p,g]=w.useState(null);w.useEffect(()=>{async function x(){try{v(!0),g(null);let _=sessionStorage.getItem("wraps-auth-token");if(_||(_=new URLSearchParams(window.location.search).get("token"),_&&sessionStorage.setItem("wraps-auth-token",_)),!_)throw new Error("Authentication token not found. Please use the URL provided by 'wraps console' command.");const A=Number.parseInt(r,10),E=Date.now()-A*24*60*60*1e3,C=Date.now(),N=await fetch(`/api/sms?startTime=${E}&endTime=${C}&limit=100&token=${_}`);if(!N.ok){let R="Failed to fetch SMS logs";try{R=(await N.json()).error||R}catch{R=`${N.status}: ${N.statusText}`}throw new Error(R)}const M=await N.json();d(M.logs.map(R=>({id:R.messageId,to:R.to,from:R.from,body:R.body,status:R.status,timestamp:R.sentAt,messageId:R.messageId,segments:R.segments})))}catch(_){const A=_ instanceof Error?_.message:"Unknown error";g(A),console.error("Error fetching SMS logs:",_)}finally{v(!1)}}x()},[r]);const b=u.filter(x=>{if(t){const _=t.toLowerCase(),A=x.to.toLowerCase().includes(_),E=x.body.toLowerCase().includes(_);if(!(A||E))return!1}return!(o!=="all"&&x.status!==o)}),O=x=>{const _=new Date(x),E=Math.floor((new Date().getTime()-_.getTime())/(1e3*60*60*24));return E===0?"Today":E===1?"Yesterday":E<7?`${E} days ago`:_.toLocaleDateString()},j=x=>x.startsWith("+1")&&x.length===12?`(${x.slice(2,5)}) ${x.slice(5,8)}-${x.slice(8)}`:x;return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Ki,{className:"h-5 w-5"}),"SMS Messages"]}),c.jsx(We,{children:"View and manage your SMS sending history"})]}),c.jsxs(ze,{children:[p&&c.jsx("div",{className:"mb-4 rounded-md border border-destructive bg-destructive/10 p-4 text-destructive text-sm",children:p}),c.jsxs("div",{className:"mb-4 flex items-center gap-2",children:[c.jsxs("div",{className:"relative flex-1",children:[c.jsx(Fj,{className:"absolute top-2.5 left-2.5 h-4 w-4 text-muted-foreground"}),c.jsx(ls,{className:"pl-8",onChange:x=>n(x.target.value),placeholder:"Search by phone or message...",value:t})]}),c.jsxs(fa,{onValueChange:i,value:r,children:[c.jsx(ha,{className:"w-[180px]",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"1",children:"Last 24 hours"}),c.jsx(Fe,{value:"7",children:"Last 7 days"}),c.jsx(Fe,{value:"15",children:"Last 15 days"}),c.jsx(Fe,{value:"30",children:"Last 30 days"}),c.jsx(Fe,{value:"90",children:"Last 90 days"})]})]}),c.jsxs(fa,{onValueChange:l,value:o,children:[c.jsx(ha,{className:"w-[180px]",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"all",children:"All Statuses"}),c.jsx(Fe,{value:"delivered",children:"Delivered"}),c.jsx(Fe,{value:"sent",children:"Sent"}),c.jsx(Fe,{value:"queued",children:"Queued"}),c.jsx(Fe,{value:"failed",children:"Failed"}),c.jsx(Fe,{value:"blocked",children:"Blocked"}),c.jsx(Fe,{value:"opted_out",children:"Opted Out"})]})]}),c.jsx(Ce,{size:"icon",variant:"outline",children:c.jsx("span",{className:"sr-only",children:"Download"})})]}),c.jsx("div",{className:"rounded-md border",children:c.jsxs(CO,{children:[c.jsx(TO,{children:c.jsxs(la,{children:[c.jsx(pn,{children:"To"}),c.jsx(pn,{children:"Status"}),c.jsx(pn,{children:"Message"}),c.jsx(pn,{children:"Sent"}),c.jsx(pn,{className:"w-[50px]"})]})}),c.jsx(MO,{children:h?c.jsx(la,{children:c.jsx(Lt,{className:"h-24 text-center text-muted-foreground",colSpan:5,children:"Loading SMS logs..."})}):b.length===0?c.jsx(la,{children:c.jsx(Lt,{className:"h-24 text-center text-muted-foreground",colSpan:5,children:"No SMS messages found"})}):b.map(x=>{var _,A,E;return c.jsxs(la,{className:"cursor-pointer hover:bg-muted/50",onClick:()=>e(`/sms/${x.id}`),children:[c.jsx(Lt,{className:"font-mono text-sm",children:j(x.to)}),c.jsx(Lt,{children:c.jsxs(Xp,{children:[c.jsx(Qp,{asChild:!0,children:c.jsx(Ge,{className:(_=I1[x.status])==null?void 0:_.className,variant:((A=I1[x.status])==null?void 0:A.variant)??"default",children:x.status.charAt(0).toUpperCase()+x.status.slice(1).replace("_"," ")})}),c.jsx(Zp,{children:c.jsx("p",{children:((E=I1[x.status])==null?void 0:E.description)??"Unknown status"})})]})}),c.jsx(Lt,{className:"max-w-[400px] truncate",children:x.body}),c.jsx(Lt,{className:"text-muted-foreground",children:O(x.timestamp)}),c.jsx(Lt,{children:c.jsx(Ce,{onClick:C=>{C.stopPropagation()},size:"icon",variant:"ghost",children:c.jsx("span",{className:"sr-only",children:"More options"})})})]},x.id)})})]})}),b.length>0&&!h&&c.jsx("div",{className:"mt-4 flex items-center justify-between text-muted-foreground text-sm",children:c.jsxs("div",{children:["Showing ",b.length," of ",u.length," messages"]})})]})]})}function gve(){const[e,t]=w.useState("7"),[n,r]=w.useState(null),[i,o]=w.useState(!0),[l,u]=w.useState(null);if(w.useEffect(()=>{async function j(){try{o(!0),u(null);let x=sessionStorage.getItem("wraps-auth-token");if(x||(x=new URLSearchParams(window.location.search).get("token"),x&&sessionStorage.setItem("wraps-auth-token",x)),!x)throw new Error("Authentication token not found. Please use the URL provided by 'wraps console' command.");const _=Number.parseInt(e,10),A=Date.now()-_*24*60*60*1e3,E=Date.now(),C=await fetch(`/api/sms/metrics?startTime=${A}&endTime=${E}&token=${x}`);if(!C.ok){let M="Failed to fetch SMS metrics";try{M=(await C.json()).error||M}catch{M=`${C.status}: ${C.statusText}`}throw new Error(M)}const N=await C.json();r(N)}catch(x){const _=x instanceof Error?x.message:"Unknown error";u(_),console.error("Error fetching SMS metrics:",x)}finally{o(!1)}}j()},[e]),l)return c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"SMS Metrics"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"View detailed metrics and analytics for your SMS messaging"})]}),c.jsx("div",{className:"mt-4 rounded-md border border-destructive bg-destructive/10 p-4 text-destructive text-sm",children:l})]});if(i||!n)return c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"SMS Metrics"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"View detailed metrics and analytics for your SMS messaging"})]}),c.jsx("div",{className:"mt-4 flex h-[400px] items-center justify-center text-muted-foreground",children:"Loading metrics..."})]});const d=n.metrics.sends.reduce((j,x)=>j+x.value,0)||0,h=n.metrics.deliveries.reduce((j,x)=>j+x.value,0)||0,v=n.metrics.failures.reduce((j,x)=>j+x.value,0)||0,p=n.metrics.optOuts.reduce((j,x)=>j+x.value,0)||0,g=d>0?h/d*100:0,b=d>0?v/d*100:0,O=[{title:"Messages Sent",value:d.toLocaleString(),description:`${e==="1"?"Last 24 hours":`Last ${e} days`}`,icon:Ki},{title:"Delivery Rate",value:`${g.toFixed(1)}%`,description:`${h.toLocaleString()} delivered`,icon:Gj},{title:"Failure Rate",value:`${b.toFixed(1)}%`,description:`${v.toLocaleString()} failed`,icon:Cp},{title:"Opt Outs",value:p.toLocaleString(),description:"Recipients unsubscribed",icon:Qh}];return c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"SMS Metrics"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"View detailed metrics and analytics for your SMS messaging"})]}),c.jsxs(fa,{onValueChange:t,value:e,children:[c.jsx(ha,{className:"w-[180px]",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"1",children:"Last 24 hours"}),c.jsx(Fe,{value:"7",children:"Last 7 days"}),c.jsx(Fe,{value:"15",children:"Last 15 days"}),c.jsx(Fe,{value:"30",children:"Last 30 days"}),c.jsx(Fe,{value:"90",children:"Last 90 days"})]})]})]}),c.jsx("div",{className:"grid gap-4 md:grid-cols-2 lg:grid-cols-4",children:O.map(j=>c.jsxs(Re,{children:[c.jsxs(De,{className:"flex flex-row items-center justify-between space-y-0 pb-2",children:[c.jsx(Ue,{className:"font-medium text-sm",children:j.title}),c.jsx(j.icon,{className:"h-4 w-4 text-muted-foreground"})]}),c.jsxs(ze,{children:[c.jsx("div",{className:"font-bold text-2xl",children:j.value}),c.jsx("p",{className:"text-muted-foreground text-xs",children:j.description})]})]},j.title))}),n.phoneNumber&&c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Phone Number"}),c.jsx(We,{children:"Your SMS sending number"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Number"}),c.jsx("span",{className:"font-mono text-sm",children:n.phoneNumber.number})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Type"}),c.jsx(Ge,{variant:"outline",children:n.phoneNumber.type})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Status"}),c.jsx(Ge,{variant:n.phoneNumber.status==="ACTIVE"?"default":"secondary",children:n.phoneNumber.status})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Throughput"}),c.jsx("span",{className:"text-muted-foreground text-sm",children:n.phoneNumber.throughput})]})]})]}),n.quota&&c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Spend Limits"}),c.jsx(We,{children:"Your AWS SMS spending limits"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"space-y-2",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Monthly Spend"}),c.jsxs("span",{className:"font-medium",children:["$",n.quota.spentThisMonth.toFixed(2)," / $",n.quota.spendLimitMonthly.toFixed(2)]})]}),c.jsx("div",{className:"h-2 w-full overflow-hidden rounded-full bg-secondary",children:c.jsx("div",{className:"h-full bg-primary transition-all",style:{width:`${Math.min(n.quota.spentThisMonth/n.quota.spendLimitMonthly*100,100)}%`}})})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Daily Limit"}),c.jsxs("span",{className:"text-muted-foreground text-sm",children:["$",n.quota.spendLimitDaily.toFixed(2)]})]})]})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Metrics Summary"}),c.jsx(We,{children:"Detailed breakdown of your SMS performance"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Total Messages Sent"}),c.jsx(Ge,{variant:"outline",children:d.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Successfully Delivered"}),c.jsx(Ge,{variant:"default",children:h.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Failed"}),c.jsx(Ge,{variant:"destructive",children:v.toLocaleString()})]}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-sm",children:"Opt Outs"}),c.jsx(Ge,{variant:"secondary",children:p.toLocaleString()})]})]})]})]})}function I4({status:e}){const t=e==="ACTIVE"||e==="SUCCESS";return c.jsxs(Ge,{className:t?"border-green-500/20 bg-green-500/10 text-green-700 dark:text-green-400":"border-yellow-500/20 bg-yellow-500/10 text-yellow-700 dark:text-yellow-400",variant:"outline",children:[t?c.jsx(eo,{className:"mr-1 h-3 w-3"}):c.jsx(sr,{className:"mr-1 h-3 w-3"}),e]})}function yve({phoneNumber:e}){if(!e)return c.jsx(Re,{children:c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Qh,{className:"h-5 w-5"}),"Phone Number"]}),c.jsx(We,{children:"No phone number configured"})]})});const t=r=>r.startsWith("+1")&&r.length===12?`(${r.slice(2,5)}) ${r.slice(5,8)}-${r.slice(8)}`:r,n=r=>{switch(r){case"simulator":return"Simulator";case"toll-free":return"Toll-Free";case"10dlc":return"10DLC";case"short-code":return"Short Code";default:return r}};return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Qh,{className:"h-5 w-5"}),"Phone Number"]}),c.jsx(We,{children:"Your SMS sending number"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium font-mono text-lg",children:t(e.number)}),c.jsx("p",{className:"text-muted-foreground text-sm",children:n(e.type)})]}),c.jsx(I4,{status:e.status})]}),e.registrationStatus&&c.jsxs(c.Fragment,{children:[c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"Registration Status"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.type==="toll-free"?"Toll-free verification":"Campaign registration"})]}),c.jsx(I4,{status:e.registrationStatus})]})]}),e.capabilities.length>0&&c.jsxs(c.Fragment,{children:[c.jsx(Bt,{}),c.jsxs("div",{className:"space-y-2",children:[c.jsx("p",{className:"font-medium text-sm",children:"Capabilities"}),c.jsx("div",{className:"flex flex-wrap gap-2",children:e.capabilities.map(r=>c.jsx(Ge,{variant:"secondary",children:r},r))})]})]}),e.monthlyLeasingPrice&&c.jsxs(c.Fragment,{children:[c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"Monthly Cost"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Phone number lease"})]}),c.jsxs("span",{className:"font-mono text-sm",children:["$",e.monthlyLeasingPrice,"/mo"]})]})]}),e.type==="simulator"&&c.jsxs(qn,{children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Simulator Mode"}),c.jsx(Un,{children:"This number is for testing only. Messages are simulated and not actually sent. Upgrade to a toll-free number for production use."})]}),e.type==="toll-free"&&e.registrationStatus!=="VERIFIED"&&c.jsxs(qn,{children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Registration Required"}),c.jsxs(Un,{children:["Toll-free numbers require registration before they can send messages. Run ",c.jsx("code",{children:"wraps sms register"})," to complete registration."]})]})]})]})}function bve({protectConfig:e}){return e!=null&&e.enabled?c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Zh,{className:"h-5 w-5"}),"Fraud Protection"]}),c.jsx(We,{children:"Country restrictions and AIT filtering"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"Status"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Protect configuration active"})]}),c.jsxs(Ge,{className:"border-green-500/20 bg-green-500/10 text-green-700 dark:text-green-400",variant:"outline",children:[c.jsx(eo,{className:"mr-1 h-3 w-3"}),"Enabled"]})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"space-y-2",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Uu,{className:"h-4 w-4 text-muted-foreground"}),c.jsx("p",{className:"font-medium text-sm",children:"Allowed Countries"})]}),c.jsx("div",{className:"flex flex-wrap gap-2",children:e.allowedCountries.map(t=>c.jsx(Ge,{variant:"secondary",children:t},t))}),c.jsx("p",{className:"text-muted-foreground text-xs",children:"Messages can only be sent to these countries. All others are blocked."})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"AIT Filtering"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.aitFiltering?"Enabled - adds per-message cost":"Disabled - no extra cost"})]}),c.jsx(Ge,{variant:e.aitFiltering?"default":"secondary",children:e.aitFiltering?"Enabled":"Disabled"})]})]})]}):c.jsx(Re,{children:c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Zh,{className:"h-5 w-5"}),"Fraud Protection"]}),c.jsx(We,{children:"Not configured"})]})})}function xve({configSet:e,onRefresh:t}){const[n,r]=w.useState(!1),[i,o]=w.useState(!1);if(!e)return c.jsx(Re,{children:c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Ki,{className:"h-5 w-5"}),"Configuration Set"]}),c.jsx(We,{children:"No configuration set found"})]})});const l=async()=>{o(!0);try{const u=sessionStorage.getItem("wraps-auth-token"),d=!e.sendingEnabled,h=await fetch(`/api/sms/settings/sending?token=${u}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({enabled:d})});if(!h.ok)throw new Error(`Failed to update: ${h.statusText}`);r(!1),jt.success(d?"SMS sending enabled":"SMS sending disabled"),t&&await t()}catch(u){console.error("Failed to toggle sending:",u),jt.error("Failed to update setting",{description:u instanceof Error?u.message:"Unknown error"})}finally{o(!1)}};return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs(Ue,{className:"flex items-center gap-2",children:[c.jsx(Ki,{className:"h-5 w-5"}),"Configuration Set"]}),c.jsx(We,{children:"SMS sending configuration"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium",children:e.name}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"Configuration Set Name"})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex-1 space-y-0.5",children:[c.jsx("p",{className:"font-medium text-sm",children:"SMS Sending"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.sendingEnabled?"Messages can be sent":"Message sending is disabled"})]}),c.jsx(Ce,{onClick:()=>r(!0),size:"sm",variant:e.sendingEnabled?"destructive":"default",children:e.sendingEnabled?"Disable":"Enable"})]}),c.jsx(pp,{onOpenChange:r,open:n,children:c.jsxs(vp,{children:[c.jsxs(gp,{children:[c.jsx(bp,{children:e.sendingEnabled?"Disable SMS sending?":"Enable SMS sending?"}),c.jsx(xp,{children:e.sendingEnabled?"All outgoing SMS messages will be blocked until you re-enable sending.":"This will allow SMS messages to be sent through this configuration set."})]}),c.jsxs(yp,{children:[c.jsx(Sp,{disabled:i,children:"Cancel"}),c.jsx(wp,{disabled:i,onClick:l,children:i?"Updating...":e.sendingEnabled?"Disable sending":"Enable sending"})]})]})})]})]})}function wve({eventTracking:e}){return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Event Tracking"}),c.jsx(We,{children:"Message history and event storage"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"Event Tracking"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e!=null&&e.enabled?"Tracking delivery events":"Event tracking disabled"})]}),c.jsx(Ge,{variant:e!=null&&e.enabled?"default":"secondary",children:e!=null&&e.enabled?"Enabled":"Disabled"})]}),(e==null?void 0:e.enabled)&&c.jsxs(c.Fragment,{children:[c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"Message History"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:e.dynamoDBHistory?"Stored in DynamoDB":"Not stored"})]}),c.jsx(Ge,{variant:e.dynamoDBHistory?"default":"secondary",children:e.dynamoDBHistory?"Enabled":"Disabled"})]}),e.archiveRetention&&c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("p",{className:"font-medium text-sm",children:"Retention Period"}),c.jsx("p",{className:"text-muted-foreground text-sm",children:"How long message history is kept"})]}),c.jsx(Ge,{variant:"outline",children:e.archiveRetention})]})]})]})]})}function Sve(){const[e,t]=w.useState(null),[n,r]=w.useState(!0),[i,o]=w.useState(null),l=w.useCallback(async()=>{try{r(!0);const u=sessionStorage.getItem("wraps-auth-token");if(!u)throw new Error("Authentication token not found");const d=await fetch(`/api/sms/settings?token=${u}`);if(!d.ok)throw new Error(`Failed to fetch settings: ${d.statusText}`);const h=await d.json();t(h),o(null)}catch(u){console.error("Failed to fetch SMS settings:",u),o(u instanceof Error?u.message:"Failed to load settings")}finally{r(!1)}},[]);return w.useEffect(()=>{l()},[l]),n?c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"SMS Settings"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"Configure your SMS settings and preferences"})]}),c.jsxs("div",{className:"mt-6 grid gap-6 md:grid-cols-2",children:[c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-48"}),c.jsx(Ne,{className:"mt-2 h-4 w-64"})]}),c.jsx(ze,{children:c.jsx(Ne,{className:"h-20 w-full"})})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-48"}),c.jsx(Ne,{className:"mt-2 h-4 w-64"})]}),c.jsx(ze,{children:c.jsx(Ne,{className:"h-20 w-full"})})]})]})]}):i?c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"SMS Settings"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"Configure your SMS settings and preferences"})]}),c.jsxs(qn,{className:"mt-6",variant:"destructive",children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Error Loading Settings"}),c.jsx(Un,{children:i})]})]}):c.jsxs(c.Fragment,{children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-semibold text-3xl tracking-tight",children:"SMS Settings"}),c.jsx("p",{className:"mt-2 text-muted-foreground",children:"Configure your SMS settings and preferences"})]}),c.jsxs("div",{className:"mt-6 grid gap-6 md:grid-cols-2",children:[c.jsx(yve,{phoneNumber:e==null?void 0:e.phoneNumber}),c.jsx(xve,{configSet:e==null?void 0:e.configurationSet,onRefresh:l}),c.jsx(bve,{protectConfig:e==null?void 0:e.protectConfiguration}),c.jsx(wve,{eventTracking:e==null?void 0:e.eventTracking})]})]})}var R6=["PageUp","PageDown"],D6=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],P6={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},wc="Slider",[Cj,jve,Ove]=Tp(wc),[k6]=jn(wc,[Ove]),[_ve,Fv]=k6(wc),$6=w.forwardRef((e,t)=>{const{name:n,min:r=0,max:i=100,step:o=1,orientation:l="horizontal",disabled:u=!1,minStepsBetweenThumbs:d=0,defaultValue:h=[r],value:v,onValueChange:p=()=>{},onValueCommit:g=()=>{},inverted:b=!1,form:O,...j}=e,x=w.useRef(new Set),_=w.useRef(0),E=l==="horizontal"?Eve:Ave,[C=[],N]=An({prop:v,defaultProp:h,onChange:L=>{var W;(W=[...x.current][_.current])==null||W.focus(),p(L)}}),M=w.useRef(C);function R(L){const F=Rve(C,L);Y(L,F)}function D(L){Y(L,_.current)}function z(){const L=M.current[_.current];C[_.current]!==L&&g(C)}function Y(L,F,{commit:W}={commit:!1}){const Q=$ve(o),X=Ive(Math.round((L-r)/o)*o+r,Q),k=pm(X,[r,i]);N((H=[])=>{const B=Tve(H,k,F);if(kve(B,d*o)){_.current=B.indexOf(k);const Z=String(B)!==String(H);return Z&&W&&g(B),Z?B:H}else return H})}return c.jsx(_ve,{scope:e.__scopeSlider,name:n,disabled:u,min:r,max:i,valueIndexToChangeRef:_,thumbs:x.current,values:C,orientation:l,form:O,children:c.jsx(Cj.Provider,{scope:e.__scopeSlider,children:c.jsx(Cj.Slot,{scope:e.__scopeSlider,children:c.jsx(E,{"aria-disabled":u,"data-disabled":u?"":void 0,...j,ref:t,onPointerDown:ye(j.onPointerDown,()=>{u||(M.current=C)}),min:r,max:i,inverted:b,onSlideStart:u?void 0:R,onSlideMove:u?void 0:D,onSlideEnd:u?void 0:z,onHomeKeyDown:()=>!u&&Y(r,0,{commit:!0}),onEndKeyDown:()=>!u&&Y(i,C.length-1,{commit:!0}),onStepKeyDown:({event:L,direction:F})=>{if(!u){const X=R6.includes(L.key)||L.shiftKey&&D6.includes(L.key)?10:1,k=_.current,H=C[k],B=o*X*F;Y(H+B,k,{commit:!0})}}})})})})});$6.displayName=wc;var[I6,L6]=k6(wc,{startEdge:"left",endEdge:"right",size:"width",direction:1}),Eve=w.forwardRef((e,t)=>{const{min:n,max:r,dir:i,inverted:o,onSlideStart:l,onSlideMove:u,onSlideEnd:d,onStepKeyDown:h,...v}=e,[p,g]=w.useState(null),b=Be(t,E=>g(E)),O=w.useRef(void 0),j=tc(i),x=j==="ltr",_=x&&!o||!x&&o;function A(E){const C=O.current||p.getBoundingClientRect(),N=[0,C.width],R=G_(N,_?[n,r]:[r,n]);return O.current=C,R(E-C.left)}return c.jsx(I6,{scope:e.__scopeSlider,startEdge:_?"left":"right",endEdge:_?"right":"left",direction:_?1:-1,size:"width",children:c.jsx(z6,{dir:j,"data-orientation":"horizontal",...v,ref:b,style:{...v.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:E=>{const C=A(E.clientX);l==null||l(C)},onSlideMove:E=>{const C=A(E.clientX);u==null||u(C)},onSlideEnd:()=>{O.current=void 0,d==null||d()},onStepKeyDown:E=>{const N=P6[_?"from-left":"from-right"].includes(E.key);h==null||h({event:E,direction:N?-1:1})}})})}),Ave=w.forwardRef((e,t)=>{const{min:n,max:r,inverted:i,onSlideStart:o,onSlideMove:l,onSlideEnd:u,onStepKeyDown:d,...h}=e,v=w.useRef(null),p=Be(t,v),g=w.useRef(void 0),b=!i;function O(j){const x=g.current||v.current.getBoundingClientRect(),_=[0,x.height],E=G_(_,b?[r,n]:[n,r]);return g.current=x,E(j-x.top)}return c.jsx(I6,{scope:e.__scopeSlider,startEdge:b?"bottom":"top",endEdge:b?"top":"bottom",size:"height",direction:b?1:-1,children:c.jsx(z6,{"data-orientation":"vertical",...h,ref:p,style:{...h.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:j=>{const x=O(j.clientY);o==null||o(x)},onSlideMove:j=>{const x=O(j.clientY);l==null||l(x)},onSlideEnd:()=>{g.current=void 0,u==null||u()},onStepKeyDown:j=>{const _=P6[b?"from-bottom":"from-top"].includes(j.key);d==null||d({event:j,direction:_?-1:1})}})})}),z6=w.forwardRef((e,t)=>{const{__scopeSlider:n,onSlideStart:r,onSlideMove:i,onSlideEnd:o,onHomeKeyDown:l,onEndKeyDown:u,onStepKeyDown:d,...h}=e,v=Fv(wc,n);return c.jsx(Ee.span,{...h,ref:t,onKeyDown:ye(e.onKeyDown,p=>{p.key==="Home"?(l(p),p.preventDefault()):p.key==="End"?(u(p),p.preventDefault()):R6.concat(D6).includes(p.key)&&(d(p),p.preventDefault())}),onPointerDown:ye(e.onPointerDown,p=>{const g=p.target;g.setPointerCapture(p.pointerId),p.preventDefault(),v.thumbs.has(g)?g.focus():r(p)}),onPointerMove:ye(e.onPointerMove,p=>{p.target.hasPointerCapture(p.pointerId)&&i(p)}),onPointerUp:ye(e.onPointerUp,p=>{const g=p.target;g.hasPointerCapture(p.pointerId)&&(g.releasePointerCapture(p.pointerId),o(p))})})}),B6="SliderTrack",q6=w.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,i=Fv(B6,n);return c.jsx(Ee.span,{"data-disabled":i.disabled?"":void 0,"data-orientation":i.orientation,...r,ref:t})});q6.displayName=B6;var Tj="SliderRange",U6=w.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,i=Fv(Tj,n),o=L6(Tj,n),l=w.useRef(null),u=Be(t,l),d=i.values.length,h=i.values.map(g=>G6(g,i.min,i.max)),v=d>1?Math.min(...h):0,p=100-Math.max(...h);return c.jsx(Ee.span,{"data-orientation":i.orientation,"data-disabled":i.disabled?"":void 0,...r,ref:u,style:{...e.style,[o.startEdge]:v+"%",[o.endEdge]:p+"%"}})});U6.displayName=Tj;var Mj="SliderThumb",H6=w.forwardRef((e,t)=>{const n=jve(e.__scopeSlider),[r,i]=w.useState(null),o=Be(t,u=>i(u)),l=w.useMemo(()=>r?n().findIndex(u=>u.ref.current===r):-1,[n,r]);return c.jsx(Nve,{...e,ref:o,index:l})}),Nve=w.forwardRef((e,t)=>{const{__scopeSlider:n,index:r,name:i,...o}=e,l=Fv(Mj,n),u=L6(Mj,n),[d,h]=w.useState(null),v=Be(t,A=>h(A)),p=d?l.form||!!d.closest("form"):!0,g=$p(d),b=l.values[r],O=b===void 0?0:G6(b,l.min,l.max),j=Mve(r,l.values.length),x=g==null?void 0:g[u.size],_=x?Dve(x,O,u.direction):0;return w.useEffect(()=>{if(d)return l.thumbs.add(d),()=>{l.thumbs.delete(d)}},[d,l.thumbs]),c.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[u.startEdge]:`calc(${O}% + ${_}px)`},children:[c.jsx(Cj.ItemSlot,{scope:e.__scopeSlider,children:c.jsx(Ee.span,{role:"slider","aria-label":e["aria-label"]||j,"aria-valuemin":l.min,"aria-valuenow":b,"aria-valuemax":l.max,"aria-orientation":l.orientation,"data-orientation":l.orientation,"data-disabled":l.disabled?"":void 0,tabIndex:l.disabled?void 0:0,...o,ref:v,style:b===void 0?{display:"none"}:e.style,onFocus:ye(e.onFocus,()=>{l.valueIndexToChangeRef.current=r})})}),p&&c.jsx(F6,{name:i??(l.name?l.name+(l.values.length>1?"[]":""):void 0),form:l.form,value:b},r)]})});H6.displayName=Mj;var Cve="RadioBubbleInput",F6=w.forwardRef(({__scopeSlider:e,value:t,...n},r)=>{const i=w.useRef(null),o=Be(i,r),l=tv(t);return w.useEffect(()=>{const u=i.current;if(!u)return;const d=window.HTMLInputElement.prototype,v=Object.getOwnPropertyDescriptor(d,"value").set;if(l!==t&&v){const p=new Event("input",{bubbles:!0});v.call(u,t),u.dispatchEvent(p)}},[l,t]),c.jsx(Ee.input,{style:{display:"none"},...n,ref:o,defaultValue:t})});F6.displayName=Cve;function Tve(e=[],t,n){const r=[...e];return r[n]=t,r.sort((i,o)=>i-o)}function G6(e,t,n){const o=100/(n-t)*(e-t);return pm(o,[0,100])}function Mve(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function Rve(e,t){if(e.length===1)return 0;const n=e.map(i=>Math.abs(i-t)),r=Math.min(...n);return n.indexOf(r)}function Dve(e,t,n){const r=e/2,o=G_([0,50],[0,r]);return(r-o(t)*n)*n}function Pve(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}function kve(e,t){if(t>0){const n=Pve(e);return Math.min(...n)>=t}return!0}function G_(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function $ve(e){return(String(e).split(".")[1]||"").length}function Ive(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}var Lve=$6,zve=q6,Bve=U6,qve=H6;function Uve({className:e,defaultValue:t,value:n,min:r=0,max:i=100,...o}){const l=w.useMemo(()=>Array.isArray(n)?n:Array.isArray(t)?t:[r,i],[n,t,r,i]);return c.jsxs(Lve,{className:me("relative flex w-full touch-none select-none items-center data-[orientation=vertical]:h-full data-[orientation=vertical]:min-h-44 data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col data-[disabled]:opacity-50",e),"data-slot":"slider",defaultValue:t,max:i,min:r,value:n,...o,children:[c.jsx(zve,{className:me("relative grow overflow-hidden rounded-full bg-muted data-[orientation=horizontal]:h-1.5 data-[orientation=vertical]:h-full data-[orientation=horizontal]:w-full data-[orientation=vertical]:w-1.5"),"data-slot":"slider-track",children:c.jsx(Bve,{className:me("absolute bg-primary data-[orientation=horizontal]:h-full data-[orientation=vertical]:w-full"),"data-slot":"slider-range"})}),Array.from({length:l.length},(u,d)=>c.jsx(qve,{className:"block size-4 shrink-0 rounded-full border border-primary bg-white shadow-sm ring-ring/50 transition-[color,box-shadow] hover:ring-4 focus-visible:outline-hidden focus-visible:ring-4 disabled:pointer-events-none disabled:opacity-50","data-slot":"slider-thumb"},`thumb-${l[d]}-${d}`))]})}var Gv="Switch",[Hve]=jn(Gv),[Fve,Gve]=Hve(Gv),V6=w.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:o,required:l,disabled:u,value:d="on",onCheckedChange:h,form:v,...p}=e,[g,b]=w.useState(null),O=Be(t,E=>b(E)),j=w.useRef(!1),x=g?v||!!g.closest("form"):!0,[_,A]=An({prop:i,defaultProp:o??!1,onChange:h,caller:Gv});return c.jsxs(Fve,{scope:n,checked:_,disabled:u,children:[c.jsx(Ee.button,{type:"button",role:"switch","aria-checked":_,"aria-required":l,"data-state":X6(_),"data-disabled":u?"":void 0,disabled:u,value:d,...p,ref:O,onClick:ye(e.onClick,E=>{A(C=>!C),x&&(j.current=E.isPropagationStopped(),j.current||E.stopPropagation())})}),x&&c.jsx(K6,{control:g,bubbles:!j.current,name:r,value:d,checked:_,required:l,disabled:u,form:v,style:{transform:"translateX(-100%)"}})]})});V6.displayName=Gv;var Y6="SwitchThumb",W6=w.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,i=Gve(Y6,n);return c.jsx(Ee.span,{"data-state":X6(i.checked),"data-disabled":i.disabled?"":void 0,...r,ref:t})});W6.displayName=Y6;var Vve="SwitchBubbleInput",K6=w.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:r=!0,...i},o)=>{const l=w.useRef(null),u=Be(l,o),d=tv(n),h=$p(t);return w.useEffect(()=>{const v=l.current;if(!v)return;const p=window.HTMLInputElement.prototype,b=Object.getOwnPropertyDescriptor(p,"checked").set;if(d!==n&&b){const O=new Event("click",{bubbles:r});b.call(v,n),v.dispatchEvent(O)}},[d,n,r]),c.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:u,style:{...i.style,...h,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});K6.displayName=Vve;function X6(e){return e?"checked":"unchecked"}var Yve=V6,Wve=W6;function Kve({className:e,...t}){return c.jsx(Yve,{className:me("peer inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs outline-none transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input dark:data-[state=unchecked]:bg-input/80",e),"data-slot":"switch",...t,children:c.jsx(Wve,{className:me("pointer-events-none block size-4 rounded-full bg-background ring-0 transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0 dark:data-[state=checked]:bg-primary-foreground dark:data-[state=unchecked]:bg-foreground"),"data-slot":"switch-thumb"})})}async function L4(e){try{const t=document.createElement("canvas");return t.width=1,t.height=1,t.toDataURL(e).startsWith(`data:${e}`)}catch{return!1}}async function Xve(){const[e,t]=await Promise.all([L4("image/webp"),L4("image/avif")]);return{webp:e,avif:t,offscreenCanvas:typeof OffscreenCanvas<"u",webWorker:typeof Worker<"u",wasm:typeof WebAssembly<"u"}}let zh=null;async function Qve(){return zh||(zh=await Xve(),zh)}async function Zve(e){if(e.type!=="image/gif")return{isAnimated:!1,frameCount:1,size:e.size};try{const t=await e.arrayBuffer(),n=new Uint8Array(t);let r=0;for(let i=0;i<n.length-2;i++)n[i]===33&&n[i+1]===249&&r++;return{isAnimated:r>1,frameCount:Math.max(1,r),size:e.size}}catch{return{isAnimated:!1,frameCount:1,size:e.size}}}function Jve(e){return e.type==="image/gif"}function ege(e){return new Promise((t,n)=>{const r=new FileReader;r.onload=()=>t(r.result),r.onerror=()=>n(new Error("Failed to read blob")),r.readAsDataURL(e)})}function Q6(e){return ege(e)}function Bh(e){if(e===0)return"0 B";const t=1024,n=["B","KB","MB","GB"],r=Math.floor(Math.log(e)/Math.log(t));return`${Number.parseFloat((e/t**r).toFixed(1))} ${n[r]}`}function tge(e){return new Promise((t,n)=>{const r=new Image,i=URL.createObjectURL(e);r.onload=()=>{URL.revokeObjectURL(i),t({width:r.naturalWidth,height:r.naturalHeight})},r.onerror=()=>{URL.revokeObjectURL(i),n(new Error("Failed to load image"))},r.src=i})}class nge{constructor(){rb(this,"worker",null);rb(this,"pending",new Map)}getWorker(){return this.worker||(this.worker=new Worker(new URL("/assets/optimizer.worker-CeufIUo5.js",import.meta.url),{type:"module"}),this.worker.onmessage=this.handleMessage.bind(this),this.worker.onerror=this.handleError.bind(this)),this.worker}handleMessage(t){const{id:n,result:r,error:i,progress:o}=t.data,l=this.pending.get(n);if(l){if(o!==void 0&&o<100&&l.onProgress){l.onProgress(o);return}if(i){l.reject(new Error(i)),this.pending.delete(n);return}r&&(l.resolve(r),this.pending.delete(n))}}handleError(t){console.error("Image optimizer worker error:",t);for(const[n,r]of this.pending)r.reject(new Error(`Worker error: ${t.message}`)),this.pending.delete(n);this.terminate()}generateId(){return crypto.randomUUID()}async optimize(t,n,r){const i=this.generateId();return new Promise((o,l)=>{this.pending.set(i,{resolve:o,reject:l,onProgress:r}),this.getWorker().postMessage({id:i,type:"optimize",file:t,options:n})})}async preview(t,n,r){const i=await Q6(t);return{...await this.optimize(t,n,r),originalDataUrl:i}}cancelAll(){for(const[t,n]of this.pending)n.reject(new Error("Operation cancelled")),this.pending.delete(t)}terminate(){this.cancelAll(),this.worker&&(this.worker.terminate(),this.worker=null)}get isActive(){return this.worker!==null}get pendingCount(){return this.pending.size}}const rge=new nge;async function age(e,t,n){return rge.preview(e,t,n)}const ige=[{value:"webp",label:"WebP",description:"Best balance of size and quality"},{value:"avif",label:"AVIF",description:"Best compression"},{value:"jpeg",label:"JPEG",description:"Universal compatibility"},{value:"png",label:"PNG",description:"Lossless, supports transparency"},{value:"original",label:"Original",description:"Keep original format"}],oge=[{value:1,label:"1x",description:"Standard displays"},{value:2,label:"2x",description:"Retina / HiDPI (recommended)"},{value:3,label:"3x",description:"iPhone Pro / flagship phones"}];function Rj(e){const t=e/1024,n=t/1024;return n>2?{level:"error",message:"This image will cause delivery issues (>2MB)",suggestion:"Reduce dimensions or increase compression to under 1MB"}:n>1?{level:"warning",message:"Most email clients struggle with images >1MB",suggestion:"Consider reducing to under 500KB for best deliverability"}:t>500?{level:"info",message:"Larger than recommended for email (>500KB)",suggestion:"This may slow load times on mobile devices"}:null}function L1(e){const t=Rj(e);if(!t)return{label:"Good",color:"text-green-600"};switch(t.level){case"info":return{label:"OK",color:"text-yellow-600"};case"warning":return{label:"Large",color:"text-orange-600"};case"error":return{label:"Too Large",color:"text-red-600"};default:return{label:"Unknown",color:"text-muted-foreground"}}}const sge=[{value:"none",label:"Original size",description:"Keep original dimensions"},{value:"600",label:"Email (600px)",description:"Standard email width"},{value:"800",label:"Medium (800px)",description:"Blog posts, cards"},{value:"1200",label:"Large (1200px)",description:"Full-width content"},{value:"1440",label:"Hero (1440px)",description:"Banner images"},{value:"1920",label:"Full HD (1920px)",description:"Desktop screens"}];function lge({files:e,onComplete:t,onClose:n,open:r}){var q;const[i,o]=w.useState([]),[l,u]=w.useState(null),[d,h]=w.useState(!1),v=i.reduce((U,ne)=>U+ne.file.size,0),p=i.reduce((U,ne)=>{var fe;return U+(((fe=ne.preview)==null?void 0:fe.optimizedSize)??ne.file.size)},0),g=v>0?Math.round((1-p/v)*100):0,b=i.length>0&&i.every(U=>U.status==="ready"||U.status==="done"||U.isAnimatedGif),O=i.some(U=>U.status==="pending"&&!U.isAnimatedGif),j=i.some(U=>U.status==="processing"),[x,_]=w.useState(!0),[A,E]=w.useState(!1),[C,N]=w.useState({format:"webp",quality:85}),[M,R]=w.useState(85),[D,z]=w.useState("none"),[Y,L]=w.useState(2),[F,W]=w.useState(!0);w.useEffect(()=>{Qve().then(U=>{W(U.wasm&&U.webWorker&&U.offscreenCanvas)})},[]),w.useEffect(()=>{var ne;if(!r||e.length===0)return;const U=e.map((fe,ie)=>({id:`${fe.name}-${ie}-${Date.now()}`,file:fe,status:"pending"}));o(U),u(((ne=U[0])==null?void 0:ne.id)??null),E(!1),h(!1);for(const fe of U)Q6(fe.file).then(ie=>{o(pe=>pe.map(re=>re.id===fe.id?{...re,thumbnailUrl:ie}:re))}),Jve(fe.file)&&Zve(fe.file).then(ie=>{ie.isAnimated&&o(pe=>pe.map(re=>re.id===fe.id?{...re,isAnimatedGif:!0,status:"ready"}:re))})},[r,e]);const Q=w.useCallback(async()=>{const U=i.filter(ne=>ne.status==="pending"&&!ne.isAnimatedGif);if(U.length===0){h(!1);return}for(const ne of U){o(fe=>fe.map(ie=>ie.id===ne.id?{...ie,status:"processing"}:ie));try{let fe;if(D==="none"){if(Y>1){const re=await tge(ne.file);fe=Math.round(re.width/Y)}}else fe=Number(D)*Y;const ie={...C,maxWidth:fe},pe=await age(ne.file,ie);o(re=>re.map(ve=>ve.id===ne.id?{...ve,status:"ready",preview:pe}:ve))}catch{o(fe=>fe.map(ie=>ie.id===ne.id?{...ie,status:"ready"}:ie))}}h(!1)},[i,C,D,Y]),X=`${C.format}-${C.quality}-${D}-${Y}`,k=w.useRef(X);w.useEffect(()=>{k.current!==X&&(k.current=X,o(U=>U.map(ne=>ne.isAnimatedGif?ne:{...ne,status:"pending",preview:void 0})),h(!1))},[X]);const H=U=>{const ne=U.name.replace(/\.[^/.]+$/,""),fe=C.format==="original"?U.name.split(".").pop():C.format;return`${ne}.${fe}`},B=()=>{h(!0),Q()},Z=()=>{const U=i.map(ne=>!x||ne.isAnimatedGif||!ne.preview?{file:ne.file,cdnFilename:ne.file.name}:{file:ne.preview.blob,cdnFilename:H(ne.file)});t(U),n()},le=()=>{const U=i.map(ne=>({file:ne.file,cdnFilename:ne.file.name}));t(U),n()};if(!r)return null;const $=i.length===1,V=$?i[0]:null;return c.jsx(_O,{onOpenChange:U=>!U&&n(),open:r,children:c.jsxs(EO,{className:"max-w-lg",children:[c.jsx(K3,{children:c.jsx(Q3,{className:"flex items-center gap-2",children:$?c.jsxs(c.Fragment,{children:[c.jsx(mb,{className:"h-5 w-5 text-muted-foreground"}),c.jsx("span",{className:"truncate",children:V==null?void 0:V.file.name})]}):c.jsxs(c.Fragment,{children:[c.jsx(mb,{className:"h-5 w-5 text-muted-foreground"}),i.length," images selected"]})})}),c.jsxs("div",{className:"space-y-4",children:[!$&&c.jsxs("div",{className:"grid grid-cols-6 gap-2",children:[i.slice(0,11).map(U=>c.jsxs(Xp,{children:[c.jsx(Qp,{asChild:!0,children:c.jsxs("div",{className:`relative aspect-square overflow-hidden rounded-md border bg-muted ${U.id===l?"ring-2 ring-primary":""}`,children:[U.thumbnailUrl?c.jsx("img",{alt:U.file.name,className:"h-full w-full object-cover",src:U.thumbnailUrl}):c.jsx("div",{className:"flex h-full items-center justify-center",children:c.jsx(mb,{className:"h-4 w-4 text-muted-foreground"})}),U.status==="processing"&&c.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-background/50",children:c.jsx(Ha,{className:"h-3 w-3 animate-spin"})}),U.status==="ready"&&U.preview&&c.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-green-500/20",children:c.jsx(Ja,{className:"h-4 w-4 text-green-600"})}),U.isAnimatedGif&&c.jsx(Ge,{className:"absolute right-0.5 bottom-0.5 h-4 px-1 text-[10px]",children:"GIF"})]})}),c.jsxs(Zp,{side:"bottom",children:[c.jsx("p",{className:"font-medium text-xs",children:U.file.name}),c.jsxs("p",{className:"text-muted-foreground text-xs",children:[Bh(U.file.size),U.preview&&` → ${Bh(U.preview.optimizedSize)}`]})]})]},U.id)),i.length>11&&c.jsxs("div",{className:"flex aspect-square items-center justify-center rounded-md border bg-muted text-muted-foreground text-xs",children:["+",i.length-11]})]}),$&&V&&c.jsxs("div",{className:"relative aspect-video overflow-hidden rounded-lg border bg-muted",children:[V.thumbnailUrl?c.jsx("img",{alt:V.file.name,className:"h-full w-full object-contain",src:V.thumbnailUrl}):c.jsx("div",{className:"flex h-full items-center justify-center",children:c.jsx(Ha,{className:"h-6 w-6 animate-spin text-muted-foreground"})}),V.status==="processing"&&c.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-background/50",children:c.jsx(Ha,{className:"h-6 w-6 animate-spin"})}),V.status==="ready"&&V.preview&&c.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-green-500/10",children:c.jsx(Ja,{className:"h-8 w-8 text-green-600"})})]}),c.jsxs("div",{className:"rounded-lg border bg-muted/30 p-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsxs("p",{className:"text-muted-foreground text-sm",children:[c.jsx("span",{className:L1(v).color,children:Bh(v)}),x&&b&&g>0&&c.jsxs(c.Fragment,{children:[c.jsx("span",{className:"mx-2",children:"→"}),c.jsx("span",{className:`font-medium ${L1(p).color}`,children:Bh(p)})]})]}),j&&c.jsx("p",{className:"text-muted-foreground text-xs",children:"Optimizing..."}),!j&&Rj(b?p:v)&&c.jsx("p",{className:`text-xs ${L1(b?p:v).color}`,children:(q=Rj(b?p:v))==null?void 0:q.suggestion})]}),x&&b&&g>0&&c.jsxs(Ge,{className:"bg-green-100 text-green-700 dark:bg-green-900 dark:text-green-300",variant:"secondary",children:[c.jsx(_F,{className:"mr-1 h-3 w-3"}),"Save ",g,"%"]})]}),j&&c.jsx(Uv,{className:"mt-3 h-1",value:i.filter(U=>U.status==="ready"||U.isAnimatedGif).length/i.length*100})]}),F&&c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx(Lo,{className:"cursor-pointer",htmlFor:"optimize-toggle",children:"Optimize before uploading"}),c.jsx(Kve,{checked:x,id:"optimize-toggle",onCheckedChange:_})]}),x&&F&&c.jsxs(yc,{onOpenChange:E,open:A,children:[c.jsx(bc,{asChild:!0,children:c.jsxs(Ce,{className:"w-full justify-start text-muted-foreground",size:"sm",variant:"ghost",children:[A?c.jsx(rs,{className:"mr-2 h-4 w-4"}):c.jsx(dF,{className:"mr-2 h-4 w-4"}),"Options"]})}),c.jsxs(xc,{className:"space-y-4 pt-2",children:[c.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[c.jsxs("div",{className:"space-y-2",children:[c.jsx(Lo,{className:"text-muted-foreground text-xs",children:"Format"}),c.jsxs(fa,{onValueChange:U=>N({...C,format:U}),value:C.format||"webp",children:[c.jsx(ha,{className:"h-9",children:c.jsx(da,{})}),c.jsx(ma,{children:ige.map(U=>c.jsx(Fe,{value:U.value,children:U.label},U.value))})]})]}),c.jsxs("div",{className:"space-y-2",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx(Lo,{className:"text-muted-foreground text-xs",children:"Quality"}),c.jsxs("span",{className:"text-muted-foreground text-xs",children:[M,"%"]})]}),c.jsx(Uve,{className:"mt-2",max:100,min:50,onValueChange:([U])=>R(U),onValueCommit:([U])=>N({...C,quality:U}),step:5,value:[M]})]})]}),c.jsxs("div",{className:"space-y-3 rounded-lg border bg-muted/20 p-3",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx(Lo,{className:"font-medium text-xs",children:"Resize Image"}),c.jsx("span",{className:"text-muted-foreground text-xs",children:"Maintains aspect ratio"})]}),c.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[c.jsxs("div",{className:"space-y-2",children:[c.jsx(Lo,{className:"text-muted-foreground text-xs",children:"Max Width"}),c.jsxs(fa,{onValueChange:z,value:D,children:[c.jsx(ha,{className:"h-9",children:c.jsx(da,{})}),c.jsx(ma,{children:sge.map(U=>c.jsx(Fe,{value:U.value,children:c.jsxs("div",{className:"flex flex-col",children:[c.jsx("span",{children:U.label}),c.jsx("span",{className:"text-muted-foreground text-xs",children:U.description})]})},U.value))})]})]}),c.jsxs("div",{className:"space-y-2",children:[c.jsx(Lo,{className:"text-muted-foreground text-xs",children:"Pixel Density"}),c.jsxs(fa,{onValueChange:U=>L(Number(U)),value:String(Y),children:[c.jsx(ha,{className:"h-9",children:c.jsx(da,{})}),c.jsx(ma,{children:oge.map(U=>c.jsx(Fe,{value:String(U.value),children:c.jsxs("div",{className:"flex flex-col",children:[c.jsx("span",{children:U.label}),c.jsx("span",{className:"text-muted-foreground text-xs",children:U.description})]})},U.value))})]})]})]}),c.jsx("p",{className:"text-muted-foreground text-xs",children:D==="none"?Y===1?"Original dimensions preserved":`Scales to 1/${Y} original size`:`Output: ${Number(D)*Y}px actual width`})]})]})]})]}),c.jsxs(X3,{className:"gap-2 sm:gap-0",children:[c.jsx(Ce,{onClick:n,variant:"ghost",children:"Cancel"}),x&&F?c.jsxs(c.Fragment,{children:[c.jsx(Ce,{onClick:le,variant:"outline",children:"Upload originals"}),b?c.jsxs(Ce,{onClick:Z,children:[c.jsx(Hu,{className:"mr-2 h-4 w-4"}),"Upload",g>0&&` (save ${g}%)`]}):c.jsxs(Ce,{disabled:d||!O,onClick:B,children:[d?c.jsx(Ha,{className:"mr-2 h-4 w-4 animate-spin"}):c.jsx(TF,{className:"mr-2 h-4 w-4"}),d?"Optimizing...":"Optimize"]})]}):c.jsxs(Ce,{onClick:le,children:[c.jsx(Hu,{className:"mr-2 h-4 w-4"}),"Upload"]})]})]})})}var Z6="Toggle",J6=w.forwardRef((e,t)=>{const{pressed:n,defaultPressed:r,onPressedChange:i,...o}=e,[l,u]=An({prop:n,onChange:i,defaultProp:r??!1,caller:Z6});return c.jsx(Ee.button,{type:"button","aria-pressed":l,"data-state":l?"on":"off","data-disabled":e.disabled?"":void 0,...o,ref:t,onClick:ye(e.onClick,()=>{e.disabled||u(!l)})})});J6.displayName=Z6;var co="ToggleGroup",[e8]=jn(co,[oc]),t8=oc(),V_=I.forwardRef((e,t)=>{const{type:n,...r}=e;if(n==="single"){const i=r;return c.jsx(cge,{...i,ref:t})}if(n==="multiple"){const i=r;return c.jsx(uge,{...i,ref:t})}throw new Error(`Missing prop \`type\` expected on \`${co}\``)});V_.displayName=co;var[n8,r8]=e8(co),cge=I.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...o}=e,[l,u]=An({prop:n,defaultProp:r??"",onChange:i,caller:co});return c.jsx(n8,{scope:e.__scopeToggleGroup,type:"single",value:I.useMemo(()=>l?[l]:[],[l]),onItemActivate:u,onItemDeactivate:I.useCallback(()=>u(""),[u]),children:c.jsx(a8,{...o,ref:t})})}),uge=I.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...o}=e,[l,u]=An({prop:n,defaultProp:r??[],onChange:i,caller:co}),d=I.useCallback(v=>u((p=[])=>[...p,v]),[u]),h=I.useCallback(v=>u((p=[])=>p.filter(g=>g!==v)),[u]);return c.jsx(n8,{scope:e.__scopeToggleGroup,type:"multiple",value:l,onItemActivate:d,onItemDeactivate:h,children:c.jsx(a8,{...o,ref:t})})});V_.displayName=co;var[fge,dge]=e8(co),a8=I.forwardRef((e,t)=>{const{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:i=!0,orientation:o,dir:l,loop:u=!0,...d}=e,h=t8(n),v=tc(l),p={role:"group",dir:v,...d};return c.jsx(fge,{scope:n,rovingFocus:i,disabled:r,children:i?c.jsx(rO,{asChild:!0,...h,orientation:o,dir:v,loop:u,children:c.jsx(Ee.div,{...p,ref:t})}):c.jsx(Ee.div,{...p,ref:t})})}),Op="ToggleGroupItem",i8=I.forwardRef((e,t)=>{const n=r8(Op,e.__scopeToggleGroup),r=dge(Op,e.__scopeToggleGroup),i=t8(e.__scopeToggleGroup),o=n.value.includes(e.value),l=r.disabled||e.disabled,u={...e,pressed:o,disabled:l},d=I.useRef(null);return r.rovingFocus?c.jsx(aO,{asChild:!0,...i,focusable:!l,active:o,ref:d,children:c.jsx(z4,{...u,ref:t})}):c.jsx(z4,{...u,ref:t})});i8.displayName=Op;var z4=I.forwardRef((e,t)=>{const{__scopeToggleGroup:n,value:r,...i}=e,o=r8(Op,n),l={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},u=o.type==="single"?l:void 0;return c.jsx(J6,{...u,...i,ref:t,onPressedChange:d=>{d?o.onItemActivate(r):o.onItemDeactivate(r)}})}),hge=V_,mge=i8;const pge=sc("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md font-medium text-sm outline-none transition-[color,box-shadow] hover:bg-muted hover:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground dark:aria-invalid:ring-destructive/40 [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",outline:"border border-input bg-transparent shadow-xs hover:bg-accent hover:text-accent-foreground"},size:{default:"h-9 min-w-9 px-2",sm:"h-8 min-w-8 px-1.5",lg:"h-10 min-w-10 px-2.5"}},defaultVariants:{variant:"default",size:"default"}}),o8=w.createContext({size:"default",variant:"default",spacing:0});function vge({className:e,variant:t,size:n,spacing:r=0,children:i,...o}){return c.jsx(hge,{className:me("group/toggle-group flex w-fit items-center gap-[var(--gap)] rounded-md data-[spacing=default]:data-[variant=outline]:shadow-xs",e),"data-size":n,"data-slot":"toggle-group","data-spacing":r,"data-variant":t,style:{"--gap":r},...o,children:c.jsx(o8.Provider,{value:{variant:t,size:n,spacing:r},children:i})})}function B4({className:e,children:t,variant:n,size:r,...i}){const o=w.useContext(o8);return c.jsx(mge,{className:me(pge({variant:o.variant||n,size:o.size||r}),"w-auto min-w-0 shrink-0 px-3 focus:z-10 focus-visible:z-10","data-[spacing=0]:data-[variant=outline]:border-l-0 data-[spacing=0]:rounded-none data-[spacing=0]:shadow-none data-[spacing=0]:last:rounded-r-md data-[spacing=0]:data-[variant=outline]:first:border-l data-[spacing=0]:first:rounded-l-md",e),"data-size":o.size||r,"data-slot":"toggle-group-item","data-spacing":o.spacing,"data-variant":o.variant||n,...i,children:t})}function gge(e){return e===0?"0 B":e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:e<1024*1024*1024?`${(e/(1024*1024)).toFixed(1)} MB`:`${(e/(1024*1024*1024)).toFixed(2)} GB`}function yge({url:e}){const[t,n]=w.useState(!1),r=async()=>{await navigator.clipboard.writeText(e),n(!0),jt.success("URL copied to clipboard"),setTimeout(()=>n(!1),2e3)};return c.jsx(Ce,{onClick:r,size:"sm",variant:"outline",children:t?c.jsx(Ja,{className:"h-3 w-3 text-green-500"}):c.jsx("span",{className:"text-xs",children:"Copy"})})}function bge(){return c.jsxs("div",{className:"space-y-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx(Ne,{className:"mb-2 h-8 w-36"}),c.jsx(Ne,{className:"h-4 w-48"})]}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx(Ne,{className:"h-9 w-9"}),c.jsx(Ne,{className:"h-9 w-24"})]})]}),c.jsxs("div",{className:"flex items-center gap-3",children:[c.jsx(Ne,{className:"h-9 min-w-[200px] flex-1"}),c.jsx(Ne,{className:"h-9 w-40"}),c.jsx(Ne,{className:"h-9 w-20"})]}),c.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-5 xl:grid-cols-6",children:[1,2,3,4,5,6,7,8,9,10,11,12].map(e=>c.jsxs("div",{className:"overflow-hidden rounded-xl bg-muted shadow-sm",children:[c.jsx(Ne,{className:"aspect-square w-full"}),c.jsxs("div",{className:"space-y-2 p-3",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Ne,{className:"h-4 w-4"}),c.jsx(Ne,{className:"h-4 flex-1"})]}),c.jsxs("div",{className:"flex items-center gap-2 pl-6",children:[c.jsx(Ne,{className:"h-4 w-10"}),c.jsx(Ne,{className:"h-4 w-12"})]})]})]},e))})]})}function xge(){return c.jsxs("div",{className:"flex flex-col items-center justify-center py-12",children:[c.jsx($f,{className:"mb-4 h-16 w-16 text-muted-foreground opacity-50"}),c.jsx("h2",{className:"mb-2 font-semibold text-xl",children:"No Storage Configured"}),c.jsxs("p",{className:"mb-6 max-w-md text-center text-muted-foreground",children:["Storage infrastructure has not been deployed yet. Run"," ",c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-sm",children:"wraps storage init"})," ","to get started."]})]})}function wge({onUploadClick:e}){return c.jsxs("div",{className:"flex flex-col items-center justify-center py-16",children:[c.jsx(u$,{className:"mb-4 h-16 w-16 text-muted-foreground opacity-50"}),c.jsx("h3",{className:"mb-2 font-semibold text-lg",children:"No Files Yet"}),c.jsx("p",{className:"mb-6 max-w-md text-center text-muted-foreground",children:"Upload your first file to get started with your CDN library"}),c.jsxs(Ce,{onClick:e,children:[c.jsx(Hu,{className:"mr-2 h-4 w-4"}),"Upload Files"]})]})}function Sge({upload:e,onRemove:t}){return c.jsx("div",{className:"flex items-center gap-3 rounded-lg border bg-muted/30 p-3",children:c.jsxs("div",{className:"min-w-0 flex-1",children:[c.jsxs("div",{className:"mb-1 flex items-center justify-between",children:[c.jsx("span",{className:"truncate font-medium text-sm",children:e.filename}),c.jsxs("div",{className:"flex items-center gap-2",children:[e.status==="uploading"&&c.jsx(Ha,{className:"h-4 w-4 animate-spin text-primary"}),e.status==="success"&&c.jsx(eo,{className:"h-4 w-4 text-green-500"}),e.status==="error"&&c.jsx(sr,{className:"h-4 w-4 text-red-500"}),c.jsx(Ce,{className:"h-6 w-6",onClick:t,size:"icon",variant:"ghost",children:c.jsx(ir,{className:"h-3 w-3"})})]})]}),e.status==="uploading"&&c.jsx(Uv,{className:"h-1",value:e.progress}),e.status==="success"&&e.cdnUrl&&c.jsxs("div",{className:"mt-1 flex items-center gap-2",children:[c.jsx("span",{className:"truncate text-muted-foreground text-xs",children:e.cdnUrl}),c.jsx(yge,{url:e.cdnUrl})]}),e.status==="error"&&c.jsx("span",{className:"text-red-500 text-xs",children:e.error})]})})}function jge({uploads:e,onFilesSelected:t,onRemoveUpload:n}){const[r,i]=w.useState(!1),o=w.useRef(null),l=v=>{v.preventDefault(),i(!0)},u=v=>{v.preventDefault(),i(!1)},d=v=>{v.preventDefault(),i(!1),v.dataTransfer.files.length>0&&t(v.dataTransfer.files)},h=v=>{v.target.files&&v.target.files.length>0&&t(v.target.files)};return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Upload Files"}),c.jsx(We,{children:"Drag and drop files or click to browse"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:`cursor-pointer rounded-lg border-2 border-dashed p-8 text-center transition-colors ${r?"border-primary bg-primary/5":"border-muted-foreground/25 hover:border-primary/50"}`,onClick:()=>{var v;return(v=o.current)==null?void 0:v.click()},onDragLeave:u,onDragOver:l,onDrop:d,children:[c.jsx(Hu,{className:"mx-auto mb-4 h-10 w-10 text-muted-foreground"}),c.jsx("p",{className:"mb-1 font-medium text-sm",children:"Drop files here or click to upload"}),c.jsx("p",{className:"text-muted-foreground text-xs",children:"Images will be optimized before uploading"}),c.jsx("input",{accept:"*/*",className:"hidden",multiple:!0,onChange:h,ref:o,type:"file"})]}),e.length>0&&c.jsx("div",{className:"space-y-2",children:e.map((v,p)=>c.jsx(Sge,{onRemove:()=>n(p),upload:v},`${v.filename}-${p}`))})]})]})}function Oge(){const[e,t]=w.useState(null),[n,r]=w.useState(!0),[i,o]=w.useState(null),[l,u]=w.useState(()=>{if(typeof window<"u"){const q=localStorage.getItem("cdn-library-view-mode");if(q==="grid"||q==="table")return q}return"grid"}),d=w.useCallback(q=>{u(q),localStorage.setItem("cdn-library-view-mode",q)},[]),[h,v]=w.useState(""),[p,g]=w.useState({starred:!1,formats:[]}),[b,O]=w.useState([]),[j,x]=w.useState(null),[_,A]=w.useState(!1),[E,C]=w.useState([]),[N,M]=w.useState({keys:[],isOpen:!1}),[R,D]=w.useState([]),[z,Y]=w.useState(!1),L=w.useCallback(async()=>{try{r(!0),o(null);const q=sessionStorage.getItem("wraps-auth-token"),U=await fetch(`/api/cdn/files?token=${q}`);if(!U.ok){if(U.status===404){t(null);return}throw new Error("Failed to fetch storage files")}const ne=await U.json();t(ne)}catch(q){o(q instanceof Error?q.message:"An error occurred")}finally{r(!1)}},[]);w.useEffect(()=>{L()},[L]);const F=w.useCallback(async(q,U)=>{const ne=sessionStorage.getItem("wraps-auth-token");try{if(!(await fetch(`/api/cdn/files/${encodeURIComponent(q)}/star?token=${ne}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({starred:U})})).ok)throw new Error("Failed to update star status");t(ie=>ie&&{...ie,files:ie.files.map(pe=>pe.key===q?{...pe,starred:U}:pe)}),(j==null?void 0:j.key)===q&&x(ie=>ie?{...ie,starred:U}:null),jt.success(U?"File starred":"Star removed")}catch{jt.error("Failed to update star status")}},[j]),W=w.useCallback(async q=>{const U=sessionStorage.getItem("wraps-auth-token");try{await Promise.all(q.map(ne=>fetch(`/api/cdn/files/${encodeURIComponent(ne)}?token=${U}`,{method:"DELETE"}))),jt.success(q.length===1?"File deleted":`${q.length} files deleted`),O([]),x(null),L()}catch{jt.error("Failed to delete file(s)")}},[L]),Q=w.useCallback(async(q,U,ne)=>{const fe=sessionStorage.getItem("wraps-auth-token"),ie=q instanceof File,pe=ne||(ie?q.name:"file"),re=q.type||"application/octet-stream";try{C(ke=>ke.map((we,Ie)=>Ie===U?{...we,status:"uploading",progress:0}:we));const ve=await fetch(`/api/cdn/upload-url?token=${fe}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filename:pe,contentType:re})});if(!ve.ok)throw new Error("Failed to get upload URL");const{uploadUrl:ge,cdnUrl:oe}=await ve.json();await new Promise((ke,we)=>{const Ie=new XMLHttpRequest;Ie.upload.addEventListener("progress",Ze=>{if(Ze.lengthComputable){const lt=Math.round(Ze.loaded/Ze.total*100);C(en=>en.map((mt,ur)=>ur===U?{...mt,progress:lt}:mt))}}),Ie.addEventListener("load",()=>{Ie.status>=200&&Ie.status<300?ke():we(new Error(`Upload failed with status ${Ie.status}`))}),Ie.addEventListener("error",()=>we(new Error("Upload failed"))),Ie.open("PUT",ge),Ie.setRequestHeader("Content-Type",re),Ie.send(q)}),C(ke=>ke.map((we,Ie)=>Ie===U?{...we,status:"success",progress:100,cdnUrl:oe}:we)),jt.success(`Uploaded ${pe}`),L()}catch(ve){C(ge=>ge.map((oe,ke)=>ke===U?{...oe,status:"error",error:ve instanceof Error?ve.message:"Upload failed"}:oe)),jt.error(`Failed to upload ${pe}`)}},[L]),X=w.useCallback(q=>{const U=Array.from(q),ne=U.filter(ie=>ie.type.startsWith("image/")),fe=U.filter(ie=>!ie.type.startsWith("image/"));if(fe.length>0){const ie=fe.map(re=>({file:re,filename:re.name,progress:0,status:"pending"}));C(re=>[...re,...ie]),A(!0);const pe=E.length;fe.forEach((re,ve)=>{Q(re,pe+ve,re.name)})}ne.length>0&&(D(ne),Y(!0))},[E.length,Q]),k=w.useCallback(q=>{if(!q||q.length===0)return;const U=E.length,ne=q.map(fe=>({file:fe.file,filename:fe.cdnFilename,progress:0,status:"pending"}));C(fe=>[...fe,...ne]),A(!0),q.forEach((fe,ie)=>{Q(fe.file,U+ie,fe.cdnFilename)})},[E.length,Q]),H=w.useCallback(q=>{O(U=>U.includes(q)?U.filter(ne=>ne!==q):[...U,q])},[]),B=w.useCallback(()=>{if(!(e!=null&&e.files))return;const q=$.map(U=>U.key);b.length===q.length?O([]):O(q)},[e==null?void 0:e.files,b.length]),Z=w.useCallback(async()=>{await Promise.all(b.map(q=>F(q,!0))),O([])},[b,F]),le=w.useCallback(()=>{M({keys:b,isOpen:!0})},[b]),$=w.useMemo(()=>e!=null&&e.files?e.files.filter(q=>{var U;if(h&&!q.key.toLowerCase().includes(h.toLowerCase())||p.starred&&!q.starred)return!1;if(p.formats.length>0){const ne=((U=q.key.split(".").pop())==null?void 0:U.toLowerCase())||"";if(!p.formats.includes(ne))return!1}return!0}):[],[e==null?void 0:e.files,h,p]),V=w.useMemo(()=>{if(!(e!=null&&e.files))return[];const q=new Set;return e.files.forEach(U=>{var fe;const ne=(fe=U.key.split(".").pop())==null?void 0:fe.toLowerCase();ne&&q.add(ne)}),Array.from(q).sort()},[e==null?void 0:e.files]);return n?c.jsx(bge,{}):i?c.jsxs(qn,{variant:"destructive",children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Error"}),c.jsx(Un,{children:i})]}):e?c.jsxs("div",{className:"space-y-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-bold text-2xl",children:"CDN Library"}),c.jsx("p",{className:"text-muted-foreground",children:e.fileCount>0?c.jsxs(c.Fragment,{children:[c.jsx("span",{className:"text-foreground",children:e.fileCount})," File",e.fileCount!==1?"s":""," · Total"," ",c.jsx("span",{className:"text-foreground",children:gge(e.totalSize)})]}):"Manage and organize your files"})]}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Ce,{onClick:L,size:"icon",variant:"outline",children:c.jsx(If,{className:"h-4 w-4"})}),c.jsxs(Ce,{onClick:()=>A(!_),children:[c.jsx(Hu,{className:"mr-2 h-4 w-4"}),"Upload"]})]})]}),_&&c.jsx(jge,{onFilesSelected:X,onRemoveUpload:q=>C(U=>U.filter((ne,fe)=>fe!==q)),uploads:E}),e.files.length>0&&c.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[b.length>0&&c.jsxs("div",{className:"flex items-center rounded-lg border",children:[c.jsxs("div",{className:"flex items-center gap-1.5 border-r px-2.5 py-1.5 text-sm font-medium",children:[b.length," selected"]}),c.jsx(ev,{className:"rounded-none border-0",onToggle:Z,size:"sm",label:"Star"}),c.jsx(H3,{className:"rounded-none border-0 border-l",onDelete:le,size:"sm",variant:"ghost",label:"Delete"}),c.jsx(Ce,{className:"rounded-l-none border-0 border-l",onClick:()=>O([]),size:"sm",variant:"ghost",children:c.jsx(ir,{className:"h-4 w-4"})})]}),c.jsxs("div",{className:"relative min-w-[200px] flex-1",children:[c.jsx(Fj,{className:"absolute top-1/2 left-3 h-4 w-4 -translate-y-1/2 text-muted-foreground"}),c.jsx(ls,{className:"pl-9",onChange:q=>v(q.target.value),placeholder:"Search files...",type:"search",value:h})]}),c.jsxs("div",{className:"flex items-center rounded-lg border",children:[c.jsxs(Ce,{className:"rounded-r-none border-0",onClick:()=>g({...p,starred:!p.starred}),size:"sm",variant:p.starred?"secondary":"ghost",children:[c.jsx(f$,{className:`mr-1.5 h-4 w-4 ${p.starred?"fill-current":""}`}),"Starred"]}),V.length>0&&c.jsxs(t3,{children:[c.jsx(n3,{asChild:!0,children:c.jsxs(Ce,{className:"rounded-l-none border-0 border-l",size:"sm",variant:"ghost",children:[c.jsx(yF,{className:"mr-1.5 h-4 w-4"}),"Formats",p.formats.length>0&&c.jsx(Ge,{className:"ml-1.5 px-1.5 py-0 text-xs",variant:"secondary",children:p.formats.length})]})}),c.jsxs(r3,{align:"end",className:"w-48",children:[c.jsx(a3,{children:"File Format"}),c.jsx(X1,{}),V.map(q=>c.jsx(WY,{checked:p.formats.includes(q),onCheckedChange:U=>{g({...p,formats:U?[...p.formats,q]:p.formats.filter(ne=>ne!==q)})},children:q.toUpperCase()},q))]})]})]}),c.jsxs(vge,{className:"rounded-lg border",onValueChange:q=>q&&d(q),type:"single",value:l,children:[c.jsx(B4,{className:"rounded-r-none border-0",value:"grid","aria-label":"Grid view",children:c.jsx(bF,{className:"h-4 w-4"})}),c.jsx(B4,{className:"rounded-l-none border-0 border-l",value:"table","aria-label":"Table view",children:c.jsx(wF,{className:"h-4 w-4"})})]})]}),e.files.length===0?c.jsx(wge,{onUploadClick:()=>A(!0)}):$.length===0?c.jsx("div",{className:"py-12 text-center text-muted-foreground",children:"No files match your search or filters"}):l==="grid"?c.jsx(cQ,{files:$,onFileClick:x,onSelectFile:H,onToggleStar:F,selectedFiles:b}):c.jsx(EQ,{files:$,onFileClick:x,onSelectAll:B,onSelectFile:H,onToggleStar:F,selectedFiles:b}),j&&c.jsx(tQ,{file:j,onClose:()=>x(null),onDelete:q=>{M({keys:[q],isOpen:!0})},onToggleStar:F}),c.jsx(pp,{onOpenChange:q=>M(U=>({...U,isOpen:q})),open:N.isOpen,children:c.jsxs(vp,{children:[c.jsxs(gp,{children:[c.jsxs(bp,{children:["Delete File",N.keys.length>1?"s":""]}),c.jsxs(xp,{children:["Are you sure you want to delete"," ",N.keys.length===1?c.jsx("strong",{children:N.keys[0].split("/").pop()}):c.jsxs("strong",{children:[N.keys.length," files"]}),"? This action cannot be undone."]})]}),c.jsxs(yp,{children:[c.jsx(Sp,{children:"Cancel"}),c.jsx(wp,{className:"bg-red-600 hover:bg-red-700",onClick:()=>{W(N.keys),M({keys:[],isOpen:!1})},children:"Delete"})]})]})}),c.jsx(lge,{files:R,onClose:()=>{Y(!1),D([])},onComplete:k,open:z})]}):c.jsx(xge,{})}function z1(e){if(e===0)return"0 B";const t=1024,n=["B","KB","MB","GB","TB"],r=Math.floor(Math.log(e)/Math.log(t));return`${Number.parseFloat((e/t**r).toFixed(1))} ${n[r]}`}function Ho(e){return e>=1e6?`${(e/1e6).toFixed(1)}M`:e>=1e3?`${(e/1e3).toFixed(1)}K`:e.toString()}function qh({title:e,value:t,description:n,icon:r,trend:i}){return c.jsxs(Re,{children:[c.jsxs(De,{className:"flex flex-row items-center justify-between pb-2",children:[c.jsx(Ue,{className:"font-medium text-muted-foreground text-sm",children:e}),c.jsx(r,{className:"h-4 w-4 text-muted-foreground"})]}),c.jsxs(ze,{children:[c.jsx("div",{className:"font-bold text-2xl",children:t}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("p",{className:"text-muted-foreground text-xs",children:n}),i!==void 0&&i!==0&&c.jsxs("span",{className:`flex items-center text-xs ${i>0?"text-green-500":"text-red-500"}`,children:[c.jsx(Gj,{className:`h-3 w-3 ${i<0?"rotate-180":""}`}),Math.abs(i),"%"]})]})]})]})}function _ge({data:e}){const t=e.map(n=>({date:new Date(n.date).toLocaleDateString("en-US",{month:"short",day:"numeric"}),size:n.size/1073741824,files:n.files}));return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Storage Usage"}),c.jsx(We,{children:"Storage size and file count over time"})]}),c.jsx(ze,{children:c.jsx(n_,{height:300,width:"100%",children:c.jsxs(s6,{data:t,children:[c.jsx(Bv,{className:"stroke-muted",strokeDasharray:"3 3"}),c.jsx(hs,{className:"text-xs",dataKey:"date",stroke:"currentColor",tick:{fill:"currentColor"}}),c.jsx(si,{className:"text-xs",stroke:"currentColor",tick:{fill:"currentColor"},tickFormatter:n=>`${n} GB`,yAxisId:"left"}),c.jsx(si,{className:"text-xs",orientation:"right",stroke:"currentColor",tick:{fill:"currentColor"},yAxisId:"right"}),c.jsx(_r,{contentStyle:{backgroundColor:"hsl(var(--card))",border:"1px solid hsl(var(--border))",borderRadius:"var(--radius)"},formatter:(n,r)=>[r==="size"?`${n.toFixed(2)} GB`:n,r==="size"?"Storage":"Files"]}),c.jsx(Xa,{}),c.jsx(Er,{dataKey:"size",dot:!1,name:"Storage (GB)",stroke:"hsl(var(--primary))",strokeWidth:2,type:"monotone",yAxisId:"left"}),c.jsx(Er,{dataKey:"files",dot:!1,name:"File Count",stroke:"hsl(var(--chart-2))",strokeWidth:2,type:"monotone",yAxisId:"right"})]})})})]})}function Ege({data:e}){const t=e.map(n=>({date:new Date(n.date).toLocaleDateString("en-US",{month:"short",day:"numeric"}),bandwidth:n.bytes/1048576,requests:n.requests}));return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"CDN Traffic"}),c.jsx(We,{children:"Bandwidth and requests over time"})]}),c.jsx(ze,{children:c.jsx(n_,{height:300,width:"100%",children:c.jsxs(bpe,{data:t,children:[c.jsx(Bv,{className:"stroke-muted",strokeDasharray:"3 3"}),c.jsx(hs,{className:"text-xs",dataKey:"date",stroke:"currentColor",tick:{fill:"currentColor"}}),c.jsx(si,{className:"text-xs",stroke:"currentColor",tick:{fill:"currentColor"},tickFormatter:n=>`${n} MB`,yAxisId:"left"}),c.jsx(si,{className:"text-xs",orientation:"right",stroke:"currentColor",tick:{fill:"currentColor"},tickFormatter:n=>Ho(n),yAxisId:"right"}),c.jsx(_r,{contentStyle:{backgroundColor:"hsl(var(--card))",border:"1px solid hsl(var(--border))",borderRadius:"var(--radius)"},formatter:(n,r)=>[r==="bandwidth"?`${n.toFixed(1)} MB`:Ho(n),r==="bandwidth"?"Bandwidth":"Requests"]}),c.jsx(Xa,{}),c.jsx(Ji,{dataKey:"bandwidth",fill:"hsl(var(--primary))",name:"Bandwidth (MB)",radius:[4,4,0,0],yAxisId:"left"}),c.jsx(Ji,{dataKey:"requests",fill:"hsl(var(--chart-3))",name:"Requests",radius:[4,4,0,0],yAxisId:"right"})]})})})]})}function Age({files:e}){return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ue,{children:"Top Files"}),c.jsx(We,{children:"Most requested files this month"})]}),c.jsx(ze,{children:e.length===0?c.jsx("div",{className:"py-4 text-center text-muted-foreground",children:"No data available"}):c.jsx("div",{className:"space-y-4",children:e.map((t,n)=>{const r=t.key.split("/").pop()||t.key,i=Math.max(...e.map(l=>l.requests)),o=t.requests/i*100;return c.jsxs("div",{children:[c.jsxs("div",{className:"mb-1 flex items-center justify-between text-sm",children:[c.jsxs("span",{className:"flex items-center gap-2",children:[c.jsxs("span",{className:"text-muted-foreground",children:[n+1,"."]}),c.jsx("span",{className:"max-w-[200px] truncate font-medium",children:r})]}),c.jsxs("span",{className:"text-muted-foreground",children:[Ho(t.requests)," requests"]})]}),c.jsx(Uv,{className:"h-2",value:o})]},t.key)})})})]})}function Nge(){return c.jsxs("div",{className:"space-y-6",children:[c.jsx("div",{className:"grid gap-4 md:grid-cols-2 lg:grid-cols-4",children:Array.from({length:4}).map((e,t)=>c.jsxs(Re,{children:[c.jsx(De,{className:"pb-2",children:c.jsx(Ne,{className:"h-4 w-20"})}),c.jsxs(ze,{children:[c.jsx(Ne,{className:"h-8 w-24"}),c.jsx(Ne,{className:"mt-2 h-3 w-32"})]})]},t))}),c.jsxs(Re,{children:[c.jsx(De,{children:c.jsx(Ne,{className:"h-6 w-32"})}),c.jsx(ze,{children:c.jsx(Ne,{className:"h-[300px] w-full"})})]})]})}function Cge(){return c.jsxs("div",{className:"flex flex-col items-center justify-center py-12",children:[c.jsx($f,{className:"mb-4 h-16 w-16 text-muted-foreground opacity-50"}),c.jsx("h2",{className:"mb-2 font-semibold text-xl",children:"No Storage Configured"}),c.jsxs("p",{className:"mb-6 max-w-md text-center text-muted-foreground",children:["Storage infrastructure has not been deployed yet. Run"," ",c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-sm",children:"wraps storage init"})," ","to get started."]})]})}function Tge(){const[e,t]=w.useState(null),[n,r]=w.useState(!0),[i,o]=w.useState(null),[l,u]=w.useState("7d"),d=w.useCallback(async()=>{try{r(!0),o(null);const h=sessionStorage.getItem("wraps-auth-token"),v=await fetch(`/api/cdn/metrics?token=${h}&range=${l}`);if(!v.ok){if(v.status===404){t(null);return}throw new Error("Failed to fetch storage metrics")}const p=await v.json();t(p)}catch(h){o(h instanceof Error?h.message:"An error occurred")}finally{r(!1)}},[l]);return w.useEffect(()=>{d()},[d]),n?c.jsx(Nge,{}):i?c.jsxs(qn,{variant:"destructive",children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Error"}),c.jsx(Un,{children:i})]}):e?c.jsxs("div",{className:"space-y-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-bold text-2xl",children:"Storage Metrics"}),c.jsx("p",{className:"text-muted-foreground",children:"Monitor your storage usage and CDN traffic"})]}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsxs(fa,{onValueChange:u,value:l,children:[c.jsx(ha,{className:"w-32",children:c.jsx(da,{})}),c.jsxs(ma,{children:[c.jsx(Fe,{value:"7d",children:"Last 7 days"}),c.jsx(Fe,{value:"30d",children:"Last 30 days"}),c.jsx(Fe,{value:"90d",children:"Last 90 days"})]})]}),c.jsxs(Ce,{onClick:d,size:"sm",variant:"outline",children:[c.jsx(If,{className:"mr-2 h-4 w-4"}),"Refresh"]})]})]}),c.jsxs("div",{className:"grid gap-4 md:grid-cols-2 lg:grid-cols-4",children:[c.jsx(qh,{description:`${Ho(e.summary.fileCount)} files`,icon:pF,title:"Storage Used",value:z1(e.summary.totalSize)}),c.jsx(qh,{description:`${z1(e.summary.bandwidth.thisMonth)} this month`,icon:uF,title:"Bandwidth Today",value:z1(e.summary.bandwidth.today)}),c.jsx(qh,{description:`${Ho(e.summary.requests.thisMonth)} this month`,icon:Uu,title:"Requests Today",value:Ho(e.summary.requests.today)}),c.jsx(qh,{description:"Files in storage",icon:fF,title:"Total Files",value:Ho(e.summary.fileCount)})]}),c.jsxs("div",{className:"grid gap-6 lg:grid-cols-2",children:[c.jsx(_ge,{data:e.usage}),c.jsx(Ege,{data:e.bandwidth})]}),c.jsx(Age,{files:e.topFiles})]}):c.jsx(Cge,{})}function _p({status:e}){const t={SUCCESS:{icon:eo,label:"Active",className:"bg-green-500/10 text-green-700 dark:text-green-400 border-green-500/20"},PENDING:{icon:Vo,label:"Pending",className:"bg-yellow-500/10 text-yellow-700 dark:text-yellow-400 border-yellow-500/20"},FAILED:{icon:c$,label:"Failed",className:"bg-red-500/10 text-red-700 dark:text-red-400 border-red-500/20"},DISABLED:{icon:sr,label:"Disabled",className:"bg-gray-500/10 text-gray-700 dark:text-gray-400 border-gray-500/20"}},{icon:n,label:r,className:i}=t[e];return c.jsxs(Ge,{className:i,variant:"outline",children:[c.jsx(n,{className:"mr-1 h-3 w-3"}),r]})}function pl({text:e}){const t=async()=>{await navigator.clipboard.writeText(e),jt.success("Copied to clipboard")};return c.jsx(Ce,{onClick:t,size:"sm",variant:"ghost",children:c.jsx(qj,{className:"h-3 w-3"})})}function Mge({settings:e}){return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx($f,{className:"h-5 w-5"}),c.jsx(Ue,{children:"S3 Bucket"})]}),c.jsx(_p,{status:"SUCCESS"})]}),c.jsx(We,{children:"Your storage bucket for uploading files"})]}),c.jsx(ze,{className:"space-y-4",children:c.jsxs("div",{className:"grid gap-4",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Bucket Name"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-sm",children:e.bucketName}),c.jsx(pl,{text:e.bucketName})]})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Region"}),c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-sm",children:e.region})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Versioning"}),c.jsx(Ge,{variant:e.versioning?"default":"secondary",children:e.versioning?"Enabled":"Disabled"})]}),c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Encryption"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Zh,{className:"h-4 w-4 text-green-500"}),c.jsx("span",{className:"text-sm",children:"AES-256"})]})]}),e.retention&&e.retention!=="none"&&c.jsxs(c.Fragment,{children:[c.jsx(Bt,{}),c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Auto-Cleanup"}),c.jsx("span",{className:"text-sm",children:e.retention})]})]})]})})]})}function Rge({settings:e}){var i,o;const[t,n]=w.useState(!1);if(!((i=e.cdn)!=null&&i.enabled))return c.jsx(Re,{children:c.jsxs(De,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Uu,{className:"h-5 w-5"}),c.jsx(Ue,{children:"CloudFront CDN"})]}),c.jsx(_p,{status:"DISABLED"})]}),c.jsx(We,{children:"CDN is not enabled for this storage bucket"})]})});const r=e.cdn.status==="Deployed"?"SUCCESS":e.cdn.status==="InProgress"?"PENDING":"FAILED";return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Uu,{className:"h-5 w-5"}),c.jsx(Ue,{children:"CloudFront CDN"})]}),c.jsx(_p,{status:r})]}),c.jsx(We,{children:"Global content delivery network for fast file access"})]}),c.jsxs(ze,{className:"space-y-4",children:[c.jsxs("div",{className:"grid gap-4",children:[e.cdn.distributionId&&c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Distribution ID"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-sm",children:e.cdn.distributionId}),c.jsx(pl,{text:e.cdn.distributionId})]})]}),c.jsx(Bt,{})]}),e.cdn.distributionDomain&&c.jsxs(c.Fragment,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"CloudFront URL"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsxs("a",{className:"text-blue-600 text-sm hover:underline dark:text-blue-400",href:`https://${e.cdn.distributionDomain}`,rel:"noopener noreferrer",target:"_blank",children:[e.cdn.distributionDomain,c.jsx(qu,{className:"ml-1 inline h-3 w-3"})]}),c.jsx(pl,{text:`https://${e.cdn.distributionDomain}`})]})]}),c.jsx(Bt,{})]}),e.cdn.customDomain&&c.jsx(c.Fragment,{children:c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Custom Domain"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsxs("a",{className:"text-blue-600 text-sm hover:underline dark:text-blue-400",href:`https://${e.cdn.customDomain}`,rel:"noopener noreferrer",target:"_blank",children:[e.cdn.customDomain,c.jsx(qu,{className:"ml-1 inline h-3 w-3"})]}),c.jsx(pl,{text:`https://${e.cdn.customDomain}`})]})]})})]}),((o=e.certificate)==null?void 0:o.validationRecords)&&e.certificate.validationRecords.length>0&&e.certificate.status==="PENDING_VALIDATION"&&c.jsxs(yc,{onOpenChange:n,open:t,children:[c.jsx(bc,{asChild:!0,children:c.jsxs(Ce,{className:"w-full justify-between",variant:"ghost",children:[c.jsxs("span",{className:"flex items-center gap-2",children:[c.jsx(sr,{className:"h-4 w-4 text-yellow-500"}),"Certificate DNS Records Required"]}),t?c.jsx("span",{className:"text-xs",children:"Hide"}):c.jsx("span",{className:"text-xs",children:"Show"})]})}),c.jsxs(xc,{className:"mt-2 space-y-2",children:[c.jsxs(qn,{children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Action Required"}),c.jsx(Un,{children:"Add these DNS records to verify your custom domain certificate"})]}),e.certificate.validationRecords.map((l,u)=>c.jsxs("div",{className:"rounded-lg border bg-muted/50 p-3 font-mono text-xs",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground",children:l.type}),c.jsx(pl,{text:l.value})]}),c.jsx("div",{className:"mt-1 break-all",children:l.name}),c.jsxs("div",{className:"mt-1 break-all text-muted-foreground",children:["→ ",l.value]})]},u))]})]})]})]})}function Dge({settings:e}){return c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(Zh,{className:"h-5 w-5"}),c.jsx(Ue,{children:"IAM Role"})]}),c.jsx(_p,{status:"SUCCESS"})]}),c.jsx(We,{children:"Role used by your application to access storage"})]}),c.jsx(ze,{children:c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("span",{className:"text-muted-foreground text-sm",children:"Role ARN"}),c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx("code",{className:"max-w-[300px] truncate rounded bg-muted px-2 py-1 font-mono text-xs",children:e.roleArn}),c.jsx(pl,{text:e.roleArn})]})]})})]})}function Pge(){return c.jsxs("div",{className:"space-y-6",children:[c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-32"}),c.jsx(Ne,{className:"h-4 w-64"})]}),c.jsx(ze,{children:c.jsxs("div",{className:"space-y-4",children:[c.jsx(Ne,{className:"h-8 w-full"}),c.jsx(Ne,{className:"h-8 w-full"}),c.jsx(Ne,{className:"h-8 w-full"})]})})]}),c.jsxs(Re,{children:[c.jsxs(De,{children:[c.jsx(Ne,{className:"h-6 w-32"}),c.jsx(Ne,{className:"h-4 w-64"})]}),c.jsx(ze,{children:c.jsxs("div",{className:"space-y-4",children:[c.jsx(Ne,{className:"h-8 w-full"}),c.jsx(Ne,{className:"h-8 w-full"})]})})]})]})}function kge(){return c.jsxs("div",{className:"flex flex-col items-center justify-center py-12",children:[c.jsx($f,{className:"mb-4 h-16 w-16 text-muted-foreground opacity-50"}),c.jsx("h2",{className:"mb-2 font-semibold text-xl",children:"No Storage Configured"}),c.jsxs("p",{className:"mb-6 max-w-md text-center text-muted-foreground",children:["Storage infrastructure has not been deployed yet. Run"," ",c.jsx("code",{className:"rounded bg-muted px-2 py-1 font-mono text-sm",children:"wraps storage init"})," ","to get started."]})]})}function $ge(){const[e,t]=w.useState(null),[n,r]=w.useState(!0),[i,o]=w.useState(null),l=w.useCallback(async()=>{try{r(!0),o(null);const u=sessionStorage.getItem("wraps-auth-token"),d=await fetch(`/api/cdn/settings?token=${u}`);if(!d.ok){if(d.status===404){t(null);return}throw new Error("Failed to fetch storage settings")}const h=await d.json();t(h)}catch(u){o(u instanceof Error?u.message:"An error occurred")}finally{r(!1)}},[]);return w.useEffect(()=>{l()},[l]),n?c.jsx(Pge,{}):i?c.jsxs(qn,{variant:"destructive",children:[c.jsx(sr,{className:"h-4 w-4"}),c.jsx(Zi,{children:"Error"}),c.jsx(Un,{children:i})]}):e?c.jsxs("div",{className:"space-y-6",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsxs("div",{children:[c.jsx("h1",{className:"font-bold text-2xl",children:"Storage Settings"}),c.jsx("p",{className:"text-muted-foreground",children:"Manage your S3 bucket and CloudFront CDN configuration"})]}),c.jsxs(Ce,{onClick:l,size:"sm",variant:"outline",children:[c.jsx(If,{className:"mr-2 h-4 w-4"}),"Refresh"]})]}),c.jsx(Mge,{settings:e}),c.jsx(Rge,{settings:e}),c.jsx(Dge,{settings:e})]}):c.jsx(kge,{})}function Ige({children:e,defaultTheme:t="system",storageKey:n="vite-ui-theme",...r}){const[i,o]=w.useState(()=>localStorage.getItem(n)||t);w.useEffect(()=>{const u=window.document.documentElement;if(u.classList.remove("light","dark"),i==="system"){const d=window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light";u.classList.add(d),u.style.colorScheme=d;return}u.classList.add(i),u.style.colorScheme=i},[i]);const l={theme:i,setTheme:u=>{localStorage.setItem(n,u),o(u)}};return c.jsx(q3.Provider,{...r,value:l,children:e})}function Lge({...e}){return c.jsx("nav",{"aria-label":"breadcrumb","data-slot":"breadcrumb",...e})}function zge({className:e,...t}){return c.jsx("ol",{className:me("flex flex-wrap items-center gap-1.5 break-words text-muted-foreground text-sm sm:gap-2.5",e),"data-slot":"breadcrumb-list",...t})}function Bge({className:e,...t}){return c.jsx("li",{className:me("inline-flex items-center gap-1.5",e),"data-slot":"breadcrumb-item",...t})}function qge({className:e,...t}){return c.jsx("span",{"aria-current":"page","aria-disabled":"true",className:me("font-normal text-foreground",e),"data-slot":"breadcrumb-page",role:"link",...t})}var Uge=(e,t,n,r,i,o,l,u)=>{let d=document.documentElement,h=["light","dark"];function v(b){(Array.isArray(e)?e:[e]).forEach(O=>{let j=O==="class",x=j&&o?i.map(_=>o[_]||_):i;j?(d.classList.remove(...x),d.classList.add(o&&o[b]?o[b]:b)):d.setAttribute(O,b)}),p(b)}function p(b){u&&h.includes(b)&&(d.style.colorScheme=b)}function g(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}if(r)v(r);else try{let b=localStorage.getItem(t)||n,O=l&&b==="system"?g():b;v(O)}catch{}},Hge=w.createContext(void 0),Fge={setTheme:e=>{},themes:[]},Gge=()=>{var e;return(e=w.useContext(Hge))!=null?e:Fge};w.memo(({forcedTheme:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:i,defaultTheme:o,value:l,themes:u,nonce:d,scriptProps:h})=>{let v=JSON.stringify([n,t,o,e,u,l,r,i]).slice(1,-1);return w.createElement("script",{...h,suppressHydrationWarning:!0,nonce:typeof window>"u"?d:"",dangerouslySetInnerHTML:{__html:`(${Uge.toString()})(${v})`}})});const Vge=({...e})=>{const{theme:t="system"}=Gge();return c.jsx(DK,{className:"toaster group",icons:{success:c.jsx(eo,{className:"size-4"}),info:c.jsx(xF,{className:"size-4"}),warning:c.jsx(NF,{className:"size-4"}),error:c.jsx(jF,{className:"size-4"}),loading:c.jsx(Ha,{className:"size-4 animate-spin"})},style:{"--normal-bg":"var(--popover)","--normal-text":"var(--popover-foreground)","--normal-border":"var(--border)","--border-radius":"var(--radius)"},theme:t,...e})};function Yge(){const e=ba(),[t,n]=w.useState(!1);w.useEffect(()=>{let i=sessionStorage.getItem("wraps-auth-token");i||(i=new URLSearchParams(window.location.search).get("token"),i&&sessionStorage.setItem("wraps-auth-token",i)),n(!0)},[]),w.useEffect(()=>{document.cookie="sidebar_state=; path=/; max-age=0"},[]);const r=()=>{if(e.pathname.startsWith("/email/")&&e.pathname!=="/email/metrics"&&e.pathname!=="/email/settings")return"Email Details";if(e.pathname.startsWith("/sms/")&&e.pathname!=="/sms/metrics"&&e.pathname!=="/sms/settings")return"SMS Details";if(e.pathname.startsWith("/cdn/")&&e.pathname!=="/cdn/metrics"&&e.pathname!=="/cdn/settings")return"File Details";switch(e.pathname){case"/":case"/email":return"Emails";case"/email/metrics":return"Email Metrics";case"/email/settings":return"Email Settings";case"/sms":return"SMS Messages";case"/sms/metrics":return"SMS Metrics";case"/sms/settings":return"SMS Settings";case"/cdn":return"CDN";case"/cdn/metrics":return"CDN Metrics";case"/cdn/settings":return"CDN Settings";default:return"Emails"}};return c.jsxs($3,{defaultOpen:!1,children:[c.jsx(oK,{}),c.jsxs(L3,{children:[c.jsxs("header",{className:"sticky top-0 flex shrink-0 items-center gap-2 border-b bg-background p-4",children:[c.jsx(I3,{className:"-ml-1"}),c.jsx(Bt,{className:"mr-2 data-[orientation=vertical]:h-4",orientation:"vertical"}),c.jsx(Lge,{children:c.jsx(zge,{children:c.jsx(Bge,{children:c.jsx(qge,{children:r()})})})})]}),c.jsx("div",{className:"flex flex-1 flex-col gap-6 p-6",children:t?c.jsxs(AH,{children:[c.jsx(Jn,{element:c.jsx(_H,{replace:!0,to:"/email"}),path:"/"}),c.jsx(Jn,{element:c.jsx(jZ,{}),path:"/email"}),c.jsx(Jn,{element:c.jsx(zQ,{}),path:"/email/:id"}),c.jsx(Jn,{element:c.jsx(Mpe,{}),path:"/email/metrics"}),c.jsx(Jn,{element:c.jsx(fve,{}),path:"/email/settings"}),c.jsx(Jn,{element:c.jsx(vve,{}),path:"/sms"}),c.jsx(Jn,{element:c.jsx(pve,{}),path:"/sms/:id"}),c.jsx(Jn,{element:c.jsx(gve,{}),path:"/sms/metrics"}),c.jsx(Jn,{element:c.jsx(Sve,{}),path:"/sms/settings"}),c.jsx(Jn,{element:c.jsx(Oge,{}),path:"/cdn"}),c.jsx(Jn,{element:c.jsx(Tge,{}),path:"/cdn/metrics"}),c.jsx(Jn,{element:c.jsx($ge,{}),path:"/cdn/settings"})]}):c.jsx("div",{className:"flex items-center justify-center p-8",children:c.jsx("div",{className:"text-muted-foreground",children:"Loading..."})})})]})]})}function Wge(){return c.jsx(Ige,{defaultTheme:"system",storageKey:"console-ui-theme",children:c.jsxs(QH,{children:[c.jsx(Yge,{}),c.jsx(Vge,{})]})})}CU.createRoot(document.getElementById("root")).render(c.jsx(w.StrictMode,{children:c.jsx(Wge,{})}));