mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-03-11 10:03:51 +00:00
814 lines
1.5 MiB
814 lines
1.5 MiB
var yW=Object.defineProperty;var ER=e=>{throw TypeError(e)};var bW=(e,t,n)=>t in e?yW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var lf=(e,t,n)=>bW(e,typeof t!="symbol"?t+"":t,n),OR=(e,t,n)=>t.has(e)||ER("Cannot "+n);var Kh=(e,t,n)=>(OR(e,t,"read from private field"),n?n.call(e):t.get(e)),Zh=(e,t,n)=>t.has(e)?ER("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Xh=(e,t,n,r)=>(OR(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n);function wW(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 a=Object.getOwnPropertyDescriptor(r,i);a&&Object.defineProperty(e,i,a.get?a:{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 a of i)if(a.type==="childList")for(const o of a.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function r(i){if(i.ep)return;i.ep=!0;const a=n(i);fetch(i.href,a)}})();var qv=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function zt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var L_={exports:{}},Qh={};/**
|
||
* @license React
|
||
* react-jsx-runtime.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var TR;function _W(){if(TR)return Qh;TR=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,a){var o=null;if(a!==void 0&&(o=""+a),i.key!==void 0&&(o=""+i.key),"key"in i){a={};for(var l in i)l!=="key"&&(a[l]=i[l])}else a=i;return i=a.ref,{$$typeof:e,type:r,key:o,ref:i!==void 0?i:null,props:a}}return Qh.Fragment=t,Qh.jsx=n,Qh.jsxs=n,Qh}var jR;function xW(){return jR||(jR=1,L_.exports=_W()),L_.exports}var v=xW(),k_={exports:{}},Jh={},D_={exports:{}},I_={};/**
|
||
* @license React
|
||
* scheduler.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var PR;function SW(){return PR||(PR=1,function(e){function t(H,I){var D=H.length;H.push(I);e:for(;0<D;){var z=D-1>>>1,N=H[z];if(0<i(N,I))H[z]=I,H[D]=N,D=z;else break e}}function n(H){return H.length===0?null:H[0]}function r(H){if(H.length===0)return null;var I=H[0],D=H.pop();if(D!==I){H[0]=D;e:for(var z=0,N=H.length,B=N>>>1;z<B;){var Q=2*(z+1)-1,G=H[Q],ae=Q+1,fe=H[ae];if(0>i(G,D))ae<N&&0>i(fe,G)?(H[z]=fe,H[ae]=D,z=ae):(H[z]=G,H[Q]=D,z=Q);else if(ae<N&&0>i(fe,D))H[z]=fe,H[ae]=D,z=ae;else break e}}return I}function i(H,I){var D=H.sortIndex-I.sortIndex;return D!==0?D:H.id-I.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,l=o.now();e.unstable_now=function(){return o.now()-l}}var f=[],u=[],h=1,m=null,g=3,_=!1,x=!1,b=!1,S=!1,C=typeof setTimeout=="function"?setTimeout:null,A=typeof clearTimeout=="function"?clearTimeout:null,O=typeof setImmediate<"u"?setImmediate:null;function P(H){for(var I=n(u);I!==null;){if(I.callback===null)r(u);else if(I.startTime<=H)r(u),I.sortIndex=I.expirationTime,t(f,I);else break;I=n(u)}}function j(H){if(b=!1,P(H),!x)if(n(f)!==null)x=!0,R||(R=!0,ee());else{var I=n(u);I!==null&&ne(j,I.startTime-H)}}var R=!1,U=-1,V=5,Y=-1;function K(){return S?!0:!(e.unstable_now()-Y<V)}function W(){if(S=!1,R){var H=e.unstable_now();Y=H;var I=!0;try{e:{x=!1,b&&(b=!1,A(U),U=-1),_=!0;var D=g;try{t:{for(P(H),m=n(f);m!==null&&!(m.expirationTime>H&&K());){var z=m.callback;if(typeof z=="function"){m.callback=null,g=m.priorityLevel;var N=z(m.expirationTime<=H);if(H=e.unstable_now(),typeof N=="function"){m.callback=N,P(H),I=!0;break t}m===n(f)&&r(f),P(H)}else r(f);m=n(f)}if(m!==null)I=!0;else{var B=n(u);B!==null&&ne(j,B.startTime-H),I=!1}}break e}finally{m=null,g=D,_=!1}I=void 0}}finally{I?ee():R=!1}}}var ee;if(typeof O=="function")ee=function(){O(W)};else if(typeof MessageChannel<"u"){var ie=new MessageChannel,X=ie.port2;ie.port1.onmessage=W,ee=function(){X.postMessage(null)}}else ee=function(){C(W,0)};function ne(H,I){U=C(function(){H(e.unstable_now())},I)}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(H){H.callback=null},e.unstable_forceFrameRate=function(H){0>H||125<H?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):V=0<H?Math.floor(1e3/H):5},e.unstable_getCurrentPriorityLevel=function(){return g},e.unstable_next=function(H){switch(g){case 1:case 2:case 3:var I=3;break;default:I=g}var D=g;g=I;try{return H()}finally{g=D}},e.unstable_requestPaint=function(){S=!0},e.unstable_runWithPriority=function(H,I){switch(H){case 1:case 2:case 3:case 4:case 5:break;default:H=3}var D=g;g=H;try{return I()}finally{g=D}},e.unstable_scheduleCallback=function(H,I,D){var z=e.unstable_now();switch(typeof D=="object"&&D!==null?(D=D.delay,D=typeof D=="number"&&0<D?z+D:z):D=z,H){case 1:var N=-1;break;case 2:N=250;break;case 5:N=1073741823;break;case 4:N=1e4;break;default:N=5e3}return N=D+N,H={id:h++,callback:I,priorityLevel:H,startTime:D,expirationTime:N,sortIndex:-1},D>z?(H.sortIndex=D,t(u,H),n(f)===null&&H===n(u)&&(b?(A(U),U=-1):b=!0,ne(j,D-z))):(H.sortIndex=N,t(f,H),x||_||(x=!0,R||(R=!0,ee()))),H},e.unstable_shouldYield=K,e.unstable_wrapCallback=function(H){var I=g;return function(){var D=g;g=I;try{return H.apply(this,arguments)}finally{g=D}}}}(I_)),I_}var RR;function CW(){return RR||(RR=1,D_.exports=SW()),D_.exports}var $_={exports:{}},Ct={};/**
|
||
* @license React
|
||
* react.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var MR;function AW(){if(MR)return Ct;MR=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"),a=Symbol.for("react.consumer"),o=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),m=Symbol.iterator;function g(N){return N===null||typeof N!="object"?null:(N=m&&N[m]||N["@@iterator"],typeof N=="function"?N:null)}var _={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,b={};function S(N,B,Q){this.props=N,this.context=B,this.refs=b,this.updater=Q||_}S.prototype.isReactComponent={},S.prototype.setState=function(N,B){if(typeof N!="object"&&typeof N!="function"&&N!=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,N,B,"setState")},S.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function C(){}C.prototype=S.prototype;function A(N,B,Q){this.props=N,this.context=B,this.refs=b,this.updater=Q||_}var O=A.prototype=new C;O.constructor=A,x(O,S.prototype),O.isPureReactComponent=!0;var P=Array.isArray,j={H:null,A:null,T:null,S:null,V:null},R=Object.prototype.hasOwnProperty;function U(N,B,Q,G,ae,fe){return Q=fe.ref,{$$typeof:e,type:N,key:B,ref:Q!==void 0?Q:null,props:fe}}function V(N,B){return U(N.type,B,void 0,void 0,void 0,N.props)}function Y(N){return typeof N=="object"&&N!==null&&N.$$typeof===e}function K(N){var B={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(Q){return B[Q]})}var W=/\/+/g;function ee(N,B){return typeof N=="object"&&N!==null&&N.key!=null?K(""+N.key):B.toString(36)}function ie(){}function X(N){switch(N.status){case"fulfilled":return N.value;case"rejected":throw N.reason;default:switch(typeof N.status=="string"?N.then(ie,ie):(N.status="pending",N.then(function(B){N.status==="pending"&&(N.status="fulfilled",N.value=B)},function(B){N.status==="pending"&&(N.status="rejected",N.reason=B)})),N.status){case"fulfilled":return N.value;case"rejected":throw N.reason}}throw N}function ne(N,B,Q,G,ae){var fe=typeof N;(fe==="undefined"||fe==="boolean")&&(N=null);var ce=!1;if(N===null)ce=!0;else switch(fe){case"bigint":case"string":case"number":ce=!0;break;case"object":switch(N.$$typeof){case e:case t:ce=!0;break;case h:return ce=N._init,ne(ce(N._payload),B,Q,G,ae)}}if(ce)return ae=ae(N),ce=G===""?"."+ee(N,0):G,P(ae)?(Q="",ce!=null&&(Q=ce.replace(W,"$&/")+"/"),ne(ae,B,Q,"",function(q){return q})):ae!=null&&(Y(ae)&&(ae=V(ae,Q+(ae.key==null||N&&N.key===ae.key?"":(""+ae.key).replace(W,"$&/")+"/")+ce)),B.push(ae)),1;ce=0;var ye=G===""?".":G+":";if(P(N))for(var F=0;F<N.length;F++)G=N[F],fe=ye+ee(G,F),ce+=ne(G,B,Q,fe,ae);else if(F=g(N),typeof F=="function")for(N=F.call(N),F=0;!(G=N.next()).done;)G=G.value,fe=ye+ee(G,F++),ce+=ne(G,B,Q,fe,ae);else if(fe==="object"){if(typeof N.then=="function")return ne(X(N),B,Q,G,ae);throw B=String(N),Error("Objects are not valid as a React child (found: "+(B==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":B)+"). If you meant to render a collection of children, use an array instead.")}return ce}function H(N,B,Q){if(N==null)return N;var G=[],ae=0;return ne(N,G,"","",function(fe){return B.call(Q,fe,ae++)}),G}function I(N){if(N._status===-1){var B=N._result;B=B(),B.then(function(Q){(N._status===0||N._status===-1)&&(N._status=1,N._result=Q)},function(Q){(N._status===0||N._status===-1)&&(N._status=2,N._result=Q)}),N._status===-1&&(N._status=0,N._result=B)}if(N._status===1)return N._result.default;throw N._result}var D=typeof reportError=="function"?reportError:function(N){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var B=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof N=="object"&&N!==null&&typeof N.message=="string"?String(N.message):String(N),error:N});if(!window.dispatchEvent(B))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",N);return}console.error(N)};function z(){}return Ct.Children={map:H,forEach:function(N,B,Q){H(N,function(){B.apply(this,arguments)},Q)},count:function(N){var B=0;return H(N,function(){B++}),B},toArray:function(N){return H(N,function(B){return B})||[]},only:function(N){if(!Y(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},Ct.Component=S,Ct.Fragment=n,Ct.Profiler=i,Ct.PureComponent=A,Ct.StrictMode=r,Ct.Suspense=f,Ct.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=j,Ct.__COMPILER_RUNTIME={__proto__:null,c:function(N){return j.H.useMemoCache(N)}},Ct.cache=function(N){return function(){return N.apply(null,arguments)}},Ct.cloneElement=function(N,B,Q){if(N==null)throw Error("The argument must be a React element, but you passed "+N+".");var G=x({},N.props),ae=N.key,fe=void 0;if(B!=null)for(ce in B.ref!==void 0&&(fe=void 0),B.key!==void 0&&(ae=""+B.key),B)!R.call(B,ce)||ce==="key"||ce==="__self"||ce==="__source"||ce==="ref"&&B.ref===void 0||(G[ce]=B[ce]);var ce=arguments.length-2;if(ce===1)G.children=Q;else if(1<ce){for(var ye=Array(ce),F=0;F<ce;F++)ye[F]=arguments[F+2];G.children=ye}return U(N.type,ae,void 0,void 0,fe,G)},Ct.createContext=function(N){return N={$$typeof:o,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null},N.Provider=N,N.Consumer={$$typeof:a,_context:N},N},Ct.createElement=function(N,B,Q){var G,ae={},fe=null;if(B!=null)for(G in B.key!==void 0&&(fe=""+B.key),B)R.call(B,G)&&G!=="key"&&G!=="__self"&&G!=="__source"&&(ae[G]=B[G]);var ce=arguments.length-2;if(ce===1)ae.children=Q;else if(1<ce){for(var ye=Array(ce),F=0;F<ce;F++)ye[F]=arguments[F+2];ae.children=ye}if(N&&N.defaultProps)for(G in ce=N.defaultProps,ce)ae[G]===void 0&&(ae[G]=ce[G]);return U(N,fe,void 0,void 0,null,ae)},Ct.createRef=function(){return{current:null}},Ct.forwardRef=function(N){return{$$typeof:l,render:N}},Ct.isValidElement=Y,Ct.lazy=function(N){return{$$typeof:h,_payload:{_status:-1,_result:N},_init:I}},Ct.memo=function(N,B){return{$$typeof:u,type:N,compare:B===void 0?null:B}},Ct.startTransition=function(N){var B=j.T,Q={};j.T=Q;try{var G=N(),ae=j.S;ae!==null&&ae(Q,G),typeof G=="object"&&G!==null&&typeof G.then=="function"&&G.then(z,D)}catch(fe){D(fe)}finally{j.T=B}},Ct.unstable_useCacheRefresh=function(){return j.H.useCacheRefresh()},Ct.use=function(N){return j.H.use(N)},Ct.useActionState=function(N,B,Q){return j.H.useActionState(N,B,Q)},Ct.useCallback=function(N,B){return j.H.useCallback(N,B)},Ct.useContext=function(N){return j.H.useContext(N)},Ct.useDebugValue=function(){},Ct.useDeferredValue=function(N,B){return j.H.useDeferredValue(N,B)},Ct.useEffect=function(N,B,Q){var G=j.H;if(typeof Q=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return G.useEffect(N,B)},Ct.useId=function(){return j.H.useId()},Ct.useImperativeHandle=function(N,B,Q){return j.H.useImperativeHandle(N,B,Q)},Ct.useInsertionEffect=function(N,B){return j.H.useInsertionEffect(N,B)},Ct.useLayoutEffect=function(N,B){return j.H.useLayoutEffect(N,B)},Ct.useMemo=function(N,B){return j.H.useMemo(N,B)},Ct.useOptimistic=function(N,B){return j.H.useOptimistic(N,B)},Ct.useReducer=function(N,B,Q){return j.H.useReducer(N,B,Q)},Ct.useRef=function(N){return j.H.useRef(N)},Ct.useState=function(N){return j.H.useState(N)},Ct.useSyncExternalStore=function(N,B,Q){return j.H.useSyncExternalStore(N,B,Q)},Ct.useTransition=function(){return j.H.useTransition()},Ct.version="19.1.0",Ct}var NR;function wb(){return NR||(NR=1,$_.exports=AW()),$_.exports}var B_={exports:{}},Tr={};/**
|
||
* @license React
|
||
* react-dom.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var LR;function EW(){if(LR)return Tr;LR=1;var e=wb();function t(f){var u="https://react.dev/errors/"+f;if(1<arguments.length){u+="?args[]="+encodeURIComponent(arguments[1]);for(var h=2;h<arguments.length;h++)u+="&args[]="+encodeURIComponent(arguments[h])}return"Minified React error #"+f+"; visit "+u+" 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 a(f,u,h){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:i,key:m==null?null:""+m,children:f,containerInfo:u,implementation:h}}var o=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function l(f,u){if(f==="font")return"";if(typeof u=="string")return u==="use-credentials"?u:""}return Tr.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,Tr.createPortal=function(f,u){var h=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!u||u.nodeType!==1&&u.nodeType!==9&&u.nodeType!==11)throw Error(t(299));return a(f,u,null,h)},Tr.flushSync=function(f){var u=o.T,h=r.p;try{if(o.T=null,r.p=2,f)return f()}finally{o.T=u,r.p=h,r.d.f()}},Tr.preconnect=function(f,u){typeof f=="string"&&(u?(u=u.crossOrigin,u=typeof u=="string"?u==="use-credentials"?u:"":void 0):u=null,r.d.C(f,u))},Tr.prefetchDNS=function(f){typeof f=="string"&&r.d.D(f)},Tr.preinit=function(f,u){if(typeof f=="string"&&u&&typeof u.as=="string"){var h=u.as,m=l(h,u.crossOrigin),g=typeof u.integrity=="string"?u.integrity:void 0,_=typeof u.fetchPriority=="string"?u.fetchPriority:void 0;h==="style"?r.d.S(f,typeof u.precedence=="string"?u.precedence:void 0,{crossOrigin:m,integrity:g,fetchPriority:_}):h==="script"&&r.d.X(f,{crossOrigin:m,integrity:g,fetchPriority:_,nonce:typeof u.nonce=="string"?u.nonce:void 0})}},Tr.preinitModule=function(f,u){if(typeof f=="string")if(typeof u=="object"&&u!==null){if(u.as==null||u.as==="script"){var h=l(u.as,u.crossOrigin);r.d.M(f,{crossOrigin:h,integrity:typeof u.integrity=="string"?u.integrity:void 0,nonce:typeof u.nonce=="string"?u.nonce:void 0})}}else u==null&&r.d.M(f)},Tr.preload=function(f,u){if(typeof f=="string"&&typeof u=="object"&&u!==null&&typeof u.as=="string"){var h=u.as,m=l(h,u.crossOrigin);r.d.L(f,h,{crossOrigin:m,integrity:typeof u.integrity=="string"?u.integrity:void 0,nonce:typeof u.nonce=="string"?u.nonce:void 0,type:typeof u.type=="string"?u.type:void 0,fetchPriority:typeof u.fetchPriority=="string"?u.fetchPriority:void 0,referrerPolicy:typeof u.referrerPolicy=="string"?u.referrerPolicy:void 0,imageSrcSet:typeof u.imageSrcSet=="string"?u.imageSrcSet:void 0,imageSizes:typeof u.imageSizes=="string"?u.imageSizes:void 0,media:typeof u.media=="string"?u.media:void 0})}},Tr.preloadModule=function(f,u){if(typeof f=="string")if(u){var h=l(u.as,u.crossOrigin);r.d.m(f,{as:typeof u.as=="string"&&u.as!=="script"?u.as:void 0,crossOrigin:h,integrity:typeof u.integrity=="string"?u.integrity:void 0})}else r.d.m(f)},Tr.requestFormReset=function(f){r.d.r(f)},Tr.unstable_batchedUpdates=function(f,u){return f(u)},Tr.useFormState=function(f,u,h){return o.H.useFormState(f,u,h)},Tr.useFormStatus=function(){return o.H.useHostTransitionStatus()},Tr.version="19.1.0",Tr}var kR;function Y7(){if(kR)return B_.exports;kR=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(),B_.exports=EW(),B_.exports}/**
|
||
* @license React
|
||
* react-dom-client.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var DR;function OW(){if(DR)return Jh;DR=1;var e=CW(),t=wb(),n=Y7();function r(s){var c="https://react.dev/errors/"+s;if(1<arguments.length){c+="?args[]="+encodeURIComponent(arguments[1]);for(var p=2;p<arguments.length;p++)c+="&args[]="+encodeURIComponent(arguments[p])}return"Minified React error #"+s+"; visit "+c+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function a(s){var c=s,p=s;if(s.alternate)for(;c.return;)c=c.return;else{s=c;do c=s,(c.flags&4098)!==0&&(p=c.return),s=c.return;while(s)}return c.tag===3?p:null}function o(s){if(s.tag===13){var c=s.memoizedState;if(c===null&&(s=s.alternate,s!==null&&(c=s.memoizedState)),c!==null)return c.dehydrated}return null}function l(s){if(a(s)!==s)throw Error(r(188))}function f(s){var c=s.alternate;if(!c){if(c=a(s),c===null)throw Error(r(188));return c!==s?null:s}for(var p=s,w=c;;){var T=p.return;if(T===null)break;var k=T.alternate;if(k===null){if(w=T.return,w!==null){p=w;continue}break}if(T.child===k.child){for(k=T.child;k;){if(k===p)return l(T),s;if(k===w)return l(T),c;k=k.sibling}throw Error(r(188))}if(p.return!==w.return)p=T,w=k;else{for(var re=!1,le=T.child;le;){if(le===p){re=!0,p=T,w=k;break}if(le===w){re=!0,w=T,p=k;break}le=le.sibling}if(!re){for(le=k.child;le;){if(le===p){re=!0,p=k,w=T;break}if(le===w){re=!0,w=k,p=T;break}le=le.sibling}if(!re)throw Error(r(189))}}if(p.alternate!==w)throw Error(r(190))}if(p.tag!==3)throw Error(r(188));return p.stateNode.current===p?s:c}function u(s){var c=s.tag;if(c===5||c===26||c===27||c===6)return s;for(s=s.child;s!==null;){if(c=u(s),c!==null)return c;s=s.sibling}return null}var h=Object.assign,m=Symbol.for("react.element"),g=Symbol.for("react.transitional.element"),_=Symbol.for("react.portal"),x=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),S=Symbol.for("react.profiler"),C=Symbol.for("react.provider"),A=Symbol.for("react.consumer"),O=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),j=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),U=Symbol.for("react.memo"),V=Symbol.for("react.lazy"),Y=Symbol.for("react.activity"),K=Symbol.for("react.memo_cache_sentinel"),W=Symbol.iterator;function ee(s){return s===null||typeof s!="object"?null:(s=W&&s[W]||s["@@iterator"],typeof s=="function"?s:null)}var ie=Symbol.for("react.client.reference");function X(s){if(s==null)return null;if(typeof s=="function")return s.$$typeof===ie?null:s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case x:return"Fragment";case S:return"Profiler";case b:return"StrictMode";case j:return"Suspense";case R:return"SuspenseList";case Y:return"Activity"}if(typeof s=="object")switch(s.$$typeof){case _:return"Portal";case O:return(s.displayName||"Context")+".Provider";case A:return(s._context.displayName||"Context")+".Consumer";case P:var c=s.render;return s=s.displayName,s||(s=c.displayName||c.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case U:return c=s.displayName||null,c!==null?c:X(s.type)||"Memo";case V:c=s._payload,s=s._init;try{return X(s(c))}catch{}}return null}var ne=Array.isArray,H=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,I=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,D={pending:!1,data:null,method:null,action:null},z=[],N=-1;function B(s){return{current:s}}function Q(s){0>N||(s.current=z[N],z[N]=null,N--)}function G(s,c){N++,z[N]=s.current,s.current=c}var ae=B(null),fe=B(null),ce=B(null),ye=B(null);function F(s,c){switch(G(ce,c),G(fe,s),G(ae,null),c.nodeType){case 9:case 11:s=(s=c.documentElement)&&(s=s.namespaceURI)?eR(s):0;break;default:if(s=c.tagName,c=c.namespaceURI)c=eR(c),s=tR(c,s);else switch(s){case"svg":s=1;break;case"math":s=2;break;default:s=0}}Q(ae),G(ae,s)}function q(){Q(ae),Q(fe),Q(ce)}function te(s){s.memoizedState!==null&&G(ye,s);var c=ae.current,p=tR(c,s.type);c!==p&&(G(fe,s),G(ae,p))}function ue(s){fe.current===s&&(Q(ae),Q(fe)),ye.current===s&&(Q(ye),Vh._currentValue=D)}var J=Object.prototype.hasOwnProperty,se=e.unstable_scheduleCallback,de=e.unstable_cancelCallback,ve=e.unstable_shouldYield,he=e.unstable_requestPaint,xe=e.unstable_now,Oe=e.unstable_getCurrentPriorityLevel,Le=e.unstable_ImmediatePriority,He=e.unstable_UserBlockingPriority,$e=e.unstable_NormalPriority,ze=e.unstable_LowPriority,_e=e.unstable_IdlePriority,Se=e.log,ke=e.unstable_setDisableYieldValue,Ne=null,je=null;function Fe(s){if(typeof Se=="function"&&ke(s),je&&typeof je.setStrictMode=="function")try{je.setStrictMode(Ne,s)}catch{}}var Ge=Math.clz32?Math.clz32:st,Xe=Math.log,ft=Math.LN2;function st(s){return s>>>=0,s===0?32:31-(Xe(s)/ft|0)|0}var wt=256,kt=4194304;function Dt(s){var c=s&42;if(c!==0)return c;switch(s&-s){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:case 262144:case 524288:case 1048576:case 2097152:return s&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return s&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return s}}function It(s,c,p){var w=s.pendingLanes;if(w===0)return 0;var T=0,k=s.suspendedLanes,re=s.pingedLanes;s=s.warmLanes;var le=w&134217727;return le!==0?(w=le&~k,w!==0?T=Dt(w):(re&=le,re!==0?T=Dt(re):p||(p=le&~s,p!==0&&(T=Dt(p))))):(le=w&~k,le!==0?T=Dt(le):re!==0?T=Dt(re):p||(p=w&~s,p!==0&&(T=Dt(p)))),T===0?0:c!==0&&c!==T&&(c&k)===0&&(k=T&-T,p=c&-c,k>=p||k===32&&(p&4194048)!==0)?c:T}function Cr(s,c){return(s.pendingLanes&~(s.suspendedLanes&~s.pingedLanes)&c)===0}function Vn(s,c){switch(s){case 1:case 2:case 4:case 8:case 64:return c+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 c+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 ys(){var s=wt;return wt<<=1,(wt&4194048)===0&&(wt=256),s}function ii(){var s=kt;return kt<<=1,(kt&62914560)===0&&(kt=4194304),s}function bs(s){for(var c=[],p=0;31>p;p++)c.push(s);return c}function La(s,c){s.pendingLanes|=c,c!==268435456&&(s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0)}function bc(s,c,p,w,T,k){var re=s.pendingLanes;s.pendingLanes=p,s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0,s.expiredLanes&=p,s.entangledLanes&=p,s.errorRecoveryDisabledLanes&=p,s.shellSuspendCounter=0;var le=s.entanglements,ge=s.expirationTimes,Te=s.hiddenUpdates;for(p=re&~p;0<p;){var Ie=31-Ge(p),Ue=1<<Ie;le[Ie]=0,ge[Ie]=-1;var Pe=Te[Ie];if(Pe!==null)for(Te[Ie]=null,Ie=0;Ie<Pe.length;Ie++){var Re=Pe[Ie];Re!==null&&(Re.lane&=-536870913)}p&=~Ue}w!==0&&ws(s,w,0),k!==0&&T===0&&s.tag!==0&&(s.suspendedLanes|=k&~(re&~c))}function ws(s,c,p){s.pendingLanes|=c,s.suspendedLanes&=~c;var w=31-Ge(c);s.entangledLanes|=c,s.entanglements[w]=s.entanglements[w]|1073741824|p&4194090}function ka(s,c){var p=s.entangledLanes|=c;for(s=s.entanglements;p;){var w=31-Ge(p),T=1<<w;T&c|s[w]&c&&(s[w]|=c),p&=~T}}function mn(s){switch(s){case 2:s=1;break;case 8:s=4;break;case 32:s=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:s=128;break;case 268435456:s=134217728;break;default:s=0}return s}function fn(s){return s&=-s,2<s?8<s?(s&134217727)!==0?32:268435456:8:2}function Jn(){var s=I.p;return s!==0?s:(s=window.event,s===void 0?32:wR(s.type))}function Hn(s,c){var p=I.p;try{return I.p=s,c()}finally{I.p=p}}var en=Math.random().toString(36).slice(2),Mt="__reactFiber$"+en,tn="__reactProps$"+en,er="__reactContainer$"+en,Mn="__reactEvents$"+en,lt="__reactListeners$"+en,Sg="__reactHandles$"+en,Qd="__reactResources$"+en,_s="__reactMarker$"+en;function wc(s){delete s[Mt],delete s[tn],delete s[Mn],delete s[lt],delete s[Sg]}function Da(s){var c=s[Mt];if(c)return c;for(var p=s.parentNode;p;){if(c=p[er]||p[Mt]){if(p=c.alternate,c.child!==null||p!==null&&p.child!==null)for(s=aR(s);s!==null;){if(p=s[Mt])return p;s=aR(s)}return c}s=p,p=s.parentNode}return null}function yo(s){if(s=s[Mt]||s[er]){var c=s.tag;if(c===5||c===6||c===13||c===26||c===27||c===3)return s}return null}function Ii(s){var c=s.tag;if(c===5||c===26||c===27||c===6)return s.stateNode;throw Error(r(33))}function bo(s){var c=s[Qd];return c||(c=s[Qd]={hoistableStyles:new Map,hoistableScripts:new Map}),c}function In(s){s[_s]=!0}var Cg=new Set,Ag={};function wo(s,c){_o(s,c),_o(s+"Capture",c)}function _o(s,c){for(Ag[s]=c,s=0;s<c.length;s++)Cg.add(c[s])}var V1=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]*$"),Jl={},Eg={};function H1(s){return J.call(Eg,s)?!0:J.call(Jl,s)?!1:V1.test(s)?Eg[s]=!0:(Jl[s]=!0,!1)}function _c(s,c,p){if(H1(c))if(p===null)s.removeAttribute(c);else{switch(typeof p){case"undefined":case"function":case"symbol":s.removeAttribute(c);return;case"boolean":var w=c.toLowerCase().slice(0,5);if(w!=="data-"&&w!=="aria-"){s.removeAttribute(c);return}}s.setAttribute(c,""+p)}}function xc(s,c,p){if(p===null)s.removeAttribute(c);else{switch(typeof p){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(c);return}s.setAttribute(c,""+p)}}function aa(s,c,p,w){if(w===null)s.removeAttribute(p);else{switch(typeof w){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(p);return}s.setAttributeNS(c,p,""+w)}}var eu,xs;function xo(s){if(eu===void 0)try{throw Error()}catch(p){var c=p.stack.trim().match(/\n( *(at )?)/);eu=c&&c[1]||"",xs=-1<p.stack.indexOf(`
|
||
at`)?" (<anonymous>)":-1<p.stack.indexOf("@")?"@unknown:0:0":""}return`
|
||
`+eu+s+xs}var Sc=!1;function So(s,c){if(!s||Sc)return"";Sc=!0;var p=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var w={DetermineComponentFrameRoot:function(){try{if(c){var Ue=function(){throw Error()};if(Object.defineProperty(Ue.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Ue,[])}catch(Re){var Pe=Re}Reflect.construct(s,[],Ue)}else{try{Ue.call()}catch(Re){Pe=Re}s.call(Ue.prototype)}}else{try{throw Error()}catch(Re){Pe=Re}(Ue=s())&&typeof Ue.catch=="function"&&Ue.catch(function(){})}}catch(Re){if(Re&&Pe&&typeof Re.stack=="string")return[Re.stack,Pe.stack]}return[null,null]}};w.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var T=Object.getOwnPropertyDescriptor(w.DetermineComponentFrameRoot,"name");T&&T.configurable&&Object.defineProperty(w.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var k=w.DetermineComponentFrameRoot(),re=k[0],le=k[1];if(re&&le){var ge=re.split(`
|
||
`),Te=le.split(`
|
||
`);for(T=w=0;w<ge.length&&!ge[w].includes("DetermineComponentFrameRoot");)w++;for(;T<Te.length&&!Te[T].includes("DetermineComponentFrameRoot");)T++;if(w===ge.length||T===Te.length)for(w=ge.length-1,T=Te.length-1;1<=w&&0<=T&&ge[w]!==Te[T];)T--;for(;1<=w&&0<=T;w--,T--)if(ge[w]!==Te[T]){if(w!==1||T!==1)do if(w--,T--,0>T||ge[w]!==Te[T]){var Ie=`
|
||
`+ge[w].replace(" at new "," at ");return s.displayName&&Ie.includes("<anonymous>")&&(Ie=Ie.replace("<anonymous>",s.displayName)),Ie}while(1<=w&&0<=T);break}}}finally{Sc=!1,Error.prepareStackTrace=p}return(p=s?s.displayName||s.name:"")?xo(p):""}function Nt(s){switch(s.tag){case 26:case 27:case 5:return xo(s.type);case 16:return xo("Lazy");case 13:return xo("Suspense");case 19:return xo("SuspenseList");case 0:case 15:return So(s.type,!1);case 11:return So(s.type.render,!1);case 1:return So(s.type,!0);case 31:return xo("Activity");default:return""}}function nn(s){try{var c="";do c+=Nt(s),s=s.return;while(s);return c}catch(p){return`
|
||
Error generating stack: `+p.message+`
|
||
`+p.stack}}function fr(s){switch(typeof s){case"bigint":case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function Co(s){var c=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(c==="checkbox"||c==="radio")}function Ss(s){var c=Co(s)?"checked":"value",p=Object.getOwnPropertyDescriptor(s.constructor.prototype,c),w=""+s[c];if(!s.hasOwnProperty(c)&&typeof p<"u"&&typeof p.get=="function"&&typeof p.set=="function"){var T=p.get,k=p.set;return Object.defineProperty(s,c,{configurable:!0,get:function(){return T.call(this)},set:function(re){w=""+re,k.call(this,re)}}),Object.defineProperty(s,c,{enumerable:p.enumerable}),{getValue:function(){return w},setValue:function(re){w=""+re},stopTracking:function(){s._valueTracker=null,delete s[c]}}}}function Cs(s){s._valueTracker||(s._valueTracker=Ss(s))}function _t(s){if(!s)return!1;var c=s._valueTracker;if(!c)return!0;var p=c.getValue(),w="";return s&&(w=Co(s)?s.checked?"true":"false":s.value),s=w,s!==p?(c.setValue(s),!0):!1}function rn(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}var Jd=/[\n"\\]/g;function dr(s){return s.replace(Jd,function(c){return"\\"+c.charCodeAt(0).toString(16)+" "})}function Ar(s,c,p,w,T,k,re,le){s.name="",re!=null&&typeof re!="function"&&typeof re!="symbol"&&typeof re!="boolean"?s.type=re:s.removeAttribute("type"),c!=null?re==="number"?(c===0&&s.value===""||s.value!=c)&&(s.value=""+fr(c)):s.value!==""+fr(c)&&(s.value=""+fr(c)):re!=="submit"&&re!=="reset"||s.removeAttribute("value"),c!=null?As(s,re,fr(c)):p!=null?As(s,re,fr(p)):w!=null&&s.removeAttribute("value"),T==null&&k!=null&&(s.defaultChecked=!!k),T!=null&&(s.checked=T&&typeof T!="function"&&typeof T!="symbol"),le!=null&&typeof le!="function"&&typeof le!="symbol"&&typeof le!="boolean"?s.name=""+fr(le):s.removeAttribute("name")}function Og(s,c,p,w,T,k,re,le){if(k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"&&(s.type=k),c!=null||p!=null){if(!(k!=="submit"&&k!=="reset"||c!=null))return;p=p!=null?""+fr(p):"",c=c!=null?""+fr(c):p,le||c===s.value||(s.value=c),s.defaultValue=c}w=w??T,w=typeof w!="function"&&typeof w!="symbol"&&!!w,s.checked=le?s.checked:!!w,s.defaultChecked=!!w,re!=null&&typeof re!="function"&&typeof re!="symbol"&&typeof re!="boolean"&&(s.name=re)}function As(s,c,p){c==="number"&&rn(s.ownerDocument)===s||s.defaultValue===""+p||(s.defaultValue=""+p)}function Zr(s,c,p,w){if(s=s.options,c){c={};for(var T=0;T<p.length;T++)c["$"+p[T]]=!0;for(p=0;p<s.length;p++)T=c.hasOwnProperty("$"+s[p].value),s[p].selected!==T&&(s[p].selected=T),T&&w&&(s[p].defaultSelected=!0)}else{for(p=""+fr(p),c=null,T=0;T<s.length;T++){if(s[T].value===p){s[T].selected=!0,w&&(s[T].defaultSelected=!0);return}c!==null||s[T].disabled||(c=s[T])}c!==null&&(c.selected=!0)}}function _n(s,c,p){if(c!=null&&(c=""+fr(c),c!==s.value&&(s.value=c),p==null)){s.defaultValue!==c&&(s.defaultValue=c);return}s.defaultValue=p!=null?""+fr(p):""}function Ia(s,c,p,w){if(c==null){if(w!=null){if(p!=null)throw Error(r(92));if(ne(w)){if(1<w.length)throw Error(r(93));w=w[0]}p=w}p==null&&(p=""),c=p}p=fr(c),s.defaultValue=p,w=s.textContent,w===p&&w!==""&&w!==null&&(s.value=w)}function $i(s,c){if(c){var p=s.firstChild;if(p&&p===s.lastChild&&p.nodeType===3){p.nodeValue=c;return}}s.textContent=c}var tu=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 Cc(s,c,p){var w=c.indexOf("--")===0;p==null||typeof p=="boolean"||p===""?w?s.setProperty(c,""):c==="float"?s.cssFloat="":s[c]="":w?s.setProperty(c,p):typeof p!="number"||p===0||tu.has(c)?c==="float"?s.cssFloat=p:s[c]=(""+p).trim():s[c]=p+"px"}function Es(s,c,p){if(c!=null&&typeof c!="object")throw Error(r(62));if(s=s.style,p!=null){for(var w in p)!p.hasOwnProperty(w)||c!=null&&c.hasOwnProperty(w)||(w.indexOf("--")===0?s.setProperty(w,""):w==="float"?s.cssFloat="":s[w]="");for(var T in c)w=c[T],c.hasOwnProperty(T)&&p[T]!==w&&Cc(s,T,w)}else for(var k in c)c.hasOwnProperty(k)&&Cc(s,k,c[k])}function nu(s){if(s.indexOf("-")===-1)return!1;switch(s){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 eh=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"]]),Ac=/^[\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 Os(s){return Ac.test(""+s)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":s}var ru=null;function Ts(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var Ao=null,$a=null;function Tg(s){var c=yo(s);if(c&&(s=c.stateNode)){var p=s[tn]||null;e:switch(s=c.stateNode,c.type){case"input":if(Ar(s,p.value,p.defaultValue,p.defaultValue,p.checked,p.defaultChecked,p.type,p.name),c=p.name,p.type==="radio"&&c!=null){for(p=s;p.parentNode;)p=p.parentNode;for(p=p.querySelectorAll('input[name="'+dr(""+c)+'"][type="radio"]'),c=0;c<p.length;c++){var w=p[c];if(w!==s&&w.form===s.form){var T=w[tn]||null;if(!T)throw Error(r(90));Ar(w,T.value,T.defaultValue,T.defaultValue,T.checked,T.defaultChecked,T.type,T.name)}}for(c=0;c<p.length;c++)w=p[c],w.form===s.form&&_t(w)}break e;case"textarea":_n(s,p.value,p.defaultValue);break e;case"select":c=p.value,c!=null&&Zr(s,!!p.multiple,c,!1)}}}var bt=!1;function ai(s,c,p){if(bt)return s(c,p);bt=!0;try{var w=s(c);return w}finally{if(bt=!1,(Ao!==null||$a!==null)&&(xv(),Ao&&(c=Ao,s=$a,$a=Ao=null,Tg(c),s)))for(c=0;c<s.length;c++)Tg(s[c])}}function $t(s,c){var p=s.stateNode;if(p===null)return null;var w=p[tn]||null;if(w===null)return null;p=w[c];e:switch(c){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(w=!w.disabled)||(s=s.type,w=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!w;break e;default:s=!1}if(s)return null;if(p&&typeof p!="function")throw Error(r(231,c,typeof p));return p}var Bi=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),iu=!1;if(Bi)try{var Eo={};Object.defineProperty(Eo,"passive",{get:function(){iu=!0}}),window.addEventListener("test",Eo,Eo),window.removeEventListener("test",Eo,Eo)}catch{iu=!1}var Ui=null,oa=null,js=null;function Ps(){if(js)return js;var s,c=oa,p=c.length,w,T="value"in Ui?Ui.value:Ui.textContent,k=T.length;for(s=0;s<p&&c[s]===T[s];s++);var re=p-s;for(w=1;w<=re&&c[p-w]===T[k-w];w++);return js=T.slice(s,1<w?1-w:void 0)}function An(s){var c=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&c===13&&(s=13)):s=c,s===10&&(s=13),32<=s||s===13?s:0}function zi(){return!0}function th(){return!1}function hr(s){function c(p,w,T,k,re){this._reactName=p,this._targetInst=T,this.type=w,this.nativeEvent=k,this.target=re,this.currentTarget=null;for(var le in s)s.hasOwnProperty(le)&&(p=s[le],this[le]=p?p(k):k[le]);return this.isDefaultPrevented=(k.defaultPrevented!=null?k.defaultPrevented:k.returnValue===!1)?zi:th,this.isPropagationStopped=th,this}return h(c.prototype,{preventDefault:function(){this.defaultPrevented=!0;var p=this.nativeEvent;p&&(p.preventDefault?p.preventDefault():typeof p.returnValue!="unknown"&&(p.returnValue=!1),this.isDefaultPrevented=zi)},stopPropagation:function(){var p=this.nativeEvent;p&&(p.stopPropagation?p.stopPropagation():typeof p.cancelBubble!="unknown"&&(p.cancelBubble=!0),this.isPropagationStopped=zi)},persist:function(){},isPersistent:zi}),c}var Oo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},au=hr(Oo),To=h({},Oo,{view:0,detail:0}),G1=hr(To),Ec,Et,ou,Er=h({},To,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Oc,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==ou&&(ou&&s.type==="mousemove"?(Ec=s.screenX-ou.screenX,Et=s.screenY-ou.screenY):Et=Ec=0,ou=s),Ec)},movementY:function(s){return"movementY"in s?s.movementY:Et}}),Rs=hr(Er),jg=h({},Er,{dataTransfer:0}),W1=hr(jg),nh=h({},To,{relatedTarget:0}),rh=hr(nh),Pg=h({},Oo,{animationName:0,elapsedTime:0,pseudoElement:0}),Y1=hr(Pg),K1=h({},Oo,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),ih=hr(K1),Z1=h({},Oo,{data:0}),oi=hr(Z1),X1={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Rg={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"},Ba={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Mg(s){var c=this.nativeEvent;return c.getModifierState?c.getModifierState(s):(s=Ba[s])?!!c[s]:!1}function Oc(){return Mg}var ah=h({},To,{key:function(s){if(s.key){var c=X1[s.key]||s.key;if(c!=="Unidentified")return c}return s.type==="keypress"?(s=An(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?Rg[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Oc,charCode:function(s){return s.type==="keypress"?An(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?An(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),Q1=hr(ah),Ng=h({},Er,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),oh=hr(Ng),J1=h({},To,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Oc}),ew=hr(J1),sh=h({},Oo,{propertyName:0,elapsedTime:0,pseudoElement:0}),tw=hr(sh),Lg=h({},Er,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),kg=hr(Lg),Tc=h({},Oo,{newState:0,oldState:0}),jo=hr(Tc),nw=[9,13,27,32],Po=Bi&&"CompositionEvent"in window,tr=null;Bi&&"documentMode"in document&&(tr=document.documentMode);var Dg=Bi&&"TextEvent"in window&&!tr,lh=Bi&&(!Po||tr&&8<tr&&11>=tr),Ig=" ",jc=!1;function Pc(s,c){switch(s){case"keyup":return nw.indexOf(c.keyCode)!==-1;case"keydown":return c.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function $g(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var Ms=!1;function Bg(s,c){switch(s){case"compositionend":return $g(c);case"keypress":return c.which!==32?null:(jc=!0,Ig);case"textInput":return s=c.data,s===Ig&&jc?null:s;default:return null}}function rw(s,c){if(Ms)return s==="compositionend"||!Po&&Pc(s,c)?(s=Ps(),js=oa=Ui=null,Ms=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(c.ctrlKey||c.altKey||c.metaKey)||c.ctrlKey&&c.altKey){if(c.char&&1<c.char.length)return c.char;if(c.which)return String.fromCharCode(c.which)}return null;case"compositionend":return lh&&c.locale!=="ko"?null:c.data;default:return null}}var si={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 Ro(s){var c=s&&s.nodeName&&s.nodeName.toLowerCase();return c==="input"?!!si[s.type]:c==="textarea"}function Ug(s,c,p,w){Ao?$a?$a.push(w):$a=[w]:Ao=w,c=Tv(c,"onChange"),0<c.length&&(p=new au("onChange","change",null,p,w),s.push({event:p,listeners:c}))}var Nr=null,su=null;function Ns(s){KP(s,0)}function Rc(s){var c=Ii(s);if(_t(c))return s}function Ls(s,c){if(s==="change")return c}var uh=!1;if(Bi){var ks;if(Bi){var ch="oninput"in document;if(!ch){var sa=document.createElement("div");sa.setAttribute("oninput","return;"),ch=typeof sa.oninput=="function"}ks=ch}else ks=!1;uh=ks&&(!document.documentMode||9<document.documentMode)}function lu(){Nr&&(Nr.detachEvent("onpropertychange",zg),su=Nr=null)}function zg(s){if(s.propertyName==="value"&&Rc(su)){var c=[];Ug(c,su,s,Ts(s)),ai(Ns,c)}}function fh(s,c,p){s==="focusin"?(lu(),Nr=c,su=p,Nr.attachEvent("onpropertychange",zg)):s==="focusout"&&lu()}function iw(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return Rc(su)}function la(s,c){if(s==="click")return Rc(c)}function aw(s,c){if(s==="input"||s==="change")return Rc(c)}function Ds(s,c){return s===c&&(s!==0||1/s===1/c)||s!==s&&c!==c}var Lr=typeof Object.is=="function"?Object.is:Ds;function kr(s,c){if(Lr(s,c))return!0;if(typeof s!="object"||s===null||typeof c!="object"||c===null)return!1;var p=Object.keys(s),w=Object.keys(c);if(p.length!==w.length)return!1;for(w=0;w<p.length;w++){var T=p[w];if(!J.call(c,T)||!Lr(s[T],c[T]))return!1}return!0}function uu(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function dh(s,c){var p=uu(s);s=0;for(var w;p;){if(p.nodeType===3){if(w=s+p.textContent.length,s<=c&&w>=c)return{node:p,offset:c-s};s=w}e:{for(;p;){if(p.nextSibling){p=p.nextSibling;break e}p=p.parentNode}p=void 0}p=uu(p)}}function Mc(s,c){return s&&c?s===c?!0:s&&s.nodeType===3?!1:c&&c.nodeType===3?Mc(s,c.parentNode):"contains"in s?s.contains(c):s.compareDocumentPosition?!!(s.compareDocumentPosition(c)&16):!1:!1}function cu(s){s=s!=null&&s.ownerDocument!=null&&s.ownerDocument.defaultView!=null?s.ownerDocument.defaultView:window;for(var c=rn(s.document);c instanceof s.HTMLIFrameElement;){try{var p=typeof c.contentWindow.location.href=="string"}catch{p=!1}if(p)s=c.contentWindow;else break;c=rn(s.document)}return c}function fu(s){var c=s&&s.nodeName&&s.nodeName.toLowerCase();return c&&(c==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||c==="textarea"||s.contentEditable==="true")}var Nc=Bi&&"documentMode"in document&&11>=document.documentMode,li=null,Is=null,Mo=null,Lc=!1;function Fg(s,c,p){var w=p.window===p?p.document:p.nodeType===9?p:p.ownerDocument;Lc||li==null||li!==rn(w)||(w=li,"selectionStart"in w&&fu(w)?w={start:w.selectionStart,end:w.selectionEnd}:(w=(w.ownerDocument&&w.ownerDocument.defaultView||window).getSelection(),w={anchorNode:w.anchorNode,anchorOffset:w.anchorOffset,focusNode:w.focusNode,focusOffset:w.focusOffset}),Mo&&kr(Mo,w)||(Mo=w,w=Tv(Is,"onSelect"),0<w.length&&(c=new au("onSelect","select",null,c,p),s.push({event:c,listeners:w}),c.target=li)))}function Fi(s,c){var p={};return p[s.toLowerCase()]=c.toLowerCase(),p["Webkit"+s]="webkit"+c,p["Moz"+s]="moz"+c,p}var $s={animationend:Fi("Animation","AnimationEnd"),animationiteration:Fi("Animation","AnimationIteration"),animationstart:Fi("Animation","AnimationStart"),transitionrun:Fi("Transition","TransitionRun"),transitionstart:Fi("Transition","TransitionStart"),transitioncancel:Fi("Transition","TransitionCancel"),transitionend:Fi("Transition","TransitionEnd")},kc={},qg={};Bi&&(qg=document.createElement("div").style,"AnimationEvent"in window||(delete $s.animationend.animation,delete $s.animationiteration.animation,delete $s.animationstart.animation),"TransitionEvent"in window||delete $s.transitionend.transition);function Ua(s){if(kc[s])return kc[s];if(!$s[s])return s;var c=$s[s],p;for(p in c)if(c.hasOwnProperty(p)&&p in qg)return kc[s]=c[p];return s}var Vg=Ua("animationend"),ui=Ua("animationiteration"),du=Ua("animationstart"),ow=Ua("transitionrun"),Dc=Ua("transitionstart"),sw=Ua("transitioncancel"),hh=Ua("transitionend"),Hg=new Map,No="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(" ");No.push("scrollEnd");function ci(s,c){Hg.set(s,c),wo(c,[s])}var Lo=new WeakMap;function Dr(s,c){if(typeof s=="object"&&s!==null){var p=Lo.get(s);return p!==void 0?p:(c={value:s,source:c,stack:nn(c)},Lo.set(s,c),c)}return{value:s,source:c,stack:nn(c)}}var Ir=[],Bs=0,fi=0;function hu(){for(var s=Bs,c=fi=Bs=0;c<s;){var p=Ir[c];Ir[c++]=null;var w=Ir[c];Ir[c++]=null;var T=Ir[c];Ir[c++]=null;var k=Ir[c];if(Ir[c++]=null,w!==null&&T!==null){var re=w.pending;re===null?T.next=T:(T.next=re.next,re.next=T),w.pending=T}k!==0&&mu(p,T,k)}}function pu(s,c,p,w){Ir[Bs++]=s,Ir[Bs++]=c,Ir[Bs++]=p,Ir[Bs++]=w,fi|=w,s.lanes|=w,s=s.alternate,s!==null&&(s.lanes|=w)}function ko(s,c,p,w){return pu(s,c,p,w),za(s)}function Us(s,c){return pu(s,null,null,c),za(s)}function mu(s,c,p){s.lanes|=p;var w=s.alternate;w!==null&&(w.lanes|=p);for(var T=!1,k=s.return;k!==null;)k.childLanes|=p,w=k.alternate,w!==null&&(w.childLanes|=p),k.tag===22&&(s=k.stateNode,s===null||s._visibility&1||(T=!0)),s=k,k=k.return;return s.tag===3?(k=s.stateNode,T&&c!==null&&(T=31-Ge(p),s=k.hiddenUpdates,w=s[T],w===null?s[T]=[c]:w.push(c),c.lane=p|536870912),k):null}function za(s){if(50<Dh)throw Dh=0,i_=null,Error(r(185));for(var c=s.return;c!==null;)s=c,c=s.return;return s.tag===3?s.stateNode:null}var Do={};function Gg(s,c,p,w){this.tag=s,this.key=p,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=c,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=w,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function $r(s,c,p,w){return new Gg(s,c,p,w)}function Ic(s){return s=s.prototype,!(!s||!s.isReactComponent)}function qi(s,c){var p=s.alternate;return p===null?(p=$r(s.tag,c,s.key,s.mode),p.elementType=s.elementType,p.type=s.type,p.stateNode=s.stateNode,p.alternate=s,s.alternate=p):(p.pendingProps=c,p.type=s.type,p.flags=0,p.subtreeFlags=0,p.deletions=null),p.flags=s.flags&65011712,p.childLanes=s.childLanes,p.lanes=s.lanes,p.child=s.child,p.memoizedProps=s.memoizedProps,p.memoizedState=s.memoizedState,p.updateQueue=s.updateQueue,c=s.dependencies,p.dependencies=c===null?null:{lanes:c.lanes,firstContext:c.firstContext},p.sibling=s.sibling,p.index=s.index,p.ref=s.ref,p.refCleanup=s.refCleanup,p}function ph(s,c){s.flags&=65011714;var p=s.alternate;return p===null?(s.childLanes=0,s.lanes=c,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=p.childLanes,s.lanes=p.lanes,s.child=p.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=p.memoizedProps,s.memoizedState=p.memoizedState,s.updateQueue=p.updateQueue,s.type=p.type,c=p.dependencies,s.dependencies=c===null?null:{lanes:c.lanes,firstContext:c.firstContext}),s}function gu(s,c,p,w,T,k){var re=0;if(w=s,typeof s=="function")Ic(s)&&(re=1);else if(typeof s=="string")re=aW(s,p,ae.current)?26:s==="html"||s==="head"||s==="body"?27:5;else e:switch(s){case Y:return s=$r(31,p,c,T),s.elementType=Y,s.lanes=k,s;case x:return Fa(p.children,T,k,c);case b:re=8,T|=24;break;case S:return s=$r(12,p,c,T|2),s.elementType=S,s.lanes=k,s;case j:return s=$r(13,p,c,T),s.elementType=j,s.lanes=k,s;case R:return s=$r(19,p,c,T),s.elementType=R,s.lanes=k,s;default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case C:case O:re=10;break e;case A:re=9;break e;case P:re=11;break e;case U:re=14;break e;case V:re=16,w=null;break e}re=29,p=Error(r(130,s===null?"null":typeof s,"")),w=null}return c=$r(re,p,c,T),c.elementType=s,c.type=w,c.lanes=k,c}function Fa(s,c,p,w){return s=$r(7,s,w,c),s.lanes=p,s}function mh(s,c,p){return s=$r(6,s,null,c),s.lanes=p,s}function $c(s,c,p){return c=$r(4,s.children!==null?s.children:[],s.key,c),c.lanes=p,c.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},c}var Io=[],zs=0,d=null,y=0,E=[],$=0,Z=null,oe=1,me="";function Ae(s,c){Io[zs++]=y,Io[zs++]=d,d=s,y=c}function Me(s,c,p){E[$++]=oe,E[$++]=me,E[$++]=Z,Z=s;var w=oe;s=me;var T=32-Ge(w)-1;w&=~(1<<T),p+=1;var k=32-Ge(c)+T;if(30<k){var re=T-T%5;k=(w&(1<<re)-1).toString(32),w>>=re,T-=re,oe=1<<32-Ge(c)+T|p<<T|w,me=k+s}else oe=1<<k|p<<T|w,me=s}function qe(s){s.return!==null&&(Ae(s,1),Me(s,1,0))}function Qe(s){for(;s===d;)d=Io[--zs],Io[zs]=null,y=Io[--zs],Io[zs]=null;for(;s===Z;)Z=E[--$],E[$]=null,me=E[--$],E[$]=null,oe=E[--$],E[$]=null}var rt=null,at=null,yt=!1,an=null,xn=!1,nr=Error(r(519));function Xr(s){var c=Error(r(418,""));throw qs(Dr(c,s)),nr}function Wg(s){var c=s.stateNode,p=s.type,w=s.memoizedProps;switch(c[Mt]=s,c[tn]=w,p){case"dialog":jt("cancel",c),jt("close",c);break;case"iframe":case"object":case"embed":jt("load",c);break;case"video":case"audio":for(p=0;p<$h.length;p++)jt($h[p],c);break;case"source":jt("error",c);break;case"img":case"image":case"link":jt("error",c),jt("load",c);break;case"details":jt("toggle",c);break;case"input":jt("invalid",c),Og(c,w.value,w.defaultValue,w.checked,w.defaultChecked,w.type,w.name,!0),Cs(c);break;case"select":jt("invalid",c);break;case"textarea":jt("invalid",c),Ia(c,w.value,w.defaultValue,w.children),Cs(c)}p=w.children,typeof p!="string"&&typeof p!="number"&&typeof p!="bigint"||c.textContent===""+p||w.suppressHydrationWarning===!0||JP(c.textContent,p)?(w.popover!=null&&(jt("beforetoggle",c),jt("toggle",c)),w.onScroll!=null&&jt("scroll",c),w.onScrollEnd!=null&&jt("scrollend",c),w.onClick!=null&&(c.onclick=jv),c=!0):c=!1,c||Xr(s)}function Yg(s){for(rt=s.return;rt;)switch(rt.tag){case 5:case 13:xn=!1;return;case 27:case 3:xn=!0;return;default:rt=rt.return}}function vu(s){if(s!==rt)return!1;if(!yt)return Yg(s),yt=!0,!1;var c=s.tag,p;if((p=c!==3&&c!==27)&&((p=c===5)&&(p=s.type,p=!(p!=="form"&&p!=="button")||w_(s.type,s.memoizedProps)),p=!p),p&&at&&Xr(s),Yg(s),c===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(317));e:{for(s=s.nextSibling,c=0;s;){if(s.nodeType===8)if(p=s.data,p==="/$"){if(c===0){at=da(s.nextSibling);break e}c--}else p!=="$"&&p!=="$!"&&p!=="$?"||c++;s=s.nextSibling}at=null}}else c===27?(c=at,il(s.type)?(s=C_,C_=null,at=s):at=c):at=rt?da(s.stateNode.nextSibling):null;return!0}function Fs(){at=rt=null,yt=!1}function Kg(){var s=an;return s!==null&&(ei===null?ei=s:ei.push.apply(ei,s),an=null),s}function qs(s){an===null?an=[s]:an.push(s)}var gn=B(null),Vi=null,ua=null;function qa(s,c,p){G(gn,c._currentValue),c._currentValue=p}function ca(s){s._currentValue=gn.current,Q(gn)}function yu(s,c,p){for(;s!==null;){var w=s.alternate;if((s.childLanes&c)!==c?(s.childLanes|=c,w!==null&&(w.childLanes|=c)):w!==null&&(w.childLanes&c)!==c&&(w.childLanes|=c),s===p)break;s=s.return}}function Bc(s,c,p,w){var T=s.child;for(T!==null&&(T.return=s);T!==null;){var k=T.dependencies;if(k!==null){var re=T.child;k=k.firstContext;e:for(;k!==null;){var le=k;k=T;for(var ge=0;ge<c.length;ge++)if(le.context===c[ge]){k.lanes|=p,le=k.alternate,le!==null&&(le.lanes|=p),yu(k.return,p,s),w||(re=null);break e}k=le.next}}else if(T.tag===18){if(re=T.return,re===null)throw Error(r(341));re.lanes|=p,k=re.alternate,k!==null&&(k.lanes|=p),yu(re,p,s),re=null}else re=T.child;if(re!==null)re.return=T;else for(re=T;re!==null;){if(re===s){re=null;break}if(T=re.sibling,T!==null){T.return=re.return,re=T;break}re=re.return}T=re}}function bu(s,c,p,w){s=null;for(var T=c,k=!1;T!==null;){if(!k){if((T.flags&524288)!==0)k=!0;else if((T.flags&262144)!==0)break}if(T.tag===10){var re=T.alternate;if(re===null)throw Error(r(387));if(re=re.memoizedProps,re!==null){var le=T.type;Lr(T.pendingProps.value,re.value)||(s!==null?s.push(le):s=[le])}}else if(T===ye.current){if(re=T.alternate,re===null)throw Error(r(387));re.memoizedState.memoizedState!==T.memoizedState.memoizedState&&(s!==null?s.push(Vh):s=[Vh])}T=T.return}s!==null&&Bc(c,s,p,w),c.flags|=262144}function Zg(s){for(s=s.firstContext;s!==null;){if(!Lr(s.context._currentValue,s.memoizedValue))return!0;s=s.next}return!1}function wu(s){Vi=s,ua=null,s=s.dependencies,s!==null&&(s.firstContext=null)}function Or(s){return B4(Vi,s)}function Xg(s,c){return Vi===null&&wu(s),B4(s,c)}function B4(s,c){var p=c._currentValue;if(c={context:c,memoizedValue:p,next:null},ua===null){if(s===null)throw Error(r(308));ua=c,s.dependencies={lanes:0,firstContext:c},s.flags|=524288}else ua=ua.next=c;return p}var iG=typeof AbortController<"u"?AbortController:function(){var s=[],c=this.signal={aborted:!1,addEventListener:function(p,w){s.push(w)}};this.abort=function(){c.aborted=!0,s.forEach(function(p){return p()})}},aG=e.unstable_scheduleCallback,oG=e.unstable_NormalPriority,Gn={$$typeof:O,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function lw(){return{controller:new iG,data:new Map,refCount:0}}function gh(s){s.refCount--,s.refCount===0&&aG(oG,function(){s.controller.abort()})}var vh=null,uw=0,Uc=0,zc=null;function sG(s,c){if(vh===null){var p=vh=[];uw=0,Uc=f_(),zc={status:"pending",value:void 0,then:function(w){p.push(w)}}}return uw++,c.then(U4,U4),c}function U4(){if(--uw===0&&vh!==null){zc!==null&&(zc.status="fulfilled");var s=vh;vh=null,Uc=0,zc=null;for(var c=0;c<s.length;c++)(0,s[c])()}}function lG(s,c){var p=[],w={status:"pending",value:null,reason:null,then:function(T){p.push(T)}};return s.then(function(){w.status="fulfilled",w.value=c;for(var T=0;T<p.length;T++)(0,p[T])(c)},function(T){for(w.status="rejected",w.reason=T,T=0;T<p.length;T++)(0,p[T])(void 0)}),w}var z4=H.S;H.S=function(s,c){typeof c=="object"&&c!==null&&typeof c.then=="function"&&sG(s,c),z4!==null&&z4(s,c)};var _u=B(null);function cw(){var s=_u.current;return s!==null?s:on.pooledCache}function Qg(s,c){c===null?G(_u,_u.current):G(_u,c.pool)}function F4(){var s=cw();return s===null?null:{parent:Gn._currentValue,pool:s}}var yh=Error(r(460)),q4=Error(r(474)),Jg=Error(r(542)),fw={then:function(){}};function V4(s){return s=s.status,s==="fulfilled"||s==="rejected"}function ev(){}function H4(s,c,p){switch(p=s[p],p===void 0?s.push(c):p!==c&&(c.then(ev,ev),c=p),c.status){case"fulfilled":return c.value;case"rejected":throw s=c.reason,W4(s),s;default:if(typeof c.status=="string")c.then(ev,ev);else{if(s=on,s!==null&&100<s.shellSuspendCounter)throw Error(r(482));s=c,s.status="pending",s.then(function(w){if(c.status==="pending"){var T=c;T.status="fulfilled",T.value=w}},function(w){if(c.status==="pending"){var T=c;T.status="rejected",T.reason=w}})}switch(c.status){case"fulfilled":return c.value;case"rejected":throw s=c.reason,W4(s),s}throw bh=c,yh}}var bh=null;function G4(){if(bh===null)throw Error(r(459));var s=bh;return bh=null,s}function W4(s){if(s===yh||s===Jg)throw Error(r(483))}var Vs=!1;function dw(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function hw(s,c){s=s.updateQueue,c.updateQueue===s&&(c.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,callbacks:null})}function Hs(s){return{lane:s,tag:0,payload:null,callback:null,next:null}}function Gs(s,c,p){var w=s.updateQueue;if(w===null)return null;if(w=w.shared,(Vt&2)!==0){var T=w.pending;return T===null?c.next=c:(c.next=T.next,T.next=c),w.pending=c,c=za(s),mu(s,null,p),c}return pu(s,w,c,p),za(s)}function wh(s,c,p){if(c=c.updateQueue,c!==null&&(c=c.shared,(p&4194048)!==0)){var w=c.lanes;w&=s.pendingLanes,p|=w,c.lanes=p,ka(s,p)}}function pw(s,c){var p=s.updateQueue,w=s.alternate;if(w!==null&&(w=w.updateQueue,p===w)){var T=null,k=null;if(p=p.firstBaseUpdate,p!==null){do{var re={lane:p.lane,tag:p.tag,payload:p.payload,callback:null,next:null};k===null?T=k=re:k=k.next=re,p=p.next}while(p!==null);k===null?T=k=c:k=k.next=c}else T=k=c;p={baseState:w.baseState,firstBaseUpdate:T,lastBaseUpdate:k,shared:w.shared,callbacks:w.callbacks},s.updateQueue=p;return}s=p.lastBaseUpdate,s===null?p.firstBaseUpdate=c:s.next=c,p.lastBaseUpdate=c}var mw=!1;function _h(){if(mw){var s=zc;if(s!==null)throw s}}function xh(s,c,p,w){mw=!1;var T=s.updateQueue;Vs=!1;var k=T.firstBaseUpdate,re=T.lastBaseUpdate,le=T.shared.pending;if(le!==null){T.shared.pending=null;var ge=le,Te=ge.next;ge.next=null,re===null?k=Te:re.next=Te,re=ge;var Ie=s.alternate;Ie!==null&&(Ie=Ie.updateQueue,le=Ie.lastBaseUpdate,le!==re&&(le===null?Ie.firstBaseUpdate=Te:le.next=Te,Ie.lastBaseUpdate=ge))}if(k!==null){var Ue=T.baseState;re=0,Ie=Te=ge=null,le=k;do{var Pe=le.lane&-536870913,Re=Pe!==le.lane;if(Re?(Lt&Pe)===Pe:(w&Pe)===Pe){Pe!==0&&Pe===Uc&&(mw=!0),Ie!==null&&(Ie=Ie.next={lane:0,tag:le.tag,payload:le.payload,callback:null,next:null});e:{var vt=s,dt=le;Pe=c;var Yt=p;switch(dt.tag){case 1:if(vt=dt.payload,typeof vt=="function"){Ue=vt.call(Yt,Ue,Pe);break e}Ue=vt;break e;case 3:vt.flags=vt.flags&-65537|128;case 0:if(vt=dt.payload,Pe=typeof vt=="function"?vt.call(Yt,Ue,Pe):vt,Pe==null)break e;Ue=h({},Ue,Pe);break e;case 2:Vs=!0}}Pe=le.callback,Pe!==null&&(s.flags|=64,Re&&(s.flags|=8192),Re=T.callbacks,Re===null?T.callbacks=[Pe]:Re.push(Pe))}else Re={lane:Pe,tag:le.tag,payload:le.payload,callback:le.callback,next:null},Ie===null?(Te=Ie=Re,ge=Ue):Ie=Ie.next=Re,re|=Pe;if(le=le.next,le===null){if(le=T.shared.pending,le===null)break;Re=le,le=Re.next,Re.next=null,T.lastBaseUpdate=Re,T.shared.pending=null}}while(!0);Ie===null&&(ge=Ue),T.baseState=ge,T.firstBaseUpdate=Te,T.lastBaseUpdate=Ie,k===null&&(T.shared.lanes=0),el|=re,s.lanes=re,s.memoizedState=Ue}}function Y4(s,c){if(typeof s!="function")throw Error(r(191,s));s.call(c)}function K4(s,c){var p=s.callbacks;if(p!==null)for(s.callbacks=null,s=0;s<p.length;s++)Y4(p[s],c)}var Fc=B(null),tv=B(0);function Z4(s,c){s=Vo,G(tv,s),G(Fc,c),Vo=s|c.baseLanes}function gw(){G(tv,Vo),G(Fc,Fc.current)}function vw(){Vo=tv.current,Q(Fc),Q(tv)}var Ws=0,At=null,Gt=null,$n=null,nv=!1,qc=!1,xu=!1,rv=0,Sh=0,Vc=null,uG=0;function Nn(){throw Error(r(321))}function yw(s,c){if(c===null)return!1;for(var p=0;p<c.length&&p<s.length;p++)if(!Lr(s[p],c[p]))return!1;return!0}function bw(s,c,p,w,T,k){return Ws=k,At=c,c.memoizedState=null,c.updateQueue=null,c.lanes=0,H.H=s===null||s.memoizedState===null?Nj:Lj,xu=!1,k=p(w,T),xu=!1,qc&&(k=Q4(c,p,w,T)),X4(s),k}function X4(s){H.H=uv;var c=Gt!==null&&Gt.next!==null;if(Ws=0,$n=Gt=At=null,nv=!1,Sh=0,Vc=null,c)throw Error(r(300));s===null||rr||(s=s.dependencies,s!==null&&Zg(s)&&(rr=!0))}function Q4(s,c,p,w){At=s;var T=0;do{if(qc&&(Vc=null),Sh=0,qc=!1,25<=T)throw Error(r(301));if(T+=1,$n=Gt=null,s.updateQueue!=null){var k=s.updateQueue;k.lastEffect=null,k.events=null,k.stores=null,k.memoCache!=null&&(k.memoCache.index=0)}H.H=gG,k=c(p,w)}while(qc);return k}function cG(){var s=H.H,c=s.useState()[0];return c=typeof c.then=="function"?Ch(c):c,s=s.useState()[0],(Gt!==null?Gt.memoizedState:null)!==s&&(At.flags|=1024),c}function ww(){var s=rv!==0;return rv=0,s}function _w(s,c,p){c.updateQueue=s.updateQueue,c.flags&=-2053,s.lanes&=~p}function xw(s){if(nv){for(s=s.memoizedState;s!==null;){var c=s.queue;c!==null&&(c.pending=null),s=s.next}nv=!1}Ws=0,$n=Gt=At=null,qc=!1,Sh=rv=0,Vc=null}function Qr(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return $n===null?At.memoizedState=$n=s:$n=$n.next=s,$n}function Bn(){if(Gt===null){var s=At.alternate;s=s!==null?s.memoizedState:null}else s=Gt.next;var c=$n===null?At.memoizedState:$n.next;if(c!==null)$n=c,Gt=s;else{if(s===null)throw At.alternate===null?Error(r(467)):Error(r(310));Gt=s,s={memoizedState:Gt.memoizedState,baseState:Gt.baseState,baseQueue:Gt.baseQueue,queue:Gt.queue,next:null},$n===null?At.memoizedState=$n=s:$n=$n.next=s}return $n}function Sw(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ch(s){var c=Sh;return Sh+=1,Vc===null&&(Vc=[]),s=H4(Vc,s,c),c=At,($n===null?c.memoizedState:$n.next)===null&&(c=c.alternate,H.H=c===null||c.memoizedState===null?Nj:Lj),s}function iv(s){if(s!==null&&typeof s=="object"){if(typeof s.then=="function")return Ch(s);if(s.$$typeof===O)return Or(s)}throw Error(r(438,String(s)))}function Cw(s){var c=null,p=At.updateQueue;if(p!==null&&(c=p.memoCache),c==null){var w=At.alternate;w!==null&&(w=w.updateQueue,w!==null&&(w=w.memoCache,w!=null&&(c={data:w.data.map(function(T){return T.slice()}),index:0})))}if(c==null&&(c={data:[],index:0}),p===null&&(p=Sw(),At.updateQueue=p),p.memoCache=c,p=c.data[c.index],p===void 0)for(p=c.data[c.index]=Array(s),w=0;w<s;w++)p[w]=K;return c.index++,p}function $o(s,c){return typeof c=="function"?c(s):c}function av(s){var c=Bn();return Aw(c,Gt,s)}function Aw(s,c,p){var w=s.queue;if(w===null)throw Error(r(311));w.lastRenderedReducer=p;var T=s.baseQueue,k=w.pending;if(k!==null){if(T!==null){var re=T.next;T.next=k.next,k.next=re}c.baseQueue=T=k,w.pending=null}if(k=s.baseState,T===null)s.memoizedState=k;else{c=T.next;var le=re=null,ge=null,Te=c,Ie=!1;do{var Ue=Te.lane&-536870913;if(Ue!==Te.lane?(Lt&Ue)===Ue:(Ws&Ue)===Ue){var Pe=Te.revertLane;if(Pe===0)ge!==null&&(ge=ge.next={lane:0,revertLane:0,action:Te.action,hasEagerState:Te.hasEagerState,eagerState:Te.eagerState,next:null}),Ue===Uc&&(Ie=!0);else if((Ws&Pe)===Pe){Te=Te.next,Pe===Uc&&(Ie=!0);continue}else Ue={lane:0,revertLane:Te.revertLane,action:Te.action,hasEagerState:Te.hasEagerState,eagerState:Te.eagerState,next:null},ge===null?(le=ge=Ue,re=k):ge=ge.next=Ue,At.lanes|=Pe,el|=Pe;Ue=Te.action,xu&&p(k,Ue),k=Te.hasEagerState?Te.eagerState:p(k,Ue)}else Pe={lane:Ue,revertLane:Te.revertLane,action:Te.action,hasEagerState:Te.hasEagerState,eagerState:Te.eagerState,next:null},ge===null?(le=ge=Pe,re=k):ge=ge.next=Pe,At.lanes|=Ue,el|=Ue;Te=Te.next}while(Te!==null&&Te!==c);if(ge===null?re=k:ge.next=le,!Lr(k,s.memoizedState)&&(rr=!0,Ie&&(p=zc,p!==null)))throw p;s.memoizedState=k,s.baseState=re,s.baseQueue=ge,w.lastRenderedState=k}return T===null&&(w.lanes=0),[s.memoizedState,w.dispatch]}function Ew(s){var c=Bn(),p=c.queue;if(p===null)throw Error(r(311));p.lastRenderedReducer=s;var w=p.dispatch,T=p.pending,k=c.memoizedState;if(T!==null){p.pending=null;var re=T=T.next;do k=s(k,re.action),re=re.next;while(re!==T);Lr(k,c.memoizedState)||(rr=!0),c.memoizedState=k,c.baseQueue===null&&(c.baseState=k),p.lastRenderedState=k}return[k,w]}function J4(s,c,p){var w=At,T=Bn(),k=yt;if(k){if(p===void 0)throw Error(r(407));p=p()}else p=c();var re=!Lr((Gt||T).memoizedState,p);re&&(T.memoizedState=p,rr=!0),T=T.queue;var le=nj.bind(null,w,T,s);if(Ah(2048,8,le,[s]),T.getSnapshot!==c||re||$n!==null&&$n.memoizedState.tag&1){if(w.flags|=2048,Hc(9,ov(),tj.bind(null,w,T,p,c),null),on===null)throw Error(r(349));k||(Ws&124)!==0||ej(w,c,p)}return p}function ej(s,c,p){s.flags|=16384,s={getSnapshot:c,value:p},c=At.updateQueue,c===null?(c=Sw(),At.updateQueue=c,c.stores=[s]):(p=c.stores,p===null?c.stores=[s]:p.push(s))}function tj(s,c,p,w){c.value=p,c.getSnapshot=w,rj(c)&&ij(s)}function nj(s,c,p){return p(function(){rj(c)&&ij(s)})}function rj(s){var c=s.getSnapshot;s=s.value;try{var p=c();return!Lr(s,p)}catch{return!0}}function ij(s){var c=Us(s,2);c!==null&&gi(c,s,2)}function Ow(s){var c=Qr();if(typeof s=="function"){var p=s;if(s=p(),xu){Fe(!0);try{p()}finally{Fe(!1)}}}return c.memoizedState=c.baseState=s,c.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:$o,lastRenderedState:s},c}function aj(s,c,p,w){return s.baseState=p,Aw(s,Gt,typeof w=="function"?w:$o)}function fG(s,c,p,w,T){if(lv(s))throw Error(r(485));if(s=c.action,s!==null){var k={payload:T,action:s,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(re){k.listeners.push(re)}};H.T!==null?p(!0):k.isTransition=!1,w(k),p=c.pending,p===null?(k.next=c.pending=k,oj(c,k)):(k.next=p.next,c.pending=p.next=k)}}function oj(s,c){var p=c.action,w=c.payload,T=s.state;if(c.isTransition){var k=H.T,re={};H.T=re;try{var le=p(T,w),ge=H.S;ge!==null&&ge(re,le),sj(s,c,le)}catch(Te){Tw(s,c,Te)}finally{H.T=k}}else try{k=p(T,w),sj(s,c,k)}catch(Te){Tw(s,c,Te)}}function sj(s,c,p){p!==null&&typeof p=="object"&&typeof p.then=="function"?p.then(function(w){lj(s,c,w)},function(w){return Tw(s,c,w)}):lj(s,c,p)}function lj(s,c,p){c.status="fulfilled",c.value=p,uj(c),s.state=p,c=s.pending,c!==null&&(p=c.next,p===c?s.pending=null:(p=p.next,c.next=p,oj(s,p)))}function Tw(s,c,p){var w=s.pending;if(s.pending=null,w!==null){w=w.next;do c.status="rejected",c.reason=p,uj(c),c=c.next;while(c!==w)}s.action=null}function uj(s){s=s.listeners;for(var c=0;c<s.length;c++)(0,s[c])()}function cj(s,c){return c}function fj(s,c){if(yt){var p=on.formState;if(p!==null){e:{var w=At;if(yt){if(at){t:{for(var T=at,k=xn;T.nodeType!==8;){if(!k){T=null;break t}if(T=da(T.nextSibling),T===null){T=null;break t}}k=T.data,T=k==="F!"||k==="F"?T:null}if(T){at=da(T.nextSibling),w=T.data==="F!";break e}}Xr(w)}w=!1}w&&(c=p[0])}}return p=Qr(),p.memoizedState=p.baseState=c,w={pending:null,lanes:0,dispatch:null,lastRenderedReducer:cj,lastRenderedState:c},p.queue=w,p=Pj.bind(null,At,w),w.dispatch=p,w=Ow(!1),k=Nw.bind(null,At,!1,w.queue),w=Qr(),T={state:c,dispatch:null,action:s,pending:null},w.queue=T,p=fG.bind(null,At,T,k,p),T.dispatch=p,w.memoizedState=s,[c,p,!1]}function dj(s){var c=Bn();return hj(c,Gt,s)}function hj(s,c,p){if(c=Aw(s,c,cj)[0],s=av($o)[0],typeof c=="object"&&c!==null&&typeof c.then=="function")try{var w=Ch(c)}catch(re){throw re===yh?Jg:re}else w=c;c=Bn();var T=c.queue,k=T.dispatch;return p!==c.memoizedState&&(At.flags|=2048,Hc(9,ov(),dG.bind(null,T,p),null)),[w,k,s]}function dG(s,c){s.action=c}function pj(s){var c=Bn(),p=Gt;if(p!==null)return hj(c,p,s);Bn(),c=c.memoizedState,p=Bn();var w=p.queue.dispatch;return p.memoizedState=s,[c,w,!1]}function Hc(s,c,p,w){return s={tag:s,create:p,deps:w,inst:c,next:null},c=At.updateQueue,c===null&&(c=Sw(),At.updateQueue=c),p=c.lastEffect,p===null?c.lastEffect=s.next=s:(w=p.next,p.next=s,s.next=w,c.lastEffect=s),s}function ov(){return{destroy:void 0,resource:void 0}}function mj(){return Bn().memoizedState}function sv(s,c,p,w){var T=Qr();w=w===void 0?null:w,At.flags|=s,T.memoizedState=Hc(1|c,ov(),p,w)}function Ah(s,c,p,w){var T=Bn();w=w===void 0?null:w;var k=T.memoizedState.inst;Gt!==null&&w!==null&&yw(w,Gt.memoizedState.deps)?T.memoizedState=Hc(c,k,p,w):(At.flags|=s,T.memoizedState=Hc(1|c,k,p,w))}function gj(s,c){sv(8390656,8,s,c)}function vj(s,c){Ah(2048,8,s,c)}function yj(s,c){return Ah(4,2,s,c)}function bj(s,c){return Ah(4,4,s,c)}function wj(s,c){if(typeof c=="function"){s=s();var p=c(s);return function(){typeof p=="function"?p():c(null)}}if(c!=null)return s=s(),c.current=s,function(){c.current=null}}function _j(s,c,p){p=p!=null?p.concat([s]):null,Ah(4,4,wj.bind(null,c,s),p)}function jw(){}function xj(s,c){var p=Bn();c=c===void 0?null:c;var w=p.memoizedState;return c!==null&&yw(c,w[1])?w[0]:(p.memoizedState=[s,c],s)}function Sj(s,c){var p=Bn();c=c===void 0?null:c;var w=p.memoizedState;if(c!==null&&yw(c,w[1]))return w[0];if(w=s(),xu){Fe(!0);try{s()}finally{Fe(!1)}}return p.memoizedState=[w,c],w}function Pw(s,c,p){return p===void 0||(Ws&1073741824)!==0?s.memoizedState=c:(s.memoizedState=p,s=EP(),At.lanes|=s,el|=s,p)}function Cj(s,c,p,w){return Lr(p,c)?p:Fc.current!==null?(s=Pw(s,p,w),Lr(s,c)||(rr=!0),s):(Ws&42)===0?(rr=!0,s.memoizedState=p):(s=EP(),At.lanes|=s,el|=s,c)}function Aj(s,c,p,w,T){var k=I.p;I.p=k!==0&&8>k?k:8;var re=H.T,le={};H.T=le,Nw(s,!1,c,p);try{var ge=T(),Te=H.S;if(Te!==null&&Te(le,ge),ge!==null&&typeof ge=="object"&&typeof ge.then=="function"){var Ie=lG(ge,w);Eh(s,c,Ie,mi(s))}else Eh(s,c,w,mi(s))}catch(Ue){Eh(s,c,{then:function(){},status:"rejected",reason:Ue},mi())}finally{I.p=k,H.T=re}}function hG(){}function Rw(s,c,p,w){if(s.tag!==5)throw Error(r(476));var T=Ej(s).queue;Aj(s,T,c,D,p===null?hG:function(){return Oj(s),p(w)})}function Ej(s){var c=s.memoizedState;if(c!==null)return c;c={memoizedState:D,baseState:D,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:$o,lastRenderedState:D},next:null};var p={};return c.next={memoizedState:p,baseState:p,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:$o,lastRenderedState:p},next:null},s.memoizedState=c,s=s.alternate,s!==null&&(s.memoizedState=c),c}function Oj(s){var c=Ej(s).next.queue;Eh(s,c,{},mi())}function Mw(){return Or(Vh)}function Tj(){return Bn().memoizedState}function jj(){return Bn().memoizedState}function pG(s){for(var c=s.return;c!==null;){switch(c.tag){case 24:case 3:var p=mi();s=Hs(p);var w=Gs(c,s,p);w!==null&&(gi(w,c,p),wh(w,c,p)),c={cache:lw()},s.payload=c;return}c=c.return}}function mG(s,c,p){var w=mi();p={lane:w,revertLane:0,action:p,hasEagerState:!1,eagerState:null,next:null},lv(s)?Rj(c,p):(p=ko(s,c,p,w),p!==null&&(gi(p,s,w),Mj(p,c,w)))}function Pj(s,c,p){var w=mi();Eh(s,c,p,w)}function Eh(s,c,p,w){var T={lane:w,revertLane:0,action:p,hasEagerState:!1,eagerState:null,next:null};if(lv(s))Rj(c,T);else{var k=s.alternate;if(s.lanes===0&&(k===null||k.lanes===0)&&(k=c.lastRenderedReducer,k!==null))try{var re=c.lastRenderedState,le=k(re,p);if(T.hasEagerState=!0,T.eagerState=le,Lr(le,re))return pu(s,c,T,0),on===null&&hu(),!1}catch{}finally{}if(p=ko(s,c,T,w),p!==null)return gi(p,s,w),Mj(p,c,w),!0}return!1}function Nw(s,c,p,w){if(w={lane:2,revertLane:f_(),action:w,hasEagerState:!1,eagerState:null,next:null},lv(s)){if(c)throw Error(r(479))}else c=ko(s,p,w,2),c!==null&&gi(c,s,2)}function lv(s){var c=s.alternate;return s===At||c!==null&&c===At}function Rj(s,c){qc=nv=!0;var p=s.pending;p===null?c.next=c:(c.next=p.next,p.next=c),s.pending=c}function Mj(s,c,p){if((p&4194048)!==0){var w=c.lanes;w&=s.pendingLanes,p|=w,c.lanes=p,ka(s,p)}}var uv={readContext:Or,use:iv,useCallback:Nn,useContext:Nn,useEffect:Nn,useImperativeHandle:Nn,useLayoutEffect:Nn,useInsertionEffect:Nn,useMemo:Nn,useReducer:Nn,useRef:Nn,useState:Nn,useDebugValue:Nn,useDeferredValue:Nn,useTransition:Nn,useSyncExternalStore:Nn,useId:Nn,useHostTransitionStatus:Nn,useFormState:Nn,useActionState:Nn,useOptimistic:Nn,useMemoCache:Nn,useCacheRefresh:Nn},Nj={readContext:Or,use:iv,useCallback:function(s,c){return Qr().memoizedState=[s,c===void 0?null:c],s},useContext:Or,useEffect:gj,useImperativeHandle:function(s,c,p){p=p!=null?p.concat([s]):null,sv(4194308,4,wj.bind(null,c,s),p)},useLayoutEffect:function(s,c){return sv(4194308,4,s,c)},useInsertionEffect:function(s,c){sv(4,2,s,c)},useMemo:function(s,c){var p=Qr();c=c===void 0?null:c;var w=s();if(xu){Fe(!0);try{s()}finally{Fe(!1)}}return p.memoizedState=[w,c],w},useReducer:function(s,c,p){var w=Qr();if(p!==void 0){var T=p(c);if(xu){Fe(!0);try{p(c)}finally{Fe(!1)}}}else T=c;return w.memoizedState=w.baseState=T,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:T},w.queue=s,s=s.dispatch=mG.bind(null,At,s),[w.memoizedState,s]},useRef:function(s){var c=Qr();return s={current:s},c.memoizedState=s},useState:function(s){s=Ow(s);var c=s.queue,p=Pj.bind(null,At,c);return c.dispatch=p,[s.memoizedState,p]},useDebugValue:jw,useDeferredValue:function(s,c){var p=Qr();return Pw(p,s,c)},useTransition:function(){var s=Ow(!1);return s=Aj.bind(null,At,s.queue,!0,!1),Qr().memoizedState=s,[!1,s]},useSyncExternalStore:function(s,c,p){var w=At,T=Qr();if(yt){if(p===void 0)throw Error(r(407));p=p()}else{if(p=c(),on===null)throw Error(r(349));(Lt&124)!==0||ej(w,c,p)}T.memoizedState=p;var k={value:p,getSnapshot:c};return T.queue=k,gj(nj.bind(null,w,k,s),[s]),w.flags|=2048,Hc(9,ov(),tj.bind(null,w,k,p,c),null),p},useId:function(){var s=Qr(),c=on.identifierPrefix;if(yt){var p=me,w=oe;p=(w&~(1<<32-Ge(w)-1)).toString(32)+p,c="«"+c+"R"+p,p=rv++,0<p&&(c+="H"+p.toString(32)),c+="»"}else p=uG++,c="«"+c+"r"+p.toString(32)+"»";return s.memoizedState=c},useHostTransitionStatus:Mw,useFormState:fj,useActionState:fj,useOptimistic:function(s){var c=Qr();c.memoizedState=c.baseState=s;var p={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return c.queue=p,c=Nw.bind(null,At,!0,p),p.dispatch=c,[s,c]},useMemoCache:Cw,useCacheRefresh:function(){return Qr().memoizedState=pG.bind(null,At)}},Lj={readContext:Or,use:iv,useCallback:xj,useContext:Or,useEffect:vj,useImperativeHandle:_j,useInsertionEffect:yj,useLayoutEffect:bj,useMemo:Sj,useReducer:av,useRef:mj,useState:function(){return av($o)},useDebugValue:jw,useDeferredValue:function(s,c){var p=Bn();return Cj(p,Gt.memoizedState,s,c)},useTransition:function(){var s=av($o)[0],c=Bn().memoizedState;return[typeof s=="boolean"?s:Ch(s),c]},useSyncExternalStore:J4,useId:Tj,useHostTransitionStatus:Mw,useFormState:dj,useActionState:dj,useOptimistic:function(s,c){var p=Bn();return aj(p,Gt,s,c)},useMemoCache:Cw,useCacheRefresh:jj},gG={readContext:Or,use:iv,useCallback:xj,useContext:Or,useEffect:vj,useImperativeHandle:_j,useInsertionEffect:yj,useLayoutEffect:bj,useMemo:Sj,useReducer:Ew,useRef:mj,useState:function(){return Ew($o)},useDebugValue:jw,useDeferredValue:function(s,c){var p=Bn();return Gt===null?Pw(p,s,c):Cj(p,Gt.memoizedState,s,c)},useTransition:function(){var s=Ew($o)[0],c=Bn().memoizedState;return[typeof s=="boolean"?s:Ch(s),c]},useSyncExternalStore:J4,useId:Tj,useHostTransitionStatus:Mw,useFormState:pj,useActionState:pj,useOptimistic:function(s,c){var p=Bn();return Gt!==null?aj(p,Gt,s,c):(p.baseState=s,[s,p.queue.dispatch])},useMemoCache:Cw,useCacheRefresh:jj},Gc=null,Oh=0;function cv(s){var c=Oh;return Oh+=1,Gc===null&&(Gc=[]),H4(Gc,s,c)}function Th(s,c){c=c.props.ref,s.ref=c!==void 0?c:null}function fv(s,c){throw c.$$typeof===m?Error(r(525)):(s=Object.prototype.toString.call(c),Error(r(31,s==="[object Object]"?"object with keys {"+Object.keys(c).join(", ")+"}":s)))}function kj(s){var c=s._init;return c(s._payload)}function Dj(s){function c(Ce,we){if(s){var Ee=Ce.deletions;Ee===null?(Ce.deletions=[we],Ce.flags|=16):Ee.push(we)}}function p(Ce,we){if(!s)return null;for(;we!==null;)c(Ce,we),we=we.sibling;return null}function w(Ce){for(var we=new Map;Ce!==null;)Ce.key!==null?we.set(Ce.key,Ce):we.set(Ce.index,Ce),Ce=Ce.sibling;return we}function T(Ce,we){return Ce=qi(Ce,we),Ce.index=0,Ce.sibling=null,Ce}function k(Ce,we,Ee){return Ce.index=Ee,s?(Ee=Ce.alternate,Ee!==null?(Ee=Ee.index,Ee<we?(Ce.flags|=67108866,we):Ee):(Ce.flags|=67108866,we)):(Ce.flags|=1048576,we)}function re(Ce){return s&&Ce.alternate===null&&(Ce.flags|=67108866),Ce}function le(Ce,we,Ee,Be){return we===null||we.tag!==6?(we=mh(Ee,Ce.mode,Be),we.return=Ce,we):(we=T(we,Ee),we.return=Ce,we)}function ge(Ce,we,Ee,Be){var it=Ee.type;return it===x?Ie(Ce,we,Ee.props.children,Be,Ee.key):we!==null&&(we.elementType===it||typeof it=="object"&&it!==null&&it.$$typeof===V&&kj(it)===we.type)?(we=T(we,Ee.props),Th(we,Ee),we.return=Ce,we):(we=gu(Ee.type,Ee.key,Ee.props,null,Ce.mode,Be),Th(we,Ee),we.return=Ce,we)}function Te(Ce,we,Ee,Be){return we===null||we.tag!==4||we.stateNode.containerInfo!==Ee.containerInfo||we.stateNode.implementation!==Ee.implementation?(we=$c(Ee,Ce.mode,Be),we.return=Ce,we):(we=T(we,Ee.children||[]),we.return=Ce,we)}function Ie(Ce,we,Ee,Be,it){return we===null||we.tag!==7?(we=Fa(Ee,Ce.mode,Be,it),we.return=Ce,we):(we=T(we,Ee),we.return=Ce,we)}function Ue(Ce,we,Ee){if(typeof we=="string"&&we!==""||typeof we=="number"||typeof we=="bigint")return we=mh(""+we,Ce.mode,Ee),we.return=Ce,we;if(typeof we=="object"&&we!==null){switch(we.$$typeof){case g:return Ee=gu(we.type,we.key,we.props,null,Ce.mode,Ee),Th(Ee,we),Ee.return=Ce,Ee;case _:return we=$c(we,Ce.mode,Ee),we.return=Ce,we;case V:var Be=we._init;return we=Be(we._payload),Ue(Ce,we,Ee)}if(ne(we)||ee(we))return we=Fa(we,Ce.mode,Ee,null),we.return=Ce,we;if(typeof we.then=="function")return Ue(Ce,cv(we),Ee);if(we.$$typeof===O)return Ue(Ce,Xg(Ce,we),Ee);fv(Ce,we)}return null}function Pe(Ce,we,Ee,Be){var it=we!==null?we.key:null;if(typeof Ee=="string"&&Ee!==""||typeof Ee=="number"||typeof Ee=="bigint")return it!==null?null:le(Ce,we,""+Ee,Be);if(typeof Ee=="object"&&Ee!==null){switch(Ee.$$typeof){case g:return Ee.key===it?ge(Ce,we,Ee,Be):null;case _:return Ee.key===it?Te(Ce,we,Ee,Be):null;case V:return it=Ee._init,Ee=it(Ee._payload),Pe(Ce,we,Ee,Be)}if(ne(Ee)||ee(Ee))return it!==null?null:Ie(Ce,we,Ee,Be,null);if(typeof Ee.then=="function")return Pe(Ce,we,cv(Ee),Be);if(Ee.$$typeof===O)return Pe(Ce,we,Xg(Ce,Ee),Be);fv(Ce,Ee)}return null}function Re(Ce,we,Ee,Be,it){if(typeof Be=="string"&&Be!==""||typeof Be=="number"||typeof Be=="bigint")return Ce=Ce.get(Ee)||null,le(we,Ce,""+Be,it);if(typeof Be=="object"&&Be!==null){switch(Be.$$typeof){case g:return Ce=Ce.get(Be.key===null?Ee:Be.key)||null,ge(we,Ce,Be,it);case _:return Ce=Ce.get(Be.key===null?Ee:Be.key)||null,Te(we,Ce,Be,it);case V:var Ot=Be._init;return Be=Ot(Be._payload),Re(Ce,we,Ee,Be,it)}if(ne(Be)||ee(Be))return Ce=Ce.get(Ee)||null,Ie(we,Ce,Be,it,null);if(typeof Be.then=="function")return Re(Ce,we,Ee,cv(Be),it);if(Be.$$typeof===O)return Re(Ce,we,Ee,Xg(we,Be),it);fv(we,Be)}return null}function vt(Ce,we,Ee,Be){for(var it=null,Ot=null,ct=we,mt=we=0,ar=null;ct!==null&&mt<Ee.length;mt++){ct.index>mt?(ar=ct,ct=null):ar=ct.sibling;var Bt=Pe(Ce,ct,Ee[mt],Be);if(Bt===null){ct===null&&(ct=ar);break}s&&ct&&Bt.alternate===null&&c(Ce,ct),we=k(Bt,we,mt),Ot===null?it=Bt:Ot.sibling=Bt,Ot=Bt,ct=ar}if(mt===Ee.length)return p(Ce,ct),yt&&Ae(Ce,mt),it;if(ct===null){for(;mt<Ee.length;mt++)ct=Ue(Ce,Ee[mt],Be),ct!==null&&(we=k(ct,we,mt),Ot===null?it=ct:Ot.sibling=ct,Ot=ct);return yt&&Ae(Ce,mt),it}for(ct=w(ct);mt<Ee.length;mt++)ar=Re(ct,Ce,mt,Ee[mt],Be),ar!==null&&(s&&ar.alternate!==null&&ct.delete(ar.key===null?mt:ar.key),we=k(ar,we,mt),Ot===null?it=ar:Ot.sibling=ar,Ot=ar);return s&&ct.forEach(function(ul){return c(Ce,ul)}),yt&&Ae(Ce,mt),it}function dt(Ce,we,Ee,Be){if(Ee==null)throw Error(r(151));for(var it=null,Ot=null,ct=we,mt=we=0,ar=null,Bt=Ee.next();ct!==null&&!Bt.done;mt++,Bt=Ee.next()){ct.index>mt?(ar=ct,ct=null):ar=ct.sibling;var ul=Pe(Ce,ct,Bt.value,Be);if(ul===null){ct===null&&(ct=ar);break}s&&ct&&ul.alternate===null&&c(Ce,ct),we=k(ul,we,mt),Ot===null?it=ul:Ot.sibling=ul,Ot=ul,ct=ar}if(Bt.done)return p(Ce,ct),yt&&Ae(Ce,mt),it;if(ct===null){for(;!Bt.done;mt++,Bt=Ee.next())Bt=Ue(Ce,Bt.value,Be),Bt!==null&&(we=k(Bt,we,mt),Ot===null?it=Bt:Ot.sibling=Bt,Ot=Bt);return yt&&Ae(Ce,mt),it}for(ct=w(ct);!Bt.done;mt++,Bt=Ee.next())Bt=Re(ct,Ce,mt,Bt.value,Be),Bt!==null&&(s&&Bt.alternate!==null&&ct.delete(Bt.key===null?mt:Bt.key),we=k(Bt,we,mt),Ot===null?it=Bt:Ot.sibling=Bt,Ot=Bt);return s&&ct.forEach(function(vW){return c(Ce,vW)}),yt&&Ae(Ce,mt),it}function Yt(Ce,we,Ee,Be){if(typeof Ee=="object"&&Ee!==null&&Ee.type===x&&Ee.key===null&&(Ee=Ee.props.children),typeof Ee=="object"&&Ee!==null){switch(Ee.$$typeof){case g:e:{for(var it=Ee.key;we!==null;){if(we.key===it){if(it=Ee.type,it===x){if(we.tag===7){p(Ce,we.sibling),Be=T(we,Ee.props.children),Be.return=Ce,Ce=Be;break e}}else if(we.elementType===it||typeof it=="object"&&it!==null&&it.$$typeof===V&&kj(it)===we.type){p(Ce,we.sibling),Be=T(we,Ee.props),Th(Be,Ee),Be.return=Ce,Ce=Be;break e}p(Ce,we);break}else c(Ce,we);we=we.sibling}Ee.type===x?(Be=Fa(Ee.props.children,Ce.mode,Be,Ee.key),Be.return=Ce,Ce=Be):(Be=gu(Ee.type,Ee.key,Ee.props,null,Ce.mode,Be),Th(Be,Ee),Be.return=Ce,Ce=Be)}return re(Ce);case _:e:{for(it=Ee.key;we!==null;){if(we.key===it)if(we.tag===4&&we.stateNode.containerInfo===Ee.containerInfo&&we.stateNode.implementation===Ee.implementation){p(Ce,we.sibling),Be=T(we,Ee.children||[]),Be.return=Ce,Ce=Be;break e}else{p(Ce,we);break}else c(Ce,we);we=we.sibling}Be=$c(Ee,Ce.mode,Be),Be.return=Ce,Ce=Be}return re(Ce);case V:return it=Ee._init,Ee=it(Ee._payload),Yt(Ce,we,Ee,Be)}if(ne(Ee))return vt(Ce,we,Ee,Be);if(ee(Ee)){if(it=ee(Ee),typeof it!="function")throw Error(r(150));return Ee=it.call(Ee),dt(Ce,we,Ee,Be)}if(typeof Ee.then=="function")return Yt(Ce,we,cv(Ee),Be);if(Ee.$$typeof===O)return Yt(Ce,we,Xg(Ce,Ee),Be);fv(Ce,Ee)}return typeof Ee=="string"&&Ee!==""||typeof Ee=="number"||typeof Ee=="bigint"?(Ee=""+Ee,we!==null&&we.tag===6?(p(Ce,we.sibling),Be=T(we,Ee),Be.return=Ce,Ce=Be):(p(Ce,we),Be=mh(Ee,Ce.mode,Be),Be.return=Ce,Ce=Be),re(Ce)):p(Ce,we)}return function(Ce,we,Ee,Be){try{Oh=0;var it=Yt(Ce,we,Ee,Be);return Gc=null,it}catch(ct){if(ct===yh||ct===Jg)throw ct;var Ot=$r(29,ct,null,Ce.mode);return Ot.lanes=Be,Ot.return=Ce,Ot}finally{}}}var Wc=Dj(!0),Ij=Dj(!1),Hi=B(null),Va=null;function Ys(s){var c=s.alternate;G(Wn,Wn.current&1),G(Hi,s),Va===null&&(c===null||Fc.current!==null||c.memoizedState!==null)&&(Va=s)}function $j(s){if(s.tag===22){if(G(Wn,Wn.current),G(Hi,s),Va===null){var c=s.alternate;c!==null&&c.memoizedState!==null&&(Va=s)}}else Ks()}function Ks(){G(Wn,Wn.current),G(Hi,Hi.current)}function Bo(s){Q(Hi),Va===s&&(Va=null),Q(Wn)}var Wn=B(0);function dv(s){for(var c=s;c!==null;){if(c.tag===13){var p=c.memoizedState;if(p!==null&&(p=p.dehydrated,p===null||p.data==="$?"||S_(p)))return c}else if(c.tag===19&&c.memoizedProps.revealOrder!==void 0){if((c.flags&128)!==0)return c}else if(c.child!==null){c.child.return=c,c=c.child;continue}if(c===s)break;for(;c.sibling===null;){if(c.return===null||c.return===s)return null;c=c.return}c.sibling.return=c.return,c=c.sibling}return null}function Lw(s,c,p,w){c=s.memoizedState,p=p(w,c),p=p==null?c:h({},c,p),s.memoizedState=p,s.lanes===0&&(s.updateQueue.baseState=p)}var kw={enqueueSetState:function(s,c,p){s=s._reactInternals;var w=mi(),T=Hs(w);T.payload=c,p!=null&&(T.callback=p),c=Gs(s,T,w),c!==null&&(gi(c,s,w),wh(c,s,w))},enqueueReplaceState:function(s,c,p){s=s._reactInternals;var w=mi(),T=Hs(w);T.tag=1,T.payload=c,p!=null&&(T.callback=p),c=Gs(s,T,w),c!==null&&(gi(c,s,w),wh(c,s,w))},enqueueForceUpdate:function(s,c){s=s._reactInternals;var p=mi(),w=Hs(p);w.tag=2,c!=null&&(w.callback=c),c=Gs(s,w,p),c!==null&&(gi(c,s,p),wh(c,s,p))}};function Bj(s,c,p,w,T,k,re){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(w,k,re):c.prototype&&c.prototype.isPureReactComponent?!kr(p,w)||!kr(T,k):!0}function Uj(s,c,p,w){s=c.state,typeof c.componentWillReceiveProps=="function"&&c.componentWillReceiveProps(p,w),typeof c.UNSAFE_componentWillReceiveProps=="function"&&c.UNSAFE_componentWillReceiveProps(p,w),c.state!==s&&kw.enqueueReplaceState(c,c.state,null)}function Su(s,c){var p=c;if("ref"in c){p={};for(var w in c)w!=="ref"&&(p[w]=c[w])}if(s=s.defaultProps){p===c&&(p=h({},p));for(var T in s)p[T]===void 0&&(p[T]=s[T])}return p}var hv=typeof reportError=="function"?reportError:function(s){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var c=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof s=="object"&&s!==null&&typeof s.message=="string"?String(s.message):String(s),error:s});if(!window.dispatchEvent(c))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",s);return}console.error(s)};function zj(s){hv(s)}function Fj(s){console.error(s)}function qj(s){hv(s)}function pv(s,c){try{var p=s.onUncaughtError;p(c.value,{componentStack:c.stack})}catch(w){setTimeout(function(){throw w})}}function Vj(s,c,p){try{var w=s.onCaughtError;w(p.value,{componentStack:p.stack,errorBoundary:c.tag===1?c.stateNode:null})}catch(T){setTimeout(function(){throw T})}}function Dw(s,c,p){return p=Hs(p),p.tag=3,p.payload={element:null},p.callback=function(){pv(s,c)},p}function Hj(s){return s=Hs(s),s.tag=3,s}function Gj(s,c,p,w){var T=p.type.getDerivedStateFromError;if(typeof T=="function"){var k=w.value;s.payload=function(){return T(k)},s.callback=function(){Vj(c,p,w)}}var re=p.stateNode;re!==null&&typeof re.componentDidCatch=="function"&&(s.callback=function(){Vj(c,p,w),typeof T!="function"&&(tl===null?tl=new Set([this]):tl.add(this));var le=w.stack;this.componentDidCatch(w.value,{componentStack:le!==null?le:""})})}function vG(s,c,p,w,T){if(p.flags|=32768,w!==null&&typeof w=="object"&&typeof w.then=="function"){if(c=p.alternate,c!==null&&bu(c,p,T,!0),p=Hi.current,p!==null){switch(p.tag){case 13:return Va===null?o_():p.alternate===null&&En===0&&(En=3),p.flags&=-257,p.flags|=65536,p.lanes=T,w===fw?p.flags|=16384:(c=p.updateQueue,c===null?p.updateQueue=new Set([w]):c.add(w),l_(s,w,T)),!1;case 22:return p.flags|=65536,w===fw?p.flags|=16384:(c=p.updateQueue,c===null?(c={transitions:null,markerInstances:null,retryQueue:new Set([w])},p.updateQueue=c):(p=c.retryQueue,p===null?c.retryQueue=new Set([w]):p.add(w)),l_(s,w,T)),!1}throw Error(r(435,p.tag))}return l_(s,w,T),o_(),!1}if(yt)return c=Hi.current,c!==null?((c.flags&65536)===0&&(c.flags|=256),c.flags|=65536,c.lanes=T,w!==nr&&(s=Error(r(422),{cause:w}),qs(Dr(s,p)))):(w!==nr&&(c=Error(r(423),{cause:w}),qs(Dr(c,p))),s=s.current.alternate,s.flags|=65536,T&=-T,s.lanes|=T,w=Dr(w,p),T=Dw(s.stateNode,w,T),pw(s,T),En!==4&&(En=2)),!1;var k=Error(r(520),{cause:w});if(k=Dr(k,p),kh===null?kh=[k]:kh.push(k),En!==4&&(En=2),c===null)return!0;w=Dr(w,p),p=c;do{switch(p.tag){case 3:return p.flags|=65536,s=T&-T,p.lanes|=s,s=Dw(p.stateNode,w,s),pw(p,s),!1;case 1:if(c=p.type,k=p.stateNode,(p.flags&128)===0&&(typeof c.getDerivedStateFromError=="function"||k!==null&&typeof k.componentDidCatch=="function"&&(tl===null||!tl.has(k))))return p.flags|=65536,T&=-T,p.lanes|=T,T=Hj(T),Gj(T,s,p,w),pw(p,T),!1}p=p.return}while(p!==null);return!1}var Wj=Error(r(461)),rr=!1;function pr(s,c,p,w){c.child=s===null?Ij(c,null,p,w):Wc(c,s.child,p,w)}function Yj(s,c,p,w,T){p=p.render;var k=c.ref;if("ref"in w){var re={};for(var le in w)le!=="ref"&&(re[le]=w[le])}else re=w;return wu(c),w=bw(s,c,p,re,k,T),le=ww(),s!==null&&!rr?(_w(s,c,T),Uo(s,c,T)):(yt&&le&&qe(c),c.flags|=1,pr(s,c,w,T),c.child)}function Kj(s,c,p,w,T){if(s===null){var k=p.type;return typeof k=="function"&&!Ic(k)&&k.defaultProps===void 0&&p.compare===null?(c.tag=15,c.type=k,Zj(s,c,k,w,T)):(s=gu(p.type,null,w,c,c.mode,T),s.ref=c.ref,s.return=c,c.child=s)}if(k=s.child,!Vw(s,T)){var re=k.memoizedProps;if(p=p.compare,p=p!==null?p:kr,p(re,w)&&s.ref===c.ref)return Uo(s,c,T)}return c.flags|=1,s=qi(k,w),s.ref=c.ref,s.return=c,c.child=s}function Zj(s,c,p,w,T){if(s!==null){var k=s.memoizedProps;if(kr(k,w)&&s.ref===c.ref)if(rr=!1,c.pendingProps=w=k,Vw(s,T))(s.flags&131072)!==0&&(rr=!0);else return c.lanes=s.lanes,Uo(s,c,T)}return Iw(s,c,p,w,T)}function Xj(s,c,p){var w=c.pendingProps,T=w.children,k=s!==null?s.memoizedState:null;if(w.mode==="hidden"){if((c.flags&128)!==0){if(w=k!==null?k.baseLanes|p:p,s!==null){for(T=c.child=s.child,k=0;T!==null;)k=k|T.lanes|T.childLanes,T=T.sibling;c.childLanes=k&~w}else c.childLanes=0,c.child=null;return Qj(s,c,w,p)}if((p&536870912)!==0)c.memoizedState={baseLanes:0,cachePool:null},s!==null&&Qg(c,k!==null?k.cachePool:null),k!==null?Z4(c,k):gw(),$j(c);else return c.lanes=c.childLanes=536870912,Qj(s,c,k!==null?k.baseLanes|p:p,p)}else k!==null?(Qg(c,k.cachePool),Z4(c,k),Ks(),c.memoizedState=null):(s!==null&&Qg(c,null),gw(),Ks());return pr(s,c,T,p),c.child}function Qj(s,c,p,w){var T=cw();return T=T===null?null:{parent:Gn._currentValue,pool:T},c.memoizedState={baseLanes:p,cachePool:T},s!==null&&Qg(c,null),gw(),$j(c),s!==null&&bu(s,c,w,!0),null}function mv(s,c){var p=c.ref;if(p===null)s!==null&&s.ref!==null&&(c.flags|=4194816);else{if(typeof p!="function"&&typeof p!="object")throw Error(r(284));(s===null||s.ref!==p)&&(c.flags|=4194816)}}function Iw(s,c,p,w,T){return wu(c),p=bw(s,c,p,w,void 0,T),w=ww(),s!==null&&!rr?(_w(s,c,T),Uo(s,c,T)):(yt&&w&&qe(c),c.flags|=1,pr(s,c,p,T),c.child)}function Jj(s,c,p,w,T,k){return wu(c),c.updateQueue=null,p=Q4(c,w,p,T),X4(s),w=ww(),s!==null&&!rr?(_w(s,c,k),Uo(s,c,k)):(yt&&w&&qe(c),c.flags|=1,pr(s,c,p,k),c.child)}function eP(s,c,p,w,T){if(wu(c),c.stateNode===null){var k=Do,re=p.contextType;typeof re=="object"&&re!==null&&(k=Or(re)),k=new p(w,k),c.memoizedState=k.state!==null&&k.state!==void 0?k.state:null,k.updater=kw,c.stateNode=k,k._reactInternals=c,k=c.stateNode,k.props=w,k.state=c.memoizedState,k.refs={},dw(c),re=p.contextType,k.context=typeof re=="object"&&re!==null?Or(re):Do,k.state=c.memoizedState,re=p.getDerivedStateFromProps,typeof re=="function"&&(Lw(c,p,re,w),k.state=c.memoizedState),typeof p.getDerivedStateFromProps=="function"||typeof k.getSnapshotBeforeUpdate=="function"||typeof k.UNSAFE_componentWillMount!="function"&&typeof k.componentWillMount!="function"||(re=k.state,typeof k.componentWillMount=="function"&&k.componentWillMount(),typeof k.UNSAFE_componentWillMount=="function"&&k.UNSAFE_componentWillMount(),re!==k.state&&kw.enqueueReplaceState(k,k.state,null),xh(c,w,k,T),_h(),k.state=c.memoizedState),typeof k.componentDidMount=="function"&&(c.flags|=4194308),w=!0}else if(s===null){k=c.stateNode;var le=c.memoizedProps,ge=Su(p,le);k.props=ge;var Te=k.context,Ie=p.contextType;re=Do,typeof Ie=="object"&&Ie!==null&&(re=Or(Ie));var Ue=p.getDerivedStateFromProps;Ie=typeof Ue=="function"||typeof k.getSnapshotBeforeUpdate=="function",le=c.pendingProps!==le,Ie||typeof k.UNSAFE_componentWillReceiveProps!="function"&&typeof k.componentWillReceiveProps!="function"||(le||Te!==re)&&Uj(c,k,w,re),Vs=!1;var Pe=c.memoizedState;k.state=Pe,xh(c,w,k,T),_h(),Te=c.memoizedState,le||Pe!==Te||Vs?(typeof Ue=="function"&&(Lw(c,p,Ue,w),Te=c.memoizedState),(ge=Vs||Bj(c,p,ge,w,Pe,Te,re))?(Ie||typeof k.UNSAFE_componentWillMount!="function"&&typeof k.componentWillMount!="function"||(typeof k.componentWillMount=="function"&&k.componentWillMount(),typeof k.UNSAFE_componentWillMount=="function"&&k.UNSAFE_componentWillMount()),typeof k.componentDidMount=="function"&&(c.flags|=4194308)):(typeof k.componentDidMount=="function"&&(c.flags|=4194308),c.memoizedProps=w,c.memoizedState=Te),k.props=w,k.state=Te,k.context=re,w=ge):(typeof k.componentDidMount=="function"&&(c.flags|=4194308),w=!1)}else{k=c.stateNode,hw(s,c),re=c.memoizedProps,Ie=Su(p,re),k.props=Ie,Ue=c.pendingProps,Pe=k.context,Te=p.contextType,ge=Do,typeof Te=="object"&&Te!==null&&(ge=Or(Te)),le=p.getDerivedStateFromProps,(Te=typeof le=="function"||typeof k.getSnapshotBeforeUpdate=="function")||typeof k.UNSAFE_componentWillReceiveProps!="function"&&typeof k.componentWillReceiveProps!="function"||(re!==Ue||Pe!==ge)&&Uj(c,k,w,ge),Vs=!1,Pe=c.memoizedState,k.state=Pe,xh(c,w,k,T),_h();var Re=c.memoizedState;re!==Ue||Pe!==Re||Vs||s!==null&&s.dependencies!==null&&Zg(s.dependencies)?(typeof le=="function"&&(Lw(c,p,le,w),Re=c.memoizedState),(Ie=Vs||Bj(c,p,Ie,w,Pe,Re,ge)||s!==null&&s.dependencies!==null&&Zg(s.dependencies))?(Te||typeof k.UNSAFE_componentWillUpdate!="function"&&typeof k.componentWillUpdate!="function"||(typeof k.componentWillUpdate=="function"&&k.componentWillUpdate(w,Re,ge),typeof k.UNSAFE_componentWillUpdate=="function"&&k.UNSAFE_componentWillUpdate(w,Re,ge)),typeof k.componentDidUpdate=="function"&&(c.flags|=4),typeof k.getSnapshotBeforeUpdate=="function"&&(c.flags|=1024)):(typeof k.componentDidUpdate!="function"||re===s.memoizedProps&&Pe===s.memoizedState||(c.flags|=4),typeof k.getSnapshotBeforeUpdate!="function"||re===s.memoizedProps&&Pe===s.memoizedState||(c.flags|=1024),c.memoizedProps=w,c.memoizedState=Re),k.props=w,k.state=Re,k.context=ge,w=Ie):(typeof k.componentDidUpdate!="function"||re===s.memoizedProps&&Pe===s.memoizedState||(c.flags|=4),typeof k.getSnapshotBeforeUpdate!="function"||re===s.memoizedProps&&Pe===s.memoizedState||(c.flags|=1024),w=!1)}return k=w,mv(s,c),w=(c.flags&128)!==0,k||w?(k=c.stateNode,p=w&&typeof p.getDerivedStateFromError!="function"?null:k.render(),c.flags|=1,s!==null&&w?(c.child=Wc(c,s.child,null,T),c.child=Wc(c,null,p,T)):pr(s,c,p,T),c.memoizedState=k.state,s=c.child):s=Uo(s,c,T),s}function tP(s,c,p,w){return Fs(),c.flags|=256,pr(s,c,p,w),c.child}var $w={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Bw(s){return{baseLanes:s,cachePool:F4()}}function Uw(s,c,p){return s=s!==null?s.childLanes&~p:0,c&&(s|=Gi),s}function nP(s,c,p){var w=c.pendingProps,T=!1,k=(c.flags&128)!==0,re;if((re=k)||(re=s!==null&&s.memoizedState===null?!1:(Wn.current&2)!==0),re&&(T=!0,c.flags&=-129),re=(c.flags&32)!==0,c.flags&=-33,s===null){if(yt){if(T?Ys(c):Ks(),yt){var le=at,ge;if(ge=le){e:{for(ge=le,le=xn;ge.nodeType!==8;){if(!le){le=null;break e}if(ge=da(ge.nextSibling),ge===null){le=null;break e}}le=ge}le!==null?(c.memoizedState={dehydrated:le,treeContext:Z!==null?{id:oe,overflow:me}:null,retryLane:536870912,hydrationErrors:null},ge=$r(18,null,null,0),ge.stateNode=le,ge.return=c,c.child=ge,rt=c,at=null,ge=!0):ge=!1}ge||Xr(c)}if(le=c.memoizedState,le!==null&&(le=le.dehydrated,le!==null))return S_(le)?c.lanes=32:c.lanes=536870912,null;Bo(c)}return le=w.children,w=w.fallback,T?(Ks(),T=c.mode,le=gv({mode:"hidden",children:le},T),w=Fa(w,T,p,null),le.return=c,w.return=c,le.sibling=w,c.child=le,T=c.child,T.memoizedState=Bw(p),T.childLanes=Uw(s,re,p),c.memoizedState=$w,w):(Ys(c),zw(c,le))}if(ge=s.memoizedState,ge!==null&&(le=ge.dehydrated,le!==null)){if(k)c.flags&256?(Ys(c),c.flags&=-257,c=Fw(s,c,p)):c.memoizedState!==null?(Ks(),c.child=s.child,c.flags|=128,c=null):(Ks(),T=w.fallback,le=c.mode,w=gv({mode:"visible",children:w.children},le),T=Fa(T,le,p,null),T.flags|=2,w.return=c,T.return=c,w.sibling=T,c.child=w,Wc(c,s.child,null,p),w=c.child,w.memoizedState=Bw(p),w.childLanes=Uw(s,re,p),c.memoizedState=$w,c=T);else if(Ys(c),S_(le)){if(re=le.nextSibling&&le.nextSibling.dataset,re)var Te=re.dgst;re=Te,w=Error(r(419)),w.stack="",w.digest=re,qs({value:w,source:null,stack:null}),c=Fw(s,c,p)}else if(rr||bu(s,c,p,!1),re=(p&s.childLanes)!==0,rr||re){if(re=on,re!==null&&(w=p&-p,w=(w&42)!==0?1:mn(w),w=(w&(re.suspendedLanes|p))!==0?0:w,w!==0&&w!==ge.retryLane))throw ge.retryLane=w,Us(s,w),gi(re,s,w),Wj;le.data==="$?"||o_(),c=Fw(s,c,p)}else le.data==="$?"?(c.flags|=192,c.child=s.child,c=null):(s=ge.treeContext,at=da(le.nextSibling),rt=c,yt=!0,an=null,xn=!1,s!==null&&(E[$++]=oe,E[$++]=me,E[$++]=Z,oe=s.id,me=s.overflow,Z=c),c=zw(c,w.children),c.flags|=4096);return c}return T?(Ks(),T=w.fallback,le=c.mode,ge=s.child,Te=ge.sibling,w=qi(ge,{mode:"hidden",children:w.children}),w.subtreeFlags=ge.subtreeFlags&65011712,Te!==null?T=qi(Te,T):(T=Fa(T,le,p,null),T.flags|=2),T.return=c,w.return=c,w.sibling=T,c.child=w,w=T,T=c.child,le=s.child.memoizedState,le===null?le=Bw(p):(ge=le.cachePool,ge!==null?(Te=Gn._currentValue,ge=ge.parent!==Te?{parent:Te,pool:Te}:ge):ge=F4(),le={baseLanes:le.baseLanes|p,cachePool:ge}),T.memoizedState=le,T.childLanes=Uw(s,re,p),c.memoizedState=$w,w):(Ys(c),p=s.child,s=p.sibling,p=qi(p,{mode:"visible",children:w.children}),p.return=c,p.sibling=null,s!==null&&(re=c.deletions,re===null?(c.deletions=[s],c.flags|=16):re.push(s)),c.child=p,c.memoizedState=null,p)}function zw(s,c){return c=gv({mode:"visible",children:c},s.mode),c.return=s,s.child=c}function gv(s,c){return s=$r(22,s,null,c),s.lanes=0,s.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},s}function Fw(s,c,p){return Wc(c,s.child,null,p),s=zw(c,c.pendingProps.children),s.flags|=2,c.memoizedState=null,s}function rP(s,c,p){s.lanes|=c;var w=s.alternate;w!==null&&(w.lanes|=c),yu(s.return,c,p)}function qw(s,c,p,w,T){var k=s.memoizedState;k===null?s.memoizedState={isBackwards:c,rendering:null,renderingStartTime:0,last:w,tail:p,tailMode:T}:(k.isBackwards=c,k.rendering=null,k.renderingStartTime=0,k.last=w,k.tail=p,k.tailMode=T)}function iP(s,c,p){var w=c.pendingProps,T=w.revealOrder,k=w.tail;if(pr(s,c,w.children,p),w=Wn.current,(w&2)!==0)w=w&1|2,c.flags|=128;else{if(s!==null&&(s.flags&128)!==0)e:for(s=c.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&rP(s,p,c);else if(s.tag===19)rP(s,p,c);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===c)break e;for(;s.sibling===null;){if(s.return===null||s.return===c)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}w&=1}switch(G(Wn,w),T){case"forwards":for(p=c.child,T=null;p!==null;)s=p.alternate,s!==null&&dv(s)===null&&(T=p),p=p.sibling;p=T,p===null?(T=c.child,c.child=null):(T=p.sibling,p.sibling=null),qw(c,!1,T,p,k);break;case"backwards":for(p=null,T=c.child,c.child=null;T!==null;){if(s=T.alternate,s!==null&&dv(s)===null){c.child=T;break}s=T.sibling,T.sibling=p,p=T,T=s}qw(c,!0,p,null,k);break;case"together":qw(c,!1,null,null,void 0);break;default:c.memoizedState=null}return c.child}function Uo(s,c,p){if(s!==null&&(c.dependencies=s.dependencies),el|=c.lanes,(p&c.childLanes)===0)if(s!==null){if(bu(s,c,p,!1),(p&c.childLanes)===0)return null}else return null;if(s!==null&&c.child!==s.child)throw Error(r(153));if(c.child!==null){for(s=c.child,p=qi(s,s.pendingProps),c.child=p,p.return=c;s.sibling!==null;)s=s.sibling,p=p.sibling=qi(s,s.pendingProps),p.return=c;p.sibling=null}return c.child}function Vw(s,c){return(s.lanes&c)!==0?!0:(s=s.dependencies,!!(s!==null&&Zg(s)))}function yG(s,c,p){switch(c.tag){case 3:F(c,c.stateNode.containerInfo),qa(c,Gn,s.memoizedState.cache),Fs();break;case 27:case 5:te(c);break;case 4:F(c,c.stateNode.containerInfo);break;case 10:qa(c,c.type,c.memoizedProps.value);break;case 13:var w=c.memoizedState;if(w!==null)return w.dehydrated!==null?(Ys(c),c.flags|=128,null):(p&c.child.childLanes)!==0?nP(s,c,p):(Ys(c),s=Uo(s,c,p),s!==null?s.sibling:null);Ys(c);break;case 19:var T=(s.flags&128)!==0;if(w=(p&c.childLanes)!==0,w||(bu(s,c,p,!1),w=(p&c.childLanes)!==0),T){if(w)return iP(s,c,p);c.flags|=128}if(T=c.memoizedState,T!==null&&(T.rendering=null,T.tail=null,T.lastEffect=null),G(Wn,Wn.current),w)break;return null;case 22:case 23:return c.lanes=0,Xj(s,c,p);case 24:qa(c,Gn,s.memoizedState.cache)}return Uo(s,c,p)}function aP(s,c,p){if(s!==null)if(s.memoizedProps!==c.pendingProps)rr=!0;else{if(!Vw(s,p)&&(c.flags&128)===0)return rr=!1,yG(s,c,p);rr=(s.flags&131072)!==0}else rr=!1,yt&&(c.flags&1048576)!==0&&Me(c,y,c.index);switch(c.lanes=0,c.tag){case 16:e:{s=c.pendingProps;var w=c.elementType,T=w._init;if(w=T(w._payload),c.type=w,typeof w=="function")Ic(w)?(s=Su(w,s),c.tag=1,c=eP(null,c,w,s,p)):(c.tag=0,c=Iw(null,c,w,s,p));else{if(w!=null){if(T=w.$$typeof,T===P){c.tag=11,c=Yj(null,c,w,s,p);break e}else if(T===U){c.tag=14,c=Kj(null,c,w,s,p);break e}}throw c=X(w)||w,Error(r(306,c,""))}}return c;case 0:return Iw(s,c,c.type,c.pendingProps,p);case 1:return w=c.type,T=Su(w,c.pendingProps),eP(s,c,w,T,p);case 3:e:{if(F(c,c.stateNode.containerInfo),s===null)throw Error(r(387));w=c.pendingProps;var k=c.memoizedState;T=k.element,hw(s,c),xh(c,w,null,p);var re=c.memoizedState;if(w=re.cache,qa(c,Gn,w),w!==k.cache&&Bc(c,[Gn],p,!0),_h(),w=re.element,k.isDehydrated)if(k={element:w,isDehydrated:!1,cache:re.cache},c.updateQueue.baseState=k,c.memoizedState=k,c.flags&256){c=tP(s,c,w,p);break e}else if(w!==T){T=Dr(Error(r(424)),c),qs(T),c=tP(s,c,w,p);break e}else{switch(s=c.stateNode.containerInfo,s.nodeType){case 9:s=s.body;break;default:s=s.nodeName==="HTML"?s.ownerDocument.body:s}for(at=da(s.firstChild),rt=c,yt=!0,an=null,xn=!0,p=Ij(c,null,w,p),c.child=p;p;)p.flags=p.flags&-3|4096,p=p.sibling}else{if(Fs(),w===T){c=Uo(s,c,p);break e}pr(s,c,w,p)}c=c.child}return c;case 26:return mv(s,c),s===null?(p=uR(c.type,null,c.pendingProps,null))?c.memoizedState=p:yt||(p=c.type,s=c.pendingProps,w=Pv(ce.current).createElement(p),w[Mt]=c,w[tn]=s,gr(w,p,s),In(w),c.stateNode=w):c.memoizedState=uR(c.type,s.memoizedProps,c.pendingProps,s.memoizedState),null;case 27:return te(c),s===null&&yt&&(w=c.stateNode=oR(c.type,c.pendingProps,ce.current),rt=c,xn=!0,T=at,il(c.type)?(C_=T,at=da(w.firstChild)):at=T),pr(s,c,c.pendingProps.children,p),mv(s,c),s===null&&(c.flags|=4194304),c.child;case 5:return s===null&&yt&&((T=w=at)&&(w=GG(w,c.type,c.pendingProps,xn),w!==null?(c.stateNode=w,rt=c,at=da(w.firstChild),xn=!1,T=!0):T=!1),T||Xr(c)),te(c),T=c.type,k=c.pendingProps,re=s!==null?s.memoizedProps:null,w=k.children,w_(T,k)?w=null:re!==null&&w_(T,re)&&(c.flags|=32),c.memoizedState!==null&&(T=bw(s,c,cG,null,null,p),Vh._currentValue=T),mv(s,c),pr(s,c,w,p),c.child;case 6:return s===null&&yt&&((s=p=at)&&(p=WG(p,c.pendingProps,xn),p!==null?(c.stateNode=p,rt=c,at=null,s=!0):s=!1),s||Xr(c)),null;case 13:return nP(s,c,p);case 4:return F(c,c.stateNode.containerInfo),w=c.pendingProps,s===null?c.child=Wc(c,null,w,p):pr(s,c,w,p),c.child;case 11:return Yj(s,c,c.type,c.pendingProps,p);case 7:return pr(s,c,c.pendingProps,p),c.child;case 8:return pr(s,c,c.pendingProps.children,p),c.child;case 12:return pr(s,c,c.pendingProps.children,p),c.child;case 10:return w=c.pendingProps,qa(c,c.type,w.value),pr(s,c,w.children,p),c.child;case 9:return T=c.type._context,w=c.pendingProps.children,wu(c),T=Or(T),w=w(T),c.flags|=1,pr(s,c,w,p),c.child;case 14:return Kj(s,c,c.type,c.pendingProps,p);case 15:return Zj(s,c,c.type,c.pendingProps,p);case 19:return iP(s,c,p);case 31:return w=c.pendingProps,p=c.mode,w={mode:w.mode,children:w.children},s===null?(p=gv(w,p),p.ref=c.ref,c.child=p,p.return=c,c=p):(p=qi(s.child,w),p.ref=c.ref,c.child=p,p.return=c,c=p),c;case 22:return Xj(s,c,p);case 24:return wu(c),w=Or(Gn),s===null?(T=cw(),T===null&&(T=on,k=lw(),T.pooledCache=k,k.refCount++,k!==null&&(T.pooledCacheLanes|=p),T=k),c.memoizedState={parent:w,cache:T},dw(c),qa(c,Gn,T)):((s.lanes&p)!==0&&(hw(s,c),xh(c,null,null,p),_h()),T=s.memoizedState,k=c.memoizedState,T.parent!==w?(T={parent:w,cache:w},c.memoizedState=T,c.lanes===0&&(c.memoizedState=c.updateQueue.baseState=T),qa(c,Gn,w)):(w=k.cache,qa(c,Gn,w),w!==T.cache&&Bc(c,[Gn],p,!0))),pr(s,c,c.pendingProps.children,p),c.child;case 29:throw c.pendingProps}throw Error(r(156,c.tag))}function zo(s){s.flags|=4}function oP(s,c){if(c.type!=="stylesheet"||(c.state.loading&4)!==0)s.flags&=-16777217;else if(s.flags|=16777216,!pR(c)){if(c=Hi.current,c!==null&&((Lt&4194048)===Lt?Va!==null:(Lt&62914560)!==Lt&&(Lt&536870912)===0||c!==Va))throw bh=fw,q4;s.flags|=8192}}function vv(s,c){c!==null&&(s.flags|=4),s.flags&16384&&(c=s.tag!==22?ii():536870912,s.lanes|=c,Xc|=c)}function jh(s,c){if(!yt)switch(s.tailMode){case"hidden":c=s.tail;for(var p=null;c!==null;)c.alternate!==null&&(p=c),c=c.sibling;p===null?s.tail=null:p.sibling=null;break;case"collapsed":p=s.tail;for(var w=null;p!==null;)p.alternate!==null&&(w=p),p=p.sibling;w===null?c||s.tail===null?s.tail=null:s.tail.sibling=null:w.sibling=null}}function Sn(s){var c=s.alternate!==null&&s.alternate.child===s.child,p=0,w=0;if(c)for(var T=s.child;T!==null;)p|=T.lanes|T.childLanes,w|=T.subtreeFlags&65011712,w|=T.flags&65011712,T.return=s,T=T.sibling;else for(T=s.child;T!==null;)p|=T.lanes|T.childLanes,w|=T.subtreeFlags,w|=T.flags,T.return=s,T=T.sibling;return s.subtreeFlags|=w,s.childLanes=p,c}function bG(s,c,p){var w=c.pendingProps;switch(Qe(c),c.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Sn(c),null;case 1:return Sn(c),null;case 3:return p=c.stateNode,w=null,s!==null&&(w=s.memoizedState.cache),c.memoizedState.cache!==w&&(c.flags|=2048),ca(Gn),q(),p.pendingContext&&(p.context=p.pendingContext,p.pendingContext=null),(s===null||s.child===null)&&(vu(c)?zo(c):s===null||s.memoizedState.isDehydrated&&(c.flags&256)===0||(c.flags|=1024,Kg())),Sn(c),null;case 26:return p=c.memoizedState,s===null?(zo(c),p!==null?(Sn(c),oP(c,p)):(Sn(c),c.flags&=-16777217)):p?p!==s.memoizedState?(zo(c),Sn(c),oP(c,p)):(Sn(c),c.flags&=-16777217):(s.memoizedProps!==w&&zo(c),Sn(c),c.flags&=-16777217),null;case 27:ue(c),p=ce.current;var T=c.type;if(s!==null&&c.stateNode!=null)s.memoizedProps!==w&&zo(c);else{if(!w){if(c.stateNode===null)throw Error(r(166));return Sn(c),null}s=ae.current,vu(c)?Wg(c):(s=oR(T,w,p),c.stateNode=s,zo(c))}return Sn(c),null;case 5:if(ue(c),p=c.type,s!==null&&c.stateNode!=null)s.memoizedProps!==w&&zo(c);else{if(!w){if(c.stateNode===null)throw Error(r(166));return Sn(c),null}if(s=ae.current,vu(c))Wg(c);else{switch(T=Pv(ce.current),s){case 1:s=T.createElementNS("http://www.w3.org/2000/svg",p);break;case 2:s=T.createElementNS("http://www.w3.org/1998/Math/MathML",p);break;default:switch(p){case"svg":s=T.createElementNS("http://www.w3.org/2000/svg",p);break;case"math":s=T.createElementNS("http://www.w3.org/1998/Math/MathML",p);break;case"script":s=T.createElement("div"),s.innerHTML="<script><\/script>",s=s.removeChild(s.firstChild);break;case"select":s=typeof w.is=="string"?T.createElement("select",{is:w.is}):T.createElement("select"),w.multiple?s.multiple=!0:w.size&&(s.size=w.size);break;default:s=typeof w.is=="string"?T.createElement(p,{is:w.is}):T.createElement(p)}}s[Mt]=c,s[tn]=w;e:for(T=c.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===c)break e;for(;T.sibling===null;){if(T.return===null||T.return===c)break e;T=T.return}T.sibling.return=T.return,T=T.sibling}c.stateNode=s;e:switch(gr(s,p,w),p){case"button":case"input":case"select":case"textarea":s=!!w.autoFocus;break e;case"img":s=!0;break e;default:s=!1}s&&zo(c)}}return Sn(c),c.flags&=-16777217,null;case 6:if(s&&c.stateNode!=null)s.memoizedProps!==w&&zo(c);else{if(typeof w!="string"&&c.stateNode===null)throw Error(r(166));if(s=ce.current,vu(c)){if(s=c.stateNode,p=c.memoizedProps,w=null,T=rt,T!==null)switch(T.tag){case 27:case 5:w=T.memoizedProps}s[Mt]=c,s=!!(s.nodeValue===p||w!==null&&w.suppressHydrationWarning===!0||JP(s.nodeValue,p)),s||Xr(c)}else s=Pv(s).createTextNode(w),s[Mt]=c,c.stateNode=s}return Sn(c),null;case 13:if(w=c.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(T=vu(c),w!==null&&w.dehydrated!==null){if(s===null){if(!T)throw Error(r(318));if(T=c.memoizedState,T=T!==null?T.dehydrated:null,!T)throw Error(r(317));T[Mt]=c}else Fs(),(c.flags&128)===0&&(c.memoizedState=null),c.flags|=4;Sn(c),T=!1}else T=Kg(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=T),T=!0;if(!T)return c.flags&256?(Bo(c),c):(Bo(c),null)}if(Bo(c),(c.flags&128)!==0)return c.lanes=p,c;if(p=w!==null,s=s!==null&&s.memoizedState!==null,p){w=c.child,T=null,w.alternate!==null&&w.alternate.memoizedState!==null&&w.alternate.memoizedState.cachePool!==null&&(T=w.alternate.memoizedState.cachePool.pool);var k=null;w.memoizedState!==null&&w.memoizedState.cachePool!==null&&(k=w.memoizedState.cachePool.pool),k!==T&&(w.flags|=2048)}return p!==s&&p&&(c.child.flags|=8192),vv(c,c.updateQueue),Sn(c),null;case 4:return q(),s===null&&m_(c.stateNode.containerInfo),Sn(c),null;case 10:return ca(c.type),Sn(c),null;case 19:if(Q(Wn),T=c.memoizedState,T===null)return Sn(c),null;if(w=(c.flags&128)!==0,k=T.rendering,k===null)if(w)jh(T,!1);else{if(En!==0||s!==null&&(s.flags&128)!==0)for(s=c.child;s!==null;){if(k=dv(s),k!==null){for(c.flags|=128,jh(T,!1),s=k.updateQueue,c.updateQueue=s,vv(c,s),c.subtreeFlags=0,s=p,p=c.child;p!==null;)ph(p,s),p=p.sibling;return G(Wn,Wn.current&1|2),c.child}s=s.sibling}T.tail!==null&&xe()>wv&&(c.flags|=128,w=!0,jh(T,!1),c.lanes=4194304)}else{if(!w)if(s=dv(k),s!==null){if(c.flags|=128,w=!0,s=s.updateQueue,c.updateQueue=s,vv(c,s),jh(T,!0),T.tail===null&&T.tailMode==="hidden"&&!k.alternate&&!yt)return Sn(c),null}else 2*xe()-T.renderingStartTime>wv&&p!==536870912&&(c.flags|=128,w=!0,jh(T,!1),c.lanes=4194304);T.isBackwards?(k.sibling=c.child,c.child=k):(s=T.last,s!==null?s.sibling=k:c.child=k,T.last=k)}return T.tail!==null?(c=T.tail,T.rendering=c,T.tail=c.sibling,T.renderingStartTime=xe(),c.sibling=null,s=Wn.current,G(Wn,w?s&1|2:s&1),c):(Sn(c),null);case 22:case 23:return Bo(c),vw(),w=c.memoizedState!==null,s!==null?s.memoizedState!==null!==w&&(c.flags|=8192):w&&(c.flags|=8192),w?(p&536870912)!==0&&(c.flags&128)===0&&(Sn(c),c.subtreeFlags&6&&(c.flags|=8192)):Sn(c),p=c.updateQueue,p!==null&&vv(c,p.retryQueue),p=null,s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(p=s.memoizedState.cachePool.pool),w=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(w=c.memoizedState.cachePool.pool),w!==p&&(c.flags|=2048),s!==null&&Q(_u),null;case 24:return p=null,s!==null&&(p=s.memoizedState.cache),c.memoizedState.cache!==p&&(c.flags|=2048),ca(Gn),Sn(c),null;case 25:return null;case 30:return null}throw Error(r(156,c.tag))}function wG(s,c){switch(Qe(c),c.tag){case 1:return s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 3:return ca(Gn),q(),s=c.flags,(s&65536)!==0&&(s&128)===0?(c.flags=s&-65537|128,c):null;case 26:case 27:case 5:return ue(c),null;case 13:if(Bo(c),s=c.memoizedState,s!==null&&s.dehydrated!==null){if(c.alternate===null)throw Error(r(340));Fs()}return s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 19:return Q(Wn),null;case 4:return q(),null;case 10:return ca(c.type),null;case 22:case 23:return Bo(c),vw(),s!==null&&Q(_u),s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 24:return ca(Gn),null;case 25:return null;default:return null}}function sP(s,c){switch(Qe(c),c.tag){case 3:ca(Gn),q();break;case 26:case 27:case 5:ue(c);break;case 4:q();break;case 13:Bo(c);break;case 19:Q(Wn);break;case 10:ca(c.type);break;case 22:case 23:Bo(c),vw(),s!==null&&Q(_u);break;case 24:ca(Gn)}}function Ph(s,c){try{var p=c.updateQueue,w=p!==null?p.lastEffect:null;if(w!==null){var T=w.next;p=T;do{if((p.tag&s)===s){w=void 0;var k=p.create,re=p.inst;w=k(),re.destroy=w}p=p.next}while(p!==T)}}catch(le){Xt(c,c.return,le)}}function Zs(s,c,p){try{var w=c.updateQueue,T=w!==null?w.lastEffect:null;if(T!==null){var k=T.next;w=k;do{if((w.tag&s)===s){var re=w.inst,le=re.destroy;if(le!==void 0){re.destroy=void 0,T=c;var ge=p,Te=le;try{Te()}catch(Ie){Xt(T,ge,Ie)}}}w=w.next}while(w!==k)}}catch(Ie){Xt(c,c.return,Ie)}}function lP(s){var c=s.updateQueue;if(c!==null){var p=s.stateNode;try{K4(c,p)}catch(w){Xt(s,s.return,w)}}}function uP(s,c,p){p.props=Su(s.type,s.memoizedProps),p.state=s.memoizedState;try{p.componentWillUnmount()}catch(w){Xt(s,c,w)}}function Rh(s,c){try{var p=s.ref;if(p!==null){switch(s.tag){case 26:case 27:case 5:var w=s.stateNode;break;case 30:w=s.stateNode;break;default:w=s.stateNode}typeof p=="function"?s.refCleanup=p(w):p.current=w}}catch(T){Xt(s,c,T)}}function Ha(s,c){var p=s.ref,w=s.refCleanup;if(p!==null)if(typeof w=="function")try{w()}catch(T){Xt(s,c,T)}finally{s.refCleanup=null,s=s.alternate,s!=null&&(s.refCleanup=null)}else if(typeof p=="function")try{p(null)}catch(T){Xt(s,c,T)}else p.current=null}function cP(s){var c=s.type,p=s.memoizedProps,w=s.stateNode;try{e:switch(c){case"button":case"input":case"select":case"textarea":p.autoFocus&&w.focus();break e;case"img":p.src?w.src=p.src:p.srcSet&&(w.srcset=p.srcSet)}}catch(T){Xt(s,s.return,T)}}function Hw(s,c,p){try{var w=s.stateNode;zG(w,s.type,p,c),w[tn]=c}catch(T){Xt(s,s.return,T)}}function fP(s){return s.tag===5||s.tag===3||s.tag===26||s.tag===27&&il(s.type)||s.tag===4}function Gw(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||fP(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.tag===27&&il(s.type)||s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function Ww(s,c,p){var w=s.tag;if(w===5||w===6)s=s.stateNode,c?(p.nodeType===9?p.body:p.nodeName==="HTML"?p.ownerDocument.body:p).insertBefore(s,c):(c=p.nodeType===9?p.body:p.nodeName==="HTML"?p.ownerDocument.body:p,c.appendChild(s),p=p._reactRootContainer,p!=null||c.onclick!==null||(c.onclick=jv));else if(w!==4&&(w===27&&il(s.type)&&(p=s.stateNode,c=null),s=s.child,s!==null))for(Ww(s,c,p),s=s.sibling;s!==null;)Ww(s,c,p),s=s.sibling}function yv(s,c,p){var w=s.tag;if(w===5||w===6)s=s.stateNode,c?p.insertBefore(s,c):p.appendChild(s);else if(w!==4&&(w===27&&il(s.type)&&(p=s.stateNode),s=s.child,s!==null))for(yv(s,c,p),s=s.sibling;s!==null;)yv(s,c,p),s=s.sibling}function dP(s){var c=s.stateNode,p=s.memoizedProps;try{for(var w=s.type,T=c.attributes;T.length;)c.removeAttributeNode(T[0]);gr(c,w,p),c[Mt]=s,c[tn]=p}catch(k){Xt(s,s.return,k)}}var Fo=!1,Ln=!1,Yw=!1,hP=typeof WeakSet=="function"?WeakSet:Set,ir=null;function _G(s,c){if(s=s.containerInfo,y_=Dv,s=cu(s),fu(s)){if("selectionStart"in s)var p={start:s.selectionStart,end:s.selectionEnd};else e:{p=(p=s.ownerDocument)&&p.defaultView||window;var w=p.getSelection&&p.getSelection();if(w&&w.rangeCount!==0){p=w.anchorNode;var T=w.anchorOffset,k=w.focusNode;w=w.focusOffset;try{p.nodeType,k.nodeType}catch{p=null;break e}var re=0,le=-1,ge=-1,Te=0,Ie=0,Ue=s,Pe=null;t:for(;;){for(var Re;Ue!==p||T!==0&&Ue.nodeType!==3||(le=re+T),Ue!==k||w!==0&&Ue.nodeType!==3||(ge=re+w),Ue.nodeType===3&&(re+=Ue.nodeValue.length),(Re=Ue.firstChild)!==null;)Pe=Ue,Ue=Re;for(;;){if(Ue===s)break t;if(Pe===p&&++Te===T&&(le=re),Pe===k&&++Ie===w&&(ge=re),(Re=Ue.nextSibling)!==null)break;Ue=Pe,Pe=Ue.parentNode}Ue=Re}p=le===-1||ge===-1?null:{start:le,end:ge}}else p=null}p=p||{start:0,end:0}}else p=null;for(b_={focusedElem:s,selectionRange:p},Dv=!1,ir=c;ir!==null;)if(c=ir,s=c.child,(c.subtreeFlags&1024)!==0&&s!==null)s.return=c,ir=s;else for(;ir!==null;){switch(c=ir,k=c.alternate,s=c.flags,c.tag){case 0:break;case 11:case 15:break;case 1:if((s&1024)!==0&&k!==null){s=void 0,p=c,T=k.memoizedProps,k=k.memoizedState,w=p.stateNode;try{var vt=Su(p.type,T,p.elementType===p.type);s=w.getSnapshotBeforeUpdate(vt,k),w.__reactInternalSnapshotBeforeUpdate=s}catch(dt){Xt(p,p.return,dt)}}break;case 3:if((s&1024)!==0){if(s=c.stateNode.containerInfo,p=s.nodeType,p===9)x_(s);else if(p===1)switch(s.nodeName){case"HEAD":case"HTML":case"BODY":x_(s);break;default:s.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((s&1024)!==0)throw Error(r(163))}if(s=c.sibling,s!==null){s.return=c.return,ir=s;break}ir=c.return}}function pP(s,c,p){var w=p.flags;switch(p.tag){case 0:case 11:case 15:Xs(s,p),w&4&&Ph(5,p);break;case 1:if(Xs(s,p),w&4)if(s=p.stateNode,c===null)try{s.componentDidMount()}catch(re){Xt(p,p.return,re)}else{var T=Su(p.type,c.memoizedProps);c=c.memoizedState;try{s.componentDidUpdate(T,c,s.__reactInternalSnapshotBeforeUpdate)}catch(re){Xt(p,p.return,re)}}w&64&&lP(p),w&512&&Rh(p,p.return);break;case 3:if(Xs(s,p),w&64&&(s=p.updateQueue,s!==null)){if(c=null,p.child!==null)switch(p.child.tag){case 27:case 5:c=p.child.stateNode;break;case 1:c=p.child.stateNode}try{K4(s,c)}catch(re){Xt(p,p.return,re)}}break;case 27:c===null&&w&4&&dP(p);case 26:case 5:Xs(s,p),c===null&&w&4&&cP(p),w&512&&Rh(p,p.return);break;case 12:Xs(s,p);break;case 13:Xs(s,p),w&4&&vP(s,p),w&64&&(s=p.memoizedState,s!==null&&(s=s.dehydrated,s!==null&&(p=PG.bind(null,p),YG(s,p))));break;case 22:if(w=p.memoizedState!==null||Fo,!w){c=c!==null&&c.memoizedState!==null||Ln,T=Fo;var k=Ln;Fo=w,(Ln=c)&&!k?Qs(s,p,(p.subtreeFlags&8772)!==0):Xs(s,p),Fo=T,Ln=k}break;case 30:break;default:Xs(s,p)}}function mP(s){var c=s.alternate;c!==null&&(s.alternate=null,mP(c)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(c=s.stateNode,c!==null&&wc(c)),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}var vn=null,Jr=!1;function qo(s,c,p){for(p=p.child;p!==null;)gP(s,c,p),p=p.sibling}function gP(s,c,p){if(je&&typeof je.onCommitFiberUnmount=="function")try{je.onCommitFiberUnmount(Ne,p)}catch{}switch(p.tag){case 26:Ln||Ha(p,c),qo(s,c,p),p.memoizedState?p.memoizedState.count--:p.stateNode&&(p=p.stateNode,p.parentNode.removeChild(p));break;case 27:Ln||Ha(p,c);var w=vn,T=Jr;il(p.type)&&(vn=p.stateNode,Jr=!1),qo(s,c,p),Uh(p.stateNode),vn=w,Jr=T;break;case 5:Ln||Ha(p,c);case 6:if(w=vn,T=Jr,vn=null,qo(s,c,p),vn=w,Jr=T,vn!==null)if(Jr)try{(vn.nodeType===9?vn.body:vn.nodeName==="HTML"?vn.ownerDocument.body:vn).removeChild(p.stateNode)}catch(k){Xt(p,c,k)}else try{vn.removeChild(p.stateNode)}catch(k){Xt(p,c,k)}break;case 18:vn!==null&&(Jr?(s=vn,iR(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,p.stateNode),Yh(s)):iR(vn,p.stateNode));break;case 4:w=vn,T=Jr,vn=p.stateNode.containerInfo,Jr=!0,qo(s,c,p),vn=w,Jr=T;break;case 0:case 11:case 14:case 15:Ln||Zs(2,p,c),Ln||Zs(4,p,c),qo(s,c,p);break;case 1:Ln||(Ha(p,c),w=p.stateNode,typeof w.componentWillUnmount=="function"&&uP(p,c,w)),qo(s,c,p);break;case 21:qo(s,c,p);break;case 22:Ln=(w=Ln)||p.memoizedState!==null,qo(s,c,p),Ln=w;break;default:qo(s,c,p)}}function vP(s,c){if(c.memoizedState===null&&(s=c.alternate,s!==null&&(s=s.memoizedState,s!==null&&(s=s.dehydrated,s!==null))))try{Yh(s)}catch(p){Xt(c,c.return,p)}}function xG(s){switch(s.tag){case 13:case 19:var c=s.stateNode;return c===null&&(c=s.stateNode=new hP),c;case 22:return s=s.stateNode,c=s._retryCache,c===null&&(c=s._retryCache=new hP),c;default:throw Error(r(435,s.tag))}}function Kw(s,c){var p=xG(s);c.forEach(function(w){var T=RG.bind(null,s,w);p.has(w)||(p.add(w),w.then(T,T))})}function di(s,c){var p=c.deletions;if(p!==null)for(var w=0;w<p.length;w++){var T=p[w],k=s,re=c,le=re;e:for(;le!==null;){switch(le.tag){case 27:if(il(le.type)){vn=le.stateNode,Jr=!1;break e}break;case 5:vn=le.stateNode,Jr=!1;break e;case 3:case 4:vn=le.stateNode.containerInfo,Jr=!0;break e}le=le.return}if(vn===null)throw Error(r(160));gP(k,re,T),vn=null,Jr=!1,k=T.alternate,k!==null&&(k.return=null),T.return=null}if(c.subtreeFlags&13878)for(c=c.child;c!==null;)yP(c,s),c=c.sibling}var fa=null;function yP(s,c){var p=s.alternate,w=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:di(c,s),hi(s),w&4&&(Zs(3,s,s.return),Ph(3,s),Zs(5,s,s.return));break;case 1:di(c,s),hi(s),w&512&&(Ln||p===null||Ha(p,p.return)),w&64&&Fo&&(s=s.updateQueue,s!==null&&(w=s.callbacks,w!==null&&(p=s.shared.hiddenCallbacks,s.shared.hiddenCallbacks=p===null?w:p.concat(w))));break;case 26:var T=fa;if(di(c,s),hi(s),w&512&&(Ln||p===null||Ha(p,p.return)),w&4){var k=p!==null?p.memoizedState:null;if(w=s.memoizedState,p===null)if(w===null)if(s.stateNode===null){e:{w=s.type,p=s.memoizedProps,T=T.ownerDocument||T;t:switch(w){case"title":k=T.getElementsByTagName("title")[0],(!k||k[_s]||k[Mt]||k.namespaceURI==="http://www.w3.org/2000/svg"||k.hasAttribute("itemprop"))&&(k=T.createElement(w),T.head.insertBefore(k,T.querySelector("head > title"))),gr(k,w,p),k[Mt]=s,In(k),w=k;break e;case"link":var re=dR("link","href",T).get(w+(p.href||""));if(re){for(var le=0;le<re.length;le++)if(k=re[le],k.getAttribute("href")===(p.href==null||p.href===""?null:p.href)&&k.getAttribute("rel")===(p.rel==null?null:p.rel)&&k.getAttribute("title")===(p.title==null?null:p.title)&&k.getAttribute("crossorigin")===(p.crossOrigin==null?null:p.crossOrigin)){re.splice(le,1);break t}}k=T.createElement(w),gr(k,w,p),T.head.appendChild(k);break;case"meta":if(re=dR("meta","content",T).get(w+(p.content||""))){for(le=0;le<re.length;le++)if(k=re[le],k.getAttribute("content")===(p.content==null?null:""+p.content)&&k.getAttribute("name")===(p.name==null?null:p.name)&&k.getAttribute("property")===(p.property==null?null:p.property)&&k.getAttribute("http-equiv")===(p.httpEquiv==null?null:p.httpEquiv)&&k.getAttribute("charset")===(p.charSet==null?null:p.charSet)){re.splice(le,1);break t}}k=T.createElement(w),gr(k,w,p),T.head.appendChild(k);break;default:throw Error(r(468,w))}k[Mt]=s,In(k),w=k}s.stateNode=w}else hR(T,s.type,s.stateNode);else s.stateNode=fR(T,w,s.memoizedProps);else k!==w?(k===null?p.stateNode!==null&&(p=p.stateNode,p.parentNode.removeChild(p)):k.count--,w===null?hR(T,s.type,s.stateNode):fR(T,w,s.memoizedProps)):w===null&&s.stateNode!==null&&Hw(s,s.memoizedProps,p.memoizedProps)}break;case 27:di(c,s),hi(s),w&512&&(Ln||p===null||Ha(p,p.return)),p!==null&&w&4&&Hw(s,s.memoizedProps,p.memoizedProps);break;case 5:if(di(c,s),hi(s),w&512&&(Ln||p===null||Ha(p,p.return)),s.flags&32){T=s.stateNode;try{$i(T,"")}catch(Re){Xt(s,s.return,Re)}}w&4&&s.stateNode!=null&&(T=s.memoizedProps,Hw(s,T,p!==null?p.memoizedProps:T)),w&1024&&(Yw=!0);break;case 6:if(di(c,s),hi(s),w&4){if(s.stateNode===null)throw Error(r(162));w=s.memoizedProps,p=s.stateNode;try{p.nodeValue=w}catch(Re){Xt(s,s.return,Re)}}break;case 3:if(Nv=null,T=fa,fa=Rv(c.containerInfo),di(c,s),fa=T,hi(s),w&4&&p!==null&&p.memoizedState.isDehydrated)try{Yh(c.containerInfo)}catch(Re){Xt(s,s.return,Re)}Yw&&(Yw=!1,bP(s));break;case 4:w=fa,fa=Rv(s.stateNode.containerInfo),di(c,s),hi(s),fa=w;break;case 12:di(c,s),hi(s);break;case 13:di(c,s),hi(s),s.child.flags&8192&&s.memoizedState!==null!=(p!==null&&p.memoizedState!==null)&&(t_=xe()),w&4&&(w=s.updateQueue,w!==null&&(s.updateQueue=null,Kw(s,w)));break;case 22:T=s.memoizedState!==null;var ge=p!==null&&p.memoizedState!==null,Te=Fo,Ie=Ln;if(Fo=Te||T,Ln=Ie||ge,di(c,s),Ln=Ie,Fo=Te,hi(s),w&8192)e:for(c=s.stateNode,c._visibility=T?c._visibility&-2:c._visibility|1,T&&(p===null||ge||Fo||Ln||Cu(s)),p=null,c=s;;){if(c.tag===5||c.tag===26){if(p===null){ge=p=c;try{if(k=ge.stateNode,T)re=k.style,typeof re.setProperty=="function"?re.setProperty("display","none","important"):re.display="none";else{le=ge.stateNode;var Ue=ge.memoizedProps.style,Pe=Ue!=null&&Ue.hasOwnProperty("display")?Ue.display:null;le.style.display=Pe==null||typeof Pe=="boolean"?"":(""+Pe).trim()}}catch(Re){Xt(ge,ge.return,Re)}}}else if(c.tag===6){if(p===null){ge=c;try{ge.stateNode.nodeValue=T?"":ge.memoizedProps}catch(Re){Xt(ge,ge.return,Re)}}}else if((c.tag!==22&&c.tag!==23||c.memoizedState===null||c===s)&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===s)break e;for(;c.sibling===null;){if(c.return===null||c.return===s)break e;p===c&&(p=null),c=c.return}p===c&&(p=null),c.sibling.return=c.return,c=c.sibling}w&4&&(w=s.updateQueue,w!==null&&(p=w.retryQueue,p!==null&&(w.retryQueue=null,Kw(s,p))));break;case 19:di(c,s),hi(s),w&4&&(w=s.updateQueue,w!==null&&(s.updateQueue=null,Kw(s,w)));break;case 30:break;case 21:break;default:di(c,s),hi(s)}}function hi(s){var c=s.flags;if(c&2){try{for(var p,w=s.return;w!==null;){if(fP(w)){p=w;break}w=w.return}if(p==null)throw Error(r(160));switch(p.tag){case 27:var T=p.stateNode,k=Gw(s);yv(s,k,T);break;case 5:var re=p.stateNode;p.flags&32&&($i(re,""),p.flags&=-33);var le=Gw(s);yv(s,le,re);break;case 3:case 4:var ge=p.stateNode.containerInfo,Te=Gw(s);Ww(s,Te,ge);break;default:throw Error(r(161))}}catch(Ie){Xt(s,s.return,Ie)}s.flags&=-3}c&4096&&(s.flags&=-4097)}function bP(s){if(s.subtreeFlags&1024)for(s=s.child;s!==null;){var c=s;bP(c),c.tag===5&&c.flags&1024&&c.stateNode.reset(),s=s.sibling}}function Xs(s,c){if(c.subtreeFlags&8772)for(c=c.child;c!==null;)pP(s,c.alternate,c),c=c.sibling}function Cu(s){for(s=s.child;s!==null;){var c=s;switch(c.tag){case 0:case 11:case 14:case 15:Zs(4,c,c.return),Cu(c);break;case 1:Ha(c,c.return);var p=c.stateNode;typeof p.componentWillUnmount=="function"&&uP(c,c.return,p),Cu(c);break;case 27:Uh(c.stateNode);case 26:case 5:Ha(c,c.return),Cu(c);break;case 22:c.memoizedState===null&&Cu(c);break;case 30:Cu(c);break;default:Cu(c)}s=s.sibling}}function Qs(s,c,p){for(p=p&&(c.subtreeFlags&8772)!==0,c=c.child;c!==null;){var w=c.alternate,T=s,k=c,re=k.flags;switch(k.tag){case 0:case 11:case 15:Qs(T,k,p),Ph(4,k);break;case 1:if(Qs(T,k,p),w=k,T=w.stateNode,typeof T.componentDidMount=="function")try{T.componentDidMount()}catch(Te){Xt(w,w.return,Te)}if(w=k,T=w.updateQueue,T!==null){var le=w.stateNode;try{var ge=T.shared.hiddenCallbacks;if(ge!==null)for(T.shared.hiddenCallbacks=null,T=0;T<ge.length;T++)Y4(ge[T],le)}catch(Te){Xt(w,w.return,Te)}}p&&re&64&&lP(k),Rh(k,k.return);break;case 27:dP(k);case 26:case 5:Qs(T,k,p),p&&w===null&&re&4&&cP(k),Rh(k,k.return);break;case 12:Qs(T,k,p);break;case 13:Qs(T,k,p),p&&re&4&&vP(T,k);break;case 22:k.memoizedState===null&&Qs(T,k,p),Rh(k,k.return);break;case 30:break;default:Qs(T,k,p)}c=c.sibling}}function Zw(s,c){var p=null;s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(p=s.memoizedState.cachePool.pool),s=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(s=c.memoizedState.cachePool.pool),s!==p&&(s!=null&&s.refCount++,p!=null&&gh(p))}function Xw(s,c){s=null,c.alternate!==null&&(s=c.alternate.memoizedState.cache),c=c.memoizedState.cache,c!==s&&(c.refCount++,s!=null&&gh(s))}function Ga(s,c,p,w){if(c.subtreeFlags&10256)for(c=c.child;c!==null;)wP(s,c,p,w),c=c.sibling}function wP(s,c,p,w){var T=c.flags;switch(c.tag){case 0:case 11:case 15:Ga(s,c,p,w),T&2048&&Ph(9,c);break;case 1:Ga(s,c,p,w);break;case 3:Ga(s,c,p,w),T&2048&&(s=null,c.alternate!==null&&(s=c.alternate.memoizedState.cache),c=c.memoizedState.cache,c!==s&&(c.refCount++,s!=null&&gh(s)));break;case 12:if(T&2048){Ga(s,c,p,w),s=c.stateNode;try{var k=c.memoizedProps,re=k.id,le=k.onPostCommit;typeof le=="function"&&le(re,c.alternate===null?"mount":"update",s.passiveEffectDuration,-0)}catch(ge){Xt(c,c.return,ge)}}else Ga(s,c,p,w);break;case 13:Ga(s,c,p,w);break;case 23:break;case 22:k=c.stateNode,re=c.alternate,c.memoizedState!==null?k._visibility&2?Ga(s,c,p,w):Mh(s,c):k._visibility&2?Ga(s,c,p,w):(k._visibility|=2,Yc(s,c,p,w,(c.subtreeFlags&10256)!==0)),T&2048&&Zw(re,c);break;case 24:Ga(s,c,p,w),T&2048&&Xw(c.alternate,c);break;default:Ga(s,c,p,w)}}function Yc(s,c,p,w,T){for(T=T&&(c.subtreeFlags&10256)!==0,c=c.child;c!==null;){var k=s,re=c,le=p,ge=w,Te=re.flags;switch(re.tag){case 0:case 11:case 15:Yc(k,re,le,ge,T),Ph(8,re);break;case 23:break;case 22:var Ie=re.stateNode;re.memoizedState!==null?Ie._visibility&2?Yc(k,re,le,ge,T):Mh(k,re):(Ie._visibility|=2,Yc(k,re,le,ge,T)),T&&Te&2048&&Zw(re.alternate,re);break;case 24:Yc(k,re,le,ge,T),T&&Te&2048&&Xw(re.alternate,re);break;default:Yc(k,re,le,ge,T)}c=c.sibling}}function Mh(s,c){if(c.subtreeFlags&10256)for(c=c.child;c!==null;){var p=s,w=c,T=w.flags;switch(w.tag){case 22:Mh(p,w),T&2048&&Zw(w.alternate,w);break;case 24:Mh(p,w),T&2048&&Xw(w.alternate,w);break;default:Mh(p,w)}c=c.sibling}}var Nh=8192;function Kc(s){if(s.subtreeFlags&Nh)for(s=s.child;s!==null;)_P(s),s=s.sibling}function _P(s){switch(s.tag){case 26:Kc(s),s.flags&Nh&&s.memoizedState!==null&&sW(fa,s.memoizedState,s.memoizedProps);break;case 5:Kc(s);break;case 3:case 4:var c=fa;fa=Rv(s.stateNode.containerInfo),Kc(s),fa=c;break;case 22:s.memoizedState===null&&(c=s.alternate,c!==null&&c.memoizedState!==null?(c=Nh,Nh=16777216,Kc(s),Nh=c):Kc(s));break;default:Kc(s)}}function xP(s){var c=s.alternate;if(c!==null&&(s=c.child,s!==null)){c.child=null;do c=s.sibling,s.sibling=null,s=c;while(s!==null)}}function Lh(s){var c=s.deletions;if((s.flags&16)!==0){if(c!==null)for(var p=0;p<c.length;p++){var w=c[p];ir=w,CP(w,s)}xP(s)}if(s.subtreeFlags&10256)for(s=s.child;s!==null;)SP(s),s=s.sibling}function SP(s){switch(s.tag){case 0:case 11:case 15:Lh(s),s.flags&2048&&Zs(9,s,s.return);break;case 3:Lh(s);break;case 12:Lh(s);break;case 22:var c=s.stateNode;s.memoizedState!==null&&c._visibility&2&&(s.return===null||s.return.tag!==13)?(c._visibility&=-3,bv(s)):Lh(s);break;default:Lh(s)}}function bv(s){var c=s.deletions;if((s.flags&16)!==0){if(c!==null)for(var p=0;p<c.length;p++){var w=c[p];ir=w,CP(w,s)}xP(s)}for(s=s.child;s!==null;){switch(c=s,c.tag){case 0:case 11:case 15:Zs(8,c,c.return),bv(c);break;case 22:p=c.stateNode,p._visibility&2&&(p._visibility&=-3,bv(c));break;default:bv(c)}s=s.sibling}}function CP(s,c){for(;ir!==null;){var p=ir;switch(p.tag){case 0:case 11:case 15:Zs(8,p,c);break;case 23:case 22:if(p.memoizedState!==null&&p.memoizedState.cachePool!==null){var w=p.memoizedState.cachePool.pool;w!=null&&w.refCount++}break;case 24:gh(p.memoizedState.cache)}if(w=p.child,w!==null)w.return=p,ir=w;else e:for(p=s;ir!==null;){w=ir;var T=w.sibling,k=w.return;if(mP(w),w===p){ir=null;break e}if(T!==null){T.return=k,ir=T;break e}ir=k}}}var SG={getCacheForType:function(s){var c=Or(Gn),p=c.data.get(s);return p===void 0&&(p=s(),c.data.set(s,p)),p}},CG=typeof WeakMap=="function"?WeakMap:Map,Vt=0,on=null,Tt=null,Lt=0,Ht=0,pi=null,Js=!1,Zc=!1,Qw=!1,Vo=0,En=0,el=0,Au=0,Jw=0,Gi=0,Xc=0,kh=null,ei=null,e_=!1,t_=0,wv=1/0,_v=null,tl=null,mr=0,nl=null,Qc=null,Jc=0,n_=0,r_=null,AP=null,Dh=0,i_=null;function mi(){if((Vt&2)!==0&&Lt!==0)return Lt&-Lt;if(H.T!==null){var s=Uc;return s!==0?s:f_()}return Jn()}function EP(){Gi===0&&(Gi=(Lt&536870912)===0||yt?ys():536870912);var s=Hi.current;return s!==null&&(s.flags|=32),Gi}function gi(s,c,p){(s===on&&(Ht===2||Ht===9)||s.cancelPendingCommit!==null)&&(ef(s,0),rl(s,Lt,Gi,!1)),La(s,p),((Vt&2)===0||s!==on)&&(s===on&&((Vt&2)===0&&(Au|=p),En===4&&rl(s,Lt,Gi,!1)),Wa(s))}function OP(s,c,p){if((Vt&6)!==0)throw Error(r(327));var w=!p&&(c&124)===0&&(c&s.expiredLanes)===0||Cr(s,c),T=w?OG(s,c):s_(s,c,!0),k=w;do{if(T===0){Zc&&!w&&rl(s,c,0,!1);break}else{if(p=s.current.alternate,k&&!AG(p)){T=s_(s,c,!1),k=!1;continue}if(T===2){if(k=c,s.errorRecoveryDisabledLanes&k)var re=0;else re=s.pendingLanes&-536870913,re=re!==0?re:re&536870912?536870912:0;if(re!==0){c=re;e:{var le=s;T=kh;var ge=le.current.memoizedState.isDehydrated;if(ge&&(ef(le,re).flags|=256),re=s_(le,re,!1),re!==2){if(Qw&&!ge){le.errorRecoveryDisabledLanes|=k,Au|=k,T=4;break e}k=ei,ei=T,k!==null&&(ei===null?ei=k:ei.push.apply(ei,k))}T=re}if(k=!1,T!==2)continue}}if(T===1){ef(s,0),rl(s,c,0,!0);break}e:{switch(w=s,k=T,k){case 0:case 1:throw Error(r(345));case 4:if((c&4194048)!==c)break;case 6:rl(w,c,Gi,!Js);break e;case 2:ei=null;break;case 3:case 5:break;default:throw Error(r(329))}if((c&62914560)===c&&(T=t_+300-xe(),10<T)){if(rl(w,c,Gi,!Js),It(w,0,!0)!==0)break e;w.timeoutHandle=nR(TP.bind(null,w,p,ei,_v,e_,c,Gi,Au,Xc,Js,k,2,-0,0),T);break e}TP(w,p,ei,_v,e_,c,Gi,Au,Xc,Js,k,0,-0,0)}}break}while(!0);Wa(s)}function TP(s,c,p,w,T,k,re,le,ge,Te,Ie,Ue,Pe,Re){if(s.timeoutHandle=-1,Ue=c.subtreeFlags,(Ue&8192||(Ue&16785408)===16785408)&&(qh={stylesheets:null,count:0,unsuspend:oW},_P(c),Ue=lW(),Ue!==null)){s.cancelPendingCommit=Ue(kP.bind(null,s,c,k,p,w,T,re,le,ge,Ie,1,Pe,Re)),rl(s,k,re,!Te);return}kP(s,c,k,p,w,T,re,le,ge)}function AG(s){for(var c=s;;){var p=c.tag;if((p===0||p===11||p===15)&&c.flags&16384&&(p=c.updateQueue,p!==null&&(p=p.stores,p!==null)))for(var w=0;w<p.length;w++){var T=p[w],k=T.getSnapshot;T=T.value;try{if(!Lr(k(),T))return!1}catch{return!1}}if(p=c.child,c.subtreeFlags&16384&&p!==null)p.return=c,c=p;else{if(c===s)break;for(;c.sibling===null;){if(c.return===null||c.return===s)return!0;c=c.return}c.sibling.return=c.return,c=c.sibling}}return!0}function rl(s,c,p,w){c&=~Jw,c&=~Au,s.suspendedLanes|=c,s.pingedLanes&=~c,w&&(s.warmLanes|=c),w=s.expirationTimes;for(var T=c;0<T;){var k=31-Ge(T),re=1<<k;w[k]=-1,T&=~re}p!==0&&ws(s,p,c)}function xv(){return(Vt&6)===0?(Ih(0),!1):!0}function a_(){if(Tt!==null){if(Ht===0)var s=Tt.return;else s=Tt,ua=Vi=null,xw(s),Gc=null,Oh=0,s=Tt;for(;s!==null;)sP(s.alternate,s),s=s.return;Tt=null}}function ef(s,c){var p=s.timeoutHandle;p!==-1&&(s.timeoutHandle=-1,qG(p)),p=s.cancelPendingCommit,p!==null&&(s.cancelPendingCommit=null,p()),a_(),on=s,Tt=p=qi(s.current,null),Lt=c,Ht=0,pi=null,Js=!1,Zc=Cr(s,c),Qw=!1,Xc=Gi=Jw=Au=el=En=0,ei=kh=null,e_=!1,(c&8)!==0&&(c|=c&32);var w=s.entangledLanes;if(w!==0)for(s=s.entanglements,w&=c;0<w;){var T=31-Ge(w),k=1<<T;c|=s[T],w&=~k}return Vo=c,hu(),p}function jP(s,c){At=null,H.H=uv,c===yh||c===Jg?(c=G4(),Ht=3):c===q4?(c=G4(),Ht=4):Ht=c===Wj?8:c!==null&&typeof c=="object"&&typeof c.then=="function"?6:1,pi=c,Tt===null&&(En=1,pv(s,Dr(c,s.current)))}function PP(){var s=H.H;return H.H=uv,s===null?uv:s}function RP(){var s=H.A;return H.A=SG,s}function o_(){En=4,Js||(Lt&4194048)!==Lt&&Hi.current!==null||(Zc=!0),(el&134217727)===0&&(Au&134217727)===0||on===null||rl(on,Lt,Gi,!1)}function s_(s,c,p){var w=Vt;Vt|=2;var T=PP(),k=RP();(on!==s||Lt!==c)&&(_v=null,ef(s,c)),c=!1;var re=En;e:do try{if(Ht!==0&&Tt!==null){var le=Tt,ge=pi;switch(Ht){case 8:a_(),re=6;break e;case 3:case 2:case 9:case 6:Hi.current===null&&(c=!0);var Te=Ht;if(Ht=0,pi=null,tf(s,le,ge,Te),p&&Zc){re=0;break e}break;default:Te=Ht,Ht=0,pi=null,tf(s,le,ge,Te)}}EG(),re=En;break}catch(Ie){jP(s,Ie)}while(!0);return c&&s.shellSuspendCounter++,ua=Vi=null,Vt=w,H.H=T,H.A=k,Tt===null&&(on=null,Lt=0,hu()),re}function EG(){for(;Tt!==null;)MP(Tt)}function OG(s,c){var p=Vt;Vt|=2;var w=PP(),T=RP();on!==s||Lt!==c?(_v=null,wv=xe()+500,ef(s,c)):Zc=Cr(s,c);e:do try{if(Ht!==0&&Tt!==null){c=Tt;var k=pi;t:switch(Ht){case 1:Ht=0,pi=null,tf(s,c,k,1);break;case 2:case 9:if(V4(k)){Ht=0,pi=null,NP(c);break}c=function(){Ht!==2&&Ht!==9||on!==s||(Ht=7),Wa(s)},k.then(c,c);break e;case 3:Ht=7;break e;case 4:Ht=5;break e;case 7:V4(k)?(Ht=0,pi=null,NP(c)):(Ht=0,pi=null,tf(s,c,k,7));break;case 5:var re=null;switch(Tt.tag){case 26:re=Tt.memoizedState;case 5:case 27:var le=Tt;if(!re||pR(re)){Ht=0,pi=null;var ge=le.sibling;if(ge!==null)Tt=ge;else{var Te=le.return;Te!==null?(Tt=Te,Sv(Te)):Tt=null}break t}}Ht=0,pi=null,tf(s,c,k,5);break;case 6:Ht=0,pi=null,tf(s,c,k,6);break;case 8:a_(),En=6;break e;default:throw Error(r(462))}}TG();break}catch(Ie){jP(s,Ie)}while(!0);return ua=Vi=null,H.H=w,H.A=T,Vt=p,Tt!==null?0:(on=null,Lt=0,hu(),En)}function TG(){for(;Tt!==null&&!ve();)MP(Tt)}function MP(s){var c=aP(s.alternate,s,Vo);s.memoizedProps=s.pendingProps,c===null?Sv(s):Tt=c}function NP(s){var c=s,p=c.alternate;switch(c.tag){case 15:case 0:c=Jj(p,c,c.pendingProps,c.type,void 0,Lt);break;case 11:c=Jj(p,c,c.pendingProps,c.type.render,c.ref,Lt);break;case 5:xw(c);default:sP(p,c),c=Tt=ph(c,Vo),c=aP(p,c,Vo)}s.memoizedProps=s.pendingProps,c===null?Sv(s):Tt=c}function tf(s,c,p,w){ua=Vi=null,xw(c),Gc=null,Oh=0;var T=c.return;try{if(vG(s,T,c,p,Lt)){En=1,pv(s,Dr(p,s.current)),Tt=null;return}}catch(k){if(T!==null)throw Tt=T,k;En=1,pv(s,Dr(p,s.current)),Tt=null;return}c.flags&32768?(yt||w===1?s=!0:Zc||(Lt&536870912)!==0?s=!1:(Js=s=!0,(w===2||w===9||w===3||w===6)&&(w=Hi.current,w!==null&&w.tag===13&&(w.flags|=16384))),LP(c,s)):Sv(c)}function Sv(s){var c=s;do{if((c.flags&32768)!==0){LP(c,Js);return}s=c.return;var p=bG(c.alternate,c,Vo);if(p!==null){Tt=p;return}if(c=c.sibling,c!==null){Tt=c;return}Tt=c=s}while(c!==null);En===0&&(En=5)}function LP(s,c){do{var p=wG(s.alternate,s);if(p!==null){p.flags&=32767,Tt=p;return}if(p=s.return,p!==null&&(p.flags|=32768,p.subtreeFlags=0,p.deletions=null),!c&&(s=s.sibling,s!==null)){Tt=s;return}Tt=s=p}while(s!==null);En=6,Tt=null}function kP(s,c,p,w,T,k,re,le,ge){s.cancelPendingCommit=null;do Cv();while(mr!==0);if((Vt&6)!==0)throw Error(r(327));if(c!==null){if(c===s.current)throw Error(r(177));if(k=c.lanes|c.childLanes,k|=fi,bc(s,p,k,re,le,ge),s===on&&(Tt=on=null,Lt=0),Qc=c,nl=s,Jc=p,n_=k,r_=T,AP=w,(c.subtreeFlags&10256)!==0||(c.flags&10256)!==0?(s.callbackNode=null,s.callbackPriority=0,MG($e,function(){return UP(),null})):(s.callbackNode=null,s.callbackPriority=0),w=(c.flags&13878)!==0,(c.subtreeFlags&13878)!==0||w){w=H.T,H.T=null,T=I.p,I.p=2,re=Vt,Vt|=4;try{_G(s,c,p)}finally{Vt=re,I.p=T,H.T=w}}mr=1,DP(),IP(),$P()}}function DP(){if(mr===1){mr=0;var s=nl,c=Qc,p=(c.flags&13878)!==0;if((c.subtreeFlags&13878)!==0||p){p=H.T,H.T=null;var w=I.p;I.p=2;var T=Vt;Vt|=4;try{yP(c,s);var k=b_,re=cu(s.containerInfo),le=k.focusedElem,ge=k.selectionRange;if(re!==le&&le&&le.ownerDocument&&Mc(le.ownerDocument.documentElement,le)){if(ge!==null&&fu(le)){var Te=ge.start,Ie=ge.end;if(Ie===void 0&&(Ie=Te),"selectionStart"in le)le.selectionStart=Te,le.selectionEnd=Math.min(Ie,le.value.length);else{var Ue=le.ownerDocument||document,Pe=Ue&&Ue.defaultView||window;if(Pe.getSelection){var Re=Pe.getSelection(),vt=le.textContent.length,dt=Math.min(ge.start,vt),Yt=ge.end===void 0?dt:Math.min(ge.end,vt);!Re.extend&&dt>Yt&&(re=Yt,Yt=dt,dt=re);var Ce=dh(le,dt),we=dh(le,Yt);if(Ce&&we&&(Re.rangeCount!==1||Re.anchorNode!==Ce.node||Re.anchorOffset!==Ce.offset||Re.focusNode!==we.node||Re.focusOffset!==we.offset)){var Ee=Ue.createRange();Ee.setStart(Ce.node,Ce.offset),Re.removeAllRanges(),dt>Yt?(Re.addRange(Ee),Re.extend(we.node,we.offset)):(Ee.setEnd(we.node,we.offset),Re.addRange(Ee))}}}}for(Ue=[],Re=le;Re=Re.parentNode;)Re.nodeType===1&&Ue.push({element:Re,left:Re.scrollLeft,top:Re.scrollTop});for(typeof le.focus=="function"&&le.focus(),le=0;le<Ue.length;le++){var Be=Ue[le];Be.element.scrollLeft=Be.left,Be.element.scrollTop=Be.top}}Dv=!!y_,b_=y_=null}finally{Vt=T,I.p=w,H.T=p}}s.current=c,mr=2}}function IP(){if(mr===2){mr=0;var s=nl,c=Qc,p=(c.flags&8772)!==0;if((c.subtreeFlags&8772)!==0||p){p=H.T,H.T=null;var w=I.p;I.p=2;var T=Vt;Vt|=4;try{pP(s,c.alternate,c)}finally{Vt=T,I.p=w,H.T=p}}mr=3}}function $P(){if(mr===4||mr===3){mr=0,he();var s=nl,c=Qc,p=Jc,w=AP;(c.subtreeFlags&10256)!==0||(c.flags&10256)!==0?mr=5:(mr=0,Qc=nl=null,BP(s,s.pendingLanes));var T=s.pendingLanes;if(T===0&&(tl=null),fn(p),c=c.stateNode,je&&typeof je.onCommitFiberRoot=="function")try{je.onCommitFiberRoot(Ne,c,void 0,(c.current.flags&128)===128)}catch{}if(w!==null){c=H.T,T=I.p,I.p=2,H.T=null;try{for(var k=s.onRecoverableError,re=0;re<w.length;re++){var le=w[re];k(le.value,{componentStack:le.stack})}}finally{H.T=c,I.p=T}}(Jc&3)!==0&&Cv(),Wa(s),T=s.pendingLanes,(p&4194090)!==0&&(T&42)!==0?s===i_?Dh++:(Dh=0,i_=s):Dh=0,Ih(0)}}function BP(s,c){(s.pooledCacheLanes&=c)===0&&(c=s.pooledCache,c!=null&&(s.pooledCache=null,gh(c)))}function Cv(s){return DP(),IP(),$P(),UP()}function UP(){if(mr!==5)return!1;var s=nl,c=n_;n_=0;var p=fn(Jc),w=H.T,T=I.p;try{I.p=32>p?32:p,H.T=null,p=r_,r_=null;var k=nl,re=Jc;if(mr=0,Qc=nl=null,Jc=0,(Vt&6)!==0)throw Error(r(331));var le=Vt;if(Vt|=4,SP(k.current),wP(k,k.current,re,p),Vt=le,Ih(0,!1),je&&typeof je.onPostCommitFiberRoot=="function")try{je.onPostCommitFiberRoot(Ne,k)}catch{}return!0}finally{I.p=T,H.T=w,BP(s,c)}}function zP(s,c,p){c=Dr(p,c),c=Dw(s.stateNode,c,2),s=Gs(s,c,2),s!==null&&(La(s,2),Wa(s))}function Xt(s,c,p){if(s.tag===3)zP(s,s,p);else for(;c!==null;){if(c.tag===3){zP(c,s,p);break}else if(c.tag===1){var w=c.stateNode;if(typeof c.type.getDerivedStateFromError=="function"||typeof w.componentDidCatch=="function"&&(tl===null||!tl.has(w))){s=Dr(p,s),p=Hj(2),w=Gs(c,p,2),w!==null&&(Gj(p,w,c,s),La(w,2),Wa(w));break}}c=c.return}}function l_(s,c,p){var w=s.pingCache;if(w===null){w=s.pingCache=new CG;var T=new Set;w.set(c,T)}else T=w.get(c),T===void 0&&(T=new Set,w.set(c,T));T.has(p)||(Qw=!0,T.add(p),s=jG.bind(null,s,c,p),c.then(s,s))}function jG(s,c,p){var w=s.pingCache;w!==null&&w.delete(c),s.pingedLanes|=s.suspendedLanes&p,s.warmLanes&=~p,on===s&&(Lt&p)===p&&(En===4||En===3&&(Lt&62914560)===Lt&&300>xe()-t_?(Vt&2)===0&&ef(s,0):Jw|=p,Xc===Lt&&(Xc=0)),Wa(s)}function FP(s,c){c===0&&(c=ii()),s=Us(s,c),s!==null&&(La(s,c),Wa(s))}function PG(s){var c=s.memoizedState,p=0;c!==null&&(p=c.retryLane),FP(s,p)}function RG(s,c){var p=0;switch(s.tag){case 13:var w=s.stateNode,T=s.memoizedState;T!==null&&(p=T.retryLane);break;case 19:w=s.stateNode;break;case 22:w=s.stateNode._retryCache;break;default:throw Error(r(314))}w!==null&&w.delete(c),FP(s,p)}function MG(s,c){return se(s,c)}var Av=null,nf=null,u_=!1,Ev=!1,c_=!1,Eu=0;function Wa(s){s!==nf&&s.next===null&&(nf===null?Av=nf=s:nf=nf.next=s),Ev=!0,u_||(u_=!0,LG())}function Ih(s,c){if(!c_&&Ev){c_=!0;do for(var p=!1,w=Av;w!==null;){if(s!==0){var T=w.pendingLanes;if(T===0)var k=0;else{var re=w.suspendedLanes,le=w.pingedLanes;k=(1<<31-Ge(42|s)+1)-1,k&=T&~(re&~le),k=k&201326741?k&201326741|1:k?k|2:0}k!==0&&(p=!0,GP(w,k))}else k=Lt,k=It(w,w===on?k:0,w.cancelPendingCommit!==null||w.timeoutHandle!==-1),(k&3)===0||Cr(w,k)||(p=!0,GP(w,k));w=w.next}while(p);c_=!1}}function NG(){qP()}function qP(){Ev=u_=!1;var s=0;Eu!==0&&(FG()&&(s=Eu),Eu=0);for(var c=xe(),p=null,w=Av;w!==null;){var T=w.next,k=VP(w,c);k===0?(w.next=null,p===null?Av=T:p.next=T,T===null&&(nf=p)):(p=w,(s!==0||(k&3)!==0)&&(Ev=!0)),w=T}Ih(s)}function VP(s,c){for(var p=s.suspendedLanes,w=s.pingedLanes,T=s.expirationTimes,k=s.pendingLanes&-62914561;0<k;){var re=31-Ge(k),le=1<<re,ge=T[re];ge===-1?((le&p)===0||(le&w)!==0)&&(T[re]=Vn(le,c)):ge<=c&&(s.expiredLanes|=le),k&=~le}if(c=on,p=Lt,p=It(s,s===c?p:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),w=s.callbackNode,p===0||s===c&&(Ht===2||Ht===9)||s.cancelPendingCommit!==null)return w!==null&&w!==null&&de(w),s.callbackNode=null,s.callbackPriority=0;if((p&3)===0||Cr(s,p)){if(c=p&-p,c===s.callbackPriority)return c;switch(w!==null&&de(w),fn(p)){case 2:case 8:p=He;break;case 32:p=$e;break;case 268435456:p=_e;break;default:p=$e}return w=HP.bind(null,s),p=se(p,w),s.callbackPriority=c,s.callbackNode=p,c}return w!==null&&w!==null&&de(w),s.callbackPriority=2,s.callbackNode=null,2}function HP(s,c){if(mr!==0&&mr!==5)return s.callbackNode=null,s.callbackPriority=0,null;var p=s.callbackNode;if(Cv()&&s.callbackNode!==p)return null;var w=Lt;return w=It(s,s===on?w:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),w===0?null:(OP(s,w,c),VP(s,xe()),s.callbackNode!=null&&s.callbackNode===p?HP.bind(null,s):null)}function GP(s,c){if(Cv())return null;OP(s,c,!0)}function LG(){VG(function(){(Vt&6)!==0?se(Le,NG):qP()})}function f_(){return Eu===0&&(Eu=ys()),Eu}function WP(s){return s==null||typeof s=="symbol"||typeof s=="boolean"?null:typeof s=="function"?s:Os(""+s)}function YP(s,c){var p=c.ownerDocument.createElement("input");return p.name=c.name,p.value=c.value,s.id&&p.setAttribute("form",s.id),c.parentNode.insertBefore(p,c),s=new FormData(s),p.parentNode.removeChild(p),s}function kG(s,c,p,w,T){if(c==="submit"&&p&&p.stateNode===T){var k=WP((T[tn]||null).action),re=w.submitter;re&&(c=(c=re[tn]||null)?WP(c.formAction):re.getAttribute("formAction"),c!==null&&(k=c,re=null));var le=new au("action","action",null,w,T);s.push({event:le,listeners:[{instance:null,listener:function(){if(w.defaultPrevented){if(Eu!==0){var ge=re?YP(T,re):new FormData(T);Rw(p,{pending:!0,data:ge,method:T.method,action:k},null,ge)}}else typeof k=="function"&&(le.preventDefault(),ge=re?YP(T,re):new FormData(T),Rw(p,{pending:!0,data:ge,method:T.method,action:k},k,ge))},currentTarget:T}]})}}for(var d_=0;d_<No.length;d_++){var h_=No[d_],DG=h_.toLowerCase(),IG=h_[0].toUpperCase()+h_.slice(1);ci(DG,"on"+IG)}ci(Vg,"onAnimationEnd"),ci(ui,"onAnimationIteration"),ci(du,"onAnimationStart"),ci("dblclick","onDoubleClick"),ci("focusin","onFocus"),ci("focusout","onBlur"),ci(ow,"onTransitionRun"),ci(Dc,"onTransitionStart"),ci(sw,"onTransitionCancel"),ci(hh,"onTransitionEnd"),_o("onMouseEnter",["mouseout","mouseover"]),_o("onMouseLeave",["mouseout","mouseover"]),_o("onPointerEnter",["pointerout","pointerover"]),_o("onPointerLeave",["pointerout","pointerover"]),wo("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),wo("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),wo("onBeforeInput",["compositionend","keypress","textInput","paste"]),wo("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),wo("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),wo("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var $h="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(" "),$G=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat($h));function KP(s,c){c=(c&4)!==0;for(var p=0;p<s.length;p++){var w=s[p],T=w.event;w=w.listeners;e:{var k=void 0;if(c)for(var re=w.length-1;0<=re;re--){var le=w[re],ge=le.instance,Te=le.currentTarget;if(le=le.listener,ge!==k&&T.isPropagationStopped())break e;k=le,T.currentTarget=Te;try{k(T)}catch(Ie){hv(Ie)}T.currentTarget=null,k=ge}else for(re=0;re<w.length;re++){if(le=w[re],ge=le.instance,Te=le.currentTarget,le=le.listener,ge!==k&&T.isPropagationStopped())break e;k=le,T.currentTarget=Te;try{k(T)}catch(Ie){hv(Ie)}T.currentTarget=null,k=ge}}}}function jt(s,c){var p=c[Mn];p===void 0&&(p=c[Mn]=new Set);var w=s+"__bubble";p.has(w)||(ZP(c,s,2,!1),p.add(w))}function p_(s,c,p){var w=0;c&&(w|=4),ZP(p,s,w,c)}var Ov="_reactListening"+Math.random().toString(36).slice(2);function m_(s){if(!s[Ov]){s[Ov]=!0,Cg.forEach(function(p){p!=="selectionchange"&&($G.has(p)||p_(p,!1,s),p_(p,!0,s))});var c=s.nodeType===9?s:s.ownerDocument;c===null||c[Ov]||(c[Ov]=!0,p_("selectionchange",!1,c))}}function ZP(s,c,p,w){switch(wR(c)){case 2:var T=fW;break;case 8:T=dW;break;default:T=j_}p=T.bind(null,c,p,s),T=void 0,!iu||c!=="touchstart"&&c!=="touchmove"&&c!=="wheel"||(T=!0),w?T!==void 0?s.addEventListener(c,p,{capture:!0,passive:T}):s.addEventListener(c,p,!0):T!==void 0?s.addEventListener(c,p,{passive:T}):s.addEventListener(c,p,!1)}function g_(s,c,p,w,T){var k=w;if((c&1)===0&&(c&2)===0&&w!==null)e:for(;;){if(w===null)return;var re=w.tag;if(re===3||re===4){var le=w.stateNode.containerInfo;if(le===T)break;if(re===4)for(re=w.return;re!==null;){var ge=re.tag;if((ge===3||ge===4)&&re.stateNode.containerInfo===T)return;re=re.return}for(;le!==null;){if(re=Da(le),re===null)return;if(ge=re.tag,ge===5||ge===6||ge===26||ge===27){w=k=re;continue e}le=le.parentNode}}w=w.return}ai(function(){var Te=k,Ie=Ts(p),Ue=[];e:{var Pe=Hg.get(s);if(Pe!==void 0){var Re=au,vt=s;switch(s){case"keypress":if(An(p)===0)break e;case"keydown":case"keyup":Re=Q1;break;case"focusin":vt="focus",Re=rh;break;case"focusout":vt="blur",Re=rh;break;case"beforeblur":case"afterblur":Re=rh;break;case"click":if(p.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Re=Rs;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Re=W1;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Re=ew;break;case Vg:case ui:case du:Re=Y1;break;case hh:Re=tw;break;case"scroll":case"scrollend":Re=G1;break;case"wheel":Re=kg;break;case"copy":case"cut":case"paste":Re=ih;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Re=oh;break;case"toggle":case"beforetoggle":Re=jo}var dt=(c&4)!==0,Yt=!dt&&(s==="scroll"||s==="scrollend"),Ce=dt?Pe!==null?Pe+"Capture":null:Pe;dt=[];for(var we=Te,Ee;we!==null;){var Be=we;if(Ee=Be.stateNode,Be=Be.tag,Be!==5&&Be!==26&&Be!==27||Ee===null||Ce===null||(Be=$t(we,Ce),Be!=null&&dt.push(Bh(we,Be,Ee))),Yt)break;we=we.return}0<dt.length&&(Pe=new Re(Pe,vt,null,p,Ie),Ue.push({event:Pe,listeners:dt}))}}if((c&7)===0){e:{if(Pe=s==="mouseover"||s==="pointerover",Re=s==="mouseout"||s==="pointerout",Pe&&p!==ru&&(vt=p.relatedTarget||p.fromElement)&&(Da(vt)||vt[er]))break e;if((Re||Pe)&&(Pe=Ie.window===Ie?Ie:(Pe=Ie.ownerDocument)?Pe.defaultView||Pe.parentWindow:window,Re?(vt=p.relatedTarget||p.toElement,Re=Te,vt=vt?Da(vt):null,vt!==null&&(Yt=a(vt),dt=vt.tag,vt!==Yt||dt!==5&&dt!==27&&dt!==6)&&(vt=null)):(Re=null,vt=Te),Re!==vt)){if(dt=Rs,Be="onMouseLeave",Ce="onMouseEnter",we="mouse",(s==="pointerout"||s==="pointerover")&&(dt=oh,Be="onPointerLeave",Ce="onPointerEnter",we="pointer"),Yt=Re==null?Pe:Ii(Re),Ee=vt==null?Pe:Ii(vt),Pe=new dt(Be,we+"leave",Re,p,Ie),Pe.target=Yt,Pe.relatedTarget=Ee,Be=null,Da(Ie)===Te&&(dt=new dt(Ce,we+"enter",vt,p,Ie),dt.target=Ee,dt.relatedTarget=Yt,Be=dt),Yt=Be,Re&&vt)t:{for(dt=Re,Ce=vt,we=0,Ee=dt;Ee;Ee=rf(Ee))we++;for(Ee=0,Be=Ce;Be;Be=rf(Be))Ee++;for(;0<we-Ee;)dt=rf(dt),we--;for(;0<Ee-we;)Ce=rf(Ce),Ee--;for(;we--;){if(dt===Ce||Ce!==null&&dt===Ce.alternate)break t;dt=rf(dt),Ce=rf(Ce)}dt=null}else dt=null;Re!==null&&XP(Ue,Pe,Re,dt,!1),vt!==null&&Yt!==null&&XP(Ue,Yt,vt,dt,!0)}}e:{if(Pe=Te?Ii(Te):window,Re=Pe.nodeName&&Pe.nodeName.toLowerCase(),Re==="select"||Re==="input"&&Pe.type==="file")var it=Ls;else if(Ro(Pe))if(uh)it=aw;else{it=iw;var Ot=fh}else Re=Pe.nodeName,!Re||Re.toLowerCase()!=="input"||Pe.type!=="checkbox"&&Pe.type!=="radio"?Te&&nu(Te.elementType)&&(it=Ls):it=la;if(it&&(it=it(s,Te))){Ug(Ue,it,p,Ie);break e}Ot&&Ot(s,Pe,Te),s==="focusout"&&Te&&Pe.type==="number"&&Te.memoizedProps.value!=null&&As(Pe,"number",Pe.value)}switch(Ot=Te?Ii(Te):window,s){case"focusin":(Ro(Ot)||Ot.contentEditable==="true")&&(li=Ot,Is=Te,Mo=null);break;case"focusout":Mo=Is=li=null;break;case"mousedown":Lc=!0;break;case"contextmenu":case"mouseup":case"dragend":Lc=!1,Fg(Ue,p,Ie);break;case"selectionchange":if(Nc)break;case"keydown":case"keyup":Fg(Ue,p,Ie)}var ct;if(Po)e:{switch(s){case"compositionstart":var mt="onCompositionStart";break e;case"compositionend":mt="onCompositionEnd";break e;case"compositionupdate":mt="onCompositionUpdate";break e}mt=void 0}else Ms?Pc(s,p)&&(mt="onCompositionEnd"):s==="keydown"&&p.keyCode===229&&(mt="onCompositionStart");mt&&(lh&&p.locale!=="ko"&&(Ms||mt!=="onCompositionStart"?mt==="onCompositionEnd"&&Ms&&(ct=Ps()):(Ui=Ie,oa="value"in Ui?Ui.value:Ui.textContent,Ms=!0)),Ot=Tv(Te,mt),0<Ot.length&&(mt=new oi(mt,s,null,p,Ie),Ue.push({event:mt,listeners:Ot}),ct?mt.data=ct:(ct=$g(p),ct!==null&&(mt.data=ct)))),(ct=Dg?Bg(s,p):rw(s,p))&&(mt=Tv(Te,"onBeforeInput"),0<mt.length&&(Ot=new oi("onBeforeInput","beforeinput",null,p,Ie),Ue.push({event:Ot,listeners:mt}),Ot.data=ct)),kG(Ue,s,Te,p,Ie)}KP(Ue,c)})}function Bh(s,c,p){return{instance:s,listener:c,currentTarget:p}}function Tv(s,c){for(var p=c+"Capture",w=[];s!==null;){var T=s,k=T.stateNode;if(T=T.tag,T!==5&&T!==26&&T!==27||k===null||(T=$t(s,p),T!=null&&w.unshift(Bh(s,T,k)),T=$t(s,c),T!=null&&w.push(Bh(s,T,k))),s.tag===3)return w;s=s.return}return[]}function rf(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5&&s.tag!==27);return s||null}function XP(s,c,p,w,T){for(var k=c._reactName,re=[];p!==null&&p!==w;){var le=p,ge=le.alternate,Te=le.stateNode;if(le=le.tag,ge!==null&&ge===w)break;le!==5&&le!==26&&le!==27||Te===null||(ge=Te,T?(Te=$t(p,k),Te!=null&&re.unshift(Bh(p,Te,ge))):T||(Te=$t(p,k),Te!=null&&re.push(Bh(p,Te,ge)))),p=p.return}re.length!==0&&s.push({event:c,listeners:re})}var BG=/\r\n?/g,UG=/\u0000|\uFFFD/g;function QP(s){return(typeof s=="string"?s:""+s).replace(BG,`
|
||
`).replace(UG,"")}function JP(s,c){return c=QP(c),QP(s)===c}function jv(){}function Wt(s,c,p,w,T,k){switch(p){case"children":typeof w=="string"?c==="body"||c==="textarea"&&w===""||$i(s,w):(typeof w=="number"||typeof w=="bigint")&&c!=="body"&&$i(s,""+w);break;case"className":xc(s,"class",w);break;case"tabIndex":xc(s,"tabindex",w);break;case"dir":case"role":case"viewBox":case"width":case"height":xc(s,p,w);break;case"style":Es(s,w,k);break;case"data":if(c!=="object"){xc(s,"data",w);break}case"src":case"href":if(w===""&&(c!=="a"||p!=="href")){s.removeAttribute(p);break}if(w==null||typeof w=="function"||typeof w=="symbol"||typeof w=="boolean"){s.removeAttribute(p);break}w=Os(""+w),s.setAttribute(p,w);break;case"action":case"formAction":if(typeof w=="function"){s.setAttribute(p,"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 k=="function"&&(p==="formAction"?(c!=="input"&&Wt(s,c,"name",T.name,T,null),Wt(s,c,"formEncType",T.formEncType,T,null),Wt(s,c,"formMethod",T.formMethod,T,null),Wt(s,c,"formTarget",T.formTarget,T,null)):(Wt(s,c,"encType",T.encType,T,null),Wt(s,c,"method",T.method,T,null),Wt(s,c,"target",T.target,T,null)));if(w==null||typeof w=="symbol"||typeof w=="boolean"){s.removeAttribute(p);break}w=Os(""+w),s.setAttribute(p,w);break;case"onClick":w!=null&&(s.onclick=jv);break;case"onScroll":w!=null&&jt("scroll",s);break;case"onScrollEnd":w!=null&&jt("scrollend",s);break;case"dangerouslySetInnerHTML":if(w!=null){if(typeof w!="object"||!("__html"in w))throw Error(r(61));if(p=w.__html,p!=null){if(T.children!=null)throw Error(r(60));s.innerHTML=p}}break;case"multiple":s.multiple=w&&typeof w!="function"&&typeof w!="symbol";break;case"muted":s.muted=w&&typeof w!="function"&&typeof w!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(w==null||typeof w=="function"||typeof w=="boolean"||typeof w=="symbol"){s.removeAttribute("xlink:href");break}p=Os(""+w),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",p);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":w!=null&&typeof w!="function"&&typeof w!="symbol"?s.setAttribute(p,""+w):s.removeAttribute(p);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":w&&typeof w!="function"&&typeof w!="symbol"?s.setAttribute(p,""):s.removeAttribute(p);break;case"capture":case"download":w===!0?s.setAttribute(p,""):w!==!1&&w!=null&&typeof w!="function"&&typeof w!="symbol"?s.setAttribute(p,w):s.removeAttribute(p);break;case"cols":case"rows":case"size":case"span":w!=null&&typeof w!="function"&&typeof w!="symbol"&&!isNaN(w)&&1<=w?s.setAttribute(p,w):s.removeAttribute(p);break;case"rowSpan":case"start":w==null||typeof w=="function"||typeof w=="symbol"||isNaN(w)?s.removeAttribute(p):s.setAttribute(p,w);break;case"popover":jt("beforetoggle",s),jt("toggle",s),_c(s,"popover",w);break;case"xlinkActuate":aa(s,"http://www.w3.org/1999/xlink","xlink:actuate",w);break;case"xlinkArcrole":aa(s,"http://www.w3.org/1999/xlink","xlink:arcrole",w);break;case"xlinkRole":aa(s,"http://www.w3.org/1999/xlink","xlink:role",w);break;case"xlinkShow":aa(s,"http://www.w3.org/1999/xlink","xlink:show",w);break;case"xlinkTitle":aa(s,"http://www.w3.org/1999/xlink","xlink:title",w);break;case"xlinkType":aa(s,"http://www.w3.org/1999/xlink","xlink:type",w);break;case"xmlBase":aa(s,"http://www.w3.org/XML/1998/namespace","xml:base",w);break;case"xmlLang":aa(s,"http://www.w3.org/XML/1998/namespace","xml:lang",w);break;case"xmlSpace":aa(s,"http://www.w3.org/XML/1998/namespace","xml:space",w);break;case"is":_c(s,"is",w);break;case"innerText":case"textContent":break;default:(!(2<p.length)||p[0]!=="o"&&p[0]!=="O"||p[1]!=="n"&&p[1]!=="N")&&(p=eh.get(p)||p,_c(s,p,w))}}function v_(s,c,p,w,T,k){switch(p){case"style":Es(s,w,k);break;case"dangerouslySetInnerHTML":if(w!=null){if(typeof w!="object"||!("__html"in w))throw Error(r(61));if(p=w.__html,p!=null){if(T.children!=null)throw Error(r(60));s.innerHTML=p}}break;case"children":typeof w=="string"?$i(s,w):(typeof w=="number"||typeof w=="bigint")&&$i(s,""+w);break;case"onScroll":w!=null&&jt("scroll",s);break;case"onScrollEnd":w!=null&&jt("scrollend",s);break;case"onClick":w!=null&&(s.onclick=jv);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Ag.hasOwnProperty(p))e:{if(p[0]==="o"&&p[1]==="n"&&(T=p.endsWith("Capture"),c=p.slice(2,T?p.length-7:void 0),k=s[tn]||null,k=k!=null?k[p]:null,typeof k=="function"&&s.removeEventListener(c,k,T),typeof w=="function")){typeof k!="function"&&k!==null&&(p in s?s[p]=null:s.hasAttribute(p)&&s.removeAttribute(p)),s.addEventListener(c,w,T);break e}p in s?s[p]=w:w===!0?s.setAttribute(p,""):_c(s,p,w)}}}function gr(s,c,p){switch(c){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":jt("error",s),jt("load",s);var w=!1,T=!1,k;for(k in p)if(p.hasOwnProperty(k)){var re=p[k];if(re!=null)switch(k){case"src":w=!0;break;case"srcSet":T=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,c));default:Wt(s,c,k,re,p,null)}}T&&Wt(s,c,"srcSet",p.srcSet,p,null),w&&Wt(s,c,"src",p.src,p,null);return;case"input":jt("invalid",s);var le=k=re=T=null,ge=null,Te=null;for(w in p)if(p.hasOwnProperty(w)){var Ie=p[w];if(Ie!=null)switch(w){case"name":T=Ie;break;case"type":re=Ie;break;case"checked":ge=Ie;break;case"defaultChecked":Te=Ie;break;case"value":k=Ie;break;case"defaultValue":le=Ie;break;case"children":case"dangerouslySetInnerHTML":if(Ie!=null)throw Error(r(137,c));break;default:Wt(s,c,w,Ie,p,null)}}Og(s,k,le,ge,Te,re,T,!1),Cs(s);return;case"select":jt("invalid",s),w=re=k=null;for(T in p)if(p.hasOwnProperty(T)&&(le=p[T],le!=null))switch(T){case"value":k=le;break;case"defaultValue":re=le;break;case"multiple":w=le;default:Wt(s,c,T,le,p,null)}c=k,p=re,s.multiple=!!w,c!=null?Zr(s,!!w,c,!1):p!=null&&Zr(s,!!w,p,!0);return;case"textarea":jt("invalid",s),k=T=w=null;for(re in p)if(p.hasOwnProperty(re)&&(le=p[re],le!=null))switch(re){case"value":w=le;break;case"defaultValue":T=le;break;case"children":k=le;break;case"dangerouslySetInnerHTML":if(le!=null)throw Error(r(91));break;default:Wt(s,c,re,le,p,null)}Ia(s,w,T,k),Cs(s);return;case"option":for(ge in p)if(p.hasOwnProperty(ge)&&(w=p[ge],w!=null))switch(ge){case"selected":s.selected=w&&typeof w!="function"&&typeof w!="symbol";break;default:Wt(s,c,ge,w,p,null)}return;case"dialog":jt("beforetoggle",s),jt("toggle",s),jt("cancel",s),jt("close",s);break;case"iframe":case"object":jt("load",s);break;case"video":case"audio":for(w=0;w<$h.length;w++)jt($h[w],s);break;case"image":jt("error",s),jt("load",s);break;case"details":jt("toggle",s);break;case"embed":case"source":case"link":jt("error",s),jt("load",s);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 p)if(p.hasOwnProperty(Te)&&(w=p[Te],w!=null))switch(Te){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,c));default:Wt(s,c,Te,w,p,null)}return;default:if(nu(c)){for(Ie in p)p.hasOwnProperty(Ie)&&(w=p[Ie],w!==void 0&&v_(s,c,Ie,w,p,void 0));return}}for(le in p)p.hasOwnProperty(le)&&(w=p[le],w!=null&&Wt(s,c,le,w,p,null))}function zG(s,c,p,w){switch(c){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var T=null,k=null,re=null,le=null,ge=null,Te=null,Ie=null;for(Re in p){var Ue=p[Re];if(p.hasOwnProperty(Re)&&Ue!=null)switch(Re){case"checked":break;case"value":break;case"defaultValue":ge=Ue;default:w.hasOwnProperty(Re)||Wt(s,c,Re,null,w,Ue)}}for(var Pe in w){var Re=w[Pe];if(Ue=p[Pe],w.hasOwnProperty(Pe)&&(Re!=null||Ue!=null))switch(Pe){case"type":k=Re;break;case"name":T=Re;break;case"checked":Te=Re;break;case"defaultChecked":Ie=Re;break;case"value":re=Re;break;case"defaultValue":le=Re;break;case"children":case"dangerouslySetInnerHTML":if(Re!=null)throw Error(r(137,c));break;default:Re!==Ue&&Wt(s,c,Pe,Re,w,Ue)}}Ar(s,re,le,ge,Te,Ie,k,T);return;case"select":Re=re=le=Pe=null;for(k in p)if(ge=p[k],p.hasOwnProperty(k)&&ge!=null)switch(k){case"value":break;case"multiple":Re=ge;default:w.hasOwnProperty(k)||Wt(s,c,k,null,w,ge)}for(T in w)if(k=w[T],ge=p[T],w.hasOwnProperty(T)&&(k!=null||ge!=null))switch(T){case"value":Pe=k;break;case"defaultValue":le=k;break;case"multiple":re=k;default:k!==ge&&Wt(s,c,T,k,w,ge)}c=le,p=re,w=Re,Pe!=null?Zr(s,!!p,Pe,!1):!!w!=!!p&&(c!=null?Zr(s,!!p,c,!0):Zr(s,!!p,p?[]:"",!1));return;case"textarea":Re=Pe=null;for(le in p)if(T=p[le],p.hasOwnProperty(le)&&T!=null&&!w.hasOwnProperty(le))switch(le){case"value":break;case"children":break;default:Wt(s,c,le,null,w,T)}for(re in w)if(T=w[re],k=p[re],w.hasOwnProperty(re)&&(T!=null||k!=null))switch(re){case"value":Pe=T;break;case"defaultValue":Re=T;break;case"children":break;case"dangerouslySetInnerHTML":if(T!=null)throw Error(r(91));break;default:T!==k&&Wt(s,c,re,T,w,k)}_n(s,Pe,Re);return;case"option":for(var vt in p)if(Pe=p[vt],p.hasOwnProperty(vt)&&Pe!=null&&!w.hasOwnProperty(vt))switch(vt){case"selected":s.selected=!1;break;default:Wt(s,c,vt,null,w,Pe)}for(ge in w)if(Pe=w[ge],Re=p[ge],w.hasOwnProperty(ge)&&Pe!==Re&&(Pe!=null||Re!=null))switch(ge){case"selected":s.selected=Pe&&typeof Pe!="function"&&typeof Pe!="symbol";break;default:Wt(s,c,ge,Pe,w,Re)}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 dt in p)Pe=p[dt],p.hasOwnProperty(dt)&&Pe!=null&&!w.hasOwnProperty(dt)&&Wt(s,c,dt,null,w,Pe);for(Te in w)if(Pe=w[Te],Re=p[Te],w.hasOwnProperty(Te)&&Pe!==Re&&(Pe!=null||Re!=null))switch(Te){case"children":case"dangerouslySetInnerHTML":if(Pe!=null)throw Error(r(137,c));break;default:Wt(s,c,Te,Pe,w,Re)}return;default:if(nu(c)){for(var Yt in p)Pe=p[Yt],p.hasOwnProperty(Yt)&&Pe!==void 0&&!w.hasOwnProperty(Yt)&&v_(s,c,Yt,void 0,w,Pe);for(Ie in w)Pe=w[Ie],Re=p[Ie],!w.hasOwnProperty(Ie)||Pe===Re||Pe===void 0&&Re===void 0||v_(s,c,Ie,Pe,w,Re);return}}for(var Ce in p)Pe=p[Ce],p.hasOwnProperty(Ce)&&Pe!=null&&!w.hasOwnProperty(Ce)&&Wt(s,c,Ce,null,w,Pe);for(Ue in w)Pe=w[Ue],Re=p[Ue],!w.hasOwnProperty(Ue)||Pe===Re||Pe==null&&Re==null||Wt(s,c,Ue,Pe,w,Re)}var y_=null,b_=null;function Pv(s){return s.nodeType===9?s:s.ownerDocument}function eR(s){switch(s){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function tR(s,c){if(s===0)switch(c){case"svg":return 1;case"math":return 2;default:return 0}return s===1&&c==="foreignObject"?0:s}function w_(s,c){return s==="textarea"||s==="noscript"||typeof c.children=="string"||typeof c.children=="number"||typeof c.children=="bigint"||typeof c.dangerouslySetInnerHTML=="object"&&c.dangerouslySetInnerHTML!==null&&c.dangerouslySetInnerHTML.__html!=null}var __=null;function FG(){var s=window.event;return s&&s.type==="popstate"?s===__?!1:(__=s,!0):(__=null,!1)}var nR=typeof setTimeout=="function"?setTimeout:void 0,qG=typeof clearTimeout=="function"?clearTimeout:void 0,rR=typeof Promise=="function"?Promise:void 0,VG=typeof queueMicrotask=="function"?queueMicrotask:typeof rR<"u"?function(s){return rR.resolve(null).then(s).catch(HG)}:nR;function HG(s){setTimeout(function(){throw s})}function il(s){return s==="head"}function iR(s,c){var p=c,w=0,T=0;do{var k=p.nextSibling;if(s.removeChild(p),k&&k.nodeType===8)if(p=k.data,p==="/$"){if(0<w&&8>w){p=w;var re=s.ownerDocument;if(p&1&&Uh(re.documentElement),p&2&&Uh(re.body),p&4)for(p=re.head,Uh(p),re=p.firstChild;re;){var le=re.nextSibling,ge=re.nodeName;re[_s]||ge==="SCRIPT"||ge==="STYLE"||ge==="LINK"&&re.rel.toLowerCase()==="stylesheet"||p.removeChild(re),re=le}}if(T===0){s.removeChild(k),Yh(c);return}T--}else p==="$"||p==="$?"||p==="$!"?T++:w=p.charCodeAt(0)-48;else w=0;p=k}while(p);Yh(c)}function x_(s){var c=s.firstChild;for(c&&c.nodeType===10&&(c=c.nextSibling);c;){var p=c;switch(c=c.nextSibling,p.nodeName){case"HTML":case"HEAD":case"BODY":x_(p),wc(p);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(p.rel.toLowerCase()==="stylesheet")continue}s.removeChild(p)}}function GG(s,c,p,w){for(;s.nodeType===1;){var T=p;if(s.nodeName.toLowerCase()!==c.toLowerCase()){if(!w&&(s.nodeName!=="INPUT"||s.type!=="hidden"))break}else if(w){if(!s[_s])switch(c){case"meta":if(!s.hasAttribute("itemprop"))break;return s;case"link":if(k=s.getAttribute("rel"),k==="stylesheet"&&s.hasAttribute("data-precedence"))break;if(k!==T.rel||s.getAttribute("href")!==(T.href==null||T.href===""?null:T.href)||s.getAttribute("crossorigin")!==(T.crossOrigin==null?null:T.crossOrigin)||s.getAttribute("title")!==(T.title==null?null:T.title))break;return s;case"style":if(s.hasAttribute("data-precedence"))break;return s;case"script":if(k=s.getAttribute("src"),(k!==(T.src==null?null:T.src)||s.getAttribute("type")!==(T.type==null?null:T.type)||s.getAttribute("crossorigin")!==(T.crossOrigin==null?null:T.crossOrigin))&&k&&s.hasAttribute("async")&&!s.hasAttribute("itemprop"))break;return s;default:return s}}else if(c==="input"&&s.type==="hidden"){var k=T.name==null?null:""+T.name;if(T.type==="hidden"&&s.getAttribute("name")===k)return s}else return s;if(s=da(s.nextSibling),s===null)break}return null}function WG(s,c,p){if(c==="")return null;for(;s.nodeType!==3;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!p||(s=da(s.nextSibling),s===null))return null;return s}function S_(s){return s.data==="$!"||s.data==="$?"&&s.ownerDocument.readyState==="complete"}function YG(s,c){var p=s.ownerDocument;if(s.data!=="$?"||p.readyState==="complete")c();else{var w=function(){c(),p.removeEventListener("DOMContentLoaded",w)};p.addEventListener("DOMContentLoaded",w),s._reactRetry=w}}function da(s){for(;s!=null;s=s.nextSibling){var c=s.nodeType;if(c===1||c===3)break;if(c===8){if(c=s.data,c==="$"||c==="$!"||c==="$?"||c==="F!"||c==="F")break;if(c==="/$")return null}}return s}var C_=null;function aR(s){s=s.previousSibling;for(var c=0;s;){if(s.nodeType===8){var p=s.data;if(p==="$"||p==="$!"||p==="$?"){if(c===0)return s;c--}else p==="/$"&&c++}s=s.previousSibling}return null}function oR(s,c,p){switch(c=Pv(p),s){case"html":if(s=c.documentElement,!s)throw Error(r(452));return s;case"head":if(s=c.head,!s)throw Error(r(453));return s;case"body":if(s=c.body,!s)throw Error(r(454));return s;default:throw Error(r(451))}}function Uh(s){for(var c=s.attributes;c.length;)s.removeAttributeNode(c[0]);wc(s)}var Wi=new Map,sR=new Set;function Rv(s){return typeof s.getRootNode=="function"?s.getRootNode():s.nodeType===9?s:s.ownerDocument}var Ho=I.d;I.d={f:KG,r:ZG,D:XG,C:QG,L:JG,m:eW,X:nW,S:tW,M:rW};function KG(){var s=Ho.f(),c=xv();return s||c}function ZG(s){var c=yo(s);c!==null&&c.tag===5&&c.type==="form"?Oj(c):Ho.r(s)}var af=typeof document>"u"?null:document;function lR(s,c,p){var w=af;if(w&&typeof c=="string"&&c){var T=dr(c);T='link[rel="'+s+'"][href="'+T+'"]',typeof p=="string"&&(T+='[crossorigin="'+p+'"]'),sR.has(T)||(sR.add(T),s={rel:s,crossOrigin:p,href:c},w.querySelector(T)===null&&(c=w.createElement("link"),gr(c,"link",s),In(c),w.head.appendChild(c)))}}function XG(s){Ho.D(s),lR("dns-prefetch",s,null)}function QG(s,c){Ho.C(s,c),lR("preconnect",s,c)}function JG(s,c,p){Ho.L(s,c,p);var w=af;if(w&&s&&c){var T='link[rel="preload"][as="'+dr(c)+'"]';c==="image"&&p&&p.imageSrcSet?(T+='[imagesrcset="'+dr(p.imageSrcSet)+'"]',typeof p.imageSizes=="string"&&(T+='[imagesizes="'+dr(p.imageSizes)+'"]')):T+='[href="'+dr(s)+'"]';var k=T;switch(c){case"style":k=of(s);break;case"script":k=sf(s)}Wi.has(k)||(s=h({rel:"preload",href:c==="image"&&p&&p.imageSrcSet?void 0:s,as:c},p),Wi.set(k,s),w.querySelector(T)!==null||c==="style"&&w.querySelector(zh(k))||c==="script"&&w.querySelector(Fh(k))||(c=w.createElement("link"),gr(c,"link",s),In(c),w.head.appendChild(c)))}}function eW(s,c){Ho.m(s,c);var p=af;if(p&&s){var w=c&&typeof c.as=="string"?c.as:"script",T='link[rel="modulepreload"][as="'+dr(w)+'"][href="'+dr(s)+'"]',k=T;switch(w){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":k=sf(s)}if(!Wi.has(k)&&(s=h({rel:"modulepreload",href:s},c),Wi.set(k,s),p.querySelector(T)===null)){switch(w){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(p.querySelector(Fh(k)))return}w=p.createElement("link"),gr(w,"link",s),In(w),p.head.appendChild(w)}}}function tW(s,c,p){Ho.S(s,c,p);var w=af;if(w&&s){var T=bo(w).hoistableStyles,k=of(s);c=c||"default";var re=T.get(k);if(!re){var le={loading:0,preload:null};if(re=w.querySelector(zh(k)))le.loading=5;else{s=h({rel:"stylesheet",href:s,"data-precedence":c},p),(p=Wi.get(k))&&A_(s,p);var ge=re=w.createElement("link");In(ge),gr(ge,"link",s),ge._p=new Promise(function(Te,Ie){ge.onload=Te,ge.onerror=Ie}),ge.addEventListener("load",function(){le.loading|=1}),ge.addEventListener("error",function(){le.loading|=2}),le.loading|=4,Mv(re,c,w)}re={type:"stylesheet",instance:re,count:1,state:le},T.set(k,re)}}}function nW(s,c){Ho.X(s,c);var p=af;if(p&&s){var w=bo(p).hoistableScripts,T=sf(s),k=w.get(T);k||(k=p.querySelector(Fh(T)),k||(s=h({src:s,async:!0},c),(c=Wi.get(T))&&E_(s,c),k=p.createElement("script"),In(k),gr(k,"link",s),p.head.appendChild(k)),k={type:"script",instance:k,count:1,state:null},w.set(T,k))}}function rW(s,c){Ho.M(s,c);var p=af;if(p&&s){var w=bo(p).hoistableScripts,T=sf(s),k=w.get(T);k||(k=p.querySelector(Fh(T)),k||(s=h({src:s,async:!0,type:"module"},c),(c=Wi.get(T))&&E_(s,c),k=p.createElement("script"),In(k),gr(k,"link",s),p.head.appendChild(k)),k={type:"script",instance:k,count:1,state:null},w.set(T,k))}}function uR(s,c,p,w){var T=(T=ce.current)?Rv(T):null;if(!T)throw Error(r(446));switch(s){case"meta":case"title":return null;case"style":return typeof p.precedence=="string"&&typeof p.href=="string"?(c=of(p.href),p=bo(T).hoistableStyles,w=p.get(c),w||(w={type:"style",instance:null,count:0,state:null},p.set(c,w)),w):{type:"void",instance:null,count:0,state:null};case"link":if(p.rel==="stylesheet"&&typeof p.href=="string"&&typeof p.precedence=="string"){s=of(p.href);var k=bo(T).hoistableStyles,re=k.get(s);if(re||(T=T.ownerDocument||T,re={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},k.set(s,re),(k=T.querySelector(zh(s)))&&!k._p&&(re.instance=k,re.state.loading=5),Wi.has(s)||(p={rel:"preload",as:"style",href:p.href,crossOrigin:p.crossOrigin,integrity:p.integrity,media:p.media,hrefLang:p.hrefLang,referrerPolicy:p.referrerPolicy},Wi.set(s,p),k||iW(T,s,p,re.state))),c&&w===null)throw Error(r(528,""));return re}if(c&&w!==null)throw Error(r(529,""));return null;case"script":return c=p.async,p=p.src,typeof p=="string"&&c&&typeof c!="function"&&typeof c!="symbol"?(c=sf(p),p=bo(T).hoistableScripts,w=p.get(c),w||(w={type:"script",instance:null,count:0,state:null},p.set(c,w)),w):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,s))}}function of(s){return'href="'+dr(s)+'"'}function zh(s){return'link[rel="stylesheet"]['+s+"]"}function cR(s){return h({},s,{"data-precedence":s.precedence,precedence:null})}function iW(s,c,p,w){s.querySelector('link[rel="preload"][as="style"]['+c+"]")?w.loading=1:(c=s.createElement("link"),w.preload=c,c.addEventListener("load",function(){return w.loading|=1}),c.addEventListener("error",function(){return w.loading|=2}),gr(c,"link",p),In(c),s.head.appendChild(c))}function sf(s){return'[src="'+dr(s)+'"]'}function Fh(s){return"script[async]"+s}function fR(s,c,p){if(c.count++,c.instance===null)switch(c.type){case"style":var w=s.querySelector('style[data-href~="'+dr(p.href)+'"]');if(w)return c.instance=w,In(w),w;var T=h({},p,{"data-href":p.href,"data-precedence":p.precedence,href:null,precedence:null});return w=(s.ownerDocument||s).createElement("style"),In(w),gr(w,"style",T),Mv(w,p.precedence,s),c.instance=w;case"stylesheet":T=of(p.href);var k=s.querySelector(zh(T));if(k)return c.state.loading|=4,c.instance=k,In(k),k;w=cR(p),(T=Wi.get(T))&&A_(w,T),k=(s.ownerDocument||s).createElement("link"),In(k);var re=k;return re._p=new Promise(function(le,ge){re.onload=le,re.onerror=ge}),gr(k,"link",w),c.state.loading|=4,Mv(k,p.precedence,s),c.instance=k;case"script":return k=sf(p.src),(T=s.querySelector(Fh(k)))?(c.instance=T,In(T),T):(w=p,(T=Wi.get(k))&&(w=h({},p),E_(w,T)),s=s.ownerDocument||s,T=s.createElement("script"),In(T),gr(T,"link",w),s.head.appendChild(T),c.instance=T);case"void":return null;default:throw Error(r(443,c.type))}else c.type==="stylesheet"&&(c.state.loading&4)===0&&(w=c.instance,c.state.loading|=4,Mv(w,p.precedence,s));return c.instance}function Mv(s,c,p){for(var w=p.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),T=w.length?w[w.length-1]:null,k=T,re=0;re<w.length;re++){var le=w[re];if(le.dataset.precedence===c)k=le;else if(k!==T)break}k?k.parentNode.insertBefore(s,k.nextSibling):(c=p.nodeType===9?p.head:p,c.insertBefore(s,c.firstChild))}function A_(s,c){s.crossOrigin==null&&(s.crossOrigin=c.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=c.referrerPolicy),s.title==null&&(s.title=c.title)}function E_(s,c){s.crossOrigin==null&&(s.crossOrigin=c.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=c.referrerPolicy),s.integrity==null&&(s.integrity=c.integrity)}var Nv=null;function dR(s,c,p){if(Nv===null){var w=new Map,T=Nv=new Map;T.set(p,w)}else T=Nv,w=T.get(p),w||(w=new Map,T.set(p,w));if(w.has(s))return w;for(w.set(s,null),p=p.getElementsByTagName(s),T=0;T<p.length;T++){var k=p[T];if(!(k[_s]||k[Mt]||s==="link"&&k.getAttribute("rel")==="stylesheet")&&k.namespaceURI!=="http://www.w3.org/2000/svg"){var re=k.getAttribute(c)||"";re=s+re;var le=w.get(re);le?le.push(k):w.set(re,[k])}}return w}function hR(s,c,p){s=s.ownerDocument||s,s.head.insertBefore(p,c==="title"?s.querySelector("head > title"):null)}function aW(s,c,p){if(p===1||c.itemProp!=null)return!1;switch(s){case"meta":case"title":return!0;case"style":if(typeof c.precedence!="string"||typeof c.href!="string"||c.href==="")break;return!0;case"link":if(typeof c.rel!="string"||typeof c.href!="string"||c.href===""||c.onLoad||c.onError)break;switch(c.rel){case"stylesheet":return s=c.disabled,typeof c.precedence=="string"&&s==null;default:return!0}case"script":if(c.async&&typeof c.async!="function"&&typeof c.async!="symbol"&&!c.onLoad&&!c.onError&&c.src&&typeof c.src=="string")return!0}return!1}function pR(s){return!(s.type==="stylesheet"&&(s.state.loading&3)===0)}var qh=null;function oW(){}function sW(s,c,p){if(qh===null)throw Error(r(475));var w=qh;if(c.type==="stylesheet"&&(typeof p.media!="string"||matchMedia(p.media).matches!==!1)&&(c.state.loading&4)===0){if(c.instance===null){var T=of(p.href),k=s.querySelector(zh(T));if(k){s=k._p,s!==null&&typeof s=="object"&&typeof s.then=="function"&&(w.count++,w=Lv.bind(w),s.then(w,w)),c.state.loading|=4,c.instance=k,In(k);return}k=s.ownerDocument||s,p=cR(p),(T=Wi.get(T))&&A_(p,T),k=k.createElement("link"),In(k);var re=k;re._p=new Promise(function(le,ge){re.onload=le,re.onerror=ge}),gr(k,"link",p),c.instance=k}w.stylesheets===null&&(w.stylesheets=new Map),w.stylesheets.set(c,s),(s=c.state.preload)&&(c.state.loading&3)===0&&(w.count++,c=Lv.bind(w),s.addEventListener("load",c),s.addEventListener("error",c))}}function lW(){if(qh===null)throw Error(r(475));var s=qh;return s.stylesheets&&s.count===0&&O_(s,s.stylesheets),0<s.count?function(c){var p=setTimeout(function(){if(s.stylesheets&&O_(s,s.stylesheets),s.unsuspend){var w=s.unsuspend;s.unsuspend=null,w()}},6e4);return s.unsuspend=c,function(){s.unsuspend=null,clearTimeout(p)}}:null}function Lv(){if(this.count--,this.count===0){if(this.stylesheets)O_(this,this.stylesheets);else if(this.unsuspend){var s=this.unsuspend;this.unsuspend=null,s()}}}var kv=null;function O_(s,c){s.stylesheets=null,s.unsuspend!==null&&(s.count++,kv=new Map,c.forEach(uW,s),kv=null,Lv.call(s))}function uW(s,c){if(!(c.state.loading&4)){var p=kv.get(s);if(p)var w=p.get(null);else{p=new Map,kv.set(s,p);for(var T=s.querySelectorAll("link[data-precedence],style[data-precedence]"),k=0;k<T.length;k++){var re=T[k];(re.nodeName==="LINK"||re.getAttribute("media")!=="not all")&&(p.set(re.dataset.precedence,re),w=re)}w&&p.set(null,w)}T=c.instance,re=T.getAttribute("data-precedence"),k=p.get(re)||w,k===w&&p.set(null,T),p.set(re,T),this.count++,w=Lv.bind(this),T.addEventListener("load",w),T.addEventListener("error",w),k?k.parentNode.insertBefore(T,k.nextSibling):(s=s.nodeType===9?s.head:s,s.insertBefore(T,s.firstChild)),c.state.loading|=4}}var Vh={$$typeof:O,Provider:null,Consumer:null,_currentValue:D,_currentValue2:D,_threadCount:0};function cW(s,c,p,w,T,k,re,le){this.tag=1,this.containerInfo=s,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=bs(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=bs(0),this.hiddenUpdates=bs(null),this.identifierPrefix=w,this.onUncaughtError=T,this.onCaughtError=k,this.onRecoverableError=re,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=le,this.incompleteTransitions=new Map}function mR(s,c,p,w,T,k,re,le,ge,Te,Ie,Ue){return s=new cW(s,c,p,re,le,ge,Te,Ue),c=1,k===!0&&(c|=24),k=$r(3,null,null,c),s.current=k,k.stateNode=s,c=lw(),c.refCount++,s.pooledCache=c,c.refCount++,k.memoizedState={element:w,isDehydrated:p,cache:c},dw(k),s}function gR(s){return s?(s=Do,s):Do}function vR(s,c,p,w,T,k){T=gR(T),w.context===null?w.context=T:w.pendingContext=T,w=Hs(c),w.payload={element:p},k=k===void 0?null:k,k!==null&&(w.callback=k),p=Gs(s,w,c),p!==null&&(gi(p,s,c),wh(p,s,c))}function yR(s,c){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var p=s.retryLane;s.retryLane=p!==0&&p<c?p:c}}function T_(s,c){yR(s,c),(s=s.alternate)&&yR(s,c)}function bR(s){if(s.tag===13){var c=Us(s,67108864);c!==null&&gi(c,s,67108864),T_(s,67108864)}}var Dv=!0;function fW(s,c,p,w){var T=H.T;H.T=null;var k=I.p;try{I.p=2,j_(s,c,p,w)}finally{I.p=k,H.T=T}}function dW(s,c,p,w){var T=H.T;H.T=null;var k=I.p;try{I.p=8,j_(s,c,p,w)}finally{I.p=k,H.T=T}}function j_(s,c,p,w){if(Dv){var T=P_(w);if(T===null)g_(s,c,w,Iv,p),_R(s,w);else if(pW(T,s,c,p,w))w.stopPropagation();else if(_R(s,w),c&4&&-1<hW.indexOf(s)){for(;T!==null;){var k=yo(T);if(k!==null)switch(k.tag){case 3:if(k=k.stateNode,k.current.memoizedState.isDehydrated){var re=Dt(k.pendingLanes);if(re!==0){var le=k;for(le.pendingLanes|=2,le.entangledLanes|=2;re;){var ge=1<<31-Ge(re);le.entanglements[1]|=ge,re&=~ge}Wa(k),(Vt&6)===0&&(wv=xe()+500,Ih(0))}}break;case 13:le=Us(k,2),le!==null&&gi(le,k,2),xv(),T_(k,2)}if(k=P_(w),k===null&&g_(s,c,w,Iv,p),k===T)break;T=k}T!==null&&w.stopPropagation()}else g_(s,c,w,null,p)}}function P_(s){return s=Ts(s),R_(s)}var Iv=null;function R_(s){if(Iv=null,s=Da(s),s!==null){var c=a(s);if(c===null)s=null;else{var p=c.tag;if(p===13){if(s=o(c),s!==null)return s;s=null}else if(p===3){if(c.stateNode.current.memoizedState.isDehydrated)return c.tag===3?c.stateNode.containerInfo:null;s=null}else c!==s&&(s=null)}}return Iv=s,null}function wR(s){switch(s){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(Oe()){case Le:return 2;case He:return 8;case $e:case ze:return 32;case _e:return 268435456;default:return 32}default:return 32}}var M_=!1,al=null,ol=null,sl=null,Hh=new Map,Gh=new Map,ll=[],hW="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 _R(s,c){switch(s){case"focusin":case"focusout":al=null;break;case"dragenter":case"dragleave":ol=null;break;case"mouseover":case"mouseout":sl=null;break;case"pointerover":case"pointerout":Hh.delete(c.pointerId);break;case"gotpointercapture":case"lostpointercapture":Gh.delete(c.pointerId)}}function Wh(s,c,p,w,T,k){return s===null||s.nativeEvent!==k?(s={blockedOn:c,domEventName:p,eventSystemFlags:w,nativeEvent:k,targetContainers:[T]},c!==null&&(c=yo(c),c!==null&&bR(c)),s):(s.eventSystemFlags|=w,c=s.targetContainers,T!==null&&c.indexOf(T)===-1&&c.push(T),s)}function pW(s,c,p,w,T){switch(c){case"focusin":return al=Wh(al,s,c,p,w,T),!0;case"dragenter":return ol=Wh(ol,s,c,p,w,T),!0;case"mouseover":return sl=Wh(sl,s,c,p,w,T),!0;case"pointerover":var k=T.pointerId;return Hh.set(k,Wh(Hh.get(k)||null,s,c,p,w,T)),!0;case"gotpointercapture":return k=T.pointerId,Gh.set(k,Wh(Gh.get(k)||null,s,c,p,w,T)),!0}return!1}function xR(s){var c=Da(s.target);if(c!==null){var p=a(c);if(p!==null){if(c=p.tag,c===13){if(c=o(p),c!==null){s.blockedOn=c,Hn(s.priority,function(){if(p.tag===13){var w=mi();w=mn(w);var T=Us(p,w);T!==null&&gi(T,p,w),T_(p,w)}});return}}else if(c===3&&p.stateNode.current.memoizedState.isDehydrated){s.blockedOn=p.tag===3?p.stateNode.containerInfo:null;return}}}s.blockedOn=null}function $v(s){if(s.blockedOn!==null)return!1;for(var c=s.targetContainers;0<c.length;){var p=P_(s.nativeEvent);if(p===null){p=s.nativeEvent;var w=new p.constructor(p.type,p);ru=w,p.target.dispatchEvent(w),ru=null}else return c=yo(p),c!==null&&bR(c),s.blockedOn=p,!1;c.shift()}return!0}function SR(s,c,p){$v(s)&&p.delete(c)}function mW(){M_=!1,al!==null&&$v(al)&&(al=null),ol!==null&&$v(ol)&&(ol=null),sl!==null&&$v(sl)&&(sl=null),Hh.forEach(SR),Gh.forEach(SR)}function Bv(s,c){s.blockedOn===c&&(s.blockedOn=null,M_||(M_=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,mW)))}var Uv=null;function CR(s){Uv!==s&&(Uv=s,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){Uv===s&&(Uv=null);for(var c=0;c<s.length;c+=3){var p=s[c],w=s[c+1],T=s[c+2];if(typeof w!="function"){if(R_(w||p)===null)continue;break}var k=yo(p);k!==null&&(s.splice(c,3),c-=3,Rw(k,{pending:!0,data:T,method:p.method,action:w},w,T))}}))}function Yh(s){function c(ge){return Bv(ge,s)}al!==null&&Bv(al,s),ol!==null&&Bv(ol,s),sl!==null&&Bv(sl,s),Hh.forEach(c),Gh.forEach(c);for(var p=0;p<ll.length;p++){var w=ll[p];w.blockedOn===s&&(w.blockedOn=null)}for(;0<ll.length&&(p=ll[0],p.blockedOn===null);)xR(p),p.blockedOn===null&&ll.shift();if(p=(s.ownerDocument||s).$$reactFormReplay,p!=null)for(w=0;w<p.length;w+=3){var T=p[w],k=p[w+1],re=T[tn]||null;if(typeof k=="function")re||CR(p);else if(re){var le=null;if(k&&k.hasAttribute("formAction")){if(T=k,re=k[tn]||null)le=re.formAction;else if(R_(T)!==null)continue}else le=re.action;typeof le=="function"?p[w+1]=le:(p.splice(w,3),w-=3),CR(p)}}}function N_(s){this._internalRoot=s}zv.prototype.render=N_.prototype.render=function(s){var c=this._internalRoot;if(c===null)throw Error(r(409));var p=c.current,w=mi();vR(p,w,s,c,null,null)},zv.prototype.unmount=N_.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var c=s.containerInfo;vR(s.current,2,null,s,null,null),xv(),c[er]=null}};function zv(s){this._internalRoot=s}zv.prototype.unstable_scheduleHydration=function(s){if(s){var c=Jn();s={blockedOn:null,target:s,priority:c};for(var p=0;p<ll.length&&c!==0&&c<ll[p].priority;p++);ll.splice(p,0,s),p===0&&xR(s)}};var AR=t.version;if(AR!=="19.1.0")throw Error(r(527,AR,"19.1.0"));I.findDOMNode=function(s){var c=s._reactInternals;if(c===void 0)throw typeof s.render=="function"?Error(r(188)):(s=Object.keys(s).join(","),Error(r(268,s)));return s=f(c),s=s!==null?u(s):null,s=s===null?null:s.stateNode,s};var gW={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:H,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Fv=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Fv.isDisabled&&Fv.supportsFiber)try{Ne=Fv.inject(gW),je=Fv}catch{}}return Jh.createRoot=function(s,c){if(!i(s))throw Error(r(299));var p=!1,w="",T=zj,k=Fj,re=qj,le=null;return c!=null&&(c.unstable_strictMode===!0&&(p=!0),c.identifierPrefix!==void 0&&(w=c.identifierPrefix),c.onUncaughtError!==void 0&&(T=c.onUncaughtError),c.onCaughtError!==void 0&&(k=c.onCaughtError),c.onRecoverableError!==void 0&&(re=c.onRecoverableError),c.unstable_transitionCallbacks!==void 0&&(le=c.unstable_transitionCallbacks)),c=mR(s,1,!1,null,null,p,w,T,k,re,le,null),s[er]=c.current,m_(s),new N_(c)},Jh.hydrateRoot=function(s,c,p){if(!i(s))throw Error(r(299));var w=!1,T="",k=zj,re=Fj,le=qj,ge=null,Te=null;return p!=null&&(p.unstable_strictMode===!0&&(w=!0),p.identifierPrefix!==void 0&&(T=p.identifierPrefix),p.onUncaughtError!==void 0&&(k=p.onUncaughtError),p.onCaughtError!==void 0&&(re=p.onCaughtError),p.onRecoverableError!==void 0&&(le=p.onRecoverableError),p.unstable_transitionCallbacks!==void 0&&(ge=p.unstable_transitionCallbacks),p.formState!==void 0&&(Te=p.formState)),c=mR(s,1,!0,c,p??null,w,T,k,re,le,ge,Te),c.context=gR(null),p=c.current,w=mi(),w=mn(w),T=Hs(w),T.callback=null,Gs(p,T,w),p=w,c.current.lanes=p,La(c,p),Wa(c),s[er]=c.current,m_(s),new zv(c)},Jh.version="19.1.0",Jh}var IR;function TW(){if(IR)return k_.exports;IR=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(),k_.exports=OW(),k_.exports}var jW=TW(),M=wb();const pe=zt(M),_b=wW({__proto__:null,default:pe},[M]);var U_={exports:{}},z_={};/**
|
||
* @license React
|
||
* use-sync-external-store-with-selector.production.js
|
||
*
|
||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var $R;function PW(){if($R)return z_;$R=1;var e=wb();function t(f,u){return f===u&&(f!==0||1/f===1/u)||f!==f&&u!==u}var n=typeof Object.is=="function"?Object.is:t,r=e.useSyncExternalStore,i=e.useRef,a=e.useEffect,o=e.useMemo,l=e.useDebugValue;return z_.useSyncExternalStoreWithSelector=function(f,u,h,m,g){var _=i(null);if(_.current===null){var x={hasValue:!1,value:null};_.current=x}else x=_.current;_=o(function(){function S(j){if(!C){if(C=!0,A=j,j=m(j),g!==void 0&&x.hasValue){var R=x.value;if(g(R,j))return O=R}return O=j}if(R=O,n(A,j))return R;var U=m(j);return g!==void 0&&g(R,U)?(A=j,R):(A=j,O=U)}var C=!1,A,O,P=h===void 0?null:h;return[function(){return S(u())},P===null?void 0:function(){return S(P())}]},[u,h,m,g]);var b=r(f,_[0],_[1]);return a(function(){x.hasValue=!0,x.value=b},[b]),l(b),b},z_}var BR;function RW(){return BR||(BR=1,U_.exports=PW()),U_.exports}RW();var MW=M.version.startsWith("19"),NW=Symbol.for(MW?"react.transitional.element":"react.element"),LW=Symbol.for("react.portal"),kW=Symbol.for("react.fragment"),DW=Symbol.for("react.strict_mode"),IW=Symbol.for("react.profiler"),$W=Symbol.for("react.consumer"),BW=Symbol.for("react.context"),K7=Symbol.for("react.forward_ref"),UW=Symbol.for("react.suspense"),zW=Symbol.for("react.suspense_list"),QO=Symbol.for("react.memo"),FW=Symbol.for("react.lazy"),qW=K7,VW=QO;function HW(e){if(typeof e=="object"&&e!==null){const{$$typeof:t}=e;switch(t){case NW:switch(e=e.type,e){case kW:case IW:case DW:case UW:case zW:return e;default:switch(e=e&&e.$$typeof,e){case BW:case K7:case FW:case QO:return e;case $W:return e;default:return t}}case LW:return t}}}function GW(e){return HW(e)===QO}function WW(e,t,n,r,{areStatesEqual:i,areOwnPropsEqual:a,areStatePropsEqual:o}){let l=!1,f,u,h,m,g;function _(A,O){return f=A,u=O,h=e(f,u),m=t(r,u),g=n(h,m,u),l=!0,g}function x(){return h=e(f,u),t.dependsOnOwnProps&&(m=t(r,u)),g=n(h,m,u),g}function b(){return e.dependsOnOwnProps&&(h=e(f,u)),t.dependsOnOwnProps&&(m=t(r,u)),g=n(h,m,u),g}function S(){const A=e(f,u),O=!o(A,h);return h=A,O&&(g=n(h,m,u)),g}function C(A,O){const P=!a(O,u),j=!i(A,f,O,u);return f=A,u=O,P&&j?x():P?b():j?S():g}return function(O,P){return l?C(O,P):_(O,P)}}function YW(e,{initMapStateToProps:t,initMapDispatchToProps:n,initMergeProps:r,...i}){const a=t(e,i),o=n(e,i),l=r(e,i);return WW(a,o,l,e,i)}function KW(e,t){const n={};for(const r in e){const i=e[r];typeof i=="function"&&(n[r]=(...a)=>t(i(...a)))}return n}function NA(e){return function(n){const r=e(n);function i(){return r}return i.dependsOnOwnProps=!1,i}}function UR(e){return e.dependsOnOwnProps?!!e.dependsOnOwnProps:e.length!==1}function Z7(e,t){return function(r,{displayName:i}){const a=function(l,f){return a.dependsOnOwnProps?a.mapToProps(l,f):a.mapToProps(l,void 0)};return a.dependsOnOwnProps=!0,a.mapToProps=function(l,f){a.mapToProps=e,a.dependsOnOwnProps=UR(e);let u=a(l,f);return typeof u=="function"&&(a.mapToProps=u,a.dependsOnOwnProps=UR(u),u=a(l,f)),u},a}}function JO(e,t){return(n,r)=>{throw new Error(`Invalid value of type ${typeof e} for ${t} argument when connecting component ${r.wrappedComponentName}.`)}}function ZW(e){return e&&typeof e=="object"?NA(t=>KW(e,t)):e?typeof e=="function"?Z7(e):JO(e,"mapDispatchToProps"):NA(t=>({dispatch:t}))}function XW(e){return e?typeof e=="function"?Z7(e):JO(e,"mapStateToProps"):NA(()=>({}))}function QW(e,t,n){return{...n,...e,...t}}function JW(e){return function(n,{displayName:r,areMergedPropsEqual:i}){let a=!1,o;return function(f,u,h){const m=e(f,u,h);return a?i(m,o)||(o=m):(a=!0,o=m),o}}}function eY(e){return e?typeof e=="function"?JW(e):JO(e,"mergeProps"):()=>QW}function tY(e){e()}function nY(){let e=null,t=null;return{clear(){e=null,t=null},notify(){tY(()=>{let n=e;for(;n;)n.callback(),n=n.next})},get(){const n=[];let r=e;for(;r;)n.push(r),r=r.next;return n},subscribe(n){let r=!0;const i=t={callback:n,next:null,prev:t};return i.prev?i.prev.next=i:e=i,function(){!r||e===null||(r=!1,i.next?i.next.prev=i.prev:t=i.prev,i.prev?i.prev.next=i.next:e=i.next)}}}}var zR={notify(){},get:()=>[]};function X7(e,t){let n,r=zR,i=0,a=!1;function o(b){h();const S=r.subscribe(b);let C=!1;return()=>{C||(C=!0,S(),m())}}function l(){r.notify()}function f(){x.onStateChange&&x.onStateChange()}function u(){return a}function h(){i++,n||(n=t?t.addNestedSub(f):e.subscribe(f),r=nY())}function m(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=zR)}function g(){a||(a=!0,h())}function _(){a&&(a=!1,m())}const x={addNestedSub:o,notifyNestedSubs:l,handleChangeWrapper:f,isSubscribed:u,trySubscribe:g,tryUnsubscribe:_,getListeners:()=>r};return x}var rY=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",iY=rY(),aY=()=>typeof navigator<"u"&&navigator.product==="ReactNative",oY=aY(),sY=()=>iY||oY?M.useLayoutEffect:M.useEffect,ky=sY();function FR(e,t){return e===t?e!==0||t!==0||1/e===1/t:e!==e&&t!==t}function F_(e,t){if(FR(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let i=0;i<n.length;i++)if(!Object.prototype.hasOwnProperty.call(t,n[i])||!FR(e[n[i]],t[n[i]]))return!1;return!0}var lY={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},uY={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},cY={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Q7={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},fY={[qW]:cY,[VW]:Q7};function qR(e){return GW(e)?Q7:fY[e.$$typeof]||lY}var dY=Object.defineProperty,hY=Object.getOwnPropertyNames,VR=Object.getOwnPropertySymbols,pY=Object.getOwnPropertyDescriptor,mY=Object.getPrototypeOf,HR=Object.prototype;function LA(e,t){if(typeof t!="string"){if(HR){const a=mY(t);a&&a!==HR&&LA(e,a)}let n=hY(t);VR&&(n=n.concat(VR(t)));const r=qR(e),i=qR(t);for(let a=0;a<n.length;++a){const o=n[a];if(!uY[o]&&!(i&&i[o])&&!(r&&r[o])){const l=pY(t,o);try{dY(e,o,l)}catch{}}}}return e}var q_=Symbol.for("react-redux-context"),V_=typeof globalThis<"u"?globalThis:{};function gY(){if(!M.createContext)return{};const e=V_[q_]??(V_[q_]=new Map);let t=e.get(M.createContext);return t||(t=M.createContext(null),e.set(M.createContext,t)),t}var J7=gY(),vY=[null,null];function yY(e,t,n){ky(()=>e(...t),n)}function bY(e,t,n,r,i,a){e.current=r,n.current=!1,i.current&&(i.current=null,a())}function wY(e,t,n,r,i,a,o,l,f,u,h){if(!e)return()=>{};let m=!1,g=null;const _=()=>{if(m||!l.current)return;const b=t.getState();let S,C;try{S=r(b,i.current)}catch(A){C=A,g=A}C||(g=null),S===a.current?o.current||u():(a.current=S,f.current=S,o.current=!0,h())};return n.onStateChange=_,n.trySubscribe(),_(),()=>{if(m=!0,n.tryUnsubscribe(),n.onStateChange=null,g)throw g}}function _Y(e,t){return e===t}function xY(e,t,n,{pure:r,areStatesEqual:i=_Y,areOwnPropsEqual:a=F_,areStatePropsEqual:o=F_,areMergedPropsEqual:l=F_,forwardRef:f=!1,context:u=J7}={}){const h=u,m=XW(e),g=ZW(t),_=eY(n),x=!!e;return S=>{const C=S.displayName||S.name||"Component",A=`Connect(${C})`,O={shouldHandleStateChanges:x,displayName:A,wrappedComponentName:C,WrappedComponent:S,initMapStateToProps:m,initMapDispatchToProps:g,initMergeProps:_,areStatesEqual:i,areStatePropsEqual:o,areOwnPropsEqual:a,areMergedPropsEqual:l};function P(U){const[V,Y,K]=M.useMemo(()=>{const{reactReduxForwardedRef:J,...se}=U;return[U.context,J,se]},[U]),W=M.useMemo(()=>{let J=h;return V!=null&&V.Consumer,J},[V,h]),ee=M.useContext(W),ie=!!U.store&&!!U.store.getState&&!!U.store.dispatch,X=!!ee&&!!ee.store,ne=ie?U.store:ee.store,H=X?ee.getServerState:ne.getState,I=M.useMemo(()=>YW(ne.dispatch,O),[ne]),[D,z]=M.useMemo(()=>{if(!x)return vY;const J=X7(ne,ie?void 0:ee.subscription),se=J.notifyNestedSubs.bind(J);return[J,se]},[ne,ie,ee]),N=M.useMemo(()=>ie?ee:{...ee,subscription:D},[ie,ee,D]),B=M.useRef(void 0),Q=M.useRef(K),G=M.useRef(void 0),ae=M.useRef(!1),fe=M.useRef(!1),ce=M.useRef(void 0);ky(()=>(fe.current=!0,()=>{fe.current=!1}),[]);const ye=M.useMemo(()=>()=>G.current&&K===Q.current?G.current:I(ne.getState(),K),[ne,K]),F=M.useMemo(()=>se=>D?wY(x,ne,D,I,Q,B,ae,fe,G,z,se):()=>{},[D]);yY(bY,[Q,B,ae,K,G,z]);let q;try{q=M.useSyncExternalStore(F,ye,H?()=>I(H(),K):ye)}catch(J){throw ce.current&&(J.message+=`
|
||
The error may be correlated with this previous error:
|
||
${ce.current.stack}
|
||
|
||
`),J}ky(()=>{ce.current=void 0,G.current=void 0,B.current=q});const te=M.useMemo(()=>M.createElement(S,{...q,ref:Y}),[Y,S,q]);return M.useMemo(()=>x?M.createElement(W.Provider,{value:N},te):te,[W,te,N])}const R=M.memo(P);if(R.WrappedComponent=S,R.displayName=P.displayName=A,f){const V=M.forwardRef(function(K,W){return M.createElement(R,{...K,reactReduxForwardedRef:W})});return V.displayName=A,V.WrappedComponent=S,LA(V,S)}return LA(R,S)}}var e9=xY;function SY(e){const{children:t,context:n,serverState:r,store:i}=e,a=M.useMemo(()=>{const f=X7(i);return{store:i,subscription:f,getServerState:r?()=>r:void 0}},[i,r]),o=M.useMemo(()=>i.getState(),[i]);ky(()=>{const{subscription:f}=a;return f.onStateChange=f.notifyNestedSubs,f.trySubscribe(),o!==i.getState()&&f.notifyNestedSubs(),()=>{f.tryUnsubscribe(),f.onStateChange=void 0}},[a,o]);const l=n||J7;return M.createElement(l.Provider,{value:a},t)}var t9=SY,ep={},GR;function CY(){if(GR)return ep;GR=1,Object.defineProperty(ep,"__esModule",{value:!0}),ep.parse=o,ep.serialize=u;const e=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,t=/^[\u0021-\u003A\u003C-\u007E]*$/,n=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,r=/^[\u0020-\u003A\u003D-\u007E]*$/,i=Object.prototype.toString,a=(()=>{const g=function(){};return g.prototype=Object.create(null),g})();function o(g,_){const x=new a,b=g.length;if(b<2)return x;const S=(_==null?void 0:_.decode)||h;let C=0;do{const A=g.indexOf("=",C);if(A===-1)break;const O=g.indexOf(";",C),P=O===-1?b:O;if(A>P){C=g.lastIndexOf(";",A-1)+1;continue}const j=l(g,C,A),R=f(g,A,j),U=g.slice(j,R);if(x[U]===void 0){let V=l(g,A+1,P),Y=f(g,P,V);const K=S(g.slice(V,Y));x[U]=K}C=P+1}while(C<b);return x}function l(g,_,x){do{const b=g.charCodeAt(_);if(b!==32&&b!==9)return _}while(++_<x);return x}function f(g,_,x){for(;_>x;){const b=g.charCodeAt(--_);if(b!==32&&b!==9)return _+1}return x}function u(g,_,x){const b=(x==null?void 0:x.encode)||encodeURIComponent;if(!e.test(g))throw new TypeError(`argument name is invalid: ${g}`);const S=b(_);if(!t.test(S))throw new TypeError(`argument val is invalid: ${_}`);let C=g+"="+S;if(!x)return C;if(x.maxAge!==void 0){if(!Number.isInteger(x.maxAge))throw new TypeError(`option maxAge is invalid: ${x.maxAge}`);C+="; Max-Age="+x.maxAge}if(x.domain){if(!n.test(x.domain))throw new TypeError(`option domain is invalid: ${x.domain}`);C+="; Domain="+x.domain}if(x.path){if(!r.test(x.path))throw new TypeError(`option path is invalid: ${x.path}`);C+="; Path="+x.path}if(x.expires){if(!m(x.expires)||!Number.isFinite(x.expires.valueOf()))throw new TypeError(`option expires is invalid: ${x.expires}`);C+="; Expires="+x.expires.toUTCString()}if(x.httpOnly&&(C+="; HttpOnly"),x.secure&&(C+="; Secure"),x.partitioned&&(C+="; Partitioned"),x.priority)switch(typeof x.priority=="string"?x.priority.toLowerCase():void 0){case"low":C+="; Priority=Low";break;case"medium":C+="; Priority=Medium";break;case"high":C+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${x.priority}`)}if(x.sameSite)switch(typeof x.sameSite=="string"?x.sameSite.toLowerCase():x.sameSite){case!0:case"strict":C+="; SameSite=Strict";break;case"lax":C+="; SameSite=Lax";break;case"none":C+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${x.sameSite}`)}return C}function h(g){if(g.indexOf("%")===-1)return g;try{return decodeURIComponent(g)}catch{return g}}function m(g){return i.call(g)==="[object Date]"}return ep}CY();var WR="popstate";function AY(e={}){function t(r,i){let{pathname:a,search:o,hash:l}=r.location;return kA("",{pathname:a,search:o,hash:l},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Hp(i)}return OY(t,n,null,e)}function bn(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Sa(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function EY(){return Math.random().toString(36).substring(2,10)}function YR(e,t){return{usr:e.state,key:e.key,idx:t}}function kA(e,t,n=null,r){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?Ed(t):t,state:n,key:t&&t.key||r||EY()}}function Hp({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 Ed(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 OY(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,l="POP",f=null,u=h();u==null&&(u=0,o.replaceState({...o.state,idx:u},""));function h(){return(o.state||{idx:null}).idx}function m(){l="POP";let S=h(),C=S==null?null:S-u;u=S,f&&f({action:l,location:b.location,delta:C})}function g(S,C){l="PUSH";let A=kA(b.location,S,C);u=h()+1;let O=YR(A,u),P=b.createHref(A);try{o.pushState(O,"",P)}catch(j){if(j instanceof DOMException&&j.name==="DataCloneError")throw j;i.location.assign(P)}a&&f&&f({action:l,location:b.location,delta:1})}function _(S,C){l="REPLACE";let A=kA(b.location,S,C);u=h();let O=YR(A,u),P=b.createHref(A);o.replaceState(O,"",P),a&&f&&f({action:l,location:b.location,delta:0})}function x(S){return TY(S)}let b={get action(){return l},get location(){return e(i,o)},listen(S){if(f)throw new Error("A history only accepts one active listener");return i.addEventListener(WR,m),f=S,()=>{i.removeEventListener(WR,m),f=null}},createHref(S){return t(i,S)},createURL:x,encodeLocation(S){let C=x(S);return{pathname:C.pathname,search:C.search,hash:C.hash}},push:g,replace:_,go(S){return o.go(S)}};return b}function TY(e,t=!1){let n="http://localhost";typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),bn(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:Hp(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function n9(e,t,n="/"){return jY(e,t,n,!1)}function jY(e,t,n,r){let i=typeof t=="string"?Ed(t):t,a=ns(i.pathname||"/",n);if(a==null)return null;let o=r9(e);PY(o);let l=null;for(let f=0;l==null&&f<o.length;++f){let u=zY(a);l=BY(o[f],u,r)}return l}function r9(e,t=[],n=[],r=""){let i=(a,o,l)=>{let f={relativePath:l===void 0?a.path||"":l,caseSensitive:a.caseSensitive===!0,childrenIndex:o,route:a};f.relativePath.startsWith("/")&&(bn(f.relativePath.startsWith(r),`Absolute route path "${f.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),f.relativePath=f.relativePath.slice(r.length));let u=Xo([r,f.relativePath]),h=n.concat(f);a.children&&a.children.length>0&&(bn(a.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${u}".`),r9(a.children,t,h,u)),!(a.path==null&&!a.index)&&t.push({path:u,score:IY(u,a.index),routesMeta:h})};return e.forEach((a,o)=>{var l;if(a.path===""||!((l=a.path)!=null&&l.includes("?")))i(a,o);else for(let f of i9(a.path))i(a,o,f)}),t}function i9(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),a=n.replace(/\?$/,"");if(r.length===0)return i?[a,""]:[a];let o=i9(r.join("/")),l=[];return l.push(...o.map(f=>f===""?a:[a,f].join("/"))),i&&l.push(...o),l.map(f=>e.startsWith("/")&&f===""?"/":f)}function PY(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:$Y(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var RY=/^:[\w-]+$/,MY=3,NY=2,LY=1,kY=10,DY=-2,KR=e=>e==="*";function IY(e,t){let n=e.split("/"),r=n.length;return n.some(KR)&&(r+=DY),t&&(r+=NY),n.filter(i=>!KR(i)).reduce((i,a)=>i+(RY.test(a)?MY:a===""?LY:kY),r)}function $Y(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 BY(e,t,n=!1){let{routesMeta:r}=e,i={},a="/",o=[];for(let l=0;l<r.length;++l){let f=r[l],u=l===r.length-1,h=a==="/"?t:t.slice(a.length)||"/",m=Dy({path:f.relativePath,caseSensitive:f.caseSensitive,end:u},h),g=f.route;if(!m&&u&&n&&!r[r.length-1].route.index&&(m=Dy({path:f.relativePath,caseSensitive:f.caseSensitive,end:!1},h)),!m)return null;Object.assign(i,m.params),o.push({params:i,pathname:Xo([a,m.pathname]),pathnameBase:HY(Xo([a,m.pathnameBase])),route:g}),m.pathnameBase!=="/"&&(a=Xo([a,m.pathnameBase]))}return o}function Dy(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=UY(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,"$1"),l=i.slice(1);return{params:r.reduce((u,{paramName:h,isOptional:m},g)=>{if(h==="*"){let x=l[g]||"";o=a.slice(0,a.length-x.length).replace(/(.)\/+$/,"$1")}const _=l[g];return m&&!_?u[h]=void 0:u[h]=(_||"").replace(/%2F/g,"/"),u},{}),pathname:a,pathnameBase:o,pattern:e}}function UY(e,t=!1,n=!0){Sa(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,l,f)=>(r.push({paramName:l,isOptional:f!=null}),f?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function zY(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Sa(!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 ns(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function FY(e,t="/"){let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Ed(e):e;return{pathname:n?n.startsWith("/")?n:qY(n,t):t,search:GY(r),hash:WY(i)}}function qY(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 H_(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 VY(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function eT(e){let t=VY(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function tT(e,t,n,r=!1){let i;typeof e=="string"?i=Ed(e):(i={...e},bn(!i.pathname||!i.pathname.includes("?"),H_("?","pathname","search",i)),bn(!i.pathname||!i.pathname.includes("#"),H_("#","pathname","hash",i)),bn(!i.search||!i.search.includes("#"),H_("#","search","hash",i)));let a=e===""||i.pathname==="",o=a?"/":i.pathname,l;if(o==null)l=n;else{let m=t.length-1;if(!r&&o.startsWith("..")){let g=o.split("/");for(;g[0]==="..";)g.shift(),m-=1;i.pathname=g.join("/")}l=m>=0?t[m]:"/"}let f=FY(i,l),u=o&&o!=="/"&&o.endsWith("/"),h=(a||o===".")&&n.endsWith("/");return!f.pathname.endsWith("/")&&(u||h)&&(f.pathname+="/"),f}var Xo=e=>e.join("/").replace(/\/\/+/g,"/"),HY=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),GY=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,WY=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function YY(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}var a9=["POST","PUT","PATCH","DELETE"];new Set(a9);var KY=["GET",...a9];new Set(KY);var Od=M.createContext(null);Od.displayName="DataRouter";var xb=M.createContext(null);xb.displayName="DataRouterState";var o9=M.createContext({isTransitioning:!1});o9.displayName="ViewTransition";var ZY=M.createContext(new Map);ZY.displayName="Fetchers";var XY=M.createContext(null);XY.displayName="Await";var Oa=M.createContext(null);Oa.displayName="Navigation";var Gm=M.createContext(null);Gm.displayName="Location";var Ta=M.createContext({outlet:null,matches:[],isDataRoute:!1});Ta.displayName="Route";var nT=M.createContext(null);nT.displayName="RouteError";function QY(e,{relative:t}={}){bn(cc(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=M.useContext(Oa),{hash:i,pathname:a,search:o}=Wm(e,{relative:t}),l=a;return n!=="/"&&(l=a==="/"?n:Xo([n,a])),r.createHref({pathname:l,search:o,hash:i})}function cc(){return M.useContext(Gm)!=null}function Sr(){return bn(cc(),"useLocation() may be used only in the context of a <Router> component."),M.useContext(Gm).location}var s9="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function l9(e){M.useContext(Oa).static||M.useLayoutEffect(e)}function po(){let{isDataRoute:e}=M.useContext(Ta);return e?fK():JY()}function JY(){bn(cc(),"useNavigate() may be used only in the context of a <Router> component.");let e=M.useContext(Od),{basename:t,navigator:n}=M.useContext(Oa),{matches:r}=M.useContext(Ta),{pathname:i}=Sr(),a=JSON.stringify(eT(r)),o=M.useRef(!1);return l9(()=>{o.current=!0}),M.useCallback((f,u={})=>{if(Sa(o.current,s9),!o.current)return;if(typeof f=="number"){n.go(f);return}let h=tT(f,JSON.parse(a),i,u.relative==="path");e==null&&t!=="/"&&(h.pathname=h.pathname==="/"?t:Xo([t,h.pathname])),(u.replace?n.replace:n.push)(h,u.state,u)},[t,n,a,i,e])}M.createContext(null);function Td(){let{matches:e}=M.useContext(Ta),t=e[e.length-1];return t?t.params:{}}function Wm(e,{relative:t}={}){let{matches:n}=M.useContext(Ta),{pathname:r}=Sr(),i=JSON.stringify(eT(n));return M.useMemo(()=>tT(e,JSON.parse(i),r,t==="path"),[e,i,r,t])}function eK(e,t){return u9(e,t)}function u9(e,t,n,r){var C;bn(cc(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:i}=M.useContext(Oa),{matches:a}=M.useContext(Ta),o=a[a.length-1],l=o?o.params:{},f=o?o.pathname:"/",u=o?o.pathnameBase:"/",h=o&&o.route;{let A=h&&h.path||"";c9(f,!h||A.endsWith("*")||A.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${f}" (under <Route path="${A}">) 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.
|
||
|
||
Please change the parent <Route path="${A}"> to <Route path="${A==="/"?"*":`${A}/*`}">.`)}let m=Sr(),g;if(t){let A=typeof t=="string"?Ed(t):t;bn(u==="/"||((C=A.pathname)==null?void 0:C.startsWith(u)),`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 "${u}" but pathname "${A.pathname}" was given in the \`location\` prop.`),g=A}else g=m;let _=g.pathname||"/",x=_;if(u!=="/"){let A=u.replace(/^\//,"").split("/");x="/"+_.replace(/^\//,"").split("/").slice(A.length).join("/")}let b=n9(e,{pathname:x});Sa(h||b!=null,`No routes matched location "${g.pathname}${g.search}${g.hash}" `),Sa(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${g.pathname}${g.search}${g.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 S=aK(b&&b.map(A=>Object.assign({},A,{params:Object.assign({},l,A.params),pathname:Xo([u,i.encodeLocation?i.encodeLocation(A.pathname).pathname:A.pathname]),pathnameBase:A.pathnameBase==="/"?u:Xo([u,i.encodeLocation?i.encodeLocation(A.pathnameBase).pathname:A.pathnameBase])})),a,n,r);return t&&S?M.createElement(Gm.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...g},navigationType:"POP"}},S):S}function tK(){let e=cK(),t=YY(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},a={padding:"2px 4px",backgroundColor:r},o=null;return console.error("Error handled by React Router default ErrorBoundary:",e),o=M.createElement(M.Fragment,null,M.createElement("p",null,"💿 Hey developer 👋"),M.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",M.createElement("code",{style:a},"ErrorBoundary")," or"," ",M.createElement("code",{style:a},"errorElement")," prop on your route.")),M.createElement(M.Fragment,null,M.createElement("h2",null,"Unexpected Application Error!"),M.createElement("h3",{style:{fontStyle:"italic"}},t),n?M.createElement("pre",{style:i},n):null,o)}var nK=M.createElement(tK,null),rK=class extends M.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){console.error("React Router caught the following error during render",e,t)}render(){return this.state.error!==void 0?M.createElement(Ta.Provider,{value:this.props.routeContext},M.createElement(nT.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function iK({routeContext:e,match:t,children:n}){let r=M.useContext(Od);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),M.createElement(Ta.Provider,{value:e},n)}function aK(e,t=[],n=null,r=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 i=e,a=n==null?void 0:n.errors;if(a!=null){let f=i.findIndex(u=>u.route.id&&(a==null?void 0:a[u.route.id])!==void 0);bn(f>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(",")}`),i=i.slice(0,Math.min(i.length,f+1))}let o=!1,l=-1;if(n)for(let f=0;f<i.length;f++){let u=i[f];if((u.route.HydrateFallback||u.route.hydrateFallbackElement)&&(l=f),u.route.id){let{loaderData:h,errors:m}=n,g=u.route.loader&&!h.hasOwnProperty(u.route.id)&&(!m||m[u.route.id]===void 0);if(u.route.lazy||g){o=!0,l>=0?i=i.slice(0,l+1):i=[i[0]];break}}}return i.reduceRight((f,u,h)=>{let m,g=!1,_=null,x=null;n&&(m=a&&u.route.id?a[u.route.id]:void 0,_=u.route.errorElement||nK,o&&(l<0&&h===0?(c9("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),g=!0,x=null):l===h&&(g=!0,x=u.route.hydrateFallbackElement||null)));let b=t.concat(i.slice(0,h+1)),S=()=>{let C;return m?C=_:g?C=x:u.route.Component?C=M.createElement(u.route.Component,null):u.route.element?C=u.route.element:C=f,M.createElement(iK,{match:u,routeContext:{outlet:f,matches:b,isDataRoute:n!=null},children:C})};return n&&(u.route.ErrorBoundary||u.route.errorElement||h===0)?M.createElement(rK,{location:n.location,revalidation:n.revalidation,component:_,error:m,children:S(),routeContext:{outlet:null,matches:b,isDataRoute:!0}}):S()},null)}function rT(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function oK(e){let t=M.useContext(Od);return bn(t,rT(e)),t}function sK(e){let t=M.useContext(xb);return bn(t,rT(e)),t}function lK(e){let t=M.useContext(Ta);return bn(t,rT(e)),t}function iT(e){let t=lK(e),n=t.matches[t.matches.length-1];return bn(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function uK(){return iT("useRouteId")}function cK(){var r;let e=M.useContext(nT),t=sK("useRouteError"),n=iT("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function fK(){let{router:e}=oK("useNavigate"),t=iT("useNavigate"),n=M.useRef(!1);return l9(()=>{n.current=!0}),M.useCallback(async(i,a={})=>{Sa(n.current,s9),n.current&&(typeof i=="number"?e.navigate(i):await e.navigate(i,{fromRouteId:t,...a}))},[e,t])}var ZR={};function c9(e,t,n){!t&&!ZR[e]&&(ZR[e]=!0,Sa(!1,n))}M.memo(dK);function dK({routes:e,future:t,state:n}){return u9(e,void 0,n,t)}function aT({to:e,replace:t,state:n,relative:r}){bn(cc(),"<Navigate> may be used only in the context of a <Router> component.");let{static:i}=M.useContext(Oa);Sa(!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:a}=M.useContext(Ta),{pathname:o}=Sr(),l=po(),f=tT(e,eT(a),o,r==="path"),u=JSON.stringify(f);return M.useEffect(()=>{l(JSON.parse(u),{replace:t,state:n,relative:r})},[l,u,r,t,n]),null}function xt(e){bn(!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 hK({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:a=!1}){bn(!cc(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let o=e.replace(/^\/*/,"/"),l=M.useMemo(()=>({basename:o,navigator:i,static:a,future:{}}),[o,i,a]);typeof n=="string"&&(n=Ed(n));let{pathname:f="/",search:u="",hash:h="",state:m=null,key:g="default"}=n,_=M.useMemo(()=>{let x=ns(f,o);return x==null?null:{location:{pathname:x,search:u,hash:h,state:m,key:g},navigationType:r}},[o,f,u,h,m,g,r]);return Sa(_!=null,`<Router basename="${o}"> is not able to match the URL "${f}${u}${h}" because it does not start with the basename, so the <Router> won't render anything.`),_==null?null:M.createElement(Oa.Provider,{value:l},M.createElement(Gm.Provider,{children:t,value:_}))}function Sb({children:e,location:t}){return eK(DA(e),t)}function DA(e,t=[]){let n=[];return M.Children.forEach(e,(r,i)=>{if(!M.isValidElement(r))return;let a=[...t,i];if(r.type===M.Fragment){n.push.apply(n,DA(r.props.children,a));return}bn(r.type===xt,`[${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>`),bn(!r.props.index||!r.props.children,"An index route cannot have child routes.");let o={id:r.props.id||a.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,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&&(o.children=DA(r.props.children,a)),n.push(o)}),n}var Cy="get",Ay="application/x-www-form-urlencoded";function Cb(e){return e!=null&&typeof e.tagName=="string"}function pK(e){return Cb(e)&&e.tagName.toLowerCase()==="button"}function mK(e){return Cb(e)&&e.tagName.toLowerCase()==="form"}function gK(e){return Cb(e)&&e.tagName.toLowerCase()==="input"}function vK(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function yK(e,t){return e.button===0&&(!t||t==="_self")&&!vK(e)}var Vv=null;function bK(){if(Vv===null)try{new FormData(document.createElement("form"),0),Vv=!1}catch{Vv=!0}return Vv}var wK=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function G_(e){return e!=null&&!wK.has(e)?(Sa(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Ay}"`),null):e}function _K(e,t){let n,r,i,a,o;if(mK(e)){let l=e.getAttribute("action");r=l?ns(l,t):null,n=e.getAttribute("method")||Cy,i=G_(e.getAttribute("enctype"))||Ay,a=new FormData(e)}else if(pK(e)||gK(e)&&(e.type==="submit"||e.type==="image")){let l=e.form;if(l==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let f=e.getAttribute("formaction")||l.getAttribute("action");if(r=f?ns(f,t):null,n=e.getAttribute("formmethod")||l.getAttribute("method")||Cy,i=G_(e.getAttribute("formenctype"))||G_(l.getAttribute("enctype"))||Ay,a=new FormData(l,e),!bK()){let{name:u,type:h,value:m}=e;if(h==="image"){let g=u?`${u}.`:"";a.append(`${g}x`,"0"),a.append(`${g}y`,"0")}else u&&a.append(u,m)}}else{if(Cb(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Cy,r=null,i=Ay,o=e}return a&&i==="text/plain"&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}function oT(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}async function xK(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 SK(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 CK(e,t,n){let r=await Promise.all(e.map(async i=>{let a=t.routes[i.route.id];if(a){let o=await xK(a,n);return o.links?o.links():[]}return[]}));return TK(r.flat(1).filter(SK).filter(i=>i.rel==="stylesheet"||i.rel==="preload").map(i=>i.rel==="stylesheet"?{...i,rel:"prefetch",as:"style"}:{...i,rel:"prefetch"}))}function XR(e,t,n,r,i,a){let o=(f,u)=>n[u]?f.route.id!==n[u].route.id:!0,l=(f,u)=>{var h;return n[u].pathname!==f.pathname||((h=n[u].route.path)==null?void 0:h.endsWith("*"))&&n[u].params["*"]!==f.params["*"]};return a==="assets"?t.filter((f,u)=>o(f,u)||l(f,u)):a==="data"?t.filter((f,u)=>{var m;let h=r.routes[f.route.id];if(!h||!h.hasLoader)return!1;if(o(f,u)||l(f,u))return!0;if(f.route.shouldRevalidate){let g=f.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:((m=n[0])==null?void 0:m.params)||{},nextUrl:new URL(e,window.origin),nextParams:f.params,defaultShouldRevalidate:!0});if(typeof g=="boolean")return g}return!0}):[]}function AK(e,t,{includeHydrateFallback:n}={}){return EK(e.map(r=>{let i=t.routes[r.route.id];if(!i)return[];let a=[i.module];return i.clientActionModule&&(a=a.concat(i.clientActionModule)),i.clientLoaderModule&&(a=a.concat(i.clientLoaderModule)),n&&i.hydrateFallbackModule&&(a=a.concat(i.hydrateFallbackModule)),i.imports&&(a=a.concat(i.imports)),a}).flat(1))}function EK(e){return[...new Set(e)]}function OK(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function TK(e,t){let n=new Set;return new Set(t),e.reduce((r,i)=>{let a=JSON.stringify(OK(i));return n.has(a)||(n.add(a),r.push({key:a,link:i})),r},[])}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var jK=new Set([100,101,204,205]);function PK(e,t){let n=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return n.pathname==="/"?n.pathname="_root.data":t&&ns(n.pathname,t)==="/"?n.pathname=`${t.replace(/\/$/,"")}/_root.data`:n.pathname=`${n.pathname.replace(/\/$/,"")}.data`,n}function f9(){let e=M.useContext(Od);return oT(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function RK(){let e=M.useContext(xb);return oT(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var sT=M.createContext(void 0);sT.displayName="FrameworkContext";function d9(){let e=M.useContext(sT);return oT(e,"You must render this element inside a <HydratedRouter> element"),e}function MK(e,t){let n=M.useContext(sT),[r,i]=M.useState(!1),[a,o]=M.useState(!1),{onFocus:l,onBlur:f,onMouseEnter:u,onMouseLeave:h,onTouchStart:m}=t,g=M.useRef(null);M.useEffect(()=>{if(e==="render"&&o(!0),e==="viewport"){let b=C=>{C.forEach(A=>{o(A.isIntersecting)})},S=new IntersectionObserver(b,{threshold:.5});return g.current&&S.observe(g.current),()=>{S.disconnect()}}},[e]),M.useEffect(()=>{if(r){let b=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(b)}}},[r]);let _=()=>{i(!0)},x=()=>{i(!1),o(!1)};return n?e!=="intent"?[a,g,{}]:[a,g,{onFocus:tp(l,_),onBlur:tp(f,x),onMouseEnter:tp(u,_),onMouseLeave:tp(h,x),onTouchStart:tp(m,_)}]:[!1,g,{}]}function tp(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function NK({page:e,...t}){let{router:n}=f9(),r=M.useMemo(()=>n9(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?M.createElement(kK,{page:e,matches:r,...t}):null}function LK(e){let{manifest:t,routeModules:n}=d9(),[r,i]=M.useState([]);return M.useEffect(()=>{let a=!1;return CK(e,t,n).then(o=>{a||i(o)}),()=>{a=!0}},[e,t,n]),r}function kK({page:e,matches:t,...n}){let r=Sr(),{manifest:i,routeModules:a}=d9(),{basename:o}=f9(),{loaderData:l,matches:f}=RK(),u=M.useMemo(()=>XR(e,t,f,i,r,"data"),[e,t,f,i,r]),h=M.useMemo(()=>XR(e,t,f,i,r,"assets"),[e,t,f,i,r]),m=M.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let x=new Set,b=!1;if(t.forEach(C=>{var O;let A=i.routes[C.route.id];!A||!A.hasLoader||(!u.some(P=>P.route.id===C.route.id)&&C.route.id in l&&((O=a[C.route.id])!=null&&O.shouldRevalidate)||A.hasClientLoader?b=!0:x.add(C.route.id))}),x.size===0)return[];let S=PK(e,o);return b&&x.size>0&&S.searchParams.set("_routes",t.filter(C=>x.has(C.route.id)).map(C=>C.route.id).join(",")),[S.pathname+S.search]},[o,l,r,i,u,t,e,a]),g=M.useMemo(()=>AK(h,i),[h,i]),_=LK(h);return M.createElement(M.Fragment,null,m.map(x=>M.createElement("link",{key:x,rel:"prefetch",as:"fetch",href:x,...n})),g.map(x=>M.createElement("link",{key:x,rel:"modulepreload",href:x,...n})),_.map(({key:x,link:b})=>M.createElement("link",{key:x,...b})))}function DK(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var h9=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{h9&&(window.__reactRouterVersion="7.6.2")}catch{}function p9({basename:e,children:t,window:n}){let r=M.useRef();r.current==null&&(r.current=AY({window:n,v5Compat:!0}));let i=r.current,[a,o]=M.useState({action:i.action,location:i.location}),l=M.useCallback(f=>{M.startTransition(()=>o(f))},[o]);return M.useLayoutEffect(()=>i.listen(l),[i,l]),M.createElement(hK,{basename:e,children:t,location:a.location,navigationType:a.action,navigator:i})}var m9=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,ur=M.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:i,reloadDocument:a,replace:o,state:l,target:f,to:u,preventScrollReset:h,viewTransition:m,...g},_){let{basename:x}=M.useContext(Oa),b=typeof u=="string"&&m9.test(u),S,C=!1;if(typeof u=="string"&&b&&(S=u,h9))try{let Y=new URL(window.location.href),K=u.startsWith("//")?new URL(Y.protocol+u):new URL(u),W=ns(K.pathname,x);K.origin===Y.origin&&W!=null?u=W+K.search+K.hash:C=!0}catch{Sa(!1,`<Link to="${u}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let A=QY(u,{relative:i}),[O,P,j]=MK(r,g),R=BK(u,{replace:o,state:l,target:f,preventScrollReset:h,relative:i,viewTransition:m});function U(Y){t&&t(Y),Y.defaultPrevented||R(Y)}let V=M.createElement("a",{...g,...j,href:S||A,onClick:C||a?t:U,ref:DK(_,P),target:f,"data-discover":!b&&n==="render"?"true":void 0});return O&&!b?M.createElement(M.Fragment,null,V,M.createElement(NK,{page:A})):V});ur.displayName="Link";var Ab=M.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:i=!1,style:a,to:o,viewTransition:l,children:f,...u},h){let m=Wm(o,{relative:u.relative}),g=Sr(),_=M.useContext(xb),{navigator:x,basename:b}=M.useContext(Oa),S=_!=null&&VK(m)&&l===!0,C=x.encodeLocation?x.encodeLocation(m).pathname:m.pathname,A=g.pathname,O=_&&_.navigation&&_.navigation.location?_.navigation.location.pathname:null;n||(A=A.toLowerCase(),O=O?O.toLowerCase():null,C=C.toLowerCase()),O&&b&&(O=ns(O,b)||O);const P=C!=="/"&&C.endsWith("/")?C.length-1:C.length;let j=A===C||!i&&A.startsWith(C)&&A.charAt(P)==="/",R=O!=null&&(O===C||!i&&O.startsWith(C)&&O.charAt(C.length)==="/"),U={isActive:j,isPending:R,isTransitioning:S},V=j?t:void 0,Y;typeof r=="function"?Y=r(U):Y=[r,j?"active":null,R?"pending":null,S?"transitioning":null].filter(Boolean).join(" ");let K=typeof a=="function"?a(U):a;return M.createElement(ur,{...u,"aria-current":V,className:Y,ref:h,style:K,to:o,viewTransition:l},typeof f=="function"?f(U):f)});Ab.displayName="NavLink";var IK=M.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:a,method:o=Cy,action:l,onSubmit:f,relative:u,preventScrollReset:h,viewTransition:m,...g},_)=>{let x=FK(),b=qK(l,{relative:u}),S=o.toLowerCase()==="get"?"get":"post",C=typeof l=="string"&&m9.test(l),A=O=>{if(f&&f(O),O.defaultPrevented)return;O.preventDefault();let P=O.nativeEvent.submitter,j=(P==null?void 0:P.getAttribute("formmethod"))||o;x(P||O.currentTarget,{fetcherKey:t,method:j,navigate:n,replace:i,state:a,relative:u,preventScrollReset:h,viewTransition:m})};return M.createElement("form",{ref:_,method:S,action:b,onSubmit:r?f:A,...g,"data-discover":!C&&e==="render"?"true":void 0})});IK.displayName="Form";function $K(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function g9(e){let t=M.useContext(Od);return bn(t,$K(e)),t}function BK(e,{target:t,replace:n,state:r,preventScrollReset:i,relative:a,viewTransition:o}={}){let l=po(),f=Sr(),u=Wm(e,{relative:a});return M.useCallback(h=>{if(yK(h,t)){h.preventDefault();let m=n!==void 0?n:Hp(f)===Hp(u);l(e,{replace:m,state:r,preventScrollReset:i,relative:a,viewTransition:o})}},[f,l,u,n,r,t,e,i,a,o])}var UK=0,zK=()=>`__${String(++UK)}__`;function FK(){let{router:e}=g9("useSubmit"),{basename:t}=M.useContext(Oa),n=uK();return M.useCallback(async(r,i={})=>{let{action:a,method:o,encType:l,formData:f,body:u}=_K(r,t);if(i.navigate===!1){let h=i.fetcherKey||zK();await e.fetch(h,n,i.action||a,{preventScrollReset:i.preventScrollReset,formData:f,body:u,formMethod:i.method||o,formEncType:i.encType||l,flushSync:i.flushSync})}else await e.navigate(i.action||a,{preventScrollReset:i.preventScrollReset,formData:f,body:u,formMethod:i.method||o,formEncType:i.encType||l,replace:i.replace,state:i.state,fromRouteId:n,flushSync:i.flushSync,viewTransition:i.viewTransition})},[e,t,n])}function qK(e,{relative:t}={}){let{basename:n}=M.useContext(Oa),r=M.useContext(Ta);bn(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),a={...Wm(e||".",{relative:t})},o=Sr();if(e==null){a.search=o.search;let l=new URLSearchParams(a.search),f=l.getAll("index");if(f.some(h=>h==="")){l.delete("index"),f.filter(m=>m).forEach(m=>l.append("index",m));let h=l.toString();a.search=h?`?${h}`:""}}return(!e||e===".")&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(a.pathname=a.pathname==="/"?n:Xo([n,a.pathname])),Hp(a)}function VK(e,t={}){let n=M.useContext(o9);bn(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=g9("useViewTransitionState"),i=Wm(e,{relative:t.relative});if(!n.isTransitioning)return!1;let a=ns(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=ns(n.nextLocation.pathname,r)||n.nextLocation.pathname;return Dy(i.pathname,o)!=null||Dy(i.pathname,a)!=null}[...jK];const HK="/shlink-web-client/feature/tailwind-nabvar",Iy={homepage:HK};var Ca,so=".",v9="function",y9="string",b9="__global__",lT="Provider",GK=0,uT=Array.prototype.slice,WK=function(t,n){var r=t[n];if(r===void 0&&Ca.config.strict)throw new Error("Bottle was unable to resolve a service. `"+n+"` is undefined.");return r},Eb=function(t){var n;return this.nested[t]||(n=Ca.pop(),this.nested[t]=n,this.factory(t,function(){return n.container})),this.nested[t]},w9=function(t){return t.split(so).reduce(WK,this)},YK=function(t,n,r,i){var a={configurable:!0,enumerable:!0};return t.length?a.get=function(){var l=0,f=function(h){if(h)throw h;t[l]&&t[l++](r,f)};return f(),r}:(a.value=r,a.writable=!0),Object.defineProperty(i,n,a),i[n]},KK=function(t,n){var r,i;return typeof t===v9&&(n=t,t=b9),r=t.split(so),i=r.shift(),r.length?Eb.call(this,i).middleware(r.join(so),n):(this.middlewares[i]||(this.middlewares[i]=[]),this.middlewares[i].push(n)),this},ZK=function(t,n){return n(t)},QR=function(t,n){return(t[n]||[]).concat(t.__global__||[])},XK=function(t,n){var r,i,a,o,l;return this.id,a=this.container,o=this.decorators,l=this.middlewares,r=t+lT,i=Object.create(null),i[r]={configurable:!0,enumerable:!0,get:function(){var u=new n;return delete a[r],a[r]=u,u}},i[t]={configurable:!0,enumerable:!0,get:function(){var u=a[r],h;return u&&(h=QR(o,t).reduce(ZK,u.$get(a)),delete a[r],delete a[t]),h===void 0?h:YK(QR(l,t),t,h,a)}},Object.defineProperties(a,i),this},_9=function(t,n){var r,i;return r=t.split(so),this.providerMap[t]&&r.length===1&&!this.container[t+lT]?console.error(t+" provider already instantiated."):(this.originalProviders[t]=n,this.providerMap[t]=!0,i=r.shift(),r.length?(Eb.call(this,i).provider(r.join(so),n),this):XK.call(this,i,n))},cT=function(t,n){return _9.call(this,t,function(){this.$get=n})},x9=function(t,n,r){var i=arguments.length>3?uT.call(arguments,3):[],a=this;return cT.call(this,t,function(){var l=n,f=i.map(w9,a.container);return r?new(n.bind.apply(n,[null].concat(f))):l.apply(null,f)})},QK=function(t,n){return x9.apply(this,[t,n,!0].concat(uT.call(arguments,2)))},JK=function(t,n){return x9.apply(this,[t,n,!1].concat(uT.call(arguments,2)))},S9=function(t,n){Object.defineProperty(this,t,{configurable:!0,enumerable:!0,value:n,writable:!0})},C9=function(t,n){var r=t[n];return r||(r={},S9.call(t,n,r)),r},eZ=function(t,n){var r;return r=t.split(so),t=r.pop(),S9.call(r.reduce(C9,this.container),t,n),this},tZ=function(t,n){Object.defineProperty(this,t,{configurable:!1,enumerable:!0,value:n,writable:!1})},nZ=function(t,n){var r=t.split(so);return t=r.pop(),tZ.call(r.reduce(C9,this.container),t,n),this},A9=function(t,n){var r,i;return typeof t===v9&&(n=t,t=b9),r=t.split(so),i=r.shift(),r.length?Eb.call(this,i).decorator(r.join(so),n):(this.decorators[i]||(this.decorators[i]=[]),this.decorators[i].push(n)),this},rZ=function(t){return this.deferred.push(t),this},iZ=function(t){return(t||[]).map(w9,this.container)},aZ=function(t,n){return cT.call(this,t,function(i){return{instance:n.bind(n,i)}})},oZ=function(t){return!/^\$(?:decorator|register|list)$|Provider$/.test(t)},fT=function(t){return Object.keys(t||this.container||{}).filter(oZ)},$y={},sZ=function(t){var n;return typeof t===y9?(n=$y[t],n||($y[t]=n=new Ca,n.constant("BOTTLE_NAME",t)),n):new Ca},lZ=function(t){typeof t===y9?delete $y[t]:$y={}},E9=function(t){var n=t.$value===void 0?t:t.$value;return this[t.$type||"service"].apply(this,[t.$name,n].concat(t.$inject||[]))},JR=function(t){delete this.providerMap[t],delete this.container[t],delete this.container[t+lT]},uZ=function(t){var n=this.originalProviders,r=Array.isArray(t);Object.keys(this.originalProviders).forEach(function(a){if(!(r&&t.indexOf(a)===-1)){var o=a.split(so);o.length>1&&o.forEach(JR,Eb.call(this,o[0])),JR.call(this,a),this.provider(a,n[a])}},this)},cZ=function(t){return this.deferred.forEach(function(r){r(t)}),this};Ca=function e(t){if(!(this instanceof e))return e.pop(t);this.id=GK++,this.decorators={},this.middlewares={},this.nested={},this.providerMap={},this.originalProviders={},this.deferred=[],this.container={$decorator:A9.bind(this),$register:E9.bind(this),$list:fT.bind(this)}};Ca.prototype={constant:nZ,decorator:A9,defer:rZ,digest:iZ,factory:cT,instanceFactory:aZ,list:fT,middleware:KK,provider:_9,resetProviders:uZ,register:E9,resolve:cZ,service:QK,serviceFactory:JK,value:eZ};Ca.pop=sZ;Ca.clear=lZ;Ca.list=fT;Ca.config={strict:!1};const O9=Ca;var T9=e=>{throw TypeError(e)},dT=(e,t,n)=>t.has(e)||T9("Cannot "+n),Ou=(e,t,n)=>(dT(e,t,"read from private field"),n?n.call(e):t.get(e)),np=(e,t,n)=>t.has(e)?T9("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Hv=(e,t,n,r)=>(dT(e,t,"write to private field"),t.set(e,n),n),sn=(e,t,n)=>(dT(e,t,"access private method"),n);const fZ=(e,t)=>`${e}/rest/v${t}`,dZ=e=>e.dir?`${e.field}-${e.dir}`:void 0,hZ=({orderBy:e={},excludeMaxVisitsReached:t,excludePastValidUntil:n,...r})=>({...r,excludeMaxVisitsReached:t===!0?"true":void 0,excludePastValidUntil:n===!0?"true":void 0,orderBy:dZ(e)}),pZ=(e,t)=>{const[n,r]=e.split("://");if(!r)throw new Error(`It is not possible to determine authority on "${e}" for replacement`);const[,...i]=r.split("/"),a=i.length?`/${i.join("/")}`:"";return`${n}://${t}${a}`},mZ=(e={})=>{const t=Object.entries(e).flatMap(([n,r])=>r==null?[]:Array.isArray(r)?r.map(i=>[`${n}[]`,i]):[[n,r]]);return new URLSearchParams(t).toString()};var By,jp,wf,Uy,Kt,bf,vr,Ey,W_;let gZ=class{constructor(t,n,r={}){np(this,Kt),np(this,By),np(this,jp),np(this,wf),np(this,Uy),Hv(this,jp,t),Hv(this,wf,n),Hv(this,Uy,r),Hv(this,By,3)}async listShortUrls({signal:t,...n}={}){return sn(this,Kt,vr).call(this,{url:"/short-urls",query:hZ(n),signal:t}).then(({shortUrls:r})=>r)}async createShortUrl({signal:t,...n}){const r=Object.entries(n).reduce((i,[a,o])=>(o&&(i[a]=o),i),{});return sn(this,Kt,vr).call(this,{url:"/short-urls",method:"POST",body:r,signal:t})}async getShortUrl({shortCode:t,domain:n},{signal:r}={}){return sn(this,Kt,vr).call(this,{url:`/short-urls/${t}`,query:{domain:n},signal:r})}async deleteShortUrl({shortCode:t,domain:n},{signal:r}={}){return sn(this,Kt,Ey).call(this,{url:`/short-urls/${t}`,method:"DELETE",query:{domain:n},signal:r})}async updateShortUrl({shortCode:t,domain:n},{signal:r,...i}){return sn(this,Kt,vr).call(this,{url:`/short-urls/${t}`,method:"PATCH",query:{domain:n},body:i,signal:r})}async getShortUrlRedirectRules({shortCode:t,domain:n},{signal:r}={}){return sn(this,Kt,vr).call(this,{url:`/short-urls/${t}/redirect-rules`,method:"GET",query:{domain:n},signal:r})}async setShortUrlRedirectRules({shortCode:t,domain:n},{signal:r,...i}){return sn(this,Kt,vr).call(this,{url:`/short-urls/${t}/redirect-rules`,method:"POST",query:{domain:n},body:i,signal:r})}async getVisitsOverview({signal:t}={}){return sn(this,Kt,vr).call(this,{url:"/visits",signal:t}).then(({visits:n})=>n)}async getShortUrlVisits({shortCode:t,domain:n},{signal:r,...i}={}){return sn(this,Kt,bf).call(this,{url:`/short-urls/${t}/visits`,query:{...i,domain:n},signal:r})}async getTagVisits(t,{signal:n,...r}={}){return sn(this,Kt,bf).call(this,{url:`/tags/${t}/visits`,query:r,signal:n})}async getDomainVisits(t,{signal:n,...r}={}){return sn(this,Kt,bf).call(this,{url:`/domains/${t}/visits`,query:r,signal:n})}async getOrphanVisits({signal:t,...n}={}){return sn(this,Kt,bf).call(this,{url:"/visits/orphan",query:n,signal:t})}async getNonOrphanVisits({signal:t,...n}={}){return sn(this,Kt,bf).call(this,{url:"/visits/non-orphan",query:n,signal:t})}async deleteShortUrlVisits({shortCode:t,domain:n},{signal:r}={}){const i=n?{domain:n}:void 0;return sn(this,Kt,vr).call(this,{method:"DELETE",url:`/short-urls/${t}/visits`,query:i,signal:r})}async deleteOrphanVisits({signal:t}={}){return sn(this,Kt,vr).call(this,{method:"DELETE",url:"/visits/orphan",signal:t})}async listTags({signal:t}={}){return sn(this,Kt,vr).call(this,{url:"/tags",signal:t}).then(({tags:n})=>n)}async tagsStats({signal:t}={}){return sn(this,Kt,vr).call(this,{url:"/tags/stats",signal:t}).then(({tags:n})=>n)}async deleteTags(t,{signal:n}={}){return sn(this,Kt,Ey).call(this,{url:"/tags",method:"DELETE",query:{tags:t},signal:n}).then(()=>({tags:t}))}async editTag({oldName:t,newName:n},{signal:r}={}){return sn(this,Kt,Ey).call(this,{url:"/tags",method:"PUT",body:{oldName:t,newName:n},signal:r}).then(()=>({oldName:t,newName:n}))}async listDomains({signal:t}={}){return sn(this,Kt,vr).call(this,{url:"/domains",signal:t}).then(({domains:n})=>n)}async editDomainRedirects(t,{signal:n}={}){return sn(this,Kt,vr).call(this,{url:"/domains/redirects",method:"PATCH",body:t,signal:n})}async health({domain:t,signal:n}={}){return sn(this,Kt,vr).call(this,{url:"/health",domain:t,signal:n})}async mercureInfo({signal:t}={}){return sn(this,Kt,vr).call(this,{url:"/mercure-info",signal:t})}};By=new WeakMap,jp=new WeakMap,wf=new WeakMap,Uy=new WeakMap,Kt=new WeakSet,bf=async function(e){return sn(this,Kt,vr).call(this,e).then(({visits:t})=>t)},vr=async function(e){return Ou(this,jp).jsonRequest(...sn(this,Kt,W_).call(this,e))},Ey=async function(e){return Ou(this,jp).emptyRequest(...sn(this,Kt,W_).call(this,e))},W_=function({url:e,method:t="GET",query:n,body:r,domain:i,signal:a}){const o=mZ(n??{}),l=o?`?${o}`:"",f=i?pZ(Ou(this,wf).baseUrl,i):Ou(this,wf).baseUrl;return[`${fZ(f,Ou(this,By))}${e}${l}`,{method:t,body:r&&JSON.stringify(r),headers:{"X-Api-Key":Ou(this,wf).apiKey},credentials:Ou(this,Uy).requestCredentials,signal:a}]};const j9=e=>!!(e!=null&&e.url)&&!!(e!=null&&e.apiKey),Pp=e=>!!(e!=null&&e.id),hT=e=>!!(e!=null&&e.version),vZ=e=>!!(e!=null&&e.serverNotFound),yZ=e=>Pp(e)?e.id:"",bZ=({name:e,url:t,apiKey:n,forwardCredentials:r})=>({name:e,url:t,apiKey:n,forwardCredentials:r?"true":"false"}),wZ=e=>typeof e.url=="string"&&typeof e.apiKey=="string"&&typeof e.name=="string",_Z=e=>{const{forwardCredentials:t,...n}=e;if(!wZ(n))throw new Error('Server is missing required "url", "apiKey" and/or "name" properties');return{...n,forwardCredentials:t==="true"}},eM=new Map,xZ=e=>typeof e=="function",SZ=e=>{const{selectedServer:t}=e();if(!j9(t))throw new Error("There's no selected server or it is not found");return t},CZ=e=>t=>{const{url:n,apiKey:r,forwardCredentials:i}=xZ(t)?SZ(t):t,a=`${r}_${n}_${i?"forward":"no-forward"}`,o=eM.get(a);if(o)return o;const l=new gZ(e,{apiKey:r,baseUrl:n},{requestCredentials:i?"include":void 0});return eM.set(a,l),l},AZ=e=>{e.serviceFactory("buildShlinkApiClient",CZ,"HttpClient")};/*!
|
||
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
|
||
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
|
||
* Copyright 2024 Fonticons, Inc.
|
||
*/const EZ={prefix:"fas",iconName:"trash-can",icon:[448,512,[61460,"trash-alt"],"f2ed","M135.2 17.7C140.6 6.8 151.7 0 163.8 0L284.2 0c12.1 0 23.2 6.8 28.6 17.7L320 32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 96C14.3 96 0 81.7 0 64S14.3 32 32 32l96 0 7.2-14.3zM32 128l384 0 0 320c0 35.3-28.7 64-64 64L96 512c-35.3 0-64-28.7-64-64l0-320zm96 64c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16s16-7.2 16-16l0-224c0-8.8-7.2-16-16-16zm96 0c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16s16-7.2 16-16l0-224c0-8.8-7.2-16-16-16zm96 0c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16s16-7.2 16-16l0-224c0-8.8-7.2-16-16-16z"]},OZ={prefix:"fas",iconName:"down-left-and-up-right-to-center",icon:[512,512,["compress-alt"],"f422","M439 7c9.4-9.4 24.6-9.4 33.9 0l32 32c9.4 9.4 9.4 24.6 0 33.9l-87 87 39 39c6.9 6.9 8.9 17.2 5.2 26.2s-12.5 14.8-22.2 14.8l-144 0c-13.3 0-24-10.7-24-24l0-144c0-9.7 5.8-18.5 14.8-22.2s19.3-1.7 26.2 5.2l39 39L439 7zM72 272l144 0c13.3 0 24 10.7 24 24l0 144c0 9.7-5.8 18.5-14.8 22.2s-19.3 1.7-26.2-5.2l-39-39L73 505c-9.4 9.4-24.6 9.4-33.9 0L7 473c-9.4-9.4-9.4-24.6 0-33.9l87-87L55 313c-6.9-6.9-8.9-17.2-5.2-26.2s12.5-14.8 22.2-14.8z"]},TZ={prefix:"fas",iconName:"calendar-days",icon:[448,512,["calendar-alt"],"f073","M128 0c17.7 0 32 14.3 32 32l0 32 128 0 0-32c0-17.7 14.3-32 32-32s32 14.3 32 32l0 32 48 0c26.5 0 48 21.5 48 48l0 48L0 160l0-48C0 85.5 21.5 64 48 64l48 0 0-32c0-17.7 14.3-32 32-32zM0 192l448 0 0 272c0 26.5-21.5 48-48 48L48 512c-26.5 0-48-21.5-48-48L0 192zm64 80l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm128 0l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0zM64 400l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0zm112 16l0 32c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l0-32c0-8.8-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16z"]},jZ=TZ,PZ={prefix:"fas",iconName:"circle-minus",icon:[512,512,["minus-circle"],"f056","M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM184 232l144 0c13.3 0 24 10.7 24 24s-10.7 24-24 24l-144 0c-13.3 0-24-10.7-24-24s10.7-24 24-24z"]},P9=PZ,RZ={prefix:"fas",iconName:"file-csv",icon:[512,512,[],"f6dd","M0 64C0 28.7 28.7 0 64 0L224 0l0 128c0 17.7 14.3 32 32 32l128 0 0 144-208 0c-35.3 0-64 28.7-64 64l0 144-48 0c-35.3 0-64-28.7-64-64L0 64zm384 64l-128 0L256 0 384 128zM200 352l16 0c22.1 0 40 17.9 40 40l0 8c0 8.8-7.2 16-16 16s-16-7.2-16-16l0-8c0-4.4-3.6-8-8-8l-16 0c-4.4 0-8 3.6-8 8l0 80c0 4.4 3.6 8 8 8l16 0c4.4 0 8-3.6 8-8l0-8c0-8.8 7.2-16 16-16s16 7.2 16 16l0 8c0 22.1-17.9 40-40 40l-16 0c-22.1 0-40-17.9-40-40l0-80c0-22.1 17.9-40 40-40zm133.1 0l34.9 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-34.9 0c-7.2 0-13.1 5.9-13.1 13.1c0 5.2 3 9.9 7.8 12l37.4 16.6c16.3 7.2 26.8 23.4 26.8 41.2c0 24.9-20.2 45.1-45.1 45.1L304 512c-8.8 0-16-7.2-16-16s7.2-16 16-16l42.9 0c7.2 0 13.1-5.9 13.1-13.1c0-5.2-3-9.9-7.8-12l-37.4-16.6c-16.3-7.2-26.8-23.4-26.8-41.2c0-24.9 20.2-45.1 45.1-45.1zm98.9 0c8.8 0 16 7.2 16 16l0 31.6c0 23 5.5 45.6 16 66c10.5-20.3 16-42.9 16-66l0-31.6c0-8.8 7.2-16 16-16s16 7.2 16 16l0 31.6c0 34.7-10.3 68.7-29.6 97.6l-5.1 7.7c-3 4.5-8 7.1-13.3 7.1s-10.3-2.7-13.3-7.1l-5.1-7.7c-19.3-28.9-29.6-62.9-29.6-97.6l0-31.6c0-8.8 7.2-16 16-16z"]},MZ={prefix:"fas",iconName:"pencil",icon:[512,512,[9999,61504,"pencil-alt"],"f303","M410.3 231l11.3-11.3-33.9-33.9-62.1-62.1L291.7 89.8l-11.3 11.3-22.6 22.6L58.6 322.9c-10.4 10.4-18 23.3-22.2 37.4L1 480.7c-2.5 8.4-.2 17.5 6.1 23.7s15.3 8.5 23.7 6.1l120.3-35.4c14.1-4.2 27-11.8 37.4-22.2L387.7 253.7 410.3 231zM160 399.4l-9.1 22.7c-4 3.1-8.5 5.4-13.3 6.9L59.4 452l23-78.1c1.4-4.9 3.8-9.4 6.9-13.3l22.7-9.1 0 32c0 8.8 7.2 16 16 16l32 0zM362.7 18.7L348.3 33.2 325.7 55.8 314.3 67.1l33.9 33.9 62.1 62.1 33.9 33.9 11.3-11.3 22.6-22.6 14.5-14.5c25-25 25-65.5 0-90.5L453.3 18.7c-25-25-65.5-25-90.5 0zm-47.4 168l-144 144c-6.2 6.2-16.4 6.2-22.6 0s-6.2-16.4 0-22.6l144-144c6.2-6.2 16.4-6.2 22.6 0s6.2 16.4 0 22.6z"]},R9=MZ,Ym={prefix:"fas",iconName:"circle-notch",icon:[512,512,[],"f1ce","M222.7 32.1c5 16.9-4.6 34.8-21.5 39.8C121.8 95.6 64 169.1 64 256c0 106 86 192 192 192s192-86 192-192c0-86.9-57.8-160.4-137.1-184.1c-16.9-5-26.6-22.9-21.5-39.8s22.9-26.6 39.8-21.5C434.9 42.1 512 140 512 256c0 141.4-114.6 256-256 256S0 397.4 0 256C0 140 77.1 42.1 182.9 10.6c16.9-5 34.8 4.6 39.8 21.5z"]},NZ={prefix:"fas",iconName:"bars",icon:[448,512,["navicon"],"f0c9","M0 96C0 78.3 14.3 64 32 64l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 128C14.3 128 0 113.7 0 96zM0 256c0-17.7 14.3-32 32-32l384 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 288c-17.7 0-32-14.3-32-32zM448 416c0 17.7-14.3 32-32 32L32 448c-17.7 0-32-14.3-32-32s14.3-32 32-32l384 0c17.7 0 32 14.3 32 32z"]},pT={prefix:"fas",iconName:"list",icon:[512,512,["list-squares"],"f03a","M40 48C26.7 48 16 58.7 16 72l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24L40 48zM192 64c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L192 64zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-288 0zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-288 0zM16 232l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24l-48 0c-13.3 0-24 10.7-24 24zM40 368c-13.3 0-24 10.7-24 24l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24l-48 0z"]},LZ={prefix:"fas",iconName:"circle-dot",icon:[512,512,[128280,"dot-circle"],"f192","M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zm0-352a96 96 0 1 1 0 192 96 96 0 1 1 0-192z"]},kZ=LZ,DZ={prefix:"fas",iconName:"pen-to-square",icon:[512,512,["edit"],"f044","M471.6 21.7c-21.9-21.9-57.3-21.9-79.2 0L362.3 51.7l97.9 97.9 30.1-30.1c21.9-21.9 21.9-57.3 0-79.2L471.6 21.7zm-299.2 220c-6.1 6.1-10.8 13.6-13.5 21.9l-29.6 88.8c-2.9 8.6-.6 18.1 5.8 24.6s15.9 8.7 24.6 5.8l88.8-29.6c8.2-2.7 15.7-7.4 21.9-13.5L437.7 172.3 339.7 74.3 172.4 241.7zM96 64C43 64 0 107 0 160L0 416c0 53 43 96 96 96l256 0c53 0 96-43 96-96l0-96c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 96c0 17.7-14.3 32-32 32L96 448c-17.7 0-32-14.3-32-32l0-256c0-17.7 14.3-32 32-32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L96 64z"]},mT=DZ,M9={prefix:"fas",iconName:"eye-slash",icon:[640,512,[],"f070","M38.8 5.1C28.4-3.1 13.3-1.2 5.1 9.2S-1.2 34.7 9.2 42.9l592 464c10.4 8.2 25.5 6.3 33.7-4.1s6.3-25.5-4.1-33.7L525.6 386.7c39.6-40.6 66.4-86.1 79.9-118.4c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C465.5 68.8 400.8 32 320 32c-68.2 0-125 26.3-169.3 60.8L38.8 5.1zM223.1 149.5C248.6 126.2 282.7 112 320 112c79.5 0 144 64.5 144 144c0 24.9-6.3 48.3-17.4 68.7L408 294.5c8.4-19.3 10.6-41.4 4.8-63.3c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3c0 10.2-2.4 19.8-6.6 28.3l-90.3-70.8zM373 389.9c-16.4 6.5-34.3 10.1-53 10.1c-79.5 0-144-64.5-144-144c0-6.9 .5-13.6 1.4-20.2L83.1 161.5C60.3 191.2 44 220.8 34.5 243.7c-3.3 7.9-3.3 16.7 0 24.6c14.9 35.7 46.2 87.7 93 131.1C174.5 443.2 239.2 480 320 480c47.8 0 89.9-12.9 126.2-32.5L373 389.9z"]},IZ={prefix:"fas",iconName:"plug",icon:[384,512,[128268],"f1e6","M96 0C78.3 0 64 14.3 64 32l0 96 64 0 0-96c0-17.7-14.3-32-32-32zM288 0c-17.7 0-32 14.3-32 32l0 96 64 0 0-96c0-17.7-14.3-32-32-32zM32 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l0 32c0 77.4 55 142 128 156.8l0 67.2c0 17.7 14.3 32 32 32s32-14.3 32-32l0-67.2C297 398 352 333.4 352 256l0-32c17.7 0 32-14.3 32-32s-14.3-32-32-32L32 160z"]},$Z={prefix:"fas",iconName:"chevron-up",icon:[512,512,[],"f077","M233.4 105.4c12.5-12.5 32.8-12.5 45.3 0l192 192c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L256 173.3 86.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l192-192z"]},BZ={prefix:"fas",iconName:"globe",icon:[512,512,[127760],"f0ac","M352 256c0 22.2-1.2 43.6-3.3 64l-185.3 0c-2.2-20.4-3.3-41.8-3.3-64s1.2-43.6 3.3-64l185.3 0c2.2 20.4 3.3 41.8 3.3 64zm28.8-64l123.1 0c5.3 20.5 8.1 41.9 8.1 64s-2.8 43.5-8.1 64l-123.1 0c2.1-20.6 3.2-42 3.2-64s-1.1-43.4-3.2-64zm112.6-32l-116.7 0c-10-63.9-29.8-117.4-55.3-151.6c78.3 20.7 142 77.5 171.9 151.6zm-149.1 0l-176.6 0c6.1-36.4 15.5-68.6 27-94.7c10.5-23.6 22.2-40.7 33.5-51.5C239.4 3.2 248.7 0 256 0s16.6 3.2 27.8 13.8c11.3 10.8 23 27.9 33.5 51.5c11.6 26 20.9 58.2 27 94.7zm-209 0L18.6 160C48.6 85.9 112.2 29.1 190.6 8.4C165.1 42.6 145.3 96.1 135.3 160zM8.1 192l123.1 0c-2.1 20.6-3.2 42-3.2 64s1.1 43.4 3.2 64L8.1 320C2.8 299.5 0 278.1 0 256s2.8-43.5 8.1-64zM194.7 446.6c-11.6-26-20.9-58.2-27-94.6l176.6 0c-6.1 36.4-15.5 68.6-27 94.6c-10.5 23.6-22.2 40.7-33.5 51.5C272.6 508.8 263.3 512 256 512s-16.6-3.2-27.8-13.8c-11.3-10.8-23-27.9-33.5-51.5zM135.3 352c10 63.9 29.8 117.4 55.3 151.6C112.2 482.9 48.6 426.1 18.6 352l116.7 0zm358.1 0c-30 74.1-93.6 130.9-171.9 151.6c25.5-34.2 45.2-87.7 55.3-151.6l116.7 0z"]},UZ={prefix:"fas",iconName:"ban",icon:[512,512,[128683,"cancel"],"f05e","M367.2 412.5L99.5 144.8C77.1 176.1 64 214.5 64 256c0 106 86 192 192 192c41.5 0 79.9-13.1 111.2-35.5zm45.3-45.3C434.9 335.9 448 297.5 448 256c0-106-86-192-192-192c-41.5 0-79.9 13.1-111.2 35.5L412.5 367.2zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256z"]},tM={prefix:"fas",iconName:"server",icon:[512,512,[],"f233","M64 32C28.7 32 0 60.7 0 96l0 64c0 35.3 28.7 64 64 64l384 0c35.3 0 64-28.7 64-64l0-64c0-35.3-28.7-64-64-64L64 32zm280 72a24 24 0 1 1 0 48 24 24 0 1 1 0-48zm48 24a24 24 0 1 1 48 0 24 24 0 1 1 -48 0zM64 288c-35.3 0-64 28.7-64 64l0 64c0 35.3 28.7 64 64 64l384 0c35.3 0 64-28.7 64-64l0-64c0-35.3-28.7-64-64-64L64 288zm280 72a24 24 0 1 1 0 48 24 24 0 1 1 0-48zm56 24a24 24 0 1 1 48 0 24 24 0 1 1 -48 0z"]},zZ={prefix:"fas",iconName:"file-arrow-up",icon:[384,512,["file-upload"],"f574","M64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-288-128 0c-17.7 0-32-14.3-32-32L224 0 64 0zM256 0l0 128 128 0L256 0zM216 408c0 13.3-10.7 24-24 24s-24-10.7-24-24l0-102.1-31 31c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l72-72c9.4-9.4 24.6-9.4 33.9 0l72 72c9.4 9.4 9.4 24.6 0 33.9s-24.6 9.4-33.9 0l-31-31L216 408z"]},FZ=zZ,qZ={prefix:"fas",iconName:"map-location-dot",icon:[576,512,["map-marked-alt"],"f5a0","M408 120c0 54.6-73.1 151.9-105.2 192c-7.7 9.6-22 9.6-29.6 0C241.1 271.9 168 174.6 168 120C168 53.7 221.7 0 288 0s120 53.7 120 120zm8 80.4c3.5-6.9 6.7-13.8 9.6-20.6c.5-1.2 1-2.5 1.5-3.7l116-46.4C558.9 123.4 576 135 576 152l0 270.8c0 9.8-6 18.6-15.1 22.3L416 503l0-302.6zM137.6 138.3c2.4 14.1 7.2 28.3 12.8 41.5c2.9 6.8 6.1 13.7 9.6 20.6l0 251.4L32.9 502.7C17.1 509 0 497.4 0 480.4L0 209.6c0-9.8 6-18.6 15.1-22.3l122.6-49zM327.8 332c13.9-17.4 35.7-45.7 56.2-77l0 249.3L192 449.4 192 255c20.5 31.3 42.3 59.6 56.2 77c20.5 25.6 59.1 25.6 79.6 0zM288 152a40 40 0 1 0 0-80 40 40 0 1 0 0 80z"]},IA=qZ,VZ={prefix:"fas",iconName:"caret-up",icon:[320,512,[],"f0d8","M182.6 137.4c-12.5-12.5-32.8-12.5-45.3 0l-128 128c-9.2 9.2-11.9 22.9-6.9 34.9s16.6 19.8 29.6 19.8l256 0c12.9 0 24.6-7.8 29.6-19.8s2.2-25.7-6.9-34.9l-128-128z"]},HZ={prefix:"fas",iconName:"palette",icon:[512,512,[127912],"f53f","M512 256c0 .9 0 1.8 0 2.7c-.4 36.5-33.6 61.3-70.1 61.3L344 320c-26.5 0-48 21.5-48 48c0 3.4 .4 6.7 1 9.9c2.1 10.2 6.5 20 10.8 29.9c6.1 13.8 12.1 27.5 12.1 42c0 31.8-21.6 60.7-53.4 62c-3.5 .1-7 .2-10.6 .2C114.6 512 0 397.4 0 256S114.6 0 256 0S512 114.6 512 256zM128 288a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zm0-96a32 32 0 1 0 0-64 32 32 0 1 0 0 64zM288 96a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zm96 96a32 32 0 1 0 0-64 32 32 0 1 0 0 64z"]},GZ={prefix:"fas",iconName:"arrow-down-wide-short",icon:[576,512,["sort-amount-asc","sort-amount-down"],"f160","M151.6 469.6C145.5 476.2 137 480 128 480s-17.5-3.8-23.6-10.4l-88-96c-11.9-13-11.1-33.3 2-45.2s33.3-11.1 45.2 2L96 365.7 96 64c0-17.7 14.3-32 32-32s32 14.3 32 32l0 301.7 32.4-35.4c11.9-13 32.2-13.9 45.2-2s13.9 32.2 2 45.2l-88 96zM320 480c-17.7 0-32-14.3-32-32s14.3-32 32-32l32 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-32 0zm0-128c-17.7 0-32-14.3-32-32s14.3-32 32-32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0zm0-128c-17.7 0-32-14.3-32-32s14.3-32 32-32l160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-160 0zm0-128c-17.7 0-32-14.3-32-32s14.3-32 32-32l224 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L320 96z"]},WZ=GZ,gT={prefix:"fas",iconName:"chart-pie",icon:[576,512,["pie-chart"],"f200","M304 240l0-223.4c0-9 7-16.6 16-16.6C443.7 0 544 100.3 544 224c0 9-7.6 16-16.6 16L304 240zM32 272C32 150.7 122.1 50.3 239 34.3c9.2-1.3 17 6.1 17 15.4L256 288 412.5 444.5c6.7 6.7 6.2 17.7-1.5 23.1C371.8 495.6 323.8 512 272 512C139.5 512 32 404.6 32 272zm526.4 16c9.3 0 16.6 7.8 15.4 17c-7.7 55.9-34.6 105.6-73.9 142.3c-6 5.6-15.4 5.2-21.2-.7L320 288l238.4 0z"]},Ob={prefix:"fas",iconName:"chart-line",icon:[512,512,["line-chart"],"f201","M64 64c0-17.7-14.3-32-32-32S0 46.3 0 64L0 400c0 44.2 35.8 80 80 80l400 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L80 416c-8.8 0-16-7.2-16-16L64 64zm406.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L320 210.7l-57.4-57.4c-12.5-12.5-32.8-12.5-45.3 0l-112 112c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L240 221.3l57.4 57.4c12.5 12.5 32.8 12.5 45.3 0l128-128z"]},N9={prefix:"fas",iconName:"tags",icon:[512,512,[],"f02c","M345 39.1L472.8 168.4c52.4 53 52.4 138.2 0 191.2L360.8 472.9c-9.3 9.4-24.5 9.5-33.9 .2s-9.5-24.5-.2-33.9L438.6 325.9c33.9-34.3 33.9-89.4 0-123.7L310.9 72.9c-9.3-9.4-9.2-24.6 .2-33.9s24.6-9.2 33.9 .2zM0 229.5L0 80C0 53.5 21.5 32 48 32l149.5 0c17 0 33.3 6.7 45.3 18.7l168 168c25 25 25 65.5 0 90.5L277.3 442.7c-25 25-65.5 25-90.5 0l-168-168C6.7 262.7 0 246.5 0 229.5zM144 144a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"]},L9={prefix:"fas",iconName:"eye",icon:[576,512,[128065],"f06e","M288 32c-80.8 0-145.5 36.8-192.6 80.6C48.6 156 17.3 208 2.5 243.7c-3.3 7.9-3.3 16.7 0 24.6C17.3 304 48.6 356 95.4 399.4C142.5 443.2 207.2 480 288 480s145.5-36.8 192.6-80.6c46.8-43.5 78.1-95.4 93-131.1c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C433.5 68.8 368.8 32 288 32zM144 256a144 144 0 1 1 288 0 144 144 0 1 1 -288 0zm144-64c0 35.3-28.7 64-64 64c-7.1 0-13.9-1.2-20.3-3.3c-5.5-1.8-11.9 1.6-11.7 7.4c.3 6.9 1.3 13.8 3.2 20.7c13.7 51.2 66.4 81.6 117.6 67.9s81.6-66.4 67.9-117.6c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3z"]},nM={prefix:"fas",iconName:"calendar-xmark",icon:[448,512,["calendar-times"],"f273","M128 0c17.7 0 32 14.3 32 32l0 32 128 0 0-32c0-17.7 14.3-32 32-32s32 14.3 32 32l0 32 48 0c26.5 0 48 21.5 48 48l0 48L0 160l0-48C0 85.5 21.5 64 48 64l48 0 0-32c0-17.7 14.3-32 32-32zM0 192l448 0 0 272c0 26.5-21.5 48-48 48L48 512c-26.5 0-48-21.5-48-48L0 192zM305 305c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0l-47 47-47-47c-9.4-9.4-24.6-9.4-33.9 0s-9.4 24.6 0 33.9l47 47-47 47c-9.4 9.4-9.4 24.6 0 33.9s24.6 9.4 33.9 0l47-47 47 47c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-47-47 47-47z"]},YZ={prefix:"fas",iconName:"trash",icon:[448,512,[],"f1f8","M135.2 17.7L128 32 32 32C14.3 32 0 46.3 0 64S14.3 96 32 96l384 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0-7.2-14.3C307.4 6.8 296.3 0 284.2 0L163.8 0c-12.1 0-23.2 6.8-28.6 17.7zM416 128L32 128 53.2 467c1.6 25.3 22.6 45 47.9 45l245.8 0c25.3 0 46.3-19.7 47.9-45L416 128z"]},KZ={prefix:"fas",iconName:"arrow-left",icon:[448,512,[8592],"f060","M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.2 288 416 288c17.7 0 32-14.3 32-32s-14.3-32-32-32l-306.7 0L214.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z"]},ZZ={prefix:"fas",iconName:"up-right-from-square",icon:[512,512,["external-link-alt"],"f35d","M352 0c-12.9 0-24.6 7.8-29.6 19.8s-2.2 25.7 6.9 34.9L370.7 96 201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L416 141.3l41.4 41.4c9.2 9.2 22.9 11.9 34.9 6.9s19.8-16.6 19.8-29.6l0-128c0-17.7-14.3-32-32-32L352 0zM80 32C35.8 32 0 67.8 0 112L0 432c0 44.2 35.8 80 80 80l320 0c44.2 0 80-35.8 80-80l0-112c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 112c0 8.8-7.2 16-16 16L80 448c-8.8 0-16-7.2-16-16l0-320c0-8.8 7.2-16 16-16l112 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L80 32z"]},XZ=ZZ,QZ={prefix:"fas",iconName:"tag",icon:[448,512,[127991],"f02b","M0 80L0 229.5c0 17 6.7 33.3 18.7 45.3l176 176c25 25 65.5 25 90.5 0L418.7 317.3c25-25 25-65.5 0-90.5l-176-176c-12-12-28.3-18.7-45.3-18.7L48 32C21.5 32 0 53.5 0 80zm112 32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z"]},JZ={prefix:"fas",iconName:"circle-info",icon:[512,512,["info-circle"],"f05a","M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM216 336l24 0 0-64-24 0c-13.3 0-24-10.7-24-24s10.7-24 24-24l48 0c13.3 0 24 10.7 24 24l0 88 8 0c13.3 0 24 10.7 24 24s-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24s10.7-24 24-24zm40-208a32 32 0 1 1 0 64 32 32 0 1 1 0-64z"]},Tb=JZ,eX={prefix:"fas",iconName:"arrow-rotate-left",icon:[512,512,[8634,"arrow-left-rotate","arrow-rotate-back","arrow-rotate-backward","undo"],"f0e2","M125.7 160l50.3 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L48 224c-17.7 0-32-14.3-32-32L16 64c0-17.7 14.3-32 32-32s32 14.3 32 32l0 51.2L97.6 97.6c87.5-87.5 229.3-87.5 316.8 0s87.5 229.3 0 316.8s-229.3 87.5-316.8 0c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0c62.5 62.5 163.8 62.5 226.3 0s62.5-163.8 0-226.3s-163.8-62.5-226.3 0L125.7 160z"]},tX=eX,nX={prefix:"fas",iconName:"grip-vertical",icon:[320,512,[],"f58e","M40 352l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40zm192 0l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40zM40 320c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0zM232 192l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40zM40 160c-22.1 0-40-17.9-40-40L0 72C0 49.9 17.9 32 40 32l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0zM232 32l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40z"]},vT={prefix:"fas",iconName:"caret-down",icon:[320,512,[],"f0d7","M137.4 374.6c12.5 12.5 32.8 12.5 45.3 0l128-128c9.2-9.2 11.9-22.9 6.9-34.9s-16.6-19.8-29.6-19.8L32 192c-12.9 0-24.6 7.8-29.6 19.8s-2.2 25.7 6.9 34.9l128 128z"]},rX={prefix:"fas",iconName:"ellipsis-vertical",icon:[128,512,["ellipsis-v"],"f142","M64 360a56 56 0 1 0 0 112 56 56 0 1 0 0-112zm0-160a56 56 0 1 0 0 112 56 56 0 1 0 0-112zM120 96A56 56 0 1 0 8 96a56 56 0 1 0 112 0z"]},k9=rX,iX={prefix:"fas",iconName:"house",icon:[576,512,[127968,63498,63500,"home","home-alt","home-lg-alt"],"f015","M575.8 255.5c0 18-15 32.1-32 32.1l-32 0 .7 160.2c0 2.7-.2 5.4-.5 8.1l0 16.2c0 22.1-17.9 40-40 40l-16 0c-1.1 0-2.2 0-3.3-.1c-1.4 .1-2.8 .1-4.2 .1L416 512l-24 0c-22.1 0-40-17.9-40-40l0-24 0-64c0-17.7-14.3-32-32-32l-64 0c-17.7 0-32 14.3-32 32l0 64 0 24c0 22.1-17.9 40-40 40l-24 0-31.9 0c-1.5 0-3-.1-4.5-.2c-1.2 .1-2.4 .2-3.6 .2l-16 0c-22.1 0-40-17.9-40-40l0-112c0-.9 0-1.9 .1-2.8l0-69.7-32 0c-18 0-32-14-32-32.1c0-9 3-17 10-24L266.4 8c7-7 15-8 22-8s15 2 21 7L564.8 231.5c8 7 12 15 11 24z"]},aX=iX,oX={prefix:"fas",iconName:"arrow-up-wide-short",icon:[576,512,["sort-amount-up"],"f161","M151.6 42.4C145.5 35.8 137 32 128 32s-17.5 3.8-23.6 10.4l-88 96c-11.9 13-11.1 33.3 2 45.2s33.3 11.1 45.2-2L96 146.3 96 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-301.7 32.4 35.4c11.9 13 32.2 13.9 45.2 2s13.9-32.2 2-45.2l-88-96zM320 480l32 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-32 0c-17.7 0-32 14.3-32 32s14.3 32 32 32zm0-128l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0c-17.7 0-32 14.3-32 32s14.3 32 32 32zm0-128l160 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-160 0c-17.7 0-32 14.3-32 32s14.3 32 32 32zm0-128l224 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L320 32c-17.7 0-32 14.3-32 32s14.3 32 32 32z"]},sX=oX,lX={prefix:"fas",iconName:"file-arrow-down",icon:[384,512,["file-download"],"f56d","M64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-288-128 0c-17.7 0-32-14.3-32-32L224 0 64 0zM256 0l0 128 128 0L256 0zM216 232l0 102.1 31-31c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9l-72 72c-9.4 9.4-24.6 9.4-33.9 0l-72-72c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0l31 31L168 232c0-13.3 10.7-24 24-24s24 10.7 24 24z"]},D9=lX,uX={prefix:"fas",iconName:"sun",icon:[512,512,[9728],"f185","M361.5 1.2c5 2.1 8.6 6.6 9.6 11.9L391 121l107.9 19.8c5.3 1 9.8 4.6 11.9 9.6s1.5 10.7-1.6 15.2L446.9 256l62.3 90.3c3.1 4.5 3.7 10.2 1.6 15.2s-6.6 8.6-11.9 9.6L391 391 371.1 498.9c-1 5.3-4.6 9.8-9.6 11.9s-10.7 1.5-15.2-1.6L256 446.9l-90.3 62.3c-4.5 3.1-10.2 3.7-15.2 1.6s-8.6-6.6-9.6-11.9L121 391 13.1 371.1c-5.3-1-9.8-4.6-11.9-9.6s-1.5-10.7 1.6-15.2L65.1 256 2.8 165.7c-3.1-4.5-3.7-10.2-1.6-15.2s6.6-8.6 11.9-9.6L121 121 140.9 13.1c1-5.3 4.6-9.8 9.6-11.9s10.7-1.5 15.2 1.6L256 65.1 346.3 2.8c4.5-3.1 10.2-3.7 15.2-1.6zM160 256a96 96 0 1 1 192 0 96 96 0 1 1 -192 0zm224 0a128 128 0 1 0 -256 0 128 128 0 1 0 256 0z"]},cX={prefix:"fas",iconName:"arrow-down",icon:[384,512,[8595],"f063","M169.4 470.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L224 370.8 224 64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 306.7L54.6 265.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]},fX={prefix:"fas",iconName:"link",icon:[640,512,[128279,"chain"],"f0c1","M579.8 267.7c56.5-56.5 56.5-148 0-204.5c-50-50-128.8-56.5-186.3-15.4l-1.6 1.1c-14.4 10.3-17.7 30.3-7.4 44.6s30.3 17.7 44.6 7.4l1.6-1.1c32.1-22.9 76-19.3 103.8 8.6c31.5 31.5 31.5 82.5 0 114L422.3 334.8c-31.5 31.5-82.5 31.5-114 0c-27.9-27.9-31.5-71.8-8.6-103.8l1.1-1.6c10.3-14.4 6.9-34.4-7.4-44.6s-34.4-6.9-44.6 7.4l-1.1 1.6C206.5 251.2 213 330 263 380c56.5 56.5 148 56.5 204.5 0L579.8 267.7zM60.2 244.3c-56.5 56.5-56.5 148 0 204.5c50 50 128.8 56.5 186.3 15.4l1.6-1.1c14.4-10.3 17.7-30.3 7.4-44.6s-30.3-17.7-44.6-7.4l-1.6 1.1c-32.1 22.9-76 19.3-103.8-8.6C74 372 74 321 105.5 289.5L217.7 177.2c31.5-31.5 82.5-31.5 114 0c27.9 27.9 31.5 71.8 8.6 103.9l-1.1 1.6c-10.3 14.4-6.9 34.4 7.4 44.6s34.4 6.9 44.6-7.4l1.1-1.6C433.5 260.8 427 182 377 132c-56.5-56.5-148-56.5-204.5 0L60.2 244.3z"]},dX={prefix:"fas",iconName:"magnifying-glass",icon:[512,512,[128269,"search"],"f002","M416 208c0 45.9-14.9 88.3-40 122.7L502.6 457.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L330.7 376c-34.4 25.2-76.8 40-122.7 40C93.1 416 0 322.9 0 208S93.1 0 208 0S416 93.1 416 208zM208 352a144 144 0 1 0 0-288 144 144 0 1 0 0 288z"]},I9=dX,hX={prefix:"fas",iconName:"chevron-down",icon:[512,512,[],"f078","M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"]},pX={prefix:"fas",iconName:"arrow-up",icon:[384,512,[8593],"f062","M214.6 41.4c-12.5-12.5-32.8-12.5-45.3 0l-160 160c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 141.2 160 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-306.7L329.4 246.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-160-160z"]},Km={prefix:"fas",iconName:"plus",icon:[448,512,[10133,61543,"add"],"2b","M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 144L48 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l144 0 0 144c0 17.7 14.3 32 32 32s32-14.3 32-32l0-144 144 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-144 0 0-144z"]},jb={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"]},Pb=jb,mX=jb,rM={prefix:"fas",iconName:"chevron-left",icon:[320,512,[9001],"f053","M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"]},zy={prefix:"fas",iconName:"chevron-right",icon:[320,512,[9002],"f054","M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"]},gX={prefix:"fas",iconName:"rotate",icon:[512,512,[128260,"sync-alt"],"f2f1","M142.9 142.9c-17.5 17.5-30.1 38-37.8 59.8c-5.9 16.7-24.2 25.4-40.8 19.5s-25.4-24.2-19.5-40.8C55.6 150.7 73.2 122 97.6 97.6c87.2-87.2 228.3-87.5 315.8-1L455 55c6.9-6.9 17.2-8.9 26.2-5.2s14.8 12.5 14.8 22.2l0 128c0 13.3-10.7 24-24 24l-8.4 0c0 0 0 0 0 0L344 224c-9.7 0-18.5-5.8-22.2-14.8s-1.7-19.3 5.2-26.2l41.1-41.1c-62.6-61.5-163.1-61.2-225.3 1zM16 312c0-13.3 10.7-24 24-24l7.6 0 .7 0L168 288c9.7 0 18.5 5.8 22.2 14.8s1.7 19.3-5.2 26.2l-41.1 41.1c62.6 61.5 163.1 61.2 225.3-1c17.5-17.5 30.1-38 37.8-59.8c5.9-16.7 24.2-25.4 40.8-19.5s25.4 24.2 19.5 40.8c-10.8 30.6-28.4 59.3-52.9 83.8c-87.2 87.2-228.3 87.5-315.8 1L57 457c-6.9 6.9-17.2 8.9-26.2 5.2S16 449.7 16 440l0-119.6 0-.7 0-7.6z"]},vX=gX,$9={prefix:"fas",iconName:"robot",icon:[640,512,[129302],"f544","M320 0c17.7 0 32 14.3 32 32l0 64 120 0c39.8 0 72 32.2 72 72l0 272c0 39.8-32.2 72-72 72l-304 0c-39.8 0-72-32.2-72-72l0-272c0-39.8 32.2-72 72-72l120 0 0-64c0-17.7 14.3-32 32-32zM208 384c-8.8 0-16 7.2-16 16s7.2 16 16 16l32 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-32 0zm96 0c-8.8 0-16 7.2-16 16s7.2 16 16 16l32 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-32 0zm96 0c-8.8 0-16 7.2-16 16s7.2 16 16 16l32 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-32 0zM264 256a40 40 0 1 0 -80 0 40 40 0 1 0 80 0zm152 40a40 40 0 1 0 0-80 40 40 0 1 0 0 80zM48 224l16 0 0 192-16 0c-26.5 0-48-21.5-48-48l0-96c0-26.5 21.5-48 48-48zm544 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-16 0 0-192 16 0z"]},B9={prefix:"fas",iconName:"gears",icon:[640,512,["cogs"],"f085","M308.5 135.3c7.1-6.3 9.9-16.2 6.2-25c-2.3-5.3-4.8-10.5-7.6-15.5L304 89.4c-3-5-6.3-9.9-9.8-14.6c-5.7-7.6-15.7-10.1-24.7-7.1l-28.2 9.3c-10.7-8.8-23-16-36.2-20.9L199 27.1c-1.9-9.3-9.1-16.7-18.5-17.8C173.9 8.4 167.2 8 160.4 8l-.7 0c-6.8 0-13.5 .4-20.1 1.2c-9.4 1.1-16.6 8.6-18.5 17.8L115 56.1c-13.3 5-25.5 12.1-36.2 20.9L50.5 67.8c-9-3-19-.5-24.7 7.1c-3.5 4.7-6.8 9.6-9.9 14.6l-3 5.3c-2.8 5-5.3 10.2-7.6 15.6c-3.7 8.7-.9 18.6 6.2 25l22.2 19.8C32.6 161.9 32 168.9 32 176s.6 14.1 1.7 20.9L11.5 216.7c-7.1 6.3-9.9 16.2-6.2 25c2.3 5.3 4.8 10.5 7.6 15.6l3 5.2c3 5.1 6.3 9.9 9.9 14.6c5.7 7.6 15.7 10.1 24.7 7.1l28.2-9.3c10.7 8.8 23 16 36.2 20.9l6.1 29.1c1.9 9.3 9.1 16.7 18.5 17.8c6.7 .8 13.5 1.2 20.4 1.2s13.7-.4 20.4-1.2c9.4-1.1 16.6-8.6 18.5-17.8l6.1-29.1c13.3-5 25.5-12.1 36.2-20.9l28.2 9.3c9 3 19 .5 24.7-7.1c3.5-4.7 6.8-9.5 9.8-14.6l3.1-5.4c2.8-5 5.3-10.2 7.6-15.5c3.7-8.7 .9-18.6-6.2-25l-22.2-19.8c1.1-6.8 1.7-13.8 1.7-20.9s-.6-14.1-1.7-20.9l22.2-19.8zM112 176a48 48 0 1 1 96 0 48 48 0 1 1 -96 0zM504.7 500.5c6.3 7.1 16.2 9.9 25 6.2c5.3-2.3 10.5-4.8 15.5-7.6l5.4-3.1c5-3 9.9-6.3 14.6-9.8c7.6-5.7 10.1-15.7 7.1-24.7l-9.3-28.2c8.8-10.7 16-23 20.9-36.2l29.1-6.1c9.3-1.9 16.7-9.1 17.8-18.5c.8-6.7 1.2-13.5 1.2-20.4s-.4-13.7-1.2-20.4c-1.1-9.4-8.6-16.6-17.8-18.5L583.9 307c-5-13.3-12.1-25.5-20.9-36.2l9.3-28.2c3-9 .5-19-7.1-24.7c-4.7-3.5-9.6-6.8-14.6-9.9l-5.3-3c-5-2.8-10.2-5.3-15.6-7.6c-8.7-3.7-18.6-.9-25 6.2l-19.8 22.2c-6.8-1.1-13.8-1.7-20.9-1.7s-14.1 .6-20.9 1.7l-19.8-22.2c-6.3-7.1-16.2-9.9-25-6.2c-5.3 2.3-10.5 4.8-15.6 7.6l-5.2 3c-5.1 3-9.9 6.3-14.6 9.9c-7.6 5.7-10.1 15.7-7.1 24.7l9.3 28.2c-8.8 10.7-16 23-20.9 36.2L315.1 313c-9.3 1.9-16.7 9.1-17.8 18.5c-.8 6.7-1.2 13.5-1.2 20.4s.4 13.7 1.2 20.4c1.1 9.4 8.6 16.6 17.8 18.5l29.1 6.1c5 13.3 12.1 25.5 20.9 36.2l-9.3 28.2c-3 9-.5 19 7.1 24.7c4.7 3.5 9.5 6.8 14.6 9.8l5.4 3.1c5 2.8 10.2 5.3 15.5 7.6c8.7 3.7 18.6 .9 25-6.2l19.8-22.2c6.8 1.1 13.8 1.7 20.9 1.7s14.1-.6 20.9-1.7l19.8 22.2zM464 304a48 48 0 1 1 0 96 48 48 0 1 1 0-96z"]},yX=B9,bX={prefix:"fas",iconName:"qrcode",icon:[448,512,[],"f029","M0 80C0 53.5 21.5 32 48 32l96 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48L0 80zM64 96l0 64 64 0 0-64L64 96zM0 336c0-26.5 21.5-48 48-48l96 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48l0-96zm64 16l0 64 64 0 0-64-64 0zM304 32l96 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48l0-96c0-26.5 21.5-48 48-48zm80 64l-64 0 0 64 64 0 0-64zM256 304c0-8.8 7.2-16 16-16l64 0c8.8 0 16 7.2 16 16s7.2 16 16 16l32 0c8.8 0 16-7.2 16-16s7.2-16 16-16s16 7.2 16 16l0 96c0 8.8-7.2 16-16 16l-64 0c-8.8 0-16-7.2-16-16s-7.2-16-16-16s-16 7.2-16 16l0 64c0 8.8-7.2 16-16 16l-32 0c-8.8 0-16-7.2-16-16l0-160zM368 480a16 16 0 1 1 0-32 16 16 0 1 1 0 32zm64 0a16 16 0 1 1 0-32 16 16 0 1 1 0 32z"]},wX={prefix:"fas",iconName:"moon",icon:[384,512,[127769,9214],"f186","M223.5 32C100 32 0 132.3 0 256S100 480 223.5 480c60.6 0 115.5-24.2 155.8-63.4c5-4.9 6.3-12.5 3.1-18.7s-10.1-9.7-17-8.5c-9.8 1.7-19.8 2.6-30.1 2.6c-96.9 0-175.5-78.8-175.5-176c0-65.8 36-123.1 89.3-153.3c6.1-3.5 9.2-10.5 7.7-17.3s-7.3-11.9-14.3-12.5c-6.3-.5-12.6-.8-19-.8z"]},_X={prefix:"fas",iconName:"up-right-and-down-left-from-center",icon:[512,512,["expand-alt"],"f424","M344 0L488 0c13.3 0 24 10.7 24 24l0 144c0 9.7-5.8 18.5-14.8 22.2s-19.3 1.7-26.2-5.2l-39-39-87 87c-9.4 9.4-24.6 9.4-33.9 0l-32-32c-9.4-9.4-9.4-24.6 0-33.9l87-87L327 41c-6.9-6.9-8.9-17.2-5.2-26.2S334.3 0 344 0zM168 512L24 512c-13.3 0-24-10.7-24-24L0 344c0-9.7 5.8-18.5 14.8-22.2s19.3-1.7 26.2 5.2l39 39 87-87c9.4-9.4 24.6-9.4 33.9 0l32 32c9.4 9.4 9.4 24.6 0 33.9l-87 87 39 39c6.9 6.9 8.9 17.2 5.2 26.2s-12.5 14.8-22.2 14.8z"]},xX={prefix:"fas",iconName:"link-slash",icon:[640,512,["chain-broken","chain-slash","unlink"],"f127","M38.8 5.1C28.4-3.1 13.3-1.2 5.1 9.2S-1.2 34.7 9.2 42.9l592 464c10.4 8.2 25.5 6.3 33.7-4.1s6.3-25.5-4.1-33.7L489.3 358.2l90.5-90.5c56.5-56.5 56.5-148 0-204.5c-50-50-128.8-56.5-186.3-15.4l-1.6 1.1c-14.4 10.3-17.7 30.3-7.4 44.6s30.3 17.7 44.6 7.4l1.6-1.1c32.1-22.9 76-19.3 103.8 8.6c31.5 31.5 31.5 82.5 0 114l-96 96-31.9-25C430.9 239.6 420.1 175.1 377 132c-52.2-52.3-134.5-56.2-191.3-11.7L38.8 5.1zM239 162c30.1-14.9 67.7-9.9 92.8 15.3c20 20 27.5 48.3 21.7 74.5L239 162zM406.6 416.4L220.9 270c-2.1 39.8 12.2 80.1 42.2 110c38.9 38.9 94.4 51 143.6 36.3zm-290-228.5L60.2 244.3c-56.5 56.5-56.5 148 0 204.5c50 50 128.8 56.5 186.3 15.4l1.6-1.1c14.4-10.3 17.7-30.3 7.4-44.6s-30.3-17.7-44.6-7.4l-1.6 1.1c-32.1 22.9-76 19.3-103.8-8.6C74 372 74 321 105.5 289.5l61.8-61.8-50.6-39.9z"]},SX={prefix:"fas",iconName:"desktop",icon:[576,512,[128421,61704,"desktop-alt"],"f390","M64 0C28.7 0 0 28.7 0 64L0 352c0 35.3 28.7 64 64 64l176 0-10.7 32L160 448c-17.7 0-32 14.3-32 32s14.3 32 32 32l256 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-69.3 0L336 416l176 0c35.3 0 64-28.7 64-64l0-288c0-35.3-28.7-64-64-64L64 0zM512 64l0 224L64 288 64 64l448 0z"]},Zu={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"]},U9={prefix:"fas",iconName:"arrows-split-up-and-left",icon:[512,512,[],"e4bc","M246.6 150.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l96-96c12.5-12.5 32.8-12.5 45.3 0l96 96c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L352 109.3 352 384c0 35.3 28.7 64 64 64l64 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-64 0c-70.7 0-128-57.3-128-128c0-35.3-28.7-64-64-64l-114.7 0 41.4 41.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0l-96-96c-12.5-12.5-12.5-32.8 0-45.3l96-96c12.5-12.5 32.8-12.5 45.3 0s12.5 32.8 0 45.3L109.3 256 224 256c23.3 0 45.2 6.2 64 17.1l0-163.9-41.4 41.4z"]},CX={prefix:"fas",iconName:"triangle-exclamation",icon:[512,512,[9888,"exclamation-triangle","warning"],"f071","M256 32c14.2 0 27.3 7.5 34.5 19.8l216 368c7.3 12.4 7.3 27.7 .2 40.1S486.3 480 472 480L40 480c-14.3 0-27.6-7.7-34.7-20.1s-7-27.8 .2-40.1l216-368C228.7 39.5 241.8 32 256 32zm0 128c-13.3 0-24 10.7-24 24l0 112c0 13.3 10.7 24 24 24s24-10.7 24-24l0-112c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"]},AX=CX;/*!
|
||
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
|
||
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
|
||
* Copyright 2024 Fonticons, Inc.
|
||
*/function EX(e,t,n){return(t=TX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function iM(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 Ke(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?iM(Object(n),!0).forEach(function(r){EX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iM(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function OX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function TX(e){var t=OX(e,"string");return typeof t=="symbol"?t:t+""}const aM=()=>{};let yT={},z9={},F9=null,q9={mark:aM,measure:aM};try{typeof window<"u"&&(yT=window),typeof document<"u"&&(z9=document),typeof MutationObserver<"u"&&(F9=MutationObserver),typeof performance<"u"&&(q9=performance)}catch{}const{userAgent:oM=""}=yT.navigator||{},jl=yT,pn=z9,sM=F9,Gv=q9;jl.document;const cs=!!pn.documentElement&&!!pn.head&&typeof pn.addEventListener=="function"&&typeof pn.createElement=="function",V9=~oM.indexOf("MSIE")||~oM.indexOf("Trident/");var jX=/fa(s|r|l|t|d|dr|dl|dt|b|k|kd|ss|sr|sl|st|sds|sdr|sdl|sdt)?[\-\ ]/,PX=/Font ?Awesome ?([56 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Sharp Duotone|Sharp|Kit)?.*/i,H9={classic:{fa:"solid",fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fab:"brands","fa-brands":"brands"},duotone:{fa:"solid",fad:"solid","fa-solid":"solid","fa-duotone":"solid",fadr:"regular","fa-regular":"regular",fadl:"light","fa-light":"light",fadt:"thin","fa-thin":"thin"},sharp:{fa:"solid",fass:"solid","fa-solid":"solid",fasr:"regular","fa-regular":"regular",fasl:"light","fa-light":"light",fast:"thin","fa-thin":"thin"},"sharp-duotone":{fa:"solid",fasds:"solid","fa-solid":"solid",fasdr:"regular","fa-regular":"regular",fasdl:"light","fa-light":"light",fasdt:"thin","fa-thin":"thin"}},RX={GROUP:"duotone-group",PRIMARY:"primary",SECONDARY:"secondary"},G9=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone"],Mr="classic",Rb="duotone",MX="sharp",NX="sharp-duotone",W9=[Mr,Rb,MX,NX],LX={classic:{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},duotone:{900:"fad",400:"fadr",300:"fadl",100:"fadt"},sharp:{900:"fass",400:"fasr",300:"fasl",100:"fast"},"sharp-duotone":{900:"fasds",400:"fasdr",300:"fasdl",100:"fasdt"}},kX={"Font Awesome 6 Free":{900:"fas",400:"far"},"Font Awesome 6 Pro":{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},"Font Awesome 6 Brands":{400:"fab",normal:"fab"},"Font Awesome 6 Duotone":{900:"fad",400:"fadr",normal:"fadr",300:"fadl",100:"fadt"},"Font Awesome 6 Sharp":{900:"fass",400:"fasr",normal:"fasr",300:"fasl",100:"fast"},"Font Awesome 6 Sharp Duotone":{900:"fasds",400:"fasdr",normal:"fasdr",300:"fasdl",100:"fasdt"}},DX=new Map([["classic",{defaultShortPrefixId:"fas",defaultStyleId:"solid",styleIds:["solid","regular","light","thin","brands"],futureStyleIds:[],defaultFontWeight:900}],["sharp",{defaultShortPrefixId:"fass",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["duotone",{defaultShortPrefixId:"fad",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp-duotone",{defaultShortPrefixId:"fasds",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}]]),IX={classic:{solid:"fas",regular:"far",light:"fal",thin:"fat",brands:"fab"},duotone:{solid:"fad",regular:"fadr",light:"fadl",thin:"fadt"},sharp:{solid:"fass",regular:"fasr",light:"fasl",thin:"fast"},"sharp-duotone":{solid:"fasds",regular:"fasdr",light:"fasdl",thin:"fasdt"}},$X=["fak","fa-kit","fakd","fa-kit-duotone"],lM={kit:{fak:"kit","fa-kit":"kit"},"kit-duotone":{fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"}},BX=["kit"],UX={kit:{"fa-kit":"fak"}},zX=["fak","fakd"],FX={kit:{fak:"fa-kit"}},uM={kit:{kit:"fak"},"kit-duotone":{"kit-duotone":"fakd"}},Wv={GROUP:"duotone-group",SWAP_OPACITY:"swap-opacity",PRIMARY:"primary",SECONDARY:"secondary"},qX=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone"],VX=["fak","fa-kit","fakd","fa-kit-duotone"],HX={"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}},GX={classic:{"fa-brands":"fab","fa-duotone":"fad","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},duotone:{"fa-regular":"fadr","fa-light":"fadl","fa-thin":"fadt"},sharp:{"fa-solid":"fass","fa-regular":"fasr","fa-light":"fasl","fa-thin":"fast"},"sharp-duotone":{"fa-solid":"fasds","fa-regular":"fasdr","fa-light":"fasdl","fa-thin":"fasdt"}},WX={classic:["fas","far","fal","fat","fad"],duotone:["fadr","fadl","fadt"],sharp:["fass","fasr","fasl","fast"],"sharp-duotone":["fasds","fasdr","fasdl","fasdt"]},$A={classic:{fab:"fa-brands",fad:"fa-duotone",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},duotone:{fadr:"fa-regular",fadl:"fa-light",fadt:"fa-thin"},sharp:{fass:"fa-solid",fasr:"fa-regular",fasl:"fa-light",fast:"fa-thin"},"sharp-duotone":{fasds:"fa-solid",fasdr:"fa-regular",fasdl:"fa-light",fasdt:"fa-thin"}},YX=["fa-solid","fa-regular","fa-light","fa-thin","fa-duotone","fa-brands"],BA=["fa","fas","far","fal","fat","fad","fadr","fadl","fadt","fab","fass","fasr","fasl","fast","fasds","fasdr","fasdl","fasdt",...qX,...YX],KX=["solid","regular","light","thin","duotone","brands"],Y9=[1,2,3,4,5,6,7,8,9,10],ZX=Y9.concat([11,12,13,14,15,16,17,18,19,20]),XX=[...Object.keys(WX),...KX,"2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","fw","inverse","layers-counter","layers-text","layers","li","pull-left","pull-right","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul",Wv.GROUP,Wv.SWAP_OPACITY,Wv.PRIMARY,Wv.SECONDARY].concat(Y9.map(e=>"".concat(e,"x"))).concat(ZX.map(e=>"w-".concat(e))),QX={"Font Awesome 5 Free":{900:"fas",400:"far"},"Font Awesome 5 Pro":{900:"fas",400:"far",normal:"far",300:"fal"},"Font Awesome 5 Brands":{400:"fab",normal:"fab"},"Font Awesome 5 Duotone":{900:"fad"}};const rs="___FONT_AWESOME___",UA=16,K9="fa",Z9="svg-inline--fa",Xu="data-fa-i2svg",zA="data-fa-pseudo-element",JX="data-fa-pseudo-element-pending",bT="data-prefix",wT="data-icon",cM="fontawesome-i2svg",eQ="async",tQ=["HTML","HEAD","STYLE","SCRIPT"],X9=(()=>{try{return!0}catch{return!1}})();function Zm(e){return new Proxy(e,{get(t,n){return n in t?t[n]:t[Mr]}})}const Q9=Ke({},H9);Q9[Mr]=Ke(Ke(Ke(Ke({},{"fa-duotone":"duotone"}),H9[Mr]),lM.kit),lM["kit-duotone"]);const nQ=Zm(Q9),FA=Ke({},IX);FA[Mr]=Ke(Ke(Ke(Ke({},{duotone:"fad"}),FA[Mr]),uM.kit),uM["kit-duotone"]);const fM=Zm(FA),qA=Ke({},$A);qA[Mr]=Ke(Ke({},qA[Mr]),FX.kit);const _T=Zm(qA),VA=Ke({},GX);VA[Mr]=Ke(Ke({},VA[Mr]),UX.kit);Zm(VA);const rQ=jX,J9="fa-layers-text",iQ=PX,aQ=Ke({},LX);Zm(aQ);const oQ=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],Y_=RX,sQ=[...BX,...XX],Rp=jl.FontAwesomeConfig||{};function lQ(e){var t=pn.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}function uQ(e){return e===""?!0:e==="false"?!1:e==="true"?!0:e}pn&&typeof pn.querySelector=="function"&&[["data-family-prefix","familyPrefix"],["data-css-prefix","cssPrefix"],["data-family-default","familyDefault"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-auto-a11y","autoA11y"],["data-search-pseudo-elements","searchPseudoElements"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]].forEach(t=>{let[n,r]=t;const i=uQ(lQ(n));i!=null&&(Rp[r]=i)});const e$={styleDefault:"solid",familyDefault:Mr,cssPrefix:K9,replacementClass:Z9,autoReplaceSvg:!0,autoAddCss:!0,autoA11y:!0,searchPseudoElements:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};Rp.familyPrefix&&(Rp.cssPrefix=Rp.familyPrefix);const Uf=Ke(Ke({},e$),Rp);Uf.autoReplaceSvg||(Uf.observeMutations=!1);const ut={};Object.keys(e$).forEach(e=>{Object.defineProperty(ut,e,{enumerable:!0,set:function(t){Uf[e]=t,Mp.forEach(n=>n(ut))},get:function(){return Uf[e]}})});Object.defineProperty(ut,"familyPrefix",{enumerable:!0,set:function(e){Uf.cssPrefix=e,Mp.forEach(t=>t(ut))},get:function(){return Uf.cssPrefix}});jl.FontAwesomeConfig=ut;const Mp=[];function cQ(e){return Mp.push(e),()=>{Mp.splice(Mp.indexOf(e),1)}}const cl=UA,Za={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function fQ(e){if(!e||!cs)return;const t=pn.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;const n=pn.head.childNodes;let r=null;for(let i=n.length-1;i>-1;i--){const a=n[i],o=(a.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(o)>-1&&(r=a)}return pn.head.insertBefore(t,r),e}const dQ="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";function Gp(){let e=12,t="";for(;e-- >0;)t+=dQ[Math.random()*62|0];return t}function jd(e){const t=[];for(let n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function xT(e){return e.classList?jd(e.classList):(e.getAttribute("class")||"").split(" ").filter(t=>t)}function t$(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function hQ(e){return Object.keys(e||{}).reduce((t,n)=>t+"".concat(n,'="').concat(t$(e[n]),'" '),"").trim()}function Mb(e){return Object.keys(e||{}).reduce((t,n)=>t+"".concat(n,": ").concat(e[n].trim(),";"),"")}function ST(e){return e.size!==Za.size||e.x!==Za.x||e.y!==Za.y||e.rotate!==Za.rotate||e.flipX||e.flipY}function pQ(e){let{transform:t,containerWidth:n,iconWidth:r}=e;const i={transform:"translate(".concat(n/2," 256)")},a="translate(".concat(t.x*32,", ").concat(t.y*32,") "),o="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),l="rotate(".concat(t.rotate," 0 0)"),f={transform:"".concat(a," ").concat(o," ").concat(l)},u={transform:"translate(".concat(r/2*-1," -256)")};return{outer:i,inner:f,path:u}}function mQ(e){let{transform:t,width:n=UA,height:r=UA,startCentered:i=!1}=e,a="";return i&&V9?a+="translate(".concat(t.x/cl-n/2,"em, ").concat(t.y/cl-r/2,"em) "):i?a+="translate(calc(-50% + ".concat(t.x/cl,"em), calc(-50% + ").concat(t.y/cl,"em)) "):a+="translate(".concat(t.x/cl,"em, ").concat(t.y/cl,"em) "),a+="scale(".concat(t.size/cl*(t.flipX?-1:1),", ").concat(t.size/cl*(t.flipY?-1:1),") "),a+="rotate(".concat(t.rotate,"deg) "),a}var gQ=`:root, :host {
|
||
--fa-font-solid: normal 900 1em/1 "Font Awesome 6 Free";
|
||
--fa-font-regular: normal 400 1em/1 "Font Awesome 6 Free";
|
||
--fa-font-light: normal 300 1em/1 "Font Awesome 6 Pro";
|
||
--fa-font-thin: normal 100 1em/1 "Font Awesome 6 Pro";
|
||
--fa-font-duotone: normal 900 1em/1 "Font Awesome 6 Duotone";
|
||
--fa-font-duotone-regular: normal 400 1em/1 "Font Awesome 6 Duotone";
|
||
--fa-font-duotone-light: normal 300 1em/1 "Font Awesome 6 Duotone";
|
||
--fa-font-duotone-thin: normal 100 1em/1 "Font Awesome 6 Duotone";
|
||
--fa-font-brands: normal 400 1em/1 "Font Awesome 6 Brands";
|
||
--fa-font-sharp-solid: normal 900 1em/1 "Font Awesome 6 Sharp";
|
||
--fa-font-sharp-regular: normal 400 1em/1 "Font Awesome 6 Sharp";
|
||
--fa-font-sharp-light: normal 300 1em/1 "Font Awesome 6 Sharp";
|
||
--fa-font-sharp-thin: normal 100 1em/1 "Font Awesome 6 Sharp";
|
||
--fa-font-sharp-duotone-solid: normal 900 1em/1 "Font Awesome 6 Sharp Duotone";
|
||
--fa-font-sharp-duotone-regular: normal 400 1em/1 "Font Awesome 6 Sharp Duotone";
|
||
--fa-font-sharp-duotone-light: normal 300 1em/1 "Font Awesome 6 Sharp Duotone";
|
||
--fa-font-sharp-duotone-thin: normal 100 1em/1 "Font Awesome 6 Sharp Duotone";
|
||
}
|
||
|
||
svg:not(:root).svg-inline--fa, svg:not(:host).svg-inline--fa {
|
||
overflow: visible;
|
||
box-sizing: content-box;
|
||
}
|
||
|
||
.svg-inline--fa {
|
||
display: var(--fa-display, inline-block);
|
||
height: 1em;
|
||
overflow: visible;
|
||
vertical-align: -0.125em;
|
||
}
|
||
.svg-inline--fa.fa-2xs {
|
||
vertical-align: 0.1em;
|
||
}
|
||
.svg-inline--fa.fa-xs {
|
||
vertical-align: 0em;
|
||
}
|
||
.svg-inline--fa.fa-sm {
|
||
vertical-align: -0.0714285705em;
|
||
}
|
||
.svg-inline--fa.fa-lg {
|
||
vertical-align: -0.2em;
|
||
}
|
||
.svg-inline--fa.fa-xl {
|
||
vertical-align: -0.25em;
|
||
}
|
||
.svg-inline--fa.fa-2xl {
|
||
vertical-align: -0.3125em;
|
||
}
|
||
.svg-inline--fa.fa-pull-left {
|
||
margin-right: var(--fa-pull-margin, 0.3em);
|
||
width: auto;
|
||
}
|
||
.svg-inline--fa.fa-pull-right {
|
||
margin-left: var(--fa-pull-margin, 0.3em);
|
||
width: auto;
|
||
}
|
||
.svg-inline--fa.fa-li {
|
||
width: var(--fa-li-width, 2em);
|
||
top: 0.25em;
|
||
}
|
||
.svg-inline--fa.fa-fw {
|
||
width: var(--fa-fw-width, 1.25em);
|
||
}
|
||
|
||
.fa-layers svg.svg-inline--fa {
|
||
bottom: 0;
|
||
left: 0;
|
||
margin: auto;
|
||
position: absolute;
|
||
right: 0;
|
||
top: 0;
|
||
}
|
||
|
||
.fa-layers-counter, .fa-layers-text {
|
||
display: inline-block;
|
||
position: absolute;
|
||
text-align: center;
|
||
}
|
||
|
||
.fa-layers {
|
||
display: inline-block;
|
||
height: 1em;
|
||
position: relative;
|
||
text-align: center;
|
||
vertical-align: -0.125em;
|
||
width: 1em;
|
||
}
|
||
.fa-layers svg.svg-inline--fa {
|
||
transform-origin: center center;
|
||
}
|
||
|
||
.fa-layers-text {
|
||
left: 50%;
|
||
top: 50%;
|
||
transform: translate(-50%, -50%);
|
||
transform-origin: center center;
|
||
}
|
||
|
||
.fa-layers-counter {
|
||
background-color: var(--fa-counter-background-color, #ff253a);
|
||
border-radius: var(--fa-counter-border-radius, 1em);
|
||
box-sizing: border-box;
|
||
color: var(--fa-inverse, #fff);
|
||
line-height: var(--fa-counter-line-height, 1);
|
||
max-width: var(--fa-counter-max-width, 5em);
|
||
min-width: var(--fa-counter-min-width, 1.5em);
|
||
overflow: hidden;
|
||
padding: var(--fa-counter-padding, 0.25em 0.5em);
|
||
right: var(--fa-right, 0);
|
||
text-overflow: ellipsis;
|
||
top: var(--fa-top, 0);
|
||
transform: scale(var(--fa-counter-scale, 0.25));
|
||
transform-origin: top right;
|
||
}
|
||
|
||
.fa-layers-bottom-right {
|
||
bottom: var(--fa-bottom, 0);
|
||
right: var(--fa-right, 0);
|
||
top: auto;
|
||
transform: scale(var(--fa-layers-scale, 0.25));
|
||
transform-origin: bottom right;
|
||
}
|
||
|
||
.fa-layers-bottom-left {
|
||
bottom: var(--fa-bottom, 0);
|
||
left: var(--fa-left, 0);
|
||
right: auto;
|
||
top: auto;
|
||
transform: scale(var(--fa-layers-scale, 0.25));
|
||
transform-origin: bottom left;
|
||
}
|
||
|
||
.fa-layers-top-right {
|
||
top: var(--fa-top, 0);
|
||
right: var(--fa-right, 0);
|
||
transform: scale(var(--fa-layers-scale, 0.25));
|
||
transform-origin: top right;
|
||
}
|
||
|
||
.fa-layers-top-left {
|
||
left: var(--fa-left, 0);
|
||
right: auto;
|
||
top: var(--fa-top, 0);
|
||
transform: scale(var(--fa-layers-scale, 0.25));
|
||
transform-origin: top left;
|
||
}
|
||
|
||
.fa-1x {
|
||
font-size: 1em;
|
||
}
|
||
|
||
.fa-2x {
|
||
font-size: 2em;
|
||
}
|
||
|
||
.fa-3x {
|
||
font-size: 3em;
|
||
}
|
||
|
||
.fa-4x {
|
||
font-size: 4em;
|
||
}
|
||
|
||
.fa-5x {
|
||
font-size: 5em;
|
||
}
|
||
|
||
.fa-6x {
|
||
font-size: 6em;
|
||
}
|
||
|
||
.fa-7x {
|
||
font-size: 7em;
|
||
}
|
||
|
||
.fa-8x {
|
||
font-size: 8em;
|
||
}
|
||
|
||
.fa-9x {
|
||
font-size: 9em;
|
||
}
|
||
|
||
.fa-10x {
|
||
font-size: 10em;
|
||
}
|
||
|
||
.fa-2xs {
|
||
font-size: 0.625em;
|
||
line-height: 0.1em;
|
||
vertical-align: 0.225em;
|
||
}
|
||
|
||
.fa-xs {
|
||
font-size: 0.75em;
|
||
line-height: 0.0833333337em;
|
||
vertical-align: 0.125em;
|
||
}
|
||
|
||
.fa-sm {
|
||
font-size: 0.875em;
|
||
line-height: 0.0714285718em;
|
||
vertical-align: 0.0535714295em;
|
||
}
|
||
|
||
.fa-lg {
|
||
font-size: 1.25em;
|
||
line-height: 0.05em;
|
||
vertical-align: -0.075em;
|
||
}
|
||
|
||
.fa-xl {
|
||
font-size: 1.5em;
|
||
line-height: 0.0416666682em;
|
||
vertical-align: -0.125em;
|
||
}
|
||
|
||
.fa-2xl {
|
||
font-size: 2em;
|
||
line-height: 0.03125em;
|
||
vertical-align: -0.1875em;
|
||
}
|
||
|
||
.fa-fw {
|
||
text-align: center;
|
||
width: 1.25em;
|
||
}
|
||
|
||
.fa-ul {
|
||
list-style-type: none;
|
||
margin-left: var(--fa-li-margin, 2.5em);
|
||
padding-left: 0;
|
||
}
|
||
.fa-ul > li {
|
||
position: relative;
|
||
}
|
||
|
||
.fa-li {
|
||
left: calc(-1 * var(--fa-li-width, 2em));
|
||
position: absolute;
|
||
text-align: center;
|
||
width: var(--fa-li-width, 2em);
|
||
line-height: inherit;
|
||
}
|
||
|
||
.fa-border {
|
||
border-color: var(--fa-border-color, #eee);
|
||
border-radius: var(--fa-border-radius, 0.1em);
|
||
border-style: var(--fa-border-style, solid);
|
||
border-width: var(--fa-border-width, 0.08em);
|
||
padding: var(--fa-border-padding, 0.2em 0.25em 0.15em);
|
||
}
|
||
|
||
.fa-pull-left {
|
||
float: left;
|
||
margin-right: var(--fa-pull-margin, 0.3em);
|
||
}
|
||
|
||
.fa-pull-right {
|
||
float: right;
|
||
margin-left: var(--fa-pull-margin, 0.3em);
|
||
}
|
||
|
||
.fa-beat {
|
||
animation-name: fa-beat;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, ease-in-out);
|
||
}
|
||
|
||
.fa-bounce {
|
||
animation-name: fa-bounce;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));
|
||
}
|
||
|
||
.fa-fade {
|
||
animation-name: fa-fade;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));
|
||
}
|
||
|
||
.fa-beat-fade {
|
||
animation-name: fa-beat-fade;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));
|
||
}
|
||
|
||
.fa-flip {
|
||
animation-name: fa-flip;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, ease-in-out);
|
||
}
|
||
|
||
.fa-shake {
|
||
animation-name: fa-shake;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, linear);
|
||
}
|
||
|
||
.fa-spin {
|
||
animation-name: fa-spin;
|
||
animation-delay: var(--fa-animation-delay, 0s);
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 2s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, linear);
|
||
}
|
||
|
||
.fa-spin-reverse {
|
||
--fa-animation-direction: reverse;
|
||
}
|
||
|
||
.fa-pulse,
|
||
.fa-spin-pulse {
|
||
animation-name: fa-spin;
|
||
animation-direction: var(--fa-animation-direction, normal);
|
||
animation-duration: var(--fa-animation-duration, 1s);
|
||
animation-iteration-count: var(--fa-animation-iteration-count, infinite);
|
||
animation-timing-function: var(--fa-animation-timing, steps(8));
|
||
}
|
||
|
||
@media (prefers-reduced-motion: reduce) {
|
||
.fa-beat,
|
||
.fa-bounce,
|
||
.fa-fade,
|
||
.fa-beat-fade,
|
||
.fa-flip,
|
||
.fa-pulse,
|
||
.fa-shake,
|
||
.fa-spin,
|
||
.fa-spin-pulse {
|
||
animation-delay: -1ms;
|
||
animation-duration: 1ms;
|
||
animation-iteration-count: 1;
|
||
transition-delay: 0s;
|
||
transition-duration: 0s;
|
||
}
|
||
}
|
||
@keyframes fa-beat {
|
||
0%, 90% {
|
||
transform: scale(1);
|
||
}
|
||
45% {
|
||
transform: scale(var(--fa-beat-scale, 1.25));
|
||
}
|
||
}
|
||
@keyframes fa-bounce {
|
||
0% {
|
||
transform: scale(1, 1) translateY(0);
|
||
}
|
||
10% {
|
||
transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);
|
||
}
|
||
30% {
|
||
transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));
|
||
}
|
||
50% {
|
||
transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);
|
||
}
|
||
57% {
|
||
transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));
|
||
}
|
||
64% {
|
||
transform: scale(1, 1) translateY(0);
|
||
}
|
||
100% {
|
||
transform: scale(1, 1) translateY(0);
|
||
}
|
||
}
|
||
@keyframes fa-fade {
|
||
50% {
|
||
opacity: var(--fa-fade-opacity, 0.4);
|
||
}
|
||
}
|
||
@keyframes fa-beat-fade {
|
||
0%, 100% {
|
||
opacity: var(--fa-beat-fade-opacity, 0.4);
|
||
transform: scale(1);
|
||
}
|
||
50% {
|
||
opacity: 1;
|
||
transform: scale(var(--fa-beat-fade-scale, 1.125));
|
||
}
|
||
}
|
||
@keyframes fa-flip {
|
||
50% {
|
||
transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));
|
||
}
|
||
}
|
||
@keyframes fa-shake {
|
||
0% {
|
||
transform: rotate(-15deg);
|
||
}
|
||
4% {
|
||
transform: rotate(15deg);
|
||
}
|
||
8%, 24% {
|
||
transform: rotate(-18deg);
|
||
}
|
||
12%, 28% {
|
||
transform: rotate(18deg);
|
||
}
|
||
16% {
|
||
transform: rotate(-22deg);
|
||
}
|
||
20% {
|
||
transform: rotate(22deg);
|
||
}
|
||
32% {
|
||
transform: rotate(-12deg);
|
||
}
|
||
36% {
|
||
transform: rotate(12deg);
|
||
}
|
||
40%, 100% {
|
||
transform: rotate(0deg);
|
||
}
|
||
}
|
||
@keyframes fa-spin {
|
||
0% {
|
||
transform: rotate(0deg);
|
||
}
|
||
100% {
|
||
transform: rotate(360deg);
|
||
}
|
||
}
|
||
.fa-rotate-90 {
|
||
transform: rotate(90deg);
|
||
}
|
||
|
||
.fa-rotate-180 {
|
||
transform: rotate(180deg);
|
||
}
|
||
|
||
.fa-rotate-270 {
|
||
transform: rotate(270deg);
|
||
}
|
||
|
||
.fa-flip-horizontal {
|
||
transform: scale(-1, 1);
|
||
}
|
||
|
||
.fa-flip-vertical {
|
||
transform: scale(1, -1);
|
||
}
|
||
|
||
.fa-flip-both,
|
||
.fa-flip-horizontal.fa-flip-vertical {
|
||
transform: scale(-1, -1);
|
||
}
|
||
|
||
.fa-rotate-by {
|
||
transform: rotate(var(--fa-rotate-angle, 0));
|
||
}
|
||
|
||
.fa-stack {
|
||
display: inline-block;
|
||
vertical-align: middle;
|
||
height: 2em;
|
||
position: relative;
|
||
width: 2.5em;
|
||
}
|
||
|
||
.fa-stack-1x,
|
||
.fa-stack-2x {
|
||
bottom: 0;
|
||
left: 0;
|
||
margin: auto;
|
||
position: absolute;
|
||
right: 0;
|
||
top: 0;
|
||
z-index: var(--fa-stack-z-index, auto);
|
||
}
|
||
|
||
.svg-inline--fa.fa-stack-1x {
|
||
height: 1em;
|
||
width: 1.25em;
|
||
}
|
||
.svg-inline--fa.fa-stack-2x {
|
||
height: 2em;
|
||
width: 2.5em;
|
||
}
|
||
|
||
.fa-inverse {
|
||
color: var(--fa-inverse, #fff);
|
||
}
|
||
|
||
.sr-only,
|
||
.fa-sr-only {
|
||
position: absolute;
|
||
width: 1px;
|
||
height: 1px;
|
||
padding: 0;
|
||
margin: -1px;
|
||
overflow: hidden;
|
||
clip: rect(0, 0, 0, 0);
|
||
white-space: nowrap;
|
||
border-width: 0;
|
||
}
|
||
|
||
.sr-only-focusable:not(:focus),
|
||
.fa-sr-only-focusable:not(:focus) {
|
||
position: absolute;
|
||
width: 1px;
|
||
height: 1px;
|
||
padding: 0;
|
||
margin: -1px;
|
||
overflow: hidden;
|
||
clip: rect(0, 0, 0, 0);
|
||
white-space: nowrap;
|
||
border-width: 0;
|
||
}
|
||
|
||
.svg-inline--fa .fa-primary {
|
||
fill: var(--fa-primary-color, currentColor);
|
||
opacity: var(--fa-primary-opacity, 1);
|
||
}
|
||
|
||
.svg-inline--fa .fa-secondary {
|
||
fill: var(--fa-secondary-color, currentColor);
|
||
opacity: var(--fa-secondary-opacity, 0.4);
|
||
}
|
||
|
||
.svg-inline--fa.fa-swap-opacity .fa-primary {
|
||
opacity: var(--fa-secondary-opacity, 0.4);
|
||
}
|
||
|
||
.svg-inline--fa.fa-swap-opacity .fa-secondary {
|
||
opacity: var(--fa-primary-opacity, 1);
|
||
}
|
||
|
||
.svg-inline--fa mask .fa-primary,
|
||
.svg-inline--fa mask .fa-secondary {
|
||
fill: black;
|
||
}`;function n$(){const e=K9,t=Z9,n=ut.cssPrefix,r=ut.replacementClass;let i=gQ;if(n!==e||r!==t){const a=new RegExp("\\.".concat(e,"\\-"),"g"),o=new RegExp("\\--".concat(e,"\\-"),"g"),l=new RegExp("\\.".concat(t),"g");i=i.replace(a,".".concat(n,"-")).replace(o,"--".concat(n,"-")).replace(l,".".concat(r))}return i}let dM=!1;function K_(){ut.autoAddCss&&!dM&&(fQ(n$()),dM=!0)}var vQ={mixout(){return{dom:{css:n$,insertCss:K_}}},hooks(){return{beforeDOMElementCreation(){K_()},beforeI2svg(){K_()}}}};const is=jl||{};is[rs]||(is[rs]={});is[rs].styles||(is[rs].styles={});is[rs].hooks||(is[rs].hooks={});is[rs].shims||(is[rs].shims=[]);var Xa=is[rs];const r$=[],i$=function(){pn.removeEventListener("DOMContentLoaded",i$),Fy=1,r$.map(e=>e())};let Fy=!1;cs&&(Fy=(pn.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(pn.readyState),Fy||pn.addEventListener("DOMContentLoaded",i$));function yQ(e){cs&&(Fy?setTimeout(e,0):r$.push(e))}function Xm(e){const{tag:t,attributes:n={},children:r=[]}=e;return typeof e=="string"?t$(e):"<".concat(t," ").concat(hQ(n),">").concat(r.map(Xm).join(""),"</").concat(t,">")}function hM(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}var Z_=function(t,n,r,i){var a=Object.keys(t),o=a.length,l=n,f,u,h;for(r===void 0?(f=1,h=t[a[0]]):(f=0,h=r);f<o;f++)u=a[f],h=l(h,t[u],u,t);return h};function bQ(e){const t=[];let n=0;const r=e.length;for(;n<r;){const i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){const a=e.charCodeAt(n++);(a&64512)==56320?t.push(((i&1023)<<10)+(a&1023)+65536):(t.push(i),n--)}else t.push(i)}return t}function HA(e){const t=bQ(e);return t.length===1?t[0].toString(16):null}function wQ(e,t){const n=e.length;let r=e.charCodeAt(t),i;return r>=55296&&r<=56319&&n>t+1&&(i=e.charCodeAt(t+1),i>=56320&&i<=57343)?(r-55296)*1024+i-56320+65536:r}function pM(e){return Object.keys(e).reduce((t,n)=>{const r=e[n];return!!r.icon?t[r.iconName]=r.icon:t[n]=r,t},{})}function GA(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const{skipHooks:r=!1}=n,i=pM(t);typeof Xa.hooks.addPack=="function"&&!r?Xa.hooks.addPack(e,pM(t)):Xa.styles[e]=Ke(Ke({},Xa.styles[e]||{}),i),e==="fas"&&GA("fa",t)}const{styles:Wp,shims:_Q}=Xa,a$=Object.keys(_T),xQ=a$.reduce((e,t)=>(e[t]=Object.keys(_T[t]),e),{});let CT=null,o$={},s$={},l$={},u$={},c$={};function SQ(e){return~sQ.indexOf(e)}function CQ(e,t){const n=t.split("-"),r=n[0],i=n.slice(1).join("-");return r===e&&i!==""&&!SQ(i)?i:null}const f$=()=>{const e=r=>Z_(Wp,(i,a,o)=>(i[o]=Z_(a,r,{}),i),{});o$=e((r,i,a)=>(i[3]&&(r[i[3]]=a),i[2]&&i[2].filter(l=>typeof l=="number").forEach(l=>{r[l.toString(16)]=a}),r)),s$=e((r,i,a)=>(r[a]=a,i[2]&&i[2].filter(l=>typeof l=="string").forEach(l=>{r[l]=a}),r)),c$=e((r,i,a)=>{const o=i[2];return r[a]=a,o.forEach(l=>{r[l]=a}),r});const t="far"in Wp||ut.autoFetchSvg,n=Z_(_Q,(r,i)=>{const a=i[0];let o=i[1];const l=i[2];return o==="far"&&!t&&(o="fas"),typeof a=="string"&&(r.names[a]={prefix:o,iconName:l}),typeof a=="number"&&(r.unicodes[a.toString(16)]={prefix:o,iconName:l}),r},{names:{},unicodes:{}});l$=n.names,u$=n.unicodes,CT=Nb(ut.styleDefault,{family:ut.familyDefault})};cQ(e=>{CT=Nb(e.styleDefault,{family:ut.familyDefault})});f$();function AT(e,t){return(o$[e]||{})[t]}function AQ(e,t){return(s$[e]||{})[t]}function Bu(e,t){return(c$[e]||{})[t]}function d$(e){return l$[e]||{prefix:null,iconName:null}}function EQ(e){const t=u$[e],n=AT("fas",e);return t||(n?{prefix:"fas",iconName:n}:null)||{prefix:null,iconName:null}}function Pl(){return CT}const h$=()=>({prefix:null,iconName:null,rest:[]});function OQ(e){let t=Mr;const n=a$.reduce((r,i)=>(r[i]="".concat(ut.cssPrefix,"-").concat(i),r),{});return W9.forEach(r=>{(e.includes(n[r])||e.some(i=>xQ[r].includes(i)))&&(t=r)}),t}function Nb(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{family:n=Mr}=t,r=nQ[n][e];if(n===Rb&&!e)return"fad";const i=fM[n][e]||fM[n][r],a=e in Xa.styles?e:null;return i||a||null}function TQ(e){let t=[],n=null;return e.forEach(r=>{const i=CQ(ut.cssPrefix,r);i?n=i:r&&t.push(r)}),{iconName:n,rest:t}}function mM(e){return e.sort().filter((t,n,r)=>r.indexOf(t)===n)}function Lb(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{skipLookups:n=!1}=t;let r=null;const i=BA.concat(VX),a=mM(e.filter(m=>i.includes(m))),o=mM(e.filter(m=>!BA.includes(m))),l=a.filter(m=>(r=m,!G9.includes(m))),[f=null]=l,u=OQ(a),h=Ke(Ke({},TQ(o)),{},{prefix:Nb(f,{family:u})});return Ke(Ke(Ke({},h),MQ({values:e,family:u,styles:Wp,config:ut,canonical:h,givenPrefix:r})),jQ(n,r,h))}function jQ(e,t,n){let{prefix:r,iconName:i}=n;if(e||!r||!i)return{prefix:r,iconName:i};const a=t==="fa"?d$(i):{},o=Bu(r,i);return i=a.iconName||o||i,r=a.prefix||r,r==="far"&&!Wp.far&&Wp.fas&&!ut.autoFetchSvg&&(r="fas"),{prefix:r,iconName:i}}const PQ=W9.filter(e=>e!==Mr||e!==Rb),RQ=Object.keys($A).filter(e=>e!==Mr).map(e=>Object.keys($A[e])).flat();function MQ(e){const{values:t,family:n,canonical:r,givenPrefix:i="",styles:a={},config:o={}}=e,l=n===Rb,f=t.includes("fa-duotone")||t.includes("fad"),u=o.familyDefault==="duotone",h=r.prefix==="fad"||r.prefix==="fa-duotone";if(!l&&(f||u||h)&&(r.prefix="fad"),(t.includes("fa-brands")||t.includes("fab"))&&(r.prefix="fab"),!r.prefix&&PQ.includes(n)&&(Object.keys(a).find(g=>RQ.includes(g))||o.autoFetchSvg)){const g=DX.get(n).defaultShortPrefixId;r.prefix=g,r.iconName=Bu(r.prefix,r.iconName)||r.iconName}return(r.prefix==="fa"||i==="fa")&&(r.prefix=Pl()||"fas"),r}class NQ{constructor(){this.definitions={}}add(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const i=n.reduce(this._pullDefinitions,{});Object.keys(i).forEach(a=>{this.definitions[a]=Ke(Ke({},this.definitions[a]||{}),i[a]),GA(a,i[a]);const o=_T[Mr][a];o&&GA(o,i[a]),f$()})}reset(){this.definitions={}}_pullDefinitions(t,n){const r=n.prefix&&n.iconName&&n.icon?{0:n}:n;return Object.keys(r).map(i=>{const{prefix:a,iconName:o,icon:l}=r[i],f=l[2];t[a]||(t[a]={}),f.length>0&&f.forEach(u=>{typeof u=="string"&&(t[a][u]=l)}),t[a][o]=l}),t}}let gM=[],_f={};const jf={},LQ=Object.keys(jf);function kQ(e,t){let{mixoutsTo:n}=t;return gM=e,_f={},Object.keys(jf).forEach(r=>{LQ.indexOf(r)===-1&&delete jf[r]}),gM.forEach(r=>{const i=r.mixout?r.mixout():{};if(Object.keys(i).forEach(a=>{typeof i[a]=="function"&&(n[a]=i[a]),typeof i[a]=="object"&&Object.keys(i[a]).forEach(o=>{n[a]||(n[a]={}),n[a][o]=i[a][o]})}),r.hooks){const a=r.hooks();Object.keys(a).forEach(o=>{_f[o]||(_f[o]=[]),_f[o].push(a[o])})}r.provides&&r.provides(jf)}),n}function WA(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return(_f[e]||[]).forEach(o=>{t=o.apply(null,[t,...r])}),t}function Qu(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];(_f[e]||[]).forEach(a=>{a.apply(null,n)})}function Rl(){const e=arguments[0],t=Array.prototype.slice.call(arguments,1);return jf[e]?jf[e].apply(null,t):void 0}function YA(e){e.prefix==="fa"&&(e.prefix="fas");let{iconName:t}=e;const n=e.prefix||Pl();if(t)return t=Bu(n,t)||t,hM(p$.definitions,n,t)||hM(Xa.styles,n,t)}const p$=new NQ,DQ=()=>{ut.autoReplaceSvg=!1,ut.observeMutations=!1,Qu("noAuto")},IQ={i2svg:function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return cs?(Qu("beforeI2svg",e),Rl("pseudoElements2svg",e),Rl("i2svg",e)):Promise.reject(new Error("Operation requires a DOM of some kind."))},watch:function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{autoReplaceSvgRoot:t}=e;ut.autoReplaceSvg===!1&&(ut.autoReplaceSvg=!0),ut.observeMutations=!0,yQ(()=>{BQ({autoReplaceSvgRoot:t}),Qu("watch",e)})}},$Q={icon:e=>{if(e===null)return null;if(typeof e=="object"&&e.prefix&&e.iconName)return{prefix:e.prefix,iconName:Bu(e.prefix,e.iconName)||e.iconName};if(Array.isArray(e)&&e.length===2){const t=e[1].indexOf("fa-")===0?e[1].slice(3):e[1],n=Nb(e[0]);return{prefix:n,iconName:Bu(n,t)||t}}if(typeof e=="string"&&(e.indexOf("".concat(ut.cssPrefix,"-"))>-1||e.match(rQ))){const t=Lb(e.split(" "),{skipLookups:!0});return{prefix:t.prefix||Pl(),iconName:Bu(t.prefix,t.iconName)||t.iconName}}if(typeof e=="string"){const t=Pl();return{prefix:t,iconName:Bu(t,e)||e}}}},ki={noAuto:DQ,config:ut,dom:IQ,parse:$Q,library:p$,findIconDefinition:YA,toHtml:Xm},BQ=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{autoReplaceSvgRoot:t=pn}=e;(Object.keys(Xa.styles).length>0||ut.autoFetchSvg)&&cs&&ut.autoReplaceSvg&&ki.dom.i2svg({node:t})};function kb(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(n=>Xm(n))}}),Object.defineProperty(e,"node",{get:function(){if(!cs)return;const n=pn.createElement("div");return n.innerHTML=e.html,n.children}}),e}function UQ(e){let{children:t,main:n,mask:r,attributes:i,styles:a,transform:o}=e;if(ST(o)&&n.found&&!r.found){const{width:l,height:f}=n,u={x:l/f/2,y:.5};i.style=Mb(Ke(Ke({},a),{},{"transform-origin":"".concat(u.x+o.x/16,"em ").concat(u.y+o.y/16,"em")}))}return[{tag:"svg",attributes:i,children:t}]}function zQ(e){let{prefix:t,iconName:n,children:r,attributes:i,symbol:a}=e;const o=a===!0?"".concat(t,"-").concat(ut.cssPrefix,"-").concat(n):a;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:Ke(Ke({},i),{},{id:o}),children:r}]}]}function ET(e){const{icons:{main:t,mask:n},prefix:r,iconName:i,transform:a,symbol:o,title:l,maskId:f,titleId:u,extra:h,watchable:m=!1}=e,{width:g,height:_}=n.found?n:t,x=zX.includes(r),b=[ut.replacementClass,i?"".concat(ut.cssPrefix,"-").concat(i):""].filter(j=>h.classes.indexOf(j)===-1).filter(j=>j!==""||!!j).concat(h.classes).join(" ");let S={children:[],attributes:Ke(Ke({},h.attributes),{},{"data-prefix":r,"data-icon":i,class:b,role:h.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(g," ").concat(_)})};const C=x&&!~h.classes.indexOf("fa-fw")?{width:"".concat(g/_*16*.0625,"em")}:{};m&&(S.attributes[Xu]=""),l&&(S.children.push({tag:"title",attributes:{id:S.attributes["aria-labelledby"]||"title-".concat(u||Gp())},children:[l]}),delete S.attributes.title);const A=Ke(Ke({},S),{},{prefix:r,iconName:i,main:t,mask:n,maskId:f,transform:a,symbol:o,styles:Ke(Ke({},C),h.styles)}),{children:O,attributes:P}=n.found&&t.found?Rl("generateAbstractMask",A)||{children:[],attributes:{}}:Rl("generateAbstractIcon",A)||{children:[],attributes:{}};return A.children=O,A.attributes=P,o?zQ(A):UQ(A)}function vM(e){const{content:t,width:n,height:r,transform:i,title:a,extra:o,watchable:l=!1}=e,f=Ke(Ke(Ke({},o.attributes),a?{title:a}:{}),{},{class:o.classes.join(" ")});l&&(f[Xu]="");const u=Ke({},o.styles);ST(i)&&(u.transform=mQ({transform:i,startCentered:!0,width:n,height:r}),u["-webkit-transform"]=u.transform);const h=Mb(u);h.length>0&&(f.style=h);const m=[];return m.push({tag:"span",attributes:f,children:[t]}),a&&m.push({tag:"span",attributes:{class:"sr-only"},children:[a]}),m}function FQ(e){const{content:t,title:n,extra:r}=e,i=Ke(Ke(Ke({},r.attributes),n?{title:n}:{}),{},{class:r.classes.join(" ")}),a=Mb(r.styles);a.length>0&&(i.style=a);const o=[];return o.push({tag:"span",attributes:i,children:[t]}),n&&o.push({tag:"span",attributes:{class:"sr-only"},children:[n]}),o}const{styles:X_}=Xa;function KA(e){const t=e[0],n=e[1],[r]=e.slice(4);let i=null;return Array.isArray(r)?i={tag:"g",attributes:{class:"".concat(ut.cssPrefix,"-").concat(Y_.GROUP)},children:[{tag:"path",attributes:{class:"".concat(ut.cssPrefix,"-").concat(Y_.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(ut.cssPrefix,"-").concat(Y_.PRIMARY),fill:"currentColor",d:r[1]}}]}:i={tag:"path",attributes:{fill:"currentColor",d:r}},{found:!0,width:t,height:n,icon:i}}const qQ={found:!1,width:512,height:512};function VQ(e,t){!X9&&!ut.showMissingIcons&&e&&console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}function ZA(e,t){let n=t;return t==="fa"&&ut.styleDefault!==null&&(t=Pl()),new Promise((r,i)=>{if(n==="fa"){const a=d$(e)||{};e=a.iconName||e,t=a.prefix||t}if(e&&t&&X_[t]&&X_[t][e]){const a=X_[t][e];return r(KA(a))}VQ(e,t),r(Ke(Ke({},qQ),{},{icon:ut.showMissingIcons&&e?Rl("missingIconAbstract")||{}:{}}))})}const yM=()=>{},XA=ut.measurePerformance&&Gv&&Gv.mark&&Gv.measure?Gv:{mark:yM,measure:yM},gp='FA "6.7.2"',HQ=e=>(XA.mark("".concat(gp," ").concat(e," begins")),()=>m$(e)),m$=e=>{XA.mark("".concat(gp," ").concat(e," ends")),XA.measure("".concat(gp," ").concat(e),"".concat(gp," ").concat(e," begins"),"".concat(gp," ").concat(e," ends"))};var OT={begin:HQ,end:m$};const Oy=()=>{};function bM(e){return typeof(e.getAttribute?e.getAttribute(Xu):null)=="string"}function GQ(e){const t=e.getAttribute?e.getAttribute(bT):null,n=e.getAttribute?e.getAttribute(wT):null;return t&&n}function WQ(e){return e&&e.classList&&e.classList.contains&&e.classList.contains(ut.replacementClass)}function YQ(){return ut.autoReplaceSvg===!0?Ty.replace:Ty[ut.autoReplaceSvg]||Ty.replace}function KQ(e){return pn.createElementNS("http://www.w3.org/2000/svg",e)}function ZQ(e){return pn.createElement(e)}function g$(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{ceFn:n=e.tag==="svg"?KQ:ZQ}=t;if(typeof e=="string")return pn.createTextNode(e);const r=n(e.tag);return Object.keys(e.attributes||[]).forEach(function(a){r.setAttribute(a,e.attributes[a])}),(e.children||[]).forEach(function(a){r.appendChild(g$(a,{ceFn:n}))}),r}function XQ(e){let t=" ".concat(e.outerHTML," ");return t="".concat(t,"Font Awesome fontawesome.com "),t}const Ty={replace:function(e){const t=e[0];if(t.parentNode)if(e[1].forEach(n=>{t.parentNode.insertBefore(g$(n),t)}),t.getAttribute(Xu)===null&&ut.keepOriginalSource){let n=pn.createComment(XQ(t));t.parentNode.replaceChild(n,t)}else t.remove()},nest:function(e){const t=e[0],n=e[1];if(~xT(t).indexOf(ut.replacementClass))return Ty.replace(e);const r=new RegExp("".concat(ut.cssPrefix,"-.*"));if(delete n[0].attributes.id,n[0].attributes.class){const a=n[0].attributes.class.split(" ").reduce((o,l)=>(l===ut.replacementClass||l.match(r)?o.toSvg.push(l):o.toNode.push(l),o),{toNode:[],toSvg:[]});n[0].attributes.class=a.toSvg.join(" "),a.toNode.length===0?t.removeAttribute("class"):t.setAttribute("class",a.toNode.join(" "))}const i=n.map(a=>Xm(a)).join(`
|
||
`);t.setAttribute(Xu,""),t.innerHTML=i}};function wM(e){e()}function v$(e,t){const n=typeof t=="function"?t:Oy;if(e.length===0)n();else{let r=wM;ut.mutateApproach===eQ&&(r=jl.requestAnimationFrame||wM),r(()=>{const i=YQ(),a=OT.begin("mutate");e.map(i),a(),n()})}}let TT=!1;function y$(){TT=!0}function QA(){TT=!1}let qy=null;function _M(e){if(!sM||!ut.observeMutations)return;const{treeCallback:t=Oy,nodeCallback:n=Oy,pseudoElementsCallback:r=Oy,observeMutationsRoot:i=pn}=e;qy=new sM(a=>{if(TT)return;const o=Pl();jd(a).forEach(l=>{if(l.type==="childList"&&l.addedNodes.length>0&&!bM(l.addedNodes[0])&&(ut.searchPseudoElements&&r(l.target),t(l.target)),l.type==="attributes"&&l.target.parentNode&&ut.searchPseudoElements&&r(l.target.parentNode),l.type==="attributes"&&bM(l.target)&&~oQ.indexOf(l.attributeName))if(l.attributeName==="class"&&GQ(l.target)){const{prefix:f,iconName:u}=Lb(xT(l.target));l.target.setAttribute(bT,f||o),u&&l.target.setAttribute(wT,u)}else WQ(l.target)&&n(l.target)})}),cs&&qy.observe(i,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}function QQ(){qy&&qy.disconnect()}function JQ(e){const t=e.getAttribute("style");let n=[];return t&&(n=t.split(";").reduce((r,i)=>{const a=i.split(":"),o=a[0],l=a.slice(1);return o&&l.length>0&&(r[o]=l.join(":").trim()),r},{})),n}function eJ(e){const t=e.getAttribute("data-prefix"),n=e.getAttribute("data-icon"),r=e.innerText!==void 0?e.innerText.trim():"";let i=Lb(xT(e));return i.prefix||(i.prefix=Pl()),t&&n&&(i.prefix=t,i.iconName=n),i.iconName&&i.prefix||(i.prefix&&r.length>0&&(i.iconName=AQ(i.prefix,e.innerText)||AT(i.prefix,HA(e.innerText))),!i.iconName&&ut.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function tJ(e){const t=jd(e.attributes).reduce((i,a)=>(i.name!=="class"&&i.name!=="style"&&(i[a.name]=a.value),i),{}),n=e.getAttribute("title"),r=e.getAttribute("data-fa-title-id");return ut.autoA11y&&(n?t["aria-labelledby"]="".concat(ut.replacementClass,"-title-").concat(r||Gp()):(t["aria-hidden"]="true",t.focusable="false")),t}function nJ(){return{iconName:null,title:null,titleId:null,prefix:null,transform:Za,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}}}function xM(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{styleParser:!0};const{iconName:n,prefix:r,rest:i}=eJ(e),a=tJ(e),o=WA("parseNodeAttributes",{},e);let l=t.styleParser?JQ(e):[];return Ke({iconName:n,title:e.getAttribute("title"),titleId:e.getAttribute("data-fa-title-id"),prefix:r,transform:Za,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:i,styles:l,attributes:a}},o)}const{styles:rJ}=Xa;function b$(e){const t=ut.autoReplaceSvg==="nest"?xM(e,{styleParser:!1}):xM(e);return~t.extra.classes.indexOf(J9)?Rl("generateLayersText",e,t):Rl("generateSvgReplacementMutation",e,t)}function iJ(){return[...$X,...BA]}function SM(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(!cs)return Promise.resolve();const n=pn.documentElement.classList,r=h=>n.add("".concat(cM,"-").concat(h)),i=h=>n.remove("".concat(cM,"-").concat(h)),a=ut.autoFetchSvg?iJ():G9.concat(Object.keys(rJ));a.includes("fa")||a.push("fa");const o=[".".concat(J9,":not([").concat(Xu,"])")].concat(a.map(h=>".".concat(h,":not([").concat(Xu,"])"))).join(", ");if(o.length===0)return Promise.resolve();let l=[];try{l=jd(e.querySelectorAll(o))}catch{}if(l.length>0)r("pending"),i("complete");else return Promise.resolve();const f=OT.begin("onTree"),u=l.reduce((h,m)=>{try{const g=b$(m);g&&h.push(g)}catch(g){X9||g.name==="MissingIcon"&&console.error(g)}return h},[]);return new Promise((h,m)=>{Promise.all(u).then(g=>{v$(g,()=>{r("active"),r("complete"),i("pending"),typeof t=="function"&&t(),f(),h()})}).catch(g=>{f(),m(g)})})}function aJ(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;b$(e).then(n=>{n&&v$([n],t)})}function oJ(e){return function(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const r=(t||{}).icon?t:YA(t||{});let{mask:i}=n;return i&&(i=(i||{}).icon?i:YA(i||{})),e(r,Ke(Ke({},n),{},{mask:i}))}}const sJ=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{transform:n=Za,symbol:r=!1,mask:i=null,maskId:a=null,title:o=null,titleId:l=null,classes:f=[],attributes:u={},styles:h={}}=t;if(!e)return;const{prefix:m,iconName:g,icon:_}=e;return kb(Ke({type:"icon"},e),()=>(Qu("beforeDOMElementCreation",{iconDefinition:e,params:t}),ut.autoA11y&&(o?u["aria-labelledby"]="".concat(ut.replacementClass,"-title-").concat(l||Gp()):(u["aria-hidden"]="true",u.focusable="false")),ET({icons:{main:KA(_),mask:i?KA(i.icon):{found:!1,width:null,height:null,icon:{}}},prefix:m,iconName:g,transform:Ke(Ke({},Za),n),symbol:r,title:o,maskId:a,titleId:l,extra:{attributes:u,styles:h,classes:f}})))};var lJ={mixout(){return{icon:oJ(sJ)}},hooks(){return{mutationObserverCallbacks(e){return e.treeCallback=SM,e.nodeCallback=aJ,e}}},provides(e){e.i2svg=function(t){const{node:n=pn,callback:r=()=>{}}=t;return SM(n,r)},e.generateSvgReplacementMutation=function(t,n){const{iconName:r,title:i,titleId:a,prefix:o,transform:l,symbol:f,mask:u,maskId:h,extra:m}=n;return new Promise((g,_)=>{Promise.all([ZA(r,o),u.iconName?ZA(u.iconName,u.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(x=>{let[b,S]=x;g([t,ET({icons:{main:b,mask:S},prefix:o,iconName:r,transform:l,symbol:f,maskId:h,title:i,titleId:a,extra:m,watchable:!0})])}).catch(_)})},e.generateAbstractIcon=function(t){let{children:n,attributes:r,main:i,transform:a,styles:o}=t;const l=Mb(o);l.length>0&&(r.style=l);let f;return ST(a)&&(f=Rl("generateAbstractTransformGrouping",{main:i,transform:a,containerWidth:i.width,iconWidth:i.width})),n.push(f||i.icon),{children:n,attributes:r}}}},uJ={mixout(){return{layer(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{classes:n=[]}=t;return kb({type:"layer"},()=>{Qu("beforeDOMElementCreation",{assembler:e,params:t});let r=[];return e(i=>{Array.isArray(i)?i.map(a=>{r=r.concat(a.abstract)}):r=r.concat(i.abstract)}),[{tag:"span",attributes:{class:["".concat(ut.cssPrefix,"-layers"),...n].join(" ")},children:r}]})}}}},cJ={mixout(){return{counter(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{title:n=null,classes:r=[],attributes:i={},styles:a={}}=t;return kb({type:"counter",content:e},()=>(Qu("beforeDOMElementCreation",{content:e,params:t}),FQ({content:e.toString(),title:n,extra:{attributes:i,styles:a,classes:["".concat(ut.cssPrefix,"-layers-counter"),...r]}})))}}}},fJ={mixout(){return{text(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{transform:n=Za,title:r=null,classes:i=[],attributes:a={},styles:o={}}=t;return kb({type:"text",content:e},()=>(Qu("beforeDOMElementCreation",{content:e,params:t}),vM({content:e,transform:Ke(Ke({},Za),n),title:r,extra:{attributes:a,styles:o,classes:["".concat(ut.cssPrefix,"-layers-text"),...i]}})))}}},provides(e){e.generateLayersText=function(t,n){const{title:r,transform:i,extra:a}=n;let o=null,l=null;if(V9){const f=parseInt(getComputedStyle(t).fontSize,10),u=t.getBoundingClientRect();o=u.width/f,l=u.height/f}return ut.autoA11y&&!r&&(a.attributes["aria-hidden"]="true"),Promise.resolve([t,vM({content:t.innerHTML,width:o,height:l,transform:i,title:r,extra:a,watchable:!0})])}}};const dJ=new RegExp('"',"ug"),CM=[1105920,1112319],AM=Ke(Ke(Ke(Ke({},{FontAwesome:{normal:"fas",400:"fas"}}),kX),QX),HX),JA=Object.keys(AM).reduce((e,t)=>(e[t.toLowerCase()]=AM[t],e),{}),hJ=Object.keys(JA).reduce((e,t)=>{const n=JA[t];return e[t]=n[900]||[...Object.entries(n)][0][1],e},{});function pJ(e){const t=e.replace(dJ,""),n=wQ(t,0),r=n>=CM[0]&&n<=CM[1],i=t.length===2?t[0]===t[1]:!1;return{value:HA(i?t[0]:t),isSecondary:r||i}}function mJ(e,t){const n=e.replace(/^['"]|['"]$/g,"").toLowerCase(),r=parseInt(t),i=isNaN(r)?"normal":r;return(JA[n]||{})[i]||hJ[n]}function EM(e,t){const n="".concat(JX).concat(t.replace(":","-"));return new Promise((r,i)=>{if(e.getAttribute(n)!==null)return r();const o=jd(e.children).filter(g=>g.getAttribute(zA)===t)[0],l=jl.getComputedStyle(e,t),f=l.getPropertyValue("font-family"),u=f.match(iQ),h=l.getPropertyValue("font-weight"),m=l.getPropertyValue("content");if(o&&!u)return e.removeChild(o),r();if(u&&m!=="none"&&m!==""){const g=l.getPropertyValue("content");let _=mJ(f,h);const{value:x,isSecondary:b}=pJ(g),S=u[0].startsWith("FontAwesome");let C=AT(_,x),A=C;if(S){const O=EQ(x);O.iconName&&O.prefix&&(C=O.iconName,_=O.prefix)}if(C&&!b&&(!o||o.getAttribute(bT)!==_||o.getAttribute(wT)!==A)){e.setAttribute(n,A),o&&e.removeChild(o);const O=nJ(),{extra:P}=O;P.attributes[zA]=t,ZA(C,_).then(j=>{const R=ET(Ke(Ke({},O),{},{icons:{main:j,mask:h$()},prefix:_,iconName:A,extra:P,watchable:!0})),U=pn.createElementNS("http://www.w3.org/2000/svg","svg");t==="::before"?e.insertBefore(U,e.firstChild):e.appendChild(U),U.outerHTML=R.map(V=>Xm(V)).join(`
|
||
`),e.removeAttribute(n),r()}).catch(i)}else r()}else r()})}function gJ(e){return Promise.all([EM(e,"::before"),EM(e,"::after")])}function vJ(e){return e.parentNode!==document.head&&!~tQ.indexOf(e.tagName.toUpperCase())&&!e.getAttribute(zA)&&(!e.parentNode||e.parentNode.tagName!=="svg")}function OM(e){if(cs)return new Promise((t,n)=>{const r=jd(e.querySelectorAll("*")).filter(vJ).map(gJ),i=OT.begin("searchPseudoElements");y$(),Promise.all(r).then(()=>{i(),QA(),t()}).catch(()=>{i(),QA(),n()})})}var yJ={hooks(){return{mutationObserverCallbacks(e){return e.pseudoElementsCallback=OM,e}}},provides(e){e.pseudoElements2svg=function(t){const{node:n=pn}=t;ut.searchPseudoElements&&OM(n)}}};let TM=!1;var bJ={mixout(){return{dom:{unwatch(){y$(),TM=!0}}}},hooks(){return{bootstrap(){_M(WA("mutationObserverCallbacks",{}))},noAuto(){QQ()},watch(e){const{observeMutationsRoot:t}=e;TM?QA():_M(WA("mutationObserverCallbacks",{observeMutationsRoot:t}))}}}};const jM=e=>{let t={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return e.toLowerCase().split(" ").reduce((n,r)=>{const i=r.toLowerCase().split("-"),a=i[0];let o=i.slice(1).join("-");if(a&&o==="h")return n.flipX=!0,n;if(a&&o==="v")return n.flipY=!0,n;if(o=parseFloat(o),isNaN(o))return n;switch(a){case"grow":n.size=n.size+o;break;case"shrink":n.size=n.size-o;break;case"left":n.x=n.x-o;break;case"right":n.x=n.x+o;break;case"up":n.y=n.y-o;break;case"down":n.y=n.y+o;break;case"rotate":n.rotate=n.rotate+o;break}return n},t)};var wJ={mixout(){return{parse:{transform:e=>jM(e)}}},hooks(){return{parseNodeAttributes(e,t){const n=t.getAttribute("data-fa-transform");return n&&(e.transform=jM(n)),e}}},provides(e){e.generateAbstractTransformGrouping=function(t){let{main:n,transform:r,containerWidth:i,iconWidth:a}=t;const o={transform:"translate(".concat(i/2," 256)")},l="translate(".concat(r.x*32,", ").concat(r.y*32,") "),f="scale(".concat(r.size/16*(r.flipX?-1:1),", ").concat(r.size/16*(r.flipY?-1:1),") "),u="rotate(".concat(r.rotate," 0 0)"),h={transform:"".concat(l," ").concat(f," ").concat(u)},m={transform:"translate(".concat(a/2*-1," -256)")},g={outer:o,inner:h,path:m};return{tag:"g",attributes:Ke({},g.outer),children:[{tag:"g",attributes:Ke({},g.inner),children:[{tag:n.icon.tag,children:n.icon.children,attributes:Ke(Ke({},n.icon.attributes),g.path)}]}]}}}};const Q_={x:0,y:0,width:"100%",height:"100%"};function PM(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}function _J(e){return e.tag==="g"?e.children:[e]}var xJ={hooks(){return{parseNodeAttributes(e,t){const n=t.getAttribute("data-fa-mask"),r=n?Lb(n.split(" ").map(i=>i.trim())):h$();return r.prefix||(r.prefix=Pl()),e.mask=r,e.maskId=t.getAttribute("data-fa-mask-id"),e}}},provides(e){e.generateAbstractMask=function(t){let{children:n,attributes:r,main:i,mask:a,maskId:o,transform:l}=t;const{width:f,icon:u}=i,{width:h,icon:m}=a,g=pQ({transform:l,containerWidth:h,iconWidth:f}),_={tag:"rect",attributes:Ke(Ke({},Q_),{},{fill:"white"})},x=u.children?{children:u.children.map(PM)}:{},b={tag:"g",attributes:Ke({},g.inner),children:[PM(Ke({tag:u.tag,attributes:Ke(Ke({},u.attributes),g.path)},x))]},S={tag:"g",attributes:Ke({},g.outer),children:[b]},C="mask-".concat(o||Gp()),A="clip-".concat(o||Gp()),O={tag:"mask",attributes:Ke(Ke({},Q_),{},{id:C,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[_,S]},P={tag:"defs",children:[{tag:"clipPath",attributes:{id:A},children:_J(m)},O]};return n.push(P,{tag:"rect",attributes:Ke({fill:"currentColor","clip-path":"url(#".concat(A,")"),mask:"url(#".concat(C,")")},Q_)}),{children:n,attributes:r}}}},SJ={provides(e){let t=!1;jl.matchMedia&&(t=jl.matchMedia("(prefers-reduced-motion: reduce)").matches),e.missingIconAbstract=function(){const n=[],r={fill:"currentColor"},i={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};n.push({tag:"path",attributes:Ke(Ke({},r),{},{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})});const a=Ke(Ke({},i),{},{attributeName:"opacity"}),o={tag:"circle",attributes:Ke(Ke({},r),{},{cx:"256",cy:"364",r:"28"}),children:[]};return t||o.children.push({tag:"animate",attributes:Ke(Ke({},i),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:Ke(Ke({},a),{},{values:"1;0;1;1;0;1;"})}),n.push(o),n.push({tag:"path",attributes:Ke(Ke({},r),{},{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),children:t?[]:[{tag:"animate",attributes:Ke(Ke({},a),{},{values:"1;0;0;0;0;1;"})}]}),t||n.push({tag:"path",attributes:Ke(Ke({},r),{},{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),children:[{tag:"animate",attributes:Ke(Ke({},a),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:n}}}},CJ={hooks(){return{parseNodeAttributes(e,t){const n=t.getAttribute("data-fa-symbol"),r=n===null?!1:n===""?!0:n;return e.symbol=r,e}}}},AJ=[vQ,lJ,uJ,cJ,fJ,yJ,bJ,wJ,xJ,SJ,CJ];kQ(AJ,{mixoutsTo:ki});ki.noAuto;ki.config;ki.library;ki.dom;const eE=ki.parse;ki.findIconDefinition;ki.toHtml;const EJ=ki.icon;ki.layer;ki.text;ki.counter;var J_={exports:{}},ex,RM;function OJ(){if(RM)return ex;RM=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return ex=e,ex}var tx,MM;function TJ(){if(MM)return tx;MM=1;var e=OJ();function t(){}function n(){}return n.resetWarningCache=t,tx=function(){function r(o,l,f,u,h,m){if(m!==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 a={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 a.PropTypes=a,a},tx}var NM;function jJ(){return NM||(NM=1,J_.exports=TJ()()),J_.exports}var PJ=jJ();const et=zt(PJ);function LM(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 Ka(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?LM(Object(n),!0).forEach(function(r){xf(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):LM(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vy(e){"@babel/helpers - typeof";return Vy=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},Vy(e)}function xf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function RJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function MJ(e,t){if(e==null)return{};var n=RJ(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function tE(e){return NJ(e)||LJ(e)||kJ(e)||DJ()}function NJ(e){if(Array.isArray(e))return nE(e)}function LJ(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function kJ(e,t){if(e){if(typeof e=="string")return nE(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 nE(e,t)}}function nE(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 DJ(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function IJ(e){var t,n=e.beat,r=e.fade,i=e.beatFade,a=e.bounce,o=e.shake,l=e.flash,f=e.spin,u=e.spinPulse,h=e.spinReverse,m=e.pulse,g=e.fixedWidth,_=e.inverse,x=e.border,b=e.listItem,S=e.flip,C=e.size,A=e.rotation,O=e.pull,P=(t={"fa-beat":n,"fa-fade":r,"fa-beat-fade":i,"fa-bounce":a,"fa-shake":o,"fa-flash":l,"fa-spin":f,"fa-spin-reverse":h,"fa-spin-pulse":u,"fa-pulse":m,"fa-fw":g,"fa-inverse":_,"fa-border":x,"fa-li":b,"fa-flip":S===!0,"fa-flip-horizontal":S==="horizontal"||S==="both","fa-flip-vertical":S==="vertical"||S==="both"},xf(t,"fa-".concat(C),typeof C<"u"&&C!==null),xf(t,"fa-rotate-".concat(A),typeof A<"u"&&A!==null&&A!==0),xf(t,"fa-pull-".concat(O),typeof O<"u"&&O!==null),xf(t,"fa-swap-opacity",e.swapOpacity),t);return Object.keys(P).map(function(j){return P[j]?j:null}).filter(function(j){return j})}function $J(e){return e=e-0,e===e}function w$(e){return $J(e)?e:(e=e.replace(/[\-_\s]+(.)?/g,function(t,n){return n?n.toUpperCase():""}),e.substr(0,1).toLowerCase()+e.substr(1))}var BJ=["style"];function UJ(e){return e.charAt(0).toUpperCase()+e.slice(1)}function zJ(e){return e.split(";").map(function(t){return t.trim()}).filter(function(t){return t}).reduce(function(t,n){var r=n.indexOf(":"),i=w$(n.slice(0,r)),a=n.slice(r+1).trim();return i.startsWith("webkit")?t[UJ(i)]=a:t[i]=a,t},{})}function _$(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(typeof t=="string")return t;var r=(t.children||[]).map(function(f){return _$(e,f)}),i=Object.keys(t.attributes||{}).reduce(function(f,u){var h=t.attributes[u];switch(u){case"class":f.attrs.className=h,delete t.attributes.class;break;case"style":f.attrs.style=zJ(h);break;default:u.indexOf("aria-")===0||u.indexOf("data-")===0?f.attrs[u.toLowerCase()]=h:f.attrs[w$(u)]=h}return f},{attrs:{}}),a=n.style,o=a===void 0?{}:a,l=MJ(n,BJ);return i.attrs.style=Ka(Ka({},i.attrs.style),o),e.apply(void 0,[t.tag,Ka(Ka({},i.attrs),l)].concat(tE(r)))}var x$=!1;try{x$=!0}catch{}function FJ(){if(!x$&&console&&typeof console.error=="function"){var e;(e=console).error.apply(e,arguments)}}function kM(e){if(e&&Vy(e)==="object"&&e.prefix&&e.iconName&&e.icon)return e;if(eE.icon)return eE.icon(e);if(e===null)return null;if(e&&Vy(e)==="object"&&e.prefix&&e.iconName)return e;if(Array.isArray(e)&&e.length===2)return{prefix:e[0],iconName:e[1]};if(typeof e=="string")return{prefix:"fas",iconName:e}}function nx(e,t){return Array.isArray(t)&&t.length>0||!Array.isArray(t)&&t?xf({},e,t):{}}var DM={border:!1,className:"",mask:null,maskId:null,fixedWidth:!1,inverse:!1,flip:!1,icon:null,listItem:!1,pull:null,pulse:!1,rotation:null,size:null,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:null,transform:null,swapOpacity:!1},Ye=pe.forwardRef(function(e,t){var n=Ka(Ka({},DM),e),r=n.icon,i=n.mask,a=n.symbol,o=n.className,l=n.title,f=n.titleId,u=n.maskId,h=kM(r),m=nx("classes",[].concat(tE(IJ(n)),tE((o||"").split(" ")))),g=nx("transform",typeof n.transform=="string"?eE.transform(n.transform):n.transform),_=nx("mask",kM(i)),x=EJ(h,Ka(Ka(Ka(Ka({},m),g),_),{},{symbol:a,title:l,titleId:f,maskId:u}));if(!x)return FJ("Could not find icon",h),null;var b=x.abstract,S={ref:t};return Object.keys(n).forEach(function(C){DM.hasOwnProperty(C)||(S[C]=n[C])}),qJ(b[0],S)});Ye.displayName="FontAwesomeIcon";Ye.propTypes={beat:et.bool,border:et.bool,beatFade:et.bool,bounce:et.bool,className:et.string,fade:et.bool,flash:et.bool,mask:et.oneOfType([et.object,et.array,et.string]),maskId:et.string,fixedWidth:et.bool,inverse:et.bool,flip:et.oneOf([!0,!1,"horizontal","vertical","both"]),icon:et.oneOfType([et.object,et.array,et.string]),listItem:et.bool,pull:et.oneOf(["right","left"]),pulse:et.bool,rotation:et.oneOf([0,90,180,270]),shake:et.bool,size:et.oneOf(["2xs","xs","sm","lg","xl","2xl","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"]),spin:et.bool,spinPulse:et.bool,spinReverse:et.bool,symbol:et.oneOfType([et.bool,et.string]),title:et.string,titleId:et.string,transform:et.oneOfType([et.string,et.object]),swapOpacity:et.bool};var qJ=_$.bind(null,pe.createElement);function S$(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=S$(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function be(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=S$(e))&&(r&&(r+=" "),r+=t);return r}var fc=Y7();function VJ(e,{elementsSelector:t,focusFirstItem:n=!1,vertical:r=!0,horizontal:i=!0}){const a=M.useMemo(()=>{const f=[];return r&&f.push("ArrowDown"),i&&f.push("ArrowRight"),f},[i,r]),o=M.useMemo(()=>{const f=[];return r&&f.push("ArrowUp"),i&&f.push("ArrowLeft"),f},[i,r]),l=M.useMemo(()=>[...a,...o],[a,o]);M.useEffect(()=>{const f=e.current;if(!f)return()=>{};const u=new AbortController,h=()=>[...f.querySelectorAll(t)],m=h(),g=Math.max(m.findIndex(_=>_.dataset.selected==="true"),0);return m.forEach((_,x)=>{_.tabIndex=x===g?0:-1,n&&x===g&&_.focus()}),f.addEventListener("keydown",_=>{if(!l.includes(_.key))return;_.preventDefault();const x=h(),b=x.findIndex(C=>C.tabIndex===0),S=a.includes(_.key)?x[b+1]??x[0]:x[b-1]??x[x.length-1];x.forEach(C=>{C.tabIndex=-1}),S.tabIndex=0,S.focus()},{signal:u.signal}),()=>u.abort()},[l,e,t,n,a])}const HJ=128;function C$(e){const[t,n,r]=(e.match(/../g)??[]).map(i=>parseInt(i,16)||0);return Math.round(Math.sqrt(.299*t**2+.587*n**2+.114*r**2))>=HJ}function A$(e,t=globalThis.setTimeout,n=globalThis.clearTimeout){const r=M.useRef(null),i=M.useCallback(()=>{r.current&&n(r.current)},[n]),a=M.useCallback((o,l)=>{i(),r.current=t(()=>{o(),r.current=null},l??e)},[i,e,t]);return M.useEffect(()=>i,[i]),M.useMemo(()=>({setTimeout:a,clearCurrentTimeout:i}),[i,a])}const GJ=2e3,jT=(e={},t,n=globalThis.setTimeout,r=globalThis.clearTimeout)=>{const{initialValue:i=!1,delay:a=GJ}=typeof e=="boolean"?{initialValue:e,delay:t}:e,{setTimeout:o}=A$(a,n,r),[l,f]=M.useState(i),u=M.useRef(i),h=M.useCallback(()=>{f(!u.current),o(()=>f(u.current))},[o]);return[l,h]};function wn(e=!1,t=!1){const[n,r]=M.useState(e),i=M.useCallback(()=>r(l=>!l),[]),a=M.useCallback(()=>r(!0),[]),o=M.useCallback(()=>r(!1),[]);return t?{flag:n,toggle:i,setToTrue:a,setToFalse:o}:[n,i,a,o]}function Db(e,t,n){if(!e||typeof e=="string")return Db({currentField:e,newField:t,currentOrderDir:n});const r=e;if(r.currentField!==r.newField)return"ASC";const i={ASC:"DESC",DESC:void 0};return r.currentOrderDir?i[r.currentOrderDir]:"ASC"}function E$(e,t,n){if(!e||typeof e=="string")return E$({currentField:e,newField:t,currentOrderDir:n});const r=e,i=Db(r);return{field:i?r.newField:void 0,dir:i}}const O$=(e,{field:t,dir:n})=>!t||!n?e:e.sort((r,i)=>{const a=n==="ASC"?1:-1,o=n==="ASC"?-1:1;return r[t]>i[t]?a:o}),WJ=e=>e.dir?`${e.field}-${e.dir}`:void 0,YJ=e=>{const[t,n]=e.split("-");return{field:t,dir:n}},KJ=()=>{const e=po();return M.useCallback(()=>e(-1),[e])},T$=e=>{const t=new URLSearchParams(e),n={};return t.forEach((r,i)=>{if(i.endsWith("[]")){const a=i.slice(0,-2);n[a]??(n[a]=[]),n[a].push(r)}else n[i]=r}),n},PT=e=>{const t=new URLSearchParams;for(const[n,r]of Object.entries(e))r!==void 0&&(Array.isArray(r)?r.forEach(i=>t.append(`${n}[]`,`${i}`)):t.append(n,`${r}`));return t.toString()},Pd=()=>{const{search:e}=Sr();return M.useMemo(()=>T$(e),[e])},Yp="#4696e5",ZJ="rgba(70, 150, 229, 0.4)",rE="#f77f28",XJ="rgba(247, 127, 40, 0.4)",QJ="white",JJ="#161b22",eee=e=>{var t;return(t=document.querySelector("html"))==null?void 0:t.setAttribute("data-theme",e)},Qm=()=>{var e;return((e=document.querySelector("html"))==null?void 0:e.getAttribute("data-theme"))==="dark"},RT=(e=window.matchMedia.bind(window))=>e("(prefers-color-scheme: dark)").matches?"dark":"light";function Ib(){return typeof window<"u"}function Rd(e){return j$(e)?(e.nodeName||"").toLowerCase():"#document"}function Ci(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function fs(e){var t;return(t=(j$(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function j$(e){return Ib()?e instanceof Node||e instanceof Ci(e).Node:!1}function wr(e){return Ib()?e instanceof Element||e instanceof Ci(e).Element:!1}function ji(e){return Ib()?e instanceof HTMLElement||e instanceof Ci(e).HTMLElement:!1}function iE(e){return!Ib()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ci(e).ShadowRoot}function Jm(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Aa(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function tee(e){return["table","td","th"].includes(Rd(e))}function $b(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function MT(e){const t=NT(),n=wr(e)?Aa(e):e;return["transform","translate","scale","rotate","perspective"].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)||["transform","translate","scale","rotate","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function nee(e){let t=Ml(e);for(;ji(t)&&!zf(t);){if(MT(t))return t;if($b(t))return null;t=Ml(t)}return null}function NT(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function zf(e){return["html","body","#document"].includes(Rd(e))}function Aa(e){return Ci(e).getComputedStyle(e)}function Bb(e){return wr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ml(e){if(Rd(e)==="html")return e;const t=e.assignedSlot||e.parentNode||iE(e)&&e.host||fs(e);return iE(t)?t.host:t}function P$(e){const t=Ml(e);return zf(t)?e.ownerDocument?e.ownerDocument.body:e.body:ji(t)&&Jm(t)?t:P$(t)}function R$(e,t,n){var r;t===void 0&&(t=[]);const i=P$(e),a=i===((r=e.ownerDocument)==null?void 0:r.body),o=Ci(i);return a?(aE(o),t.concat(o,o.visualViewport||[],Jm(i)?i:[],[])):t.concat(i,R$(i,[]))}function aE(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const ree=["top","right","bottom","left"],IM=["start","end"],$M=ree.reduce((e,t)=>e.concat(t,t+"-"+IM[0],t+"-"+IM[1]),[]),Kp=Math.min,Pf=Math.max,Hy=Math.round,to=e=>({x:e,y:e}),iee={left:"right",right:"left",bottom:"top",top:"bottom"},aee={start:"end",end:"start"};function oee(e,t,n){return Pf(e,Kp(t,n))}function eg(e,t){return typeof e=="function"?e(t):e}function Nl(e){return e.split("-")[0]}function no(e){return e.split("-")[1]}function see(e){return e==="x"?"y":"x"}function LT(e){return e==="y"?"height":"width"}function Uu(e){return["top","bottom"].includes(Nl(e))?"y":"x"}function kT(e){return see(Uu(e))}function M$(e,t,n){n===void 0&&(n=!1);const r=no(e),i=kT(e),a=LT(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(o=Wy(o)),[o,Wy(o)]}function lee(e){const t=Wy(e);return[Gy(e),t,Gy(t)]}function Gy(e){return e.replace(/start|end/g,t=>aee[t])}function uee(e,t,n){const r=["left","right"],i=["right","left"],a=["top","bottom"],o=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?a:o;default:return[]}}function cee(e,t,n,r){const i=no(e);let a=uee(Nl(e),n==="start",r);return i&&(a=a.map(o=>o+"-"+i),t&&(a=a.concat(a.map(Gy)))),a}function Wy(e){return e.replace(/left|right|bottom|top/g,t=>iee[t])}function fee(e){return{top:0,right:0,bottom:0,left:0,...e}}function N$(e){return typeof e!="number"?fee(e):{top:e,right:e,bottom:e,left:e}}function Yy(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}}const dee="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function hee(e,t){if(!e||!t)return!1;const n=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&iE(n)){let r=t;for(;r;){if(e===r)return!0;r=r.parentNode||r.host}}return!1}function Yv(e){return(e==null?void 0:e.ownerDocument)||document}function pee(e){return ji(e)&&e.matches(dee)}function Zp(e,t){const n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}var mee=typeof document<"u",gee=function(){},Ll=mee?M.useLayoutEffect:gee;const vee={..._b};function yl(e){const t=M.useRef(e);return Ll(()=>{t.current=e}),t}const yee=vee.useInsertionEffect,bee=yee||(e=>e());function vp(e){const t=M.useRef(()=>{});return bee(()=>{t.current=e}),M.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.current==null?void 0:t.current(...r)},[])}function BM(e,t,n){let{reference:r,floating:i}=e;const a=Uu(t),o=kT(t),l=LT(o),f=Nl(t),u=a==="y",h=r.x+r.width/2-i.width/2,m=r.y+r.height/2-i.height/2,g=r[l]/2-i[l]/2;let _;switch(f){case"top":_={x:h,y:r.y-i.height};break;case"bottom":_={x:h,y:r.y+r.height};break;case"right":_={x:r.x+r.width,y:m};break;case"left":_={x:r.x-i.width,y:m};break;default:_={x:r.x,y:r.y}}switch(no(t)){case"start":_[o]-=g*(n&&u?-1:1);break;case"end":_[o]+=g*(n&&u?-1:1);break}return _}const wee=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:a=[],platform:o}=n,l=a.filter(Boolean),f=await(o.isRTL==null?void 0:o.isRTL(t));let u=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:h,y:m}=BM(u,r,f),g=r,_={},x=0;for(let b=0;b<l.length;b++){const{name:S,fn:C}=l[b],{x:A,y:O,data:P,reset:j}=await C({x:h,y:m,initialPlacement:r,placement:g,strategy:i,middlewareData:_,rects:u,platform:o,elements:{reference:e,floating:t}});h=A??h,m=O??m,_={..._,[S]:{..._[S],...P}},j&&x<=50&&(x++,typeof j=="object"&&(j.placement&&(g=j.placement),j.rects&&(u=j.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):j.rects),{x:h,y:m}=BM(u,g,f)),b=-1)}return{x:h,y:m,placement:g,strategy:i,middlewareData:_}};async function L$(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:a,rects:o,elements:l,strategy:f}=e,{boundary:u="clippingAncestors",rootBoundary:h="viewport",elementContext:m="floating",altBoundary:g=!1,padding:_=0}=eg(t,e),x=N$(_),S=l[g?m==="floating"?"reference":"floating":m],C=Yy(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(S)))==null||n?S:S.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(l.floating)),boundary:u,rootBoundary:h,strategy:f})),A=m==="floating"?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,O=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l.floating)),P=await(a.isElement==null?void 0:a.isElement(O))?await(a.getScale==null?void 0:a.getScale(O))||{x:1,y:1}:{x:1,y:1},j=Yy(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:A,offsetParent:O,strategy:f}):A);return{top:(C.top-j.top+x.top)/P.y,bottom:(j.bottom-C.bottom+x.bottom)/P.y,left:(C.left-j.left+x.left)/P.x,right:(j.right-C.right+x.right)/P.x}}const _ee=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:a,platform:o,elements:l,middlewareData:f}=t,{element:u,padding:h=0}=eg(e,t)||{};if(u==null)return{};const m=N$(h),g={x:n,y:r},_=kT(i),x=LT(_),b=await o.getDimensions(u),S=_==="y",C=S?"top":"left",A=S?"bottom":"right",O=S?"clientHeight":"clientWidth",P=a.reference[x]+a.reference[_]-g[_]-a.floating[x],j=g[_]-a.reference[_],R=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u));let U=R?R[O]:0;(!U||!await(o.isElement==null?void 0:o.isElement(R)))&&(U=l.floating[O]||a.floating[x]);const V=P/2-j/2,Y=U/2-b[x]/2-1,K=Kp(m[C],Y),W=Kp(m[A],Y),ee=K,ie=U-b[x]-W,X=U/2-b[x]/2+V,ne=oee(ee,X,ie),H=!f.arrow&&no(i)!=null&&X!==ne&&a.reference[x]/2-(X<ee?K:W)-b[x]/2<0,I=H?X<ee?X-ee:X-ie:0;return{[_]:g[_]+I,data:{[_]:ne,centerOffset:X-ne-I,...H&&{alignmentOffset:I}},reset:H}}});function xee(e,t,n){return(e?[...n.filter(i=>no(i)===e),...n.filter(i=>no(i)!==e)]:n.filter(i=>Nl(i)===i)).filter(i=>e?no(i)===e||(t?Gy(i)!==i:!1):!0)}const See=function(e){return e===void 0&&(e={}),{name:"autoPlacement",options:e,async fn(t){var n,r,i;const{rects:a,middlewareData:o,placement:l,platform:f,elements:u}=t,{crossAxis:h=!1,alignment:m,allowedPlacements:g=$M,autoAlignment:_=!0,...x}=eg(e,t),b=m!==void 0||g===$M?xee(m||null,_,g):g,S=await L$(t,x),C=((n=o.autoPlacement)==null?void 0:n.index)||0,A=b[C];if(A==null)return{};const O=M$(A,a,await(f.isRTL==null?void 0:f.isRTL(u.floating)));if(l!==A)return{reset:{placement:b[0]}};const P=[S[Nl(A)],S[O[0]],S[O[1]]],j=[...((r=o.autoPlacement)==null?void 0:r.overflows)||[],{placement:A,overflows:P}],R=b[C+1];if(R)return{data:{index:C+1,overflows:j},reset:{placement:R}};const U=j.map(K=>{const W=no(K.placement);return[K.placement,W&&h?K.overflows.slice(0,2).reduce((ee,ie)=>ee+ie,0):K.overflows[0],K.overflows]}).sort((K,W)=>K[1]-W[1]),Y=((i=U.filter(K=>K[2].slice(0,no(K[0])?2:3).every(W=>W<=0))[0])==null?void 0:i[0])||U[0][0];return Y!==l?{data:{index:C+1,overflows:j},reset:{placement:Y}}:{}}}},Cee=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:a,rects:o,initialPlacement:l,platform:f,elements:u}=t,{mainAxis:h=!0,crossAxis:m=!0,fallbackPlacements:g,fallbackStrategy:_="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:b=!0,...S}=eg(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const C=Nl(i),A=Uu(l),O=Nl(l)===l,P=await(f.isRTL==null?void 0:f.isRTL(u.floating)),j=g||(O||!b?[Wy(l)]:lee(l)),R=x!=="none";!g&&R&&j.push(...cee(l,b,x,P));const U=[l,...j],V=await L$(t,S),Y=[];let K=((r=a.flip)==null?void 0:r.overflows)||[];if(h&&Y.push(V[C]),m){const X=M$(i,o,P);Y.push(V[X[0]],V[X[1]])}if(K=[...K,{placement:i,overflows:Y}],!Y.every(X=>X<=0)){var W,ee;const X=(((W=a.flip)==null?void 0:W.index)||0)+1,ne=U[X];if(ne&&(!(m==="alignment"?A!==Uu(ne):!1)||K.every(D=>D.overflows[0]>0&&Uu(D.placement)===A)))return{data:{index:X,overflows:K},reset:{placement:ne}};let H=(ee=K.filter(I=>I.overflows[0]<=0).sort((I,D)=>I.overflows[1]-D.overflows[1])[0])==null?void 0:ee.placement;if(!H)switch(_){case"bestFit":{var ie;const I=(ie=K.filter(D=>{if(R){const z=Uu(D.placement);return z===A||z==="y"}return!0}).map(D=>[D.placement,D.overflows.filter(z=>z>0).reduce((z,N)=>z+N,0)]).sort((D,z)=>D[1]-z[1])[0])==null?void 0:ie[0];I&&(H=I);break}case"initialPlacement":H=l;break}if(i!==H)return{reset:{placement:H}}}return{}}}};async function Aee(e,t){const{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Nl(n),l=no(n),f=Uu(n)==="y",u=["left","top"].includes(o)?-1:1,h=a&&f?-1:1,m=eg(t,e);let{mainAxis:g,crossAxis:_,alignmentAxis:x}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return l&&typeof x=="number"&&(_=l==="end"?x*-1:x),f?{x:_*h,y:g*u}:{x:g*u,y:_*h}}const Eee=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:a,placement:o,middlewareData:l}=t,f=await Aee(t,e);return o===((n=l.offset)==null?void 0:n.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:i+f.x,y:a+f.y,data:{...f,placement:o}}}}};function k$(e){const t=Aa(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=ji(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,l=Hy(n)!==a||Hy(r)!==o;return l&&(n=a,r=o),{width:n,height:r,$:l}}function D$(e){return wr(e)?e:e.contextElement}function Rf(e){const t=D$(e);if(!ji(t))return to(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:a}=k$(t);let o=(a?Hy(n.width):n.width)/r,l=(a?Hy(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!l||!Number.isFinite(l))&&(l=1),{x:o,y:l}}const Oee=to(0);function I$(e){const t=Ci(e);return!NT()||!t.visualViewport?Oee:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Tee(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ci(e)?!1:t}function Xp(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),a=D$(e);let o=to(1);t&&(r?wr(r)&&(o=Rf(r)):o=Rf(e));const l=Tee(a,n,r)?I$(a):to(0);let f=(i.left+l.x)/o.x,u=(i.top+l.y)/o.y,h=i.width/o.x,m=i.height/o.y;if(a){const g=Ci(a),_=r&&wr(r)?Ci(r):r;let x=g,b=aE(x);for(;b&&r&&_!==x;){const S=Rf(b),C=b.getBoundingClientRect(),A=Aa(b),O=C.left+(b.clientLeft+parseFloat(A.paddingLeft))*S.x,P=C.top+(b.clientTop+parseFloat(A.paddingTop))*S.y;f*=S.x,u*=S.y,h*=S.x,m*=S.y,f+=O,u+=P,x=Ci(b),b=aE(x)}}return Yy({width:h,height:m,x:f,y:u})}function DT(e,t){const n=Bb(e).scrollLeft;return t?t.left+n:Xp(fs(e)).left+n}function $$(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),i=r.left+t.scrollLeft-(n?0:DT(e,r)),a=r.top+t.scrollTop;return{x:i,y:a}}function jee(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const a=i==="fixed",o=fs(r),l=t?$b(t.floating):!1;if(r===o||l&&a)return n;let f={scrollLeft:0,scrollTop:0},u=to(1);const h=to(0),m=ji(r);if((m||!m&&!a)&&((Rd(r)!=="body"||Jm(o))&&(f=Bb(r)),ji(r))){const _=Xp(r);u=Rf(r),h.x=_.x+r.clientLeft,h.y=_.y+r.clientTop}const g=o&&!m&&!a?$$(o,f,!0):to(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-f.scrollLeft*u.x+h.x+g.x,y:n.y*u.y-f.scrollTop*u.y+h.y+g.y}}function Pee(e){return Array.from(e.getClientRects())}function Ree(e){const t=fs(e),n=Bb(e),r=e.ownerDocument.body,i=Pf(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Pf(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+DT(e);const l=-n.scrollTop;return Aa(r).direction==="rtl"&&(o+=Pf(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:l}}function Mee(e,t){const n=Ci(e),r=fs(e),i=n.visualViewport;let a=r.clientWidth,o=r.clientHeight,l=0,f=0;if(i){a=i.width,o=i.height;const u=NT();(!u||u&&t==="fixed")&&(l=i.offsetLeft,f=i.offsetTop)}return{width:a,height:o,x:l,y:f}}function Nee(e,t){const n=Xp(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=ji(e)?Rf(e):to(1),o=e.clientWidth*a.x,l=e.clientHeight*a.y,f=i*a.x,u=r*a.y;return{width:o,height:l,x:f,y:u}}function UM(e,t,n){let r;if(t==="viewport")r=Mee(e,n);else if(t==="document")r=Ree(fs(e));else if(wr(t))r=Nee(t,n);else{const i=I$(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Yy(r)}function B$(e,t){const n=Ml(e);return n===t||!wr(n)||zf(n)?!1:Aa(n).position==="fixed"||B$(n,t)}function Lee(e,t){const n=t.get(e);if(n)return n;let r=R$(e,[]).filter(l=>wr(l)&&Rd(l)!=="body"),i=null;const a=Aa(e).position==="fixed";let o=a?Ml(e):e;for(;wr(o)&&!zf(o);){const l=Aa(o),f=MT(o);!f&&l.position==="fixed"&&(i=null),(a?!f&&!i:!f&&l.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||Jm(o)&&!f&&B$(e,o))?r=r.filter(h=>h!==o):i=l,o=Ml(o)}return t.set(e,r),r}function kee(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[...n==="clippingAncestors"?$b(t)?[]:Lee(t,this._c):[].concat(n),r],l=o[0],f=o.reduce((u,h)=>{const m=UM(t,h,i);return u.top=Pf(m.top,u.top),u.right=Kp(m.right,u.right),u.bottom=Kp(m.bottom,u.bottom),u.left=Pf(m.left,u.left),u},UM(t,l,i));return{width:f.right-f.left,height:f.bottom-f.top,x:f.left,y:f.top}}function Dee(e){const{width:t,height:n}=k$(e);return{width:t,height:n}}function Iee(e,t,n){const r=ji(t),i=fs(t),a=n==="fixed",o=Xp(e,!0,a,t);let l={scrollLeft:0,scrollTop:0};const f=to(0);function u(){f.x=DT(i)}if(r||!r&&!a)if((Rd(t)!=="body"||Jm(i))&&(l=Bb(t)),r){const _=Xp(t,!0,a,t);f.x=_.x+t.clientLeft,f.y=_.y+t.clientTop}else i&&u();a&&!r&&i&&u();const h=i&&!r&&!a?$$(i,l):to(0),m=o.left+l.scrollLeft-f.x-h.x,g=o.top+l.scrollTop-f.y-h.y;return{x:m,y:g,width:o.width,height:o.height}}function rx(e){return Aa(e).position==="static"}function zM(e,t){if(!ji(e)||Aa(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return fs(e)===n&&(n=n.ownerDocument.body),n}function U$(e,t){const n=Ci(e);if($b(e))return n;if(!ji(e)){let i=Ml(e);for(;i&&!zf(i);){if(wr(i)&&!rx(i))return i;i=Ml(i)}return n}let r=zM(e,t);for(;r&&tee(r)&&rx(r);)r=zM(r,t);return r&&zf(r)&&rx(r)&&!MT(r)?n:r||nee(e)||n}const $ee=async function(e){const t=this.getOffsetParent||U$,n=this.getDimensions,r=await n(e.floating);return{reference:Iee(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Bee(e){return Aa(e).direction==="rtl"}const Uee={convertOffsetParentRelativeRectToViewportRelativeRect:jee,getDocumentElement:fs,getClippingRect:kee,getOffsetParent:U$,getElementRects:$ee,getClientRects:Pee,getDimensions:Dee,getScale:Rf,isElement:wr,isRTL:Bee},zee=Eee,Fee=See,qee=Cee,FM=_ee,Vee=(e,t,n)=>{const r=new Map,i={platform:Uee,...n},a={...i.platform,_c:r};return wee(e,t,{...i,platform:a})};var Hee=typeof document<"u",Gee=function(){},jy=Hee?M.useLayoutEffect:Gee;function Ky(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(!Ky(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 a=i[r];if(!(a==="_owner"&&e.$$typeof)&&!Ky(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function z$(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function qM(e,t){const n=z$(e);return Math.round(t*n)/n}function ix(e){const t=M.useRef(e);return jy(()=>{t.current=e}),t}function Wee(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:l=!0,whileElementsMounted:f,open:u}=e,[h,m]=M.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[g,_]=M.useState(r);Ky(g,r)||_(r);const[x,b]=M.useState(null),[S,C]=M.useState(null),A=M.useCallback(D=>{D!==R.current&&(R.current=D,b(D))},[]),O=M.useCallback(D=>{D!==U.current&&(U.current=D,C(D))},[]),P=a||x,j=o||S,R=M.useRef(null),U=M.useRef(null),V=M.useRef(h),Y=f!=null,K=ix(f),W=ix(i),ee=ix(u),ie=M.useCallback(()=>{if(!R.current||!U.current)return;const D={placement:t,strategy:n,middleware:g};W.current&&(D.platform=W.current),Vee(R.current,U.current,D).then(z=>{const N={...z,isPositioned:ee.current!==!1};X.current&&!Ky(V.current,N)&&(V.current=N,fc.flushSync(()=>{m(N)}))})},[g,t,n,W,ee]);jy(()=>{u===!1&&V.current.isPositioned&&(V.current.isPositioned=!1,m(D=>({...D,isPositioned:!1})))},[u]);const X=M.useRef(!1);jy(()=>(X.current=!0,()=>{X.current=!1}),[]),jy(()=>{if(P&&(R.current=P),j&&(U.current=j),P&&j){if(K.current)return K.current(P,j,ie);ie()}},[P,j,ie,K,Y]);const ne=M.useMemo(()=>({reference:R,floating:U,setReference:A,setFloating:O}),[A,O]),H=M.useMemo(()=>({reference:P,floating:j}),[P,j]),I=M.useMemo(()=>{const D={position:n,left:0,top:0};if(!H.floating)return D;const z=qM(H.floating,h.x),N=qM(H.floating,h.y);return l?{...D,transform:"translate("+z+"px, "+N+"px)",...z$(H.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:z,top:N}},[n,l,H.floating,h.x,h.y]);return M.useMemo(()=>({...h,update:ie,refs:ne,elements:H,floatingStyles:I}),[h,ie,ne,H,I])}const Yee=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?FM({element:r.current,padding:i}).fn(n):{}:r?FM({element:r,padding:i}).fn(n):{}}}},Kee=(e,t)=>({...zee(e),options:[e,t]}),Zee=(e,t)=>({...qee(e),options:[e,t]}),Xee=(e,t)=>({...Fee(e),options:[e,t]}),Qee=(e,t)=>({...Yee(e),options:[e,t]}),Jee="data-floating-ui-focusable",VM="active",HM="selected",ete={..._b};let GM=!1,tte=0;const WM=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+tte++;function nte(){const[e,t]=M.useState(()=>GM?WM():void 0);return Ll(()=>{e==null&&t(WM())},[]),M.useEffect(()=>{GM=!0},[]),e}const rte=ete.useId,ite=rte||nte;function ate(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(i=>i(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){var r;(r=e.get(t))==null||r.delete(n)}}}const ote=M.createContext(null),ste=M.createContext(null),F$=()=>{var e;return((e=M.useContext(ote))==null?void 0:e.id)||null},q$=()=>M.useContext(ste);function lte(e){return"data-floating-ui-"+e}function ha(e){e.current!==-1&&(clearTimeout(e.current),e.current=-1)}const YM=lte("safe-polygon");function ax(e,t,n){if(n&&!Zp(n))return 0;if(typeof e=="number")return e;if(typeof e=="function"){const r=e();return typeof r=="number"?r:r==null?void 0:r[t]}return e==null?void 0:e[t]}function ox(e){return typeof e=="function"?e():e}function ute(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,dataRef:i,events:a,elements:o}=e,{enabled:l=!0,delay:f=0,handleClose:u=null,mouseOnly:h=!1,restMs:m=0,move:g=!0}=t,_=q$(),x=F$(),b=yl(u),S=yl(f),C=yl(n),A=yl(m),O=M.useRef(),P=M.useRef(-1),j=M.useRef(),R=M.useRef(-1),U=M.useRef(!0),V=M.useRef(!1),Y=M.useRef(()=>{}),K=M.useRef(!1),W=vp(()=>{var I;const D=(I=i.current.openEvent)==null?void 0:I.type;return(D==null?void 0:D.includes("mouse"))&&D!=="mousedown"});M.useEffect(()=>{if(!l)return;function I(D){let{open:z}=D;z||(ha(P),ha(R),U.current=!0,K.current=!1)}return a.on("openchange",I),()=>{a.off("openchange",I)}},[l,a]),M.useEffect(()=>{if(!l||!b.current||!n)return;function I(z){W()&&r(!1,z,"hover")}const D=Yv(o.floating).documentElement;return D.addEventListener("mouseleave",I),()=>{D.removeEventListener("mouseleave",I)}},[o.floating,n,r,l,b,W]);const ee=M.useCallback(function(I,D,z){D===void 0&&(D=!0),z===void 0&&(z="hover");const N=ax(S.current,"close",O.current);N&&!j.current?(ha(P),P.current=window.setTimeout(()=>r(!1,I,z),N)):D&&(ha(P),r(!1,I,z))},[S,r]),ie=vp(()=>{Y.current(),j.current=void 0}),X=vp(()=>{if(V.current){const I=Yv(o.floating).body;I.style.pointerEvents="",I.removeAttribute(YM),V.current=!1}}),ne=vp(()=>i.current.openEvent?["click","mousedown"].includes(i.current.openEvent.type):!1);M.useEffect(()=>{if(!l)return;function I(Q){if(ha(P),U.current=!1,h&&!Zp(O.current)||ox(A.current)>0&&!ax(S.current,"open"))return;const G=ax(S.current,"open",O.current);G?P.current=window.setTimeout(()=>{C.current||r(!0,Q,"hover")},G):n||r(!0,Q,"hover")}function D(Q){if(ne()){X();return}Y.current();const G=Yv(o.floating);if(ha(R),K.current=!1,b.current&&i.current.floatingContext){n||ha(P),j.current=b.current({...i.current.floatingContext,tree:_,x:Q.clientX,y:Q.clientY,onClose(){X(),ie(),ne()||ee(Q,!0,"safe-polygon")}});const fe=j.current;G.addEventListener("mousemove",fe),Y.current=()=>{G.removeEventListener("mousemove",fe)};return}(O.current==="touch"?!hee(o.floating,Q.relatedTarget):!0)&&ee(Q)}function z(Q){ne()||i.current.floatingContext&&(b.current==null||b.current({...i.current.floatingContext,tree:_,x:Q.clientX,y:Q.clientY,onClose(){X(),ie(),ne()||ee(Q)}})(Q))}function N(){ha(P)}function B(Q){ne()||ee(Q,!1)}if(wr(o.domReference)){const Q=o.domReference,G=o.floating;return n&&Q.addEventListener("mouseleave",z),g&&Q.addEventListener("mousemove",I,{once:!0}),Q.addEventListener("mouseenter",I),Q.addEventListener("mouseleave",D),G&&(G.addEventListener("mouseleave",z),G.addEventListener("mouseenter",N),G.addEventListener("mouseleave",B)),()=>{n&&Q.removeEventListener("mouseleave",z),g&&Q.removeEventListener("mousemove",I),Q.removeEventListener("mouseenter",I),Q.removeEventListener("mouseleave",D),G&&(G.removeEventListener("mouseleave",z),G.removeEventListener("mouseenter",N),G.removeEventListener("mouseleave",B))}}},[o,l,e,h,g,ee,ie,X,r,n,C,_,S,b,i,ne,A]),Ll(()=>{var I;if(l&&n&&(I=b.current)!=null&&(I=I.__options)!=null&&I.blockPointerEvents&&W()){V.current=!0;const z=o.floating;if(wr(o.domReference)&&z){var D;const N=Yv(o.floating).body;N.setAttribute(YM,"");const B=o.domReference,Q=_==null||(D=_.nodesRef.current.find(G=>G.id===x))==null||(D=D.context)==null?void 0:D.elements.floating;return Q&&(Q.style.pointerEvents=""),N.style.pointerEvents="none",B.style.pointerEvents="auto",z.style.pointerEvents="auto",()=>{N.style.pointerEvents="",B.style.pointerEvents="",z.style.pointerEvents=""}}}},[l,n,x,o,_,b,W]),Ll(()=>{n||(O.current=void 0,K.current=!1,ie(),X())},[n,ie,X]),M.useEffect(()=>()=>{ie(),ha(P),ha(R),X()},[l,o.domReference,ie,X]);const H=M.useMemo(()=>{function I(D){O.current=D.pointerType}return{onPointerDown:I,onPointerEnter:I,onMouseMove(D){const{nativeEvent:z}=D;function N(){!U.current&&!C.current&&r(!0,z,"hover")}h&&!Zp(O.current)||n||ox(A.current)===0||K.current&&D.movementX**2+D.movementY**2<2||(ha(R),O.current==="touch"?N():(K.current=!0,R.current=window.setTimeout(N,ox(A.current))))}}},[h,r,n,C,A]);return M.useMemo(()=>l?{reference:H}:{},[l,H])}function KM(e){return ji(e.target)&&e.target.tagName==="BUTTON"}function cte(e){return ji(e.target)&&e.target.tagName==="A"}function ZM(e){return pee(e)}function fte(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,dataRef:i,elements:{domReference:a}}=e,{enabled:o=!0,event:l="click",toggle:f=!0,ignoreMouse:u=!1,keyboardHandlers:h=!0,stickIfOpen:m=!0}=t,g=M.useRef(),_=M.useRef(!1),x=M.useMemo(()=>({onPointerDown(b){g.current=b.pointerType},onMouseDown(b){const S=g.current;b.button===0&&l!=="click"&&(Zp(S,!0)&&u||(n&&f&&(!(i.current.openEvent&&m)||i.current.openEvent.type==="mousedown")?r(!1,b.nativeEvent,"click"):(b.preventDefault(),r(!0,b.nativeEvent,"click"))))},onClick(b){const S=g.current;if(l==="mousedown"&&g.current){g.current=void 0;return}Zp(S,!0)&&u||(n&&f&&(!(i.current.openEvent&&m)||i.current.openEvent.type==="click")?r(!1,b.nativeEvent,"click"):r(!0,b.nativeEvent,"click"))},onKeyDown(b){g.current=void 0,!(b.defaultPrevented||!h||KM(b))&&(b.key===" "&&!ZM(a)&&(b.preventDefault(),_.current=!0),!cte(b)&&b.key==="Enter"&&r(!(n&&f),b.nativeEvent,"click"))},onKeyUp(b){b.defaultPrevented||!h||KM(b)||ZM(a)||b.key===" "&&_.current&&(_.current=!1,r(!(n&&f),b.nativeEvent,"click"))}}),[i,a,l,u,h,r,n,m,f]);return M.useMemo(()=>o?{reference:x}:{},[o,x])}function dte(e){const{open:t=!1,onOpenChange:n,elements:r}=e,i=ite(),a=M.useRef({}),[o]=M.useState(()=>ate()),l=F$()!=null,[f,u]=M.useState(r.reference),h=vp((_,x,b)=>{a.current.openEvent=_?x:void 0,o.emit("openchange",{open:_,event:x,reason:b,nested:l}),n==null||n(_,x,b)}),m=M.useMemo(()=>({setPositionReference:u}),[]),g=M.useMemo(()=>({reference:f||r.reference||null,floating:r.floating||null,domReference:r.reference}),[f,r.reference,r.floating]);return M.useMemo(()=>({dataRef:a,open:t,onOpenChange:h,elements:g,events:o,floatingId:i,refs:m}),[t,h,g,o,i,m])}function V$(e){e===void 0&&(e={});const{nodeId:t}=e,n=dte({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,i=r.elements,[a,o]=M.useState(null),[l,f]=M.useState(null),h=(i==null?void 0:i.domReference)||a,m=M.useRef(null),g=q$();Ll(()=>{h&&(m.current=h)},[h]);const _=Wee({...e,elements:{...i,...l&&{reference:l}}}),x=M.useCallback(O=>{const P=wr(O)?{getBoundingClientRect:()=>O.getBoundingClientRect(),getClientRects:()=>O.getClientRects(),contextElement:O}:O;f(P),_.refs.setReference(P)},[_.refs]),b=M.useCallback(O=>{(wr(O)||O===null)&&(m.current=O,o(O)),(wr(_.refs.reference.current)||_.refs.reference.current===null||O!==null&&!wr(O))&&_.refs.setReference(O)},[_.refs]),S=M.useMemo(()=>({..._.refs,setReference:b,setPositionReference:x,domReference:m}),[_.refs,b,x]),C=M.useMemo(()=>({..._.elements,domReference:h}),[_.elements,h]),A=M.useMemo(()=>({..._,...r,refs:S,elements:C,nodeId:t}),[_,S,C,t,r]);return Ll(()=>{r.dataRef.current.floatingContext=A;const O=g==null?void 0:g.nodesRef.current.find(P=>P.id===t);O&&(O.context=A)}),M.useMemo(()=>({..._,context:A,refs:S,elements:C}),[_,S,C,A])}function sx(e,t,n){const r=new Map,i=n==="item";let a=e;if(i&&e){const{[VM]:o,[HM]:l,...f}=e;a=f}return{...n==="floating"&&{tabIndex:-1,[Jee]:""},...a,...t.map(o=>{const l=o?o[n]:null;return typeof l=="function"?e?l(e):null:l}).concat(e).reduce((o,l)=>(l&&Object.entries(l).forEach(f=>{let[u,h]=f;if(!(i&&[VM,HM].includes(u)))if(u.indexOf("on")===0){if(r.has(u)||r.set(u,[]),typeof h=="function"){var m;(m=r.get(u))==null||m.push(h),o[u]=function(){for(var g,_=arguments.length,x=new Array(_),b=0;b<_;b++)x[b]=arguments[b];return(g=r.get(u))==null?void 0:g.map(S=>S(...x)).find(S=>S!==void 0)}}}else o[u]=h}),o),{})}}function H$(e){e===void 0&&(e=[]);const t=e.map(l=>l==null?void 0:l.reference),n=e.map(l=>l==null?void 0:l.floating),r=e.map(l=>l==null?void 0:l.item),i=M.useCallback(l=>sx(l,e,"reference"),t),a=M.useCallback(l=>sx(l,e,"floating"),n),o=M.useCallback(l=>sx(l,e,"item"),r);return M.useMemo(()=>({getReferenceProps:i,getFloatingProps:a,getItemProps:o}),[i,a,o])}const XM=e=>e.replace(/[A-Z]+(?![a-z])|[A-Z]/g,(t,n)=>(n?"-":"")+t.toLowerCase());function uf(e,t){return typeof e=="function"?e(t):e}function hte(e,t){const[n,r]=M.useState(e);return e&&!n&&r(!0),M.useEffect(()=>{if(!e&&n){const i=setTimeout(()=>r(!1),t);return()=>clearTimeout(i)}},[e,n,t]),n}function pte(e,t){t===void 0&&(t={});const{open:n,elements:{floating:r}}=e,{duration:i=250}=t,o=(typeof i=="number"?i:i.close)||0,[l,f]=M.useState("unmounted"),u=hte(n,o);return!u&&l==="close"&&f("unmounted"),Ll(()=>{if(r){if(n){f("initial");const h=requestAnimationFrame(()=>{fc.flushSync(()=>{f("open")})});return()=>{cancelAnimationFrame(h)}}f("close")}},[n,r]),{isMounted:u,status:l}}function mte(e,t){t===void 0&&(t={});const{initial:n={opacity:0},open:r,close:i,common:a,duration:o=250}=t,l=e.placement,f=l.split("-")[0],u=M.useMemo(()=>({side:f,placement:l}),[f,l]),h=typeof o=="number",m=(h?o:o.open)||0,g=(h?o:o.close)||0,[_,x]=M.useState(()=>({...uf(a,u),...uf(n,u)})),{isMounted:b,status:S}=pte(e,{duration:o}),C=yl(n),A=yl(r),O=yl(i),P=yl(a);return Ll(()=>{const j=uf(C.current,u),R=uf(O.current,u),U=uf(P.current,u),V=uf(A.current,u)||Object.keys(j).reduce((Y,K)=>(Y[K]="",Y),{});if(S==="initial"&&x(Y=>({transitionProperty:Y.transitionProperty,...U,...j})),S==="open"&&x({transitionProperty:Object.keys(V).map(XM).join(","),transitionDuration:m+"ms",...U,...V}),S==="close"){const Y=R||j;x({transitionProperty:Object.keys(Y).map(XM).join(","),transitionDuration:g+"ms",...U,...Y})}},[g,O,C,A,P,m,S,u]),{isMounted:b,styles:_}}/*!
|
||
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
|
||
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
|
||
* Copyright 2024 Fonticons, Inc.
|
||
*/const gte={prefix:"far",iconName:"image",icon:[512,512,[],"f03e","M448 80c8.8 0 16 7.2 16 16l0 319.8-5-6.5-136-176c-4.5-5.9-11.6-9.3-19-9.3s-14.4 3.4-19 9.3L202 340.7l-30.5-42.7C167 291.7 159.8 288 152 288s-15 3.7-19.5 10.1l-80 112L48 416.3l0-.3L48 96c0-8.8 7.2-16 16-16l384 0zM64 32C28.7 32 0 60.7 0 96L0 416c0 35.3 28.7 64 64 64l384 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L64 32zm80 192a48 48 0 1 0 0-96 48 48 0 1 0 0 96z"]},vte={prefix:"far",iconName:"circle-right",icon:[512,512,[61838,"arrow-alt-circle-right"],"f35a","M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM0 256a256 256 0 1 0 512 0A256 256 0 1 0 0 256zM294.6 151.2c-4.2-4.6-10.1-7.2-16.4-7.2C266 144 256 154 256 166.3l0 41.7-96 0c-17.7 0-32 14.3-32 32l0 32c0 17.7 14.3 32 32 32l96 0 0 41.7c0 12.3 10 22.3 22.3 22.3c6.2 0 12.1-2.6 16.4-7.2l84-91c3.5-3.8 5.4-8.7 5.4-13.9s-1.9-10.1-5.4-13.9l-84-91z"]},yte=vte,bte={prefix:"far",iconName:"circle",icon:[512,512,[128308,128309,128992,128993,128994,128995,128996,9679,9898,9899,11044,61708,61915],"f111","M464 256A208 208 0 1 0 48 256a208 208 0 1 0 416 0zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256z"]},G$={prefix:"far",iconName:"clone",icon:[512,512,[],"f24d","M64 464l224 0c8.8 0 16-7.2 16-16l0-64 48 0 0 64c0 35.3-28.7 64-64 64L64 512c-35.3 0-64-28.7-64-64L0 224c0-35.3 28.7-64 64-64l64 0 0 48-64 0c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16zM224 304l224 0c8.8 0 16-7.2 16-16l0-224c0-8.8-7.2-16-16-16L224 48c-8.8 0-16 7.2-16 16l0 224c0 8.8 7.2 16 16 16zm-64-16l0-224c0-35.3 28.7-64 64-64L448 0c35.3 0 64 28.7 64 64l0 224c0 35.3-28.7 64-64 64l-224 0c-35.3 0-64-28.7-64-64z"]},wte=({children:e,summary:t,summaryClasses:n,...r})=>{const i=M.useRef(null),[a,o]=M.useState(!1);return M.useEffect(()=>{const l=i.current,f=()=>o(!!(l!=null&&l.open));return l==null||l.addEventListener("toggle",f),()=>l==null?void 0:l.removeEventListener("toggle",f)},[]),v.jsxs("details",{ref:i,...r,children:[v.jsx("summary",{className:be("tw:focus-ring tw:px-1 tw:-mx-1 tw:rounded-sm",n),children:t}),a&&v.jsx("div",{className:"tw:mt-3 tw:flex tw:flex-col tw:gap-y-3",children:e})]})},_te=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:px-4 tw:py-3 tw:rounded-t-md","tw:bg-lm-primary tw:dark:bg-dm-primary tw:border-b tw:border-lm-border tw:dark:border-dm-border",e),...t,ref:n})),xte=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:p-4 tw:bg-lm-primary tw:dark:bg-dm-primary tw:first:rounded-t-md","tw:first:rounded-t-md tw:last:rounded-b-md",e),...t,ref:n})),Ste=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:px-4 tw:py-3 tw:rounded-b-md","tw:bg-lm-primary tw:dark:bg-dm-primary tw:border-t tw:border-lm-border tw:dark:border-dm-border",e),...t,ref:n})),Cte=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:group/card tw:rounded-md tw:shadow-md","tw:border tw:border-lm-border tw:dark:border-dm-border tw:bg-lm-primary tw:dark:bg-dm-primary",e),...t,ref:n})),zr=Object.assign(Cte,{Body:xte,Header:_te,Footer:Ste}),Ub=M.forwardRef(({bodyClassName:e,children:t,...n},r)=>{const{title:i,titleSize:a="md",...o}="title"in n?n:{...n,title:void 0,titleSize:void 0};return v.jsxs(zr,{...o,ref:r,children:[i&&v.jsxs(zr.Header,{children:[a==="lg"&&v.jsx("h4",{children:i}),a==="md"&&v.jsx("h5",{children:i}),a==="sm"&&v.jsx("h6",{children:i})]}),v.jsx(zr.Body,{className:e,children:t})]})});function Ate({id:e,items:t,onSelectItem:n,onActiveItemChange:r,renderItem:i,className:a,noItemsMessage:o="No items",anchor:l,"aria-label":f="Items",...u}){const[h,m]=M.useState(0),g=M.useCallback(_=>{if(m(_),r){const[x,b]=[...t.entries()][_];r(x,b)}},[t,r]);return M.useEffect(()=>{const _=l==null?void 0:l.current;if(!_)return;const x=b=>{["Enter","ArrowUp","ArrowDown"].includes(b.key)&&b.preventDefault(),b.key==="ArrowDown"?g(Math.min(h+1,t.size-1)):b.key==="ArrowUp"?g(Math.max(h-1,0)):b.key==="Enter"&&n([...t.values()][h])};return _.addEventListener("keydown",x),()=>_.removeEventListener("keydown",x)},[h,l,g,t,n]),v.jsxs(zr,{id:e,className:be("tw:py-1 tw:flex tw:flex-col",a),role:"listbox","aria-orientation":"vertical","aria-label":f,...u,children:[t.size===0&&v.jsx("i",{role:"option","aria-disabled":!0,"aria-selected":!1,"data-testid":"no-items",className:"tw:px-2 tw:py-1",children:o}),[...t.entries()].map(([_,x],b)=>v.jsx("button",{id:`${e}_${_}`,type:"button",role:"option","aria-selected":b===h,className:be("tw:px-2 tw:py-1 tw:text-left tw:truncate",{"tw:bg-lm-secondary tw:dark:bg-dm-secondary":b===h}),tabIndex:-1,onClick:()=>n(x),onMouseOver:()=>g(b),children:i(x)},_))]})}const tg=M.createContext(void 0),Md=M.createContext({responsive:!0,size:"md"}),Ete=({children:e,className:t})=>{const{responsive:n}=M.useContext(Md);return v.jsx(tg.Provider,{value:{section:"head"},children:v.jsx("thead",{className:be({"tw:hidden tw:lg:table-header-group":n},t),children:e})})},Ote=({children:e,className:t})=>{const{responsive:n}=M.useContext(Md);return v.jsx(tg.Provider,{value:{section:"body"},children:v.jsx("tbody",{className:be({"tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3":n},t),children:e})})},Tte=({children:e,className:t})=>{const{responsive:n}=M.useContext(Md);return v.jsx(tg.Provider,{value:{section:"footer"},children:v.jsx("tfoot",{className:be({"tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3 tw:mt-4":n},t),children:e})})},jte=({children:e,className:t,...n})=>{const r=M.useContext(tg),i=(r==null?void 0:r.section)==="body",{responsive:a}=M.useContext(Md);return v.jsx("tr",{className:be("tw:group",{"tw:lg:table-row tw:flex tw:flex-col":a,"tw:lg:border-0 tw:border-y-2 tw:border-lm-border tw:dark:border-dm-border":a,"tw:hover:bg-lm-primary tw:dark:hover:bg-dm-primary":i,"tw:group-[&]/card:hover:bg-lm-secondary tw:dark:group-[&]/card:hover:bg-dm-secondary":i},t),...n,children:e})},Pte=({children:e,className:t,columnName:n,type:r,...i})=>{const a=M.useContext(tg),o=r??((a==null?void 0:a.section)!=="body"?"th":"td"),{responsive:l,size:f}=M.useContext(Md);return v.jsx(o,{"data-column":l?n:void 0,className:be("tw:border-lm-border tw:dark:border-dm-border",{"tw:p-1":f==="sm","tw:p-2":f==="md","tw:p-3":f==="lg","tw:border-b-1":!l,"tw:block tw:lg:table-cell tw:not-last:border-b-1 tw:lg:border-b-1":l,"tw:text-left":o==="th","tw:before:lg:hidden tw:before:content-[attr(data-column)] tw:before:font-bold tw:before:mr-1":l&&o==="td"},t),...i,children:e})},Rte=({header:e,footer:t,children:n,responsive:r=!0,size:i="md",...a})=>v.jsx(Md.Provider,{value:{responsive:r,size:i},children:v.jsxs("table",{className:"tw:w-full",...a,children:[v.jsx(Ete,{children:e}),v.jsx(Ote,{children:n}),t&&v.jsx(Tte,{children:t})]})}),wi=Object.assign(Rte,{Row:jte,Cell:Pte}),Pi=M.forwardRef(({className:e,disabled:t,variant:n="primary",size:r="md",inline:i=!1,solid:a=!1,type:o="button",...l},f)=>{const u="to"in l&&typeof l.to=="string",h=u?ur:"button",m=u?void 0:o;return v.jsx(h,{ref:f,className:be({"tw:inline-flex":i,"tw:flex":!i},"tw:gap-2 tw:items-center tw:justify-center","tw:border tw:rounded-md tw:no-underline","tw:transition-colors",{"tw:focus-ring":n==="primary","tw:focus-ring-secondary":n==="secondary","tw:focus-ring-danger":n==="danger"},{"tw:px-1.5 tw:py-1 tw:text-sm":r==="sm","tw:px-3 tw:py-1.5":r==="md","tw:px-4 tw:py-2 tw:text-lg":r==="lg"},{"tw:border-lm-brand tw:dark:border-dm-brand":n==="primary","tw:text-lm-brand tw:dark:text-dm-brand":n==="primary"&&!a,"tw:border-zinc-500":n==="secondary","tw:text-zinc-500":n==="secondary"&&!a,"tw:border-danger":n==="danger","tw:text-danger":n==="danger"&&!a},a&&{"tw:text-white":!0,"tw:bg-lm-brand tw:dark:bg-dm-brand":n==="primary","tw:highlight:bg-lm-brand-dark tw:dark:highlight:bg-dm-brand-dark":n==="primary","tw:highlight:border-lm-brand-dark tw:dark:highlight:border-dm-brand-dark":n==="primary","tw:bg-zinc-500":n==="secondary","tw:highlight:bg-zinc-600 tw:highlight:border-zinc-600":n==="secondary","tw:bg-danger":n==="danger","tw:highlight:bg-danger-dark tw:highlight:border-danger-dark":n==="danger"},!t&&{"tw:highlight:text-white":!a,"tw:highlight:bg-lm-brand tw:dark:highlight:bg-dm-brand":n==="primary","tw:highlight:bg-zinc-500":n==="secondary","tw:highlight:bg-danger":n==="danger"},{"tw:cursor-pointer":!t,"tw:pointer-events-none tw:opacity-65":t},e),disabled:u?void 0:t,"aria-disabled":u?t:void 0,type:m,...l})}),W$=M.forwardRef(({className:e,onChange:t,...n},r)=>{const i=M.useCallback(a=>t==null?void 0:t(a.target.checked,a),[t]);return v.jsx("input",{ref:r,type:"checkbox",className:be("tw:appearance-none tw:focus-ring tw:cursor-[inherit]","tw:border-1 tw:border-lm-input-border tw:dark:border-dm-input-border","tw:bg-lm-primary tw:dark:bg-dm-primary tw:checked:bg-lm-brand tw:dark:checked:bg-dm-brand tw:bg-no-repeat","tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input",e),onChange:i,...n})}),Mte=M.forwardRef(({className:e,...t},n)=>v.jsx(W$,{ref:n,className:be("tw:rounded-sm tw:w-4 tw:h-4 tw:checked:bg-(image:--tick) tw:bg-center",e),...t})),oE=M.forwardRef(({onClick:e,className:t,label:n="Close",size:r="lg",solid:i},a)=>v.jsx("button",{ref:a,type:"button",onClick:e,className:be("tw:rounded-md tw:focus-ring tw:cursor-pointer",{"tw:opacity-50 tw:highlight:opacity-80 tw:transition-opacity":!i},t),"aria-label":n,children:v.jsx(Ye,{icon:Pb,size:r==="lg"?"xl":r==="md"?"lg":void 0})})),IT=M.forwardRef(({borderless:e=!1,size:t="md",feedback:n,variant:r="default",className:i,disabled:a,...o},l)=>v.jsx("input",{ref:l,className:be("tw:outline-none",r==="default"&&["tw:w-full",{"tw:focus-ring":!n,"tw:focus-ring-danger":n==="error","tw:px-2 tw:py-1 tw:text-sm":t==="sm","tw:px-3 tw:py-1.5":t==="md","tw:px-4 tw:py-2 tw:text-xl":t==="lg","tw:rounded-md tw:border":!e,"tw:border-lm-input-border tw:dark:border-dm-input-border":!e&&!n,"tw:border-danger":!e&&n==="error","tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input":a,"tw:bg-lm-primary tw:dark:bg-dm-primary":!a,"tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":!a}],i),disabled:a,...o})),zb=({required:e,children:t,className:n,...r})=>v.jsxs("label",{className:be("tw:cursor-pointer",n),...r,children:[t,e&&v.jsx("span",{className:"tw:text-danger tw:ml-1","data-testid":"required-indicator",children:"*"})]}),$T=({children:e,helpText:t,error:n,"data-testid":r})=>v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1","data-testid":r,children:[e,t&&v.jsx("small",{"data-testid":r?`${r}-help-text`:"help-text",className:"tw:text-gray-500 tw:dark:text-gray-400",children:t}),n&&v.jsx("span",{"data-testid":r?`${r}-error`:"error",className:"tw:text-danger",children:n})]}),QM=M.forwardRef(({label:e,inputClassName:t,required:n,hiddenRequired:r,error:i,helpText:a,"data-testid":o,...l},f)=>{const u=M.useId();return v.jsxs($T,{error:i,helpText:a,"data-testid":o,children:[v.jsx(zb,{htmlFor:u,required:n,children:e}),v.jsx(IT,{ref:f,id:u,className:t,required:n||r,feedback:i?"error":void 0,...l})]})}),Nte=M.forwardRef(({containerClassName:e,className:t,size:n,...r},i)=>{const[a,o,,l]=wn(!1),f=M.useRef(null),u=M.useCallback(({relatedTarget:h})=>{var m;(m=f.current)!=null&&m.contains(h)||l()},[f,l]);return v.jsxs("div",{className:be("tw:group tw:relative",e),ref:f,onBlurCapture:u,children:[v.jsx(IT,{ref:i,type:a?"text":"password",className:be({"tw:pr-10":n!=="sm","tw:pr-8":n==="sm"},t),size:n,"data-testid":"input",...r}),v.jsx("button",{type:"button",onClick:o,title:a?"Hide password":"Show password","aria-label":a?"Hide password":"Show password",className:be("tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:px-1 tw:cursor-pointer","tw:text-placeholder tw:hover:text-lm-text tw:hover:dark:text-dm-text tw:transition-colors",{"tw:right-1.5":n!=="sm","tw:scale-85 tw:right-1":n==="sm"}),tabIndex:-1,children:v.jsx(Ye,{fixedWidth:!0,icon:a?M9:L9})})]})}),Lte=M.forwardRef(({label:e,inputClassName:t,required:n,hiddenRequired:r,error:i,helpText:a,"data-testid":o,...l},f)=>{const u=M.useId();return v.jsxs($T,{error:i,helpText:a,"data-testid":o,children:[v.jsx(zb,{htmlFor:u,required:n,children:e}),v.jsx(Nte,{ref:f,id:u,className:t,required:n||r,feedback:i?"error":void 0,...l})]})}),kte=M.forwardRef(({className:e,size:t="md",feedback:n,style:r={},disabled:i,...a},o)=>v.jsx("select",{ref:o,className:be("tw:w-full tw:appearance-none tw:pr-9","tw:bg-(image:--chevron-down) tw:bg-no-repeat",{"tw:focus-ring":!n,"tw:focus-ring-danger":n==="error"},"tw:rounded-md tw:border",{"tw:border-lm-input-border tw:dark:border-dm-input-border":!n,"tw:border-danger":n==="error"},{"tw:pl-2 tw:py-1 tw:text-sm":t==="sm","tw:pl-3 tw:py-1.5":t==="md","tw:pl-4 tw:py-2 tw:text-xl":t==="lg","tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input":i,"tw:bg-lm-primary tw:dark:bg-dm-primary tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":!i},e),style:{...r,background:"right 0.75rem center / 16px 12px"},disabled:i,...a}));M.forwardRef(({selectClassName:e,label:t,error:n,helpText:r,required:i,hiddenRequired:a,"data-testid":o,...l},f)=>{const u=M.useId();return v.jsxs($T,{error:n,helpText:r,"data-testid":o,children:[v.jsx(zb,{htmlFor:u,required:i,children:t}),v.jsx(kte,{ref:f,id:u,className:e,required:i||a,feedback:n?"error":void 0,...l})]})});const Y$=M.forwardRef(({onChange:e,containerClassName:t,inputClassName:n,size:r="lg",loading:i=!1,variant:a="default",immediate:o=!1,...l},f)=>{const{setTimeout:u,clearCurrentTimeout:h}=A$(500),m=M.useCallback(g=>{!g||o?(h(),e(g)):u(()=>e(g))},[h,o,e,u]);return v.jsxs("div",{className:be("tw:group tw:relative tw:focus-within:z-10",t),children:[a==="default"&&v.jsx(Ye,{icon:i?Ym:I9,spin:i,className:be("tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:transition-colors","tw:text-placeholder tw:group-focus-within:text-lm-text tw:dark:group-focus-within:text-dm-text",{"tw:left-3":r!=="sm","tw:scale-85 tw:left-2":r==="sm"})}),v.jsx(IT,{ref:f,variant:a,type:"search",className:be(a==="default"&&{"tw:pl-9":r!=="sm","tw:pl-7":r==="sm"},n),placeholder:"Search...",onChange:g=>m(g.target.value),size:r,...l})]})});function Dte({searchResults:e,onSearch:t,onSelectSearchResult:n,renderSearchResult:r,size:i="md",listboxSpan:a="full",onFocus:o,containerClassName:l,listboxClassName:f,...u},h){const m=M.useId(),[g,_]=M.useState(),x=M.useRef(null);M.useImperativeHandle(h,()=>x.current);const b=M.useMemo(()=>e?g??[...e.keys()][0]:void 0,[g,e]),S=M.useCallback(C=>{n(C),t(""),x.current.value=""},[t,n,x]);return v.jsxs("div",{className:be("tw:relative",l),onBlur:C=>{C.currentTarget.contains(C.relatedTarget)||t("")},children:[v.jsx(Y$,{onChange:t,size:i,ref:x,role:"combobox","aria-autocomplete":"list","aria-expanded":!!e,"aria-controls":m,"aria-activedescendant":b?`${m}_${b}`:void 0,autoComplete:"off",autoCorrect:"off",onFocus:C=>{o==null||o(C),t(C.target.value)},...u}),e&&v.jsx(Ate,{id:m,items:e,anchor:x,onSelectItem:S,onActiveItemChange:_,renderItem:r,className:be("tw:absolute tw:top-full tw:mt-1 tw:z-10",{"tw:min-w-60":a==="auto","tw:w-full":a==="full"},f),"aria-label":"Matching items",noItemsMessage:"No results found matching search"})]})}M.forwardRef(Dte);M.forwardRef(({className:e,...t},n)=>v.jsx(W$,{ref:n,className:be("tw:rounded-full tw:w-8 tw:h-4","tw:bg-(image:--circle-grey-dark) tw:dark:bg-(image:--circle-grey-light) tw:checked:bg-(image:--circle-white)","tw:focus-visible:not-checked:bg-(image:--circle-light-blue)","tw:checked:bg-right tw:transition-[background-position]",e),...t}));const Ite=({className:e,selected:t,disabled:n,...r})=>{const i="to"in r&&typeof r.to=="string";return v.jsx(i?ur:"button",{role:"menuitem","data-selected":t,className:be("tw:flex tw:items-center tw:gap-2","tw:w-full tw:px-3 tw:py-1.5 tw:focus-ring","tw:no-underline tw:text-inherit",{"tw:cursor-pointer":!n,"tw:pointer-events-none tw:opacity-50":n,"tw:bg-lm-secondary tw:dark:bg-dm-secondary":t&&!n,"tw:highlight:bg-lm-secondary tw:dark:highlight:bg-dm-secondary tw:highlight:z-1 tw:relative":!t&&!n},e),tabIndex:-1,disabled:i?void 0:n,"aria-disabled":i?n:void 0,...r})},$te=()=>v.jsx("div",{role:"separator","aria-hidden":!0,className:"tw:border-b tw:border-lm-border tw:dark:border-dm-border tw:my-2"}),Bte=({children:e})=>v.jsx("div",{role:"heading","aria-level":6,"aria-hidden":!0,className:be("tw:flex tw:items-center tw:w-full tw:px-3 tw:py-1.5","tw:text-gray-500 tw:text-sm tw:font-semibold"),onClick:t=>t.stopPropagation(),children:e}),Ute=({className:e,onClick:t,...n})=>v.jsx("div",{className:be("tw:px-3 tw:py-1.5",e),...n,onClick:r=>{r.stopPropagation(),t==null||t(r)}}),zte=({children:e,className:t,focusableElementsSelector:n='[role="menuitem"]:not([disabled]):not([aria-disabled])',focusFirstItem:r=!1,...i})=>{const a=M.useRef(null);return VJ(a,{elementsSelector:n,focusFirstItem:r}),v.jsx(zr,{ref:a,role:"menu",className:be("tw:py-2 tw:whitespace-nowrap",t),...i,children:e})},yp=Object.assign(zte,{Item:Ite,Separator:$te,Title:Bte,Misc:Ute}),Fte=({children:e,menuAlignment:t="left",buttonVariant:n="button",buttonContent:r,buttonClassName:i,buttonSize:a="md",buttonDisabled:o=!1,containerClassName:l,menuClassName:f,caretless:u,buttonLabel:h,menuOffset:m=3})=>{const[g,_]=M.useState(!1),x=M.useRef(null),{refs:b,floatingStyles:S,context:C}=V$({open:g,onOpenChange:_,placement:t==="right"?"bottom-end":"bottom-start",middleware:[Zee(),Kee(m)],elements:{reference:x.current}}),A=fte(C),{getReferenceProps:O,getFloatingProps:P}=H$([A]),j=M.useId(),R=M.useRef(null);return M.useEffect(()=>{const U=R.current,V=x.current;if(!U||!V)return()=>{};const Y=new AbortController;return document.body.addEventListener("click",K=>{K.composedPath().includes(V)||_(!1)},{signal:Y.signal}),()=>Y.abort()},[]),v.jsxs("div",{ref:R,className:be("tw:relative tw:inline-block",l),onKeyDown:U=>{U.key==="Escape"&&_(!1)},onBlur:U=>{U.relatedTarget&&!R.current.contains(U.relatedTarget)&&_(!1)},children:[v.jsxs("button",{ref:x,...O(),type:"button","aria-haspopup":!0,"aria-expanded":g,"aria-controls":j,"aria-label":h,disabled:o,className:be("tw:flex tw:items-center tw:rounded-md tw:focus-ring",{"tw:justify-between":!u,"tw:cursor-pointer":!o,"tw:pointer-events-none tw:opacity-50":o,"tw:border tw:border-lm-border tw:dark:border-dm-border":n==="button","tw:bg-lm-primary tw:dark:bg-dm-primary":n==="button","tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":n==="button","tw:text-lm-brand tw:dark:text-dm-brand":n==="link","tw:highlight:text-lm-brand-dark tw:dark:highlight:text-dm-brand-dark tw:highlight:underline":n==="link","tw:px-1.5 tw:py-1 tw:text-sm":n!=="text"&&a==="sm","tw:px-3 tw:py-1.5":n!=="text"&&a==="md","tw:px-4 tw:py-2 tw:text-lg":n!=="text"&&a==="lg","tw:gap-x-1.5":a==="sm","tw:gap-x-2":a!=="sm"},i),onKeyDown:U=>{U.key==="ArrowDown"&&(U.preventDefault(),_(!0))},children:[r,!u&&v.jsx(Ye,{icon:vT,size:"xs"})]}),g&&v.jsx("div",{ref:b.setFloating,style:S,className:"tw:min-w-full tw:z-500",...P(),children:v.jsx(yp,{className:f,id:j,focusableElementsSelector:'[role="menuitem"]:not([disabled]):not([aria-disabled]),input:not([disabled]),select:not([disabled])',focusFirstItem:!0,children:e})})]})},Qa=Object.assign(Fte,{Item:yp.Item,Separator:yp.Separator,Title:yp.Title,Misc:yp.Misc}),qte=M.forwardRef(({className:e,disabled:t,size:n="md",type:r="button",...i},a)=>v.jsx("button",{className:be("tw:inline-flex tw:rounded-md tw:focus-ring","tw:text-lm-brand tw:dark:text-dm-brand","tw:highlight:text-lm-brand-dark tw:dark:highlight:text-dm-brand-dark tw:highlight:underline",{"tw:px-1.5 tw:py-1 tw:text-sm":n==="sm","tw:px-3 tw:py-1.5":n==="md","tw:px-4 tw:py-2 tw:text-lg":n==="lg","tw:cursor-pointer":!t,"tw:pointer-events-none tw:opacity-65":t},e),disabled:t,type:r,...i,ref:a})),Vte=({className:e,active:t,...n})=>v.jsx("li",{role:"menuitem",className:"tw:w-full tw:flex","data-active":t,children:v.jsx(ur,{className:be("tw:px-2 tw:py-3","tw:max-md:w-full tw:max-md:px-3 tw:max-md:py-2","tw:text-white tw:no-underline tw:highlight:opacity-100 tw:transition-opacity",{"tw:opacity-60":!t,"tw:opacity-100":t},e),...n})}),Hte=({containerClassName:e,buttonClassName:t,menuClassName:n,active:r,...i})=>v.jsx("li",{role:"menuitem","aria-haspopup":!0,className:"tw:w-full tw:flex","data-active":r,children:v.jsx(Qa,{containerClassName:be("tw:max-md:w-full",e),buttonVariant:"text",buttonClassName:be("tw:px-2 tw:py-3","tw:max-md:w-full tw:max-md:px-3 tw:max-md:py-2","tw:text-white tw:highlight:opacity-100 tw:transition-opacity",{"tw:opacity-60":!r,"tw:opacity-100":r},t),menuAlignment:"right",menuOffset:-3,menuClassName:be("tw:mx-2",n),...i})}),Gte=({className:e,brand:t,children:n})=>{const{flag:r,toggle:i,setToFalse:a}=wn(!1,!0),o=M.useId(),l=M.useId(),{pathname:f}=Sr();return M.useEffect(()=>a(),[f,a]),v.jsxs("nav",{className:be("tw:w-full tw:relative","tw:bg-lm-main tw:dark:bg-dm-main","tw:flex tw:max-md:flex-col tw:items-center tw:justify-between",e),children:[v.jsxs("div",{className:"tw:w-full tw:relative",children:[v.jsx("h4",{className:be("tw:text-white tw:px-4 tw:py-3","tw:max-md:w-full tw:max-md:flex tw:max-md:flex-col tw:items-center"),children:t}),v.jsx(Pi,{id:l,variant:"secondary",className:be("tw:absolute tw:right-0 tw:top-[50%] tw:translate-y-[-50%]","tw:md:hidden tw:mx-2 tw:[&]:px-2","tw:opacity-60 tw:highlight:opacity-100 tw:transition-opacity","tw:[&]:text-inherit tw:[&]:border-white tw:[&]:highlight:bg-transparent"),onClick:i,"aria-label":`${r?"Hide":"Show"} menu`,"aria-controls":o,children:v.jsx(Ye,{icon:r?$Z:hX})})]}),v.jsx("ul",{id:o,"aria-labelledby":l,role:"menu",className:be("tw:m-0 tw:p-0","tw:max-md:w-full tw:md:mr-2 tw:max-md:absolute tw:max-md:top-full tw:z-2000","tw:flex tw:max-md:flex-col tw:items-center","tw:bg-lm-main tw:dark:bg-dm-main",{"tw:max-md:hidden":!r}),children:n})]})},sE=Object.assign(Gte,{MenuItem:Vte,Dropdown:Hte}),K$=M.createContext(null),Wte=({className:e,to:t,...n})=>{const r=M.useContext(K$);return v.jsx(Ab,{role:"menuitem",to:t,className:({isActive:i})=>be("tw:px-4 tw:pt-2 tw:pb-[calc(0.5rem-3px)] tw:border-b-3","tw:highlight:text-lm-brand tw:dark:highlight:text-dm-brand","tw:font-bold tw:text-center tw:no-underline tw:transition-colors","tw:rounded-none tw:outline-none tw:focus-visible:inset-ring-2","tw:focus-visible:inset-ring-lm-brand/50 tw:dark:focus-visible:inset-ring-dm-brand/50",{"tw:text-lm-brand tw:dark:text-dm-brand":i,"tw:border-b-lm-brand tw:dark:border-b-dm-brand active":i,"tw:border-b-transparent tw:text-gray-500":!i,"tw:flex-grow":r==null?void 0:r.fill},e),...n})},Yte=({children:e,className:t,fill:n})=>v.jsx(K$.Provider,{value:{fill:n},children:v.jsx(zr,{role:"menubar",className:be("tw:flex tw:overflow-hidden",t),children:e})});Object.assign(Yte,{Pill:Wte});const Kte=({buttonLabel:e="Options",buttonSize:t="md",...n})=>v.jsx(Qa,{buttonContent:v.jsx(Ye,{icon:k9,className:be({"tw:px-1":t==="sm"})}),caretless:!0,buttonLabel:e,buttonSize:t,...n}),cf=Object.assign(Kte,{Item:Qa.Item,Separator:Qa.Separator,Title:Qa.Title,Misc:Qa.Misc}),Zte=({open:e,children:t,className:n,onClose:r,...i})=>{const a=M.useRef(null);return M.useEffect(()=>{var o,l;const f=document.body,u=f.style.overflow,h=f.style.paddingRight;if(e){const m=window.outerWidth-f.clientWidth,g=f.scrollHeight>f.clientHeight;f.style.overflow="hidden",g&&(f.style.paddingRight=`${m}px`),(o=a.current)==null||o.showModal()}else(l=a.current)==null||l.close();return()=>{f.style.overflow=u,f.style.paddingRight=h}},[e]),fc.createPortal(v.jsx("dialog",{ref:a,className:be("tw:bg-transparent tw:backdrop:bg-black/50",n),onCancel:o=>{o.preventDefault(),r()},...i,children:e&&t}),document.body)},Z$=({open:e,onClose:t,variant:n="default",title:r,children:i,className:a,...o})=>{const{size:l="md",confirmText:f="Confirm",cancelText:u="Cancel",confirmDisabled:h,onConfirm:m,onClosed:g,..._}="onConfirm"in o?o:{...o},[x,b]=M.useState(e),S=M.useRef(null),C=M.useRef("cancel"),A=M.useCallback(O=>{O.preventDefault(),O.stopPropagation(),C.current="confirm",m==null||m()},[m]);return M.useEffect(()=>{if(e){C.current="cancel",b(!0);return}const O=S.current;if(O){delete S.current.dataset.open;let P=!1;const j=R=>{P||R.target!==O||(P=!0,b(!1),g==null||g(C.current))};return O.addEventListener("transitionend",j),()=>{O.removeEventListener("transitionend",j)}}},[g,e]),M.useEffect(()=>{const O=S.current;x&&O&&(O.dataset.open="")},[x]),v.jsx(Zte,{open:x,onClose:t,className:be({"tw:flex tw:w-screen tw:h-screen tw:max-w-screen tw:max-h-screen":x,"tw:overflow-hidden":n==="cover"},a),..._,children:v.jsx("form",{"data-testid":"transition-container",ref:S,className:be("tw:w-full tw:m-auto tw:p-4 tw:sm:p-6","tw:-translate-y-4 tw:data-open:translate-y-0 tw:opacity-0 tw:data-open:opacity-100","tw:transition-[opacity_,_translate] tw:duration-300",n!=="cover"&&{"tw:sm:w-sm":l==="sm","tw:md:w-lg":l==="md","tw:md:w-4xl":l==="lg","tw:md:w-6xl":l==="xl"},{"tw:h-full":n==="cover"}),onSubmit:A,children:v.jsx(zr,{className:be("tw:w-full",{"tw:h-full tw:relative tw:overflow-auto":n==="cover"}),children:n==="cover"?v.jsxs(v.Fragment,{children:[v.jsxs("div",{className:be("tw:px-4 tw:py-3 tw:absolute tw:top-0 tw:left-0 tw:right-0 tw:z-3000","tw:flex tw:items-center tw:justify-between","tw:text-white tw:bg-linear-to-b tw:from-black/70 tw:to-black/10","tw:[text-shadow:_0_2px_4px_rgb(0_0_0/_0.8)]"),children:[v.jsx("h5",{children:r}),v.jsx(oE,{onClick:t,label:"Close dialog"})]}),i]}):v.jsxs(v.Fragment,{children:[v.jsxs(zr.Header,{className:be("tw:sticky tw:top-0","tw:flex tw:items-center tw:justify-between tw:gap-x-2"),children:[v.jsx("h5",{className:be({"tw:text-danger":n==="danger"}),children:r}),v.jsx(oE,{onClick:t,label:"Close dialog"})]}),v.jsx(zr.Body,{children:i}),m&&v.jsxs(zr.Footer,{"data-testid":"footer",className:be("tw:flex tw:justify-end tw:items-center tw:gap-x-2","tw:[&]:px-3 tw:sticky tw:bottom-0"),children:[v.jsx(qte,{onClick:t,children:u}),v.jsx(Pi,{solid:!0,variant:n==="danger"?"danger":"primary",disabled:h,type:"submit",children:f})]})]})})})})},X$=({className:e,children:t,loading:n=!1,variant:r="default"})=>v.jsx(Ub,{className:be({"tw:[&]:border-danger":r==="error"},e),children:v.jsxs("h3",{className:be("tw:text-center",{"tw:text-gray-500 tw:dark:text-gray-400":r==="default","tw:text-danger":r==="error"}),children:[n&&v.jsxs(v.Fragment,{children:[v.jsx(Ye,{icon:Ym,spin:!0}),v.jsx("span",{className:"tw:ml-2",children:t??"Loading..."})]}),!n&&t]})}),Q$=({variant:e,className:t,size:n="md",children:r})=>v.jsx("div",{className:be("tw:rounded-md tw:text-center",{"tw:p-2":n==="sm","tw:p-4":n==="md","tw:p-6":n==="lg","tw:[&]:text-white":e!=="warning","tw:bg-lm-brand tw:dark:bg-dm-brand":e==="success","tw:bg-danger":e==="error","tw:bg-warning tw:text-black":e==="warning"},t),children:r}),J$=({placement:e="auto"}={})=>{const t=M.useRef(null),n=(()=>{const b=[];return e==="auto"&&b.push(Xee()),b.push(Qee({element:t})),b})(),[r,i]=M.useState(!1),{refs:a,floatingStyles:o,context:l,middlewareData:f}=V$({placement:e==="auto"?void 0:e,open:r,onOpenChange:i,middleware:n}),u=ute(l,{delay:{open:300},move:!0}),{getFloatingProps:h,getReferenceProps:m}=H$([u]),{isMounted:g,styles:_}=mte(l,{duration:200}),x=M.useMemo(()=>{const b=l.placement.split("-")[0];return{top:"bottom",right:"left",bottom:"top",left:"right"}[b]??""},[l.placement]);return{anchor:{...m(),ref:a.setReference},tooltip:{...h(),refSetter:a.setFloating,isMounted:g,styles:{...o,..._},arrowPos:f.arrow,arrowRef:t,arrowSide:x}}},eB=({children:e,isMounted:t,styles:n,refSetter:r,arrowRef:i,arrowPos:a,arrowSide:o,...l})=>{var f;return t&&v.jsx("div",{role:"tooltip","aria-live":"polite",className:be("tw:z-500 tw:max-w-64",{"tw:pt-2.5":o==="top","tw:pb-2.5":o==="bottom","tw:pr-2.5":o==="right","tw:pl-2.5":o==="left"}),ref:r,style:n,...l,children:v.jsxs("div",{className:"tw:relative tw:px-1.5 tw:py-1 tw:rounded tw:bg-black/90 tw:text-white tw:text-center",children:[v.jsx("span",{className:"tw:sr-only",children:"Tooltip: "}),e,v.jsx("div",{ref:i,className:be("tw:absolute","tw:border-l-6 tw:border-r-6 tw:border-b-6 tw:border-l-transparent tw:border-r-transparent tw:border-b-black/90",{"tw:rotate-180":o==="bottom","tw:rotate-90 tw:mr-[-3px]":o==="right","tw:rotate-270 tw:ml-[-3px]":o==="left"}),style:{left:a==null?void 0:a.x,top:a==null?void 0:a.y,[o]:`${-(((f=i.current)==null?void 0:f.offsetWidth)??0)/2}px`},"data-testid":"arrow"})]})})},Xte=({isOpen:e,onClose:t,forceUpdate:n})=>{const{flag:r,setToTrue:i}=wn(!1,!0),a=M.useCallback(()=>{i(),n()},[n,i]);return e?v.jsxs(zr,{role:"alert",className:be("tw:w-[700px] tw:max-w-[calc(100%-30px)]","tw:fixed tw:top-[35px] tw:left-[50%] tw:translate-x-[-50%] tw:z-[1040]"),children:[v.jsxs(zr.Header,{className:"tw:flex tw:items-center tw:justify-between",children:[v.jsx("h5",{children:"This app has just been updated!"}),v.jsx(oE,{onClick:t})]}),v.jsxs(zr.Body,{className:"tw:flex tw:gap-4 tw:items-center tw:justify-between tw:max-md:flex-col",children:["Restart it to enjoy the new features.",v.jsxs(Pi,{disabled:r,variant:"secondary",solid:!0,onClick:a,children:[!r&&v.jsxs(v.Fragment,{children:["Restart now ",v.jsx(Ye,{icon:vX})]}),r&&v.jsx(v.Fragment,{children:"Restarting..."})]})]})]}):null},tB=({children:e,title:t})=>v.jsx("div",{className:"tw:pt-4",children:v.jsxs(Ub,{className:"tw:p-4 tw:w-full tw:lg:w-[65%] tw:m-auto",children:[v.jsx("h2",{children:t}),e]})}),nB=({to:e="/",children:t="Home"})=>v.jsxs(tB,{title:"Oops! We could not find requested route.",children:[v.jsx("p",{children:"Use your browser's back button to navigate to the page you have previously come from, or just press this button."}),v.jsx("br",{}),v.jsx(Pi,{inline:!0,to:e,size:"lg",children:t})]});function ja(e){return M.useMemo(()=>e,[e])}function Pa(e,t){return(n,r=globalThis.console)=>(t.forEach(i=>{const a=n[i];e[i]=a}),e)}const Qte=async()=>{var t;(await((t=navigator.serviceWorker)==null?void 0:t.getRegistrations())??[]).forEach(({waiting:n})=>{n==null||n.addEventListener("statechange",r=>{var i;((i=r.target)==null?void 0:i.state)==="activated"&&window.location.reload()}),n==null||n.postMessage({type:"SKIP_WAITING"})})},rB=({fetchServers:e,servers:t,settings:n,appUpdated:r,resetAppUpdate:i})=>{var S;const{MainHeader:a,Home:o,ShlinkWebComponentContainer:l,CreateServer:f,EditServer:u,Settings:h,ManageServers:m,ShlinkVersionsContainer:g}=ja(rB),_=Sr(),x=M.useRef(t),b=_.pathname==="/";return M.useEffect(()=>{Object.keys(x.current).length===0&&e()},[e]),M.useEffect(()=>{var C;eee(((C=n.ui)==null?void 0:C.theme)??RT())},[(S=n.ui)==null?void 0:S.theme]),v.jsxs("div",{className:"tw:h-full",children:[v.jsx(a,{}),v.jsxs("div",{className:"tw:h-full tw:pt-(--tw-header-height)",children:[v.jsx("div",{"data-testid":"shlink-wrapper",className:be("tw:min-h-full tw:pb-[calc(var(--footer-height)+var(--footer-margin))] tw:-mb-[calc(var(--footer-height)+var(--footer-margin))]",{"tw:flex tw:items-center tw:pt-4":b}),children:v.jsxs(Sb,{children:[v.jsx(xt,{index:!0,element:v.jsx(o,{})}),v.jsx(xt,{path:"/settings",children:["","*"].map(C=>v.jsx(xt,{path:C,element:v.jsx(h,{})},C))}),v.jsx(xt,{path:"/manage-servers",element:v.jsx(m,{})}),v.jsx(xt,{path:"/server/create",element:v.jsx(f,{})}),v.jsx(xt,{path:"/server/:serverId/edit",element:v.jsx(u,{})}),v.jsx(xt,{path:"/server/:serverId",children:["","*"].map(C=>v.jsx(xt,{path:C,element:v.jsx(l,{})},C))}),v.jsx(xt,{path:"*",element:v.jsx(nB,{})})]})}),v.jsx("div",{className:"tw:h-(--footer-height) tw:mt-(--footer-margin) tw:md:px-4",children:v.jsx(g,{})})]}),v.jsx(Xte,{isOpen:r,onClose:i,forceUpdate:Qte})]})},Jte=Pa(rB,["MainHeader","Home","ShlinkWebComponentContainer","CreateServer","EditServer","Settings","ManageServers","ShlinkVersionsContainer"]);function yr(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var ene=typeof Symbol=="function"&&Symbol.observable||"@@observable",JM=ene,lx=()=>Math.random().toString(36).substring(7).split("").join("."),tne={INIT:`@@redux/INIT${lx()}`,REPLACE:`@@redux/REPLACE${lx()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${lx()}`},Zy=tne;function BT(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function iB(e,t,n){if(typeof e!="function")throw new Error(yr(2));if(typeof t=="function"&&typeof n=="function"||typeof n=="function"&&typeof arguments[3]=="function")throw new Error(yr(0));if(typeof t=="function"&&typeof n>"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(yr(1));return n(iB)(e,t)}let r=e,i=t,a=new Map,o=a,l=0,f=!1;function u(){o===a&&(o=new Map,a.forEach((S,C)=>{o.set(C,S)}))}function h(){if(f)throw new Error(yr(3));return i}function m(S){if(typeof S!="function")throw new Error(yr(4));if(f)throw new Error(yr(5));let C=!0;u();const A=l++;return o.set(A,S),function(){if(C){if(f)throw new Error(yr(6));C=!1,u(),o.delete(A),a=null}}}function g(S){if(!BT(S))throw new Error(yr(7));if(typeof S.type>"u")throw new Error(yr(8));if(typeof S.type!="string")throw new Error(yr(17));if(f)throw new Error(yr(9));try{f=!0,i=r(i,S)}finally{f=!1}return(a=o).forEach(A=>{A()}),S}function _(S){if(typeof S!="function")throw new Error(yr(10));r=S,g({type:Zy.REPLACE})}function x(){const S=m;return{subscribe(C){if(typeof C!="object"||C===null)throw new Error(yr(11));function A(){const P=C;P.next&&P.next(h())}return A(),{unsubscribe:S(A)}},[JM](){return this}}}return g({type:Zy.INIT}),{dispatch:g,subscribe:m,getState:h,replaceReducer:_,[JM]:x}}function nne(e){Object.keys(e).forEach(t=>{const n=e[t];if(typeof n(void 0,{type:Zy.INIT})>"u")throw new Error(yr(12));if(typeof n(void 0,{type:Zy.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(yr(13))})}function UT(e){const t=Object.keys(e),n={};for(let a=0;a<t.length;a++){const o=t[a];typeof e[o]=="function"&&(n[o]=e[o])}const r=Object.keys(n);let i;try{nne(n)}catch(a){i=a}return function(o={},l){if(i)throw i;let f=!1;const u={};for(let h=0;h<r.length;h++){const m=r[h],g=n[m],_=o[m],x=g(_,l);if(typeof x>"u")throw l&&l.type,new Error(yr(14));u[m]=x,f=f||x!==_}return f=f||r.length!==Object.keys(o).length,f?u:o}}function Xy(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,n)=>(...r)=>t(n(...r)))}function rne(...e){return t=>(n,r)=>{const i=t(n,r);let a=()=>{throw new Error(yr(15))};const o={getState:i.getState,dispatch:(f,...u)=>a(f,...u)},l=e.map(f=>f(o));return a=Xy(...l)(i.dispatch),{...i,dispatch:a}}}function ine(e){return BT(e)&&"type"in e&&typeof e.type=="string"}var aB=Symbol.for("immer-nothing"),e6=Symbol.for("immer-draftable"),Ri=Symbol.for("immer-state");function ba(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Ff=Object.getPrototypeOf;function Ju(e){return!!e&&!!e[Ri]}function as(e){var t;return e?oB(e)||Array.isArray(e)||!!e[e6]||!!((t=e.constructor)!=null&&t[e6])||qb(e)||Vb(e):!1}var ane=Object.prototype.constructor.toString();function oB(e){if(!e||typeof e!="object")return!1;const t=Ff(e);if(t===null)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object?!0:typeof n=="function"&&Function.toString.call(n)===ane}function Qp(e,t){Fb(e)===0?Object.entries(e).forEach(([n,r])=>{t(n,r,e)}):e.forEach((n,r)=>t(r,n,e))}function Fb(e){const t=e[Ri];return t?t.type_:Array.isArray(e)?1:qb(e)?2:Vb(e)?3:0}function lE(e,t){return Fb(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function sB(e,t,n){const r=Fb(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function one(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function qb(e){return e instanceof Map}function Vb(e){return e instanceof Set}function Mu(e){return e.copy_||e.base_}function uE(e,t){if(qb(e))return new Map(e);if(Vb(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);if(!t&&oB(e))return Ff(e)?{...e}:Object.assign(Object.create(null),e);const n=Object.getOwnPropertyDescriptors(e);delete n[Ri];let r=Reflect.ownKeys(n);for(let i=0;i<r.length;i++){const a=r[i],o=n[a];o.writable===!1&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(n[a]={configurable:!0,writable:!0,enumerable:o.enumerable,value:e[a]})}return Object.create(Ff(e),n)}function zT(e,t=!1){return Hb(e)||Ju(e)||!as(e)||(Fb(e)>1&&(e.set=e.add=e.clear=e.delete=sne),Object.freeze(e),t&&Qp(e,(n,r)=>zT(r,!0))),e}function sne(){ba(2)}function Hb(e){return Object.isFrozen(e)}var lne={};function ec(e){const t=lne[e];return t||ba(0,e),t}var Jp;function lB(){return Jp}function une(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function t6(e,t){t&&(ec("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function cE(e){fE(e),e.drafts_.forEach(cne),e.drafts_=null}function fE(e){e===Jp&&(Jp=e.parent_)}function n6(e){return Jp=une(Jp,e)}function cne(e){const t=e[Ri];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function r6(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[Ri].modified_&&(cE(t),ba(4)),as(e)&&(e=Qy(t,e),t.parent_||Jy(t,e)),t.patches_&&ec("Patches").generateReplacementPatches_(n[Ri].base_,e,t.patches_,t.inversePatches_)):e=Qy(t,n,[]),cE(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==aB?e:void 0}function Qy(e,t,n){if(Hb(t))return t;const r=t[Ri];if(!r)return Qp(t,(i,a)=>i6(e,r,t,i,a,n)),t;if(r.scope_!==e)return t;if(!r.modified_)return Jy(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const i=r.copy_;let a=i,o=!1;r.type_===3&&(a=new Set(i),i.clear(),o=!0),Qp(a,(l,f)=>i6(e,r,i,l,f,n,o)),Jy(e,i,!1),n&&e.patches_&&ec("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function i6(e,t,n,r,i,a,o){if(Ju(i)){const l=a&&t&&t.type_!==3&&!lE(t.assigned_,r)?a.concat(r):void 0,f=Qy(e,i,l);if(sB(n,r,f),Ju(f))e.canAutoFreeze_=!1;else return}else o&&n.add(i);if(as(i)&&!Hb(i)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Qy(e,i),(!t||!t.scope_.parent_)&&Jy(e,i)}}function Jy(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&zT(t,n)}function fne(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:lB(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=r,a=FT;n&&(i=[r],a=em);const{revoke:o,proxy:l}=Proxy.revocable(i,a);return r.draft_=l,r.revoke_=o,l}var FT={get(e,t){if(t===Ri)return e;const n=Mu(e);if(!lE(n,t))return dne(e,n,t);const r=n[t];return e.finalized_||!as(r)?r:r===ux(e.base_,t)?(cx(e),e.copy_[t]=hE(r,e)):r},has(e,t){return t in Mu(e)},ownKeys(e){return Reflect.ownKeys(Mu(e))},set(e,t,n){const r=uB(Mu(e),t);if(r!=null&&r.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=ux(Mu(e),t),a=i==null?void 0:i[Ri];if(a&&a.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(one(n,i)&&(n!==void 0||lE(e.base_,t)))return!0;cx(e),dE(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return ux(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,cx(e),dE(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=Mu(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){ba(11)},getPrototypeOf(e){return Ff(e.base_)},setPrototypeOf(){ba(12)}},em={};Qp(FT,(e,t)=>{em[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});em.deleteProperty=function(e,t){return em.set.call(this,e,t,void 0)};em.set=function(e,t,n){return FT.set.call(this,e[0],t,n,e[0])};function ux(e,t){const n=e[Ri];return(n?Mu(n):e)[t]}function dne(e,t,n){var i;const r=uB(t,n);return r?"value"in r?r.value:(i=r.get)==null?void 0:i.call(e.draft_):void 0}function uB(e,t){if(!(t in e))return;let n=Ff(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Ff(n)}}function dE(e){e.modified_||(e.modified_=!0,e.parent_&&dE(e.parent_))}function cx(e){e.copy_||(e.copy_=uE(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var hne=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const a=n;n=t;const o=this;return function(f=a,...u){return o.produce(f,h=>n.call(this,h,...u))}}typeof n!="function"&&ba(6),r!==void 0&&typeof r!="function"&&ba(7);let i;if(as(t)){const a=n6(this),o=hE(t,void 0);let l=!0;try{i=n(o),l=!1}finally{l?cE(a):fE(a)}return t6(a,r),r6(i,a)}else if(!t||typeof t!="object"){if(i=n(t),i===void 0&&(i=t),i===aB&&(i=void 0),this.autoFreeze_&&zT(i,!0),r){const a=[],o=[];ec("Patches").generateReplacementPatches_(t,i,a,o),r(a,o)}return i}else ba(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(o,...l)=>this.produceWithPatches(o,f=>t(f,...l));let r,i;return[this.produce(t,n,(o,l)=>{r=o,i=l}),r,i]},typeof(e==null?void 0:e.autoFreeze)=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof(e==null?void 0:e.useStrictShallowCopy)=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){as(e)||ba(8),Ju(e)&&(e=pne(e));const t=n6(this),n=hE(e,void 0);return n[Ri].isManual_=!0,fE(t),n}finishDraft(e,t){const n=e&&e[Ri];(!n||!n.isManual_)&&ba(9);const{scope_:r}=n;return t6(r,t),r6(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}n>-1&&(t=t.slice(n+1));const r=ec("Patches").applyPatches_;return Ju(e)?r(e,t):this.produce(e,i=>r(i,t))}};function hE(e,t){const n=qb(e)?ec("MapSet").proxyMap_(e,t):Vb(e)?ec("MapSet").proxySet_(e,t):fne(e,t);return(t?t.scope_:lB()).drafts_.push(n),n}function pne(e){return Ju(e)||ba(10,e),cB(e)}function cB(e){if(!as(e)||Hb(e))return e;const t=e[Ri];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=uE(e,t.scope_.immer_.useStrictShallowCopy_)}else n=uE(e,!0);return Qp(n,(r,i)=>{sB(n,r,cB(i))}),t&&(t.finalized_=!1),n}var Mi=new hne,fB=Mi.produce;Mi.produceWithPatches.bind(Mi);Mi.setAutoFreeze.bind(Mi);Mi.setUseStrictShallowCopy.bind(Mi);Mi.applyPatches.bind(Mi);Mi.createDraft.bind(Mi);Mi.finishDraft.bind(Mi);function dB(e){return({dispatch:n,getState:r})=>i=>a=>typeof a=="function"?a(n,r,e):i(a)}var mne=dB(),gne=dB,vne=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?Xy:Xy.apply(null,arguments)},yne=e=>e&&typeof e.match=="function";function Hr(e,t){function n(...r){if(t){let i=t(...r);if(!i)throw new Error(Qo(0));return{type:e,payload:i.payload,..."meta"in i&&{meta:i.meta},..."error"in i&&{error:i.error}}}return{type:e,payload:r[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=r=>ine(r)&&r.type===e,n}var hB=class bp extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,bp.prototype)}static get[Symbol.species](){return bp}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new bp(...t[0].concat(this)):new bp(...t.concat(this))}};function a6(e){return as(e)?fB(e,()=>{}):e}function Kv(e,t,n){return e.has(t)?e.get(t):e.set(t,n(t)).get(t)}function bne(e){return typeof e=="boolean"}var wne=()=>function(t){const{thunk:n=!0,immutableCheck:r=!0,serializableCheck:i=!0,actionCreatorCheck:a=!0}=t??{};let o=new hB;return n&&(bne(n)?o.push(mne):o.push(gne(n.extraArgument))),o},_ne="RTK_autoBatch",o6=e=>t=>{setTimeout(t,e)},xne=(e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let i=!0,a=!1,o=!1;const l=new Set,f=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:o6(10):e.type==="callback"?e.queueNotification:o6(e.timeout),u=()=>{o=!1,a&&(a=!1,l.forEach(h=>h()))};return Object.assign({},r,{subscribe(h){const m=()=>i&&h(),g=r.subscribe(m);return l.add(h),()=>{g(),l.delete(h)}},dispatch(h){var m;try{return i=!((m=h==null?void 0:h.meta)!=null&&m[_ne]),a=!i,a&&(o||(o=!0,f(u))),r.dispatch(h)}finally{i=!0}}})},Sne=e=>function(n){const{autoBatch:r=!0}=n??{};let i=new hB(e);return r&&i.push(xne(typeof r=="object"?r:void 0)),i};function pB(e){const t=wne(),{reducer:n=void 0,middleware:r,devTools:i=!0,duplicateMiddlewareCheck:a=!0,preloadedState:o=void 0,enhancers:l=void 0}=e||{};let f;if(typeof n=="function")f=n;else if(BT(n))f=UT(n);else throw new Error(Qo(1));let u;typeof r=="function"?u=r(t):u=t();let h=Xy;i&&(h=vne({trace:!1,...typeof i=="object"&&i}));const m=rne(...u),g=Sne(m);let _=typeof l=="function"?l(g):g();const x=h(..._);return iB(f,o,x)}function mB(e){const t={},n=[];let r;const i={addCase(a,o){const l=typeof a=="string"?a:a.type;if(!l)throw new Error(Qo(28));if(l in t)throw new Error(Qo(29));return t[l]=o,i},addMatcher(a,o){return n.push({matcher:a,reducer:o}),i},addDefaultCase(a){return r=a,i}};return e(i),[t,n,r]}function Cne(e){return typeof e=="function"}function Ane(e,t){let[n,r,i]=mB(t),a;if(Cne(e))a=()=>a6(e());else{const l=a6(e);a=()=>l}function o(l=a(),f){let u=[n[f.type],...r.filter(({matcher:h})=>h(f)).map(({reducer:h})=>h)];return u.filter(h=>!!h).length===0&&(u=[i]),u.reduce((h,m)=>{if(m)if(Ju(h)){const _=m(h,f);return _===void 0?h:_}else{if(as(h))return fB(h,g=>m(g,f));{const g=m(h,f);if(g===void 0){if(h===null)return h;throw Error("A case reducer on a non-draftable value must not return undefined")}return g}}return h},l)}return o.getInitialState=a,o}var Ene=(e,t)=>yne(e)?e.match(t):e(t);function One(...e){return t=>e.some(n=>Ene(n,t))}var Tne="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",jne=(e=21)=>{let t="",n=e;for(;n--;)t+=Tne[Math.random()*64|0];return t},Pne=["name","message","stack","code"],fx=class{constructor(e,t){lf(this,"_type");this.payload=e,this.meta=t}},s6=class{constructor(e,t){lf(this,"_type");this.payload=e,this.meta=t}},Rne=e=>{if(typeof e=="object"&&e!==null){const t={};for(const n of Pne)typeof e[n]=="string"&&(t[n]=e[n]);return t}return{message:String(e)}},l6="External signal was aborted",gB=(()=>{function e(t,n,r){const i=Hr(t+"/fulfilled",(f,u,h,m)=>({payload:f,meta:{...m||{},arg:h,requestId:u,requestStatus:"fulfilled"}})),a=Hr(t+"/pending",(f,u,h)=>({payload:void 0,meta:{...h||{},arg:u,requestId:f,requestStatus:"pending"}})),o=Hr(t+"/rejected",(f,u,h,m,g)=>({payload:m,error:(r&&r.serializeError||Rne)(f||"Rejected"),meta:{...g||{},arg:h,requestId:u,rejectedWithValue:!!m,requestStatus:"rejected",aborted:(f==null?void 0:f.name)==="AbortError",condition:(f==null?void 0:f.name)==="ConditionError"}}));function l(f,{signal:u}={}){return(h,m,g)=>{const _=r!=null&&r.idGenerator?r.idGenerator(f):jne(),x=new AbortController;let b,S;function C(O){S=O,x.abort()}u&&(u.aborted?C(l6):u.addEventListener("abort",()=>C(l6),{once:!0}));const A=async function(){var j,R;let O;try{let U=(j=r==null?void 0:r.condition)==null?void 0:j.call(r,f,{getState:m,extra:g});if(Nne(U)&&(U=await U),U===!1||x.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};const V=new Promise((Y,K)=>{b=()=>{K({name:"AbortError",message:S||"Aborted"})},x.signal.addEventListener("abort",b)});h(a(_,f,(R=r==null?void 0:r.getPendingMeta)==null?void 0:R.call(r,{requestId:_,arg:f},{getState:m,extra:g}))),O=await Promise.race([V,Promise.resolve(n(f,{dispatch:h,getState:m,extra:g,requestId:_,signal:x.signal,abort:C,rejectWithValue:(Y,K)=>new fx(Y,K),fulfillWithValue:(Y,K)=>new s6(Y,K)})).then(Y=>{if(Y instanceof fx)throw Y;return Y instanceof s6?i(Y.payload,_,f,Y.meta):i(Y,_,f)})])}catch(U){O=U instanceof fx?o(null,_,f,U.payload,U.meta):o(U,_,f)}finally{b&&x.signal.removeEventListener("abort",b)}return r&&!r.dispatchConditionRejection&&o.match(O)&&O.meta.condition||h(O),O}();return Object.assign(A,{abort:C,requestId:_,arg:f,unwrap(){return A.then(Mne)}})}}return Object.assign(l,{pending:a,rejected:o,fulfilled:i,settled:One(o,i),typePrefix:t})}return e.withTypes=()=>e,e})();function Mne(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function Nne(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var Lne=Symbol.for("rtk-slice-createasyncthunk");function kne(e,t){return`${e}/${t}`}function Dne({creators:e}={}){var n;const t=(n=e==null?void 0:e.asyncThunk)==null?void 0:n[Lne];return function(i){const{name:a,reducerPath:o=a}=i;if(!a)throw new Error(Qo(11));const l=(typeof i.reducers=="function"?i.reducers($ne()):i.reducers)||{},f=Object.keys(l),u={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},h={addCase(P,j){const R=typeof P=="string"?P:P.type;if(!R)throw new Error(Qo(12));if(R in u.sliceCaseReducersByType)throw new Error(Qo(13));return u.sliceCaseReducersByType[R]=j,h},addMatcher(P,j){return u.sliceMatchers.push({matcher:P,reducer:j}),h},exposeAction(P,j){return u.actionCreators[P]=j,h},exposeCaseReducer(P,j){return u.sliceCaseReducersByName[P]=j,h}};f.forEach(P=>{const j=l[P],R={reducerName:P,type:kne(a,P),createNotation:typeof i.reducers=="function"};Une(j)?Fne(R,j,h,t):Bne(R,j,h)});function m(){const[P={},j=[],R=void 0]=typeof i.extraReducers=="function"?mB(i.extraReducers):[i.extraReducers],U={...P,...u.sliceCaseReducersByType};return Ane(i.initialState,V=>{for(let Y in U)V.addCase(Y,U[Y]);for(let Y of u.sliceMatchers)V.addMatcher(Y.matcher,Y.reducer);for(let Y of j)V.addMatcher(Y.matcher,Y.reducer);R&&V.addDefaultCase(R)})}const g=P=>P,_=new Map,x=new WeakMap;let b;function S(P,j){return b||(b=m()),b(P,j)}function C(){return b||(b=m()),b.getInitialState()}function A(P,j=!1){function R(V){let Y=V[P];return typeof Y>"u"&&j&&(Y=Kv(x,R,C)),Y}function U(V=g){const Y=Kv(_,j,()=>new WeakMap);return Kv(Y,V,()=>{const K={};for(const[W,ee]of Object.entries(i.selectors??{}))K[W]=Ine(ee,V,()=>Kv(x,V,C),j);return K})}return{reducerPath:P,getSelectors:U,get selectors(){return U(R)},selectSlice:R}}const O={name:a,reducer:S,actions:u.actionCreators,caseReducers:u.sliceCaseReducersByName,getInitialState:C,...A(o),injectInto(P,{reducerPath:j,...R}={}){const U=j??o;return P.inject({reducerPath:U,reducer:S},R),{...O,...A(U,!0)}}};return O}}function Ine(e,t,n,r){function i(a,...o){let l=t(a);return typeof l>"u"&&r&&(l=n()),e(l,...o)}return i.unwrapped=e,i}var Dn=Dne();function $ne(){function e(t,n){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...n}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...n){return t(...n)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,n){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:n}},asyncThunk:e}}function Bne({type:e,reducerName:t,createNotation:n},r,i){let a,o;if("reducer"in r){if(n&&!zne(r))throw new Error(Qo(17));a=r.reducer,o=r.prepare}else a=r;i.addCase(e,a).exposeCaseReducer(t,a).exposeAction(t,o?Hr(e,o):Hr(e))}function Une(e){return e._reducerDefinitionType==="asyncThunk"}function zne(e){return e._reducerDefinitionType==="reducerWithPrepare"}function Fne({type:e,reducerName:t},n,r,i){if(!i)throw new Error(Qo(18));const{payloadCreator:a,fulfilled:o,pending:l,rejected:f,settled:u,options:h}=n,m=i(e,a,h);r.exposeAction(t,m),o&&r.addCase(m.fulfilled,o),l&&r.addCase(m.pending,l),f&&r.addCase(m.rejected,f),u&&r.addMatcher(m.settled,u),r.exposeCaseReducer(t,{fulfilled:o||Zv,pending:l||Zv,rejected:f||Zv,settled:u||Zv})}function Zv(){}function Qo(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}const{actions:qne,reducer:Vne}=Dn({name:"shlink/appUpdates",initialState:!1,reducers:{appUpdateAvailable:()=>!0,resetAppUpdate:()=>!1}}),{appUpdateAvailable:Hne,resetAppUpdate:Gne}=qne,Wne=Vne,Yne=(e,t)=>{e.factory("App",Jte),e.decorator("App",t(["servers","settings","appUpdated"],["fetchServers","resetAppUpdate"])),e.serviceFactory("appUpdateAvailable",()=>Hne),e.serviceFactory("resetAppUpdate",()=>Gne)};var vB=e=>{throw TypeError(e)},yB=(e,t,n)=>t.has(e)||vB("Cannot "+n),u6=(e,t,n)=>(yB(e,t,"read from private field"),n?n.call(e):t.get(e)),Kne=(e,t,n)=>t.has(e)?vB("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Zne=(e,t,n,r)=>(yB(e,t,"write to private field"),t.set(e,n),n);const c6={"Content-Type":"application/json"},f6=e=>e!=null&&e.body?e?{...e,headers:{...e.headers??{},...c6}}:{headers:c6}:e;var wp;let Xne=class{constructor(t=globalThis.fetch.bind(globalThis)){Kne(this,wp),Zne(this,wp,t)}async jsonRequest(t,n){const r=await u6(this,wp).call(this,t,f6(n)),i=await r.json();if(!r.ok)throw i;return i}async emptyRequest(t,n){const r=await u6(this,wp).call(this,t,f6(n));if(!r.ok)throw await r.json()}};wp=new WeakMap;const bB=(e,t)=>e.reduce((n,r)=>{const i=t(r);return n[i]=(n[i]||0)+1,n},{}),wB=(e,t)=>e.reduce((n,r)=>{const i=t(r);return(n[i]=n[i]||[]).push(r),n},{}),dx=e=>Object.prototype.toString.call(e)==="[object Object]",_B=(e,t)=>{const n={};return(...r)=>{const i=e(...r);if(n[i])return n[i];const a=t(...r);return n[i]=a,a}},Gb=(e,t)=>{const n={...e};return!dx(e)||!dx(t)||Object.keys(t).forEach(r=>{dx(t[r])?n[r]=r in e&&e[r]!==void 0?Gb(e[r],t[r]):{...t[r]}:n[r]=t[r]}),n},xB=(e,t)=>Array.from({length:t-e},(n,r)=>e+r),Qne=(e,t)=>[...e].sort((n,r)=>{const i=t(n),a=t(r);return i===a?0:i<a?-1:1}),Mf=(e,t)=>{const n=[];for(let r=0;r<e.length;r+=t)n.push(e.slice(r,r+t));return n},d6=(e,t)=>Object.fromEntries(e.map((n,r)=>[n,t[r]]));function Jne(e,{elementsSelector:t,focusFirstItem:n=!1,vertical:r=!0,horizontal:i=!0}){const a=M.useMemo(()=>{const f=[];return r&&f.push("ArrowDown"),i&&f.push("ArrowRight"),f},[i,r]),o=M.useMemo(()=>{const f=[];return r&&f.push("ArrowUp"),i&&f.push("ArrowLeft"),f},[i,r]),l=M.useMemo(()=>[...a,...o],[a,o]);M.useEffect(()=>{const f=e.current;if(!f)return()=>{};const u=new AbortController,h=()=>[...f.querySelectorAll(t)],m=h(),g=Math.max(m.findIndex(_=>_.dataset.selected==="true"),0);return m.forEach((_,x)=>{_.tabIndex=x===g?0:-1,n&&x===g&&_.focus()}),f.addEventListener("keydown",_=>{if(!l.includes(_.key))return;_.preventDefault();const x=h(),b=x.findIndex(C=>C.tabIndex===0),S=a.includes(_.key)?x[b+1]??x[0]:x[b-1]??x[x.length-1];x.forEach(C=>{C.tabIndex=-1}),S.tabIndex=0,S.focus()},{signal:u.signal}),()=>u.abort()},[l,e,t,n,a])}const ere=128;function tre(e){const[t,n,r]=(e.match(/../g)??[]).map(i=>parseInt(i,16)||0);return Math.round(Math.sqrt(.299*t**2+.587*n**2+.114*r**2))>=ere}function SB(e,t=globalThis.setTimeout,n=globalThis.clearTimeout){const r=M.useRef(null),i=M.useCallback(()=>{r.current&&n(r.current)},[n]),a=M.useCallback((o,l)=>{i(),r.current=t(()=>{o(),r.current=null},l??e)},[i,e,t]);return M.useEffect(()=>i,[i]),M.useMemo(()=>({setTimeout:a,clearCurrentTimeout:i}),[i,a])}const nre=2e3,rre=(e={},t,n=globalThis.setTimeout,r=globalThis.clearTimeout)=>{const{initialValue:i=!1,delay:a=nre}=typeof e=="boolean"?{initialValue:e,delay:t}:e,{setTimeout:o}=SB(a,n,r),[l,f]=M.useState(i),u=M.useRef(i),h=M.useCallback(()=>{f(!u.current),o(()=>f(u.current))},[o]);return[l,h]};function ire(e=!1,t=!1){const[n,r]=M.useState(e),i=M.useCallback(()=>r(l=>!l),[]),a=M.useCallback(()=>r(!0),[]),o=M.useCallback(()=>r(!1),[]);return t?{flag:n,toggle:i,setToTrue:a,setToFalse:o}:[n,i,a,o]}function CB(e,t,n){if(!e||typeof e=="string")return CB({currentField:e,newField:t,currentOrderDir:n});const r=e;if(r.currentField!==r.newField)return"ASC";const i={ASC:"DESC",DESC:void 0};return r.currentOrderDir?i[r.currentOrderDir]:"ASC"}function AB(e,t,n){if(!e||typeof e=="string")return AB({currentField:e,newField:t,currentOrderDir:n});const r=e,i=CB(r);return{field:i?r.newField:void 0,dir:i}}function Wb(){return typeof window<"u"}function Nd(e){return EB(e)?(e.nodeName||"").toLowerCase():"#document"}function Ai(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function ds(e){var t;return(t=(EB(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function EB(e){return Wb()?e instanceof Node||e instanceof Ai(e).Node:!1}function _r(e){return Wb()?e instanceof Element||e instanceof Ai(e).Element:!1}function Ni(e){return Wb()?e instanceof HTMLElement||e instanceof Ai(e).HTMLElement:!1}function pE(e){return!Wb()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ai(e).ShadowRoot}function ng(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Ea(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function are(e){return["table","td","th"].includes(Nd(e))}function Yb(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function qT(e){const t=VT(),n=_r(e)?Ea(e):e;return["transform","translate","scale","rotate","perspective"].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)||["transform","translate","scale","rotate","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function ore(e){let t=kl(e);for(;Ni(t)&&!qf(t);){if(qT(t))return t;if(Yb(t))return null;t=kl(t)}return null}function VT(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function qf(e){return["html","body","#document"].includes(Nd(e))}function Ea(e){return Ai(e).getComputedStyle(e)}function Kb(e){return _r(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function kl(e){if(Nd(e)==="html")return e;const t=e.assignedSlot||e.parentNode||pE(e)&&e.host||ds(e);return pE(t)?t.host:t}function OB(e){const t=kl(e);return qf(t)?e.ownerDocument?e.ownerDocument.body:e.body:Ni(t)&&ng(t)?t:OB(t)}function TB(e,t,n){var r;t===void 0&&(t=[]);const i=OB(e),a=i===((r=e.ownerDocument)==null?void 0:r.body),o=Ai(i);return a?(mE(o),t.concat(o,o.visualViewport||[],ng(i)?i:[],[])):t.concat(i,TB(i,[]))}function mE(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const sre=["top","right","bottom","left"],h6=["start","end"],p6=sre.reduce((e,t)=>e.concat(t,t+"-"+h6[0],t+"-"+h6[1]),[]),tm=Math.min,Nf=Math.max,e0=Math.round,ro=e=>({x:e,y:e}),lre={left:"right",right:"left",bottom:"top",top:"bottom"},ure={start:"end",end:"start"};function cre(e,t,n){return Nf(e,tm(t,n))}function rg(e,t){return typeof e=="function"?e(t):e}function Dl(e){return e.split("-")[0]}function io(e){return e.split("-")[1]}function fre(e){return e==="x"?"y":"x"}function HT(e){return e==="y"?"height":"width"}function zu(e){return["top","bottom"].includes(Dl(e))?"y":"x"}function GT(e){return fre(zu(e))}function jB(e,t,n){n===void 0&&(n=!1);const r=io(e),i=GT(e),a=HT(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(o=n0(o)),[o,n0(o)]}function dre(e){const t=n0(e);return[t0(e),t,t0(t)]}function t0(e){return e.replace(/start|end/g,t=>ure[t])}function hre(e,t,n){const r=["left","right"],i=["right","left"],a=["top","bottom"],o=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?a:o;default:return[]}}function pre(e,t,n,r){const i=io(e);let a=hre(Dl(e),n==="start",r);return i&&(a=a.map(o=>o+"-"+i),t&&(a=a.concat(a.map(t0)))),a}function n0(e){return e.replace(/left|right|bottom|top/g,t=>lre[t])}function mre(e){return{top:0,right:0,bottom:0,left:0,...e}}function PB(e){return typeof e!="number"?mre(e):{top:e,right:e,bottom:e,left:e}}function r0(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}}const gre="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function vre(e,t){if(!e||!t)return!1;const n=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&pE(n)){let r=t;for(;r;){if(e===r)return!0;r=r.parentNode||r.host}}return!1}function Xv(e){return(e==null?void 0:e.ownerDocument)||document}function yre(e){return Ni(e)&&e.matches(gre)}function nm(e,t){const n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}var bre=typeof document<"u",wre=function(){},Il=bre?M.useLayoutEffect:wre;const _re={..._b};function bl(e){const t=M.useRef(e);return Il(()=>{t.current=e}),t}const xre=_re.useInsertionEffect,Sre=xre||(e=>e());function _p(e){const t=M.useRef(()=>{});return Sre(()=>{t.current=e}),M.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.current==null?void 0:t.current(...r)},[])}function m6(e,t,n){let{reference:r,floating:i}=e;const a=zu(t),o=GT(t),l=HT(o),f=Dl(t),u=a==="y",h=r.x+r.width/2-i.width/2,m=r.y+r.height/2-i.height/2,g=r[l]/2-i[l]/2;let _;switch(f){case"top":_={x:h,y:r.y-i.height};break;case"bottom":_={x:h,y:r.y+r.height};break;case"right":_={x:r.x+r.width,y:m};break;case"left":_={x:r.x-i.width,y:m};break;default:_={x:r.x,y:r.y}}switch(io(t)){case"start":_[o]-=g*(n&&u?-1:1);break;case"end":_[o]+=g*(n&&u?-1:1);break}return _}const Cre=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:a=[],platform:o}=n,l=a.filter(Boolean),f=await(o.isRTL==null?void 0:o.isRTL(t));let u=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:h,y:m}=m6(u,r,f),g=r,_={},x=0;for(let b=0;b<l.length;b++){const{name:S,fn:C}=l[b],{x:A,y:O,data:P,reset:j}=await C({x:h,y:m,initialPlacement:r,placement:g,strategy:i,middlewareData:_,rects:u,platform:o,elements:{reference:e,floating:t}});h=A??h,m=O??m,_={..._,[S]:{..._[S],...P}},j&&x<=50&&(x++,typeof j=="object"&&(j.placement&&(g=j.placement),j.rects&&(u=j.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):j.rects),{x:h,y:m}=m6(u,g,f)),b=-1)}return{x:h,y:m,placement:g,strategy:i,middlewareData:_}};async function RB(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:a,rects:o,elements:l,strategy:f}=e,{boundary:u="clippingAncestors",rootBoundary:h="viewport",elementContext:m="floating",altBoundary:g=!1,padding:_=0}=rg(t,e),x=PB(_),b=l[g?m==="floating"?"reference":"floating":m],S=r0(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(b)))==null||n?b:b.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(l.floating)),boundary:u,rootBoundary:h,strategy:f})),C=m==="floating"?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,A=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l.floating)),O=await(a.isElement==null?void 0:a.isElement(A))?await(a.getScale==null?void 0:a.getScale(A))||{x:1,y:1}:{x:1,y:1},P=r0(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:C,offsetParent:A,strategy:f}):C);return{top:(S.top-P.top+x.top)/O.y,bottom:(P.bottom-S.bottom+x.bottom)/O.y,left:(S.left-P.left+x.left)/O.x,right:(P.right-S.right+x.right)/O.x}}const Are=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:a,platform:o,elements:l,middlewareData:f}=t,{element:u,padding:h=0}=rg(e,t)||{};if(u==null)return{};const m=PB(h),g={x:n,y:r},_=GT(i),x=HT(_),b=await o.getDimensions(u),S=_==="y",C=S?"top":"left",A=S?"bottom":"right",O=S?"clientHeight":"clientWidth",P=a.reference[x]+a.reference[_]-g[_]-a.floating[x],j=g[_]-a.reference[_],R=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u));let U=R?R[O]:0;(!U||!await(o.isElement==null?void 0:o.isElement(R)))&&(U=l.floating[O]||a.floating[x]);const V=P/2-j/2,Y=U/2-b[x]/2-1,K=tm(m[C],Y),W=tm(m[A],Y),ee=K,ie=U-b[x]-W,X=U/2-b[x]/2+V,ne=cre(ee,X,ie),H=!f.arrow&&io(i)!=null&&X!==ne&&a.reference[x]/2-(X<ee?K:W)-b[x]/2<0,I=H?X<ee?X-ee:X-ie:0;return{[_]:g[_]+I,data:{[_]:ne,centerOffset:X-ne-I,...H&&{alignmentOffset:I}},reset:H}}});function Ere(e,t,n){return(e?[...n.filter(r=>io(r)===e),...n.filter(r=>io(r)!==e)]:n.filter(r=>Dl(r)===r)).filter(r=>e?io(r)===e||(t?t0(r)!==r:!1):!0)}const Ore=function(e){return e===void 0&&(e={}),{name:"autoPlacement",options:e,async fn(t){var n,r,i;const{rects:a,middlewareData:o,placement:l,platform:f,elements:u}=t,{crossAxis:h=!1,alignment:m,allowedPlacements:g=p6,autoAlignment:_=!0,...x}=rg(e,t),b=m!==void 0||g===p6?Ere(m||null,_,g):g,S=await RB(t,x),C=((n=o.autoPlacement)==null?void 0:n.index)||0,A=b[C];if(A==null)return{};const O=jB(A,a,await(f.isRTL==null?void 0:f.isRTL(u.floating)));if(l!==A)return{reset:{placement:b[0]}};const P=[S[Dl(A)],S[O[0]],S[O[1]]],j=[...((r=o.autoPlacement)==null?void 0:r.overflows)||[],{placement:A,overflows:P}],R=b[C+1];if(R)return{data:{index:C+1,overflows:j},reset:{placement:R}};const U=j.map(Y=>{const K=io(Y.placement);return[Y.placement,K&&h?Y.overflows.slice(0,2).reduce((W,ee)=>W+ee,0):Y.overflows[0],Y.overflows]}).sort((Y,K)=>Y[1]-K[1]),V=((i=U.filter(Y=>Y[2].slice(0,io(Y[0])?2:3).every(K=>K<=0))[0])==null?void 0:i[0])||U[0][0];return V!==l?{data:{index:C+1,overflows:j},reset:{placement:V}}:{}}}},Tre=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:a,rects:o,initialPlacement:l,platform:f,elements:u}=t,{mainAxis:h=!0,crossAxis:m=!0,fallbackPlacements:g,fallbackStrategy:_="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:b=!0,...S}=rg(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const C=Dl(i),A=zu(l),O=Dl(l)===l,P=await(f.isRTL==null?void 0:f.isRTL(u.floating)),j=g||(O||!b?[n0(l)]:dre(l)),R=x!=="none";!g&&R&&j.push(...pre(l,b,x,P));const U=[l,...j],V=await RB(t,S),Y=[];let K=((r=a.flip)==null?void 0:r.overflows)||[];if(h&&Y.push(V[C]),m){const X=jB(i,o,P);Y.push(V[X[0]],V[X[1]])}if(K=[...K,{placement:i,overflows:Y}],!Y.every(X=>X<=0)){var W,ee;const X=(((W=a.flip)==null?void 0:W.index)||0)+1,ne=U[X];if(ne&&(!(m==="alignment"&&A!==zu(ne))||K.every(I=>I.overflows[0]>0&&zu(I.placement)===A)))return{data:{index:X,overflows:K},reset:{placement:ne}};let H=(ee=K.filter(I=>I.overflows[0]<=0).sort((I,D)=>I.overflows[1]-D.overflows[1])[0])==null?void 0:ee.placement;if(!H)switch(_){case"bestFit":{var ie;const I=(ie=K.filter(D=>{if(R){const z=zu(D.placement);return z===A||z==="y"}return!0}).map(D=>[D.placement,D.overflows.filter(z=>z>0).reduce((z,N)=>z+N,0)]).sort((D,z)=>D[1]-z[1])[0])==null?void 0:ie[0];I&&(H=I);break}case"initialPlacement":H=l;break}if(i!==H)return{reset:{placement:H}}}return{}}}};async function jre(e,t){const{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Dl(n),l=io(n),f=zu(n)==="y",u=["left","top"].includes(o)?-1:1,h=a&&f?-1:1,m=rg(t,e);let{mainAxis:g,crossAxis:_,alignmentAxis:x}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return l&&typeof x=="number"&&(_=l==="end"?x*-1:x),f?{x:_*h,y:g*u}:{x:g*u,y:_*h}}const Pre=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:a,placement:o,middlewareData:l}=t,f=await jre(t,e);return o===((n=l.offset)==null?void 0:n.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:i+f.x,y:a+f.y,data:{...f,placement:o}}}}};function MB(e){const t=Ea(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Ni(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,l=e0(n)!==a||e0(r)!==o;return l&&(n=a,r=o),{width:n,height:r,$:l}}function NB(e){return _r(e)?e:e.contextElement}function Lf(e){const t=NB(e);if(!Ni(t))return ro(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:a}=MB(t);let o=(a?e0(n.width):n.width)/r,l=(a?e0(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!l||!Number.isFinite(l))&&(l=1),{x:o,y:l}}const Rre=ro(0);function LB(e){const t=Ai(e);return!VT()||!t.visualViewport?Rre:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Mre(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ai(e)?!1:t}function rm(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),a=NB(e);let o=ro(1);t&&(r?_r(r)&&(o=Lf(r)):o=Lf(e));const l=Mre(a,n,r)?LB(a):ro(0);let f=(i.left+l.x)/o.x,u=(i.top+l.y)/o.y,h=i.width/o.x,m=i.height/o.y;if(a){const g=Ai(a),_=r&&_r(r)?Ai(r):r;let x=g,b=mE(x);for(;b&&r&&_!==x;){const S=Lf(b),C=b.getBoundingClientRect(),A=Ea(b),O=C.left+(b.clientLeft+parseFloat(A.paddingLeft))*S.x,P=C.top+(b.clientTop+parseFloat(A.paddingTop))*S.y;f*=S.x,u*=S.y,h*=S.x,m*=S.y,f+=O,u+=P,x=Ai(b),b=mE(x)}}return r0({width:h,height:m,x:f,y:u})}function WT(e,t){const n=Kb(e).scrollLeft;return t?t.left+n:rm(ds(e)).left+n}function kB(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),i=r.left+t.scrollLeft-(n?0:WT(e,r)),a=r.top+t.scrollTop;return{x:i,y:a}}function Nre(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const a=i==="fixed",o=ds(r),l=t?Yb(t.floating):!1;if(r===o||l&&a)return n;let f={scrollLeft:0,scrollTop:0},u=ro(1);const h=ro(0),m=Ni(r);if((m||!m&&!a)&&((Nd(r)!=="body"||ng(o))&&(f=Kb(r)),Ni(r))){const _=rm(r);u=Lf(r),h.x=_.x+r.clientLeft,h.y=_.y+r.clientTop}const g=o&&!m&&!a?kB(o,f,!0):ro(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-f.scrollLeft*u.x+h.x+g.x,y:n.y*u.y-f.scrollTop*u.y+h.y+g.y}}function Lre(e){return Array.from(e.getClientRects())}function kre(e){const t=ds(e),n=Kb(e),r=e.ownerDocument.body,i=Nf(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Nf(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+WT(e);const l=-n.scrollTop;return Ea(r).direction==="rtl"&&(o+=Nf(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:l}}function Dre(e,t){const n=Ai(e),r=ds(e),i=n.visualViewport;let a=r.clientWidth,o=r.clientHeight,l=0,f=0;if(i){a=i.width,o=i.height;const u=VT();(!u||u&&t==="fixed")&&(l=i.offsetLeft,f=i.offsetTop)}return{width:a,height:o,x:l,y:f}}function Ire(e,t){const n=rm(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Ni(e)?Lf(e):ro(1),o=e.clientWidth*a.x,l=e.clientHeight*a.y,f=i*a.x,u=r*a.y;return{width:o,height:l,x:f,y:u}}function g6(e,t,n){let r;if(t==="viewport")r=Dre(e,n);else if(t==="document")r=kre(ds(e));else if(_r(t))r=Ire(t,n);else{const i=LB(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return r0(r)}function DB(e,t){const n=kl(e);return n===t||!_r(n)||qf(n)?!1:Ea(n).position==="fixed"||DB(n,t)}function $re(e,t){const n=t.get(e);if(n)return n;let r=TB(e,[]).filter(l=>_r(l)&&Nd(l)!=="body"),i=null;const a=Ea(e).position==="fixed";let o=a?kl(e):e;for(;_r(o)&&!qf(o);){const l=Ea(o),f=qT(o);!f&&l.position==="fixed"&&(i=null),(a?!f&&!i:!f&&l.position==="static"&&i&&["absolute","fixed"].includes(i.position)||ng(o)&&!f&&DB(e,o))?r=r.filter(u=>u!==o):i=l,o=kl(o)}return t.set(e,r),r}function Bre(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const a=[...n==="clippingAncestors"?Yb(t)?[]:$re(t,this._c):[].concat(n),r],o=a[0],l=a.reduce((f,u)=>{const h=g6(t,u,i);return f.top=Nf(h.top,f.top),f.right=tm(h.right,f.right),f.bottom=tm(h.bottom,f.bottom),f.left=Nf(h.left,f.left),f},g6(t,o,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Ure(e){const{width:t,height:n}=MB(e);return{width:t,height:n}}function zre(e,t,n){const r=Ni(t),i=ds(t),a=n==="fixed",o=rm(e,!0,a,t);let l={scrollLeft:0,scrollTop:0};const f=ro(0);function u(){f.x=WT(i)}if(r||!r&&!a)if((Nd(t)!=="body"||ng(i))&&(l=Kb(t)),r){const _=rm(t,!0,a,t);f.x=_.x+t.clientLeft,f.y=_.y+t.clientTop}else i&&u();a&&!r&&i&&u();const h=i&&!r&&!a?kB(i,l):ro(0),m=o.left+l.scrollLeft-f.x-h.x,g=o.top+l.scrollTop-f.y-h.y;return{x:m,y:g,width:o.width,height:o.height}}function hx(e){return Ea(e).position==="static"}function v6(e,t){if(!Ni(e)||Ea(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return ds(e)===n&&(n=n.ownerDocument.body),n}function IB(e,t){const n=Ai(e);if(Yb(e))return n;if(!Ni(e)){let i=kl(e);for(;i&&!qf(i);){if(_r(i)&&!hx(i))return i;i=kl(i)}return n}let r=v6(e,t);for(;r&&are(r)&&hx(r);)r=v6(r,t);return r&&qf(r)&&hx(r)&&!qT(r)?n:r||ore(e)||n}const Fre=async function(e){const t=this.getOffsetParent||IB,n=this.getDimensions,r=await n(e.floating);return{reference:zre(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function qre(e){return Ea(e).direction==="rtl"}const Vre={convertOffsetParentRelativeRectToViewportRelativeRect:Nre,getDocumentElement:ds,getClippingRect:Bre,getOffsetParent:IB,getElementRects:Fre,getClientRects:Lre,getDimensions:Ure,getScale:Lf,isElement:_r,isRTL:qre},Hre=Pre,Gre=Ore,Wre=Tre,y6=Are,Yre=(e,t,n)=>{const r=new Map,i={platform:Vre,...n},a={...i.platform,_c:r};return Cre(e,t,{...i,platform:a})};var Kre=typeof document<"u",Zre=function(){},Py=Kre?M.useLayoutEffect:Zre;function i0(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(!i0(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 a=i[r];if(!(a==="_owner"&&e.$$typeof)&&!i0(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function $B(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function b6(e,t){const n=$B(e);return Math.round(t*n)/n}function px(e){const t=M.useRef(e);return Py(()=>{t.current=e}),t}function Xre(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:l=!0,whileElementsMounted:f,open:u}=e,[h,m]=M.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[g,_]=M.useState(r);i0(g,r)||_(r);const[x,b]=M.useState(null),[S,C]=M.useState(null),A=M.useCallback(D=>{D!==R.current&&(R.current=D,b(D))},[]),O=M.useCallback(D=>{D!==U.current&&(U.current=D,C(D))},[]),P=a||x,j=o||S,R=M.useRef(null),U=M.useRef(null),V=M.useRef(h),Y=f!=null,K=px(f),W=px(i),ee=px(u),ie=M.useCallback(()=>{if(!R.current||!U.current)return;const D={placement:t,strategy:n,middleware:g};W.current&&(D.platform=W.current),Yre(R.current,U.current,D).then(z=>{const N={...z,isPositioned:ee.current!==!1};X.current&&!i0(V.current,N)&&(V.current=N,fc.flushSync(()=>{m(N)}))})},[g,t,n,W,ee]);Py(()=>{u===!1&&V.current.isPositioned&&(V.current.isPositioned=!1,m(D=>({...D,isPositioned:!1})))},[u]);const X=M.useRef(!1);Py(()=>(X.current=!0,()=>{X.current=!1}),[]),Py(()=>{if(P&&(R.current=P),j&&(U.current=j),P&&j){if(K.current)return K.current(P,j,ie);ie()}},[P,j,ie,K,Y]);const ne=M.useMemo(()=>({reference:R,floating:U,setReference:A,setFloating:O}),[A,O]),H=M.useMemo(()=>({reference:P,floating:j}),[P,j]),I=M.useMemo(()=>{const D={position:n,left:0,top:0};if(!H.floating)return D;const z=b6(H.floating,h.x),N=b6(H.floating,h.y);return l?{...D,transform:"translate("+z+"px, "+N+"px)",...$B(H.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:z,top:N}},[n,l,H.floating,h.x,h.y]);return M.useMemo(()=>({...h,update:ie,refs:ne,elements:H,floatingStyles:I}),[h,ie,ne,H,I])}const Qre=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?y6({element:r.current,padding:i}).fn(n):{}:r?y6({element:r,padding:i}).fn(n):{}}}},Jre=(e,t)=>({...Hre(e),options:[e,t]}),eie=(e,t)=>({...Wre(e),options:[e,t]}),tie=(e,t)=>({...Gre(e),options:[e,t]}),nie=(e,t)=>({...Qre(e),options:[e,t]}),rie="data-floating-ui-focusable",w6="active",_6="selected",iie={..._b};let x6=!1,aie=0;const S6=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+aie++;function oie(){const[e,t]=M.useState(()=>x6?S6():void 0);return Il(()=>{e==null&&t(S6())},[]),M.useEffect(()=>{x6=!0},[]),e}const sie=iie.useId,lie=sie||oie;function uie(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(i=>i(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){var r;(r=e.get(t))==null||r.delete(n)}}}const cie=M.createContext(null),fie=M.createContext(null),BB=()=>{var e;return((e=M.useContext(cie))==null?void 0:e.id)||null},UB=()=>M.useContext(fie);function die(e){return"data-floating-ui-"+e}function pa(e){e.current!==-1&&(clearTimeout(e.current),e.current=-1)}const C6=die("safe-polygon");function mx(e,t,n){if(n&&!nm(n))return 0;if(typeof e=="number")return e;if(typeof e=="function"){const r=e();return typeof r=="number"?r:r==null?void 0:r[t]}return e==null?void 0:e[t]}function gx(e){return typeof e=="function"?e():e}function hie(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,dataRef:i,events:a,elements:o}=e,{enabled:l=!0,delay:f=0,handleClose:u=null,mouseOnly:h=!1,restMs:m=0,move:g=!0}=t,_=UB(),x=BB(),b=bl(u),S=bl(f),C=bl(n),A=bl(m),O=M.useRef(),P=M.useRef(-1),j=M.useRef(),R=M.useRef(-1),U=M.useRef(!0),V=M.useRef(!1),Y=M.useRef(()=>{}),K=M.useRef(!1),W=_p(()=>{var I;const D=(I=i.current.openEvent)==null?void 0:I.type;return(D==null?void 0:D.includes("mouse"))&&D!=="mousedown"});M.useEffect(()=>{if(!l)return;function I(D){let{open:z}=D;z||(pa(P),pa(R),U.current=!0,K.current=!1)}return a.on("openchange",I),()=>{a.off("openchange",I)}},[l,a]),M.useEffect(()=>{if(!l||!b.current||!n)return;function I(z){W()&&r(!1,z,"hover")}const D=Xv(o.floating).documentElement;return D.addEventListener("mouseleave",I),()=>{D.removeEventListener("mouseleave",I)}},[o.floating,n,r,l,b,W]);const ee=M.useCallback(function(I,D,z){D===void 0&&(D=!0),z===void 0&&(z="hover");const N=mx(S.current,"close",O.current);N&&!j.current?(pa(P),P.current=window.setTimeout(()=>r(!1,I,z),N)):D&&(pa(P),r(!1,I,z))},[S,r]),ie=_p(()=>{Y.current(),j.current=void 0}),X=_p(()=>{if(V.current){const I=Xv(o.floating).body;I.style.pointerEvents="",I.removeAttribute(C6),V.current=!1}}),ne=_p(()=>i.current.openEvent?["click","mousedown"].includes(i.current.openEvent.type):!1);M.useEffect(()=>{if(!l)return;function I(Q){if(pa(P),U.current=!1,h&&!nm(O.current)||gx(A.current)>0&&!mx(S.current,"open"))return;const G=mx(S.current,"open",O.current);G?P.current=window.setTimeout(()=>{C.current||r(!0,Q,"hover")},G):n||r(!0,Q,"hover")}function D(Q){if(ne()){X();return}Y.current();const G=Xv(o.floating);if(pa(R),K.current=!1,b.current&&i.current.floatingContext){n||pa(P),j.current=b.current({...i.current.floatingContext,tree:_,x:Q.clientX,y:Q.clientY,onClose(){X(),ie(),ne()||ee(Q,!0,"safe-polygon")}});const ae=j.current;G.addEventListener("mousemove",ae),Y.current=()=>{G.removeEventListener("mousemove",ae)};return}(O.current!=="touch"||!vre(o.floating,Q.relatedTarget))&&ee(Q)}function z(Q){ne()||i.current.floatingContext&&(b.current==null||b.current({...i.current.floatingContext,tree:_,x:Q.clientX,y:Q.clientY,onClose(){X(),ie(),ne()||ee(Q)}})(Q))}function N(){pa(P)}function B(Q){ne()||ee(Q,!1)}if(_r(o.domReference)){const Q=o.domReference,G=o.floating;return n&&Q.addEventListener("mouseleave",z),g&&Q.addEventListener("mousemove",I,{once:!0}),Q.addEventListener("mouseenter",I),Q.addEventListener("mouseleave",D),G&&(G.addEventListener("mouseleave",z),G.addEventListener("mouseenter",N),G.addEventListener("mouseleave",B)),()=>{n&&Q.removeEventListener("mouseleave",z),g&&Q.removeEventListener("mousemove",I),Q.removeEventListener("mouseenter",I),Q.removeEventListener("mouseleave",D),G&&(G.removeEventListener("mouseleave",z),G.removeEventListener("mouseenter",N),G.removeEventListener("mouseleave",B))}}},[o,l,e,h,g,ee,ie,X,r,n,C,_,S,b,i,ne,A]),Il(()=>{var I;if(l&&n&&(I=b.current)!=null&&(I=I.__options)!=null&&I.blockPointerEvents&&W()){V.current=!0;const z=o.floating;if(_r(o.domReference)&&z){var D;const N=Xv(o.floating).body;N.setAttribute(C6,"");const B=o.domReference,Q=_==null||(D=_.nodesRef.current.find(G=>G.id===x))==null||(D=D.context)==null?void 0:D.elements.floating;return Q&&(Q.style.pointerEvents=""),N.style.pointerEvents="none",B.style.pointerEvents="auto",z.style.pointerEvents="auto",()=>{N.style.pointerEvents="",B.style.pointerEvents="",z.style.pointerEvents=""}}}},[l,n,x,o,_,b,W]),Il(()=>{n||(O.current=void 0,K.current=!1,ie(),X())},[n,ie,X]),M.useEffect(()=>()=>{ie(),pa(P),pa(R),X()},[l,o.domReference,ie,X]);const H=M.useMemo(()=>{function I(D){O.current=D.pointerType}return{onPointerDown:I,onPointerEnter:I,onMouseMove(D){const{nativeEvent:z}=D;function N(){!U.current&&!C.current&&r(!0,z,"hover")}h&&!nm(O.current)||n||gx(A.current)===0||K.current&&D.movementX**2+D.movementY**2<2||(pa(R),O.current==="touch"?N():(K.current=!0,R.current=window.setTimeout(N,gx(A.current))))}}},[h,r,n,C,A]);return M.useMemo(()=>l?{reference:H}:{},[l,H])}function A6(e){return Ni(e.target)&&e.target.tagName==="BUTTON"}function pie(e){return Ni(e.target)&&e.target.tagName==="A"}function E6(e){return yre(e)}function mie(e,t){t===void 0&&(t={});const{open:n,onOpenChange:r,dataRef:i,elements:{domReference:a}}=e,{enabled:o=!0,event:l="click",toggle:f=!0,ignoreMouse:u=!1,keyboardHandlers:h=!0,stickIfOpen:m=!0}=t,g=M.useRef(),_=M.useRef(!1),x=M.useMemo(()=>({onPointerDown(b){g.current=b.pointerType},onMouseDown(b){const S=g.current;b.button===0&&l!=="click"&&(nm(S,!0)&&u||(n&&f&&(!(i.current.openEvent&&m)||i.current.openEvent.type==="mousedown")?r(!1,b.nativeEvent,"click"):(b.preventDefault(),r(!0,b.nativeEvent,"click"))))},onClick(b){const S=g.current;if(l==="mousedown"&&g.current){g.current=void 0;return}nm(S,!0)&&u||(n&&f&&(!(i.current.openEvent&&m)||i.current.openEvent.type==="click")?r(!1,b.nativeEvent,"click"):r(!0,b.nativeEvent,"click"))},onKeyDown(b){g.current=void 0,!(b.defaultPrevented||!h||A6(b))&&(b.key===" "&&!E6(a)&&(b.preventDefault(),_.current=!0),!pie(b)&&b.key==="Enter"&&r(!(n&&f),b.nativeEvent,"click"))},onKeyUp(b){b.defaultPrevented||!h||A6(b)||E6(a)||b.key===" "&&_.current&&(_.current=!1,r(!(n&&f),b.nativeEvent,"click"))}}),[i,a,l,u,h,r,n,m,f]);return M.useMemo(()=>o?{reference:x}:{},[o,x])}function gie(e){const{open:t=!1,onOpenChange:n,elements:r}=e,i=lie(),a=M.useRef({}),[o]=M.useState(()=>uie()),l=BB()!=null,[f,u]=M.useState(r.reference),h=_p((_,x,b)=>{a.current.openEvent=_?x:void 0,o.emit("openchange",{open:_,event:x,reason:b,nested:l}),n==null||n(_,x,b)}),m=M.useMemo(()=>({setPositionReference:u}),[]),g=M.useMemo(()=>({reference:f||r.reference||null,floating:r.floating||null,domReference:r.reference}),[f,r.reference,r.floating]);return M.useMemo(()=>({dataRef:a,open:t,onOpenChange:h,elements:g,events:o,floatingId:i,refs:m}),[t,h,g,o,i,m])}function zB(e){e===void 0&&(e={});const{nodeId:t}=e,n=gie({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,i=r.elements,[a,o]=M.useState(null),[l,f]=M.useState(null),u=(i==null?void 0:i.domReference)||a,h=M.useRef(null),m=UB();Il(()=>{u&&(h.current=u)},[u]);const g=Xre({...e,elements:{...i,...l&&{reference:l}}}),_=M.useCallback(A=>{const O=_r(A)?{getBoundingClientRect:()=>A.getBoundingClientRect(),getClientRects:()=>A.getClientRects(),contextElement:A}:A;f(O),g.refs.setReference(O)},[g.refs]),x=M.useCallback(A=>{(_r(A)||A===null)&&(h.current=A,o(A)),(_r(g.refs.reference.current)||g.refs.reference.current===null||A!==null&&!_r(A))&&g.refs.setReference(A)},[g.refs]),b=M.useMemo(()=>({...g.refs,setReference:x,setPositionReference:_,domReference:h}),[g.refs,x,_]),S=M.useMemo(()=>({...g.elements,domReference:u}),[g.elements,u]),C=M.useMemo(()=>({...g,...r,refs:b,elements:S,nodeId:t}),[g,b,S,t,r]);return Il(()=>{r.dataRef.current.floatingContext=C;const A=m==null?void 0:m.nodesRef.current.find(O=>O.id===t);A&&(A.context=C)}),M.useMemo(()=>({...g,context:C,refs:b,elements:S}),[g,b,S,C])}function vx(e,t,n){const r=new Map,i=n==="item";let a=e;if(i&&e){const{[w6]:o,[_6]:l,...f}=e;a=f}return{...n==="floating"&&{tabIndex:-1,[rie]:""},...a,...t.map(o=>{const l=o?o[n]:null;return typeof l=="function"?e?l(e):null:l}).concat(e).reduce((o,l)=>(l&&Object.entries(l).forEach(f=>{let[u,h]=f;if(!(i&&[w6,_6].includes(u)))if(u.indexOf("on")===0){if(r.has(u)||r.set(u,[]),typeof h=="function"){var m;(m=r.get(u))==null||m.push(h),o[u]=function(){for(var g,_=arguments.length,x=new Array(_),b=0;b<_;b++)x[b]=arguments[b];return(g=r.get(u))==null?void 0:g.map(S=>S(...x)).find(S=>S!==void 0)}}}else o[u]=h}),o),{})}}function FB(e){e===void 0&&(e=[]);const t=e.map(l=>l==null?void 0:l.reference),n=e.map(l=>l==null?void 0:l.floating),r=e.map(l=>l==null?void 0:l.item),i=M.useCallback(l=>vx(l,e,"reference"),t),a=M.useCallback(l=>vx(l,e,"floating"),n),o=M.useCallback(l=>vx(l,e,"item"),r);return M.useMemo(()=>({getReferenceProps:i,getFloatingProps:a,getItemProps:o}),[i,a,o])}const O6=e=>e.replace(/[A-Z]+(?![a-z])|[A-Z]/g,(t,n)=>(n?"-":"")+t.toLowerCase());function ff(e,t){return typeof e=="function"?e(t):e}function vie(e,t){const[n,r]=M.useState(e);return e&&!n&&r(!0),M.useEffect(()=>{if(!e&&n){const i=setTimeout(()=>r(!1),t);return()=>clearTimeout(i)}},[e,n,t]),n}function yie(e,t){t===void 0&&(t={});const{open:n,elements:{floating:r}}=e,{duration:i=250}=t,a=(typeof i=="number"?i:i.close)||0,[o,l]=M.useState("unmounted"),f=vie(n,a);return!f&&o==="close"&&l("unmounted"),Il(()=>{if(r){if(n){l("initial");const u=requestAnimationFrame(()=>{fc.flushSync(()=>{l("open")})});return()=>{cancelAnimationFrame(u)}}l("close")}},[n,r]),{isMounted:f,status:o}}function bie(e,t){t===void 0&&(t={});const{initial:n={opacity:0},open:r,close:i,common:a,duration:o=250}=t,l=e.placement,f=l.split("-")[0],u=M.useMemo(()=>({side:f,placement:l}),[f,l]),h=typeof o=="number",m=(h?o:o.open)||0,g=(h?o:o.close)||0,[_,x]=M.useState(()=>({...ff(a,u),...ff(n,u)})),{isMounted:b,status:S}=yie(e,{duration:o}),C=bl(n),A=bl(r),O=bl(i),P=bl(a);return Il(()=>{const j=ff(C.current,u),R=ff(O.current,u),U=ff(P.current,u),V=ff(A.current,u)||Object.keys(j).reduce((Y,K)=>(Y[K]="",Y),{});if(S==="initial"&&x(Y=>({transitionProperty:Y.transitionProperty,...U,...j})),S==="open"&&x({transitionProperty:Object.keys(V).map(O6).join(","),transitionDuration:m+"ms",...U,...V}),S==="close"){const Y=R||j;x({transitionProperty:Object.keys(Y).map(O6).join(","),transitionDuration:g+"ms",...U,...Y})}},[g,O,C,A,P,m,S,u]),{isMounted:b,styles:_}}const wie=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:px-4 tw:py-3 tw:rounded-t-md","tw:bg-lm-primary tw:dark:bg-dm-primary tw:border-b tw:border-lm-border tw:dark:border-dm-border",e),...t,ref:n})),_ie=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:p-4 tw:bg-lm-primary tw:dark:bg-dm-primary tw:first:rounded-t-md","tw:first:rounded-t-md tw:last:rounded-b-md",e),...t,ref:n})),xie=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:px-4 tw:py-3 tw:rounded-b-md","tw:bg-lm-primary tw:dark:bg-dm-primary tw:border-t tw:border-lm-border tw:dark:border-dm-border",e),...t,ref:n})),Sie=M.forwardRef(({className:e,...t},n)=>v.jsx("div",{className:be("tw:group/card tw:rounded-md tw:shadow-md","tw:border tw:border-lm-border tw:dark:border-dm-border tw:bg-lm-primary tw:dark:bg-dm-primary",e),...t,ref:n})),Fn=Object.assign(Sie,{Body:_ie,Header:wie,Footer:xie}),qt=M.forwardRef(({bodyClassName:e,children:t,...n},r)=>{const{title:i,titleSize:a="md",...o}="title"in n?n:{...n,title:void 0,titleSize:void 0};return v.jsxs(Fn,{...o,ref:r,children:[i&&v.jsxs(Fn.Header,{children:[a==="lg"&&v.jsx("h4",{children:i}),a==="md"&&v.jsx("h5",{children:i}),a==="sm"&&v.jsx("h6",{children:i})]}),v.jsx(Fn.Body,{className:e,children:t})]})});function Cie({id:e,items:t,onSelectItem:n,onActiveItemChange:r,renderItem:i,className:a,noItemsMessage:o="No items",anchor:l,"aria-label":f="Items",...u}){const[h,m]=M.useState(0),g=M.useCallback(_=>{if(m(_),r){const[x,b]=[...t.entries()][_];r(x,b)}},[t,r]);return M.useEffect(()=>{const _=l==null?void 0:l.current;if(!_)return;const x=b=>{["Enter","ArrowUp","ArrowDown"].includes(b.key)&&b.preventDefault(),b.key==="ArrowDown"?g(Math.min(h+1,t.size-1)):b.key==="ArrowUp"?g(Math.max(h-1,0)):b.key==="Enter"&&n([...t.values()][h])};return _.addEventListener("keydown",x),()=>_.removeEventListener("keydown",x)},[h,l,g,t,n]),v.jsxs(Fn,{id:e,className:be("tw:py-1 tw:flex tw:flex-col",a),role:"listbox","aria-orientation":"vertical","aria-label":f,...u,children:[t.size===0&&v.jsx("i",{role:"option","aria-disabled":!0,"aria-selected":!1,"data-testid":"no-items",className:"tw:px-2 tw:py-1",children:o}),[...t.entries()].map(([_,x],b)=>v.jsx("button",{id:`${e}_${_}`,type:"button",role:"option","aria-selected":b===h,className:be("tw:px-2 tw:py-1 tw:text-left tw:truncate",{"tw:bg-lm-secondary tw:dark:bg-dm-secondary":b===h}),tabIndex:-1,onClick:()=>n(x),onMouseOver:()=>g(b),children:i(x)},_))]})}const ig=M.createContext(void 0),Ld=M.createContext({responsive:!0,size:"md"}),Aie=({children:e,className:t})=>{const{responsive:n}=M.useContext(Ld);return v.jsx(ig.Provider,{value:{section:"head"},children:v.jsx("thead",{className:be({"tw:hidden tw:lg:table-header-group":n},t),children:e})})},Eie=({children:e,className:t})=>{const{responsive:n}=M.useContext(Ld);return v.jsx(ig.Provider,{value:{section:"body"},children:v.jsx("tbody",{className:be({"tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3":n},t),children:e})})},Oie=({children:e,className:t})=>{const{responsive:n}=M.useContext(Ld);return v.jsx(ig.Provider,{value:{section:"footer"},children:v.jsx("tfoot",{className:be({"tw:lg:table-row-group tw:flex tw:flex-col tw:gap-y-3 tw:mt-4":n},t),children:e})})},Tie=({children:e,className:t,...n})=>{const r=M.useContext(ig),i=(r==null?void 0:r.section)==="body",{responsive:a}=M.useContext(Ld);return v.jsx("tr",{className:be("tw:group",{"tw:lg:table-row tw:flex tw:flex-col":a,"tw:lg:border-0 tw:border-y-2 tw:border-lm-border tw:dark:border-dm-border":a,"tw:hover:bg-lm-primary tw:dark:hover:bg-dm-primary":i,"tw:group-[&]/card:hover:bg-lm-secondary tw:dark:group-[&]/card:hover:bg-dm-secondary":i},t),...n,children:e})},jie=({children:e,className:t,columnName:n,type:r,...i})=>{const a=M.useContext(ig),o=r??((a==null?void 0:a.section)!=="body"?"th":"td"),{responsive:l,size:f}=M.useContext(Ld);return v.jsx(o,{"data-column":l?n:void 0,className:be("tw:border-lm-border tw:dark:border-dm-border",{"tw:p-1":f==="sm","tw:p-2":f==="md","tw:p-3":f==="lg","tw:border-b-1":!l,"tw:block tw:lg:table-cell tw:not-last:border-b-1 tw:lg:border-b-1":l,"tw:text-left":o==="th","tw:before:lg:hidden tw:before:content-[attr(data-column)] tw:before:font-bold tw:before:mr-1":l&&o==="td"},t),...i,children:e})},Pie=({header:e,footer:t,children:n,responsive:r=!0,size:i="md",...a})=>v.jsx(Ld.Provider,{value:{responsive:r,size:i},children:v.jsxs("table",{className:"tw:w-full",...a,children:[v.jsx(Aie,{children:e}),v.jsx(Eie,{children:n}),t&&v.jsx(Oie,{children:t})]})}),Je=Object.assign(Pie,{Row:Tie,Cell:jie}),Tn=M.forwardRef(({className:e,disabled:t,variant:n="primary",size:r="md",inline:i=!1,solid:a=!1,type:o="button",...l},f)=>{const u="to"in l&&typeof l.to=="string",h=u?ur:"button",m=u?void 0:o;return v.jsx(h,{ref:f,className:be({"tw:inline-flex":i,"tw:flex":!i},"tw:gap-2 tw:items-center tw:justify-center","tw:border tw:rounded-md tw:no-underline","tw:transition-colors",{"tw:focus-ring":n==="primary","tw:focus-ring-secondary":n==="secondary","tw:focus-ring-danger":n==="danger"},{"tw:px-1.5 tw:py-1 tw:text-sm":r==="sm","tw:px-3 tw:py-1.5":r==="md","tw:px-4 tw:py-2 tw:text-lg":r==="lg"},{"tw:border-lm-brand tw:dark:border-dm-brand":n==="primary","tw:text-lm-brand tw:dark:text-dm-brand":n==="primary"&&!a,"tw:border-zinc-500":n==="secondary","tw:text-zinc-500":n==="secondary"&&!a,"tw:border-danger":n==="danger","tw:text-danger":n==="danger"&&!a},a&&{"tw:text-white":!0,"tw:bg-lm-brand tw:dark:bg-dm-brand":n==="primary","tw:highlight:bg-lm-brand-dark tw:dark:highlight:bg-dm-brand-dark":n==="primary","tw:highlight:border-lm-brand-dark tw:dark:highlight:border-dm-brand-dark":n==="primary","tw:bg-zinc-500":n==="secondary","tw:highlight:bg-zinc-600 tw:highlight:border-zinc-600":n==="secondary","tw:bg-danger":n==="danger","tw:highlight:bg-danger-dark tw:highlight:border-danger-dark":n==="danger"},!t&&{"tw:highlight:text-white":!a,"tw:highlight:bg-lm-brand tw:dark:highlight:bg-dm-brand":n==="primary","tw:highlight:bg-zinc-500":n==="secondary","tw:highlight:bg-danger":n==="danger"},{"tw:cursor-pointer":!t,"tw:pointer-events-none tw:opacity-65":t},e),disabled:u?void 0:t,"aria-disabled":u?t:void 0,type:m,...l})}),qB=M.forwardRef(({className:e,onChange:t,...n},r)=>{const i=M.useCallback(a=>t==null?void 0:t(a.target.checked,a),[t]);return v.jsx("input",{ref:r,type:"checkbox",className:be("tw:appearance-none tw:focus-ring tw:cursor-[inherit]","tw:border-1 tw:border-lm-input-border tw:dark:border-dm-input-border","tw:bg-lm-primary tw:dark:bg-dm-primary tw:checked:bg-lm-brand tw:dark:checked:bg-dm-brand tw:bg-no-repeat","tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input",e),onChange:i,...n})}),VB=M.forwardRef(({className:e,...t},n)=>v.jsx(qB,{ref:n,className:be("tw:rounded-sm tw:w-4 tw:h-4 tw:checked:bg-(image:--tick) tw:bg-center",e),...t})),Vf=M.forwardRef(({onClick:e,className:t,label:n="Close",size:r="lg",solid:i},a)=>v.jsx("button",{ref:a,type:"button",onClick:e,className:be("tw:rounded-md tw:focus-ring tw:cursor-pointer",{"tw:opacity-50 tw:highlight:opacity-80 tw:transition-opacity":!i},t),"aria-label":n,children:v.jsx(Ye,{icon:Pb,size:r==="lg"?"xl":r==="md"?"lg":void 0})})),ti=M.forwardRef(({borderless:e=!1,size:t="md",feedback:n,variant:r="default",className:i,disabled:a,...o},l)=>v.jsx("input",{ref:l,className:be("tw:outline-none",r==="default"&&["tw:w-full",{"tw:focus-ring":!n,"tw:focus-ring-danger":n==="error","tw:px-2 tw:py-1 tw:text-sm":t==="sm","tw:px-3 tw:py-1.5":t==="md","tw:px-4 tw:py-2 tw:text-xl":t==="lg","tw:rounded-md tw:border":!e,"tw:border-lm-input-border tw:dark:border-dm-input-border":!e&&!n,"tw:border-danger":!e&&n==="error","tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input":a,"tw:bg-lm-primary tw:dark:bg-dm-primary":!a,"tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":!a}],i),disabled:a,...o})),mo=({required:e,children:t,className:n,...r})=>v.jsxs("label",{className:be("tw:cursor-pointer",n),...r,children:[t,e&&v.jsx("span",{className:"tw:text-danger tw:ml-1","data-testid":"required-indicator",children:"*"})]}),YT=({children:e,helpText:t,error:n,"data-testid":r})=>v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1","data-testid":r,children:[e,t&&v.jsx("small",{"data-testid":r?`${r}-help-text`:"help-text",className:"tw:text-gray-500 tw:dark:text-gray-400",children:t}),n&&v.jsx("span",{"data-testid":r?`${r}-error`:"error",className:"tw:text-danger",children:n})]}),ta=M.forwardRef(({label:e,inputClassName:t,required:n,hiddenRequired:r,error:i,helpText:a,"data-testid":o,...l},f)=>{const u=M.useId();return v.jsxs(YT,{error:i,helpText:a,"data-testid":o,children:[v.jsx(mo,{htmlFor:u,required:n,children:e}),v.jsx(ti,{ref:f,id:u,className:t,required:n||r,feedback:i?"error":void 0,...l})]})}),Rie=M.forwardRef(({containerClassName:e,className:t,size:n,...r},i)=>{const[a,o,,l]=ire(!1),f=M.useRef(null),u=M.useCallback(({relatedTarget:h})=>{var m;(m=f.current)!=null&&m.contains(h)||l()},[f,l]);return v.jsxs("div",{className:be("tw:group tw:relative",e),ref:f,onBlurCapture:u,children:[v.jsx(ti,{ref:i,type:a?"text":"password",className:be({"tw:pr-10":n!=="sm","tw:pr-8":n==="sm"},t),size:n,"data-testid":"input",...r}),v.jsx("button",{type:"button",onClick:o,title:a?"Hide password":"Show password","aria-label":a?"Hide password":"Show password",className:be("tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:px-1 tw:cursor-pointer","tw:text-placeholder tw:hover:text-lm-text tw:hover:dark:text-dm-text tw:transition-colors",{"tw:right-1.5":n!=="sm","tw:scale-85 tw:right-1":n==="sm"}),tabIndex:-1,children:v.jsx(Ye,{fixedWidth:!0,icon:a?M9:L9})})]})});M.forwardRef(({label:e,inputClassName:t,required:n,hiddenRequired:r,error:i,helpText:a,"data-testid":o,...l},f)=>{const u=M.useId();return v.jsxs(YT,{error:i,helpText:a,"data-testid":o,children:[v.jsx(mo,{htmlFor:u,required:n,children:e}),v.jsx(Rie,{ref:f,id:u,className:t,required:n||r,feedback:i?"error":void 0,...l})]})});const Mie=M.forwardRef(({className:e,size:t="md",feedback:n,style:r={},disabled:i,...a},o)=>v.jsx("select",{ref:o,className:be("tw:w-full tw:appearance-none tw:pr-9","tw:bg-(image:--chevron-down) tw:bg-no-repeat",{"tw:focus-ring":!n,"tw:focus-ring-danger":n==="error"},"tw:rounded-md tw:border",{"tw:border-lm-input-border tw:dark:border-dm-input-border":!n,"tw:border-danger":n==="error"},{"tw:pl-2 tw:py-1 tw:text-sm":t==="sm","tw:pl-3 tw:py-1.5":t==="md","tw:pl-4 tw:py-2 tw:text-xl":t==="lg","tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input":i,"tw:bg-lm-primary tw:dark:bg-dm-primary tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":!i},e),style:{...r,background:"right 0.75rem center / 16px 12px"},disabled:i,...a})),KT=M.forwardRef(({selectClassName:e,label:t,error:n,helpText:r,required:i,hiddenRequired:a,"data-testid":o,...l},f)=>{const u=M.useId();return v.jsxs(YT,{error:n,helpText:r,"data-testid":o,children:[v.jsx(mo,{htmlFor:u,required:i,children:t}),v.jsx(Mie,{ref:f,id:u,className:e,required:i||a,feedback:n?"error":void 0,...l})]})}),ag=M.forwardRef(({onChange:e,containerClassName:t,inputClassName:n,size:r="lg",loading:i=!1,variant:a="default",immediate:o=!1,...l},f)=>{const{setTimeout:u,clearCurrentTimeout:h}=SB(500),m=M.useCallback(g=>{!g||o?(h(),e(g)):u(()=>e(g))},[h,o,e,u]);return v.jsxs("div",{className:be("tw:group tw:relative tw:focus-within:z-10",t),children:[a==="default"&&v.jsx(Ye,{icon:i?Ym:I9,spin:i,className:be("tw:absolute tw:top-[50%] tw:translate-y-[-50%] tw:transition-colors","tw:text-placeholder tw:group-focus-within:text-lm-text tw:dark:group-focus-within:text-dm-text",{"tw:left-3":r!=="sm","tw:scale-85 tw:left-2":r==="sm"})}),v.jsx(ti,{ref:f,variant:a,type:"search",className:be(a==="default"&&{"tw:pl-9":r!=="sm","tw:pl-7":r==="sm"},n),placeholder:"Search...",onChange:g=>m(g.target.value),size:r,...l})]})});function Nie({searchResults:e,onSearch:t,onSelectSearchResult:n,renderSearchResult:r,size:i="md",listboxSpan:a="full",onFocus:o,containerClassName:l,listboxClassName:f,...u},h){const m=M.useId(),[g,_]=M.useState(),x=M.useRef(null);M.useImperativeHandle(h,()=>x.current);const b=M.useMemo(()=>e?g??[...e.keys()][0]:void 0,[g,e]),S=M.useCallback(C=>{n(C),t(""),x.current.value=""},[t,n,x]);return v.jsxs("div",{className:be("tw:relative",l),onBlur:C=>{C.currentTarget.contains(C.relatedTarget)||t("")},children:[v.jsx(ag,{onChange:t,size:i,ref:x,role:"combobox","aria-autocomplete":"list","aria-expanded":!!e,"aria-controls":m,"aria-activedescendant":b?`${m}_${b}`:void 0,autoComplete:"off",autoCorrect:"off",onFocus:C=>{o==null||o(C),t(C.target.value)},...u}),e&&v.jsx(Cie,{id:m,items:e,anchor:x,onSelectItem:S,onActiveItemChange:_,renderItem:r,className:be("tw:absolute tw:top-full tw:mt-1 tw:z-10",{"tw:min-w-60":a==="auto","tw:w-full":a==="full"},f),"aria-label":"Matching items",noItemsMessage:"No results found matching search"})]})}const Lie=M.forwardRef(Nie),kie=({name:e,color:t})=>v.jsxs("div",{className:"tw:inline-flex tw:items-center tw:gap-2",children:[v.jsx("div",{"aria-hidden":!0,className:"tw:w-4 tw:h-4 tw:rounded-full",style:{backgroundColor:t}}),e]}),Die=({tag:e,color:t,size:n,onRemove:r})=>v.jsxs("li",{className:be("tw:inline-flex tw:items-center tw:gap-1 tw:font-bold tw:[&]:rounded-md",{"tw:px-1 tw:text-sm":n==="sm","tw:py-0.25 tw:px-1.5":n==="md","tw:py-0.5 tw:px-1.5":n==="lg"}),style:{backgroundColor:t,color:tre(t)?"#000":"#fff"},onClick:i=>i.stopPropagation(),children:[e,v.jsx(Vf,{label:`Remove ${e}`,solid:!0,size:"sm",onClick:()=>r(e)})]}),Iie=/\s+/g,T6="#99a1af",j6=e=>e.trim().toLowerCase().replace(Iie,"-"),$ie=({tags:e,selectedTags:t=[],onTagsChange:n,getColorForTag:r,searchMode:i="startsWith",immutable:a=!1,size:o="md",disabled:l,containerClassName:f,...u})=>{const[h,m]=M.useState(),g=M.useCallback(S=>{const C=S.toLowerCase().trim();if(!C){m(void 0);return}const A=e.filter(O=>{if(t.includes(O))return!1;const P=O.toLowerCase();return i==="startsWith"?P.startsWith(C):P.includes(C)}).slice(0,5);a||A.push(`Add "${C.split(",").map(j6).join(",")}" tag`),m(new Map(A.map(O=>[O,O])))},[a,i,t,e]),_=M.useCallback(S=>{const C=S.match(/Add\s+"([^"]+)"\s+tag/),A=((C==null?void 0:C[1])??S).split(",").map(j6);n==null||n([...new Set([...t,...A])])},[n,t]),x=M.useCallback(S=>n==null?void 0:n(t.filter(C=>C!==S)),[n,t]),b=M.useRef(null);return v.jsxs("div",{className:be("tw:rounded-md tw:flex tw:flex-wrap tw:gap-1","tw:border tw:border-lm-input-border tw:dark:border-dm-input-border","tw:cursor-text tw:focus-within:focus-within-ring",{"tw:p-0.5":o==="sm","tw:p-1.25":o==="md","tw:p-2":o==="lg","tw:bg-lm-disabled-input tw:dark:bg-dm-disabled-input":l,"tw:bg-lm-primary tw:dark:bg-dm-primary":!l,"tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":!l},f),onClick:S=>{var C;S.target!==b.current&&((C=b.current)==null||C.focus())},children:[v.jsx("ul",{className:"tw:m-0 tw:p-0 tw:flex tw:flex-wrap tw:gap-1",children:t.map((S,C)=>{const A=(r==null?void 0:r(S))??T6;return v.jsx(Die,{tag:S,color:A,onRemove:x,size:o},`${S}${C}`)})}),v.jsx(Lie,{variant:"unstyled",listboxSpan:"auto",containerClassName:"tw:flex tw:items-center",listboxClassName:"tw:whitespace-nowrap",inputClassName:be("tw:no-clear-button",{"tw:px-1 tw:text-sm":o==="sm","tw:px-2 tw:h-[26px]":o==="md","tw:px-3 tw:text-xl":o==="lg"}),searchResults:h,onSearch:g,onSelectSearchResult:_,renderSearchResult:S=>S.match(/Add\s+"([^"]+)"\s+tag/)?S:v.jsx(kie,{name:S,color:(r==null?void 0:r(S))??T6}),onKeyDown:S=>{S.key==="Backspace"&&!h&&x(t[t.length-1])},size:o,disabled:l,ref:b,immediate:!0,...u})]})},Bie=M.forwardRef(({className:e,...t},n)=>v.jsx(qB,{ref:n,className:be("tw:rounded-full tw:w-8 tw:h-4","tw:bg-(image:--circle-grey-dark) tw:dark:bg-(image:--circle-grey-light) tw:checked:bg-(image:--circle-white)","tw:focus-visible:not-checked:bg-(image:--circle-light-blue)","tw:checked:bg-right tw:transition-[background-position]",e),...t})),Uie=({className:e,selected:t,disabled:n,...r})=>{const i="to"in r&&typeof r.to=="string";return v.jsx(i?ur:"button",{role:"menuitem","data-selected":t,className:be("tw:flex tw:items-center tw:gap-2","tw:w-full tw:px-3 tw:py-1.5 tw:focus-ring","tw:no-underline tw:text-inherit",{"tw:cursor-pointer":!n,"tw:pointer-events-none tw:opacity-50":n,"tw:bg-lm-secondary tw:dark:bg-dm-secondary":t&&!n,"tw:highlight:bg-lm-secondary tw:dark:highlight:bg-dm-secondary tw:highlight:z-1 tw:relative":!t&&!n},e),tabIndex:-1,disabled:i?void 0:n,"aria-disabled":i?n:void 0,...r})},zie=()=>v.jsx("div",{role:"separator","aria-hidden":!0,className:"tw:border-b tw:border-lm-border tw:dark:border-dm-border tw:my-2"}),Fie=({children:e})=>v.jsx("div",{role:"heading","aria-level":6,"aria-hidden":!0,className:be("tw:flex tw:items-center tw:w-full tw:px-3 tw:py-1.5","tw:text-gray-500 tw:text-sm tw:font-semibold"),onClick:t=>t.stopPropagation(),children:e}),qie=({className:e,onClick:t,...n})=>v.jsx("div",{className:be("tw:px-3 tw:py-1.5",e),...n,onClick:r=>{r.stopPropagation(),t==null||t(r)}}),Vie=({children:e,className:t,focusableElementsSelector:n='[role="menuitem"]:not([disabled]):not([aria-disabled])',focusFirstItem:r=!1,...i})=>{const a=M.useRef(null);return Jne(a,{elementsSelector:n,focusFirstItem:r}),v.jsx(Fn,{ref:a,role:"menu",className:be("tw:py-2 tw:whitespace-nowrap",t),...i,children:e})},xp=Object.assign(Vie,{Item:Uie,Separator:zie,Title:Fie,Misc:qie}),Hie=({children:e,menuAlignment:t="left",buttonVariant:n="button",buttonContent:r,buttonClassName:i,buttonSize:a="md",buttonDisabled:o=!1,containerClassName:l,menuClassName:f,caretless:u,buttonLabel:h})=>{const[m,g]=M.useState(!1),_=M.useRef(null),{refs:x,floatingStyles:b,context:S}=zB({open:m,onOpenChange:g,placement:t==="right"?"bottom-end":"bottom-start",middleware:[eie(),Jre(3)],elements:{reference:_.current}}),C=mie(S),{getReferenceProps:A,getFloatingProps:O}=FB([C]),P=M.useId(),j=M.useRef(null);return M.useEffect(()=>{const R=j.current,U=_.current;if(!R||!U)return()=>{};const V=new AbortController;return document.body.addEventListener("click",Y=>{Y.composedPath().includes(U)||g(!1)},{signal:V.signal}),()=>V.abort()},[]),v.jsxs("div",{ref:j,className:be("tw:relative tw:inline-block",l),onKeyDown:R=>{R.key==="Escape"&&g(!1)},onBlur:R=>{R.relatedTarget&&!j.current.contains(R.relatedTarget)&&g(!1)},children:[v.jsxs("button",{ref:_,...A(),type:"button","aria-haspopup":!0,"aria-expanded":m,"aria-controls":P,"aria-label":h,disabled:o,className:be("tw:flex tw:items-center tw:rounded-md tw:focus-ring",{"tw:justify-between":!u,"tw:cursor-pointer":!o,"tw:pointer-events-none tw:opacity-50":o,"tw:border tw:border-lm-border tw:dark:border-dm-border":n==="button","tw:bg-lm-primary tw:dark:bg-dm-primary":n==="button","tw:group-[&]/card:bg-lm-input tw:group-[&]/card:dark:bg-dm-input":n==="button","tw:text-lm-brand tw:dark:text-dm-brand":n==="link","tw:highlight:text-lm-brand-dark tw:dark:highlight:text-dm-brand-dark tw:highlight:underline":n==="link","tw:px-1.5 tw:py-1 tw:text-sm tw:gap-x-1.5":a==="sm","tw:px-3 tw:py-1.5 tw:gap-x-2":a==="md","tw:px-4 tw:py-2 tw:text-lg tw:gap-x-2":a==="lg"},i),onKeyDown:R=>{R.key==="ArrowDown"&&(R.preventDefault(),g(!0))},children:[r,!u&&v.jsx(Ye,{icon:vT,size:"xs"})]}),m&&v.jsx("div",{ref:x.setFloating,style:b,className:"tw:min-w-full tw:z-1000",...O(),children:v.jsx(xp,{className:f,id:P,focusableElementsSelector:'[role="menuitem"]:not([disabled]):not([aria-disabled]),input:not([disabled]),select:not([disabled])',focusFirstItem:!0,children:e})})]})},tt=Object.assign(Hie,{Item:xp.Item,Separator:xp.Separator,Title:xp.Title,Misc:xp.Misc}),Zb=M.forwardRef(({className:e,disabled:t,size:n="md",type:r="button",...i},a)=>v.jsx("button",{className:be("tw:inline-flex tw:rounded-md tw:focus-ring","tw:text-lm-brand tw:dark:text-dm-brand","tw:highlight:text-lm-brand-dark tw:dark:highlight:text-dm-brand-dark tw:highlight:underline",{"tw:px-1.5 tw:py-1 tw:text-sm":n==="sm","tw:px-3 tw:py-1.5":n==="md","tw:px-4 tw:py-2 tw:text-lg":n==="lg","tw:cursor-pointer":!t,"tw:pointer-events-none tw:opacity-65":t},e),disabled:t,type:r,...i,ref:a})),HB=M.createContext(null),Gie=({className:e,to:t,...n})=>{const r=M.useContext(HB);return v.jsx(Ab,{role:"menuitem",to:t,className:({isActive:i})=>be("tw:px-4 tw:pt-2 tw:pb-[calc(0.5rem-3px)] tw:border-b-3","tw:highlight:text-lm-brand tw:dark:highlight:text-dm-brand","tw:font-bold tw:text-center tw:no-underline tw:transition-colors","tw:rounded-none tw:outline-none tw:focus-visible:inset-ring-2","tw:focus-visible:inset-ring-lm-brand/50 tw:dark:focus-visible:inset-ring-dm-brand/50",{"tw:text-lm-brand tw:dark:text-dm-brand":i,"tw:border-b-lm-brand tw:dark:border-b-dm-brand active":i,"tw:border-b-transparent tw:text-gray-500":!i,"tw:flex-grow":r==null?void 0:r.fill},e),...n})},Wie=({children:e,className:t,fill:n})=>v.jsx(HB.Provider,{value:{fill:n},children:v.jsx(Fn,{role:"menubar",className:be("tw:flex tw:overflow-hidden",t),children:e})}),Du=Object.assign(Wie,{Pill:Gie}),Yie=new Intl.NumberFormat("en-US"),jn=e=>Yie.format(Number(e)),P6=10,Kie=e=>Math.ceil(e/P6)*P6,df=2,a0="...",Zie=(e,t)=>Array.from({length:t-e},(n,r)=>e+r),Xie=(e,t)=>{const n=Zie(Math.max(df,e-df),Math.min(t-1,e+df)+1);return e-df>df&&n.unshift(a0),e+df<t-1&&n.push(a0),n.unshift(1),n.push(t),n},Np=e=>e===a0,Qie=e=>Np(e)?e:jn(e),Jie=(e,t)=>Np(e)?`${e}_${t}`:`${e}`,GB=["tw:border tw:border-r-0 tw:last:border-r tw:border-lm-border tw:dark:border-dm-border","tw:rounded-none tw:first:rounded-l tw:last:rounded-r"],WB=(e=!1)=>be(GB,"tw:px-3 tw:py-2 tw:cursor-pointer tw:no-underline","tw:focus-ring tw:focus-visible:z-1",!e&&["tw:text-lm-brand tw:dark:text-dm-brand","tw:bg-lm-primary tw:dark:bg-dm-primary","tw:highlight:bg-lm-secondary tw:dark:highlight:bg-dm-secondary"],e&&"tw:bg-lm-main tw:dark:bg-dm-main tw:text-white"),gE=({children:e})=>v.jsx("span",{"aria-hidden":!0,className:be(GB,"tw:px-3 tw:py-2 tw:text-gray-400"),children:e}),YB=()=>v.jsx(gE,{children:a0});function eae({children:e,active:t,isEllipsis:n,href:r,...i}){const a=M.useMemo(()=>WB(t),[t]);return n?v.jsx(YB,{}):v.jsx(ur,{className:a,to:r,...i,children:e})}function tae({children:e,active:t,isEllipsis:n,...r}){const i=M.useMemo(()=>WB(t),[t]);return n?v.jsx(YB,{}):v.jsx("button",{type:"button",className:i,...r,children:e})}const Xb=({currentPage:e,pagesCount:t,...n})=>{const r="urlForPage"in n,i=r?eae:tae,a=M.useCallback(o=>r?{href:Np(o)?void 0:n.urlForPage(o)}:{onClick:()=>!Np(o)&&n.onPageChange(o)},[r,n]);return t<2?null:v.jsxs("div",{className:"tw:select-none tw:flex","data-testid":"paginator",children:[e===1?v.jsx(gE,{children:v.jsx(Ye,{size:"xs",icon:rM})}):v.jsx(i,{...a(Math.max(1,e-1)),"aria-label":"Previous",children:v.jsx(Ye,{size:"xs",icon:rM})}),Xie(e,t).map((o,l)=>v.jsx(i,{active:o===e,isEllipsis:Np(o),...a(o),children:Qie(o)},Jie(o,l))),e===t?v.jsx(gE,{children:v.jsx(Ye,{size:"xs",icon:zy})}):v.jsx(i,{...a(Math.min(t,e+1)),"aria-label":"Next",children:v.jsx(Ye,{size:"xs",icon:zy})})]})},nae=({buttonLabel:e="Options",buttonSize:t="md",...n})=>v.jsx(tt,{buttonContent:v.jsx(Ye,{icon:k9,className:be({"tw:px-1":t==="sm"})}),caretless:!0,buttonLabel:e,buttonSize:t,...n}),zn=Object.assign(nae,{Item:tt.Item,Separator:tt.Separator,Title:tt.Title,Misc:tt.Misc}),rae=({open:e,children:t,className:n,onClose:r,...i})=>{const a=M.useRef(null);return M.useEffect(()=>{var o,l;const f=document.body,u=f.style.overflow,h=f.style.paddingRight;if(e){const m=window.outerWidth-f.clientWidth,g=f.scrollHeight>f.clientHeight;f.style.overflow="hidden",g&&(f.style.paddingRight=`${m}px`),(o=a.current)==null||o.showModal()}else(l=a.current)==null||l.close();return()=>{f.style.overflow=u,f.style.paddingRight=h}},[e]),fc.createPortal(v.jsx("dialog",{ref:a,className:be("tw:bg-transparent tw:backdrop:bg-black/50",n),onCancel:o=>{o.preventDefault(),r()},...i,children:e&&t}),document.body)},Vl=({open:e,onClose:t,variant:n="default",title:r,children:i,className:a,...o})=>{const{size:l="md",confirmText:f="Confirm",cancelText:u="Cancel",confirmDisabled:h,onConfirm:m,onClosed:g,..._}="onConfirm"in o?o:{...o},[x,b]=M.useState(e),S=M.useRef(null),C=M.useRef("cancel"),A=M.useCallback(O=>{O.preventDefault(),O.stopPropagation(),C.current="confirm",m==null||m()},[m]);return M.useEffect(()=>{if(e){C.current="cancel",b(!0);return}const O=S.current;if(O){delete S.current.dataset.open;let P=!1;const j=R=>{P||R.target!==O||(P=!0,b(!1),g==null||g(C.current))};return O.addEventListener("transitionend",j),()=>{O.removeEventListener("transitionend",j)}}},[g,e]),M.useEffect(()=>{const O=S.current;x&&O&&(O.dataset.open="")},[x]),v.jsx(rae,{open:x,onClose:t,className:be({"tw:flex tw:w-screen tw:h-screen tw:max-w-screen tw:max-h-screen":x,"tw:overflow-hidden":n==="cover"},a),..._,children:v.jsx("form",{"data-testid":"transition-container",ref:S,className:be("tw:w-full tw:m-auto tw:p-4 tw:sm:p-6","tw:-translate-y-4 tw:data-open:translate-y-0 tw:opacity-0 tw:data-open:opacity-100","tw:transition-[opacity_,_translate] tw:duration-300",n!=="cover"&&{"tw:sm:w-sm":l==="sm","tw:md:w-lg":l==="md","tw:md:w-4xl":l==="lg","tw:md:w-6xl":l==="xl"},{"tw:h-full":n==="cover"}),onSubmit:A,children:v.jsx(Fn,{className:be("tw:w-full",{"tw:h-full tw:relative tw:overflow-auto":n==="cover"}),children:n==="cover"?v.jsxs(v.Fragment,{children:[v.jsxs("div",{className:be("tw:px-4 tw:py-3 tw:absolute tw:top-0 tw:left-0 tw:right-0 tw:z-3000","tw:flex tw:items-center tw:justify-between","tw:text-white tw:bg-linear-to-b tw:from-black/70 tw:to-black/10","tw:[text-shadow:_0_2px_4px_rgb(0_0_0/_0.8)]"),children:[v.jsx("h5",{children:r}),v.jsx(Vf,{onClick:t,label:"Close dialog"})]}),i]}):v.jsxs(v.Fragment,{children:[v.jsxs(Fn.Header,{className:be("tw:sticky tw:top-0","tw:flex tw:items-center tw:justify-between tw:gap-x-2"),children:[v.jsx("h5",{className:be({"tw:text-danger":n==="danger"}),children:r}),v.jsx(Vf,{onClick:t,label:"Close dialog"})]}),v.jsx(Fn.Body,{children:i}),m&&v.jsxs(Fn.Footer,{"data-testid":"footer",className:be("tw:flex tw:justify-end tw:items-center tw:gap-x-2","tw:[&]:px-3 tw:sticky tw:bottom-0"),children:[v.jsx(Zb,{onClick:t,children:u}),v.jsx(Tn,{solid:!0,variant:n==="danger"?"danger":"primary",disabled:h,type:"submit",children:f})]})]})})})})},tc=({className:e,children:t,loading:n=!1,variant:r="default"})=>v.jsx(qt,{className:be({"tw:[&]:border-danger":r==="error"},e),children:v.jsxs("h3",{className:be("tw:text-center",{"tw:text-gray-500 tw:dark:text-gray-400":r==="default","tw:text-danger":r==="error"}),children:[n&&v.jsxs(v.Fragment,{children:[v.jsx(Ye,{icon:Ym,spin:!0}),v.jsx("span",{className:"tw:ml-2",children:t??"Loading..."})]}),!n&&t]})}),Ei=({variant:e,className:t,size:n="md",children:r})=>v.jsx("div",{className:be("tw:rounded-md tw:text-center",{"tw:p-2":n==="sm","tw:p-4":n==="md","tw:p-6":n==="lg","tw:[&]:text-white":e!=="warning","tw:bg-lm-brand tw:dark:bg-dm-brand":e==="success","tw:bg-danger":e==="error","tw:bg-warning tw:text-black":e==="warning"},t),children:r}),Hl=({placement:e="auto"}={})=>{const t=M.useRef(null),n=(()=>{const b=[];return e==="auto"&&b.push(tie()),b.push(nie({element:t})),b})(),[r,i]=M.useState(!1),{refs:a,floatingStyles:o,context:l,middlewareData:f}=zB({placement:e==="auto"?void 0:e,open:r,onOpenChange:i,middleware:n}),u=hie(l,{delay:{open:300},move:!0}),{getFloatingProps:h,getReferenceProps:m}=FB([u]),{isMounted:g,styles:_}=bie(l,{duration:200}),x=M.useMemo(()=>{const b=l.placement.split("-")[0];return{top:"bottom",right:"left",bottom:"top",left:"right"}[b]??""},[l.placement]);return{anchor:{...m(),ref:a.setReference},tooltip:{...h(),refSetter:a.setFloating,isMounted:g,styles:{...o,..._},arrowPos:f.arrow,arrowRef:t,arrowSide:x}}},Gl=({children:e,isMounted:t,styles:n,refSetter:r,arrowRef:i,arrowPos:a,arrowSide:o,...l})=>{var f;return t&&v.jsx("div",{role:"tooltip","aria-live":"polite",className:be("tw:z-1000 tw:max-w-64",{"tw:pt-2.5":o==="top","tw:pb-2.5":o==="bottom","tw:pr-2.5":o==="right","tw:pl-2.5":o==="left"}),ref:r,style:n,...l,children:v.jsxs("div",{className:"tw:relative tw:px-1.5 tw:py-1 tw:rounded tw:bg-black/90 tw:text-white tw:text-center",children:[v.jsx("span",{className:"tw:sr-only",children:"Tooltip: "}),e,v.jsx("div",{ref:i,className:be("tw:absolute","tw:border-l-6 tw:border-r-6 tw:border-b-6 tw:border-l-transparent tw:border-r-transparent tw:border-b-black/90",{"tw:rotate-180":o==="bottom","tw:rotate-90 tw:mr-[-3px]":o==="right","tw:rotate-270 tw:ml-[-3px]":o==="left"}),style:{left:a==null?void 0:a.x,top:a==null?void 0:a.y,[o]:`${-(((f=i.current)==null?void 0:f.offsetWidth)??0)/2}px`},"data-testid":"arrow"})]})})};function og({items:e,order:t,onChange:n,prefixed:r=!0,buttonVariant:i="button",...a}){const o=M.useCallback(f=>{const u=AB({currentOrderDir:t.dir,currentField:t.field,newField:f});n(u)},[n,t.dir,t.field]),l=i==="button";return v.jsxs(tt,{buttonContent:v.jsxs(v.Fragment,{children:[!l&&"Order by",l&&!t.field&&v.jsx("i",{children:"Order by..."}),l&&t.field&&v.jsxs(v.Fragment,{children:[r&&"Order by: ",e[t.field]," - ",t.dir??"DESC"]})]}),buttonVariant:i,...a,children:[Object.entries(e).map(([f,u])=>v.jsxs(tt.Item,{selected:t.field===f,onClick:()=>o(f),className:"tw:flex tw:items-center tw:justify-between tw:gap-2",children:[u,t.field===f&&v.jsx(Ye,{icon:t.dir==="ASC"?sX:WZ})]},f)),v.jsx(tt.Separator,{}),v.jsx(tt.Item,{disabled:!t.field,onClick:()=>n({}),children:v.jsx("i",{children:"Clear selection"})})]})}const KB=({text:e,className:t,size:n="lg",initialCopied:r=!1,navigator_:i=globalThis.navigator,...a})=>{const[o,l]=rre(r),f=M.useCallback(()=>i.clipboard.writeText(e).then(l),[i.clipboard,e,l]);return v.jsx("button",{type:"button",className:be("tw:focus-ring tw:rounded-sm tw:cursor-pointer",{"tw:text-md":n==="sm","tw:text-lg":n==="md","tw:text-xl":n==="lg"},t),"aria-label":`Copy ${e} to clipboard`,title:"Copy to clipboard",onClick:f,...a,children:v.jsx(Ye,{icon:o?Zu:G$,fixedWidth:!0})})},R6="tw:[&]:p-0 tw:[&]:md:w-1/4 tw:[&]:rounded-none",iae=({onChange:e,className:t})=>{const n=Xn("qrCodes",kd),{color:r,bgColor:i}=n;return v.jsxs(qt,{title:"Colors",className:t,bodyClassName:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(ta,{label:"Default color:",helpText:v.jsxs(v.Fragment,{children:["QR codes will initially use ",v.jsx("b",{"data-testid":"color",children:r})," color."]}),type:"color",value:r,onChange:a=>e({...n,color:a.target.value}),inputClassName:R6}),v.jsx(ta,{label:"Default background color:",helpText:v.jsxs(v.Fragment,{children:["QR codes will initially use ",v.jsx("b",{"data-testid":"bg-color",children:i})," background color."]}),type:"color",value:i,onChange:a=>e({...n,bgColor:a.target.value}),inputClassName:R6})]})},ZB=({errorCorrection:e,onChange:t})=>v.jsxs(tt,{buttonContent:e?`Error correction (${e})`:v.jsx("i",{children:"Default error correction"}),buttonClassName:"tw:w-full",children:[v.jsxs(tt.Item,{selected:e==="L",onClick:()=>t("L"),children:[v.jsx("b",{children:"L"}),"ow"]}),v.jsxs(tt.Item,{selected:e==="M",onClick:()=>t("M"),children:[v.jsx("b",{children:"M"}),"edium"]}),v.jsxs(tt.Item,{selected:e==="Q",onClick:()=>t("Q"),children:[v.jsx("b",{children:"Q"}),"uartile"]}),v.jsxs(tt.Item,{selected:e==="H",onClick:()=>t("H"),children:[v.jsx("b",{children:"H"}),"igh"]})]}),aae=["png","svg","webp","jpeg"],XB=({format:e,onChange:t})=>v.jsx(tt,{buttonContent:`Format (${e})`,buttonClassName:"tw:w-full",children:aae.map(n=>v.jsx(tt.Item,{selected:e===n,onClick:()=>t(n),children:n},n))}),Hf=({className:e,size:t,...n})=>v.jsx("span",{className:be("tw:text-gray-500 tw:dark:text-gray-400",{"tw:text-sm":t==="sm","tw:text-lg":t==="lg"},e),...n}),oae=({onChange:e})=>{const t=Xn("qrCodes",kd),{format:n,errorCorrection:r}=t;return v.jsxs(qt,{title:"Format",className:"card",bodyClassName:"tw:flex tw:flex-col tw:gap-4",children:[v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1",children:[v.jsx(XB,{format:n,onChange:i=>e({...t,format:i})}),v.jsxs(Hf,{size:"sm",children:["When downloading a QR code, it will use ",v.jsx("b",{"data-testid":"format",children:n})," format by default."]})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1",children:[v.jsx(ZB,{errorCorrection:r,onChange:i=>e({...t,errorCorrection:i})}),v.jsxs(Hf,{size:"sm",children:["QR codes will initially have a ",v.jsx("b",{"data-testid":"error-correction",children:r})," error correction."]})]})]})},sae=({onChange:e,className:t})=>{const n=Xn("qrCodes",kd),{size:r,margin:i}=n;return v.jsxs(qt,{title:"Size",className:t,bodyClassName:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(ta,{label:"Default dimensions:",helpText:v.jsxs(v.Fragment,{children:["QR codes will be initially generated with ",v.jsxs("b",{"data-testid":"size",children:[r,"x",r,"px"]}),"."]}),type:"range",value:r,step:10,min:50,max:1e3,onChange:a=>e({...n,size:Number(a.target.value)}),inputClassName:"tw:[&]:p-0"}),v.jsx(ta,{label:"Default margin:",helpText:v.jsxs(v.Fragment,{children:["QR codes will be initially generated with a ",v.jsxs("b",{"data-testid":"margin",children:[i,"px"]})," margin."]}),type:"range",value:i,step:1,min:0,max:100,onChange:a=>e({...n,margin:Number(a.target.value)}),inputClassName:"tw:[&]:p-0"})]})},os=({children:e,helpText:t,"data-testid":n,...r})=>v.jsxs("div",{"data-testid":n,children:[v.jsxs(mo,{className:"tw:flex tw:items-center tw:gap-x-2",children:[v.jsx(Bie,{...r}),e]}),t&&v.jsx(Hf,{size:"sm","data-testid":n?`${n}-help-text`:"help-text",className:"tw:pl-10",children:t})]}),lae=({toggleRealTimeUpdates:e,onIntervalChange:t})=>{const{enabled:n,interval:r}=Xn("realTimeUpdates",{enabled:!0});return v.jsxs(qt,{title:"Real-time updates",className:"tw:h-full",bodyClassName:"tw:flex tw:flex-col tw:gap-y-4",children:[v.jsx(os,{checked:n,onChange:e,helpText:v.jsxs(v.Fragment,{children:["Real-time updates are currently being ",v.jsx("b",{children:n?"processed":"ignored"}),"."]}),children:"Enable or disable real-time updates."}),v.jsxs("div",{children:[v.jsx(ta,{label:v.jsx("span",{className:be({"tw:dark:text-gray-400":!n}),children:"Real-time updates frequency (in minutes):"}),type:"number",min:0,placeholder:"Immediate",disabled:!n,value:`${r??""}`,onChange:({target:i})=>t(Number(i.value))}),n&&v.jsx(Hf,{size:"sm",children:r?v.jsxs("span",{children:["Updates will be reflected in the UI every ",v.jsx("b",{children:r})," minute",r>1&&"s","."]}):"Updates will be reflected in the UI as soon as they happen."})]})]})},yx=e=>e==="includes"?"Suggest tags including input":"Suggest tags starting with input",uae=e=>e==="includes"?v.jsxs(v.Fragment,{children:["The list of suggested tags will contain those ",v.jsx("b",{children:"including"})," provided input."]}):v.jsxs(v.Fragment,{children:["The list of suggested tags will contain those ",v.jsx("b",{children:"starting with"})," provided input."]}),cae=({onChange:e})=>{const t=Xn("shortUrlCreation",{validateUrls:!1}),n=r=>()=>e({...t??{validateUrls:!1},tagFilteringMode:r});return v.jsxs(qt,{title:"Short URLs form",className:"card",bodyClassName:"tw:flex tw:flex-col tw:gap-4",children:[v.jsxs(os,{"data-testid":"validate-url",checked:t.validateUrls??!1,onChange:r=>e({...t,validateUrls:r}),helpText:v.jsxs(v.Fragment,{children:["The initial state of the ",v.jsx("b",{children:"Validate URL"})," checkbox will be ",v.jsx("b",{children:t.validateUrls?"checked":"unchecked"}),"."]}),children:["Request validation on long URLs when creating new short URLs."," ",v.jsxs("b",{children:["This option is ignored by Shlink ",">=","4.0.0"]})]}),v.jsx(os,{"data-testid":"forward-query",checked:t.forwardQuery??!0,onChange:r=>e({...t,forwardQuery:r}),helpText:v.jsxs(v.Fragment,{children:["The initial state of the ",v.jsx("b",{children:"Forward query params on redirect"})," checkbox will be ",v.jsx("b",{children:t.forwardQuery??!0?"checked":"unchecked"}),"."]}),children:"Make all new short URLs forward their query params to the long URL."}),v.jsxs("div",{className:"tw:flex tw:flex-col",children:[v.jsx(mo,{className:"tw:mb-1.5",children:"Tag suggestions search mode:"}),v.jsxs(tt,{buttonContent:yx(t.tagFilteringMode),buttonClassName:"tw:w-full",children:[v.jsx(tt.Item,{selected:!t.tagFilteringMode||t.tagFilteringMode==="startsWith",onClick:n("startsWith"),children:yx("startsWith")}),v.jsx(tt.Item,{selected:t.tagFilteringMode==="includes",onClick:n("includes"),children:yx("includes")})]}),v.jsx(Hf,{size:"sm",className:"tw:mt-0.5",children:uae(t.tagFilteringMode)})]})]})},fae={dateCreated:"Created at",shortCode:"Short URL",longUrl:"Long URL",title:"Title",visits:"Visits"},dae=({onChange:e,defaultOrdering:t})=>{const n=Xn("shortUrlsList"),r=(n==null?void 0:n.confirmDeletions)??!0;return v.jsxs(qt,{title:"Short URLs list",className:"card",bodyClassName:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(os,{checked:r,onChange:i=>e({...n,confirmDeletions:i}),helpText:v.jsxs(v.Fragment,{children:["When deleting a short URL, confirmation ",v.jsx("b",{children:r?"will":"won't"})," be required."]}),children:"Request confirmation before deleting a short URL."}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1.5",children:[v.jsx(mo,{children:"Default ordering for short URLs list:"}),v.jsx(og,{buttonClassName:"tw:w-full",items:fae,order:(n==null?void 0:n.defaultOrdering)??t,onChange:i=>e({defaultOrdering:!i.dir&&!i.field?void 0:i})})]})]})},hae={tag:"Tag",shortUrls:"Short URLs",visits:"Visits"},pae=({onChange:e})=>{const t=Xn("tags",{});return v.jsx(qt,{title:"Tags",className:"card",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1.5",children:[v.jsx(mo,{children:"Default ordering for tags list:"}),v.jsx(og,{buttonClassName:"tw:w-full",items:hae,order:t.defaultOrdering??{},onChange:n=>e({...t,defaultOrdering:!n.field&&!n.dir?void 0:n})})]})})},mae=({onChange:e,_matchMedia:t})=>{const n=Xn("ui"),r=M.useMemo(()=>(n==null?void 0:n.theme)??RT(t),[n==null?void 0:n.theme,t]);return v.jsxs(qt,{title:"User interface",bodyClassName:"tw:flex tw:justify-between tw:items-center",children:[v.jsx(os,{checked:r==="dark",onChange:i=>e({...n,theme:i?"dark":"light"}),children:"Use dark theme."}),v.jsx(Ye,{icon:r==="dark"?wX:uX})]})},QB={today:"Today",yesterday:"Yesterday",last7Days:"Last 7 days",last30Days:"Last 30 days",last90Days:"Last 90 days",last180Days:"Last 180 days",last365Days:"Last 365 days"},gae=(e,t)=>!e||e==="all"?t:QB[e],vae=({onChange:e,active:t,allText:n})=>v.jsxs(tt,{buttonContent:gae(t,n),buttonClassName:"tw:w-full",children:[v.jsx(tt.Item,{selected:t==="all",onClick:()=>e("all"),children:n}),v.jsx(tt.Separator,{}),Object.entries(QB).map(([r,i])=>v.jsx(tt.Item,{selected:t===r,onClick:()=>e(r),children:i},r))]}),M6=e=>(e==null?void 0:e.defaultInterval)??"last30Days",yae=({onChange:e})=>{const t=Xn("visits"),n=M.useCallback(({defaultInterval:r,...i})=>e({defaultInterval:r??M6(t),...i}),[e,t]);return v.jsxs(qt,{title:"Visits",className:"card",bodyClassName:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(os,{"data-testid":"exclude-bots",checked:!!(t!=null&&t.excludeBots),onChange:r=>n({excludeBots:r}),helpText:v.jsxs(v.Fragment,{children:["The visits coming from potential bots will be ",v.jsx("b",{children:t!=null&&t.excludeBots?"excluded":"included"}),"."]}),children:"Exclude bots wherever possible (this option‘s effect might depend on Shlink server‘s version)."}),v.jsx(os,{"data-testid":"compare-visits",checked:!!(t!=null&&t.loadPrevInterval),onChange:r=>n({loadPrevInterval:r}),helpText:v.jsxs(v.Fragment,{children:["When loading visits, previous period ",v.jsx("b",{children:t!=null&&t.loadPrevInterval?"will":"won't"})," be loaded by default."]}),children:"Compare visits with previous period."}),v.jsxs("div",{className:"tw:flex tw:flex-col",children:[v.jsx(mo,{className:"tw:mb-1.5",children:"Default interval to load on visits sections:"}),v.jsx(vae,{allText:"All visits",active:M6(t),onChange:r=>n({defaultInterval:r})})]})]})},Qv=({children:e,className:t})=>v.jsx("div",{className:be("tw:flex tw:flex-col tw:gap-4",t),children:e}),bae=({settings:e,updateSettings:t,onUpdateSettings:n=t,defaultShortUrlsListOrdering:r})=>{const i=M.useCallback(u=>n==null?void 0:n(Gb(e,u)),[e,n]),a=M.useCallback(u=>i({realTimeUpdates:{enabled:u}}),[i]),o=M.useCallback(u=>i({realTimeUpdates:{interval:u}}),[i]),l=M.useCallback((u,h)=>i({[u]:h}),[i]),f=M.useCallback(u=>l("qrCodes",u),[l]);return v.jsxs(tU,{value:e,children:[v.jsxs(Du,{className:"tw:mb-4 tw:sticky tw:top-(--header-height) tw:z-2",children:[v.jsx(Du.Pill,{to:"../general",children:"General"}),v.jsx(Du.Pill,{to:"../short-urls",children:"Short URLs"}),v.jsx(Du.Pill,{to:"../qr-codes",children:"QR codes"}),v.jsx(Du.Pill,{to:"../other-items",children:"Other items"})]}),v.jsxs(Sb,{children:[v.jsx(xt,{path:"general",element:v.jsxs(Qv,{children:[v.jsx(mae,{onChange:u=>l("ui",u)}),v.jsx(lae,{toggleRealTimeUpdates:a,onIntervalChange:o})]})}),v.jsx(xt,{path:"short-urls",element:v.jsxs(Qv,{children:[v.jsx(cae,{onChange:u=>l("shortUrlCreation",u)}),v.jsx(dae,{defaultOrdering:r,onChange:u=>l("shortUrlsList",u)})]})}),v.jsx(xt,{path:"other-items",element:v.jsxs(Qv,{children:[v.jsx(pae,{onChange:u=>l("tags",u)}),v.jsx(yae,{onChange:u=>l("visits",u)})]})}),v.jsx(xt,{path:"qr-codes",element:v.jsxs(Qv,{children:[v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row tw:gap-4",children:[v.jsx(sae,{onChange:f,className:"tw:w-full"}),v.jsx(iae,{onChange:f,className:"tw:w-full"})]}),v.jsx(oae,{onChange:f})]})}),v.jsx(xt,{path:"*",element:v.jsx(aT,{replace:!0,to:"../general"})})]})]})},kd={size:300,margin:0,color:"#000000",bgColor:"#ffffff",errorCorrection:"L",format:"png"};Object.freeze(kd);const JB={realTimeUpdates:{enabled:!0},shortUrlCreation:{validateUrls:!1},visits:{defaultInterval:"last30Days"},shortUrlsList:{defaultOrdering:{field:"dateCreated",dir:"DESC"}},qrCodes:kd},eU=M.createContext(JB),{Provider:tU}=eU,ZT=()=>M.useContext(eU)??JB;function Xn(e,t){return ZT()[e]??t}const XT={INVALID_ARGUMENT:"https://shlink.io/api/error/invalid-data",INVALID_SHORT_URL_DELETION:"https://shlink.io/api/error/invalid-short-url-deletion",DOMAIN_NOT_FOUND:"https://shlink.io/api/error/domain-not-found",FORBIDDEN_OPERATION:"https://shlink.io/api/error/forbidden-tag-operation",INVALID_SLUG:"https://shlink.io/api/error/non-unique-slug",INVALID_SHORTCODE:"https://shlink.io/api/error/short-url-not-found",TAG_CONFLICT:"https://shlink.io/api/error/tag-conflict",TAG_NOT_FOUND:"https://shlink.io/api/error/tag-not-found",MERCURE_NOT_CONFIGURED:"https://shlink.io/api/error/mercure-not-configured",INVALID_AUTHORIZATION:"https://shlink.io/api/error/missing-authentication",INVALID_API_KEY:"https://shlink.io/api/error/invalid-api-key",NOT_FOUND:"https://shlink.io/api/error/not-found",INVALID_URL:"https://shlink.io/api/error/invalid-url"};Object.freeze(XT);const wae=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,N6=e=>{if(typeof e!="string")throw new TypeError("Invalid argument expected string");const t=e.match(wae);if(!t)throw new Error(`Invalid argument not valid semver ('${e}' received)`);return t.shift(),t},L6=e=>e==="*"||e==="x"||e==="X",k6=e=>{const t=parseInt(e,10);return isNaN(t)?e:t},_ae=(e,t)=>typeof e!=typeof t?[String(e),String(t)]:[e,t],xae=(e,t)=>{if(L6(e)||L6(t))return 0;const[n,r]=_ae(k6(e),k6(t));return n>r?1:n<r?-1:0},D6=(e,t)=>{for(let n=0;n<Math.max(e.length,t.length);n++){const r=xae(e[n]||"0",t[n]||"0");if(r!==0)return r}return 0},Sae=(e,t)=>{const n=N6(e),r=N6(t),i=n.pop(),a=r.pop(),o=D6(n,r);return o!==0?o:i&&a?D6(i.split("."),a.split(".")):i||a?i?-1:1:0},vE=(e,t,n)=>{Cae(n);const r=Sae(e,t);return nU[n].includes(r)},nU={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},I6=Object.keys(nU),Cae=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(I6.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${I6.join("|")}`)},Oi=({href:e,children:t,rel:n,...r})=>v.jsx("a",{target:"_blank",rel:`noopener noreferrer${n?` ${n}`:""}`,href:e,...r,children:t??e});var Sp={exports:{}};/** @license
|
||
* eventsource.js
|
||
* Available under MIT License (MIT)
|
||
* https://github.com/Yaffle/EventSource/
|
||
*/var Aae=Sp.exports,$6;function Eae(){return $6||($6=1,function(e,t){(function(n){var r=n.setTimeout,i=n.clearTimeout,a=n.XMLHttpRequest,o=n.XDomainRequest,l=n.ActiveXObject,f=n.EventSource,u=n.document,h=n.Promise,m=n.fetch,g=n.Response,_=n.TextDecoder,x=n.TextEncoder,b=n.AbortController;if(typeof window<"u"&&typeof u<"u"&&!("readyState"in u)&&u.body==null&&(u.readyState="loading",window.addEventListener("load",function(he){u.readyState="complete"},!1)),a==null&&l!=null&&(a=function(){return new l("Microsoft.XMLHTTP")}),Object.create==null&&(Object.create=function(he){function xe(){}return xe.prototype=he,new xe}),Date.now||(Date.now=function(){return new Date().getTime()}),b==null){var S=m;m=function(he,xe){var Oe=xe.signal;return S(he,{headers:xe.headers,credentials:xe.credentials,cache:xe.cache}).then(function(Le){var He=Le.body.getReader();return Oe._reader=He,Oe._aborted&&Oe._reader.cancel(),{status:Le.status,statusText:Le.statusText,headers:Le.headers,body:{getReader:function(){return He}}}})},b=function(){this.signal={_reader:null,_aborted:!1},this.abort=function(){this.signal._reader!=null&&this.signal._reader.cancel(),this.signal._aborted=!0}}}function C(){this.bitsNeeded=0,this.codePoint=0}C.prototype.decode=function(he){function xe(ke,Ne,je){if(je===1)return ke>=128>>Ne&&ke<<Ne<=2047;if(je===2)return ke>=2048>>Ne&&ke<<Ne<=55295||ke>=57344>>Ne&&ke<<Ne<=65535;if(je===3)return ke>=65536>>Ne&&ke<<Ne<=1114111;throw new Error}function Oe(ke,Ne){if(ke===6*1)return Ne>>6>15?3:Ne>31?2:1;if(ke===6*2)return Ne>15?3:2;if(ke===6*3)return 3;throw new Error}for(var Le=65533,He="",$e=this.bitsNeeded,ze=this.codePoint,_e=0;_e<he.length;_e+=1){var Se=he[_e];$e!==0&&(Se<128||Se>191||!xe(ze<<6|Se&63,$e-6,Oe($e,ze)))&&($e=0,ze=Le,He+=String.fromCharCode(ze)),$e===0?(Se>=0&&Se<=127?($e=0,ze=Se):Se>=192&&Se<=223?($e=6*1,ze=Se&31):Se>=224&&Se<=239?($e=6*2,ze=Se&15):Se>=240&&Se<=247?($e=6*3,ze=Se&7):($e=0,ze=Le),$e!==0&&!xe(ze,$e,Oe($e,ze))&&($e=0,ze=Le)):($e-=6,ze=ze<<6|Se&63),$e===0&&(ze<=65535?He+=String.fromCharCode(ze):(He+=String.fromCharCode(55296+(ze-65535-1>>10)),He+=String.fromCharCode(56320+(ze-65535-1&1023))))}return this.bitsNeeded=$e,this.codePoint=ze,He};var A=function(){try{return new _().decode(new x().encode("test"),{stream:!0})==="test"}catch(he){console.debug("TextDecoder does not support streaming option. Using polyfill instead: "+he)}return!1};(_==null||x==null||!A())&&(_=C);var O=function(){};function P(he){this.withCredentials=!1,this.readyState=0,this.status=0,this.statusText="",this.responseText="",this.onprogress=O,this.onload=O,this.onerror=O,this.onreadystatechange=O,this._contentType="",this._xhr=he,this._sendTimeout=0,this._abort=O}P.prototype.open=function(he,xe){this._abort(!0);var Oe=this,Le=this._xhr,He=1,$e=0;this._abort=function(je){Oe._sendTimeout!==0&&(i(Oe._sendTimeout),Oe._sendTimeout=0),(He===1||He===2||He===3)&&(He=4,Le.onload=O,Le.onerror=O,Le.onabort=O,Le.onprogress=O,Le.onreadystatechange=O,Le.abort(),$e!==0&&(i($e),$e=0),je||(Oe.readyState=4,Oe.onabort(null),Oe.onreadystatechange())),He=0};var ze=function(){if(He===1){var je=0,Fe="",Ge=void 0;if("contentType"in Le)je=200,Fe="OK",Ge=Le.contentType;else try{je=Le.status,Fe=Le.statusText,Ge=Le.getResponseHeader("Content-Type")}catch{je=0,Fe="",Ge=void 0}je!==0&&(He=2,Oe.readyState=2,Oe.status=je,Oe.statusText=Fe,Oe._contentType=Ge,Oe.onreadystatechange())}},_e=function(){if(ze(),He===2||He===3){He=3;var je="";try{je=Le.responseText}catch{}Oe.readyState=3,Oe.responseText=je,Oe.onprogress()}},Se=function(je,Fe){if((Fe==null||Fe.preventDefault==null)&&(Fe={preventDefault:O}),_e(),He===1||He===2||He===3){if(He=4,$e!==0&&(i($e),$e=0),Oe.readyState=4,je==="load")Oe.onload(Fe);else if(je==="error")Oe.onerror(Fe);else if(je==="abort")Oe.onabort(Fe);else throw new TypeError;Oe.onreadystatechange()}},ke=function(je){Le!=null&&(Le.readyState===4?(!("onload"in Le)||!("onerror"in Le)||!("onabort"in Le))&&Se(Le.responseText===""?"error":"load",je):Le.readyState===3?"onprogress"in Le||_e():Le.readyState===2&&ze())},Ne=function(){$e=r(function(){Ne()},500),Le.readyState===3&&_e()};"onload"in Le&&(Le.onload=function(je){Se("load",je)}),"onerror"in Le&&(Le.onerror=function(je){Se("error",je)}),"onabort"in Le&&(Le.onabort=function(je){Se("abort",je)}),"onprogress"in Le&&(Le.onprogress=_e),"onreadystatechange"in Le&&(Le.onreadystatechange=function(je){ke(je)}),("contentType"in Le||!("ontimeout"in a.prototype))&&(xe+=(xe.indexOf("?")===-1?"?":"&")+"padding=true"),Le.open(he,xe,!0),"readyState"in Le&&($e=r(function(){Ne()},0))},P.prototype.abort=function(){this._abort(!1)},P.prototype.getResponseHeader=function(he){return this._contentType},P.prototype.setRequestHeader=function(he,xe){var Oe=this._xhr;"setRequestHeader"in Oe&&Oe.setRequestHeader(he,xe)},P.prototype.getAllResponseHeaders=function(){return this._xhr.getAllResponseHeaders!=null&&this._xhr.getAllResponseHeaders()||""},P.prototype.send=function(){if((!("ontimeout"in a.prototype)||!("sendAsBinary"in a.prototype)&&!("mozAnon"in a.prototype))&&u!=null&&u.readyState!=null&&u.readyState!=="complete"){var he=this;he._sendTimeout=r(function(){he._sendTimeout=0,he.send()},4);return}var xe=this._xhr;"withCredentials"in xe&&(xe.withCredentials=this.withCredentials);try{xe.send(void 0)}catch(Oe){throw Oe}};function j(he){return he.replace(/[A-Z]/g,function(xe){return String.fromCharCode(xe.charCodeAt(0)+32)})}function R(he){for(var xe=Object.create(null),Oe=he.split(`\r
|
||
`),Le=0;Le<Oe.length;Le+=1){var He=Oe[Le],$e=He.split(": "),ze=$e.shift(),_e=$e.join(": ");xe[j(ze)]=_e}this._map=xe}R.prototype.get=function(he){return this._map[j(he)]},a!=null&&a.HEADERS_RECEIVED==null&&(a.HEADERS_RECEIVED=2);function U(){}U.prototype.open=function(he,xe,Oe,Le,He,$e,ze){he.open("GET",He);var _e=0;he.onprogress=function(){var ke=he.responseText,Ne=ke.slice(_e);_e+=Ne.length,Oe(Ne)},he.onerror=function(ke){ke.preventDefault(),Le(new Error("NetworkError"))},he.onload=function(){Le(null)},he.onabort=function(){Le(null)},he.onreadystatechange=function(){if(he.readyState===a.HEADERS_RECEIVED){var ke=he.status,Ne=he.statusText,je=he.getResponseHeader("Content-Type"),Fe=he.getAllResponseHeaders();xe(ke,Ne,je,new R(Fe))}},he.withCredentials=$e;for(var Se in ze)Object.prototype.hasOwnProperty.call(ze,Se)&&he.setRequestHeader(Se,ze[Se]);return he.send(),he};function V(he){this._headers=he}V.prototype.get=function(he){return this._headers.get(he)};function Y(){}Y.prototype.open=function(he,xe,Oe,Le,He,$e,ze){var _e=null,Se=new b,ke=Se.signal,Ne=new _;return m(He,{headers:ze,credentials:$e?"include":"same-origin",signal:ke,cache:"no-store"}).then(function(je){return _e=je.body.getReader(),xe(je.status,je.statusText,je.headers.get("Content-Type"),new V(je.headers)),new h(function(Fe,Ge){var Xe=function(){_e.read().then(function(ft){if(ft.done)Fe(void 0);else{var st=Ne.decode(ft.value,{stream:!0});Oe(st),Xe()}}).catch(function(ft){Ge(ft)})};Xe()})}).catch(function(je){if(je.name!=="AbortError")return je}).then(function(je){Le(je)}),{abort:function(){_e!=null&&_e.cancel(),Se.abort()}}};function K(){this._listeners=Object.create(null)}function W(he){r(function(){throw he},0)}K.prototype.dispatchEvent=function(he){he.target=this;var xe=this._listeners[he.type];if(xe!=null)for(var Oe=xe.length,Le=0;Le<Oe;Le+=1){var He=xe[Le];try{typeof He.handleEvent=="function"?He.handleEvent(he):He.call(this,he)}catch($e){W($e)}}},K.prototype.addEventListener=function(he,xe){he=String(he);var Oe=this._listeners,Le=Oe[he];Le==null&&(Le=[],Oe[he]=Le);for(var He=!1,$e=0;$e<Le.length;$e+=1)Le[$e]===xe&&(He=!0);He||Le.push(xe)},K.prototype.removeEventListener=function(he,xe){he=String(he);var Oe=this._listeners,Le=Oe[he];if(Le!=null){for(var He=[],$e=0;$e<Le.length;$e+=1)Le[$e]!==xe&&He.push(Le[$e]);He.length===0?delete Oe[he]:Oe[he]=He}};function ee(he){this.type=he,this.target=void 0}function ie(he,xe){ee.call(this,he),this.data=xe.data,this.lastEventId=xe.lastEventId}ie.prototype=Object.create(ee.prototype);function X(he,xe){ee.call(this,he),this.status=xe.status,this.statusText=xe.statusText,this.headers=xe.headers}X.prototype=Object.create(ee.prototype);function ne(he,xe){ee.call(this,he),this.error=xe.error}ne.prototype=Object.create(ee.prototype);var H=-1,I=0,D=1,z=2,N=-1,B=0,Q=1,G=2,ae=3,fe=/^text\/event\-stream(;.*)?$/i,ce=1e3,ye=18e6,F=function(he,xe){var Oe=he==null?xe:parseInt(he,10);return Oe!==Oe&&(Oe=xe),q(Oe)},q=function(he){return Math.min(Math.max(he,ce),ye)},te=function(he,xe,Oe){try{typeof xe=="function"&&xe.call(he,Oe)}catch(Le){W(Le)}};function ue(he,xe){K.call(this),xe=xe||{},this.onopen=void 0,this.onmessage=void 0,this.onerror=void 0,this.url=void 0,this.readyState=void 0,this.withCredentials=void 0,this.headers=void 0,this._close=void 0,de(this,he,xe)}function J(){return a!=null&&"withCredentials"in a.prototype||o==null?new a:new o}var se=m!=null&&g!=null&&"body"in g.prototype;function de(he,xe,Oe){xe=String(xe);var Le=!!Oe.withCredentials,He=Oe.lastEventIdQueryParameterName||"lastEventId",$e=q(1e3),ze=F(Oe.heartbeatTimeout,45e3),_e="",Se=$e,ke=!1,Ne=0,je=Oe.headers||{},Fe=Oe.Transport,Ge=se&&Fe==null?void 0:new P(Fe!=null?new Fe:J()),Xe=Fe!=null&&typeof Fe!="string"?new Fe:Ge==null?new Y:new U,ft=void 0,st=0,wt=H,kt="",Dt="",It="",Cr="",Vn=B,ys=0,ii=0,bs=function(mn,fn,Jn,Hn){if(wt===I)if(mn===200&&Jn!=null&&fe.test(Jn)){wt=D,ke=Date.now(),Se=$e,he.readyState=D;var en=new X("open",{status:mn,statusText:fn,headers:Hn});he.dispatchEvent(en),te(he,he.onopen,en)}else{var Mt="";mn!==200?(fn&&(fn=fn.replace(/\s+/g," ")),Mt="EventSource's response has a status "+mn+" "+fn+" that is not 200. Aborting the connection."):Mt="EventSource's response has a Content-Type specifying an unsupported type: "+(Jn==null?"-":Jn.replace(/\s+/g," "))+". Aborting the connection.",ws();var en=new X("error",{status:mn,statusText:fn,headers:Hn});he.dispatchEvent(en),te(he,he.onerror,en),console.error(Mt)}},La=function(mn){if(wt===D){for(var fn=-1,Jn=0;Jn<mn.length;Jn+=1){var Hn=mn.charCodeAt(Jn);(Hn===10||Hn===13)&&(fn=Jn)}var en=(fn!==-1?Cr:"")+mn.slice(0,fn+1);Cr=(fn===-1?Cr:"")+mn.slice(fn+1),mn!==""&&(ke=Date.now(),Ne+=mn.length);for(var Mt=0;Mt<en.length;Mt+=1){var Hn=en.charCodeAt(Mt);if(Vn===N&&Hn===10)Vn=B;else if(Vn===N&&(Vn=B),Hn===13||Hn===10){if(Vn!==B){Vn===Q&&(ii=Mt+1);var tn=en.slice(ys,ii-1),er=en.slice(ii+(ii<Mt&&en.charCodeAt(ii)===32?1:0),Mt);tn==="data"?(kt+=`
|
||
`,kt+=er):tn==="id"?Dt=er:tn==="event"?It=er:tn==="retry"?($e=F(er,$e),Se=$e):tn==="heartbeatTimeout"&&(ze=F(er,ze),st!==0&&(i(st),st=r(function(){ka()},ze)))}if(Vn===B){if(kt!==""){_e=Dt,It===""&&(It="message");var Mn=new ie(It,{data:kt.slice(1),lastEventId:Dt});if(he.dispatchEvent(Mn),It==="open"?te(he,he.onopen,Mn):It==="message"?te(he,he.onmessage,Mn):It==="error"&&te(he,he.onerror,Mn),wt===z)return}kt="",It=""}Vn=Hn===13?N:B}else Vn===B&&(ys=Mt,Vn=Q),Vn===Q?Hn===58&&(ii=Mt+1,Vn=G):Vn===G&&(Vn=ae)}}},bc=function(mn){if(wt===D||wt===I){wt=H,st!==0&&(i(st),st=0),st=r(function(){ka()},Se),Se=q(Math.min($e*16,Se*2)),he.readyState=I;var fn=new ne("error",{error:mn});he.dispatchEvent(fn),te(he,he.onerror,fn),mn!=null&&console.error(mn)}},ws=function(){wt=z,ft!=null&&(ft.abort(),ft=void 0),st!==0&&(i(st),st=0),he.readyState=z},ka=function(){if(st=0,wt!==H){if(!ke&&ft!=null)bc(new Error("No activity within "+ze+" milliseconds. "+(wt===I?"No response received.":Ne+" chars received.")+" Reconnecting.")),ft!=null&&(ft.abort(),ft=void 0);else{var mn=Math.max((ke||Date.now())+ze-Date.now(),1);ke=!1,st=r(function(){ka()},mn)}return}ke=!1,Ne=0,st=r(function(){ka()},ze),wt=I,kt="",It="",Dt=_e,Cr="",ys=0,ii=0,Vn=B;var fn=xe;if(xe.slice(0,5)!=="data:"&&xe.slice(0,5)!=="blob:"&&_e!==""){var Jn=xe.indexOf("?");fn=Jn===-1?xe:xe.slice(0,Jn+1)+xe.slice(Jn+1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g,function(er,Mn){return Mn===He?"":er}),fn+=(xe.indexOf("?")===-1?"?":"&")+He+"="+encodeURIComponent(_e)}var Hn=he.withCredentials,en={};en.Accept="text/event-stream";var Mt=he.headers;if(Mt!=null)for(var tn in Mt)Object.prototype.hasOwnProperty.call(Mt,tn)&&(en[tn]=Mt[tn]);try{ft=Xe.open(Ge,bs,La,bc,fn,Hn,en)}catch(er){throw ws(),er}};he.url=xe,he.readyState=I,he.withCredentials=Le,he.headers=je,he._close=ws,ka()}ue.prototype=Object.create(K.prototype),ue.prototype.CONNECTING=I,ue.prototype.OPEN=D,ue.prototype.CLOSED=z,ue.prototype.close=function(){this._close()},ue.CONNECTING=I,ue.OPEN=D,ue.CLOSED=z,ue.prototype.withCredentials=void 0;var ve=f;a!=null&&(f==null||!("withCredentials"in f.prototype))&&(ve=ue),function(he){{var xe=he(t);xe!==void 0&&(e.exports=xe)}}(function(he){he.EventSourcePolyfill=ue,he.NativeEventSource=f,he.EventSource=ve})})(typeof globalThis>"u"?typeof window<"u"?window:typeof self<"u"?self:Aae:globalThis)}(Sp,Sp.exports)),Sp.exports}var Oae=Eae();const QT=6048e5,Tae=864e5,rU=6e4,JT=36e5,Jv=43200,B6=1440,U6=Symbol.for("constructDateFrom");function xr(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&U6 in e?e[U6](t):e instanceof Date?new e.constructor(t):new Date(t)}function Rt(e,t){return xr(t||e,e)}function e3(e,t,n){const r=Rt(e,n==null?void 0:n.in);return isNaN(t)?xr(e,NaN):(t&&r.setDate(r.getDate()+t),r)}function jae(e,t,n){const r=Rt(e,n==null?void 0:n.in);if(isNaN(t))return xr(e,NaN);if(!t)return r;const i=r.getDate(),a=xr(e,r.getTime());a.setMonth(r.getMonth()+t+1,0);const o=a.getDate();return i>=o?a:(r.setFullYear(a.getFullYear(),a.getMonth(),i),r)}function Pae(e,t,n){const{years:r=0,months:i=0,weeks:a=0,days:o=0,hours:l=0,minutes:f=0,seconds:u=0}=t,h=Rt(e,n==null?void 0:n.in),m=i||r?jae(h,i+r*12):h,g=o||a?e3(m,o+a*7):m,_=f+l*60,b=(u+_*60)*1e3;return xr(e,+g+b)}let Rae={};function sg(){return Rae}function nc(e,t){var l,f,u,h;const n=sg(),r=(t==null?void 0:t.weekStartsOn)??((f=(l=t==null?void 0:t.locale)==null?void 0:l.options)==null?void 0:f.weekStartsOn)??n.weekStartsOn??((h=(u=n.locale)==null?void 0:u.options)==null?void 0:h.weekStartsOn)??0,i=Rt(e,t==null?void 0:t.in),a=i.getDay(),o=(a<r?7:0)+a-r;return i.setDate(i.getDate()-o),i.setHours(0,0,0,0),i}function im(e,t){return nc(e,{...t,weekStartsOn:1})}function iU(e,t){const n=Rt(e,t==null?void 0:t.in),r=n.getFullYear(),i=xr(n,0);i.setFullYear(r+1,0,4),i.setHours(0,0,0,0);const a=im(i),o=xr(n,0);o.setFullYear(r,0,4),o.setHours(0,0,0,0);const l=im(o);return n.getTime()>=a.getTime()?r+1:n.getTime()>=l.getTime()?r:r-1}function Gf(e){const t=Rt(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 dc(e,...t){const n=xr.bind(null,e||t.find(r=>typeof r=="object"));return t.map(n)}function rc(e,t){const n=Rt(e,t==null?void 0:t.in);return n.setHours(0,0,0,0),n}function Qb(e,t,n){const[r,i]=dc(n==null?void 0:n.in,e,t),a=rc(r),o=rc(i),l=+a-Gf(a),f=+o-Gf(o);return Math.round((l-f)/Tae)}function Mae(e,t){const n=iU(e,t),r=xr(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),im(r)}function aU(e,t){let n,r=t==null?void 0:t.in;return e.forEach(i=>{!r&&typeof i=="object"&&(r=xr.bind(null,i));const a=Rt(i,r);(!n||n<a||isNaN(+a))&&(n=a)}),xr(r,n||NaN)}function Nae(e,t){let n,r=t==null?void 0:t.in;return e.forEach(i=>{!r&&typeof i=="object"&&(r=xr.bind(null,i));const a=Rt(i,r);(!n||n>a||isNaN(+a))&&(n=a)}),xr(r,n||NaN)}function Ry(e,t){const n=+Rt(e)-+Rt(t);return n<0?-1:n>0?1:n}function Lae(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function kae(e){return!(!Lae(e)&&typeof e!="number"||isNaN(+Rt(e)))}function o0(e,t,n){const[r,i]=dc(n==null?void 0:n.in,e,t),a=r.getFullYear()-i.getFullYear(),o=r.getMonth()-i.getMonth();return a*12+o}function Dae(e,t,n){const[r,i]=dc(n==null?void 0:n.in,e,t),a=nc(r,n),o=nc(i,n),l=+a-Gf(a),f=+o-Gf(o);return Math.round((l-f)/QT)}function oU(e,t,n){const[r,i]=dc(n==null?void 0:n.in,e,t),a=z6(r,i),o=Math.abs(Qb(r,i));r.setDate(r.getDate()-a*o);const l=+(z6(r,i)===-a),f=a*(o-l);return f===0?0:f}function z6(e,t){const n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function sU(e){return t=>{const r=(e?Math[e]:Math.trunc)(t);return r===0?0:r}}function Iae(e,t,n){const[r,i]=dc(n==null?void 0:n.in,e,t),a=(+r-+i)/JT;return sU(n==null?void 0:n.roundingMethod)(a)}function $ae(e,t){return+Rt(e)-+Rt(t)}function Wf(e,t){const n=Rt(e,t==null?void 0:t.in);return n.setHours(23,59,59,999),n}function Bae(e,t){const n=Rt(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 Uae(e,t){const n=Rt(e,t==null?void 0:t.in);return+Wf(n,t)==+Bae(n,t)}function zae(e,t,n){const[r,i,a]=dc(n==null?void 0:n.in,e,e,t),o=Ry(i,a),l=Math.abs(o0(i,a));if(l<1)return 0;i.getMonth()===1&&i.getDate()>27&&i.setDate(30),i.setMonth(i.getMonth()-o*l);let f=Ry(i,a)===-o;Uae(r)&&l===1&&Ry(r,a)===1&&(f=!1);const u=o*(l-+f);return u===0?0:u}function Fae(e,t,n){const r=$ae(e,t)/1e3;return sU(n==null?void 0:n.roundingMethod)(r)}function qae(e,t){const n=Rt(e,t==null?void 0:t.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function Vae(e,t){const n=t==null?void 0:t.weekStartsOn,r=Rt(e,t==null?void 0:t.in),i=r.getDay(),a=(i<n?-7:0)+6-(i-n);return r.setDate(r.getDate()+a),r.setHours(23,59,59,999),r}function Hae(e,t){return Vae(e,{...t,weekStartsOn:1})}const Gae={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"}},Wae=(e,t,n)=>{let r;const i=Gae[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 bx(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const Yae={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Kae={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Zae={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Xae={date:bx({formats:Yae,defaultWidth:"full"}),time:bx({formats:Kae,defaultWidth:"full"}),dateTime:bx({formats:Zae,defaultWidth:"full"})},Qae={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Jae=(e,t,n,r)=>Qae[e];function rp(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const o=e.defaultFormattingWidth||e.defaultWidth,l=n!=null&&n.width?String(n.width):o;i=e.formattingValues[l]||e.formattingValues[o]}else{const o=e.defaultWidth,l=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[l]||e.values[o]}const a=e.argumentCallback?e.argumentCallback(t):t;return i[a]}}const eoe={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},toe={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},noe={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"]},roe={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"]},ioe={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"}},aoe={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"}},ooe=(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"},soe={ordinalNumber:ooe,era:rp({values:eoe,defaultWidth:"wide"}),quarter:rp({values:toe,defaultWidth:"wide",argumentCallback:e=>e-1}),month:rp({values:noe,defaultWidth:"wide"}),day:rp({values:roe,defaultWidth:"wide"}),dayPeriod:rp({values:ioe,defaultWidth:"wide",formattingValues:aoe,defaultFormattingWidth:"wide"})};function ip(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(i);if(!a)return null;const o=a[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],f=Array.isArray(l)?uoe(l,m=>m.test(o)):loe(l,m=>m.test(o));let u;u=e.valueCallback?e.valueCallback(f):f,u=n.valueCallback?n.valueCallback(u):u;const h=t.slice(o.length);return{value:u,rest:h}}}function loe(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function uoe(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function coe(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],a=t.match(e.parsePattern);if(!a)return null;let o=e.valueCallback?e.valueCallback(a[0]):a[0];o=n.valueCallback?n.valueCallback(o):o;const l=t.slice(i.length);return{value:o,rest:l}}}const foe=/^(\d+)(th|st|nd|rd)?/i,doe=/\d+/i,hoe={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},poe={any:[/^b/i,/^(a|c)/i]},moe={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},goe={any:[/1/i,/2/i,/3/i,/4/i]},voe={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},yoe={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]},boe={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},woe={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]},_oe={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},xoe={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}},Soe={ordinalNumber:coe({matchPattern:foe,parsePattern:doe,valueCallback:e=>parseInt(e,10)}),era:ip({matchPatterns:hoe,defaultMatchWidth:"wide",parsePatterns:poe,defaultParseWidth:"any"}),quarter:ip({matchPatterns:moe,defaultMatchWidth:"wide",parsePatterns:goe,defaultParseWidth:"any",valueCallback:e=>e+1}),month:ip({matchPatterns:voe,defaultMatchWidth:"wide",parsePatterns:yoe,defaultParseWidth:"any"}),day:ip({matchPatterns:boe,defaultMatchWidth:"wide",parsePatterns:woe,defaultParseWidth:"any"}),dayPeriod:ip({matchPatterns:_oe,defaultMatchWidth:"any",parsePatterns:xoe,defaultParseWidth:"any"})},lU={code:"en-US",formatDistance:Wae,formatLong:Xae,formatRelative:Jae,localize:soe,match:Soe,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Coe(e,t){const n=Rt(e,t==null?void 0:t.in);return Qb(n,qae(n))+1}function Aoe(e,t){const n=Rt(e,t==null?void 0:t.in),r=+im(n)-+Mae(n);return Math.round(r/QT)+1}function uU(e,t){var h,m,g,_;const n=Rt(e,t==null?void 0:t.in),r=n.getFullYear(),i=sg(),a=(t==null?void 0:t.firstWeekContainsDate)??((m=(h=t==null?void 0:t.locale)==null?void 0:h.options)==null?void 0:m.firstWeekContainsDate)??i.firstWeekContainsDate??((_=(g=i.locale)==null?void 0:g.options)==null?void 0:_.firstWeekContainsDate)??1,o=xr((t==null?void 0:t.in)||e,0);o.setFullYear(r+1,0,a),o.setHours(0,0,0,0);const l=nc(o,t),f=xr((t==null?void 0:t.in)||e,0);f.setFullYear(r,0,a),f.setHours(0,0,0,0);const u=nc(f,t);return+n>=+l?r+1:+n>=+u?r:r-1}function Eoe(e,t){var l,f,u,h;const n=sg(),r=(t==null?void 0:t.firstWeekContainsDate)??((f=(l=t==null?void 0:t.locale)==null?void 0:l.options)==null?void 0:f.firstWeekContainsDate)??n.firstWeekContainsDate??((h=(u=n.locale)==null?void 0:u.options)==null?void 0:h.firstWeekContainsDate)??1,i=uU(e,t),a=xr((t==null?void 0:t.in)||e,0);return a.setFullYear(i,0,r),a.setHours(0,0,0,0),nc(a,t)}function Ooe(e,t){const n=Rt(e,t==null?void 0:t.in),r=+nc(n,t)-+Eoe(n,t);return Math.round(r/QT)+1}function Pt(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const fl={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return Pt(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):Pt(n+1,2)},d(e,t){return Pt(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 Pt(e.getHours()%12||12,t.length)},H(e,t){return Pt(e.getHours(),t.length)},m(e,t){return Pt(e.getMinutes(),t.length)},s(e,t){return Pt(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),i=Math.trunc(r*Math.pow(10,n-3));return Pt(i,t.length)}},hf={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},F6={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 fl.y(e,t)},Y:function(e,t,n,r){const i=uU(e,r),a=i>0?i:1-i;if(t==="YY"){const o=a%100;return Pt(o,2)}return t==="Yo"?n.ordinalNumber(a,{unit:"year"}):Pt(a,t.length)},R:function(e,t){const n=iU(e);return Pt(n,t.length)},u:function(e,t){const n=e.getFullYear();return Pt(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 Pt(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 Pt(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 fl.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 Pt(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=Ooe(e,r);return t==="wo"?n.ordinalNumber(i,{unit:"week"}):Pt(i,t.length)},I:function(e,t,n){const r=Aoe(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):Pt(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):fl.d(e,t)},D:function(e,t,n){const r=Coe(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):Pt(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(),a=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return Pt(a,2);case"eo":return n.ordinalNumber(a,{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(),a=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return Pt(a,t.length);case"co":return n.ordinalNumber(a,{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 Pt(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=hf.noon:r===0?i=hf.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=hf.evening:r>=12?i=hf.afternoon:r>=4?i=hf.morning:i=hf.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 fl.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):fl.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):Pt(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):Pt(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):fl.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):fl.s(e,t)},S:function(e,t){return fl.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return V6(r);case"XXXX":case"XX":return Nu(r);case"XXXXX":case"XXX":default:return Nu(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return V6(r);case"xxxx":case"xx":return Nu(r);case"xxxxx":case"xxx":default:return Nu(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+q6(r,":");case"OOOO":default:return"GMT"+Nu(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+q6(r,":");case"zzzz":default:return"GMT"+Nu(r,":")}},t:function(e,t,n){const r=Math.trunc(+e/1e3);return Pt(r,t.length)},T:function(e,t,n){return Pt(+e,t.length)}};function q6(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Math.trunc(r/60),a=r%60;return a===0?n+String(i):n+String(i)+t+Pt(a,2)}function V6(e,t){return e%60===0?(e>0?"-":"+")+Pt(Math.abs(e)/60,2):Nu(e,t)}function Nu(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Pt(Math.trunc(r/60),2),a=Pt(r%60,2);return n+i+t+a}const H6=(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"})}},cU=(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"})}},Toe=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return H6(e,t);let a;switch(r){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",H6(r,t)).replace("{{time}}",cU(i,t))},joe={p:cU,P:Toe},Poe=/^D+$/,Roe=/^Y+$/,Moe=["D","DD","YY","YYYY"];function Noe(e){return Poe.test(e)}function Loe(e){return Roe.test(e)}function koe(e,t,n){const r=Doe(e,t,n);if(console.warn(r),Moe.includes(e))throw new RangeError(r)}function Doe(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 Ioe=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,$oe=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Boe=/^'([^]*?)'?$/,Uoe=/''/g,zoe=/[a-zA-Z]/;function s0(e,t,n){var h,m,g,_;const r=sg(),i=r.locale??lU,a=r.firstWeekContainsDate??((m=(h=r.locale)==null?void 0:h.options)==null?void 0:m.firstWeekContainsDate)??1,o=r.weekStartsOn??((_=(g=r.locale)==null?void 0:g.options)==null?void 0:_.weekStartsOn)??0,l=Rt(e,n==null?void 0:n.in);if(!kae(l))throw new RangeError("Invalid time value");let f=t.match($oe).map(x=>{const b=x[0];if(b==="p"||b==="P"){const S=joe[b];return S(x,i.formatLong)}return x}).join("").match(Ioe).map(x=>{if(x==="''")return{isToken:!1,value:"'"};const b=x[0];if(b==="'")return{isToken:!1,value:Foe(x)};if(F6[b])return{isToken:!0,value:x};if(b.match(zoe))throw new RangeError("Format string contains an unescaped latin alphabet character `"+b+"`");return{isToken:!1,value:x}});i.localize.preprocessor&&(f=i.localize.preprocessor(l,f));const u={firstWeekContainsDate:a,weekStartsOn:o,locale:i};return f.map(x=>{if(!x.isToken)return x.value;const b=x.value;(Loe(b)||Noe(b))&&koe(b,t,String(e));const S=F6[b[0]];return S(l,b,i.localize,u)}).join("")}function Foe(e){const t=e.match(Boe);return t?t[1].replace(Uoe,"'"):e}function qoe(e,t,n){const r=sg(),i=(n==null?void 0:n.locale)??r.locale??lU,a=2520,o=Ry(e,t);if(isNaN(o))throw new RangeError("Invalid time value");const l=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:o}),[f,u]=dc(n==null?void 0:n.in,...o>0?[t,e]:[e,t]),h=Fae(u,f),m=(Gf(u)-Gf(f))/1e3,g=Math.round((h-m)/60);let _;if(g<2)return g===0?i.formatDistance("lessThanXMinutes",1,l):i.formatDistance("xMinutes",g,l);if(g<45)return i.formatDistance("xMinutes",g,l);if(g<90)return i.formatDistance("aboutXHours",1,l);if(g<B6){const x=Math.round(g/60);return i.formatDistance("aboutXHours",x,l)}else{if(g<a)return i.formatDistance("xDays",1,l);if(g<Jv){const x=Math.round(g/B6);return i.formatDistance("xDays",x,l)}else if(g<Jv*2)return _=Math.round(g/Jv),i.formatDistance("aboutXMonths",_,l)}if(_=zae(u,f),_<12){const x=Math.round(g/Jv);return i.formatDistance("xMonths",x,l)}else{const x=_%12,b=Math.trunc(_/12);return x<3?i.formatDistance("aboutXYears",b,l):x<9?i.formatDistance("overXYears",b,l):i.formatDistance("almostXYears",b+1,l)}}function Voe(e,t){const n=Rt(e,t==null?void 0:t.in);if(isNaN(+n))throw new RangeError("Invalid time value");let r="",i="";const a="-",o=":";{const l=Pt(n.getDate(),2),f=Pt(n.getMonth()+1,2);r=`${Pt(n.getFullYear(),4)}${a}${f}${a}${l}`}{const l=n.getTimezoneOffset();if(l!==0){const _=Math.abs(l),x=Pt(Math.trunc(_/60),2),b=Pt(_%60,2);i=`${l<0?"+":"-"}${x}:${b}`}else i="Z";const f=Pt(n.getHours(),2),u=Pt(n.getMinutes(),2),h=Pt(n.getSeconds(),2),m=r===""?"":"T",g=[f,u,h].join(o);r=`${r}${m}${g}${i}`}return r}function Hoe(e){return Math.trunc(+Rt(e)/1e3)}function Goe(e,t){return+Rt(e)>+Rt(t)}function l0(e,t){return+Rt(e)<+Rt(t)}function yE(e,t){return+Rt(e)==+Rt(t)}function Woe(e,t,n){const r=+Rt(e,n==null?void 0:n.in),[i,a]=[+Rt(t.start,n==null?void 0:n.in),+Rt(t.end,n==null?void 0:n.in)].sort((o,l)=>o-l);return r>=i&&r<=a}function u0(e,t,n){return e3(e,-t,n)}function $l(e,t){const n=()=>xr(t==null?void 0:t.in,NaN),i=Xoe(e);let a;if(i.date){const u=Qoe(i.date,2);a=Joe(u.restDateString,u.year)}if(!a||isNaN(+a))return n();const o=+a;let l=0,f;if(i.time&&(l=ese(i.time),isNaN(l)))return n();if(i.timezone){if(f=tse(i.timezone),isNaN(f))return n()}else{const u=new Date(o+l),h=Rt(0,t==null?void 0:t.in);return h.setFullYear(u.getUTCFullYear(),u.getUTCMonth(),u.getUTCDate()),h.setHours(u.getUTCHours(),u.getUTCMinutes(),u.getUTCSeconds(),u.getUTCMilliseconds()),h}return Rt(o+l+f,t==null?void 0:t.in)}const ey={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Yoe=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,Koe=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,Zoe=/^([+-])(\d{2})(?::?(\d{2}))?$/;function Xoe(e){const t={},n=e.split(ey.dateTimeDelimiter);let r;if(n.length>2)return t;if(/:/.test(n[0])?r=n[0]:(t.date=n[0],r=n[1],ey.timeZoneDelimiter.test(t.date)&&(t.date=e.split(ey.timeZoneDelimiter)[0],r=e.substr(t.date.length,e.length))),r){const i=ey.timezone.exec(r);i?(t.time=r.replace(i[1],""),t.timezone=i[1]):t.time=r}return t}function Qoe(e,t){const n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:NaN,restDateString:""};const i=r[1]?parseInt(r[1]):null,a=r[2]?parseInt(r[2]):null;return{year:a===null?i:a*100,restDateString:e.slice((r[1]||r[2]).length)}}function Joe(e,t){if(t===null)return new Date(NaN);const n=e.match(Yoe);if(!n)return new Date(NaN);const r=!!n[4],i=ap(n[1]),a=ap(n[2])-1,o=ap(n[3]),l=ap(n[4]),f=ap(n[5])-1;if(r)return ose(t,l,f)?nse(t,l,f):new Date(NaN);{const u=new Date(0);return!ise(t,a,o)||!ase(t,i)?new Date(NaN):(u.setUTCFullYear(t,a,Math.max(i,o)),u)}}function ap(e){return e?parseInt(e):1}function ese(e){const t=e.match(Koe);if(!t)return NaN;const n=wx(t[1]),r=wx(t[2]),i=wx(t[3]);return sse(n,r,i)?n*JT+r*rU+i*1e3:NaN}function wx(e){return e&&parseFloat(e.replace(",","."))||0}function tse(e){if(e==="Z")return 0;const t=e.match(Zoe);if(!t)return 0;const n=t[1]==="+"?-1:1,r=parseInt(t[2]),i=t[3]&&parseInt(t[3])||0;return lse(r,i)?n*(r*JT+i*rU):NaN}function nse(e,t,n){const r=new Date(0);r.setUTCFullYear(e,0,4);const i=r.getUTCDay()||7,a=(t-1)*7+n+1-i;return r.setUTCDate(r.getUTCDate()+a),r}const rse=[31,null,31,30,31,30,31,31,30,31,30,31];function fU(e){return e%400===0||e%4===0&&e%100!==0}function ise(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(rse[t]||(fU(e)?29:28))}function ase(e,t){return t>=1&&t<=(fU(e)?366:365)}function ose(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function sse(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function lse(e,t){return t>=0&&t<=59}var My={exports:{}},use=My.exports,G6;function cse(){return G6||(G6=1,function(e,t){(function(n,r){e.exports=r()})(use,()=>(()=>{var n={873:(o,l)=>{var f,u,h=function(){var m=function(X,ne){var H=X,I=C[ne],D=null,z=0,N=null,B=[],Q={},G=function(J,se){D=function(de){for(var ve=new Array(de),he=0;he<de;he+=1){ve[he]=new Array(de);for(var xe=0;xe<de;xe+=1)ve[he][xe]=null}return ve}(z=4*H+17),ae(0,0),ae(z-7,0),ae(0,z-7),ce(),fe(),F(J,se),H>=7&&ye(J),N==null&&(N=te(H,I,B)),q(N,se)},ae=function(J,se){for(var de=-1;de<=7;de+=1)if(!(J+de<=-1||z<=J+de))for(var ve=-1;ve<=7;ve+=1)se+ve<=-1||z<=se+ve||(D[J+de][se+ve]=0<=de&&de<=6&&(ve==0||ve==6)||0<=ve&&ve<=6&&(de==0||de==6)||2<=de&&de<=4&&2<=ve&&ve<=4)},fe=function(){for(var J=8;J<z-8;J+=1)D[J][6]==null&&(D[J][6]=J%2==0);for(var se=8;se<z-8;se+=1)D[6][se]==null&&(D[6][se]=se%2==0)},ce=function(){for(var J=A.getPatternPosition(H),se=0;se<J.length;se+=1)for(var de=0;de<J.length;de+=1){var ve=J[se],he=J[de];if(D[ve][he]==null)for(var xe=-2;xe<=2;xe+=1)for(var Oe=-2;Oe<=2;Oe+=1)D[ve+xe][he+Oe]=xe==-2||xe==2||Oe==-2||Oe==2||xe==0&&Oe==0}},ye=function(J){for(var se=A.getBCHTypeNumber(H),de=0;de<18;de+=1){var ve=!J&&(se>>de&1)==1;D[Math.floor(de/3)][de%3+z-8-3]=ve}for(de=0;de<18;de+=1)ve=!J&&(se>>de&1)==1,D[de%3+z-8-3][Math.floor(de/3)]=ve},F=function(J,se){for(var de=I<<3|se,ve=A.getBCHTypeInfo(de),he=0;he<15;he+=1){var xe=!J&&(ve>>he&1)==1;he<6?D[he][8]=xe:he<8?D[he+1][8]=xe:D[z-15+he][8]=xe}for(he=0;he<15;he+=1)xe=!J&&(ve>>he&1)==1,he<8?D[8][z-he-1]=xe:he<9?D[8][15-he-1+1]=xe:D[8][15-he-1]=xe;D[z-8][8]=!J},q=function(J,se){for(var de=-1,ve=z-1,he=7,xe=0,Oe=A.getMaskFunction(se),Le=z-1;Le>0;Le-=2)for(Le==6&&(Le-=1);;){for(var He=0;He<2;He+=1)if(D[ve][Le-He]==null){var $e=!1;xe<J.length&&($e=(J[xe]>>>he&1)==1),Oe(ve,Le-He)&&($e=!$e),D[ve][Le-He]=$e,(he-=1)==-1&&(xe+=1,he=7)}if((ve+=de)<0||z<=ve){ve-=de,de=-de;break}}},te=function(J,se,de){for(var ve=j.getRSBlocks(J,se),he=R(),xe=0;xe<de.length;xe+=1){var Oe=de[xe];he.put(Oe.getMode(),4),he.put(Oe.getLength(),A.getLengthInBits(Oe.getMode(),J)),Oe.write(he)}var Le=0;for(xe=0;xe<ve.length;xe+=1)Le+=ve[xe].dataCount;if(he.getLengthInBits()>8*Le)throw"code length overflow. ("+he.getLengthInBits()+">"+8*Le+")";for(he.getLengthInBits()+4<=8*Le&&he.put(0,4);he.getLengthInBits()%8!=0;)he.putBit(!1);for(;!(he.getLengthInBits()>=8*Le||(he.put(236,8),he.getLengthInBits()>=8*Le));)he.put(17,8);return function(He,$e){for(var ze=0,_e=0,Se=0,ke=new Array($e.length),Ne=new Array($e.length),je=0;je<$e.length;je+=1){var Fe=$e[je].dataCount,Ge=$e[je].totalCount-Fe;_e=Math.max(_e,Fe),Se=Math.max(Se,Ge),ke[je]=new Array(Fe);for(var Xe=0;Xe<ke[je].length;Xe+=1)ke[je][Xe]=255&He.getBuffer()[Xe+ze];ze+=Fe;var ft=A.getErrorCorrectPolynomial(Ge),st=P(ke[je],ft.getLength()-1).mod(ft);for(Ne[je]=new Array(ft.getLength()-1),Xe=0;Xe<Ne[je].length;Xe+=1){var wt=Xe+st.getLength()-Ne[je].length;Ne[je][Xe]=wt>=0?st.getAt(wt):0}}var kt=0;for(Xe=0;Xe<$e.length;Xe+=1)kt+=$e[Xe].totalCount;var Dt=new Array(kt),It=0;for(Xe=0;Xe<_e;Xe+=1)for(je=0;je<$e.length;je+=1)Xe<ke[je].length&&(Dt[It]=ke[je][Xe],It+=1);for(Xe=0;Xe<Se;Xe+=1)for(je=0;je<$e.length;je+=1)Xe<Ne[je].length&&(Dt[It]=Ne[je][Xe],It+=1);return Dt}(he,ve)};Q.addData=function(J,se){var de=null;switch(se=se||"Byte"){case"Numeric":de=U(J);break;case"Alphanumeric":de=V(J);break;case"Byte":de=Y(J);break;case"Kanji":de=K(J);break;default:throw"mode:"+se}B.push(de),N=null},Q.isDark=function(J,se){if(J<0||z<=J||se<0||z<=se)throw J+","+se;return D[J][se]},Q.getModuleCount=function(){return z},Q.make=function(){if(H<1){for(var J=1;J<40;J++){for(var se=j.getRSBlocks(J,I),de=R(),ve=0;ve<B.length;ve++){var he=B[ve];de.put(he.getMode(),4),de.put(he.getLength(),A.getLengthInBits(he.getMode(),J)),he.write(de)}var xe=0;for(ve=0;ve<se.length;ve++)xe+=se[ve].dataCount;if(de.getLengthInBits()<=8*xe)break}H=J}G(!1,function(){for(var Oe=0,Le=0,He=0;He<8;He+=1){G(!0,He);var $e=A.getLostPoint(Q);(He==0||Oe>$e)&&(Oe=$e,Le=He)}return Le}())},Q.createTableTag=function(J,se){J=J||2;var de="";de+='<table style="',de+=" border-width: 0px; border-style: none;",de+=" border-collapse: collapse;",de+=" padding: 0px; margin: "+(se=se===void 0?4*J:se)+"px;",de+='">',de+="<tbody>";for(var ve=0;ve<Q.getModuleCount();ve+=1){de+="<tr>";for(var he=0;he<Q.getModuleCount();he+=1)de+='<td style="',de+=" border-width: 0px; border-style: none;",de+=" border-collapse: collapse;",de+=" padding: 0px; margin: 0px;",de+=" width: "+J+"px;",de+=" height: "+J+"px;",de+=" background-color: ",de+=Q.isDark(ve,he)?"#000000":"#ffffff",de+=";",de+='"/>';de+="</tr>"}return(de+="</tbody>")+"</table>"},Q.createSvgTag=function(J,se,de,ve){var he={};typeof arguments[0]=="object"&&(J=(he=arguments[0]).cellSize,se=he.margin,de=he.alt,ve=he.title),J=J||2,se=se===void 0?4*J:se,(de=typeof de=="string"?{text:de}:de||{}).text=de.text||null,de.id=de.text?de.id||"qrcode-description":null,(ve=typeof ve=="string"?{text:ve}:ve||{}).text=ve.text||null,ve.id=ve.text?ve.id||"qrcode-title":null;var xe,Oe,Le,He,$e=Q.getModuleCount()*J+2*se,ze="";for(He="l"+J+",0 0,"+J+" -"+J+",0 0,-"+J+"z ",ze+='<svg version="1.1" xmlns="http://www.w3.org/2000/svg"',ze+=he.scalable?"":' width="'+$e+'px" height="'+$e+'px"',ze+=' viewBox="0 0 '+$e+" "+$e+'" ',ze+=' preserveAspectRatio="xMinYMin meet"',ze+=ve.text||de.text?' role="img" aria-labelledby="'+ue([ve.id,de.id].join(" ").trim())+'"':"",ze+=">",ze+=ve.text?'<title id="'+ue(ve.id)+'">'+ue(ve.text)+"</title>":"",ze+=de.text?'<description id="'+ue(de.id)+'">'+ue(de.text)+"</description>":"",ze+='<rect width="100%" height="100%" fill="white" cx="0" cy="0"/>',ze+='<path d="',Oe=0;Oe<Q.getModuleCount();Oe+=1)for(Le=Oe*J+se,xe=0;xe<Q.getModuleCount();xe+=1)Q.isDark(Oe,xe)&&(ze+="M"+(xe*J+se)+","+Le+He);return(ze+='" stroke="transparent" fill="black"/>')+"</svg>"},Q.createDataURL=function(J,se){J=J||2,se=se===void 0?4*J:se;var de=Q.getModuleCount()*J+2*se,ve=se,he=de-se;return ie(de,de,function(xe,Oe){if(ve<=xe&&xe<he&&ve<=Oe&&Oe<he){var Le=Math.floor((xe-ve)/J),He=Math.floor((Oe-ve)/J);return Q.isDark(He,Le)?0:1}return 1})},Q.createImgTag=function(J,se,de){J=J||2,se=se===void 0?4*J:se;var ve=Q.getModuleCount()*J+2*se,he="";return he+="<img",he+=' src="',he+=Q.createDataURL(J,se),he+='"',he+=' width="',he+=ve,he+='"',he+=' height="',he+=ve,he+='"',de&&(he+=' alt="',he+=ue(de),he+='"'),he+"/>"};var ue=function(J){for(var se="",de=0;de<J.length;de+=1){var ve=J.charAt(de);switch(ve){case"<":se+="<";break;case">":se+=">";break;case"&":se+="&";break;case'"':se+=""";break;default:se+=ve}}return se};return Q.createASCII=function(J,se){if((J=J||1)<2)return function(ke){ke=ke===void 0?2:ke;var Ne,je,Fe,Ge,Xe,ft=1*Q.getModuleCount()+2*ke,st=ke,wt=ft-ke,kt={"██":"█","█ ":"▀"," █":"▄"," ":" "},Dt={"██":"▀","█ ":"▀"," █":" "," ":" "},It="";for(Ne=0;Ne<ft;Ne+=2){for(Fe=Math.floor((Ne-st)/1),Ge=Math.floor((Ne+1-st)/1),je=0;je<ft;je+=1)Xe="█",st<=je&&je<wt&&st<=Ne&&Ne<wt&&Q.isDark(Fe,Math.floor((je-st)/1))&&(Xe=" "),st<=je&&je<wt&&st<=Ne+1&&Ne+1<wt&&Q.isDark(Ge,Math.floor((je-st)/1))?Xe+=" ":Xe+="█",It+=ke<1&&Ne+1>=wt?Dt[Xe]:kt[Xe];It+=`
|
||
`}return ft%2&&ke>0?It.substring(0,It.length-ft-1)+Array(ft+1).join("▀"):It.substring(0,It.length-1)}(se);J-=1,se=se===void 0?2*J:se;var de,ve,he,xe,Oe=Q.getModuleCount()*J+2*se,Le=se,He=Oe-se,$e=Array(J+1).join("██"),ze=Array(J+1).join(" "),_e="",Se="";for(de=0;de<Oe;de+=1){for(he=Math.floor((de-Le)/J),Se="",ve=0;ve<Oe;ve+=1)xe=1,Le<=ve&&ve<He&&Le<=de&&de<He&&Q.isDark(he,Math.floor((ve-Le)/J))&&(xe=0),Se+=xe?$e:ze;for(he=0;he<J;he+=1)_e+=Se+`
|
||
`}return _e.substring(0,_e.length-1)},Q.renderTo2dContext=function(J,se){se=se||2;for(var de=Q.getModuleCount(),ve=0;ve<de;ve++)for(var he=0;he<de;he++)J.fillStyle=Q.isDark(ve,he)?"black":"white",J.fillRect(ve*se,he*se,se,se)},Q};m.stringToBytes=(m.stringToBytesFuncs={default:function(X){for(var ne=[],H=0;H<X.length;H+=1){var I=X.charCodeAt(H);ne.push(255&I)}return ne}}).default,m.createStringToBytes=function(X,ne){var H=function(){for(var D=ee(X),z=function(){var fe=D.read();if(fe==-1)throw"eof";return fe},N=0,B={};;){var Q=D.read();if(Q==-1)break;var G=z(),ae=z()<<8|z();B[String.fromCharCode(Q<<8|G)]=ae,N+=1}if(N!=ne)throw N+" != "+ne;return B}(),I=63;return function(D){for(var z=[],N=0;N<D.length;N+=1){var B=D.charCodeAt(N);if(B<128)z.push(B);else{var Q=H[D.charAt(N)];typeof Q=="number"?(255&Q)==Q?z.push(Q):(z.push(Q>>>8),z.push(255&Q)):z.push(I)}}return z}};var g,_,x,b,S,C={L:1,M:0,Q:3,H:2},A=(g=[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],_=1335,x=7973,S=function(X){for(var ne=0;X!=0;)ne+=1,X>>>=1;return ne},(b={}).getBCHTypeInfo=function(X){for(var ne=X<<10;S(ne)-S(_)>=0;)ne^=_<<S(ne)-S(_);return 21522^(X<<10|ne)},b.getBCHTypeNumber=function(X){for(var ne=X<<12;S(ne)-S(x)>=0;)ne^=x<<S(ne)-S(x);return X<<12|ne},b.getPatternPosition=function(X){return g[X-1]},b.getMaskFunction=function(X){switch(X){case 0:return function(ne,H){return(ne+H)%2==0};case 1:return function(ne,H){return ne%2==0};case 2:return function(ne,H){return H%3==0};case 3:return function(ne,H){return(ne+H)%3==0};case 4:return function(ne,H){return(Math.floor(ne/2)+Math.floor(H/3))%2==0};case 5:return function(ne,H){return ne*H%2+ne*H%3==0};case 6:return function(ne,H){return(ne*H%2+ne*H%3)%2==0};case 7:return function(ne,H){return(ne*H%3+(ne+H)%2)%2==0};default:throw"bad maskPattern:"+X}},b.getErrorCorrectPolynomial=function(X){for(var ne=P([1],0),H=0;H<X;H+=1)ne=ne.multiply(P([1,O.gexp(H)],0));return ne},b.getLengthInBits=function(X,ne){if(1<=ne&&ne<10)switch(X){case 1:return 10;case 2:return 9;case 4:case 8:return 8;default:throw"mode:"+X}else if(ne<27)switch(X){case 1:return 12;case 2:return 11;case 4:return 16;case 8:return 10;default:throw"mode:"+X}else{if(!(ne<41))throw"type:"+ne;switch(X){case 1:return 14;case 2:return 13;case 4:return 16;case 8:return 12;default:throw"mode:"+X}}},b.getLostPoint=function(X){for(var ne=X.getModuleCount(),H=0,I=0;I<ne;I+=1)for(var D=0;D<ne;D+=1){for(var z=0,N=X.isDark(I,D),B=-1;B<=1;B+=1)if(!(I+B<0||ne<=I+B))for(var Q=-1;Q<=1;Q+=1)D+Q<0||ne<=D+Q||B==0&&Q==0||N==X.isDark(I+B,D+Q)&&(z+=1);z>5&&(H+=3+z-5)}for(I=0;I<ne-1;I+=1)for(D=0;D<ne-1;D+=1){var G=0;X.isDark(I,D)&&(G+=1),X.isDark(I+1,D)&&(G+=1),X.isDark(I,D+1)&&(G+=1),X.isDark(I+1,D+1)&&(G+=1),G!=0&&G!=4||(H+=3)}for(I=0;I<ne;I+=1)for(D=0;D<ne-6;D+=1)X.isDark(I,D)&&!X.isDark(I,D+1)&&X.isDark(I,D+2)&&X.isDark(I,D+3)&&X.isDark(I,D+4)&&!X.isDark(I,D+5)&&X.isDark(I,D+6)&&(H+=40);for(D=0;D<ne;D+=1)for(I=0;I<ne-6;I+=1)X.isDark(I,D)&&!X.isDark(I+1,D)&&X.isDark(I+2,D)&&X.isDark(I+3,D)&&X.isDark(I+4,D)&&!X.isDark(I+5,D)&&X.isDark(I+6,D)&&(H+=40);var ae=0;for(D=0;D<ne;D+=1)for(I=0;I<ne;I+=1)X.isDark(I,D)&&(ae+=1);return H+Math.abs(100*ae/ne/ne-50)/5*10},b),O=function(){for(var X=new Array(256),ne=new Array(256),H=0;H<8;H+=1)X[H]=1<<H;for(H=8;H<256;H+=1)X[H]=X[H-4]^X[H-5]^X[H-6]^X[H-8];for(H=0;H<255;H+=1)ne[X[H]]=H;return{glog:function(I){if(I<1)throw"glog("+I+")";return ne[I]},gexp:function(I){for(;I<0;)I+=255;for(;I>=256;)I-=255;return X[I]}}}();function P(X,ne){if(X.length===void 0)throw X.length+"/"+ne;var H=function(){for(var D=0;D<X.length&&X[D]==0;)D+=1;for(var z=new Array(X.length-D+ne),N=0;N<X.length-D;N+=1)z[N]=X[N+D];return z}(),I={getAt:function(D){return H[D]},getLength:function(){return H.length},multiply:function(D){for(var z=new Array(I.getLength()+D.getLength()-1),N=0;N<I.getLength();N+=1)for(var B=0;B<D.getLength();B+=1)z[N+B]^=O.gexp(O.glog(I.getAt(N))+O.glog(D.getAt(B)));return P(z,0)},mod:function(D){if(I.getLength()-D.getLength()<0)return I;for(var z=O.glog(I.getAt(0))-O.glog(D.getAt(0)),N=new Array(I.getLength()),B=0;B<I.getLength();B+=1)N[B]=I.getAt(B);for(B=0;B<D.getLength();B+=1)N[B]^=O.gexp(O.glog(D.getAt(B))+z);return P(N,0).mod(D)}};return I}var j=function(){var X=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12,7,37,13],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]],ne=function(I,D){var z={};return z.totalCount=I,z.dataCount=D,z},H={getRSBlocks:function(I,D){var z=function(ye,F){switch(F){case C.L:return X[4*(ye-1)+0];case C.M:return X[4*(ye-1)+1];case C.Q:return X[4*(ye-1)+2];case C.H:return X[4*(ye-1)+3];default:return}}(I,D);if(z===void 0)throw"bad rs block @ typeNumber:"+I+"/errorCorrectionLevel:"+D;for(var N=z.length/3,B=[],Q=0;Q<N;Q+=1)for(var G=z[3*Q+0],ae=z[3*Q+1],fe=z[3*Q+2],ce=0;ce<G;ce+=1)B.push(ne(ae,fe));return B}};return H}(),R=function(){var X=[],ne=0,H={getBuffer:function(){return X},getAt:function(I){var D=Math.floor(I/8);return(X[D]>>>7-I%8&1)==1},put:function(I,D){for(var z=0;z<D;z+=1)H.putBit((I>>>D-z-1&1)==1)},getLengthInBits:function(){return ne},putBit:function(I){var D=Math.floor(ne/8);X.length<=D&&X.push(0),I&&(X[D]|=128>>>ne%8),ne+=1}};return H},U=function(X){var ne=X,H={getMode:function(){return 1},getLength:function(z){return ne.length},write:function(z){for(var N=ne,B=0;B+2<N.length;)z.put(I(N.substring(B,B+3)),10),B+=3;B<N.length&&(N.length-B==1?z.put(I(N.substring(B,B+1)),4):N.length-B==2&&z.put(I(N.substring(B,B+2)),7))}},I=function(z){for(var N=0,B=0;B<z.length;B+=1)N=10*N+D(z.charAt(B));return N},D=function(z){if("0"<=z&&z<="9")return z.charCodeAt(0)-48;throw"illegal char :"+z};return H},V=function(X){var ne=X,H={getMode:function(){return 2},getLength:function(D){return ne.length},write:function(D){for(var z=ne,N=0;N+1<z.length;)D.put(45*I(z.charAt(N))+I(z.charAt(N+1)),11),N+=2;N<z.length&&D.put(I(z.charAt(N)),6)}},I=function(D){if("0"<=D&&D<="9")return D.charCodeAt(0)-48;if("A"<=D&&D<="Z")return D.charCodeAt(0)-65+10;switch(D){case" ":return 36;case"$":return 37;case"%":return 38;case"*":return 39;case"+":return 40;case"-":return 41;case".":return 42;case"/":return 43;case":":return 44;default:throw"illegal char :"+D}};return H},Y=function(X){var ne=m.stringToBytes(X);return{getMode:function(){return 4},getLength:function(H){return ne.length},write:function(H){for(var I=0;I<ne.length;I+=1)H.put(ne[I],8)}}},K=function(X){var ne=m.stringToBytesFuncs.SJIS;if(!ne)throw"sjis not supported.";(function(){var D=ne("友");if(D.length!=2||(D[0]<<8|D[1])!=38726)throw"sjis not supported."})();var H=ne(X),I={getMode:function(){return 8},getLength:function(D){return~~(H.length/2)},write:function(D){for(var z=H,N=0;N+1<z.length;){var B=(255&z[N])<<8|255&z[N+1];if(33088<=B&&B<=40956)B-=33088;else{if(!(57408<=B&&B<=60351))throw"illegal char at "+(N+1)+"/"+B;B-=49472}B=192*(B>>>8&255)+(255&B),D.put(B,13),N+=2}if(N<z.length)throw"illegal char at "+(N+1)}};return I},W=function(){var X=[],ne={writeByte:function(H){X.push(255&H)},writeShort:function(H){ne.writeByte(H),ne.writeByte(H>>>8)},writeBytes:function(H,I,D){I=I||0,D=D||H.length;for(var z=0;z<D;z+=1)ne.writeByte(H[z+I])},writeString:function(H){for(var I=0;I<H.length;I+=1)ne.writeByte(H.charCodeAt(I))},toByteArray:function(){return X},toString:function(){var H="";H+="[";for(var I=0;I<X.length;I+=1)I>0&&(H+=","),H+=X[I];return H+"]"}};return ne},ee=function(X){var ne=X,H=0,I=0,D=0,z={read:function(){for(;D<8;){if(H>=ne.length){if(D==0)return-1;throw"unexpected end of file./"+D}var B=ne.charAt(H);if(H+=1,B=="=")return D=0,-1;B.match(/^\s$/)||(I=I<<6|N(B.charCodeAt(0)),D+=6)}var Q=I>>>D-8&255;return D-=8,Q}},N=function(B){if(65<=B&&B<=90)return B-65;if(97<=B&&B<=122)return B-97+26;if(48<=B&&B<=57)return B-48+52;if(B==43)return 62;if(B==47)return 63;throw"c:"+B};return z},ie=function(X,ne,H){for(var I=function(ae,fe){var ce=ae,ye=fe,F=new Array(ae*fe),q={setPixel:function(J,se,de){F[se*ce+J]=de},write:function(J){J.writeString("GIF87a"),J.writeShort(ce),J.writeShort(ye),J.writeByte(128),J.writeByte(0),J.writeByte(0),J.writeByte(0),J.writeByte(0),J.writeByte(0),J.writeByte(255),J.writeByte(255),J.writeByte(255),J.writeString(","),J.writeShort(0),J.writeShort(0),J.writeShort(ce),J.writeShort(ye),J.writeByte(0);var se=te(2);J.writeByte(2);for(var de=0;se.length-de>255;)J.writeByte(255),J.writeBytes(se,de,255),de+=255;J.writeByte(se.length-de),J.writeBytes(se,de,se.length-de),J.writeByte(0),J.writeString(";")}},te=function(J){for(var se=1<<J,de=1+(1<<J),ve=J+1,he=ue(),xe=0;xe<se;xe+=1)he.add(String.fromCharCode(xe));he.add(String.fromCharCode(se)),he.add(String.fromCharCode(de));var Oe,Le,He,$e=W(),ze=(Oe=$e,Le=0,He=0,{write:function(Ne,je){if(Ne>>>je)throw"length over";for(;Le+je>=8;)Oe.writeByte(255&(Ne<<Le|He)),je-=8-Le,Ne>>>=8-Le,He=0,Le=0;He|=Ne<<Le,Le+=je},flush:function(){Le>0&&Oe.writeByte(He)}});ze.write(se,ve);var _e=0,Se=String.fromCharCode(F[_e]);for(_e+=1;_e<F.length;){var ke=String.fromCharCode(F[_e]);_e+=1,he.contains(Se+ke)?Se+=ke:(ze.write(he.indexOf(Se),ve),he.size()<4095&&(he.size()==1<<ve&&(ve+=1),he.add(Se+ke)),Se=ke)}return ze.write(he.indexOf(Se),ve),ze.write(de,ve),ze.flush(),$e.toByteArray()},ue=function(){var J={},se=0,de={add:function(ve){if(de.contains(ve))throw"dup key:"+ve;J[ve]=se,se+=1},size:function(){return se},indexOf:function(ve){return J[ve]},contains:function(ve){return J[ve]!==void 0}};return de};return q}(X,ne),D=0;D<ne;D+=1)for(var z=0;z<X;z+=1)I.setPixel(z,D,H(z,D));var N=W();I.write(N);for(var B=function(){var ae=0,fe=0,ce=0,ye="",F={},q=function(ue){ye+=String.fromCharCode(te(63&ue))},te=function(ue){if(!(ue<0)){if(ue<26)return 65+ue;if(ue<52)return ue-26+97;if(ue<62)return ue-52+48;if(ue==62)return 43;if(ue==63)return 47}throw"n:"+ue};return F.writeByte=function(ue){for(ae=ae<<8|255&ue,fe+=8,ce+=1;fe>=6;)q(ae>>>fe-6),fe-=6},F.flush=function(){if(fe>0&&(q(ae<<6-fe),ae=0,fe=0),ce%3!=0)for(var ue=3-ce%3,J=0;J<ue;J+=1)ye+="="},F.toString=function(){return ye},F}(),Q=N.toByteArray(),G=0;G<Q.length;G+=1)B.writeByte(Q[G]);return B.flush(),"data:image/gif;base64,"+B};return m}();h.stringToBytesFuncs["UTF-8"]=function(m){return function(g){for(var _=[],x=0;x<g.length;x++){var b=g.charCodeAt(x);b<128?_.push(b):b<2048?_.push(192|b>>6,128|63&b):b<55296||b>=57344?_.push(224|b>>12,128|b>>6&63,128|63&b):(x++,b=65536+((1023&b)<<10|1023&g.charCodeAt(x)),_.push(240|b>>18,128|b>>12&63,128|b>>6&63,128|63&b))}return _}(m)},(u=typeof(f=function(){return h})=="function"?f.apply(l,[]):f)===void 0||(o.exports=u)}},r={};function i(o){var l=r[o];if(l!==void 0)return l.exports;var f=r[o]={exports:{}};return n[o](f,f.exports,i),f.exports}i.n=o=>{var l=o&&o.__esModule?()=>o.default:()=>o;return i.d(l,{a:l}),l},i.d=(o,l)=>{for(var f in l)i.o(l,f)&&!i.o(o,f)&&Object.defineProperty(o,f,{enumerable:!0,get:l[f]})},i.o=(o,l)=>Object.prototype.hasOwnProperty.call(o,l);var a={};return(()=>{i.d(a,{default:()=>ne});const o=H=>!!H&&typeof H=="object"&&!Array.isArray(H);function l(H,...I){if(!I.length)return H;const D=I.shift();return D!==void 0&&o(H)&&o(D)?(H=Object.assign({},H),Object.keys(D).forEach(z=>{const N=H[z],B=D[z];Array.isArray(N)&&Array.isArray(B)?H[z]=B:o(N)&&o(B)?H[z]=l(Object.assign({},N),B):H[z]=B}),l(H,...I)):H}function f(H,I){const D=document.createElement("a");D.download=I,D.href=H,document.body.appendChild(D),D.click(),document.body.removeChild(D)}const u={L:.07,M:.15,Q:.25,H:.3};class h{constructor({svg:I,type:D,window:z}){this._svg=I,this._type=D,this._window=z}draw(I,D,z,N){let B;switch(this._type){case"dots":B=this._drawDot;break;case"classy":B=this._drawClassy;break;case"classy-rounded":B=this._drawClassyRounded;break;case"rounded":B=this._drawRounded;break;case"extra-rounded":B=this._drawExtraRounded;break;default:B=this._drawSquare}B.call(this,{x:I,y:D,size:z,getNeighbor:N})}_rotateFigure({x:I,y:D,size:z,rotation:N=0,draw:B}){var Q;const G=I+z/2,ae=D+z/2;B(),(Q=this._element)===null||Q===void 0||Q.setAttribute("transform",`rotate(${180*N/Math.PI},${G},${ae})`)}_basicDot(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","circle"),this._element.setAttribute("cx",String(z+D/2)),this._element.setAttribute("cy",String(N+D/2)),this._element.setAttribute("r",String(D/2))}}))}_basicSquare(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","rect"),this._element.setAttribute("x",String(z)),this._element.setAttribute("y",String(N)),this._element.setAttribute("width",String(D)),this._element.setAttribute("height",String(D))}}))}_basicSideRounded(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("d",`M ${z} ${N}v ${D}h `+D/2+`a ${D/2} ${D/2}, 0, 0, 0, 0 ${-D}`)}}))}_basicCornerRounded(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("d",`M ${z} ${N}v ${D}h ${D}v `+-D/2+`a ${D/2} ${D/2}, 0, 0, 0, ${-D/2} ${-D/2}`)}}))}_basicCornerExtraRounded(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("d",`M ${z} ${N}v ${D}h ${D}a ${D} ${D}, 0, 0, 0, ${-D} ${-D}`)}}))}_basicCornersRounded(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("d",`M ${z} ${N}v `+D/2+`a ${D/2} ${D/2}, 0, 0, 0, ${D/2} ${D/2}h `+D/2+"v "+-D/2+`a ${D/2} ${D/2}, 0, 0, 0, ${-D/2} ${-D/2}`)}}))}_drawDot({x:I,y:D,size:z}){this._basicDot({x:I,y:D,size:z,rotation:0})}_drawSquare({x:I,y:D,size:z}){this._basicSquare({x:I,y:D,size:z,rotation:0})}_drawRounded({x:I,y:D,size:z,getNeighbor:N}){const B=N?+N(-1,0):0,Q=N?+N(1,0):0,G=N?+N(0,-1):0,ae=N?+N(0,1):0,fe=B+Q+G+ae;if(fe!==0)if(fe>2||B&&Q||G&&ae)this._basicSquare({x:I,y:D,size:z,rotation:0});else{if(fe===2){let ce=0;return B&&G?ce=Math.PI/2:G&&Q?ce=Math.PI:Q&&ae&&(ce=-Math.PI/2),void this._basicCornerRounded({x:I,y:D,size:z,rotation:ce})}if(fe===1){let ce=0;return G?ce=Math.PI/2:Q?ce=Math.PI:ae&&(ce=-Math.PI/2),void this._basicSideRounded({x:I,y:D,size:z,rotation:ce})}}else this._basicDot({x:I,y:D,size:z,rotation:0})}_drawExtraRounded({x:I,y:D,size:z,getNeighbor:N}){const B=N?+N(-1,0):0,Q=N?+N(1,0):0,G=N?+N(0,-1):0,ae=N?+N(0,1):0,fe=B+Q+G+ae;if(fe!==0)if(fe>2||B&&Q||G&&ae)this._basicSquare({x:I,y:D,size:z,rotation:0});else{if(fe===2){let ce=0;return B&&G?ce=Math.PI/2:G&&Q?ce=Math.PI:Q&&ae&&(ce=-Math.PI/2),void this._basicCornerExtraRounded({x:I,y:D,size:z,rotation:ce})}if(fe===1){let ce=0;return G?ce=Math.PI/2:Q?ce=Math.PI:ae&&(ce=-Math.PI/2),void this._basicSideRounded({x:I,y:D,size:z,rotation:ce})}}else this._basicDot({x:I,y:D,size:z,rotation:0})}_drawClassy({x:I,y:D,size:z,getNeighbor:N}){const B=N?+N(-1,0):0,Q=N?+N(1,0):0,G=N?+N(0,-1):0,ae=N?+N(0,1):0;B+Q+G+ae!==0?B||G?Q||ae?this._basicSquare({x:I,y:D,size:z,rotation:0}):this._basicCornerRounded({x:I,y:D,size:z,rotation:Math.PI/2}):this._basicCornerRounded({x:I,y:D,size:z,rotation:-Math.PI/2}):this._basicCornersRounded({x:I,y:D,size:z,rotation:Math.PI/2})}_drawClassyRounded({x:I,y:D,size:z,getNeighbor:N}){const B=N?+N(-1,0):0,Q=N?+N(1,0):0,G=N?+N(0,-1):0,ae=N?+N(0,1):0;B+Q+G+ae!==0?B||G?Q||ae?this._basicSquare({x:I,y:D,size:z,rotation:0}):this._basicCornerExtraRounded({x:I,y:D,size:z,rotation:Math.PI/2}):this._basicCornerExtraRounded({x:I,y:D,size:z,rotation:-Math.PI/2}):this._basicCornersRounded({x:I,y:D,size:z,rotation:Math.PI/2})}}const m={dot:"dot",square:"square",extraRounded:"extra-rounded"},g=Object.values(m);class _{constructor({svg:I,type:D,window:z}){this._svg=I,this._type=D,this._window=z}draw(I,D,z,N){let B;switch(this._type){case m.square:B=this._drawSquare;break;case m.extraRounded:B=this._drawExtraRounded;break;default:B=this._drawDot}B.call(this,{x:I,y:D,size:z,rotation:N})}_rotateFigure({x:I,y:D,size:z,rotation:N=0,draw:B}){var Q;const G=I+z/2,ae=D+z/2;B(),(Q=this._element)===null||Q===void 0||Q.setAttribute("transform",`rotate(${180*N/Math.PI},${G},${ae})`)}_basicDot(I){const{size:D,x:z,y:N}=I,B=D/7;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("clip-rule","evenodd"),this._element.setAttribute("d",`M ${z+D/2} ${N}a ${D/2} ${D/2} 0 1 0 0.1 0zm 0 ${B}a ${D/2-B} ${D/2-B} 0 1 1 -0.1 0Z`)}}))}_basicSquare(I){const{size:D,x:z,y:N}=I,B=D/7;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("clip-rule","evenodd"),this._element.setAttribute("d",`M ${z} ${N}v ${D}h ${D}v `+-D+`zM ${z+B} ${N+B}h `+(D-2*B)+"v "+(D-2*B)+"h "+(2*B-D)+"z")}}))}_basicExtraRounded(I){const{size:D,x:z,y:N}=I,B=D/7;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","path"),this._element.setAttribute("clip-rule","evenodd"),this._element.setAttribute("d",`M ${z} ${N+2.5*B}v `+2*B+`a ${2.5*B} ${2.5*B}, 0, 0, 0, ${2.5*B} ${2.5*B}h `+2*B+`a ${2.5*B} ${2.5*B}, 0, 0, 0, ${2.5*B} ${2.5*-B}v `+-2*B+`a ${2.5*B} ${2.5*B}, 0, 0, 0, ${2.5*-B} ${2.5*-B}h `+-2*B+`a ${2.5*B} ${2.5*B}, 0, 0, 0, ${2.5*-B} ${2.5*B}M ${z+2.5*B} ${N+B}h `+2*B+`a ${1.5*B} ${1.5*B}, 0, 0, 1, ${1.5*B} ${1.5*B}v `+2*B+`a ${1.5*B} ${1.5*B}, 0, 0, 1, ${1.5*-B} ${1.5*B}h `+-2*B+`a ${1.5*B} ${1.5*B}, 0, 0, 1, ${1.5*-B} ${1.5*-B}v `+-2*B+`a ${1.5*B} ${1.5*B}, 0, 0, 1, ${1.5*B} ${1.5*-B}`)}}))}_drawDot({x:I,y:D,size:z,rotation:N}){this._basicDot({x:I,y:D,size:z,rotation:N})}_drawSquare({x:I,y:D,size:z,rotation:N}){this._basicSquare({x:I,y:D,size:z,rotation:N})}_drawExtraRounded({x:I,y:D,size:z,rotation:N}){this._basicExtraRounded({x:I,y:D,size:z,rotation:N})}}const x={dot:"dot",square:"square"},b=Object.values(x);class S{constructor({svg:I,type:D,window:z}){this._svg=I,this._type=D,this._window=z}draw(I,D,z,N){let B;B=this._type===x.square?this._drawSquare:this._drawDot,B.call(this,{x:I,y:D,size:z,rotation:N})}_rotateFigure({x:I,y:D,size:z,rotation:N=0,draw:B}){var Q;const G=I+z/2,ae=D+z/2;B(),(Q=this._element)===null||Q===void 0||Q.setAttribute("transform",`rotate(${180*N/Math.PI},${G},${ae})`)}_basicDot(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","circle"),this._element.setAttribute("cx",String(z+D/2)),this._element.setAttribute("cy",String(N+D/2)),this._element.setAttribute("r",String(D/2))}}))}_basicSquare(I){const{size:D,x:z,y:N}=I;this._rotateFigure(Object.assign(Object.assign({},I),{draw:()=>{this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","rect"),this._element.setAttribute("x",String(z)),this._element.setAttribute("y",String(N)),this._element.setAttribute("width",String(D)),this._element.setAttribute("height",String(D))}}))}_drawDot({x:I,y:D,size:z,rotation:N}){this._basicDot({x:I,y:D,size:z,rotation:N})}_drawSquare({x:I,y:D,size:z,rotation:N}){this._basicSquare({x:I,y:D,size:z,rotation:N})}}const C="circle",A=[[1,1,1,1,1,1,1],[1,0,0,0,0,0,1],[1,0,0,0,0,0,1],[1,0,0,0,0,0,1],[1,0,0,0,0,0,1],[1,0,0,0,0,0,1],[1,1,1,1,1,1,1]],O=[[0,0,0,0,0,0,0],[0,0,0,0,0,0,0],[0,0,1,1,1,0,0],[0,0,1,1,1,0,0],[0,0,1,1,1,0,0],[0,0,0,0,0,0,0],[0,0,0,0,0,0,0]];class P{constructor(I,D){this._roundSize=z=>this._options.dotsOptions.roundSize?Math.floor(z):z,this._window=D,this._element=this._window.document.createElementNS("http://www.w3.org/2000/svg","svg"),this._element.setAttribute("width",String(I.width)),this._element.setAttribute("height",String(I.height)),this._element.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),I.dotsOptions.roundSize||this._element.setAttribute("shape-rendering","crispEdges"),this._element.setAttribute("viewBox",`0 0 ${I.width} ${I.height}`),this._defs=this._window.document.createElementNS("http://www.w3.org/2000/svg","defs"),this._element.appendChild(this._defs),this._imageUri=I.image,this._instanceId=P.instanceCount++,this._options=I}get width(){return this._options.width}get height(){return this._options.height}getElement(){return this._element}async drawQR(I){const D=I.getModuleCount(),z=Math.min(this._options.width,this._options.height)-2*this._options.margin,N=this._options.shape===C?z/Math.sqrt(2):z,B=this._roundSize(N/D);let Q={hideXDots:0,hideYDots:0,width:0,height:0};if(this._qr=I,this._options.image){if(await this.loadImage(),!this._image)return;const{imageOptions:G,qrOptions:ae}=this._options,fe=G.imageSize*u[ae.errorCorrectionLevel],ce=Math.floor(fe*D*D);Q=function({originalHeight:ye,originalWidth:F,maxHiddenDots:q,maxHiddenAxisDots:te,dotSize:ue}){const J={x:0,y:0},se={x:0,y:0};if(ye<=0||F<=0||q<=0||ue<=0)return{height:0,width:0,hideYDots:0,hideXDots:0};const de=ye/F;return J.x=Math.floor(Math.sqrt(q/de)),J.x<=0&&(J.x=1),te&&te<J.x&&(J.x=te),J.x%2==0&&J.x--,se.x=J.x*ue,J.y=1+2*Math.ceil((J.x*de-1)/2),se.y=Math.round(se.x*de),(J.y*J.x>q||te&&te<J.y)&&(te&&te<J.y?(J.y=te,J.y%2==0&&J.x--):J.y-=2,se.y=J.y*ue,J.x=1+2*Math.ceil((J.y/de-1)/2),se.x=Math.round(se.y/de)),{height:se.y,width:se.x,hideYDots:J.y,hideXDots:J.x}}({originalWidth:this._image.width,originalHeight:this._image.height,maxHiddenDots:ce,maxHiddenAxisDots:D-14,dotSize:B})}this.drawBackground(),this.drawDots((G,ae)=>{var fe,ce,ye,F,q,te;return!(this._options.imageOptions.hideBackgroundDots&&G>=(D-Q.hideYDots)/2&&G<(D+Q.hideYDots)/2&&ae>=(D-Q.hideXDots)/2&&ae<(D+Q.hideXDots)/2||!((fe=A[G])===null||fe===void 0)&&fe[ae]||!((ce=A[G-D+7])===null||ce===void 0)&&ce[ae]||!((ye=A[G])===null||ye===void 0)&&ye[ae-D+7]||!((F=O[G])===null||F===void 0)&&F[ae]||!((q=O[G-D+7])===null||q===void 0)&&q[ae]||!((te=O[G])===null||te===void 0)&&te[ae-D+7])}),this.drawCorners(),this._options.image&&await this.drawImage({width:Q.width,height:Q.height,count:D,dotSize:B})}drawBackground(){var I,D,z;const N=this._element,B=this._options;if(N){const Q=(I=B.backgroundOptions)===null||I===void 0?void 0:I.gradient,G=(D=B.backgroundOptions)===null||D===void 0?void 0:D.color;let ae=B.height,fe=B.width;if(Q||G){const ce=this._window.document.createElementNS("http://www.w3.org/2000/svg","rect");this._backgroundClipPath=this._window.document.createElementNS("http://www.w3.org/2000/svg","clipPath"),this._backgroundClipPath.setAttribute("id",`clip-path-background-color-${this._instanceId}`),this._defs.appendChild(this._backgroundClipPath),!((z=B.backgroundOptions)===null||z===void 0)&&z.round&&(ae=fe=Math.min(B.width,B.height),ce.setAttribute("rx",String(ae/2*B.backgroundOptions.round))),ce.setAttribute("x",String(this._roundSize((B.width-fe)/2))),ce.setAttribute("y",String(this._roundSize((B.height-ae)/2))),ce.setAttribute("width",String(fe)),ce.setAttribute("height",String(ae)),this._backgroundClipPath.appendChild(ce),this._createColor({options:Q,color:G,additionalRotation:0,x:0,y:0,height:B.height,width:B.width,name:`background-color-${this._instanceId}`})}}}drawDots(I){var D,z;if(!this._qr)throw"QR code is not defined";const N=this._options,B=this._qr.getModuleCount();if(B>N.width||B>N.height)throw"The canvas is too small.";const Q=Math.min(N.width,N.height)-2*N.margin,G=N.shape===C?Q/Math.sqrt(2):Q,ae=this._roundSize(G/B),fe=this._roundSize((N.width-B*ae)/2),ce=this._roundSize((N.height-B*ae)/2),ye=new h({svg:this._element,type:N.dotsOptions.type,window:this._window});this._dotsClipPath=this._window.document.createElementNS("http://www.w3.org/2000/svg","clipPath"),this._dotsClipPath.setAttribute("id",`clip-path-dot-color-${this._instanceId}`),this._defs.appendChild(this._dotsClipPath),this._createColor({options:(D=N.dotsOptions)===null||D===void 0?void 0:D.gradient,color:N.dotsOptions.color,additionalRotation:0,x:0,y:0,height:N.height,width:N.width,name:`dot-color-${this._instanceId}`});for(let F=0;F<B;F++)for(let q=0;q<B;q++)I&&!I(F,q)||!((z=this._qr)===null||z===void 0)&&z.isDark(F,q)&&(ye.draw(fe+q*ae,ce+F*ae,ae,(te,ue)=>!(q+te<0||F+ue<0||q+te>=B||F+ue>=B)&&!(I&&!I(F+ue,q+te))&&!!this._qr&&this._qr.isDark(F+ue,q+te)),ye._element&&this._dotsClipPath&&this._dotsClipPath.appendChild(ye._element));if(N.shape===C){const F=this._roundSize((Q/ae-B)/2),q=B+2*F,te=fe-F*ae,ue=ce-F*ae,J=[],se=this._roundSize(q/2);for(let de=0;de<q;de++){J[de]=[];for(let ve=0;ve<q;ve++)de>=F-1&&de<=q-F&&ve>=F-1&&ve<=q-F||Math.sqrt((de-se)*(de-se)+(ve-se)*(ve-se))>se?J[de][ve]=0:J[de][ve]=this._qr.isDark(ve-2*F<0?ve:ve>=B?ve-2*F:ve-F,de-2*F<0?de:de>=B?de-2*F:de-F)?1:0}for(let de=0;de<q;de++)for(let ve=0;ve<q;ve++)J[de][ve]&&(ye.draw(te+ve*ae,ue+de*ae,ae,(he,xe)=>{var Oe;return!!(!((Oe=J[de+xe])===null||Oe===void 0)&&Oe[ve+he])}),ye._element&&this._dotsClipPath&&this._dotsClipPath.appendChild(ye._element))}}drawCorners(){if(!this._qr)throw"QR code is not defined";const I=this._element,D=this._options;if(!I)throw"Element code is not defined";const z=this._qr.getModuleCount(),N=Math.min(D.width,D.height)-2*D.margin,B=D.shape===C?N/Math.sqrt(2):N,Q=this._roundSize(B/z),G=7*Q,ae=3*Q,fe=this._roundSize((D.width-z*Q)/2),ce=this._roundSize((D.height-z*Q)/2);[[0,0,0],[1,0,Math.PI/2],[0,1,-Math.PI/2]].forEach(([ye,F,q])=>{var te,ue,J,se,de,ve,he,xe,Oe,Le,He,$e,ze,_e;const Se=fe+ye*Q*(z-7),ke=ce+F*Q*(z-7);let Ne=this._dotsClipPath,je=this._dotsClipPath;if((!((te=D.cornersSquareOptions)===null||te===void 0)&&te.gradient||!((ue=D.cornersSquareOptions)===null||ue===void 0)&&ue.color)&&(Ne=this._window.document.createElementNS("http://www.w3.org/2000/svg","clipPath"),Ne.setAttribute("id",`clip-path-corners-square-color-${ye}-${F}-${this._instanceId}`),this._defs.appendChild(Ne),this._cornersSquareClipPath=this._cornersDotClipPath=je=Ne,this._createColor({options:(J=D.cornersSquareOptions)===null||J===void 0?void 0:J.gradient,color:(se=D.cornersSquareOptions)===null||se===void 0?void 0:se.color,additionalRotation:q,x:Se,y:ke,height:G,width:G,name:`corners-square-color-${ye}-${F}-${this._instanceId}`})),((de=D.cornersSquareOptions)===null||de===void 0?void 0:de.type)&&g.includes(D.cornersSquareOptions.type)){const Fe=new _({svg:this._element,type:D.cornersSquareOptions.type,window:this._window});Fe.draw(Se,ke,G,q),Fe._element&&Ne&&Ne.appendChild(Fe._element)}else{const Fe=new h({svg:this._element,type:((ve=D.cornersSquareOptions)===null||ve===void 0?void 0:ve.type)||D.dotsOptions.type,window:this._window});for(let Ge=0;Ge<A.length;Ge++)for(let Xe=0;Xe<A[Ge].length;Xe++)!((he=A[Ge])===null||he===void 0)&&he[Xe]&&(Fe.draw(Se+Xe*Q,ke+Ge*Q,Q,(ft,st)=>{var wt;return!!(!((wt=A[Ge+st])===null||wt===void 0)&&wt[Xe+ft])}),Fe._element&&Ne&&Ne.appendChild(Fe._element))}if((!((xe=D.cornersDotOptions)===null||xe===void 0)&&xe.gradient||!((Oe=D.cornersDotOptions)===null||Oe===void 0)&&Oe.color)&&(je=this._window.document.createElementNS("http://www.w3.org/2000/svg","clipPath"),je.setAttribute("id",`clip-path-corners-dot-color-${ye}-${F}-${this._instanceId}`),this._defs.appendChild(je),this._cornersDotClipPath=je,this._createColor({options:(Le=D.cornersDotOptions)===null||Le===void 0?void 0:Le.gradient,color:(He=D.cornersDotOptions)===null||He===void 0?void 0:He.color,additionalRotation:q,x:Se+2*Q,y:ke+2*Q,height:ae,width:ae,name:`corners-dot-color-${ye}-${F}-${this._instanceId}`})),(($e=D.cornersDotOptions)===null||$e===void 0?void 0:$e.type)&&b.includes(D.cornersDotOptions.type)){const Fe=new S({svg:this._element,type:D.cornersDotOptions.type,window:this._window});Fe.draw(Se+2*Q,ke+2*Q,ae,q),Fe._element&&je&&je.appendChild(Fe._element)}else{const Fe=new h({svg:this._element,type:((ze=D.cornersDotOptions)===null||ze===void 0?void 0:ze.type)||D.dotsOptions.type,window:this._window});for(let Ge=0;Ge<O.length;Ge++)for(let Xe=0;Xe<O[Ge].length;Xe++)!((_e=O[Ge])===null||_e===void 0)&&_e[Xe]&&(Fe.draw(Se+Xe*Q,ke+Ge*Q,Q,(ft,st)=>{var wt;return!!(!((wt=O[Ge+st])===null||wt===void 0)&&wt[Xe+ft])}),Fe._element&&je&&je.appendChild(Fe._element))}})}loadImage(){return new Promise((I,D)=>{var z;const N=this._options;if(!N.image)return D("Image is not defined");if(!((z=N.nodeCanvas)===null||z===void 0)&&z.loadImage)N.nodeCanvas.loadImage(N.image).then(B=>{var Q,G;if(this._image=B,this._options.imageOptions.saveAsBlob){const ae=(Q=N.nodeCanvas)===null||Q===void 0?void 0:Q.createCanvas(this._image.width,this._image.height);(G=ae==null?void 0:ae.getContext("2d"))===null||G===void 0||G.drawImage(B,0,0),this._imageUri=ae==null?void 0:ae.toDataURL()}I()}).catch(D);else{const B=new this._window.Image;typeof N.imageOptions.crossOrigin=="string"&&(B.crossOrigin=N.imageOptions.crossOrigin),this._image=B,B.onload=async()=>{this._options.imageOptions.saveAsBlob&&(this._imageUri=await async function(Q,G){return new Promise(ae=>{const fe=new G.XMLHttpRequest;fe.onload=function(){const ce=new G.FileReader;ce.onloadend=function(){ae(ce.result)},ce.readAsDataURL(fe.response)},fe.open("GET",Q),fe.responseType="blob",fe.send()})}(N.image||"",this._window)),I()},B.src=N.image}})}async drawImage({width:I,height:D,count:z,dotSize:N}){const B=this._options,Q=this._roundSize((B.width-z*N)/2),G=this._roundSize((B.height-z*N)/2),ae=Q+this._roundSize(B.imageOptions.margin+(z*N-I)/2),fe=G+this._roundSize(B.imageOptions.margin+(z*N-D)/2),ce=I-2*B.imageOptions.margin,ye=D-2*B.imageOptions.margin,F=this._window.document.createElementNS("http://www.w3.org/2000/svg","image");F.setAttribute("href",this._imageUri||""),F.setAttribute("xlink:href",this._imageUri||""),F.setAttribute("x",String(ae)),F.setAttribute("y",String(fe)),F.setAttribute("width",`${ce}px`),F.setAttribute("height",`${ye}px`),this._element.appendChild(F)}_createColor({options:I,color:D,additionalRotation:z,x:N,y:B,height:Q,width:G,name:ae}){const fe=G>Q?G:Q,ce=this._window.document.createElementNS("http://www.w3.org/2000/svg","rect");if(ce.setAttribute("x",String(N)),ce.setAttribute("y",String(B)),ce.setAttribute("height",String(Q)),ce.setAttribute("width",String(G)),ce.setAttribute("clip-path",`url('#clip-path-${ae}')`),I){let ye;if(I.type==="radial")ye=this._window.document.createElementNS("http://www.w3.org/2000/svg","radialGradient"),ye.setAttribute("id",ae),ye.setAttribute("gradientUnits","userSpaceOnUse"),ye.setAttribute("fx",String(N+G/2)),ye.setAttribute("fy",String(B+Q/2)),ye.setAttribute("cx",String(N+G/2)),ye.setAttribute("cy",String(B+Q/2)),ye.setAttribute("r",String(fe/2));else{const F=((I.rotation||0)+z)%(2*Math.PI),q=(F+2*Math.PI)%(2*Math.PI);let te=N+G/2,ue=B+Q/2,J=N+G/2,se=B+Q/2;q>=0&&q<=.25*Math.PI||q>1.75*Math.PI&&q<=2*Math.PI?(te-=G/2,ue-=Q/2*Math.tan(F),J+=G/2,se+=Q/2*Math.tan(F)):q>.25*Math.PI&&q<=.75*Math.PI?(ue-=Q/2,te-=G/2/Math.tan(F),se+=Q/2,J+=G/2/Math.tan(F)):q>.75*Math.PI&&q<=1.25*Math.PI?(te+=G/2,ue+=Q/2*Math.tan(F),J-=G/2,se-=Q/2*Math.tan(F)):q>1.25*Math.PI&&q<=1.75*Math.PI&&(ue+=Q/2,te+=G/2/Math.tan(F),se-=Q/2,J-=G/2/Math.tan(F)),ye=this._window.document.createElementNS("http://www.w3.org/2000/svg","linearGradient"),ye.setAttribute("id",ae),ye.setAttribute("gradientUnits","userSpaceOnUse"),ye.setAttribute("x1",String(Math.round(te))),ye.setAttribute("y1",String(Math.round(ue))),ye.setAttribute("x2",String(Math.round(J))),ye.setAttribute("y2",String(Math.round(se)))}I.colorStops.forEach(({offset:F,color:q})=>{const te=this._window.document.createElementNS("http://www.w3.org/2000/svg","stop");te.setAttribute("offset",100*F+"%"),te.setAttribute("stop-color",q),ye.appendChild(te)}),ce.setAttribute("fill",`url('#${ae}')`),this._defs.appendChild(ye)}else D&&ce.setAttribute("fill",D);this._element.appendChild(ce)}}P.instanceCount=0;const j=P,R="canvas",U={};for(let H=0;H<=40;H++)U[H]=H;const V={type:R,shape:"square",width:300,height:300,data:"",margin:0,qrOptions:{typeNumber:U[0],mode:void 0,errorCorrectionLevel:"Q"},imageOptions:{saveAsBlob:!0,hideBackgroundDots:!0,imageSize:.4,crossOrigin:void 0,margin:0},dotsOptions:{type:"square",color:"#000",roundSize:!0},backgroundOptions:{round:0,color:"#fff"}};function Y(H){const I=Object.assign({},H);if(!I.colorStops||!I.colorStops.length)throw"Field 'colorStops' is required in gradient";return I.rotation?I.rotation=Number(I.rotation):I.rotation=0,I.colorStops=I.colorStops.map(D=>Object.assign(Object.assign({},D),{offset:Number(D.offset)})),I}function K(H){const I=Object.assign({},H);return I.width=Number(I.width),I.height=Number(I.height),I.margin=Number(I.margin),I.imageOptions=Object.assign(Object.assign({},I.imageOptions),{hideBackgroundDots:!!I.imageOptions.hideBackgroundDots,imageSize:Number(I.imageOptions.imageSize),margin:Number(I.imageOptions.margin)}),I.margin>Math.min(I.width,I.height)&&(I.margin=Math.min(I.width,I.height)),I.dotsOptions=Object.assign({},I.dotsOptions),I.dotsOptions.gradient&&(I.dotsOptions.gradient=Y(I.dotsOptions.gradient)),I.cornersSquareOptions&&(I.cornersSquareOptions=Object.assign({},I.cornersSquareOptions),I.cornersSquareOptions.gradient&&(I.cornersSquareOptions.gradient=Y(I.cornersSquareOptions.gradient))),I.cornersDotOptions&&(I.cornersDotOptions=Object.assign({},I.cornersDotOptions),I.cornersDotOptions.gradient&&(I.cornersDotOptions.gradient=Y(I.cornersDotOptions.gradient))),I.backgroundOptions&&(I.backgroundOptions=Object.assign({},I.backgroundOptions),I.backgroundOptions.gradient&&(I.backgroundOptions.gradient=Y(I.backgroundOptions.gradient))),I}var W=i(873),ee=i.n(W);function ie(H){if(!H)throw new Error("Extension must be defined");H[0]==="."&&(H=H.substring(1));const I={bmp:"image/bmp",gif:"image/gif",ico:"image/vnd.microsoft.icon",jpeg:"image/jpeg",jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",tif:"image/tiff",tiff:"image/tiff",webp:"image/webp",pdf:"application/pdf"}[H.toLowerCase()];if(!I)throw new Error(`Extension "${H}" is not supported`);return I}class X{constructor(I){I!=null&&I.jsdom?this._window=new I.jsdom("",{resources:"usable"}).window:this._window=window,this._options=I?K(l(V,I)):V,this.update()}static _clearContainer(I){I&&(I.innerHTML="")}_setupSvg(){if(!this._qr)return;const I=new j(this._options,this._window);this._svg=I.getElement(),this._svgDrawingPromise=I.drawQR(this._qr).then(()=>{var D;this._svg&&((D=this._extension)===null||D===void 0||D.call(this,I.getElement(),this._options))})}_setupCanvas(){var I,D;this._qr&&(!((I=this._options.nodeCanvas)===null||I===void 0)&&I.createCanvas?(this._nodeCanvas=this._options.nodeCanvas.createCanvas(this._options.width,this._options.height),this._nodeCanvas.width=this._options.width,this._nodeCanvas.height=this._options.height):(this._domCanvas=document.createElement("canvas"),this._domCanvas.width=this._options.width,this._domCanvas.height=this._options.height),this._setupSvg(),this._canvasDrawingPromise=(D=this._svgDrawingPromise)===null||D===void 0?void 0:D.then(()=>{var z;if(!this._svg)return;const N=this._svg,B=new this._window.XMLSerializer().serializeToString(N),Q=btoa(B),G=`data:${ie("svg")};base64,${Q}`;if(!((z=this._options.nodeCanvas)===null||z===void 0)&&z.loadImage)return this._options.nodeCanvas.loadImage(G).then(ae=>{var fe,ce;ae.width=this._options.width,ae.height=this._options.height,(ce=(fe=this._nodeCanvas)===null||fe===void 0?void 0:fe.getContext("2d"))===null||ce===void 0||ce.drawImage(ae,0,0)});{const ae=new this._window.Image;return new Promise(fe=>{ae.onload=()=>{var ce,ye;(ye=(ce=this._domCanvas)===null||ce===void 0?void 0:ce.getContext("2d"))===null||ye===void 0||ye.drawImage(ae,0,0),fe()},ae.src=G})}}))}async _getElement(I="png"){if(!this._qr)throw"QR code is empty";return I.toLowerCase()==="svg"?(this._svg&&this._svgDrawingPromise||this._setupSvg(),await this._svgDrawingPromise,this._svg):((this._domCanvas||this._nodeCanvas)&&this._canvasDrawingPromise||this._setupCanvas(),await this._canvasDrawingPromise,this._domCanvas||this._nodeCanvas)}update(I){X._clearContainer(this._container),this._options=I?K(l(this._options,I)):this._options,this._options.data&&(this._qr=ee()(this._options.qrOptions.typeNumber,this._options.qrOptions.errorCorrectionLevel),this._qr.addData(this._options.data,this._options.qrOptions.mode||function(D){switch(!0){case/^[0-9]*$/.test(D):return"Numeric";case/^[0-9A-Z $%*+\-./:]*$/.test(D):return"Alphanumeric";default:return"Byte"}}(this._options.data)),this._qr.make(),this._options.type===R?this._setupCanvas():this._setupSvg(),this.append(this._container))}append(I){if(I){if(typeof I.appendChild!="function")throw"Container should be a single DOM node";this._options.type===R?this._domCanvas&&I.appendChild(this._domCanvas):this._svg&&I.appendChild(this._svg),this._container=I}}applyExtension(I){if(!I)throw"Extension function should be defined.";this._extension=I,this.update()}deleteExtension(){this._extension=void 0,this.update()}async getRawData(I="png"){if(!this._qr)throw"QR code is empty";const D=await this._getElement(I),z=ie(I);if(!D)return null;if(I.toLowerCase()==="svg"){const N=`<?xml version="1.0" standalone="no"?>\r
|
||
${new this._window.XMLSerializer().serializeToString(D)}`;return typeof Blob>"u"||this._options.jsdom?Buffer.from(N):new Blob([N],{type:z})}return new Promise(N=>{const B=D;if("toBuffer"in B)if(z==="image/png")N(B.toBuffer(z));else if(z==="image/jpeg")N(B.toBuffer(z));else{if(z!=="application/pdf")throw Error("Unsupported extension");N(B.toBuffer(z))}else"toBlob"in B&&B.toBlob(N,z,1)})}async download(I){if(!this._qr)throw"QR code is empty";if(typeof Blob>"u")throw"Cannot download in Node.js, call getRawData instead.";let D="png",z="qr";typeof I=="string"?(D=I,console.warn("Extension is deprecated as argument for 'download' method, please pass object { name: '...', extension: '...' } as argument")):typeof I=="object"&&I!==null&&(I.name&&(z=I.name),I.extension&&(D=I.extension));const N=await this._getElement(D);if(N)if(D.toLowerCase()==="svg"){let B=new XMLSerializer().serializeToString(N);B=`<?xml version="1.0" standalone="no"?>\r
|
||
`+B,f(`data:${ie(D)};charset=utf-8,${encodeURIComponent(B)}`,`${z}.svg`)}else f(N.toDataURL(ie(D)),`${z}.${D}`)}}const ne=X})(),a.default})())}(My)),My.exports}var fse=cse();const dse=zt(fse);/*!
|
||
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
|
||
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
|
||
* Copyright 2024 Fonticons, Inc.
|
||
*/const hse={prefix:"fab",iconName:"apple",icon:[384,512,[],"f179","M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"]},pse={prefix:"fab",iconName:"android",icon:[576,512,[],"f17b","M420.55,301.93a24,24,0,1,1,24-24,24,24,0,0,1-24,24m-265.1,0a24,24,0,1,1,24-24,24,24,0,0,1-24,24m273.7-144.48,47.94-83a10,10,0,1,0-17.27-10h0l-48.54,84.07a301.25,301.25,0,0,0-246.56,0L116.18,64.45a10,10,0,1,0-17.27,10h0l47.94,83C64.53,202.22,8.24,285.55,0,384H576c-8.24-98.45-64.54-181.78-146.85-226.55"]},mse="Left",gse="Right",vse="Up",yse="Down",Sf={delta:10,preventScrollOnSwipe:!1,rotationAngle:0,trackMouse:!1,trackTouch:!0,swipeDuration:1/0,touchEventOptions:{passive:!0}},bE={first:!0,initial:[0,0],start:0,swiping:!1,xy:[0,0]},W6="mousemove",Y6="mouseup",bse="touchend",wse="touchmove",_se="touchstart";function xse(e,t,n,r){return e>t?n>0?gse:mse:r>0?yse:vse}function K6(e,t){if(t===0)return e;const n=Math.PI/180*t,r=e[0]*Math.cos(n)+e[1]*Math.sin(n),i=e[1]*Math.cos(n)-e[0]*Math.sin(n);return[r,i]}function Sse(e,t){const n=h=>{const m="touches"in h;m&&h.touches.length>1||e((g,_)=>{_.trackMouse&&!m&&(document.addEventListener(W6,r),document.addEventListener(Y6,o));const{clientX:x,clientY:b}=m?h.touches[0]:h,S=K6([x,b],_.rotationAngle);return _.onTouchStartOrOnMouseDown&&_.onTouchStartOrOnMouseDown({event:h}),Object.assign(Object.assign(Object.assign({},g),bE),{initial:S.slice(),xy:S,start:h.timeStamp||0})})},r=h=>{e((m,g)=>{const _="touches"in h;if(_&&h.touches.length>1)return m;if(h.timeStamp-m.start>g.swipeDuration)return m.swiping?Object.assign(Object.assign({},m),{swiping:!1}):m;const{clientX:x,clientY:b}=_?h.touches[0]:h,[S,C]=K6([x,b],g.rotationAngle),A=S-m.xy[0],O=C-m.xy[1],P=Math.abs(A),j=Math.abs(O),R=(h.timeStamp||0)-m.start,U=Math.sqrt(P*P+j*j)/(R||1),V=[A/(R||1),O/(R||1)],Y=xse(P,j,A,O),K=typeof g.delta=="number"?g.delta:g.delta[Y.toLowerCase()]||Sf.delta;if(P<K&&j<K&&!m.swiping)return m;const W={absX:P,absY:j,deltaX:A,deltaY:O,dir:Y,event:h,first:m.first,initial:m.initial,velocity:U,vxvy:V};W.first&&g.onSwipeStart&&g.onSwipeStart(W),g.onSwiping&&g.onSwiping(W);let ee=!1;return(g.onSwiping||g.onSwiped||g[`onSwiped${Y}`])&&(ee=!0),ee&&g.preventScrollOnSwipe&&g.trackTouch&&h.cancelable&&h.preventDefault(),Object.assign(Object.assign({},m),{first:!1,eventData:W,swiping:!0})})},i=h=>{e((m,g)=>{let _;if(m.swiping&&m.eventData){if(h.timeStamp-m.start<g.swipeDuration){_=Object.assign(Object.assign({},m.eventData),{event:h}),g.onSwiped&&g.onSwiped(_);const x=g[`onSwiped${_.dir}`];x&&x(_)}}else g.onTap&&g.onTap({event:h});return g.onTouchEndOrOnMouseUp&&g.onTouchEndOrOnMouseUp({event:h}),Object.assign(Object.assign(Object.assign({},m),bE),{eventData:_})})},a=()=>{document.removeEventListener(W6,r),document.removeEventListener(Y6,o)},o=h=>{a(),i(h)},l=(h,m)=>{let g=()=>{};if(h&&h.addEventListener){const _=Object.assign(Object.assign({},Sf.touchEventOptions),m.touchEventOptions),x=[[_se,n,_],[wse,r,Object.assign(Object.assign({},_),m.preventScrollOnSwipe?{passive:!1}:{})],[bse,i,_]];x.forEach(([b,S,C])=>h.addEventListener(b,S,C)),g=()=>x.forEach(([b,S])=>h.removeEventListener(b,S))}return g},u={ref:h=>{h!==null&&e((m,g)=>{if(m.el===h)return m;const _={};return m.el&&m.el!==h&&m.cleanUpTouch&&(m.cleanUpTouch(),_.cleanUpTouch=void 0),g.trackTouch&&h&&(_.cleanUpTouch=l(h,g)),Object.assign(Object.assign(Object.assign({},m),{el:h}),_)})}};return t.trackMouse&&(u.onMouseDown=n),[u,l]}function Cse(e,t,n,r){return!t.trackTouch||!e.el?(e.cleanUpTouch&&e.cleanUpTouch(),Object.assign(Object.assign({},e),{cleanUpTouch:void 0})):e.cleanUpTouch?t.preventScrollOnSwipe!==n.preventScrollOnSwipe||t.touchEventOptions.passive!==n.touchEventOptions.passive?(e.cleanUpTouch(),Object.assign(Object.assign({},e),{cleanUpTouch:r(e.el,t)})):e:Object.assign(Object.assign({},e),{cleanUpTouch:r(e.el,t)})}function Ase(e){const{trackMouse:t}=e,n=M.useRef(Object.assign({},bE)),r=M.useRef(Object.assign({},Sf)),i=M.useRef(Object.assign({},r.current));i.current=Object.assign({},r.current),r.current=Object.assign(Object.assign({},Sf),e);let a;for(a in Sf)r.current[a]===void 0&&(r.current[a]=Sf[a]);const[o,l]=M.useMemo(()=>Sse(f=>n.current=f(n.current,r.current),{trackMouse:t}),[t]);return n.current=Cse(n.current,r.current,i.current,l),o}function _x(e){return e==null?"":`${e}`}function Ese(e={}){const{separator:t,decimals:n}=e;return t?n?r=>r.toFixed(n).replace(".",t):r=>`${r}`.replace(".",t):n?r=>r.toFixed(n):r=>`${r}`}function t3(e={}){const t=typeof e.quote=="string"?e.quote:'"',n=typeof e.escapedQuote=="string"?e.escapedQuote:`${t}${t}`;if(!t||t===n)return i=>i;const r=new RegExp(t,"g");return i=>(i.includes(t)&&(i=i.replace(r,n)),`${t}${i}${t}`)}function Ose(e={stringFormatter:t3()}){return t=>e.stringFormatter(t.toString().slice(7,-1))}function Tse(e={stringFormatter:t3()}){return t=>{if(t===null)return"";let n=JSON.stringify(t);return n===void 0?"":(n[0]==='"'&&(n=n.replace(/^"(.+)"$/,"$1")),e.stringFormatter(n))}}const jse=RegExp(`[^.[\\]]+|\\[(?:([^"'][^[]*)|(["'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))`,"g");function Pse(e){var t,n,r;const i=[];let a;for(;a=jse.exec(e);)i.push((r=(t=a[3])!==null&&t!==void 0?t:(n=a[1])===null||n===void 0?void 0:n.trim())!==null&&r!==void 0?r:a[0]);return i}function Z6(e,t,n){if(t in e){const a=e[t];return a===void 0?n:a}const r=Array.isArray(t)?t:Pse(t);let i=e;for(const a of r)if(i=i==null?void 0:i[a],i===void 0)return n;return i}function dU(e,t){try{return Array.isArray(t)?e.push(...t):e.push(t),e}catch{return e.concat(t)}}function wE(e,t){let n=!0;return e.reduce((r,i)=>(i==null&&(i=""),n?(n=!1,`${i}`):`${r}${t}${i}`),"")}var X6;(function(e){e.header="header",e.undefined="undefined",e.boolean="boolean",e.number="number",e.bigint="bigint",e.string="string",e.symbol="symbol",e.function="function",e.object="object"})(X6||(X6={}));class Rse{constructor(t){this.opts=this.preprocessOpts(t)}preprocessOpts(t){const n=Object.assign({},t);n.fields&&(n.fields=this.preprocessFieldsInfo(n.fields,n.defaultValue)),n.transforms=n.transforms||[];const r=n.formatters&&n.formatters.string||t3(),i=Tse({stringFormatter:r}),a={header:r,undefined:_x,boolean:_x,number:Ese(),bigint:_x,string:r,symbol:Ose({stringFormatter:r}),function:i,object:i};return n.formatters=Object.assign(Object.assign({},a),n.formatters),n.delimiter=n.delimiter||",",n.eol=n.eol||`
|
||
`,n.header=n.header!==!1,n.includeEmptyRows=n.includeEmptyRows||!1,n.withBOM=n.withBOM||!1,n}preprocessFieldsInfo(t,n){return t.map(r=>{if(typeof r=="string")return{label:r,value:i=>Z6(i,r,n)};if(typeof r=="object"){const i="default"in r?r.default:n;if(typeof r.value=="string"){const a=r.value;return{label:r.label||r.value,value:o=>Z6(o,a,i)}}if(typeof r.value=="function"){const a=r.label||r.value.name||"",o={label:a,default:i},l=r.value;return{label:a,value(f){const u=l(f,o);return u===void 0?i:u}}}}throw new Error("Invalid field info option. "+JSON.stringify(r))})}getHeader(){return wE(this.opts.fields.map(t=>this.opts.formatters.header(t.label)),this.opts.delimiter)}preprocessRow(t){return this.opts.transforms.reduce((n,r)=>n.map(i=>r(i)).reduce(dU,[]),[t])}processRow(t){if(!t)return;const n=this.opts.fields.map(r=>this.processCell(t,r));if(!(!this.opts.includeEmptyRows&&n.every(r=>r==="")))return wE(n,this.opts.delimiter)}processCell(t,n){return this.processValue(n.value(t))}processValue(t){const n=this.opts.formatters[typeof t];return n(t)}}class hU extends Rse{constructor(t){super(t)}parse(t){const n=this.preprocessData(t);this.opts.fields=this.opts.fields||this.preprocessFieldsInfo(n.reduce((o,l)=>(Object.keys(l).forEach(f=>{o.includes(f)||o.push(f)}),o),[]),this.opts.defaultValue);const r=this.opts.header?this.getHeader():"",i=this.processData(n);return(this.opts.withBOM?"\uFEFF":"")+r+(r&&i?this.opts.eol:"")+i}preprocessData(t){const n=Array.isArray(t)?t:[t];if(!this.opts.fields){if(t==null||n.length===0)throw new Error('Data should not be empty or the "fields" option should be included');if(typeof n[0]!="object")throw new Error('Data items should be objects or the "fields" option should be included')}return this.opts.transforms.length===0?n:n.map(r=>this.preprocessRow(r)).reduce(dU,[])}processData(t){return wE(t.map(n=>this.processRow(n)).filter(n=>n),this.opts.eol)}}var or;(function(e){e[e.BACKSPACE=8]="BACKSPACE",e[e.FORM_FEED=12]="FORM_FEED",e[e.NEWLINE=10]="NEWLINE",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.TAB=9]="TAB",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.NUMBER_SIGN=35]="NUMBER_SIGN",e[e.DOLLAR_SIGN=36]="DOLLAR_SIGN",e[e.PERCENT_SIGN=37]="PERCENT_SIGN",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.LEFT_PARENTHESIS=40]="LEFT_PARENTHESIS",e[e.RIGHT_PARENTHESIS=41]="RIGHT_PARENTHESIS",e[e.ASTERISK=42]="ASTERISK",e[e.PLUS_SIGN=43]="PLUS_SIGN",e[e.COMMA=44]="COMMA",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.FULL_STOP=46]="FULL_STOP",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_ZERO=48]="DIGIT_ZERO",e[e.DIGIT_ONE=49]="DIGIT_ONE",e[e.DIGIT_TWO=50]="DIGIT_TWO",e[e.DIGIT_THREE=51]="DIGIT_THREE",e[e.DIGIT_FOUR=52]="DIGIT_FOUR",e[e.DIGIT_FIVE=53]="DIGIT_FIVE",e[e.DIGIT_SIX=54]="DIGIT_SIX",e[e.DIGIT_SEVEN=55]="DIGIT_SEVEN",e[e.DIGIT_EIGHT=56]="DIGIT_EIGHT",e[e.DIGIT_NINE=57]="DIGIT_NINE",e[e.COLON=58]="COLON",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.COMMERCIAL_AT=64]="COMMERCIAL_AT",e[e.LATIN_CAPITAL_LETTER_A=65]="LATIN_CAPITAL_LETTER_A",e[e.LATIN_CAPITAL_LETTER_B=66]="LATIN_CAPITAL_LETTER_B",e[e.LATIN_CAPITAL_LETTER_C=67]="LATIN_CAPITAL_LETTER_C",e[e.LATIN_CAPITAL_LETTER_D=68]="LATIN_CAPITAL_LETTER_D",e[e.LATIN_CAPITAL_LETTER_E=69]="LATIN_CAPITAL_LETTER_E",e[e.LATIN_CAPITAL_LETTER_F=70]="LATIN_CAPITAL_LETTER_F",e[e.LATIN_CAPITAL_LETTER_G=71]="LATIN_CAPITAL_LETTER_G",e[e.LATIN_CAPITAL_LETTER_H=72]="LATIN_CAPITAL_LETTER_H",e[e.LATIN_CAPITAL_LETTER_I=73]="LATIN_CAPITAL_LETTER_I",e[e.LATIN_CAPITAL_LETTER_J=74]="LATIN_CAPITAL_LETTER_J",e[e.LATIN_CAPITAL_LETTER_K=75]="LATIN_CAPITAL_LETTER_K",e[e.LATIN_CAPITAL_LETTER_L=76]="LATIN_CAPITAL_LETTER_L",e[e.LATIN_CAPITAL_LETTER_M=77]="LATIN_CAPITAL_LETTER_M",e[e.LATIN_CAPITAL_LETTER_N=78]="LATIN_CAPITAL_LETTER_N",e[e.LATIN_CAPITAL_LETTER_O=79]="LATIN_CAPITAL_LETTER_O",e[e.LATIN_CAPITAL_LETTER_P=80]="LATIN_CAPITAL_LETTER_P",e[e.LATIN_CAPITAL_LETTER_Q=81]="LATIN_CAPITAL_LETTER_Q",e[e.LATIN_CAPITAL_LETTER_R=82]="LATIN_CAPITAL_LETTER_R",e[e.LATIN_CAPITAL_LETTER_S=83]="LATIN_CAPITAL_LETTER_S",e[e.LATIN_CAPITAL_LETTER_T=84]="LATIN_CAPITAL_LETTER_T",e[e.LATIN_CAPITAL_LETTER_U=85]="LATIN_CAPITAL_LETTER_U",e[e.LATIN_CAPITAL_LETTER_V=86]="LATIN_CAPITAL_LETTER_V",e[e.LATIN_CAPITAL_LETTER_W=87]="LATIN_CAPITAL_LETTER_W",e[e.LATIN_CAPITAL_LETTER_X=88]="LATIN_CAPITAL_LETTER_X",e[e.LATIN_CAPITAL_LETTER_Y=89]="LATIN_CAPITAL_LETTER_Y",e[e.LATIN_CAPITAL_LETTER_Z=90]="LATIN_CAPITAL_LETTER_Z",e[e.LEFT_SQUARE_BRACKET=91]="LEFT_SQUARE_BRACKET",e[e.REVERSE_SOLIDUS=92]="REVERSE_SOLIDUS",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.CIRCUMFLEX_ACCENT=94]="CIRCUMFLEX_ACCENT",e[e.LOW_LINE=95]="LOW_LINE",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_LETTER_A=97]="LATIN_SMALL_LETTER_A",e[e.LATIN_SMALL_LETTER_B=98]="LATIN_SMALL_LETTER_B",e[e.LATIN_SMALL_LETTER_C=99]="LATIN_SMALL_LETTER_C",e[e.LATIN_SMALL_LETTER_D=100]="LATIN_SMALL_LETTER_D",e[e.LATIN_SMALL_LETTER_E=101]="LATIN_SMALL_LETTER_E",e[e.LATIN_SMALL_LETTER_F=102]="LATIN_SMALL_LETTER_F",e[e.LATIN_SMALL_LETTER_G=103]="LATIN_SMALL_LETTER_G",e[e.LATIN_SMALL_LETTER_H=104]="LATIN_SMALL_LETTER_H",e[e.LATIN_SMALL_LETTER_I=105]="LATIN_SMALL_LETTER_I",e[e.LATIN_SMALL_LETTER_J=106]="LATIN_SMALL_LETTER_J",e[e.LATIN_SMALL_LETTER_K=107]="LATIN_SMALL_LETTER_K",e[e.LATIN_SMALL_LETTER_L=108]="LATIN_SMALL_LETTER_L",e[e.LATIN_SMALL_LETTER_M=109]="LATIN_SMALL_LETTER_M",e[e.LATIN_SMALL_LETTER_N=110]="LATIN_SMALL_LETTER_N",e[e.LATIN_SMALL_LETTER_O=111]="LATIN_SMALL_LETTER_O",e[e.LATIN_SMALL_LETTER_P=112]="LATIN_SMALL_LETTER_P",e[e.LATIN_SMALL_LETTER_Q=113]="LATIN_SMALL_LETTER_Q",e[e.LATIN_SMALL_LETTER_R=114]="LATIN_SMALL_LETTER_R",e[e.LATIN_SMALL_LETTER_S=115]="LATIN_SMALL_LETTER_S",e[e.LATIN_SMALL_LETTER_T=116]="LATIN_SMALL_LETTER_T",e[e.LATIN_SMALL_LETTER_U=117]="LATIN_SMALL_LETTER_U",e[e.LATIN_SMALL_LETTER_V=118]="LATIN_SMALL_LETTER_V",e[e.LATIN_SMALL_LETTER_W=119]="LATIN_SMALL_LETTER_W",e[e.LATIN_SMALL_LETTER_X=120]="LATIN_SMALL_LETTER_X",e[e.LATIN_SMALL_LETTER_Y=121]="LATIN_SMALL_LETTER_Y",e[e.LATIN_SMALL_LETTER_Z=122]="LATIN_SMALL_LETTER_Z",e[e.LEFT_CURLY_BRACKET=123]="LEFT_CURLY_BRACKET",e[e.VERTICAL_LINE=124]="VERTICAL_LINE",e[e.RIGHT_CURLY_BRACKET=125]="RIGHT_CURLY_BRACKET",e[e.TILDE=126]="TILDE"})(or||(or={}));or.QUOTATION_MARK+"",or.QUOTATION_MARK,or.REVERSE_SOLIDUS+"",or.REVERSE_SOLIDUS,or.SOLIDUS+"",or.SOLIDUS,or.LATIN_SMALL_LETTER_B+"",or.BACKSPACE,or.LATIN_SMALL_LETTER_F+"",or.FORM_FEED,or.LATIN_SMALL_LETTER_N+"",or.NEWLINE,or.LATIN_SMALL_LETTER_R+"",or.CARRIAGE_RETURN,or.LATIN_SMALL_LETTER_T+"",or.TAB;var Q6;(function(e){e[e.LEFT_BRACE=0]="LEFT_BRACE",e[e.RIGHT_BRACE=1]="RIGHT_BRACE",e[e.LEFT_BRACKET=2]="LEFT_BRACKET",e[e.RIGHT_BRACKET=3]="RIGHT_BRACKET",e[e.COLON=4]="COLON",e[e.COMMA=5]="COMMA",e[e.TRUE=6]="TRUE",e[e.FALSE=7]="FALSE",e[e.NULL=8]="NULL",e[e.STRING=9]="STRING",e[e.NUMBER=10]="NUMBER",e[e.SEPARATOR=11]="SEPARATOR"})(Q6||(Q6={}));var J6;(function(e){e[e.START=0]="START",e[e.ENDED=1]="ENDED",e[e.ERROR=2]="ERROR",e[e.TRUE1=3]="TRUE1",e[e.TRUE2=4]="TRUE2",e[e.TRUE3=5]="TRUE3",e[e.FALSE1=6]="FALSE1",e[e.FALSE2=7]="FALSE2",e[e.FALSE3=8]="FALSE3",e[e.FALSE4=9]="FALSE4",e[e.NULL1=10]="NULL1",e[e.NULL2=11]="NULL2",e[e.NULL3=12]="NULL3",e[e.STRING_DEFAULT=13]="STRING_DEFAULT",e[e.STRING_AFTER_BACKSLASH=14]="STRING_AFTER_BACKSLASH",e[e.STRING_UNICODE_DIGIT_1=15]="STRING_UNICODE_DIGIT_1",e[e.STRING_UNICODE_DIGIT_2=16]="STRING_UNICODE_DIGIT_2",e[e.STRING_UNICODE_DIGIT_3=17]="STRING_UNICODE_DIGIT_3",e[e.STRING_UNICODE_DIGIT_4=18]="STRING_UNICODE_DIGIT_4",e[e.STRING_INCOMPLETE_CHAR=19]="STRING_INCOMPLETE_CHAR",e[e.NUMBER_AFTER_INITIAL_MINUS=20]="NUMBER_AFTER_INITIAL_MINUS",e[e.NUMBER_AFTER_INITIAL_ZERO=21]="NUMBER_AFTER_INITIAL_ZERO",e[e.NUMBER_AFTER_INITIAL_NON_ZERO=22]="NUMBER_AFTER_INITIAL_NON_ZERO",e[e.NUMBER_AFTER_FULL_STOP=23]="NUMBER_AFTER_FULL_STOP",e[e.NUMBER_AFTER_DECIMAL=24]="NUMBER_AFTER_DECIMAL",e[e.NUMBER_AFTER_E=25]="NUMBER_AFTER_E",e[e.NUMBER_AFTER_E_AND_SIGN=26]="NUMBER_AFTER_E_AND_SIGN",e[e.NUMBER_AFTER_E_AND_DIGIT=27]="NUMBER_AFTER_E_AND_DIGIT",e[e.SEPARATOR=28]="SEPARATOR",e[e.BOM_OR_START=29]="BOM_OR_START",e[e.BOM=30]="BOM"})(J6||(J6={}));var eN;(function(e){e[e.OBJECT=0]="OBJECT",e[e.ARRAY=1]="ARRAY"})(eN||(eN={}));var tN;(function(e){e[e.VALUE=0]="VALUE",e[e.KEY=1]="KEY",e[e.COLON=2]="COLON",e[e.COMMA=3]="COMMA",e[e.ENDED=4]="ENDED",e[e.ERROR=5]="ERROR",e[e.SEPARATOR=6]="SEPARATOR"})(tN||(tN={}));var xx,nN;function ri(){if(nN)return xx;nN=1;var e=Array.isArray;return xx=e,xx}var Sx,rN;function pU(){if(rN)return Sx;rN=1;var e=typeof qv=="object"&&qv&&qv.Object===Object&&qv;return Sx=e,Sx}var Cx,iN;function go(){if(iN)return Cx;iN=1;var e=pU(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return Cx=n,Cx}var Ax,aN;function lg(){if(aN)return Ax;aN=1;var e=go(),t=e.Symbol;return Ax=t,Ax}var Ex,oN;function Mse(){if(oN)return Ex;oN=1;var e=lg(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function a(o){var l=n.call(o,i),f=o[i];try{o[i]=void 0;var u=!0}catch{}var h=r.call(o);return u&&(l?o[i]=f:delete o[i]),h}return Ex=a,Ex}var Ox,sN;function Nse(){if(sN)return Ox;sN=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return Ox=n,Ox}var Tx,lN;function hs(){if(lN)return Tx;lN=1;var e=lg(),t=Mse(),n=Nse(),r="[object Null]",i="[object Undefined]",a=e?e.toStringTag:void 0;function o(l){return l==null?l===void 0?i:r:a&&a in Object(l)?t(l):n(l)}return Tx=o,Tx}var jx,uN;function ps(){if(uN)return jx;uN=1;function e(t){return t!=null&&typeof t=="object"}return jx=e,jx}var Px,cN;function Dd(){if(cN)return Px;cN=1;var e=hs(),t=ps(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return Px=r,Px}var Rx,fN;function n3(){if(fN)return Rx;fN=1;var e=ri(),t=Dd(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(a,o){if(e(a))return!1;var l=typeof a;return l=="number"||l=="symbol"||l=="boolean"||a==null||t(a)?!0:r.test(a)||!n.test(a)||o!=null&&a in Object(o)}return Rx=i,Rx}var Mx,dN;function Wl(){if(dN)return Mx;dN=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return Mx=e,Mx}var Nx,hN;function r3(){if(hN)return Nx;hN=1;var e=hs(),t=Wl(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",a="[object Proxy]";function o(l){if(!t(l))return!1;var f=e(l);return f==r||f==i||f==n||f==a}return Nx=o,Nx}var Lx,pN;function Lse(){if(pN)return Lx;pN=1;var e=go(),t=e["__core-js_shared__"];return Lx=t,Lx}var kx,mN;function kse(){if(mN)return kx;mN=1;var e=Lse(),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 kx=n,kx}var Dx,gN;function mU(){if(gN)return Dx;gN=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 Dx=n,Dx}var Ix,vN;function Dse(){if(vN)return Ix;vN=1;var e=r3(),t=kse(),n=Wl(),r=mU(),i=/[\\^$.*+?()[\]{}|]/g,a=/^\[object .+?Constructor\]$/,o=Function.prototype,l=Object.prototype,f=o.toString,u=l.hasOwnProperty,h=RegExp("^"+f.call(u).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function m(g){if(!n(g)||t(g))return!1;var _=e(g)?h:a;return _.test(r(g))}return Ix=m,Ix}var $x,yN;function Ise(){if(yN)return $x;yN=1;function e(t,n){return t==null?void 0:t[n]}return $x=e,$x}var Bx,bN;function hc(){if(bN)return Bx;bN=1;var e=Dse(),t=Ise();function n(r,i){var a=t(r,i);return e(a)?a:void 0}return Bx=n,Bx}var Ux,wN;function Jb(){if(wN)return Ux;wN=1;var e=hc(),t=e(Object,"create");return Ux=t,Ux}var zx,_N;function $se(){if(_N)return zx;_N=1;var e=Jb();function t(){this.__data__=e?e(null):{},this.size=0}return zx=t,zx}var Fx,xN;function Bse(){if(xN)return Fx;xN=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return Fx=e,Fx}var qx,SN;function Use(){if(SN)return qx;SN=1;var e=Jb(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(a){var o=this.__data__;if(e){var l=o[a];return l===t?void 0:l}return r.call(o,a)?o[a]:void 0}return qx=i,qx}var Vx,CN;function zse(){if(CN)return Vx;CN=1;var e=Jb(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var a=this.__data__;return e?a[i]!==void 0:n.call(a,i)}return Vx=r,Vx}var Hx,AN;function Fse(){if(AN)return Hx;AN=1;var e=Jb(),t="__lodash_hash_undefined__";function n(r,i){var a=this.__data__;return this.size+=this.has(r)?0:1,a[r]=e&&i===void 0?t:i,this}return Hx=n,Hx}var Gx,EN;function qse(){if(EN)return Gx;EN=1;var e=$se(),t=Bse(),n=Use(),r=zse(),i=Fse();function a(o){var l=-1,f=o==null?0:o.length;for(this.clear();++l<f;){var u=o[l];this.set(u[0],u[1])}}return a.prototype.clear=e,a.prototype.delete=t,a.prototype.get=n,a.prototype.has=r,a.prototype.set=i,Gx=a,Gx}var Wx,ON;function Vse(){if(ON)return Wx;ON=1;function e(){this.__data__=[],this.size=0}return Wx=e,Wx}var Yx,TN;function i3(){if(TN)return Yx;TN=1;function e(t,n){return t===n||t!==t&&n!==n}return Yx=e,Yx}var Kx,jN;function e1(){if(jN)return Kx;jN=1;var e=i3();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return Kx=t,Kx}var Zx,PN;function Hse(){if(PN)return Zx;PN=1;var e=e1(),t=Array.prototype,n=t.splice;function r(i){var a=this.__data__,o=e(a,i);if(o<0)return!1;var l=a.length-1;return o==l?a.pop():n.call(a,o,1),--this.size,!0}return Zx=r,Zx}var Xx,RN;function Gse(){if(RN)return Xx;RN=1;var e=e1();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return Xx=t,Xx}var Qx,MN;function Wse(){if(MN)return Qx;MN=1;var e=e1();function t(n){return e(this.__data__,n)>-1}return Qx=t,Qx}var Jx,NN;function Yse(){if(NN)return Jx;NN=1;var e=e1();function t(n,r){var i=this.__data__,a=e(i,n);return a<0?(++this.size,i.push([n,r])):i[a][1]=r,this}return Jx=t,Jx}var e2,LN;function t1(){if(LN)return e2;LN=1;var e=Vse(),t=Hse(),n=Gse(),r=Wse(),i=Yse();function a(o){var l=-1,f=o==null?0:o.length;for(this.clear();++l<f;){var u=o[l];this.set(u[0],u[1])}}return a.prototype.clear=e,a.prototype.delete=t,a.prototype.get=n,a.prototype.has=r,a.prototype.set=i,e2=a,e2}var t2,kN;function a3(){if(kN)return t2;kN=1;var e=hc(),t=go(),n=e(t,"Map");return t2=n,t2}var n2,DN;function Kse(){if(DN)return n2;DN=1;var e=qse(),t=t1(),n=a3();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return n2=r,n2}var r2,IN;function Zse(){if(IN)return r2;IN=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return r2=e,r2}var i2,$N;function n1(){if($N)return i2;$N=1;var e=Zse();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return i2=t,i2}var a2,BN;function Xse(){if(BN)return a2;BN=1;var e=n1();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return a2=t,a2}var o2,UN;function Qse(){if(UN)return o2;UN=1;var e=n1();function t(n){return e(this,n).get(n)}return o2=t,o2}var s2,zN;function Jse(){if(zN)return s2;zN=1;var e=n1();function t(n){return e(this,n).has(n)}return s2=t,s2}var l2,FN;function ele(){if(FN)return l2;FN=1;var e=n1();function t(n,r){var i=e(this,n),a=i.size;return i.set(n,r),this.size+=i.size==a?0:1,this}return l2=t,l2}var u2,qN;function o3(){if(qN)return u2;qN=1;var e=Kse(),t=Xse(),n=Qse(),r=Jse(),i=ele();function a(o){var l=-1,f=o==null?0:o.length;for(this.clear();++l<f;){var u=o[l];this.set(u[0],u[1])}}return a.prototype.clear=e,a.prototype.delete=t,a.prototype.get=n,a.prototype.has=r,a.prototype.set=i,u2=a,u2}var c2,VN;function gU(){if(VN)return c2;VN=1;var e=o3(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var a=function(){var o=arguments,l=i?i.apply(this,o):o[0],f=a.cache;if(f.has(l))return f.get(l);var u=r.apply(this,o);return a.cache=f.set(l,u)||f,u};return a.cache=new(n.Cache||e),a}return n.Cache=e,c2=n,c2}var f2,HN;function tle(){if(HN)return f2;HN=1;var e=gU(),t=500;function n(r){var i=e(r,function(o){return a.size===t&&a.clear(),o}),a=i.cache;return i}return f2=n,f2}var d2,GN;function nle(){if(GN)return d2;GN=1;var e=tle(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var a=[];return i.charCodeAt(0)===46&&a.push(""),i.replace(t,function(o,l,f,u){a.push(f?u.replace(n,"$1"):l||o)}),a});return d2=r,d2}var h2,WN;function s3(){if(WN)return h2;WN=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,a=Array(i);++r<i;)a[r]=n(t[r],r,t);return a}return h2=e,h2}var p2,YN;function rle(){if(YN)return p2;YN=1;var e=lg(),t=s3(),n=ri(),r=Dd(),i=e?e.prototype:void 0,a=i?i.toString:void 0;function o(l){if(typeof l=="string")return l;if(n(l))return t(l,o)+"";if(r(l))return a?a.call(l):"";var f=l+"";return f=="0"&&1/l==-1/0?"-0":f}return p2=o,p2}var m2,KN;function vU(){if(KN)return m2;KN=1;var e=rle();function t(n){return n==null?"":e(n)}return m2=t,m2}var g2,ZN;function yU(){if(ZN)return g2;ZN=1;var e=ri(),t=n3(),n=nle(),r=vU();function i(a,o){return e(a)?a:t(a,o)?[a]:n(r(a))}return g2=i,g2}var v2,XN;function r1(){if(XN)return v2;XN=1;var e=Dd();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return v2=t,v2}var y2,QN;function l3(){if(QN)return y2;QN=1;var e=yU(),t=r1();function n(r,i){i=e(i,r);for(var a=0,o=i.length;r!=null&&a<o;)r=r[t(i[a++])];return a&&a==o?r:void 0}return y2=n,y2}var b2,JN;function bU(){if(JN)return b2;JN=1;var e=l3();function t(n,r,i){var a=n==null?void 0:e(n,r);return a===void 0?i:a}return b2=t,b2}var ile=bU();const Ti=zt(ile);var w2,e5;function ale(){if(e5)return w2;e5=1;function e(t){return t==null}return w2=e,w2}var ole=ale();const pt=zt(ole);var _2,t5;function sle(){if(t5)return _2;t5=1;var e=hs(),t=ri(),n=ps(),r="[object String]";function i(a){return typeof a=="string"||!t(a)&&n(a)&&e(a)==r}return _2=i,_2}var lle=sle();const ic=zt(lle);var ule=r3();const ht=zt(ule);var cle=Wl();const Id=zt(cle);var x2={exports:{}},Ft={};/**
|
||
* @license React
|
||
* react-is.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var n5;function fle(){if(n5)return Ft;n5=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"),a=Symbol.for("react.provider"),o=Symbol.for("react.context"),l=Symbol.for("react.server_context"),f=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),h=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),_=Symbol.for("react.offscreen"),x;x=Symbol.for("react.module.reference");function b(S){if(typeof S=="object"&&S!==null){var C=S.$$typeof;switch(C){case e:switch(S=S.type,S){case n:case i:case r:case u:case h:return S;default:switch(S=S&&S.$$typeof,S){case l:case o:case f:case g:case m:case a:return S;default:return C}}case t:return C}}}return Ft.ContextConsumer=o,Ft.ContextProvider=a,Ft.Element=e,Ft.ForwardRef=f,Ft.Fragment=n,Ft.Lazy=g,Ft.Memo=m,Ft.Portal=t,Ft.Profiler=i,Ft.StrictMode=r,Ft.Suspense=u,Ft.SuspenseList=h,Ft.isAsyncMode=function(){return!1},Ft.isConcurrentMode=function(){return!1},Ft.isContextConsumer=function(S){return b(S)===o},Ft.isContextProvider=function(S){return b(S)===a},Ft.isElement=function(S){return typeof S=="object"&&S!==null&&S.$$typeof===e},Ft.isForwardRef=function(S){return b(S)===f},Ft.isFragment=function(S){return b(S)===n},Ft.isLazy=function(S){return b(S)===g},Ft.isMemo=function(S){return b(S)===m},Ft.isPortal=function(S){return b(S)===t},Ft.isProfiler=function(S){return b(S)===i},Ft.isStrictMode=function(S){return b(S)===r},Ft.isSuspense=function(S){return b(S)===u},Ft.isSuspenseList=function(S){return b(S)===h},Ft.isValidElementType=function(S){return typeof S=="string"||typeof S=="function"||S===n||S===i||S===r||S===u||S===h||S===_||typeof S=="object"&&S!==null&&(S.$$typeof===g||S.$$typeof===m||S.$$typeof===a||S.$$typeof===o||S.$$typeof===f||S.$$typeof===x||S.getModuleId!==void 0)},Ft.typeOf=b,Ft}var r5;function dle(){return r5||(r5=1,x2.exports=fle()),x2.exports}var hle=dle(),S2,i5;function wU(){if(i5)return S2;i5=1;var e=hs(),t=ps(),n="[object Number]";function r(i){return typeof i=="number"||t(i)&&e(i)==n}return S2=r,S2}var C2,a5;function ple(){if(a5)return C2;a5=1;var e=wU();function t(n){return e(n)&&n!=+n}return C2=t,C2}var mle=ple();const $d=zt(mle);var gle=wU();const vle=zt(gle);var Fr=function(t){return t===0?0:t>0?1:-1},Fu=function(t){return ic(t)&&t.indexOf("%")===t.length-1},Ze=function(t){return vle(t)&&!$d(t)},Kn=function(t){return Ze(t)||ic(t)},yle=0,Yl=function(t){var n=++yle;return"".concat(t||"").concat(n)},qr=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(!Ze(t)&&!ic(t))return r;var a;if(Fu(t)){var o=t.indexOf("%");a=n*parseFloat(t.slice(0,o))/100}else a=+t;return $d(a)&&(a=r),i&&a>n&&(a=n),a},vl=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},ble=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},Cn=function(t,n){return Ze(t)&&Ze(n)?function(r){return t+r*(n-t)}:function(){return n}};function c0(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):Ti(r,t))===n})}var wle=function(t){if(!t||!t.length)return null;for(var n=t.length,r=0,i=0,a=0,o=0,l=1/0,f=-1/0,u=0,h=0,m=0;m<n;m++)u=t[m].cx||0,h=t[m].cy||0,r+=u,i+=h,a+=u*h,o+=u*u,l=Math.min(l,u),f=Math.max(f,u);var g=n*o!==r*r?(n*a-r*i)/(n*o-r*r):0;return{xmin:l,xmax:f,a:g,b:(i-g*r)/n}},_le=function(t,n){return Ze(t)&&Ze(n)?t-n:ic(t)&&ic(n)?t.localeCompare(n):t instanceof Date&&n instanceof Date?t.getTime()-n.getTime():String(t).localeCompare(String(n))};function kf(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 _E(e){"@babel/helpers - typeof";return _E=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},_E(e)}var xle=["viewBox","children"],Sle=["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"],o5=["points","pathLength"],A2={svg:xle,polygon:o5,polyline:o5},u3=["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"],f0=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(M.isValidElement(t)&&(r=t.props),!Id(r))return null;var i={};return Object.keys(r).forEach(function(a){u3.includes(a)&&(i[a]=n||function(o){return r[a](r,o)})}),i},Cle=function(t,n,r){return function(i){return t(n,r,i),null}},Bl=function(t,n,r){if(!Id(t)||_E(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(a){var o=t[a];u3.includes(a)&&typeof o=="function"&&(i||(i={}),i[a]=Cle(o,n,r))}),i},Ale=["children"],Ele=["children"];function s5(e,t){if(e==null)return{};var n=Ole(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ole(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 xE(e){"@babel/helpers - typeof";return xE=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},xE(e)}var l5={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"},Jo=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},u5=null,E2=null,c3=function e(t){if(t===u5&&Array.isArray(E2))return E2;var n=[];return M.Children.forEach(t,function(r){pt(r)||(hle.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),E2=n,u5=t,n};function Gr(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(i){return Jo(i)}):r=[Jo(t)],c3(e).forEach(function(i){var a=Ti(i,"type.displayName")||Ti(i,"type.name");r.indexOf(a)!==-1&&n.push(i)}),n}function _i(e,t){var n=Gr(e,t);return n&&n[0]}var c5=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,i=n.height;return!(!Ze(r)||r<=0||!Ze(i)||i<=0)},Tle=["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"],jle=function(t){return t&&t.type&&ic(t.type)&&Tle.indexOf(t.type)>=0},_U=function(t){return t&&xE(t)==="object"&&"clipDot"in t},Ple=function(t,n,r,i){var a,o=(a=A2==null?void 0:A2[i])!==null&&a!==void 0?a:[];return n.startsWith("data-")||!ht(t)&&(i&&o.includes(n)||Sle.includes(n))||r&&u3.includes(n)},ot=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(M.isValidElement(t)&&(i=t.props),!Id(i))return null;var a={};return Object.keys(i).forEach(function(o){var l;Ple((l=i)===null||l===void 0?void 0:l[o],o,n,r)&&(a[o]=i[o])}),a},SE=function e(t,n){if(t===n)return!0;var r=M.Children.count(t);if(r!==M.Children.count(n))return!1;if(r===0)return!0;if(r===1)return f5(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i<r;i++){var a=t[i],o=n[i];if(Array.isArray(a)||Array.isArray(o)){if(!e(a,o))return!1}else if(!f5(a,o))return!1}return!0},f5=function(t,n){if(pt(t)&&pt(n))return!0;if(!pt(t)&&!pt(n)){var r=t.props||{},i=r.children,a=s5(r,Ale),o=n.props||{},l=o.children,f=s5(o,Ele);return i&&l?kf(a,f)&&SE(i,l):!i&&!l?kf(a,f):!1}return!1},d5=function(t,n){var r=[],i={};return c3(t).forEach(function(a,o){if(jle(a))r.push(a);else if(a){var l=Jo(a.type),f=n[l]||{},u=f.handler,h=f.once;if(u&&(!h||!i[l])){var m=u(a,l,o);r.push(m),i[l]=!0}}}),r},Rle=function(t){var n=t&&t.type;return n&&l5[n]?l5[n]:null},Mle=function(t,n){return c3(n).indexOf(t)},Nle=["children","width","height","viewBox","className","style","title","desc"];function CE(){return CE=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},CE.apply(this,arguments)}function Lle(e,t){if(e==null)return{};var n=kle(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function kle(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 AE(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,a=e.className,o=e.style,l=e.title,f=e.desc,u=Lle(e,Nle),h=i||{width:n,height:r,x:0,y:0},m=be("recharts-surface",a);return pe.createElement("svg",CE({},ot(u,!0,"svg"),{className:m,width:n,height:r,style:o,viewBox:"".concat(h.x," ").concat(h.y," ").concat(h.width," ").concat(h.height)}),pe.createElement("title",null,l),pe.createElement("desc",null,f),t)}var Dle=["children","className"];function EE(){return EE=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},EE.apply(this,arguments)}function Ile(e,t){if(e==null)return{};var n=$le(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function $le(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 St=pe.forwardRef(function(e,t){var n=e.children,r=e.className,i=Ile(e,Dle),a=be("recharts-layer",r);return pe.createElement("g",EE({className:a},ot(i,!0),{ref:t}),n)}),_a=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),a=2;a<r;a++)i[a-2]=arguments[a]},O2,h5;function Ble(){if(h5)return O2;h5=1;function e(t,n,r){var i=-1,a=t.length;n<0&&(n=-n>a?0:a+n),r=r>a?a:r,r<0&&(r+=a),a=n>r?0:r-n>>>0,n>>>=0;for(var o=Array(a);++i<a;)o[i]=t[i+n];return o}return O2=e,O2}var T2,p5;function Ule(){if(p5)return T2;p5=1;var e=Ble();function t(n,r,i){var a=n.length;return i=i===void 0?a:i,!r&&i>=a?n:e(n,r,i)}return T2=t,T2}var j2,m5;function xU(){if(m5)return j2;m5=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,a="\\ufe0e\\ufe0f",o="\\u200d",l=RegExp("["+o+e+i+a+"]");function f(u){return l.test(u)}return j2=f,j2}var P2,g5;function zle(){if(g5)return P2;g5=1;function e(t){return t.split("")}return P2=e,P2}var R2,v5;function Fle(){if(v5)return R2;v5=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,a="\\ufe0e\\ufe0f",o="["+e+"]",l="["+i+"]",f="\\ud83c[\\udffb-\\udfff]",u="(?:"+l+"|"+f+")",h="[^"+e+"]",m="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",_="\\u200d",x=u+"?",b="["+a+"]?",S="(?:"+_+"(?:"+[h,m,g].join("|")+")"+b+x+")*",C=b+x+S,A="(?:"+[h+l+"?",l,m,g,o].join("|")+")",O=RegExp(f+"(?="+f+")|"+A+C,"g");function P(j){return j.match(O)||[]}return R2=P,R2}var M2,y5;function qle(){if(y5)return M2;y5=1;var e=zle(),t=xU(),n=Fle();function r(i){return t(i)?n(i):e(i)}return M2=r,M2}var N2,b5;function Vle(){if(b5)return N2;b5=1;var e=Ule(),t=xU(),n=qle(),r=vU();function i(a){return function(o){o=r(o);var l=t(o)?n(o):void 0,f=l?l[0]:o.charAt(0),u=l?e(l,1).join(""):o.slice(1);return f[a]()+u}}return N2=i,N2}var L2,w5;function Hle(){if(w5)return L2;w5=1;var e=Vle(),t=e("toUpperCase");return L2=t,L2}var Gle=Hle();const i1=zt(Gle);function un(e){return function(){return e}}const SU=Math.cos,d0=Math.sin,Ra=Math.sqrt,h0=Math.PI,a1=2*h0,OE=Math.PI,TE=2*OE,Lu=1e-6,Wle=TE-Lu;function CU(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function Yle(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return CU;const n=10**t;return function(r){this._+=r[0];for(let i=1,a=r.length;i<a;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class Kle{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?CU:Yle(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,a,o){this._append`C${+t},${+n},${+r},${+i},${this._x1=+a},${this._y1=+o}`}arcTo(t,n,r,i,a){if(t=+t,n=+n,r=+r,i=+i,a=+a,a<0)throw new Error(`negative radius: ${a}`);let o=this._x1,l=this._y1,f=r-t,u=i-n,h=o-t,m=l-n,g=h*h+m*m;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(g>Lu)if(!(Math.abs(m*f-u*h)>Lu)||!a)this._append`L${this._x1=t},${this._y1=n}`;else{let _=r-o,x=i-l,b=f*f+u*u,S=_*_+x*x,C=Math.sqrt(b),A=Math.sqrt(g),O=a*Math.tan((OE-Math.acos((b+g-S)/(2*C*A)))/2),P=O/A,j=O/C;Math.abs(P-1)>Lu&&this._append`L${t+P*h},${n+P*m}`,this._append`A${a},${a},0,0,${+(m*_>h*x)},${this._x1=t+j*f},${this._y1=n+j*u}`}}arc(t,n,r,i,a,o){if(t=+t,n=+n,r=+r,o=!!o,r<0)throw new Error(`negative radius: ${r}`);let l=r*Math.cos(i),f=r*Math.sin(i),u=t+l,h=n+f,m=1^o,g=o?i-a:a-i;this._x1===null?this._append`M${u},${h}`:(Math.abs(this._x1-u)>Lu||Math.abs(this._y1-h)>Lu)&&this._append`L${u},${h}`,r&&(g<0&&(g=g%TE+TE),g>Wle?this._append`A${r},${r},0,1,${m},${t-l},${n-f}A${r},${r},0,1,${m},${this._x1=u},${this._y1=h}`:g>Lu&&this._append`A${r},${r},0,${+(g>=OE)},${m},${this._x1=t+r*Math.cos(a)},${this._y1=n+r*Math.sin(a)}`)}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 f3(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 Kle(t)}function d3(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function AU(e){this._context=e}AU.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 o1(e){return new AU(e)}function EU(e){return e[0]}function OU(e){return e[1]}function TU(e,t){var n=un(!0),r=null,i=o1,a=null,o=f3(l);e=typeof e=="function"?e:e===void 0?EU:un(e),t=typeof t=="function"?t:t===void 0?OU:un(t);function l(f){var u,h=(f=d3(f)).length,m,g=!1,_;for(r==null&&(a=i(_=o())),u=0;u<=h;++u)!(u<h&&n(m=f[u],u,f))===g&&((g=!g)?a.lineStart():a.lineEnd()),g&&a.point(+e(m,u,f),+t(m,u,f));if(_)return a=null,_+""||null}return l.x=function(f){return arguments.length?(e=typeof f=="function"?f:un(+f),l):e},l.y=function(f){return arguments.length?(t=typeof f=="function"?f:un(+f),l):t},l.defined=function(f){return arguments.length?(n=typeof f=="function"?f:un(!!f),l):n},l.curve=function(f){return arguments.length?(i=f,r!=null&&(a=i(r)),l):i},l.context=function(f){return arguments.length?(f==null?r=a=null:a=i(r=f),l):r},l}function ty(e,t,n){var r=null,i=un(!0),a=null,o=o1,l=null,f=f3(u);e=typeof e=="function"?e:e===void 0?EU:un(+e),t=typeof t=="function"?t:un(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?OU:un(+n);function u(m){var g,_,x,b=(m=d3(m)).length,S,C=!1,A,O=new Array(b),P=new Array(b);for(a==null&&(l=o(A=f())),g=0;g<=b;++g){if(!(g<b&&i(S=m[g],g,m))===C)if(C=!C)_=g,l.areaStart(),l.lineStart();else{for(l.lineEnd(),l.lineStart(),x=g-1;x>=_;--x)l.point(O[x],P[x]);l.lineEnd(),l.areaEnd()}C&&(O[g]=+e(S,g,m),P[g]=+t(S,g,m),l.point(r?+r(S,g,m):O[g],n?+n(S,g,m):P[g]))}if(A)return l=null,A+""||null}function h(){return TU().defined(i).curve(o).context(a)}return u.x=function(m){return arguments.length?(e=typeof m=="function"?m:un(+m),r=null,u):e},u.x0=function(m){return arguments.length?(e=typeof m=="function"?m:un(+m),u):e},u.x1=function(m){return arguments.length?(r=m==null?null:typeof m=="function"?m:un(+m),u):r},u.y=function(m){return arguments.length?(t=typeof m=="function"?m:un(+m),n=null,u):t},u.y0=function(m){return arguments.length?(t=typeof m=="function"?m:un(+m),u):t},u.y1=function(m){return arguments.length?(n=m==null?null:typeof m=="function"?m:un(+m),u):n},u.lineX0=u.lineY0=function(){return h().x(e).y(t)},u.lineY1=function(){return h().x(e).y(n)},u.lineX1=function(){return h().x(r).y(t)},u.defined=function(m){return arguments.length?(i=typeof m=="function"?m:un(!!m),u):i},u.curve=function(m){return arguments.length?(o=m,a!=null&&(l=o(a)),u):o},u.context=function(m){return arguments.length?(m==null?a=l=null:l=o(a=m),u):a},u}class jU{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 Zle(e){return new jU(e,!0)}function Xle(e){return new jU(e,!1)}const h3={draw(e,t){const n=Ra(t/h0);e.moveTo(n,0),e.arc(0,0,n,0,a1)}},Qle={draw(e,t){const n=Ra(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()}},PU=Ra(1/3),Jle=PU*2,eue={draw(e,t){const n=Ra(t/Jle),r=n*PU;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},tue={draw(e,t){const n=Ra(t),r=-n/2;e.rect(r,r,n,n)}},nue=.8908130915292852,RU=d0(h0/10)/d0(7*h0/10),rue=d0(a1/10)*RU,iue=-SU(a1/10)*RU,aue={draw(e,t){const n=Ra(t*nue),r=rue*n,i=iue*n;e.moveTo(0,-n),e.lineTo(r,i);for(let a=1;a<5;++a){const o=a1*a/5,l=SU(o),f=d0(o);e.lineTo(f*n,-l*n),e.lineTo(l*r-f*i,f*r+l*i)}e.closePath()}},k2=Ra(3),oue={draw(e,t){const n=-Ra(t/(k2*3));e.moveTo(0,n*2),e.lineTo(-k2*n,-n),e.lineTo(k2*n,-n),e.closePath()}},Yi=-.5,Ki=Ra(3)/2,jE=1/Ra(12),sue=(jE/2+1)*3,lue={draw(e,t){const n=Ra(t/sue),r=n/2,i=n*jE,a=r,o=n*jE+n,l=-a,f=o;e.moveTo(r,i),e.lineTo(a,o),e.lineTo(l,f),e.lineTo(Yi*r-Ki*i,Ki*r+Yi*i),e.lineTo(Yi*a-Ki*o,Ki*a+Yi*o),e.lineTo(Yi*l-Ki*f,Ki*l+Yi*f),e.lineTo(Yi*r+Ki*i,Yi*i-Ki*r),e.lineTo(Yi*a+Ki*o,Yi*o-Ki*a),e.lineTo(Yi*l+Ki*f,Yi*f-Ki*l),e.closePath()}};function uue(e,t){let n=null,r=f3(i);e=typeof e=="function"?e:un(e||h3),t=typeof t=="function"?t:un(t===void 0?64:+t);function i(){let a;if(n||(n=a=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),a)return n=null,a+""||null}return i.type=function(a){return arguments.length?(e=typeof a=="function"?a:un(a),i):e},i.size=function(a){return arguments.length?(t=typeof a=="function"?a:un(+a),i):t},i.context=function(a){return arguments.length?(n=a??null,i):n},i}function p0(){}function m0(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 MU(e){this._context=e}MU.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:m0(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:m0(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function cue(e){return new MU(e)}function NU(e){this._context=e}NU.prototype={areaStart:p0,areaEnd:p0,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:m0(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function fue(e){return new NU(e)}function LU(e){this._context=e}LU.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:m0(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function due(e){return new LU(e)}function kU(e){this._context=e}kU.prototype={areaStart:p0,areaEnd:p0,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 hue(e){return new kU(e)}function _5(e){return e<0?-1:1}function x5(e,t,n){var r=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(r||i<0&&-0),o=(n-e._y1)/(i||r<0&&-0),l=(a*i+o*r)/(r+i);return(_5(a)+_5(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(l))||0}function S5(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function D2(e,t,n){var r=e._x0,i=e._y0,a=e._x1,o=e._y1,l=(a-r)/3;e._context.bezierCurveTo(r+l,i+l*t,a-l,o-l*n,a,o)}function g0(e){this._context=e}g0.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:D2(this,this._t0,S5(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,D2(this,S5(this,n=x5(this,e,t)),n);break;default:D2(this,this._t0,n=x5(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function DU(e){this._context=new IU(e)}(DU.prototype=Object.create(g0.prototype)).point=function(e,t){g0.prototype.point.call(this,t,e)};function IU(e){this._context=e}IU.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,a){this._context.bezierCurveTo(t,e,r,n,a,i)}};function pue(e){return new g0(e)}function mue(e){return new DU(e)}function $U(e){this._context=e}$U.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=C5(e),i=C5(t),a=0,o=1;o<n;++a,++o)this._context.bezierCurveTo(r[0][a],i[0][a],r[1][a],i[1][a],e[o],t[o]);(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 C5(e){var t,n=e.length-1,r,i=new Array(n),a=new Array(n),o=new Array(n);for(i[0]=0,a[0]=2,o[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,a[t]=4,o[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,a[n-1]=7,o[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/a[t-1],a[t]-=r,o[t]-=r*o[t-1];for(i[n-1]=o[n-1]/a[n-1],t=n-2;t>=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)a[t]=2*e[t+1]-i[t+1];return[i,a]}function gue(e){return new $U(e)}function s1(e,t){this._context=e,this._t=t}s1.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 vue(e){return new s1(e,.5)}function yue(e){return new s1(e,0)}function bue(e){return new s1(e,1)}function Yf(e,t){if((o=e.length)>1)for(var n=1,r,i,a=e[t[0]],o,l=a.length;n<o;++n)for(i=a,a=e[t[n]],r=0;r<l;++r)a[r][1]+=a[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function PE(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function wue(e,t){return e[t]}function _ue(e){const t=[];return t.key=e,t}function xue(){var e=un([]),t=PE,n=Yf,r=wue;function i(a){var o=Array.from(e.apply(this,arguments),_ue),l,f=o.length,u=-1,h;for(const m of a)for(l=0,++u;l<f;++l)(o[l][u]=[0,+r(m,o[l].key,u,a)]).data=m;for(l=0,h=d3(t(o));l<f;++l)o[h[l]].index=l;return n(o,h),o}return i.keys=function(a){return arguments.length?(e=typeof a=="function"?a:un(Array.from(a)),i):e},i.value=function(a){return arguments.length?(r=typeof a=="function"?a:un(+a),i):r},i.order=function(a){return arguments.length?(t=a==null?PE:typeof a=="function"?a:un(Array.from(a)),i):t},i.offset=function(a){return arguments.length?(n=a??Yf,i):n},i}function Sue(e,t){if((r=e.length)>0){for(var n,r,i=0,a=e[0].length,o;i<a;++i){for(o=n=0;n<r;++n)o+=e[n][i][1]||0;if(o)for(n=0;n<r;++n)e[n][i][1]/=o}Yf(e,t)}}function Cue(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,a=r.length;n<a;++n){for(var o=0,l=0;o<i;++o)l+=e[o][n][1]||0;r[n][1]+=r[n][0]=-l/2}Yf(e,t)}}function Aue(e,t){if(!(!((o=e.length)>0)||!((a=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,a,o;r<a;++r){for(var l=0,f=0,u=0;l<o;++l){for(var h=e[t[l]],m=h[r][1]||0,g=h[r-1][1]||0,_=(m-g)/2,x=0;x<l;++x){var b=e[t[x]],S=b[r][1]||0,C=b[r-1][1]||0;_+=S-C}f+=m,u+=_*m}i[r-1][1]+=i[r-1][0]=n,f&&(n-=u/f)}i[r-1][1]+=i[r-1][0]=n,Yf(e,t)}}function am(e){"@babel/helpers - typeof";return am=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},am(e)}var Eue=["type","size","sizeType"];function RE(){return RE=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},RE.apply(this,arguments)}function A5(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 E5(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?A5(Object(n),!0).forEach(function(r){Oue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):A5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Oue(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=jue(e,"string");return am(t)=="symbol"?t:t+""}function jue(e,t){if(am(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(am(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Pue(e,t){if(e==null)return{};var n=Rue(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Rue(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 BU={symbolCircle:h3,symbolCross:Qle,symbolDiamond:eue,symbolSquare:tue,symbolStar:aue,symbolTriangle:oue,symbolWye:lue},Mue=Math.PI/180,Nue=function(t){var n="symbol".concat(i1(t));return BU[n]||h3},Lue=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*Mue;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}},kue=function(t,n){BU["symbol".concat(i1(t))]=n},l1=function(t){var n=t.type,r=n===void 0?"circle":n,i=t.size,a=i===void 0?64:i,o=t.sizeType,l=o===void 0?"area":o,f=Pue(t,Eue),u=E5(E5({},f),{},{type:r,size:a,sizeType:l}),h=function(){var S=Nue(r),C=uue().type(S).size(Lue(a,l,r));return C()},m=u.className,g=u.cx,_=u.cy,x=ot(u,!0);return g===+g&&_===+_&&a===+a?pe.createElement("path",RE({},x,{className:be("recharts-symbols",m),transform:"translate(".concat(g,", ").concat(_,")"),d:h()})):null};l1.registerSymbol=kue;function Kf(e){"@babel/helpers - typeof";return Kf=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},Kf(e)}function ME(){return ME=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},ME.apply(this,arguments)}function O5(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 Due(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?O5(Object(n),!0).forEach(function(r){om(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):O5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Iue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $ue(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,zU(r.key),r)}}function Bue(e,t,n){return t&&$ue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Uue(e,t,n){return t=v0(t),zue(e,UU()?Reflect.construct(t,n||[],v0(e).constructor):t.apply(e,n))}function zue(e,t){if(t&&(Kf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Fue(e)}function Fue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UU(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(UU=function(){return!!e})()}function v0(e){return v0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},v0(e)}function que(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&&NE(e,t)}function NE(e,t){return NE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},NE(e,t)}function om(e,t,n){return t=zU(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zU(e){var t=Vue(e,"string");return Kf(t)=="symbol"?t:t+""}function Vue(e,t){if(Kf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Kf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var ma=32,p3=function(e){function t(){return Iue(this,t),Uue(this,t,arguments)}return que(t,e),Bue(t,[{key:"renderIcon",value:function(r){var i=this.props.inactiveColor,a=ma/2,o=ma/6,l=ma/3,f=r.inactive?i:r.color;if(r.type==="plainline")return pe.createElement("line",{strokeWidth:4,fill:"none",stroke:f,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:a,x2:ma,y2:a,className:"recharts-legend-icon"});if(r.type==="line")return pe.createElement("path",{strokeWidth:4,fill:"none",stroke:f,d:"M0,".concat(a,"h").concat(l,`
|
||
A`).concat(o,",").concat(o,",0,1,1,").concat(2*l,",").concat(a,`
|
||
H`).concat(ma,"M").concat(2*l,",").concat(a,`
|
||
A`).concat(o,",").concat(o,",0,1,1,").concat(l,",").concat(a),className:"recharts-legend-icon"});if(r.type==="rect")return pe.createElement("path",{stroke:"none",fill:f,d:"M0,".concat(ma/8,"h").concat(ma,"v").concat(ma*3/4,"h").concat(-32,"z"),className:"recharts-legend-icon"});if(pe.isValidElement(r.legendIcon)){var u=Due({},r);return delete u.legendIcon,pe.cloneElement(r.legendIcon,u)}return pe.createElement(l1,{fill:f,cx:a,cy:a,size:ma,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,i=this.props,a=i.payload,o=i.iconSize,l=i.layout,f=i.formatter,u=i.inactiveColor,h={x:0,y:0,width:ma,height:ma},m={display:l==="horizontal"?"inline-block":"block",marginRight:10},g={display:"inline-block",verticalAlign:"middle",marginRight:4};return a.map(function(_,x){var b=_.formatter||f,S=be(om(om({"recharts-legend-item":!0},"legend-item-".concat(x),!0),"inactive",_.inactive));if(_.type==="none")return null;var C=ht(_.value)?null:_.value;_a(!ht(_.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=_.inactive?u:_.color;return pe.createElement("li",ME({className:S,style:m,key:"legend-item-".concat(x)},Bl(r.props,_,x)),pe.createElement(AE,{width:o,height:o,viewBox:h,style:g},r.renderIcon(_)),pe.createElement("span",{className:"recharts-legend-item-text",style:{color:A}},b?b(C,_,x):C))})}},{key:"render",value:function(){var r=this.props,i=r.payload,a=r.layout,o=r.align;if(!i||!i.length)return null;var l={padding:0,margin:0,textAlign:a==="horizontal"?o:"left"};return pe.createElement("ul",{className:"recharts-default-legend",style:l},this.renderItems())}}])}(M.PureComponent);om(p3,"displayName","Legend");om(p3,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var I2,T5;function Hue(){if(T5)return I2;T5=1;var e=t1();function t(){this.__data__=new e,this.size=0}return I2=t,I2}var $2,j5;function Gue(){if(j5)return $2;j5=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return $2=e,$2}var B2,P5;function Wue(){if(P5)return B2;P5=1;function e(t){return this.__data__.get(t)}return B2=e,B2}var U2,R5;function Yue(){if(R5)return U2;R5=1;function e(t){return this.__data__.has(t)}return U2=e,U2}var z2,M5;function Kue(){if(M5)return z2;M5=1;var e=t1(),t=a3(),n=o3(),r=200;function i(a,o){var l=this.__data__;if(l instanceof e){var f=l.__data__;if(!t||f.length<r-1)return f.push([a,o]),this.size=++l.size,this;l=this.__data__=new n(f)}return l.set(a,o),this.size=l.size,this}return z2=i,z2}var F2,N5;function FU(){if(N5)return F2;N5=1;var e=t1(),t=Hue(),n=Gue(),r=Wue(),i=Yue(),a=Kue();function o(l){var f=this.__data__=new e(l);this.size=f.size}return o.prototype.clear=t,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=a,F2=o,F2}var q2,L5;function Zue(){if(L5)return q2;L5=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return q2=t,q2}var V2,k5;function Xue(){if(k5)return V2;k5=1;function e(t){return this.__data__.has(t)}return V2=e,V2}var H2,D5;function qU(){if(D5)return H2;D5=1;var e=o3(),t=Zue(),n=Xue();function r(i){var a=-1,o=i==null?0:i.length;for(this.__data__=new e;++a<o;)this.add(i[a])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,H2=r,H2}var G2,I5;function VU(){if(I5)return G2;I5=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 G2=e,G2}var W2,$5;function HU(){if($5)return W2;$5=1;function e(t,n){return t.has(n)}return W2=e,W2}var Y2,B5;function GU(){if(B5)return Y2;B5=1;var e=qU(),t=VU(),n=HU(),r=1,i=2;function a(o,l,f,u,h,m){var g=f&r,_=o.length,x=l.length;if(_!=x&&!(g&&x>_))return!1;var b=m.get(o),S=m.get(l);if(b&&S)return b==l&&S==o;var C=-1,A=!0,O=f&i?new e:void 0;for(m.set(o,l),m.set(l,o);++C<_;){var P=o[C],j=l[C];if(u)var R=g?u(j,P,C,l,o,m):u(P,j,C,o,l,m);if(R!==void 0){if(R)continue;A=!1;break}if(O){if(!t(l,function(U,V){if(!n(O,V)&&(P===U||h(P,U,f,u,m)))return O.push(V)})){A=!1;break}}else if(!(P===j||h(P,j,f,u,m))){A=!1;break}}return m.delete(o),m.delete(l),A}return Y2=a,Y2}var K2,U5;function Que(){if(U5)return K2;U5=1;var e=go(),t=e.Uint8Array;return K2=t,K2}var Z2,z5;function Jue(){if(z5)return Z2;z5=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,a){r[++n]=[a,i]}),r}return Z2=e,Z2}var X2,F5;function m3(){if(F5)return X2;F5=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return X2=e,X2}var Q2,q5;function ece(){if(q5)return Q2;q5=1;var e=lg(),t=Que(),n=i3(),r=GU(),i=Jue(),a=m3(),o=1,l=2,f="[object Boolean]",u="[object Date]",h="[object Error]",m="[object Map]",g="[object Number]",_="[object RegExp]",x="[object Set]",b="[object String]",S="[object Symbol]",C="[object ArrayBuffer]",A="[object DataView]",O=e?e.prototype:void 0,P=O?O.valueOf:void 0;function j(R,U,V,Y,K,W,ee){switch(V){case A:if(R.byteLength!=U.byteLength||R.byteOffset!=U.byteOffset)return!1;R=R.buffer,U=U.buffer;case C:return!(R.byteLength!=U.byteLength||!W(new t(R),new t(U)));case f:case u:case g:return n(+R,+U);case h:return R.name==U.name&&R.message==U.message;case _:case b:return R==U+"";case m:var ie=i;case x:var X=Y&o;if(ie||(ie=a),R.size!=U.size&&!X)return!1;var ne=ee.get(R);if(ne)return ne==U;Y|=l,ee.set(R,U);var H=r(ie(R),ie(U),Y,K,W,ee);return ee.delete(R),H;case S:if(P)return P.call(R)==P.call(U)}return!1}return Q2=j,Q2}var J2,V5;function WU(){if(V5)return J2;V5=1;function e(t,n){for(var r=-1,i=n.length,a=t.length;++r<i;)t[a+r]=n[r];return t}return J2=e,J2}var eS,H5;function tce(){if(H5)return eS;H5=1;var e=WU(),t=ri();function n(r,i,a){var o=i(r);return t(r)?o:e(o,a(r))}return eS=n,eS}var tS,G5;function nce(){if(G5)return tS;G5=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,a=0,o=[];++r<i;){var l=t[r];n(l,r,t)&&(o[a++]=l)}return o}return tS=e,tS}var nS,W5;function rce(){if(W5)return nS;W5=1;function e(){return[]}return nS=e,nS}var rS,Y5;function ice(){if(Y5)return rS;Y5=1;var e=nce(),t=rce(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,a=i?function(o){return o==null?[]:(o=Object(o),e(i(o),function(l){return r.call(o,l)}))}:t;return rS=a,rS}var iS,K5;function ace(){if(K5)return iS;K5=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return iS=e,iS}var aS,Z5;function oce(){if(Z5)return aS;Z5=1;var e=hs(),t=ps(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return aS=r,aS}var oS,X5;function g3(){if(X5)return oS;X5=1;var e=oce(),t=ps(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,a=e(function(){return arguments}())?e:function(o){return t(o)&&r.call(o,"callee")&&!i.call(o,"callee")};return oS=a,oS}var Cp={exports:{}},sS,Q5;function sce(){if(Q5)return sS;Q5=1;function e(){return!1}return sS=e,sS}Cp.exports;var J5;function YU(){return J5||(J5=1,function(e,t){var n=go(),r=sce(),i=t&&!t.nodeType&&t,a=i&&!0&&e&&!e.nodeType&&e,o=a&&a.exports===i,l=o?n.Buffer:void 0,f=l?l.isBuffer:void 0,u=f||r;e.exports=u}(Cp,Cp.exports)),Cp.exports}var lS,eL;function v3(){if(eL)return lS;eL=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var a=typeof r;return i=i??e,!!i&&(a=="number"||a!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return lS=n,lS}var uS,tL;function y3(){if(tL)return uS;tL=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return uS=t,uS}var cS,nL;function lce(){if(nL)return cS;nL=1;var e=hs(),t=y3(),n=ps(),r="[object Arguments]",i="[object Array]",a="[object Boolean]",o="[object Date]",l="[object Error]",f="[object Function]",u="[object Map]",h="[object Number]",m="[object Object]",g="[object RegExp]",_="[object Set]",x="[object String]",b="[object WeakMap]",S="[object ArrayBuffer]",C="[object DataView]",A="[object Float32Array]",O="[object Float64Array]",P="[object Int8Array]",j="[object Int16Array]",R="[object Int32Array]",U="[object Uint8Array]",V="[object Uint8ClampedArray]",Y="[object Uint16Array]",K="[object Uint32Array]",W={};W[A]=W[O]=W[P]=W[j]=W[R]=W[U]=W[V]=W[Y]=W[K]=!0,W[r]=W[i]=W[S]=W[a]=W[C]=W[o]=W[l]=W[f]=W[u]=W[h]=W[m]=W[g]=W[_]=W[x]=W[b]=!1;function ee(ie){return n(ie)&&t(ie.length)&&!!W[e(ie)]}return cS=ee,cS}var fS,rL;function KU(){if(rL)return fS;rL=1;function e(t){return function(n){return t(n)}}return fS=e,fS}var Ap={exports:{}};Ap.exports;var iL;function uce(){return iL||(iL=1,function(e,t){var n=pU(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===r,o=a&&n.process,l=function(){try{var f=i&&i.require&&i.require("util").types;return f||o&&o.binding&&o.binding("util")}catch{}}();e.exports=l}(Ap,Ap.exports)),Ap.exports}var dS,aL;function ZU(){if(aL)return dS;aL=1;var e=lce(),t=KU(),n=uce(),r=n&&n.isTypedArray,i=r?t(r):e;return dS=i,dS}var hS,oL;function cce(){if(oL)return hS;oL=1;var e=ace(),t=g3(),n=ri(),r=YU(),i=v3(),a=ZU(),o=Object.prototype,l=o.hasOwnProperty;function f(u,h){var m=n(u),g=!m&&t(u),_=!m&&!g&&r(u),x=!m&&!g&&!_&&a(u),b=m||g||_||x,S=b?e(u.length,String):[],C=S.length;for(var A in u)(h||l.call(u,A))&&!(b&&(A=="length"||_&&(A=="offset"||A=="parent")||x&&(A=="buffer"||A=="byteLength"||A=="byteOffset")||i(A,C)))&&S.push(A);return S}return hS=f,hS}var pS,sL;function fce(){if(sL)return pS;sL=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return pS=t,pS}var mS,lL;function XU(){if(lL)return mS;lL=1;function e(t,n){return function(r){return t(n(r))}}return mS=e,mS}var gS,uL;function dce(){if(uL)return gS;uL=1;var e=XU(),t=e(Object.keys,Object);return gS=t,gS}var vS,cL;function hce(){if(cL)return vS;cL=1;var e=fce(),t=dce(),n=Object.prototype,r=n.hasOwnProperty;function i(a){if(!e(a))return t(a);var o=[];for(var l in Object(a))r.call(a,l)&&l!="constructor"&&o.push(l);return o}return vS=i,vS}var yS,fL;function ug(){if(fL)return yS;fL=1;var e=r3(),t=y3();function n(r){return r!=null&&t(r.length)&&!e(r)}return yS=n,yS}var bS,dL;function u1(){if(dL)return bS;dL=1;var e=cce(),t=hce(),n=ug();function r(i){return n(i)?e(i):t(i)}return bS=r,bS}var wS,hL;function pce(){if(hL)return wS;hL=1;var e=tce(),t=ice(),n=u1();function r(i){return e(i,n,t)}return wS=r,wS}var _S,pL;function mce(){if(pL)return _S;pL=1;var e=pce(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(a,o,l,f,u,h){var m=l&t,g=e(a),_=g.length,x=e(o),b=x.length;if(_!=b&&!m)return!1;for(var S=_;S--;){var C=g[S];if(!(m?C in o:r.call(o,C)))return!1}var A=h.get(a),O=h.get(o);if(A&&O)return A==o&&O==a;var P=!0;h.set(a,o),h.set(o,a);for(var j=m;++S<_;){C=g[S];var R=a[C],U=o[C];if(f)var V=m?f(U,R,C,o,a,h):f(R,U,C,a,o,h);if(!(V===void 0?R===U||u(R,U,l,f,h):V)){P=!1;break}j||(j=C=="constructor")}if(P&&!j){var Y=a.constructor,K=o.constructor;Y!=K&&"constructor"in a&&"constructor"in o&&!(typeof Y=="function"&&Y instanceof Y&&typeof K=="function"&&K instanceof K)&&(P=!1)}return h.delete(a),h.delete(o),P}return _S=i,_S}var xS,mL;function gce(){if(mL)return xS;mL=1;var e=hc(),t=go(),n=e(t,"DataView");return xS=n,xS}var SS,gL;function vce(){if(gL)return SS;gL=1;var e=hc(),t=go(),n=e(t,"Promise");return SS=n,SS}var CS,vL;function QU(){if(vL)return CS;vL=1;var e=hc(),t=go(),n=e(t,"Set");return CS=n,CS}var AS,yL;function yce(){if(yL)return AS;yL=1;var e=hc(),t=go(),n=e(t,"WeakMap");return AS=n,AS}var ES,bL;function bce(){if(bL)return ES;bL=1;var e=gce(),t=a3(),n=vce(),r=QU(),i=yce(),a=hs(),o=mU(),l="[object Map]",f="[object Object]",u="[object Promise]",h="[object Set]",m="[object WeakMap]",g="[object DataView]",_=o(e),x=o(t),b=o(n),S=o(r),C=o(i),A=a;return(e&&A(new e(new ArrayBuffer(1)))!=g||t&&A(new t)!=l||n&&A(n.resolve())!=u||r&&A(new r)!=h||i&&A(new i)!=m)&&(A=function(O){var P=a(O),j=P==f?O.constructor:void 0,R=j?o(j):"";if(R)switch(R){case _:return g;case x:return l;case b:return u;case S:return h;case C:return m}return P}),ES=A,ES}var OS,wL;function wce(){if(wL)return OS;wL=1;var e=FU(),t=GU(),n=ece(),r=mce(),i=bce(),a=ri(),o=YU(),l=ZU(),f=1,u="[object Arguments]",h="[object Array]",m="[object Object]",g=Object.prototype,_=g.hasOwnProperty;function x(b,S,C,A,O,P){var j=a(b),R=a(S),U=j?h:i(b),V=R?h:i(S);U=U==u?m:U,V=V==u?m:V;var Y=U==m,K=V==m,W=U==V;if(W&&o(b)){if(!o(S))return!1;j=!0,Y=!1}if(W&&!Y)return P||(P=new e),j||l(b)?t(b,S,C,A,O,P):n(b,S,U,C,A,O,P);if(!(C&f)){var ee=Y&&_.call(b,"__wrapped__"),ie=K&&_.call(S,"__wrapped__");if(ee||ie){var X=ee?b.value():b,ne=ie?S.value():S;return P||(P=new e),O(X,ne,C,A,P)}}return W?(P||(P=new e),r(b,S,C,A,O,P)):!1}return OS=x,OS}var TS,_L;function b3(){if(_L)return TS;_L=1;var e=wce(),t=ps();function n(r,i,a,o,l){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,a,o,n,l)}return TS=n,TS}var jS,xL;function _ce(){if(xL)return jS;xL=1;var e=FU(),t=b3(),n=1,r=2;function i(a,o,l,f){var u=l.length,h=u,m=!f;if(a==null)return!h;for(a=Object(a);u--;){var g=l[u];if(m&&g[2]?g[1]!==a[g[0]]:!(g[0]in a))return!1}for(;++u<h;){g=l[u];var _=g[0],x=a[_],b=g[1];if(m&&g[2]){if(x===void 0&&!(_ in a))return!1}else{var S=new e;if(f)var C=f(x,b,_,a,o,S);if(!(C===void 0?t(b,x,n|r,f,S):C))return!1}}return!0}return jS=i,jS}var PS,SL;function JU(){if(SL)return PS;SL=1;var e=Wl();function t(n){return n===n&&!e(n)}return PS=t,PS}var RS,CL;function xce(){if(CL)return RS;CL=1;var e=JU(),t=u1();function n(r){for(var i=t(r),a=i.length;a--;){var o=i[a],l=r[o];i[a]=[o,l,e(l)]}return i}return RS=n,RS}var MS,AL;function ez(){if(AL)return MS;AL=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return MS=e,MS}var NS,EL;function Sce(){if(EL)return NS;EL=1;var e=_ce(),t=xce(),n=ez();function r(i){var a=t(i);return a.length==1&&a[0][2]?n(a[0][0],a[0][1]):function(o){return o===i||e(o,i,a)}}return NS=r,NS}var LS,OL;function Cce(){if(OL)return LS;OL=1;function e(t,n){return t!=null&&n in Object(t)}return LS=e,LS}var kS,TL;function Ace(){if(TL)return kS;TL=1;var e=yU(),t=g3(),n=ri(),r=v3(),i=y3(),a=r1();function o(l,f,u){f=e(f,l);for(var h=-1,m=f.length,g=!1;++h<m;){var _=a(f[h]);if(!(g=l!=null&&u(l,_)))break;l=l[_]}return g||++h!=m?g:(m=l==null?0:l.length,!!m&&i(m)&&r(_,m)&&(n(l)||t(l)))}return kS=o,kS}var DS,jL;function Ece(){if(jL)return DS;jL=1;var e=Cce(),t=Ace();function n(r,i){return r!=null&&t(r,i,e)}return DS=n,DS}var IS,PL;function Oce(){if(PL)return IS;PL=1;var e=b3(),t=bU(),n=Ece(),r=n3(),i=JU(),a=ez(),o=r1(),l=1,f=2;function u(h,m){return r(h)&&i(m)?a(o(h),m):function(g){var _=t(g,h);return _===void 0&&_===m?n(g,h):e(m,_,l|f)}}return IS=u,IS}var $S,RL;function Bd(){if(RL)return $S;RL=1;function e(t){return t}return $S=e,$S}var BS,ML;function Tce(){if(ML)return BS;ML=1;function e(t){return function(n){return n==null?void 0:n[t]}}return BS=e,BS}var US,NL;function jce(){if(NL)return US;NL=1;var e=l3();function t(n){return function(r){return e(r,n)}}return US=t,US}var zS,LL;function Pce(){if(LL)return zS;LL=1;var e=Tce(),t=jce(),n=n3(),r=r1();function i(a){return n(a)?e(r(a)):t(a)}return zS=i,zS}var FS,kL;function vo(){if(kL)return FS;kL=1;var e=Sce(),t=Oce(),n=Bd(),r=ri(),i=Pce();function a(o){return typeof o=="function"?o:o==null?n:typeof o=="object"?r(o)?t(o[0],o[1]):e(o):i(o)}return FS=a,FS}var qS,DL;function tz(){if(DL)return qS;DL=1;function e(t,n,r,i){for(var a=t.length,o=r+(i?1:-1);i?o--:++o<a;)if(n(t[o],o,t))return o;return-1}return qS=e,qS}var VS,IL;function Rce(){if(IL)return VS;IL=1;function e(t){return t!==t}return VS=e,VS}var HS,$L;function Mce(){if($L)return HS;$L=1;function e(t,n,r){for(var i=r-1,a=t.length;++i<a;)if(t[i]===n)return i;return-1}return HS=e,HS}var GS,BL;function Nce(){if(BL)return GS;BL=1;var e=tz(),t=Rce(),n=Mce();function r(i,a,o){return a===a?n(i,a,o):e(i,t,o)}return GS=r,GS}var WS,UL;function Lce(){if(UL)return WS;UL=1;var e=Nce();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return WS=t,WS}var YS,zL;function kce(){if(zL)return YS;zL=1;function e(t,n,r){for(var i=-1,a=t==null?0:t.length;++i<a;)if(r(n,t[i]))return!0;return!1}return YS=e,YS}var KS,FL;function Dce(){if(FL)return KS;FL=1;function e(){}return KS=e,KS}var ZS,qL;function Ice(){if(qL)return ZS;qL=1;var e=QU(),t=Dce(),n=m3(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(a){return new e(a)}:t;return ZS=i,ZS}var XS,VL;function $ce(){if(VL)return XS;VL=1;var e=qU(),t=Lce(),n=kce(),r=HU(),i=Ice(),a=m3(),o=200;function l(f,u,h){var m=-1,g=t,_=f.length,x=!0,b=[],S=b;if(h)x=!1,g=n;else if(_>=o){var C=u?null:i(f);if(C)return a(C);x=!1,g=r,S=new e}else S=u?[]:b;e:for(;++m<_;){var A=f[m],O=u?u(A):A;if(A=h||A!==0?A:0,x&&O===O){for(var P=S.length;P--;)if(S[P]===O)continue e;u&&S.push(O),b.push(A)}else g(S,O,h)||(S!==b&&S.push(O),b.push(A))}return b}return XS=l,XS}var QS,HL;function Bce(){if(HL)return QS;HL=1;var e=vo(),t=$ce();function n(r,i){return r&&r.length?t(r,e(i,2)):[]}return QS=n,QS}var Uce=Bce();const GL=zt(Uce);function nz(e,t,n){return t===!0?GL(e,n):ht(t)?GL(e,t):e}function Zf(e){"@babel/helpers - typeof";return Zf=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},Zf(e)}var zce=["ref"];function WL(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 Go(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WL(Object(n),!0).forEach(function(r){c1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WL(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Fce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function YL(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,iz(r.key),r)}}function qce(e,t,n){return t&&YL(e.prototype,t),n&&YL(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Vce(e,t,n){return t=y0(t),Hce(e,rz()?Reflect.construct(t,n||[],y0(e).constructor):t.apply(e,n))}function Hce(e,t){if(t&&(Zf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Gce(e)}function Gce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function rz(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(rz=function(){return!!e})()}function y0(e){return y0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},y0(e)}function Wce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&LE(e,t)}function LE(e,t){return LE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},LE(e,t)}function c1(e,t,n){return t=iz(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function iz(e){var t=Yce(e,"string");return Zf(t)=="symbol"?t:t+""}function Yce(e,t){if(Zf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Zf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Kce(e,t){if(e==null)return{};var n=Zce(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Zce(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 Xce(e){return e.value}function Qce(e,t){if(pe.isValidElement(e))return pe.cloneElement(e,t);if(typeof e=="function")return pe.createElement(e,t);t.ref;var n=Kce(t,zce);return pe.createElement(p3,n)}var KL=1,Df=function(e){function t(){var n;Fce(this,t);for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];return n=Vce(this,t,[].concat(i)),c1(n,"lastBoundingBox",{width:-1,height:-1}),n}return Wce(t,e),qce(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)>KL||Math.abs(i.height-this.lastBoundingBox.height)>KL)&&(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?Go({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var i=this.props,a=i.layout,o=i.align,l=i.verticalAlign,f=i.margin,u=i.chartWidth,h=i.chartHeight,m,g;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(o==="center"&&a==="vertical"){var _=this.getBBoxSnapshot();m={left:((u||0)-_.width)/2}}else m=o==="right"?{right:f&&f.right||0}:{left:f&&f.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(l==="middle"){var x=this.getBBoxSnapshot();g={top:((h||0)-x.height)/2}}else g=l==="bottom"?{bottom:f&&f.bottom||0}:{top:f&&f.top||0};return Go(Go({},m),g)}},{key:"render",value:function(){var r=this,i=this.props,a=i.content,o=i.width,l=i.height,f=i.wrapperStyle,u=i.payloadUniqBy,h=i.payload,m=Go(Go({position:"absolute",width:o||"auto",height:l||"auto"},this.getDefaultPosition(f)),f);return pe.createElement("div",{className:"recharts-legend-wrapper",style:m,ref:function(_){r.wrapperNode=_}},Qce(a,Go(Go({},this.props),{},{payload:nz(h,u,Xce)})))}}],[{key:"getWithHeight",value:function(r,i){var a=Go(Go({},this.defaultProps),r.props),o=a.layout;return o==="vertical"&&Ze(r.props.height)?{height:r.props.height}:o==="horizontal"?{width:r.props.width||i}:null}}])}(M.PureComponent);c1(Df,"displayName","Legend");c1(Df,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var JS,ZL;function Jce(){if(ZL)return JS;ZL=1;var e=lg(),t=g3(),n=ri(),r=e?e.isConcatSpreadable:void 0;function i(a){return n(a)||t(a)||!!(r&&a&&a[r])}return JS=i,JS}var eC,XL;function az(){if(XL)return eC;XL=1;var e=WU(),t=Jce();function n(r,i,a,o,l){var f=-1,u=r.length;for(a||(a=t),l||(l=[]);++f<u;){var h=r[f];i>0&&a(h)?i>1?n(h,i-1,a,o,l):e(l,h):o||(l[l.length]=h)}return l}return eC=n,eC}var tC,QL;function efe(){if(QL)return tC;QL=1;function e(t){return function(n,r,i){for(var a=-1,o=Object(n),l=i(n),f=l.length;f--;){var u=l[t?f:++a];if(r(o[u],u,o)===!1)break}return n}}return tC=e,tC}var nC,JL;function tfe(){if(JL)return nC;JL=1;var e=efe(),t=e();return nC=t,nC}var rC,ek;function oz(){if(ek)return rC;ek=1;var e=tfe(),t=u1();function n(r,i){return r&&e(r,i,t)}return rC=n,rC}var iC,tk;function nfe(){if(tk)return iC;tk=1;var e=ug();function t(n,r){return function(i,a){if(i==null)return i;if(!e(i))return n(i,a);for(var o=i.length,l=r?o:-1,f=Object(i);(r?l--:++l<o)&&a(f[l],l,f)!==!1;);return i}}return iC=t,iC}var aC,nk;function w3(){if(nk)return aC;nk=1;var e=oz(),t=nfe(),n=t(e);return aC=n,aC}var oC,rk;function sz(){if(rk)return oC;rk=1;var e=w3(),t=ug();function n(r,i){var a=-1,o=t(r)?Array(r.length):[];return e(r,function(l,f,u){o[++a]=i(l,f,u)}),o}return oC=n,oC}var sC,ik;function rfe(){if(ik)return sC;ik=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return sC=e,sC}var lC,ak;function ife(){if(ak)return lC;ak=1;var e=Dd();function t(n,r){if(n!==r){var i=n!==void 0,a=n===null,o=n===n,l=e(n),f=r!==void 0,u=r===null,h=r===r,m=e(r);if(!u&&!m&&!l&&n>r||l&&f&&h&&!u&&!m||a&&f&&h||!i&&h||!o)return 1;if(!a&&!l&&!m&&n<r||m&&i&&o&&!a&&!l||u&&i&&o||!f&&o||!h)return-1}return 0}return lC=t,lC}var uC,ok;function afe(){if(ok)return uC;ok=1;var e=ife();function t(n,r,i){for(var a=-1,o=n.criteria,l=r.criteria,f=o.length,u=i.length;++a<f;){var h=e(o[a],l[a]);if(h){if(a>=u)return h;var m=i[a];return h*(m=="desc"?-1:1)}}return n.index-r.index}return uC=t,uC}var cC,sk;function ofe(){if(sk)return cC;sk=1;var e=s3(),t=l3(),n=vo(),r=sz(),i=rfe(),a=KU(),o=afe(),l=Bd(),f=ri();function u(h,m,g){m.length?m=e(m,function(b){return f(b)?function(S){return t(S,b.length===1?b[0]:b)}:b}):m=[l];var _=-1;m=e(m,a(n));var x=r(h,function(b,S,C){var A=e(m,function(O){return O(b)});return{criteria:A,index:++_,value:b}});return i(x,function(b,S){return o(b,S,g)})}return cC=u,cC}var fC,lk;function sfe(){if(lk)return fC;lk=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 fC=e,fC}var dC,uk;function lfe(){if(uk)return dC;uk=1;var e=sfe(),t=Math.max;function n(r,i,a){return i=t(i===void 0?r.length-1:i,0),function(){for(var o=arguments,l=-1,f=t(o.length-i,0),u=Array(f);++l<f;)u[l]=o[i+l];l=-1;for(var h=Array(i+1);++l<i;)h[l]=o[l];return h[i]=a(u),e(r,this,h)}}return dC=n,dC}var hC,ck;function ufe(){if(ck)return hC;ck=1;function e(t){return function(){return t}}return hC=e,hC}var pC,fk;function lz(){if(fk)return pC;fk=1;var e=hc(),t=function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch{}}();return pC=t,pC}var mC,dk;function cfe(){if(dk)return mC;dk=1;var e=ufe(),t=lz(),n=Bd(),r=t?function(i,a){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(a),writable:!0})}:n;return mC=r,mC}var gC,hk;function ffe(){if(hk)return gC;hk=1;var e=800,t=16,n=Date.now;function r(i){var a=0,o=0;return function(){var l=n(),f=t-(l-o);if(o=l,f>0){if(++a>=e)return arguments[0]}else a=0;return i.apply(void 0,arguments)}}return gC=r,gC}var vC,pk;function dfe(){if(pk)return vC;pk=1;var e=cfe(),t=ffe(),n=t(e);return vC=n,vC}var yC,mk;function hfe(){if(mk)return yC;mk=1;var e=Bd(),t=lfe(),n=dfe();function r(i,a){return n(t(i,a,e),i+"")}return yC=r,yC}var bC,gk;function f1(){if(gk)return bC;gk=1;var e=i3(),t=ug(),n=v3(),r=Wl();function i(a,o,l){if(!r(l))return!1;var f=typeof o;return(f=="number"?t(l)&&n(o,l.length):f=="string"&&o in l)?e(l[o],a):!1}return bC=i,bC}var wC,vk;function pfe(){if(vk)return wC;vk=1;var e=az(),t=ofe(),n=hfe(),r=f1(),i=n(function(a,o){if(a==null)return[];var l=o.length;return l>1&&r(a,o[0],o[1])?o=[]:l>2&&r(o[0],o[1],o[2])&&(o=[o[0]]),t(a,e(o,1),[])});return wC=i,wC}var mfe=pfe();const _3=zt(mfe);function sm(e){"@babel/helpers - typeof";return sm=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},sm(e)}function kE(){return kE=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},kE.apply(this,arguments)}function gfe(e,t){return wfe(e)||bfe(e,t)||yfe(e,t)||vfe()}function vfe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function yfe(e,t){if(e){if(typeof e=="string")return yk(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 yk(e,t)}}function yk(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 bfe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function wfe(e){if(Array.isArray(e))return 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 _C(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){_fe(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 _fe(e,t,n){return t=xfe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xfe(e){var t=Sfe(e,"string");return sm(t)=="symbol"?t:t+""}function Sfe(e,t){if(sm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(sm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Cfe(e){return Array.isArray(e)&&Kn(e[0])&&Kn(e[1])?e.join(" ~ "):e}var Afe=function(t){var n=t.separator,r=n===void 0?" : ":n,i=t.contentStyle,a=i===void 0?{}:i,o=t.itemStyle,l=o===void 0?{}:o,f=t.labelStyle,u=f===void 0?{}:f,h=t.payload,m=t.formatter,g=t.itemSorter,_=t.wrapperClassName,x=t.labelClassName,b=t.label,S=t.labelFormatter,C=t.accessibilityLayer,A=C===void 0?!1:C,O=function(){if(h&&h.length){var ee={padding:0,margin:0},ie=(g?_3(h,g):h).map(function(X,ne){if(X.type==="none")return null;var H=_C({display:"block",paddingTop:4,paddingBottom:4,color:X.color||"#000"},l),I=X.formatter||m||Cfe,D=X.value,z=X.name,N=D,B=z;if(I&&N!=null&&B!=null){var Q=I(D,z,X,ne,h);if(Array.isArray(Q)){var G=gfe(Q,2);N=G[0],B=G[1]}else N=Q}return pe.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(ne),style:H},Kn(B)?pe.createElement("span",{className:"recharts-tooltip-item-name"},B):null,Kn(B)?pe.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,pe.createElement("span",{className:"recharts-tooltip-item-value"},N),pe.createElement("span",{className:"recharts-tooltip-item-unit"},X.unit||""))});return pe.createElement("ul",{className:"recharts-tooltip-item-list",style:ee},ie)}return null},P=_C({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},a),j=_C({margin:0},u),R=!pt(b),U=R?b:"",V=be("recharts-default-tooltip",_),Y=be("recharts-tooltip-label",x);R&&S&&h!==void 0&&h!==null&&(U=S(b,h));var K=A?{role:"status","aria-live":"assertive"}:{};return pe.createElement("div",kE({className:V,style:P},K),pe.createElement("p",{className:Y,style:j},pe.isValidElement(U)?U:"".concat(U)),O())};function lm(e){"@babel/helpers - typeof";return lm=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},lm(e)}function ny(e,t,n){return t=Efe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Efe(e){var t=Ofe(e,"string");return lm(t)=="symbol"?t:t+""}function Ofe(e,t){if(lm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var op="recharts-tooltip-wrapper",Tfe={visibility:"hidden"};function jfe(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return be(op,ny(ny(ny(ny({},"".concat(op,"-right"),Ze(n)&&t&&Ze(t.x)&&n>=t.x),"".concat(op,"-left"),Ze(n)&&t&&Ze(t.x)&&n<t.x),"".concat(op,"-bottom"),Ze(r)&&t&&Ze(t.y)&&r>=t.y),"".concat(op,"-top"),Ze(r)&&t&&Ze(t.y)&&r<t.y))}function wk(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,i=e.offsetTopLeft,a=e.position,o=e.reverseDirection,l=e.tooltipDimension,f=e.viewBox,u=e.viewBoxDimension;if(a&&Ze(a[r]))return a[r];var h=n[r]-l-i,m=n[r]+i;if(t[r])return o[r]?h:m;if(o[r]){var g=h,_=f[r];return g<_?Math.max(m,f[r]):Math.max(h,f[r])}var x=m+l,b=f[r]+u;return x>b?Math.max(h,f[r]):Math.max(m,f[r])}function Pfe(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 Rfe(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,a=e.reverseDirection,o=e.tooltipBox,l=e.useTranslate3d,f=e.viewBox,u,h,m;return o.height>0&&o.width>0&&n?(h=wk({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:i,reverseDirection:a,tooltipDimension:o.width,viewBox:f,viewBoxDimension:f.width}),m=wk({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:i,reverseDirection:a,tooltipDimension:o.height,viewBox:f,viewBoxDimension:f.height}),u=Pfe({translateX:h,translateY:m,useTranslate3d:l})):u=Tfe,{cssProperties:u,cssClasses:jfe({translateX:h,translateY:m,coordinate:n})}}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 _k(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 xk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_k(Object(n),!0).forEach(function(r){IE(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_k(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 Nfe(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,cz(r.key),r)}}function Lfe(e,t,n){return t&&Nfe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function kfe(e,t,n){return t=b0(t),Dfe(e,uz()?Reflect.construct(t,n||[],b0(e).constructor):t.apply(e,n))}function Dfe(e,t){if(t&&(Xf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ife(e)}function Ife(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uz(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(uz=function(){return!!e})()}function b0(e){return b0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},b0(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&&DE(e,t)}function DE(e,t){return DE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},DE(e,t)}function IE(e,t,n){return t=cz(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cz(e){var t=Bfe(e,"string");return Xf(t)=="symbol"?t:t+""}function Bfe(e,t){if(Xf(e)!="object"||!e)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 String(e)}var Sk=1,Ufe=function(e){function t(){var n;Mfe(this,t);for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];return n=kfe(this,t,[].concat(i)),IE(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),IE(n,"handleKeyDown",function(o){if(o.key==="Escape"){var l,f,u,h;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(l=(f=n.props.coordinate)===null||f===void 0?void 0:f.x)!==null&&l!==void 0?l:0,y:(u=(h=n.props.coordinate)===null||h===void 0?void 0:h.y)!==null&&u!==void 0?u:0}})}}),n}return $fe(t,e),Lfe(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>Sk||Math.abs(r.height-this.state.lastBoundingBox.height)>Sk)&&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,a=i.active,o=i.allowEscapeViewBox,l=i.animationDuration,f=i.animationEasing,u=i.children,h=i.coordinate,m=i.hasPayload,g=i.isAnimationActive,_=i.offset,x=i.position,b=i.reverseDirection,S=i.useTranslate3d,C=i.viewBox,A=i.wrapperStyle,O=Rfe({allowEscapeViewBox:o,coordinate:h,offsetTopLeft:_,position:x,reverseDirection:b,tooltipBox:this.state.lastBoundingBox,useTranslate3d:S,viewBox:C}),P=O.cssClasses,j=O.cssProperties,R=xk(xk({transition:g&&a?"transform ".concat(l,"ms ").concat(f):void 0},j),{},{pointerEvents:"none",visibility:!this.state.dismissed&&a&&m?"visible":"hidden",position:"absolute",top:0,left:0},A);return pe.createElement("div",{tabIndex:-1,className:P,style:R,ref:function(V){r.wrapperNode=V}},u)}}])}(M.PureComponent),zfe=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},ms={isSsr:zfe()};function Qf(e){"@babel/helpers - typeof";return Qf=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},Qf(e)}function Ck(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 Ak(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ck(Object(n),!0).forEach(function(r){x3(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ck(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ffe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qfe(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,dz(r.key),r)}}function Vfe(e,t,n){return t&&qfe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Hfe(e,t,n){return t=w0(t),Gfe(e,fz()?Reflect.construct(t,n||[],w0(e).constructor):t.apply(e,n))}function Gfe(e,t){if(t&&(Qf(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Wfe(e)}function Wfe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fz(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(fz=function(){return!!e})()}function w0(e){return w0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},w0(e)}function Yfe(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&&$E(e,t)}function $E(e,t){return $E=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},$E(e,t)}function x3(e,t,n){return t=dz(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dz(e){var t=Kfe(e,"string");return Qf(t)=="symbol"?t:t+""}function Kfe(e,t){if(Qf(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Qf(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Zfe(e){return e.dataKey}function Xfe(e,t){return pe.isValidElement(e)?pe.cloneElement(e,t):typeof e=="function"?pe.createElement(e,t):pe.createElement(Afe,t)}var Xi=function(e){function t(){return Ffe(this,t),Hfe(this,t,arguments)}return Yfe(t,e),Vfe(t,[{key:"render",value:function(){var r=this,i=this.props,a=i.active,o=i.allowEscapeViewBox,l=i.animationDuration,f=i.animationEasing,u=i.content,h=i.coordinate,m=i.filterNull,g=i.isAnimationActive,_=i.offset,x=i.payload,b=i.payloadUniqBy,S=i.position,C=i.reverseDirection,A=i.useTranslate3d,O=i.viewBox,P=i.wrapperStyle,j=x??[];m&&j.length&&(j=nz(x.filter(function(U){return U.value!=null&&(U.hide!==!0||r.props.includeHidden)}),b,Zfe));var R=j.length>0;return pe.createElement(Ufe,{allowEscapeViewBox:o,animationDuration:l,animationEasing:f,isAnimationActive:g,active:a,coordinate:h,hasPayload:R,offset:_,position:S,reverseDirection:C,useTranslate3d:A,viewBox:O,wrapperStyle:P},Xfe(u,Ak(Ak({},this.props),{},{payload:j})))}}])}(M.PureComponent);x3(Xi,"displayName","Tooltip");x3(Xi,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!ms.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 xC,Ek;function Qfe(){if(Ek)return xC;Ek=1;var e=go(),t=function(){return e.Date.now()};return xC=t,xC}var SC,Ok;function Jfe(){if(Ok)return SC;Ok=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return SC=t,SC}var CC,Tk;function ede(){if(Tk)return CC;Tk=1;var e=Jfe(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return CC=n,CC}var AC,jk;function hz(){if(jk)return AC;jk=1;var e=ede(),t=Wl(),n=Dd(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,o=/^0o[0-7]+$/i,l=parseInt;function f(u){if(typeof u=="number")return u;if(n(u))return r;if(t(u)){var h=typeof u.valueOf=="function"?u.valueOf():u;u=t(h)?h+"":h}if(typeof u!="string")return u===0?u:+u;u=e(u);var m=a.test(u);return m||o.test(u)?l(u.slice(2),m?2:8):i.test(u)?r:+u}return AC=f,AC}var EC,Pk;function tde(){if(Pk)return EC;Pk=1;var e=Wl(),t=Qfe(),n=hz(),r="Expected a function",i=Math.max,a=Math.min;function o(l,f,u){var h,m,g,_,x,b,S=0,C=!1,A=!1,O=!0;if(typeof l!="function")throw new TypeError(r);f=n(f)||0,e(u)&&(C=!!u.leading,A="maxWait"in u,g=A?i(n(u.maxWait)||0,f):g,O="trailing"in u?!!u.trailing:O);function P(ie){var X=h,ne=m;return h=m=void 0,S=ie,_=l.apply(ne,X),_}function j(ie){return S=ie,x=setTimeout(V,f),C?P(ie):_}function R(ie){var X=ie-b,ne=ie-S,H=f-X;return A?a(H,g-ne):H}function U(ie){var X=ie-b,ne=ie-S;return b===void 0||X>=f||X<0||A&&ne>=g}function V(){var ie=t();if(U(ie))return Y(ie);x=setTimeout(V,R(ie))}function Y(ie){return x=void 0,O&&h?P(ie):(h=m=void 0,_)}function K(){x!==void 0&&clearTimeout(x),S=0,h=b=m=x=void 0}function W(){return x===void 0?_:Y(t())}function ee(){var ie=t(),X=U(ie);if(h=arguments,m=this,b=ie,X){if(x===void 0)return j(b);if(A)return clearTimeout(x),x=setTimeout(V,f),P(b)}return x===void 0&&(x=setTimeout(V,f)),_}return ee.cancel=K,ee.flush=W,ee}return EC=o,EC}var OC,Rk;function nde(){if(Rk)return OC;Rk=1;var e=tde(),t=Wl(),n="Expected a function";function r(i,a,o){var l=!0,f=!0;if(typeof i!="function")throw new TypeError(n);return t(o)&&(l="leading"in o?!!o.leading:l,f="trailing"in o?!!o.trailing:f),e(i,a,{leading:l,maxWait:a,trailing:f})}return OC=r,OC}var rde=nde();const pz=zt(rde);function um(e){"@babel/helpers - typeof";return um=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},um(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 ry(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){ide(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 ide(e,t,n){return t=ade(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ade(e){var t=ode(e,"string");return um(t)=="symbol"?t:t+""}function ode(e,t){if(um(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(um(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function sde(e,t){return fde(e)||cde(e,t)||ude(e,t)||lde()}function lde(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ude(e,t){if(e){if(typeof e=="string")return Nk(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 Nk(e,t)}}function Nk(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 cde(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function fde(e){if(Array.isArray(e))return e}var dde=M.forwardRef(function(e,t){var n=e.aspect,r=e.initialDimension,i=r===void 0?{width:-1,height:-1}:r,a=e.width,o=a===void 0?"100%":a,l=e.height,f=l===void 0?"100%":l,u=e.minWidth,h=u===void 0?0:u,m=e.minHeight,g=e.maxHeight,_=e.children,x=e.debounce,b=x===void 0?0:x,S=e.id,C=e.className,A=e.onResize,O=e.style,P=O===void 0?{}:O,j=M.useRef(null),R=M.useRef();R.current=A,M.useImperativeHandle(t,function(){return Object.defineProperty(j.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),j.current},configurable:!0})});var U=M.useState({containerWidth:i.width,containerHeight:i.height}),V=sde(U,2),Y=V[0],K=V[1],W=M.useCallback(function(ie,X){K(function(ne){var H=Math.round(ie),I=Math.round(X);return ne.containerWidth===H&&ne.containerHeight===I?ne:{containerWidth:H,containerHeight:I}})},[]);M.useEffect(function(){var ie=function(z){var N,B=z[0].contentRect,Q=B.width,G=B.height;W(Q,G),(N=R.current)===null||N===void 0||N.call(R,Q,G)};b>0&&(ie=pz(ie,b,{trailing:!0,leading:!1}));var X=new ResizeObserver(ie),ne=j.current.getBoundingClientRect(),H=ne.width,I=ne.height;return W(H,I),X.observe(j.current),function(){X.disconnect()}},[W,b]);var ee=M.useMemo(function(){var ie=Y.containerWidth,X=Y.containerHeight;if(ie<0||X<0)return null;_a(Fu(o)||Fu(f),`The width(%s) and height(%s) are both fixed numbers,
|
||
maybe you don't need to use a ResponsiveContainer.`,o,f),_a(!n||n>0,"The aspect(%s) must be greater than zero.",n);var ne=Fu(o)?ie:o,H=Fu(f)?X:f;n&&n>0&&(ne?H=ne/n:H&&(ne=H*n),g&&H>g&&(H=g)),_a(ne>0||H>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
||
please check the style of container, or the props width(%s) and height(%s),
|
||
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
||
height and width.`,ne,H,o,f,h,m,n);var I=!Array.isArray(_)&&Jo(_.type).endsWith("Chart");return pe.Children.map(_,function(D){return pe.isValidElement(D)?M.cloneElement(D,ry({width:ne,height:H},I?{style:ry({height:"100%",width:"100%",maxHeight:H,maxWidth:ne},D.props.style)}:{})):D})},[n,_,f,g,m,h,Y,o]);return pe.createElement("div",{id:S?"".concat(S):void 0,className:be("recharts-responsive-container",C),style:ry(ry({},P),{},{width:o,height:f,minWidth:h,minHeight:m,maxHeight:g}),ref:j},ee)}),Cl=function(t){return null};Cl.displayName="Cell";function cm(e){"@babel/helpers - typeof";return cm=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},cm(e)}function Lk(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 BE(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Lk(Object(n),!0).forEach(function(r){hde(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lk(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hde(e,t,n){return t=pde(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pde(e){var t=mde(e,"string");return cm(t)=="symbol"?t:t+""}function mde(e,t){if(cm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var pf={widthCache:{},cacheCount:0},gde=2e3,vde={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},kk="recharts_measurement_span";function yde(e){var t=BE({},e);return Object.keys(t).forEach(function(n){t[n]||delete t[n]}),t}var Lp=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||ms.isSsr)return{width:0,height:0};var r=yde(n),i=JSON.stringify({text:t,copyStyle:r});if(pf.widthCache[i])return pf.widthCache[i];try{var a=document.getElementById(kk);a||(a=document.createElement("span"),a.setAttribute("id",kk),a.setAttribute("aria-hidden","true"),document.body.appendChild(a));var o=BE(BE({},vde),r);Object.assign(a.style,o),a.textContent="".concat(t);var l=a.getBoundingClientRect(),f={width:l.width,height:l.height};return pf.widthCache[i]=f,++pf.cacheCount>gde&&(pf.cacheCount=0,pf.widthCache={}),f}catch{return{width:0,height:0}}},bde=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function fm(e){"@babel/helpers - typeof";return fm=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},fm(e)}function _0(e,t){return Sde(e)||xde(e,t)||_de(e,t)||wde()}function wde(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _de(e,t){if(e){if(typeof e=="string")return Dk(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 Dk(e,t)}}function Dk(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 xde(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;f=!1}else for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function Sde(e){if(Array.isArray(e))return e}function Cde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ik(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,Ede(r.key),r)}}function Ade(e,t,n){return t&&Ik(e.prototype,t),n&&Ik(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ede(e){var t=Ode(e,"string");return fm(t)=="symbol"?t:t+""}function Ode(e,t){if(fm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(fm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var $k=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Bk=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Tde=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,jde=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,mz={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},Pde=Object.keys(mz),Cf="NaN";function Rde(e,t){return e*mz[t]}var iy=function(){function e(t,n){Cde(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=""),n!==""&&!Tde.test(n)&&(this.num=NaN,this.unit=""),Pde.includes(n)&&(this.num=Rde(t,n),this.unit="px")}return Ade(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=jde.exec(n))!==null&&r!==void 0?r:[],a=_0(i,3),o=a[1],l=a[2];return new e(parseFloat(o),l??"")}}])}();function gz(e){if(e.includes(Cf))return Cf;for(var t=e;t.includes("*")||t.includes("/");){var n,r=(n=$k.exec(t))!==null&&n!==void 0?n:[],i=_0(r,4),a=i[1],o=i[2],l=i[3],f=iy.parse(a??""),u=iy.parse(l??""),h=o==="*"?f.multiply(u):f.divide(u);if(h.isNaN())return Cf;t=t.replace($k,h.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var m,g=(m=Bk.exec(t))!==null&&m!==void 0?m:[],_=_0(g,4),x=_[1],b=_[2],S=_[3],C=iy.parse(x??""),A=iy.parse(S??""),O=b==="+"?C.add(A):C.subtract(A);if(O.isNaN())return Cf;t=t.replace(Bk,O.toString())}return t}var Uk=/\(([^()]*)\)/;function Mde(e){for(var t=e;t.includes("(");){var n=Uk.exec(t),r=_0(n,2),i=r[1];t=t.replace(Uk,gz(i))}return t}function Nde(e){var t=e.replace(/\s+/g,"");return t=Mde(t),t=gz(t),t}function Lde(e){try{return Nde(e)}catch{return Cf}}function TC(e){var t=Lde(e.slice(5,-1));return t===Cf?"":t}var kde=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],Dde=["dx","dy","angle","className","breakAll"];function UE(){return UE=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},UE.apply(this,arguments)}function zk(e,t){if(e==null)return{};var n=Ide(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Ide(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 Fk(e,t){return zde(e)||Ude(e,t)||Bde(e,t)||$de()}function $de(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Bde(e,t){if(e){if(typeof e=="string")return qk(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 qk(e,t)}}function qk(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 Ude(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;f=!1}else for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function zde(e){if(Array.isArray(e))return e}var vz=/[ \f\n\r\t\v\u2028\u2029]+/,yz=function(t){var n=t.children,r=t.breakAll,i=t.style;try{var a=[];pt(n)||(r?a=n.toString().split(""):a=n.toString().split(vz));var o=a.map(function(f){return{word:f,width:Lp(f,i).width}}),l=r?0:Lp(" ",i).width;return{wordsWithComputedWidth:o,spaceWidth:l}}catch{return null}},Fde=function(t,n,r,i,a){var o=t.maxLines,l=t.children,f=t.style,u=t.breakAll,h=Ze(o),m=l,g=function(){var ne=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return ne.reduce(function(H,I){var D=I.word,z=I.width,N=H[H.length-1];if(N&&(i==null||a||N.width+z+r<Number(i)))N.words.push(D),N.width+=z+r;else{var B={words:[D],width:z};H.push(B)}return H},[])},_=g(n),x=function(ne){return ne.reduce(function(H,I){return H.width>I.width?H:I})};if(!h)return _;for(var b="…",S=function(ne){var H=m.slice(0,ne),I=yz({breakAll:u,style:f,children:H+b}).wordsWithComputedWidth,D=g(I),z=D.length>o||x(D).width>Number(i);return[z,D]},C=0,A=m.length-1,O=0,P;C<=A&&O<=m.length-1;){var j=Math.floor((C+A)/2),R=j-1,U=S(R),V=Fk(U,2),Y=V[0],K=V[1],W=S(j),ee=Fk(W,1),ie=ee[0];if(!Y&&!ie&&(C=j+1),Y&&ie&&(A=j-1),!Y&&ie){P=K;break}O++}return P||_},Vk=function(t){var n=pt(t)?[]:t.toString().split(vz);return[{words:n}]},qde=function(t){var n=t.width,r=t.scaleToFit,i=t.children,a=t.style,o=t.breakAll,l=t.maxLines;if((n||r)&&!ms.isSsr){var f,u,h=yz({breakAll:o,children:i,style:a});if(h){var m=h.wordsWithComputedWidth,g=h.spaceWidth;f=m,u=g}else return Vk(i);return Fde({breakAll:o,children:i,maxLines:l,style:a},f,u,n,r)}return Vk(i)},Hk="#808080",ac=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,a=i===void 0?0:i,o=t.lineHeight,l=o===void 0?"1em":o,f=t.capHeight,u=f===void 0?"0.71em":f,h=t.scaleToFit,m=h===void 0?!1:h,g=t.textAnchor,_=g===void 0?"start":g,x=t.verticalAnchor,b=x===void 0?"end":x,S=t.fill,C=S===void 0?Hk:S,A=zk(t,kde),O=M.useMemo(function(){return qde({breakAll:A.breakAll,children:A.children,maxLines:A.maxLines,scaleToFit:m,style:A.style,width:A.width})},[A.breakAll,A.children,A.maxLines,m,A.style,A.width]),P=A.dx,j=A.dy,R=A.angle,U=A.className,V=A.breakAll,Y=zk(A,Dde);if(!Kn(r)||!Kn(a))return null;var K=r+(Ze(P)?P:0),W=a+(Ze(j)?j:0),ee;switch(b){case"start":ee=TC("calc(".concat(u,")"));break;case"middle":ee=TC("calc(".concat((O.length-1)/2," * -").concat(l," + (").concat(u," / 2))"));break;default:ee=TC("calc(".concat(O.length-1," * -").concat(l,")"));break}var ie=[];if(m){var X=O[0].width,ne=A.width;ie.push("scale(".concat((Ze(ne)?ne/X:1)/X,")"))}return R&&ie.push("rotate(".concat(R,", ").concat(K,", ").concat(W,")")),ie.length&&(Y.transform=ie.join(" ")),pe.createElement("text",UE({},ot(Y,!0),{x:K,y:W,className:be("recharts-text",U),textAnchor:_,fill:C.includes("url")?Hk:C}),O.map(function(H,I){var D=H.words.join(V?"":" ");return pe.createElement("tspan",{x:K,dy:I===0?ee:l,key:"".concat(D,"-").concat(I)},D)}))};function Al(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Vde(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function S3(e){let t,n,r;e.length!==2?(t=Al,n=(l,f)=>Al(e(l),f),r=(l,f)=>e(l)-f):(t=e===Al||e===Vde?e:Hde,n=e,r=e);function i(l,f,u=0,h=l.length){if(u<h){if(t(f,f)!==0)return h;do{const m=u+h>>>1;n(l[m],f)<0?u=m+1:h=m}while(u<h)}return u}function a(l,f,u=0,h=l.length){if(u<h){if(t(f,f)!==0)return h;do{const m=u+h>>>1;n(l[m],f)<=0?u=m+1:h=m}while(u<h)}return u}function o(l,f,u=0,h=l.length){const m=i(l,f,u,h-1);return m>u&&r(l[m-1],f)>-r(l[m],f)?m-1:m}return{left:i,center:o,right:a}}function Hde(){return 0}function bz(e){return e===null?NaN:+e}function*Gde(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const Wde=S3(Al),cg=Wde.right;S3(bz).center;class Gk extends Map{constructor(t,n=Zde){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(Wk(this,t))}has(t){return super.has(Wk(this,t))}set(t,n){return super.set(Yde(this,t),n)}delete(t){return super.delete(Kde(this,t))}}function Wk({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function Yde({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function Kde({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function Zde(e){return e!==null&&typeof e=="object"?e.valueOf():e}function Xde(e=Al){if(e===Al)return wz;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 wz(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const Qde=Math.sqrt(50),Jde=Math.sqrt(10),ehe=Math.sqrt(2);function x0(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),a=r/Math.pow(10,i),o=a>=Qde?10:a>=Jde?5:a>=ehe?2:1;let l,f,u;return i<0?(u=Math.pow(10,-i)/o,l=Math.round(e*u),f=Math.round(t*u),l/u<e&&++l,f/u>t&&--f,u=-u):(u=Math.pow(10,i)*o,l=Math.round(e/u),f=Math.round(t/u),l*u<e&&++l,f*u>t&&--f),f<l&&.5<=n&&n<2?x0(e,t,n*2):[l,f,u]}function zE(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,a,o]=r?x0(t,e,n):x0(e,t,n);if(!(a>=i))return[];const l=a-i+1,f=new Array(l);if(r)if(o<0)for(let u=0;u<l;++u)f[u]=(a-u)/-o;else for(let u=0;u<l;++u)f[u]=(a-u)*o;else if(o<0)for(let u=0;u<l;++u)f[u]=(i+u)/-o;else for(let u=0;u<l;++u)f[u]=(i+u)*o;return f}function FE(e,t,n){return t=+t,e=+e,n=+n,x0(e,t,n)[2]}function qE(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?FE(t,e,n):FE(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function Yk(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function Kk(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function _z(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?wz:Xde(i);r>n;){if(r-n>600){const f=r-n+1,u=t-n+1,h=Math.log(f),m=.5*Math.exp(2*h/3),g=.5*Math.sqrt(h*m*(f-m)/f)*(u-f/2<0?-1:1),_=Math.max(n,Math.floor(t-u*m/f+g)),x=Math.min(r,Math.floor(t+(f-u)*m/f+g));_z(e,t,_,x,i)}const a=e[t];let o=n,l=r;for(sp(e,n,t),i(e[r],a)>0&&sp(e,n,r);o<l;){for(sp(e,o,l),++o,--l;i(e[o],a)<0;)++o;for(;i(e[l],a)>0;)--l}i(e[n],a)===0?sp(e,n,l):(++l,sp(e,l,r)),l<=t&&(n=l+1),t<=l&&(r=l-1)}return e}function sp(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function the(e,t,n){if(e=Float64Array.from(Gde(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Kk(e);if(t>=1)return Yk(e);var r,i=(r-1)*t,a=Math.floor(i),o=Yk(_z(e,a).subarray(0,a+1)),l=Kk(e.subarray(a+1));return o+(l-o)*(i-a)}}function nhe(e,t,n=bz){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,a=Math.floor(i),o=+n(e[a],a,e),l=+n(e[a+1],a+1,e);return o+(l-o)*(i-a)}}function rhe(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,a=new Array(i);++r<i;)a[r]=e+r*n;return a}function ia(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function gs(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 VE=Symbol("implicit");function C3(){var e=new Gk,t=[],n=[],r=VE;function i(a){let o=e.get(a);if(o===void 0){if(r!==VE)return r;e.set(a,o=t.push(a)-1)}return n[o%n.length]}return i.domain=function(a){if(!arguments.length)return t.slice();t=[],e=new Gk;for(const o of a)e.has(o)||e.set(o,t.push(o)-1);return i},i.range=function(a){return arguments.length?(n=Array.from(a),i):n.slice()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.copy=function(){return C3(t,n).unknown(r)},ia.apply(i,arguments),i}function dm(){var e=C3().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,a,o,l=!1,f=0,u=0,h=.5;delete e.unknown;function m(){var g=t().length,_=i<r,x=_?i:r,b=_?r:i;a=(b-x)/Math.max(1,g-f+u*2),l&&(a=Math.floor(a)),x+=(b-x-a*(g-f))*h,o=a*(1-f),l&&(x=Math.round(x),o=Math.round(o));var S=rhe(g).map(function(C){return x+a*C});return n(_?S.reverse():S)}return e.domain=function(g){return arguments.length?(t(g),m()):t()},e.range=function(g){return arguments.length?([r,i]=g,r=+r,i=+i,m()):[r,i]},e.rangeRound=function(g){return[r,i]=g,r=+r,i=+i,l=!0,m()},e.bandwidth=function(){return o},e.step=function(){return a},e.round=function(g){return arguments.length?(l=!!g,m()):l},e.padding=function(g){return arguments.length?(f=Math.min(1,u=+g),m()):f},e.paddingInner=function(g){return arguments.length?(f=Math.min(1,g),m()):f},e.paddingOuter=function(g){return arguments.length?(u=+g,m()):u},e.align=function(g){return arguments.length?(h=Math.max(0,Math.min(1,g)),m()):h},e.copy=function(){return dm(t(),[r,i]).round(l).paddingInner(f).paddingOuter(u).align(h)},ia.apply(m(),arguments)}function xz(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return xz(t())},e}function kp(){return xz(dm.apply(null,arguments).paddingInner(1))}function A3(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Sz(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function fg(){}var hm=.7,S0=1/hm,If="\\s*([+-]?\\d+)\\s*",pm="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ao="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",ihe=/^#([0-9a-f]{3,8})$/,ahe=new RegExp(`^rgb\\(${If},${If},${If}\\)$`),ohe=new RegExp(`^rgb\\(${ao},${ao},${ao}\\)$`),she=new RegExp(`^rgba\\(${If},${If},${If},${pm}\\)$`),lhe=new RegExp(`^rgba\\(${ao},${ao},${ao},${pm}\\)$`),uhe=new RegExp(`^hsl\\(${pm},${ao},${ao}\\)$`),che=new RegExp(`^hsla\\(${pm},${ao},${ao},${pm}\\)$`),Zk={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};A3(fg,mm,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Xk,formatHex:Xk,formatHex8:fhe,formatHsl:dhe,formatRgb:Qk,toString:Qk});function Xk(){return this.rgb().formatHex()}function fhe(){return this.rgb().formatHex8()}function dhe(){return Cz(this).formatHsl()}function Qk(){return this.rgb().formatRgb()}function mm(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=ihe.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Jk(t):n===3?new ni(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?ay(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?ay(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=ahe.exec(e))?new ni(t[1],t[2],t[3],1):(t=ohe.exec(e))?new ni(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=she.exec(e))?ay(t[1],t[2],t[3],t[4]):(t=lhe.exec(e))?ay(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=uhe.exec(e))?nD(t[1],t[2]/100,t[3]/100,1):(t=che.exec(e))?nD(t[1],t[2]/100,t[3]/100,t[4]):Zk.hasOwnProperty(e)?Jk(Zk[e]):e==="transparent"?new ni(NaN,NaN,NaN,0):null}function Jk(e){return new ni(e>>16&255,e>>8&255,e&255,1)}function ay(e,t,n,r){return r<=0&&(e=t=n=NaN),new ni(e,t,n,r)}function hhe(e){return e instanceof fg||(e=mm(e)),e?(e=e.rgb(),new ni(e.r,e.g,e.b,e.opacity)):new ni}function HE(e,t,n,r){return arguments.length===1?hhe(e):new ni(e,t,n,r??1)}function ni(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}A3(ni,HE,Sz(fg,{brighter(e){return e=e==null?S0:Math.pow(S0,e),new ni(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?hm:Math.pow(hm,e),new ni(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ni(Wu(this.r),Wu(this.g),Wu(this.b),C0(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:eD,formatHex:eD,formatHex8:phe,formatRgb:tD,toString:tD}));function eD(){return`#${qu(this.r)}${qu(this.g)}${qu(this.b)}`}function phe(){return`#${qu(this.r)}${qu(this.g)}${qu(this.b)}${qu((isNaN(this.opacity)?1:this.opacity)*255)}`}function tD(){const e=C0(this.opacity);return`${e===1?"rgb(":"rgba("}${Wu(this.r)}, ${Wu(this.g)}, ${Wu(this.b)}${e===1?")":`, ${e})`}`}function C0(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Wu(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function qu(e){return e=Wu(e),(e<16?"0":"")+e.toString(16)}function nD(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new wa(e,t,n,r)}function Cz(e){if(e instanceof wa)return new wa(e.h,e.s,e.l,e.opacity);if(e instanceof fg||(e=mm(e)),!e)return new wa;if(e instanceof wa)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=NaN,l=a-i,f=(a+i)/2;return l?(t===a?o=(n-r)/l+(n<r)*6:n===a?o=(r-t)/l+2:o=(t-n)/l+4,l/=f<.5?a+i:2-a-i,o*=60):l=f>0&&f<1?0:o,new wa(o,l,f,e.opacity)}function mhe(e,t,n,r){return arguments.length===1?Cz(e):new wa(e,t,n,r??1)}function wa(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}A3(wa,mhe,Sz(fg,{brighter(e){return e=e==null?S0:Math.pow(S0,e),new wa(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?hm:Math.pow(hm,e),new wa(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 ni(jC(e>=240?e-240:e+120,i,r),jC(e,i,r),jC(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new wa(rD(this.h),oy(this.s),oy(this.l),C0(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=C0(this.opacity);return`${e===1?"hsl(":"hsla("}${rD(this.h)}, ${oy(this.s)*100}%, ${oy(this.l)*100}%${e===1?")":`, ${e})`}`}}));function rD(e){return e=(e||0)%360,e<0?e+360:e}function oy(e){return Math.max(0,Math.min(1,e||0))}function jC(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 E3=e=>()=>e;function ghe(e,t){return function(n){return e+n*t}}function vhe(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 yhe(e){return(e=+e)==1?Az:function(t,n){return n-t?vhe(t,n,e):E3(isNaN(t)?n:t)}}function Az(e,t){var n=t-e;return n?ghe(e,n):E3(isNaN(e)?t:e)}const iD=function e(t){var n=yhe(t);function r(i,a){var o=n((i=HE(i)).r,(a=HE(a)).r),l=n(i.g,a.g),f=n(i.b,a.b),u=Az(i.opacity,a.opacity);return function(h){return i.r=o(h),i.g=l(h),i.b=f(h),i.opacity=u(h),i+""}}return r.gamma=e,r}(1);function bhe(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(a){for(i=0;i<n;++i)r[i]=e[i]*(1-a)+t[i]*a;return r}}function whe(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function _he(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),a=new Array(n),o;for(o=0;o<r;++o)i[o]=Ud(e[o],t[o]);for(;o<n;++o)a[o]=t[o];return function(l){for(o=0;o<r;++o)a[o]=i[o](l);return a}}function xhe(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function A0(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function She(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]=Ud(e[i],t[i]):r[i]=t[i];return function(a){for(i in n)r[i]=n[i](a);return r}}var GE=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,PC=new RegExp(GE.source,"g");function Che(e){return function(){return e}}function Ahe(e){return function(t){return e(t)+""}}function Ehe(e,t){var n=GE.lastIndex=PC.lastIndex=0,r,i,a,o=-1,l=[],f=[];for(e=e+"",t=t+"";(r=GE.exec(e))&&(i=PC.exec(t));)(a=i.index)>n&&(a=t.slice(n,a),l[o]?l[o]+=a:l[++o]=a),(r=r[0])===(i=i[0])?l[o]?l[o]+=i:l[++o]=i:(l[++o]=null,f.push({i:o,x:A0(r,i)})),n=PC.lastIndex;return n<t.length&&(a=t.slice(n),l[o]?l[o]+=a:l[++o]=a),l.length<2?f[0]?Ahe(f[0].x):Che(t):(t=f.length,function(u){for(var h=0,m;h<t;++h)l[(m=f[h]).i]=m.x(u);return l.join("")})}function Ud(e,t){var n=typeof t,r;return t==null||n==="boolean"?E3(t):(n==="number"?A0:n==="string"?(r=mm(t))?(t=r,iD):Ehe:t instanceof mm?iD:t instanceof Date?xhe:whe(t)?bhe:Array.isArray(t)?_he:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?She:A0)(e,t)}function O3(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function Ohe(e,t){t===void 0&&(t=e,e=Ud);for(var n=0,r=t.length-1,i=t[0],a=new Array(r<0?0:r);n<r;)a[n]=e(i,i=t[++n]);return function(o){var l=Math.max(0,Math.min(r-1,Math.floor(o*=r)));return a[l](o-l)}}function The(e){return function(){return e}}function E0(e){return+e}var aD=[0,1];function Vr(e){return e}function WE(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:The(isNaN(t)?NaN:.5)}function jhe(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function Phe(e,t,n){var r=e[0],i=e[1],a=t[0],o=t[1];return i<r?(r=WE(i,r),a=n(o,a)):(r=WE(r,i),a=n(a,o)),function(l){return a(r(l))}}function Rhe(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),a=new Array(r),o=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<r;)i[o]=WE(e[o],e[o+1]),a[o]=n(t[o],t[o+1]);return function(l){var f=cg(e,l,1,r)-1;return a[f](i[f](l))}}function dg(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function d1(){var e=aD,t=aD,n=Ud,r,i,a,o=Vr,l,f,u;function h(){var g=Math.min(e.length,t.length);return o!==Vr&&(o=jhe(e[0],e[g-1])),l=g>2?Rhe:Phe,f=u=null,m}function m(g){return g==null||isNaN(g=+g)?a:(f||(f=l(e.map(r),t,n)))(r(o(g)))}return m.invert=function(g){return o(i((u||(u=l(t,e.map(r),A0)))(g)))},m.domain=function(g){return arguments.length?(e=Array.from(g,E0),h()):e.slice()},m.range=function(g){return arguments.length?(t=Array.from(g),h()):t.slice()},m.rangeRound=function(g){return t=Array.from(g),n=O3,h()},m.clamp=function(g){return arguments.length?(o=g?!0:Vr,h()):o!==Vr},m.interpolate=function(g){return arguments.length?(n=g,h()):n},m.unknown=function(g){return arguments.length?(a=g,m):a},function(g,_){return r=g,i=_,h()}}function T3(){return d1()(Vr,Vr)}function Mhe(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function O0(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 Jf(e){return e=O0(Math.abs(e)),e?e[1]:NaN}function Nhe(e,t){return function(n,r){for(var i=n.length,a=[],o=0,l=e[0],f=0;i>0&&l>0&&(f+l+1>r&&(l=Math.max(1,r-f)),a.push(n.substring(i-=l,i+l)),!((f+=l+1)>r));)l=e[o=(o+1)%e.length];return a.reverse().join(t)}}function Lhe(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var khe=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function gm(e){if(!(t=khe.exec(e)))throw new Error("invalid format: "+e);var t;return new j3({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]})}gm.prototype=j3.prototype;function j3(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+""}j3.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 Dhe(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 Ez;function Ihe(e,t){var n=O0(e,t);if(!n)return e+"";var r=n[0],i=n[1],a=i-(Ez=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=r.length;return a===o?r:a>o?r+new Array(a-o+1).join("0"):a>0?r.slice(0,a)+"."+r.slice(a):"0."+new Array(1-a).join("0")+O0(e,Math.max(0,t+a-1))[0]}function oD(e,t){var n=O0(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 sD={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:Mhe,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)=>oD(e*100,t),r:oD,s:Ihe,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function lD(e){return e}var uD=Array.prototype.map,cD=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function $he(e){var t=e.grouping===void 0||e.thousands===void 0?lD:Nhe(uD.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+"",a=e.numerals===void 0?lD:Lhe(uD.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",l=e.minus===void 0?"−":e.minus+"",f=e.nan===void 0?"NaN":e.nan+"";function u(m){m=gm(m);var g=m.fill,_=m.align,x=m.sign,b=m.symbol,S=m.zero,C=m.width,A=m.comma,O=m.precision,P=m.trim,j=m.type;j==="n"?(A=!0,j="g"):sD[j]||(O===void 0&&(O=12),P=!0,j="g"),(S||g==="0"&&_==="=")&&(S=!0,g="0",_="=");var R=b==="$"?n:b==="#"&&/[boxX]/.test(j)?"0"+j.toLowerCase():"",U=b==="$"?r:/[%p]/.test(j)?o:"",V=sD[j],Y=/[defgprs%]/.test(j);O=O===void 0?6:/[gprs]/.test(j)?Math.max(1,Math.min(21,O)):Math.max(0,Math.min(20,O));function K(W){var ee=R,ie=U,X,ne,H;if(j==="c")ie=V(W)+ie,W="";else{W=+W;var I=W<0||1/W<0;if(W=isNaN(W)?f:V(Math.abs(W),O),P&&(W=Dhe(W)),I&&+W==0&&x!=="+"&&(I=!1),ee=(I?x==="("?x:l:x==="-"||x==="("?"":x)+ee,ie=(j==="s"?cD[8+Ez/3]:"")+ie+(I&&x==="("?")":""),Y){for(X=-1,ne=W.length;++X<ne;)if(H=W.charCodeAt(X),48>H||H>57){ie=(H===46?i+W.slice(X+1):W.slice(X))+ie,W=W.slice(0,X);break}}}A&&!S&&(W=t(W,1/0));var D=ee.length+W.length+ie.length,z=D<C?new Array(C-D+1).join(g):"";switch(A&&S&&(W=t(z+W,z.length?C-ie.length:1/0),z=""),_){case"<":W=ee+W+ie+z;break;case"=":W=ee+z+W+ie;break;case"^":W=z.slice(0,D=z.length>>1)+ee+W+ie+z.slice(D);break;default:W=z+ee+W+ie;break}return a(W)}return K.toString=function(){return m+""},K}function h(m,g){var _=u((m=gm(m),m.type="f",m)),x=Math.max(-8,Math.min(8,Math.floor(Jf(g)/3)))*3,b=Math.pow(10,-x),S=cD[8+x/3];return function(C){return _(b*C)+S}}return{format:u,formatPrefix:h}}var sy,P3,Oz;Bhe({thousands:",",grouping:[3],currency:["$",""]});function Bhe(e){return sy=$he(e),P3=sy.format,Oz=sy.formatPrefix,sy}function Uhe(e){return Math.max(0,-Jf(Math.abs(e)))}function zhe(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Jf(t)/3)))*3-Jf(Math.abs(e)))}function Fhe(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Jf(t)-Jf(e))+1}function Tz(e,t,n,r){var i=qE(e,t,n),a;switch(r=gm(r??",f"),r.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(a=zhe(i,o))&&(r.precision=a),Oz(r,o)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(a=Fhe(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=a-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(a=Uhe(i))&&(r.precision=a-(r.type==="%")*2);break}}return P3(r)}function Kl(e){var t=e.domain;return e.ticks=function(n){var r=t();return zE(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return Tz(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,a=r.length-1,o=r[i],l=r[a],f,u,h=10;for(l<o&&(u=o,o=l,l=u,u=i,i=a,a=u);h-- >0;){if(u=FE(o,l,n),u===f)return r[i]=o,r[a]=l,t(r);if(u>0)o=Math.floor(o/u)*u,l=Math.ceil(l/u)*u;else if(u<0)o=Math.ceil(o*u)/u,l=Math.floor(l*u)/u;else break;f=u}return e},e}function T0(){var e=T3();return e.copy=function(){return dg(e,T0())},ia.apply(e,arguments),Kl(e)}function jz(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,E0),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return jz(e).unknown(t)},e=arguments.length?Array.from(e,E0):[0,1],Kl(n)}function Pz(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],a=e[r],o;return a<i&&(o=n,n=r,r=o,o=i,i=a,a=o),e[n]=t.floor(i),e[r]=t.ceil(a),e}function fD(e){return Math.log(e)}function dD(e){return Math.exp(e)}function qhe(e){return-Math.log(-e)}function Vhe(e){return-Math.exp(-e)}function Hhe(e){return isFinite(e)?+("1e"+e):e<0?0:e}function Ghe(e){return e===10?Hhe:e===Math.E?Math.exp:t=>Math.pow(e,t)}function Whe(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 hD(e){return(t,n)=>-e(-t,n)}function R3(e){const t=e(fD,dD),n=t.domain;let r=10,i,a;function o(){return i=Whe(r),a=Ghe(r),n()[0]<0?(i=hD(i),a=hD(a),e(qhe,Vhe)):e(fD,dD),t}return t.base=function(l){return arguments.length?(r=+l,o()):r},t.domain=function(l){return arguments.length?(n(l),o()):n()},t.ticks=l=>{const f=n();let u=f[0],h=f[f.length-1];const m=h<u;m&&([u,h]=[h,u]);let g=i(u),_=i(h),x,b;const S=l==null?10:+l;let C=[];if(!(r%1)&&_-g<S){if(g=Math.floor(g),_=Math.ceil(_),u>0){for(;g<=_;++g)for(x=1;x<r;++x)if(b=g<0?x/a(-g):x*a(g),!(b<u)){if(b>h)break;C.push(b)}}else for(;g<=_;++g)for(x=r-1;x>=1;--x)if(b=g>0?x/a(-g):x*a(g),!(b<u)){if(b>h)break;C.push(b)}C.length*2<S&&(C=zE(u,h,S))}else C=zE(g,_,Math.min(_-g,S)).map(a);return m?C.reverse():C},t.tickFormat=(l,f)=>{if(l==null&&(l=10),f==null&&(f=r===10?"s":","),typeof f!="function"&&(!(r%1)&&(f=gm(f)).precision==null&&(f.trim=!0),f=P3(f)),l===1/0)return f;const u=Math.max(1,r*l/t.ticks().length);return h=>{let m=h/a(Math.round(i(h)));return m*r<r-.5&&(m*=r),m<=u?f(h):""}},t.nice=()=>n(Pz(n(),{floor:l=>a(Math.floor(i(l))),ceil:l=>a(Math.ceil(i(l)))})),t}function Rz(){const e=R3(d1()).domain([1,10]);return e.copy=()=>dg(e,Rz()).base(e.base()),ia.apply(e,arguments),e}function pD(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function mD(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function M3(e){var t=1,n=e(pD(t),mD(t));return n.constant=function(r){return arguments.length?e(pD(t=+r),mD(t)):t},Kl(n)}function Mz(){var e=M3(d1());return e.copy=function(){return dg(e,Mz()).constant(e.constant())},ia.apply(e,arguments)}function gD(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function Yhe(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function Khe(e){return e<0?-e*e:e*e}function N3(e){var t=e(Vr,Vr),n=1;function r(){return n===1?e(Vr,Vr):n===.5?e(Yhe,Khe):e(gD(n),gD(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},Kl(t)}function L3(){var e=N3(d1());return e.copy=function(){return dg(e,L3()).exponent(e.exponent())},ia.apply(e,arguments),e}function Zhe(){return L3.apply(null,arguments).exponent(.5)}function vD(e){return Math.sign(e)*e*e}function Xhe(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function Nz(){var e=T3(),t=[0,1],n=!1,r;function i(a){var o=Xhe(e(a));return isNaN(o)?r:n?Math.round(o):o}return i.invert=function(a){return e.invert(vD(a))},i.domain=function(a){return arguments.length?(e.domain(a),i):e.domain()},i.range=function(a){return arguments.length?(e.range((t=Array.from(a,E0)).map(vD)),i):t.slice()},i.rangeRound=function(a){return i.range(a).round(!0)},i.round=function(a){return arguments.length?(n=!!a,i):n},i.clamp=function(a){return arguments.length?(e.clamp(a),i):e.clamp()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.copy=function(){return Nz(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},ia.apply(i,arguments),Kl(i)}function Lz(){var e=[],t=[],n=[],r;function i(){var o=0,l=Math.max(1,t.length);for(n=new Array(l-1);++o<l;)n[o-1]=nhe(e,o/l);return a}function a(o){return o==null||isNaN(o=+o)?r:t[cg(n,o)]}return a.invertExtent=function(o){var l=t.indexOf(o);return l<0?[NaN,NaN]:[l>0?n[l-1]:e[0],l<n.length?n[l]:e[e.length-1]]},a.domain=function(o){if(!arguments.length)return e.slice();e=[];for(let l of o)l!=null&&!isNaN(l=+l)&&e.push(l);return e.sort(Al),i()},a.range=function(o){return arguments.length?(t=Array.from(o),i()):t.slice()},a.unknown=function(o){return arguments.length?(r=o,a):r},a.quantiles=function(){return n.slice()},a.copy=function(){return Lz().domain(e).range(t).unknown(r)},ia.apply(a,arguments)}function kz(){var e=0,t=1,n=1,r=[.5],i=[0,1],a;function o(f){return f!=null&&f<=f?i[cg(r,f,0,n)]:a}function l(){var f=-1;for(r=new Array(n);++f<n;)r[f]=((f+1)*t-(f-n)*e)/(n+1);return o}return o.domain=function(f){return arguments.length?([e,t]=f,e=+e,t=+t,l()):[e,t]},o.range=function(f){return arguments.length?(n=(i=Array.from(f)).length-1,l()):i.slice()},o.invertExtent=function(f){var u=i.indexOf(f);return u<0?[NaN,NaN]:u<1?[e,r[0]]:u>=n?[r[n-1],t]:[r[u-1],r[u]]},o.unknown=function(f){return arguments.length&&(a=f),o},o.thresholds=function(){return r.slice()},o.copy=function(){return kz().domain([e,t]).range(i).unknown(a)},ia.apply(Kl(o),arguments)}function Dz(){var e=[.5],t=[0,1],n,r=1;function i(a){return a!=null&&a<=a?t[cg(e,a,0,r)]:n}return i.domain=function(a){return arguments.length?(e=Array.from(a),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(a){return arguments.length?(t=Array.from(a),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(a){var o=t.indexOf(a);return[e[o-1],e[o]]},i.unknown=function(a){return arguments.length?(n=a,i):n},i.copy=function(){return Dz().domain(e).range(t).unknown(n)},ia.apply(i,arguments)}const RC=new Date,MC=new Date;function Qn(e,t,n,r){function i(a){return e(a=arguments.length===0?new Date:new Date(+a)),a}return i.floor=a=>(e(a=new Date(+a)),a),i.ceil=a=>(e(a=new Date(a-1)),t(a,1),e(a),a),i.round=a=>{const o=i(a),l=i.ceil(a);return a-o<l-a?o:l},i.offset=(a,o)=>(t(a=new Date(+a),o==null?1:Math.floor(o)),a),i.range=(a,o,l)=>{const f=[];if(a=i.ceil(a),l=l==null?1:Math.floor(l),!(a<o)||!(l>0))return f;let u;do f.push(u=new Date(+a)),t(a,l),e(a);while(u<a&&a<o);return f},i.filter=a=>Qn(o=>{if(o>=o)for(;e(o),!a(o);)o.setTime(o-1)},(o,l)=>{if(o>=o)if(l<0)for(;++l<=0;)for(;t(o,-1),!a(o););else for(;--l>=0;)for(;t(o,1),!a(o););}),n&&(i.count=(a,o)=>(RC.setTime(+a),MC.setTime(+o),e(RC),e(MC),Math.floor(n(RC,MC))),i.every=a=>(a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?i.filter(r?o=>r(o)%a===0:o=>i.count(0,o)%a===0):i)),i}const j0=Qn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);j0.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Qn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):j0);j0.range;const Yo=1e3,ea=Yo*60,Ko=ea*60,ss=Ko*24,k3=ss*7,yD=ss*30,NC=ss*365,Vu=Qn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Yo)},(e,t)=>(t-e)/Yo,e=>e.getUTCSeconds());Vu.range;const D3=Qn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Yo)},(e,t)=>{e.setTime(+e+t*ea)},(e,t)=>(t-e)/ea,e=>e.getMinutes());D3.range;const I3=Qn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*ea)},(e,t)=>(t-e)/ea,e=>e.getUTCMinutes());I3.range;const $3=Qn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Yo-e.getMinutes()*ea)},(e,t)=>{e.setTime(+e+t*Ko)},(e,t)=>(t-e)/Ko,e=>e.getHours());$3.range;const B3=Qn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Ko)},(e,t)=>(t-e)/Ko,e=>e.getUTCHours());B3.range;const hg=Qn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*ea)/ss,e=>e.getDate()-1);hg.range;const h1=Qn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ss,e=>e.getUTCDate()-1);h1.range;const Iz=Qn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ss,e=>Math.floor(e/ss));Iz.range;function pc(e){return Qn(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())*ea)/k3)}const p1=pc(0),P0=pc(1),Qhe=pc(2),Jhe=pc(3),ed=pc(4),epe=pc(5),tpe=pc(6);p1.range;P0.range;Qhe.range;Jhe.range;ed.range;epe.range;tpe.range;function mc(e){return Qn(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)/k3)}const m1=mc(0),R0=mc(1),npe=mc(2),rpe=mc(3),td=mc(4),ipe=mc(5),ape=mc(6);m1.range;R0.range;npe.range;rpe.range;td.range;ipe.range;ape.range;const U3=Qn(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());U3.range;const z3=Qn(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());z3.range;const ls=Qn(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());ls.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Qn(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)});ls.range;const us=Qn(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());us.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Qn(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)});us.range;function $z(e,t,n,r,i,a){const o=[[Vu,1,Yo],[Vu,5,5*Yo],[Vu,15,15*Yo],[Vu,30,30*Yo],[a,1,ea],[a,5,5*ea],[a,15,15*ea],[a,30,30*ea],[i,1,Ko],[i,3,3*Ko],[i,6,6*Ko],[i,12,12*Ko],[r,1,ss],[r,2,2*ss],[n,1,k3],[t,1,yD],[t,3,3*yD],[e,1,NC]];function l(u,h,m){const g=h<u;g&&([u,h]=[h,u]);const _=m&&typeof m.range=="function"?m:f(u,h,m),x=_?_.range(u,+h+1):[];return g?x.reverse():x}function f(u,h,m){const g=Math.abs(h-u)/m,_=S3(([,,S])=>S).right(o,g);if(_===o.length)return e.every(qE(u/NC,h/NC,m));if(_===0)return j0.every(Math.max(qE(u,h,m),1));const[x,b]=o[g/o[_-1][2]<o[_][2]/g?_-1:_];return x.every(b)}return[l,f]}const[ope,spe]=$z(us,z3,m1,Iz,B3,I3),[lpe,upe]=$z(ls,U3,p1,hg,$3,D3);function LC(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 kC(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 lp(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function cpe(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,a=e.days,o=e.shortDays,l=e.months,f=e.shortMonths,u=up(i),h=cp(i),m=up(a),g=cp(a),_=up(o),x=cp(o),b=up(l),S=cp(l),C=up(f),A=cp(f),O={a:I,A:D,b:z,B:N,c:null,d:CD,e:CD,f:Npe,g:qpe,G:Hpe,H:Ppe,I:Rpe,j:Mpe,L:Bz,m:Lpe,M:kpe,p:B,q:Q,Q:OD,s:TD,S:Dpe,u:Ipe,U:$pe,V:Bpe,w:Upe,W:zpe,x:null,X:null,y:Fpe,Y:Vpe,Z:Gpe,"%":ED},P={a:G,A:ae,b:fe,B:ce,c:null,d:AD,e:AD,f:Zpe,g:ome,G:lme,H:Wpe,I:Ype,j:Kpe,L:zz,m:Xpe,M:Qpe,p:ye,q:F,Q:OD,s:TD,S:Jpe,u:eme,U:tme,V:nme,w:rme,W:ime,x:null,X:null,y:ame,Y:sme,Z:ume,"%":ED},j={a:K,A:W,b:ee,B:ie,c:X,d:xD,e:xD,f:Epe,g:_D,G:wD,H:SD,I:SD,j:xpe,L:Ape,m:_pe,M:Spe,p:Y,q:wpe,Q:Tpe,s:jpe,S:Cpe,u:mpe,U:gpe,V:vpe,w:ppe,W:ype,x:ne,X:H,y:_D,Y:wD,Z:bpe,"%":Ope};O.x=R(n,O),O.X=R(r,O),O.c=R(t,O),P.x=R(n,P),P.X=R(r,P),P.c=R(t,P);function R(q,te){return function(ue){var J=[],se=-1,de=0,ve=q.length,he,xe,Oe;for(ue instanceof Date||(ue=new Date(+ue));++se<ve;)q.charCodeAt(se)===37&&(J.push(q.slice(de,se)),(xe=bD[he=q.charAt(++se)])!=null?he=q.charAt(++se):xe=he==="e"?" ":"0",(Oe=te[he])&&(he=Oe(ue,xe)),J.push(he),de=se+1);return J.push(q.slice(de,se)),J.join("")}}function U(q,te){return function(ue){var J=lp(1900,void 0,1),se=V(J,q,ue+="",0),de,ve;if(se!=ue.length)return null;if("Q"in J)return new Date(J.Q);if("s"in J)return new Date(J.s*1e3+("L"in J?J.L:0));if(te&&!("Z"in J)&&(J.Z=0),"p"in J&&(J.H=J.H%12+J.p*12),J.m===void 0&&(J.m="q"in J?J.q:0),"V"in J){if(J.V<1||J.V>53)return null;"w"in J||(J.w=1),"Z"in J?(de=kC(lp(J.y,0,1)),ve=de.getUTCDay(),de=ve>4||ve===0?R0.ceil(de):R0(de),de=h1.offset(de,(J.V-1)*7),J.y=de.getUTCFullYear(),J.m=de.getUTCMonth(),J.d=de.getUTCDate()+(J.w+6)%7):(de=LC(lp(J.y,0,1)),ve=de.getDay(),de=ve>4||ve===0?P0.ceil(de):P0(de),de=hg.offset(de,(J.V-1)*7),J.y=de.getFullYear(),J.m=de.getMonth(),J.d=de.getDate()+(J.w+6)%7)}else("W"in J||"U"in J)&&("w"in J||(J.w="u"in J?J.u%7:"W"in J?1:0),ve="Z"in J?kC(lp(J.y,0,1)).getUTCDay():LC(lp(J.y,0,1)).getDay(),J.m=0,J.d="W"in J?(J.w+6)%7+J.W*7-(ve+5)%7:J.w+J.U*7-(ve+6)%7);return"Z"in J?(J.H+=J.Z/100|0,J.M+=J.Z%100,kC(J)):LC(J)}}function V(q,te,ue,J){for(var se=0,de=te.length,ve=ue.length,he,xe;se<de;){if(J>=ve)return-1;if(he=te.charCodeAt(se++),he===37){if(he=te.charAt(se++),xe=j[he in bD?te.charAt(se++):he],!xe||(J=xe(q,ue,J))<0)return-1}else if(he!=ue.charCodeAt(J++))return-1}return J}function Y(q,te,ue){var J=u.exec(te.slice(ue));return J?(q.p=h.get(J[0].toLowerCase()),ue+J[0].length):-1}function K(q,te,ue){var J=_.exec(te.slice(ue));return J?(q.w=x.get(J[0].toLowerCase()),ue+J[0].length):-1}function W(q,te,ue){var J=m.exec(te.slice(ue));return J?(q.w=g.get(J[0].toLowerCase()),ue+J[0].length):-1}function ee(q,te,ue){var J=C.exec(te.slice(ue));return J?(q.m=A.get(J[0].toLowerCase()),ue+J[0].length):-1}function ie(q,te,ue){var J=b.exec(te.slice(ue));return J?(q.m=S.get(J[0].toLowerCase()),ue+J[0].length):-1}function X(q,te,ue){return V(q,t,te,ue)}function ne(q,te,ue){return V(q,n,te,ue)}function H(q,te,ue){return V(q,r,te,ue)}function I(q){return o[q.getDay()]}function D(q){return a[q.getDay()]}function z(q){return f[q.getMonth()]}function N(q){return l[q.getMonth()]}function B(q){return i[+(q.getHours()>=12)]}function Q(q){return 1+~~(q.getMonth()/3)}function G(q){return o[q.getUTCDay()]}function ae(q){return a[q.getUTCDay()]}function fe(q){return f[q.getUTCMonth()]}function ce(q){return l[q.getUTCMonth()]}function ye(q){return i[+(q.getUTCHours()>=12)]}function F(q){return 1+~~(q.getUTCMonth()/3)}return{format:function(q){var te=R(q+="",O);return te.toString=function(){return q},te},parse:function(q){var te=U(q+="",!1);return te.toString=function(){return q},te},utcFormat:function(q){var te=R(q+="",P);return te.toString=function(){return q},te},utcParse:function(q){var te=U(q+="",!0);return te.toString=function(){return q},te}}}var bD={"-":"",_:" ",0:"0"},cr=/^\s*\d+/,fpe=/^%/,dpe=/[\\^$*+?|[\]().{}]/g;function Ut(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",a=i.length;return r+(a<n?new Array(n-a+1).join(t)+i:i)}function hpe(e){return e.replace(dpe,"\\$&")}function up(e){return new RegExp("^(?:"+e.map(hpe).join("|")+")","i")}function cp(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function ppe(e,t,n){var r=cr.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function mpe(e,t,n){var r=cr.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function gpe(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function vpe(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function ype(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function wD(e,t,n){var r=cr.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function _D(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function bpe(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 wpe(e,t,n){var r=cr.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function _pe(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function xD(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function xpe(e,t,n){var r=cr.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function SD(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Spe(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Cpe(e,t,n){var r=cr.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Ape(e,t,n){var r=cr.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Epe(e,t,n){var r=cr.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Ope(e,t,n){var r=fpe.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Tpe(e,t,n){var r=cr.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function jpe(e,t,n){var r=cr.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function CD(e,t){return Ut(e.getDate(),t,2)}function Ppe(e,t){return Ut(e.getHours(),t,2)}function Rpe(e,t){return Ut(e.getHours()%12||12,t,2)}function Mpe(e,t){return Ut(1+hg.count(ls(e),e),t,3)}function Bz(e,t){return Ut(e.getMilliseconds(),t,3)}function Npe(e,t){return Bz(e,t)+"000"}function Lpe(e,t){return Ut(e.getMonth()+1,t,2)}function kpe(e,t){return Ut(e.getMinutes(),t,2)}function Dpe(e,t){return Ut(e.getSeconds(),t,2)}function Ipe(e){var t=e.getDay();return t===0?7:t}function $pe(e,t){return Ut(p1.count(ls(e)-1,e),t,2)}function Uz(e){var t=e.getDay();return t>=4||t===0?ed(e):ed.ceil(e)}function Bpe(e,t){return e=Uz(e),Ut(ed.count(ls(e),e)+(ls(e).getDay()===4),t,2)}function Upe(e){return e.getDay()}function zpe(e,t){return Ut(P0.count(ls(e)-1,e),t,2)}function Fpe(e,t){return Ut(e.getFullYear()%100,t,2)}function qpe(e,t){return e=Uz(e),Ut(e.getFullYear()%100,t,2)}function Vpe(e,t){return Ut(e.getFullYear()%1e4,t,4)}function Hpe(e,t){var n=e.getDay();return e=n>=4||n===0?ed(e):ed.ceil(e),Ut(e.getFullYear()%1e4,t,4)}function Gpe(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Ut(t/60|0,"0",2)+Ut(t%60,"0",2)}function AD(e,t){return Ut(e.getUTCDate(),t,2)}function Wpe(e,t){return Ut(e.getUTCHours(),t,2)}function Ype(e,t){return Ut(e.getUTCHours()%12||12,t,2)}function Kpe(e,t){return Ut(1+h1.count(us(e),e),t,3)}function zz(e,t){return Ut(e.getUTCMilliseconds(),t,3)}function Zpe(e,t){return zz(e,t)+"000"}function Xpe(e,t){return Ut(e.getUTCMonth()+1,t,2)}function Qpe(e,t){return Ut(e.getUTCMinutes(),t,2)}function Jpe(e,t){return Ut(e.getUTCSeconds(),t,2)}function eme(e){var t=e.getUTCDay();return t===0?7:t}function tme(e,t){return Ut(m1.count(us(e)-1,e),t,2)}function Fz(e){var t=e.getUTCDay();return t>=4||t===0?td(e):td.ceil(e)}function nme(e,t){return e=Fz(e),Ut(td.count(us(e),e)+(us(e).getUTCDay()===4),t,2)}function rme(e){return e.getUTCDay()}function ime(e,t){return Ut(R0.count(us(e)-1,e),t,2)}function ame(e,t){return Ut(e.getUTCFullYear()%100,t,2)}function ome(e,t){return e=Fz(e),Ut(e.getUTCFullYear()%100,t,2)}function sme(e,t){return Ut(e.getUTCFullYear()%1e4,t,4)}function lme(e,t){var n=e.getUTCDay();return e=n>=4||n===0?td(e):td.ceil(e),Ut(e.getUTCFullYear()%1e4,t,4)}function ume(){return"+0000"}function ED(){return"%"}function OD(e){return+e}function TD(e){return Math.floor(+e/1e3)}var mf,qz,Vz;cme({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 cme(e){return mf=cpe(e),qz=mf.format,mf.parse,Vz=mf.utcFormat,mf.utcParse,mf}function fme(e){return new Date(e)}function dme(e){return e instanceof Date?+e:+new Date(+e)}function F3(e,t,n,r,i,a,o,l,f,u){var h=T3(),m=h.invert,g=h.domain,_=u(".%L"),x=u(":%S"),b=u("%I:%M"),S=u("%I %p"),C=u("%a %d"),A=u("%b %d"),O=u("%B"),P=u("%Y");function j(R){return(f(R)<R?_:l(R)<R?x:o(R)<R?b:a(R)<R?S:r(R)<R?i(R)<R?C:A:n(R)<R?O:P)(R)}return h.invert=function(R){return new Date(m(R))},h.domain=function(R){return arguments.length?g(Array.from(R,dme)):g().map(fme)},h.ticks=function(R){var U=g();return e(U[0],U[U.length-1],R??10)},h.tickFormat=function(R,U){return U==null?j:u(U)},h.nice=function(R){var U=g();return(!R||typeof R.range!="function")&&(R=t(U[0],U[U.length-1],R??10)),R?g(Pz(U,R)):h},h.copy=function(){return dg(h,F3(e,t,n,r,i,a,o,l,f,u))},h}function hme(){return ia.apply(F3(lpe,upe,ls,U3,p1,hg,$3,D3,Vu,qz).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function pme(){return ia.apply(F3(ope,spe,us,z3,m1,h1,B3,I3,Vu,Vz).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function g1(){var e=0,t=1,n,r,i,a,o=Vr,l=!1,f;function u(m){return m==null||isNaN(m=+m)?f:o(i===0?.5:(m=(a(m)-n)*i,l?Math.max(0,Math.min(1,m)):m))}u.domain=function(m){return arguments.length?([e,t]=m,n=a(e=+e),r=a(t=+t),i=n===r?0:1/(r-n),u):[e,t]},u.clamp=function(m){return arguments.length?(l=!!m,u):l},u.interpolator=function(m){return arguments.length?(o=m,u):o};function h(m){return function(g){var _,x;return arguments.length?([_,x]=g,o=m(_,x),u):[o(0),o(1)]}}return u.range=h(Ud),u.rangeRound=h(O3),u.unknown=function(m){return arguments.length?(f=m,u):f},function(m){return a=m,n=m(e),r=m(t),i=n===r?0:1/(r-n),u}}function Zl(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function Hz(){var e=Kl(g1()(Vr));return e.copy=function(){return Zl(e,Hz())},gs.apply(e,arguments)}function Gz(){var e=R3(g1()).domain([1,10]);return e.copy=function(){return Zl(e,Gz()).base(e.base())},gs.apply(e,arguments)}function Wz(){var e=M3(g1());return e.copy=function(){return Zl(e,Wz()).constant(e.constant())},gs.apply(e,arguments)}function q3(){var e=N3(g1());return e.copy=function(){return Zl(e,q3()).exponent(e.exponent())},gs.apply(e,arguments)}function mme(){return q3.apply(null,arguments).exponent(.5)}function Yz(){var e=[],t=Vr;function n(r){if(r!=null&&!isNaN(r=+r))return t((cg(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(Al),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,a)=>the(e,a/r))},n.copy=function(){return Yz(t).domain(e)},gs.apply(n,arguments)}function v1(){var e=0,t=.5,n=1,r=1,i,a,o,l,f,u=Vr,h,m=!1,g;function _(b){return isNaN(b=+b)?g:(b=.5+((b=+h(b))-a)*(r*b<r*a?l:f),u(m?Math.max(0,Math.min(1,b)):b))}_.domain=function(b){return arguments.length?([e,t,n]=b,i=h(e=+e),a=h(t=+t),o=h(n=+n),l=i===a?0:.5/(a-i),f=a===o?0:.5/(o-a),r=a<i?-1:1,_):[e,t,n]},_.clamp=function(b){return arguments.length?(m=!!b,_):m},_.interpolator=function(b){return arguments.length?(u=b,_):u};function x(b){return function(S){var C,A,O;return arguments.length?([C,A,O]=S,u=Ohe(b,[C,A,O]),_):[u(0),u(.5),u(1)]}}return _.range=x(Ud),_.rangeRound=x(O3),_.unknown=function(b){return arguments.length?(g=b,_):g},function(b){return h=b,i=b(e),a=b(t),o=b(n),l=i===a?0:.5/(a-i),f=a===o?0:.5/(o-a),r=a<i?-1:1,_}}function Kz(){var e=Kl(v1()(Vr));return e.copy=function(){return Zl(e,Kz())},gs.apply(e,arguments)}function Zz(){var e=R3(v1()).domain([.1,1,10]);return e.copy=function(){return Zl(e,Zz()).base(e.base())},gs.apply(e,arguments)}function Xz(){var e=M3(v1());return e.copy=function(){return Zl(e,Xz()).constant(e.constant())},gs.apply(e,arguments)}function V3(){var e=N3(v1());return e.copy=function(){return Zl(e,V3()).exponent(e.exponent())},gs.apply(e,arguments)}function gme(){return V3.apply(null,arguments).exponent(.5)}const jD=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:dm,scaleDiverging:Kz,scaleDivergingLog:Zz,scaleDivergingPow:V3,scaleDivergingSqrt:gme,scaleDivergingSymlog:Xz,scaleIdentity:jz,scaleImplicit:VE,scaleLinear:T0,scaleLog:Rz,scaleOrdinal:C3,scalePoint:kp,scalePow:L3,scaleQuantile:Lz,scaleQuantize:kz,scaleRadial:Nz,scaleSequential:Hz,scaleSequentialLog:Gz,scaleSequentialPow:q3,scaleSequentialQuantile:Yz,scaleSequentialSqrt:mme,scaleSequentialSymlog:Wz,scaleSqrt:Zhe,scaleSymlog:Mz,scaleThreshold:Dz,scaleTime:hme,scaleUtc:pme,tickFormat:Tz},Symbol.toStringTag,{value:"Module"}));var DC,PD;function y1(){if(PD)return DC;PD=1;var e=Dd();function t(n,r,i){for(var a=-1,o=n.length;++a<o;){var l=n[a],f=r(l);if(f!=null&&(u===void 0?f===f&&!e(f):i(f,u)))var u=f,h=l}return h}return DC=t,DC}var IC,RD;function Qz(){if(RD)return IC;RD=1;function e(t,n){return t>n}return IC=e,IC}var $C,MD;function vme(){if(MD)return $C;MD=1;var e=y1(),t=Qz(),n=Bd();function r(i){return i&&i.length?e(i,n,t):void 0}return $C=r,$C}var yme=vme();const wl=zt(yme);var BC,ND;function Jz(){if(ND)return BC;ND=1;function e(t,n){return t<n}return BC=e,BC}var UC,LD;function bme(){if(LD)return UC;LD=1;var e=y1(),t=Jz(),n=Bd();function r(i){return i&&i.length?e(i,n,t):void 0}return UC=r,UC}var wme=bme();const b1=zt(wme);var zC,kD;function _me(){if(kD)return zC;kD=1;var e=s3(),t=vo(),n=sz(),r=ri();function i(a,o){var l=r(a)?e:n;return l(a,t(o,3))}return zC=i,zC}var FC,DD;function xme(){if(DD)return FC;DD=1;var e=az(),t=_me();function n(r,i){return e(t(r,i),1)}return FC=n,FC}var Sme=xme();const Cme=zt(Sme);var qC,ID;function Ame(){if(ID)return qC;ID=1;var e=b3();function t(n,r){return e(n,r)}return qC=t,qC}var Eme=Ame();const Ul=zt(Eme);var zd=1e9,Ome={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},G3,yn=!0,na="[DecimalError] ",Yu=na+"Invalid argument: ",H3=na+"Exponent out of range: ",Fd=Math.floor,ku=Math.pow,Tme=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,xi,sr=1e7,dn=7,eF=9007199254740991,M0=Fd(eF/dn),nt={};nt.absoluteValue=nt.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};nt.comparedTo=nt.cmp=function(e){var t,n,r,i,a=this;if(e=new a.constructor(e),a.s!==e.s)return a.s||-e.s;if(a.e!==e.e)return a.e>e.e^a.s<0?1:-1;for(r=a.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(a.d[t]!==e.d[t])return a.d[t]>e.d[t]^a.s<0?1:-1;return r===i?0:r>i^a.s<0?1:-1};nt.decimalPlaces=nt.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*dn;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};nt.dividedBy=nt.div=function(e){return es(this,new this.constructor(e))};nt.dividedToIntegerBy=nt.idiv=function(e){var t=this,n=t.constructor;return Jt(es(t,new n(e),0,1),n.precision)};nt.equals=nt.eq=function(e){return!this.cmp(e)};nt.exponent=function(){return qn(this)};nt.greaterThan=nt.gt=function(e){return this.cmp(e)>0};nt.greaterThanOrEqualTo=nt.gte=function(e){return this.cmp(e)>=0};nt.isInteger=nt.isint=function(){return this.e>this.d.length-2};nt.isNegative=nt.isneg=function(){return this.s<0};nt.isPositive=nt.ispos=function(){return this.s>0};nt.isZero=function(){return this.s===0};nt.lessThan=nt.lt=function(e){return this.cmp(e)<0};nt.lessThanOrEqualTo=nt.lte=function(e){return this.cmp(e)<1};nt.logarithm=nt.log=function(e){var t,n=this,r=n.constructor,i=r.precision,a=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(xi))throw Error(na+"NaN");if(n.s<1)throw Error(na+(n.s?"NaN":"-Infinity"));return n.eq(xi)?new r(0):(yn=!1,t=es(vm(n,a),vm(e,a),a),yn=!0,Jt(t,i))};nt.minus=nt.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?rF(t,e):tF(t,(e.s=-e.s,e))};nt.modulo=nt.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(na+"NaN");return n.s?(yn=!1,t=es(n,e,0,1).times(e),yn=!0,n.minus(t)):Jt(new r(n),i)};nt.naturalExponential=nt.exp=function(){return nF(this)};nt.naturalLogarithm=nt.ln=function(){return vm(this)};nt.negated=nt.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};nt.plus=nt.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?tF(t,e):rF(t,(e.s=-e.s,e))};nt.precision=nt.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Yu+e);if(t=qn(i)+1,r=i.d.length-1,n=r*dn+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};nt.squareRoot=nt.sqrt=function(){var e,t,n,r,i,a,o,l=this,f=l.constructor;if(l.s<1){if(!l.s)return new f(0);throw Error(na+"NaN")}for(e=qn(l),yn=!1,i=Math.sqrt(+l),i==0||i==1/0?(t=Ja(l.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Fd((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 f(t)):r=new f(i.toString()),n=f.precision,i=o=n+3;;)if(a=r,r=a.plus(es(l,a,o+2)).times(.5),Ja(a.d).slice(0,o)===(t=Ja(r.d)).slice(0,o)){if(t=t.slice(o-3,o+1),i==o&&t=="4999"){if(Jt(a,n+1,0),a.times(a).eq(l)){r=a;break}}else if(t!="9999")break;o+=4}return yn=!0,Jt(r,n)};nt.times=nt.mul=function(e){var t,n,r,i,a,o,l,f,u,h=this,m=h.constructor,g=h.d,_=(e=new m(e)).d;if(!h.s||!e.s)return new m(0);for(e.s*=h.s,n=h.e+e.e,f=g.length,u=_.length,f<u&&(a=g,g=_,_=a,o=f,f=u,u=o),a=[],o=f+u,r=o;r--;)a.push(0);for(r=u;--r>=0;){for(t=0,i=f+r;i>r;)l=a[i]+_[r]*g[i-r-1]+t,a[i--]=l%sr|0,t=l/sr|0;a[i]=(a[i]+t)%sr|0}for(;!a[--o];)a.pop();return t?++n:a.shift(),e.d=a,e.e=n,yn?Jt(e,m.precision):e};nt.toDecimalPlaces=nt.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(lo(e,0,zd),t===void 0?t=r.rounding:lo(t,0,8),Jt(n,e+qn(n)+1,t))};nt.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=oc(r,!0):(lo(e,0,zd),t===void 0?t=i.rounding:lo(t,0,8),r=Jt(new i(r),e+1,t),n=oc(r,!0,e+1)),n};nt.toFixed=function(e,t){var n,r,i=this,a=i.constructor;return e===void 0?oc(i):(lo(e,0,zd),t===void 0?t=a.rounding:lo(t,0,8),r=Jt(new a(i),e+qn(i)+1,t),n=oc(r.abs(),!1,e+qn(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};nt.toInteger=nt.toint=function(){var e=this,t=e.constructor;return Jt(new t(e),qn(e)+1,t.rounding)};nt.toNumber=function(){return+this};nt.toPower=nt.pow=function(e){var t,n,r,i,a,o,l=this,f=l.constructor,u=12,h=+(e=new f(e));if(!e.s)return new f(xi);if(l=new f(l),!l.s){if(e.s<1)throw Error(na+"Infinity");return l}if(l.eq(xi))return l;if(r=f.precision,e.eq(xi))return Jt(l,r);if(t=e.e,n=e.d.length-1,o=t>=n,a=l.s,o){if((n=h<0?-h:h)<=eF){for(i=new f(xi),t=Math.ceil(r/dn+4),yn=!1;n%2&&(i=i.times(l),BD(i.d,t)),n=Fd(n/2),n!==0;)l=l.times(l),BD(l.d,t);return yn=!0,e.s<0?new f(xi).div(i):Jt(i,r)}}else if(a<0)throw Error(na+"NaN");return a=a<0&&e.d[Math.max(t,n)]&1?-1:1,l.s=1,yn=!1,i=e.times(vm(l,r+u)),yn=!0,i=nF(i),i.s=a,i};nt.toPrecision=function(e,t){var n,r,i=this,a=i.constructor;return e===void 0?(n=qn(i),r=oc(i,n<=a.toExpNeg||n>=a.toExpPos)):(lo(e,1,zd),t===void 0?t=a.rounding:lo(t,0,8),i=Jt(new a(i),e,t),n=qn(i),r=oc(i,e<=n||n<=a.toExpNeg,e)),r};nt.toSignificantDigits=nt.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(lo(e,1,zd),t===void 0?t=r.rounding:lo(t,0,8)),Jt(new r(n),e,t)};nt.toString=nt.valueOf=nt.val=nt.toJSON=nt[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=qn(e),n=e.constructor;return oc(e,t<=n.toExpNeg||t>=n.toExpPos)};function tF(e,t){var n,r,i,a,o,l,f,u,h=e.constructor,m=h.precision;if(!e.s||!t.s)return t.s||(t=new h(e)),yn?Jt(t,m):t;if(f=e.d,u=t.d,o=e.e,i=t.e,f=f.slice(),a=o-i,a){for(a<0?(r=f,a=-a,l=u.length):(r=u,i=o,l=f.length),o=Math.ceil(m/dn),l=o>l?o+1:l+1,a>l&&(a=l,r.length=1),r.reverse();a--;)r.push(0);r.reverse()}for(l=f.length,a=u.length,l-a<0&&(a=l,r=u,u=f,f=r),n=0;a;)n=(f[--a]=f[a]+u[a]+n)/sr|0,f[a]%=sr;for(n&&(f.unshift(n),++i),l=f.length;f[--l]==0;)f.pop();return t.d=f,t.e=i,yn?Jt(t,m):t}function lo(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Yu+e)}function Ja(e){var t,n,r,i=e.length-1,a="",o=e[0];if(i>0){for(a+=o,t=1;t<i;t++)r=e[t]+"",n=dn-r.length,n&&(a+=gl(n)),a+=r;o=e[t],r=o+"",n=dn-r.length,n&&(a+=gl(n))}else if(o===0)return"0";for(;o%10===0;)o/=10;return a+o}var es=function(){function e(r,i){var a,o=0,l=r.length;for(r=r.slice();l--;)a=r[l]*i+o,r[l]=a%sr|0,o=a/sr|0;return o&&r.unshift(o),r}function t(r,i,a,o){var l,f;if(a!=o)f=a>o?1:-1;else for(l=f=0;l<a;l++)if(r[l]!=i[l]){f=r[l]>i[l]?1:-1;break}return f}function n(r,i,a){for(var o=0;a--;)r[a]-=o,o=r[a]<i[a]?1:0,r[a]=o*sr+r[a]-i[a];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,a,o){var l,f,u,h,m,g,_,x,b,S,C,A,O,P,j,R,U,V,Y=r.constructor,K=r.s==i.s?1:-1,W=r.d,ee=i.d;if(!r.s)return new Y(r);if(!i.s)throw Error(na+"Division by zero");for(f=r.e-i.e,U=ee.length,j=W.length,_=new Y(K),x=_.d=[],u=0;ee[u]==(W[u]||0);)++u;if(ee[u]>(W[u]||0)&&--f,a==null?A=a=Y.precision:o?A=a+(qn(r)-qn(i))+1:A=a,A<0)return new Y(0);if(A=A/dn+2|0,u=0,U==1)for(h=0,ee=ee[0],A++;(u<j||h)&&A--;u++)O=h*sr+(W[u]||0),x[u]=O/ee|0,h=O%ee|0;else{for(h=sr/(ee[0]+1)|0,h>1&&(ee=e(ee,h),W=e(W,h),U=ee.length,j=W.length),P=U,b=W.slice(0,U),S=b.length;S<U;)b[S++]=0;V=ee.slice(),V.unshift(0),R=ee[0],ee[1]>=sr/2&&++R;do h=0,l=t(ee,b,U,S),l<0?(C=b[0],U!=S&&(C=C*sr+(b[1]||0)),h=C/R|0,h>1?(h>=sr&&(h=sr-1),m=e(ee,h),g=m.length,S=b.length,l=t(m,b,g,S),l==1&&(h--,n(m,U<g?V:ee,g))):(h==0&&(l=h=1),m=ee.slice()),g=m.length,g<S&&m.unshift(0),n(b,m,S),l==-1&&(S=b.length,l=t(ee,b,U,S),l<1&&(h++,n(b,U<S?V:ee,S))),S=b.length):l===0&&(h++,b=[0]),x[u++]=h,l&&b[0]?b[S++]=W[P]||0:(b=[W[P]],S=1);while((P++<j||b[0]!==void 0)&&A--)}return x[0]||x.shift(),_.e=f,Jt(_,o?a+qn(_)+1:a)}}();function nF(e,t){var n,r,i,a,o,l,f=0,u=0,h=e.constructor,m=h.precision;if(qn(e)>16)throw Error(H3+qn(e));if(!e.s)return new h(xi);for(yn=!1,l=m,o=new h(.03125);e.abs().gte(.1);)e=e.times(o),u+=5;for(r=Math.log(ku(2,u))/Math.LN10*2+5|0,l+=r,n=i=a=new h(xi),h.precision=l;;){if(i=Jt(i.times(e),l),n=n.times(++f),o=a.plus(es(i,n,l)),Ja(o.d).slice(0,l)===Ja(a.d).slice(0,l)){for(;u--;)a=Jt(a.times(a),l);return h.precision=m,t==null?(yn=!0,Jt(a,m)):a}a=o}}function qn(e){for(var t=e.e*dn,n=e.d[0];n>=10;n/=10)t++;return t}function VC(e,t,n){if(t>e.LN10.sd())throw yn=!0,n&&(e.precision=n),Error(na+"LN10 precision limit exceeded");return Jt(new e(e.LN10),t)}function gl(e){for(var t="";e--;)t+="0";return t}function vm(e,t){var n,r,i,a,o,l,f,u,h,m=1,g=10,_=e,x=_.d,b=_.constructor,S=b.precision;if(_.s<1)throw Error(na+(_.s?"NaN":"-Infinity"));if(_.eq(xi))return new b(0);if(t==null?(yn=!1,u=S):u=t,_.eq(10))return t==null&&(yn=!0),VC(b,u);if(u+=g,b.precision=u,n=Ja(x),r=n.charAt(0),a=qn(_),Math.abs(a)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)_=_.times(e),n=Ja(_.d),r=n.charAt(0),m++;a=qn(_),r>1?(_=new b("0."+n),a++):_=new b(r+"."+n.slice(1))}else return f=VC(b,u+2,S).times(a+""),_=vm(new b(r+"."+n.slice(1)),u-g).plus(f),b.precision=S,t==null?(yn=!0,Jt(_,S)):_;for(l=o=_=es(_.minus(xi),_.plus(xi),u),h=Jt(_.times(_),u),i=3;;){if(o=Jt(o.times(h),u),f=l.plus(es(o,new b(i),u)),Ja(f.d).slice(0,u)===Ja(l.d).slice(0,u))return l=l.times(2),a!==0&&(l=l.plus(VC(b,u+2,S).times(a+""))),l=es(l,new b(m),u),b.precision=S,t==null?(yn=!0,Jt(l,S)):l;l=f,i+=2}}function $D(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=Fd(n/dn),e.d=[],r=(n+1)%dn,n<0&&(r+=dn),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=dn;r<i;)e.d.push(+t.slice(r,r+=dn));t=t.slice(r),r=dn-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),yn&&(e.e>M0||e.e<-M0))throw Error(H3+n)}else e.s=0,e.e=0,e.d=[0];return e}function Jt(e,t,n){var r,i,a,o,l,f,u,h,m=e.d;for(o=1,a=m[0];a>=10;a/=10)o++;if(r=t-o,r<0)r+=dn,i=t,u=m[h=0];else{if(h=Math.ceil((r+1)/dn),a=m.length,h>=a)return e;for(u=a=m[h],o=1;a>=10;a/=10)o++;r%=dn,i=r-dn+o}if(n!==void 0&&(a=ku(10,o-i-1),l=u/a%10|0,f=t<0||m[h+1]!==void 0||u%a,f=n<4?(l||f)&&(n==0||n==(e.s<0?3:2)):l>5||l==5&&(n==4||f||n==6&&(r>0?i>0?u/ku(10,o-i):0:m[h-1])%10&1||n==(e.s<0?8:7))),t<1||!m[0])return f?(a=qn(e),m.length=1,t=t-a-1,m[0]=ku(10,(dn-t%dn)%dn),e.e=Fd(-t/dn)||0):(m.length=1,m[0]=e.e=e.s=0),e;if(r==0?(m.length=h,a=1,h--):(m.length=h+1,a=ku(10,dn-r),m[h]=i>0?(u/ku(10,o-i)%ku(10,i)|0)*a:0),f)for(;;)if(h==0){(m[0]+=a)==sr&&(m[0]=1,++e.e);break}else{if(m[h]+=a,m[h]!=sr)break;m[h--]=0,a=1}for(r=m.length;m[--r]===0;)m.pop();if(yn&&(e.e>M0||e.e<-M0))throw Error(H3+qn(e));return e}function rF(e,t){var n,r,i,a,o,l,f,u,h,m,g=e.constructor,_=g.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new g(e),yn?Jt(t,_):t;if(f=e.d,m=t.d,r=t.e,u=e.e,f=f.slice(),o=u-r,o){for(h=o<0,h?(n=f,o=-o,l=m.length):(n=m,r=u,l=f.length),i=Math.max(Math.ceil(_/dn),l)+2,o>i&&(o=i,n.length=1),n.reverse(),i=o;i--;)n.push(0);n.reverse()}else{for(i=f.length,l=m.length,h=i<l,h&&(l=i),i=0;i<l;i++)if(f[i]!=m[i]){h=f[i]<m[i];break}o=0}for(h&&(n=f,f=m,m=n,t.s=-t.s),l=f.length,i=m.length-l;i>0;--i)f[l++]=0;for(i=m.length;i>o;){if(f[--i]<m[i]){for(a=i;a&&f[--a]===0;)f[a]=sr-1;--f[a],f[i]+=sr}f[i]-=m[i]}for(;f[--l]===0;)f.pop();for(;f[0]===0;f.shift())--r;return f[0]?(t.d=f,t.e=r,yn?Jt(t,_):t):new g(0)}function oc(e,t,n){var r,i=qn(e),a=Ja(e.d),o=a.length;return t?(n&&(r=n-o)>0?a=a.charAt(0)+"."+a.slice(1)+gl(r):o>1&&(a=a.charAt(0)+"."+a.slice(1)),a=a+(i<0?"e":"e+")+i):i<0?(a="0."+gl(-i-1)+a,n&&(r=n-o)>0&&(a+=gl(r))):i>=o?(a+=gl(i+1-o),n&&(r=n-i-1)>0&&(a=a+"."+gl(r))):((r=i+1)<o&&(a=a.slice(0,r)+"."+a.slice(r)),n&&(r=n-o)>0&&(i+1===o&&(a+="."),a+=gl(r))),e.s<0?"-"+a:a}function BD(e,t){if(e.length>t)return e.length=t,!0}function iF(e){var t,n,r;function i(a){var o=this;if(!(o instanceof i))return new i(a);if(o.constructor=i,a instanceof i){o.s=a.s,o.e=a.e,o.d=(a=a.d)?a.slice():a;return}if(typeof a=="number"){if(a*0!==0)throw Error(Yu+a);if(a>0)o.s=1;else if(a<0)a=-a,o.s=-1;else{o.s=0,o.e=0,o.d=[0];return}if(a===~~a&&a<1e7){o.e=0,o.d=[a];return}return $D(o,a.toString())}else if(typeof a!="string")throw Error(Yu+a);if(a.charCodeAt(0)===45?(a=a.slice(1),o.s=-1):o.s=1,Tme.test(a))$D(o,a);else throw Error(Yu+a)}if(i.prototype=nt,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=iF,i.config=i.set=jme,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 jme(e){if(!e||typeof e!="object")throw Error(na+"Object expected");var t,n,r,i=["precision",1,zd,"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(Fd(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(Yu+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Yu+n+": "+r);return this}var G3=iF(Ome);xi=new G3(1);const Zt=G3;function Pme(e){return Lme(e)||Nme(e)||Mme(e)||Rme()}function Rme(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Mme(e,t){if(e){if(typeof e=="string")return YE(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 YE(e,t)}}function Nme(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Lme(e){if(Array.isArray(e))return YE(e)}function YE(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 kme=function(t){return t},aF={},oF=function(t){return t===aF},UD=function(t){return function n(){return arguments.length===0||arguments.length===1&&oF(arguments.length<=0?void 0:arguments[0])?n:t.apply(void 0,arguments)}},Dme=function e(t,n){return t===1?n:UD(function(){for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];var o=i.filter(function(l){return l!==aF}).length;return o>=t?n.apply(void 0,i):e(t-o,UD(function(){for(var l=arguments.length,f=new Array(l),u=0;u<l;u++)f[u]=arguments[u];var h=i.map(function(m){return oF(m)?f.shift():m});return n.apply(void 0,Pme(h).concat(f))}))})},w1=function(t){return Dme(t.length,t)},KE=function(t,n){for(var r=[],i=t;i<n;++i)r[i-t]=i;return r},Ime=w1(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(n){return t[n]}).map(e)}),$me=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return kme;var i=n.reverse(),a=i[0],o=i.slice(1);return function(){return o.reduce(function(l,f){return f(l)},a.apply(void 0,arguments))}},ZE=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},sF=function(t){var n=null,r=null;return function(){for(var i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];return n&&a.every(function(l,f){return l===n[f]})||(n=a,r=t.apply(void 0,a)),r}};function Bme(e){var t;return e===0?t=1:t=Math.floor(new Zt(e).abs().log(10).toNumber())+1,t}function Ume(e,t,n){for(var r=new Zt(e),i=0,a=[];r.lt(t)&&i<1e5;)a.push(r.toNumber()),r=r.add(n),i++;return a}var zme=w1(function(e,t,n){var r=+e,i=+t;return r+n*(i-r)}),Fme=w1(function(e,t,n){var r=t-+e;return r=r||1/0,(n-e)/r}),qme=w1(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});const _1={rangeStep:Ume,getDigitCount:Bme,interpolateNumber:zme,uninterpolateNumber:Fme,uninterpolateTruncation:qme};function XE(e){return Gme(e)||Hme(e)||lF(e)||Vme()}function Vme(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Hme(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Gme(e){if(Array.isArray(e))return QE(e)}function ym(e,t){return Kme(e)||Yme(e,t)||lF(e,t)||Wme()}function Wme(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function lF(e,t){if(e){if(typeof e=="string")return QE(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 QE(e,t)}}function QE(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 Yme(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,a=void 0;try{for(var o=e[Symbol.iterator](),l;!(r=(l=o.next()).done)&&(n.push(l.value),!(t&&n.length===t));r=!0);}catch(f){i=!0,a=f}finally{try{!r&&o.return!=null&&o.return()}finally{if(i)throw a}}return n}}function Kme(e){if(Array.isArray(e))return e}function uF(e){var t=ym(e,2),n=t[0],r=t[1],i=n,a=r;return n>r&&(i=r,a=n),[i,a]}function cF(e,t,n){if(e.lte(0))return new Zt(0);var r=_1.getDigitCount(e.toNumber()),i=new Zt(10).pow(r),a=e.div(i),o=r!==1?.05:.1,l=new Zt(Math.ceil(a.div(o).toNumber())).add(n).mul(o),f=l.mul(i);return t?f:new Zt(Math.ceil(f))}function Zme(e,t,n){var r=1,i=new Zt(e);if(!i.isint()&&n){var a=Math.abs(e);a<1?(r=new Zt(10).pow(_1.getDigitCount(e)-1),i=new Zt(Math.floor(i.div(r).toNumber())).mul(r)):a>1&&(i=new Zt(Math.floor(e)))}else e===0?i=new Zt(Math.floor((t-1)/2)):n||(i=new Zt(Math.floor(e)));var o=Math.floor((t-1)/2),l=$me(Ime(function(f){return i.add(new Zt(f-o).mul(r)).toNumber()}),KE);return l(0,t)}function fF(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 Zt(0),tickMin:new Zt(0),tickMax:new Zt(0)};var a=cF(new Zt(t).sub(e).div(n-1),r,i),o;e<=0&&t>=0?o=new Zt(0):(o=new Zt(e).add(t).div(2),o=o.sub(new Zt(o).mod(a)));var l=Math.ceil(o.sub(e).div(a).toNumber()),f=Math.ceil(new Zt(t).sub(o).div(a).toNumber()),u=l+f+1;return u>n?fF(e,t,n,r,i+1):(u<n&&(f=t>0?f+(n-u):f,l=t>0?l:l+(n-u)),{step:a,tickMin:o.sub(new Zt(l).mul(a)),tickMax:o.add(new Zt(f).mul(a))})}function Xme(e){var t=ym(e,2),n=t[0],r=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=Math.max(i,2),l=uF([n,r]),f=ym(l,2),u=f[0],h=f[1];if(u===-1/0||h===1/0){var m=h===1/0?[u].concat(XE(KE(0,i-1).map(function(){return 1/0}))):[].concat(XE(KE(0,i-1).map(function(){return-1/0})),[h]);return n>r?ZE(m):m}if(u===h)return Zme(u,i,a);var g=fF(u,h,o,a),_=g.step,x=g.tickMin,b=g.tickMax,S=_1.rangeStep(x,b.add(new Zt(.1).mul(_)),_);return n>r?ZE(S):S}function Qme(e,t){var n=ym(e,2),r=n[0],i=n[1],a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=uF([r,i]),l=ym(o,2),f=l[0],u=l[1];if(f===-1/0||u===1/0)return[r,i];if(f===u)return[f];var h=Math.max(t,2),m=cF(new Zt(u).sub(f).div(h-1),a,0),g=[].concat(XE(_1.rangeStep(new Zt(f),new Zt(u).sub(new Zt(.99).mul(m)),m)),[u]);return r>i?ZE(g):g}var Jme=sF(Xme),ege=sF(Qme),tge="Invariant failed";function sc(e,t){throw new Error(tge)}var nge=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function nd(e){"@babel/helpers - typeof";return nd=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},nd(e)}function N0(){return N0=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},N0.apply(this,arguments)}function rge(e,t){return sge(e)||oge(e,t)||age(e,t)||ige()}function ige(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function age(e,t){if(e){if(typeof e=="string")return zD(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 zD(e,t)}}function zD(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 oge(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function sge(e){if(Array.isArray(e))return e}function lge(e,t){if(e==null)return{};var n=uge(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function uge(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 cge(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function fge(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,pF(r.key),r)}}function dge(e,t,n){return t&&fge(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function hge(e,t,n){return t=L0(t),pge(e,dF()?Reflect.construct(t,n||[],L0(e).constructor):t.apply(e,n))}function pge(e,t){if(t&&(nd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return mge(e)}function mge(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function dF(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(dF=function(){return!!e})()}function L0(e){return L0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},L0(e)}function gge(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&&JE(e,t)}function JE(e,t){return JE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},JE(e,t)}function hF(e,t,n){return t=pF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pF(e){var t=vge(e,"string");return nd(t)=="symbol"?t:t+""}function vge(e,t){if(nd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(nd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var qd=function(e){function t(){return cge(this,t),hge(this,t,arguments)}return gge(t,e),dge(t,[{key:"render",value:function(){var r=this.props,i=r.offset,a=r.layout,o=r.width,l=r.dataKey,f=r.data,u=r.dataPointFormatter,h=r.xAxis,m=r.yAxis,g=lge(r,nge),_=ot(g,!1);this.props.direction==="x"&&h.type!=="number"&&sc();var x=f.map(function(b){var S=u(b,l),C=S.x,A=S.y,O=S.value,P=S.errorVal;if(!P)return null;var j=[],R,U;if(Array.isArray(P)){var V=rge(P,2);R=V[0],U=V[1]}else R=U=P;if(a==="vertical"){var Y=h.scale,K=A+i,W=K+o,ee=K-o,ie=Y(O-R),X=Y(O+U);j.push({x1:X,y1:W,x2:X,y2:ee}),j.push({x1:ie,y1:K,x2:X,y2:K}),j.push({x1:ie,y1:W,x2:ie,y2:ee})}else if(a==="horizontal"){var ne=m.scale,H=C+i,I=H-o,D=H+o,z=ne(O-R),N=ne(O+U);j.push({x1:I,y1:N,x2:D,y2:N}),j.push({x1:H,y1:z,x2:H,y2:N}),j.push({x1:I,y1:z,x2:D,y2:z})}return pe.createElement(St,N0({className:"recharts-errorBar",key:"bar-".concat(j.map(function(B){return"".concat(B.x1,"-").concat(B.x2,"-").concat(B.y1,"-").concat(B.y2)}))},_),j.map(function(B){return pe.createElement("line",N0({},B,{key:"line-".concat(B.x1,"-").concat(B.x2,"-").concat(B.y1,"-").concat(B.y2)}))}))});return pe.createElement(St,{className:"recharts-errorBars"},x)}}])}(pe.Component);hF(qd,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});hF(qd,"displayName","ErrorBar");function bm(e){"@babel/helpers - typeof";return bm=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},bm(e)}function FD(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 Tu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?FD(Object(n),!0).forEach(function(r){yge(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function yge(e,t,n){return t=bge(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bge(e){var t=wge(e,"string");return bm(t)=="symbol"?t:t+""}function wge(e,t){if(bm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var mF=function(t){var n=t.children,r=t.formattedGraphicalItems,i=t.legendWidth,a=t.legendContent,o=_i(n,Df);if(!o)return null;var l=Df.defaultProps,f=l!==void 0?Tu(Tu({},l),o.props):{},u;return o.props&&o.props.payload?u=o.props&&o.props.payload:a==="children"?u=(r||[]).reduce(function(h,m){var g=m.item,_=m.props,x=_.sectors||_.data||[];return h.concat(x.map(function(b){return{type:o.props.iconType||g.props.legendType,value:b.name,color:b.fill,payload:b}}))},[]):u=(r||[]).map(function(h){var m=h.item,g=m.type.defaultProps,_=g!==void 0?Tu(Tu({},g),m.props):{},x=_.dataKey,b=_.name,S=_.legendType,C=_.hide;return{inactive:C,dataKey:x,type:f.iconType||S||"square",color:W3(m),value:b||x,payload:_}}),Tu(Tu(Tu({},f),Df.getWithHeight(o,i)),{},{payload:u,item:o})};function wm(e){"@babel/helpers - typeof";return wm=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},wm(e)}function qD(e){return Cge(e)||Sge(e)||xge(e)||_ge()}function _ge(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xge(e,t){if(e){if(typeof e=="string")return eO(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 eO(e,t)}}function Sge(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Cge(e){if(Array.isArray(e))return eO(e)}function eO(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 VD(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 On(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?VD(Object(n),!0).forEach(function(r){$f(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):VD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $f(e,t,n){return t=Age(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Age(e){var t=Ege(e,"string");return wm(t)=="symbol"?t:t+""}function Ege(e,t){if(wm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(wm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function hn(e,t,n){return pt(e)||pt(t)?n:Kn(t)?Ti(e,t,n):ht(t)?t(e):n}function Dp(e,t,n,r){var i=Cme(e,function(l){return hn(l,t)});if(n==="number"){var a=i.filter(function(l){return Ze(l)||parseFloat(l)});return a.length?[b1(a),wl(a)]:[1/0,-1/0]}var o=r?i.filter(function(l){return!pt(l)}):i;return o.map(function(l){return Kn(l)||l instanceof Date?l:""})}var Oge=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,a=arguments.length>3?arguments[3]:void 0,o=-1,l=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(l<=1)return 0;if(a&&a.axisType==="angleAxis"&&Math.abs(Math.abs(a.range[1]-a.range[0])-360)<=1e-6)for(var f=a.range,u=0;u<l;u++){var h=u>0?i[u-1].coordinate:i[l-1].coordinate,m=i[u].coordinate,g=u>=l-1?i[0].coordinate:i[u+1].coordinate,_=void 0;if(Fr(m-h)!==Fr(g-m)){var x=[];if(Fr(g-m)===Fr(f[1]-f[0])){_=g;var b=m+f[1]-f[0];x[0]=Math.min(b,(b+h)/2),x[1]=Math.max(b,(b+h)/2)}else{_=h;var S=g+f[1]-f[0];x[0]=Math.min(m,(S+m)/2),x[1]=Math.max(m,(S+m)/2)}var C=[Math.min(m,(_+m)/2),Math.max(m,(_+m)/2)];if(t>C[0]&&t<=C[1]||t>=x[0]&&t<=x[1]){o=i[u].index;break}}else{var A=Math.min(h,g),O=Math.max(h,g);if(t>(A+m)/2&&t<=(O+m)/2){o=i[u].index;break}}}else for(var P=0;P<l;P++)if(P===0&&t<=(r[P].coordinate+r[P+1].coordinate)/2||P>0&&P<l-1&&t>(r[P].coordinate+r[P-1].coordinate)/2&&t<=(r[P].coordinate+r[P+1].coordinate)/2||P===l-1&&t>(r[P].coordinate+r[P-1].coordinate)/2){o=r[P].index;break}return o},W3=function(t){var n,r=t,i=r.type.displayName,a=(n=t.type)!==null&&n!==void 0&&n.defaultProps?On(On({},t.type.defaultProps),t.props):t.props,o=a.stroke,l=a.fill,f;switch(i){case"Line":f=o;break;case"Area":case"Radar":f=o&&o!=="none"?o:l;break;default:f=l;break}return f},Tge=function(t){var n=t.barSize,r=t.totalSize,i=t.stackGroups,a=i===void 0?{}:i;if(!a)return{};for(var o={},l=Object.keys(a),f=0,u=l.length;f<u;f++)for(var h=a[l[f]].stackGroups,m=Object.keys(h),g=0,_=m.length;g<_;g++){var x=h[m[g]],b=x.items,S=x.cateAxisId,C=b.filter(function(U){return Jo(U.type).indexOf("Bar")>=0});if(C&&C.length){var A=C[0].type.defaultProps,O=A!==void 0?On(On({},A),C[0].props):C[0].props,P=O.barSize,j=O[S];o[j]||(o[j]=[]);var R=pt(P)?n:P;o[j].push({item:C[0],stackList:C.slice(1),barSize:pt(R)?void 0:qr(R,r,0)})}}return o},jge=function(t){var n=t.barGap,r=t.barCategoryGap,i=t.bandSize,a=t.sizeList,o=a===void 0?[]:a,l=t.maxBarSize,f=o.length;if(f<1)return null;var u=qr(n,i,0,!0),h,m=[];if(o[0].barSize===+o[0].barSize){var g=!1,_=i/f,x=o.reduce(function(P,j){return P+j.barSize||0},0);x+=(f-1)*u,x>=i&&(x-=(f-1)*u,u=0),x>=i&&_>0&&(g=!0,_*=.9,x=f*_);var b=(i-x)/2>>0,S={offset:b-u,size:0};h=o.reduce(function(P,j){var R={item:j.item,position:{offset:S.offset+S.size+u,size:g?_:j.barSize}},U=[].concat(qD(P),[R]);return S=U[U.length-1].position,j.stackList&&j.stackList.length&&j.stackList.forEach(function(V){U.push({item:V,position:S})}),U},m)}else{var C=qr(r,i,0,!0);i-2*C-(f-1)*u<=0&&(u=0);var A=(i-2*C-(f-1)*u)/f;A>1&&(A>>=0);var O=l===+l?Math.min(A,l):A;h=o.reduce(function(P,j,R){var U=[].concat(qD(P),[{item:j.item,position:{offset:C+(A+u)*R+(A-O)/2,size:O}}]);return j.stackList&&j.stackList.length&&j.stackList.forEach(function(V){U.push({item:V,position:U[U.length-1].position})}),U},m)}return h},Pge=function(t,n,r,i){var a=r.children,o=r.width,l=r.margin,f=o-(l.left||0)-(l.right||0),u=mF({children:a,legendWidth:f});if(u){var h=i||{},m=h.width,g=h.height,_=u.align,x=u.verticalAlign,b=u.layout;if((b==="vertical"||b==="horizontal"&&x==="middle")&&_!=="center"&&Ze(t[_]))return On(On({},t),{},$f({},_,t[_]+(m||0)));if((b==="horizontal"||b==="vertical"&&_==="center")&&x!=="middle"&&Ze(t[x]))return On(On({},t),{},$f({},x,t[x]+(g||0)))}return t},Rge=function(t,n,r){return pt(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},gF=function(t,n,r,i,a){var o=n.props.children,l=Gr(o,qd).filter(function(u){return Rge(i,a,u.props.direction)});if(l&&l.length){var f=l.map(function(u){return u.props.dataKey});return t.reduce(function(u,h){var m=hn(h,r);if(pt(m))return u;var g=Array.isArray(m)?[b1(m),wl(m)]:[m,m],_=f.reduce(function(x,b){var S=hn(h,b,0),C=g[0]-Math.abs(Array.isArray(S)?S[0]:S),A=g[1]+Math.abs(Array.isArray(S)?S[1]:S);return[Math.min(C,x[0]),Math.max(A,x[1])]},[1/0,-1/0]);return[Math.min(_[0],u[0]),Math.max(_[1],u[1])]},[1/0,-1/0])}return null},Mge=function(t,n,r,i,a){var o=n.map(function(l){return gF(t,l,r,a,i)}).filter(function(l){return!pt(l)});return o&&o.length?o.reduce(function(l,f){return[Math.min(l[0],f[0]),Math.max(l[1],f[1])]},[1/0,-1/0]):null},vF=function(t,n,r,i,a){var o=n.map(function(f){var u=f.props.dataKey;return r==="number"&&u&&gF(t,f,u,i)||Dp(t,u,r,a)});if(r==="number")return o.reduce(function(f,u){return[Math.min(f[0],u[0]),Math.max(f[1],u[1])]},[1/0,-1/0]);var l={};return o.reduce(function(f,u){for(var h=0,m=u.length;h<m;h++)l[u[h]]||(l[u[h]]=!0,f.push(u[h]));return f},[])},yF=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},bF=function(t,n,r,i){if(i)return t.map(function(f){return f.coordinate});var a,o,l=t.map(function(f){return f.coordinate===n&&(a=!0),f.coordinate===r&&(o=!0),f.coordinate});return a||l.push(n),o||l.push(r),l},Zo=function(t,n,r){if(!t)return null;var i=t.scale,a=t.duplicateDomain,o=t.type,l=t.range,f=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,u=(n||r)&&o==="category"&&i.bandwidth?i.bandwidth()/f:0;if(u=t.axisType==="angleAxis"&&(l==null?void 0:l.length)>=2?Fr(l[0]-l[1])*2*u:u,n&&(t.ticks||t.niceTicks)){var h=(t.ticks||t.niceTicks).map(function(m){var g=a?a.indexOf(m):m;return{coordinate:i(g)+u,value:m,offset:u}});return h.filter(function(m){return!$d(m.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(m,g){return{coordinate:i(m)+u,value:m,index:g,offset:u}}):i.ticks&&!r?i.ticks(t.tickCount).map(function(m){return{coordinate:i(m)+u,value:m,offset:u}}):i.domain().map(function(m,g){return{coordinate:i(m)+u,value:a?a[m]:m,index:g,offset:u}})},HC=new WeakMap,ly=function(t,n){if(typeof n!="function")return t;HC.has(t)||HC.set(t,new WeakMap);var r=HC.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},wF=function(t,n,r){var i=t.scale,a=t.type,o=t.layout,l=t.axisType;if(i==="auto")return o==="radial"&&l==="radiusAxis"?{scale:dm(),realScaleType:"band"}:o==="radial"&&l==="angleAxis"?{scale:T0(),realScaleType:"linear"}:a==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:kp(),realScaleType:"point"}:a==="category"?{scale:dm(),realScaleType:"band"}:{scale:T0(),realScaleType:"linear"};if(ic(i)){var f="scale".concat(i1(i));return{scale:(jD[f]||kp)(),realScaleType:jD[f]?f:"point"}}return ht(i)?{scale:i}:{scale:kp(),realScaleType:"point"}},HD=1e-4,_F=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,i=t.range(),a=Math.min(i[0],i[1])-HD,o=Math.max(i[0],i[1])+HD,l=t(n[0]),f=t(n[r-1]);(l<a||l>o||f<a||f>o)&&t.domain([n[0],n[r-1]])}},Nge=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},Lge=function(t,n){if(!n||n.length!==2||!Ze(n[0])||!Ze(n[1]))return t;var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]),a=[t[0],t[1]];return(!Ze(t[0])||t[0]<r)&&(a[0]=r),(!Ze(t[1])||t[1]>i)&&(a[1]=i),a[0]>i&&(a[0]=i),a[1]<r&&(a[1]=r),a},kge=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var a=0,o=0,l=0;l<n;++l){var f=$d(t[l][r][1])?t[l][r][0]:t[l][r][1];f>=0?(t[l][r][0]=a,t[l][r][1]=a+f,a=t[l][r][1]):(t[l][r][0]=o,t[l][r][1]=o+f,o=t[l][r][1])}},Dge=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var a=0,o=0;o<n;++o){var l=$d(t[o][r][1])?t[o][r][0]:t[o][r][1];l>=0?(t[o][r][0]=a,t[o][r][1]=a+l,a=t[o][r][1]):(t[o][r][0]=0,t[o][r][1]=0)}},Ige={sign:kge,expand:Sue,none:Yf,silhouette:Cue,wiggle:Aue,positive:Dge},$ge=function(t,n,r){var i=n.map(function(l){return l.props.dataKey}),a=Ige[r],o=xue().keys(i).value(function(l,f){return+hn(l,f,0)}).order(PE).offset(a);return o(t)},Bge=function(t,n,r,i,a,o){if(!t)return null;var l=o?n.reverse():n,f={},u=l.reduce(function(m,g){var _,x=(_=g.type)!==null&&_!==void 0&&_.defaultProps?On(On({},g.type.defaultProps),g.props):g.props,b=x.stackId,S=x.hide;if(S)return m;var C=x[r],A=m[C]||{hasStack:!1,stackGroups:{}};if(Kn(b)){var O=A.stackGroups[b]||{numericAxisId:r,cateAxisId:i,items:[]};O.items.push(g),A.hasStack=!0,A.stackGroups[b]=O}else A.stackGroups[Yl("_stackId_")]={numericAxisId:r,cateAxisId:i,items:[g]};return On(On({},m),{},$f({},C,A))},f),h={};return Object.keys(u).reduce(function(m,g){var _=u[g];if(_.hasStack){var x={};_.stackGroups=Object.keys(_.stackGroups).reduce(function(b,S){var C=_.stackGroups[S];return On(On({},b),{},$f({},S,{numericAxisId:r,cateAxisId:i,items:C.items,stackedData:$ge(t,C.items,a)}))},x)}return On(On({},m),{},$f({},g,_))},h)},xF=function(t,n){var r=n.realScaleType,i=n.type,a=n.tickCount,o=n.originalDomain,l=n.allowDecimals,f=r||n.scale;if(f!=="auto"&&f!=="linear")return null;if(a&&i==="number"&&o&&(o[0]==="auto"||o[1]==="auto")){var u=t.domain();if(!u.length)return null;var h=Jme(u,a,l);return t.domain([b1(h),wl(h)]),{niceTicks:h}}if(a&&i==="number"){var m=t.domain(),g=ege(m,a,l);return{niceTicks:g}}return null};function rd(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,a=e.index,o=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!pt(i[t.dataKey])){var l=c0(n,"value",i[t.dataKey]);if(l)return l.coordinate+r/2}return n[a]?n[a].coordinate+r/2:null}var f=hn(i,pt(o)?t.dataKey:o);return pt(f)?null:t.scale(f)}var GD=function(t){var n=t.axis,r=t.ticks,i=t.offset,a=t.bandSize,o=t.entry,l=t.index;if(n.type==="category")return r[l]?r[l].coordinate+i:null;var f=hn(o,n.dataKey,n.domain[l]);return pt(f)?null:n.scale(f)-a/2+i},Uge=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var i=Math.min(r[0],r[1]),a=Math.max(r[0],r[1]);return i<=0&&a>=0?0:a<0?a:i}return r[0]},zge=function(t,n){var r,i=(r=t.type)!==null&&r!==void 0&&r.defaultProps?On(On({},t.type.defaultProps),t.props):t.props,a=i.stackId;if(Kn(a)){var o=n[a];if(o){var l=o.items.indexOf(t);return l>=0?o.stackedData[l]:null}}return null},Fge=function(t){return t.reduce(function(n,r){return[b1(r.concat([n[0]]).filter(Ze)),wl(r.concat([n[1]]).filter(Ze))]},[1/0,-1/0])},SF=function(t,n,r){return Object.keys(t).reduce(function(i,a){var o=t[a],l=o.stackedData,f=l.reduce(function(u,h){var m=Fge(h.slice(n,r+1));return[Math.min(u[0],m[0]),Math.max(u[1],m[1])]},[1/0,-1/0]);return[Math.min(f[0],i[0]),Math.max(f[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},WD=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,YD=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,tO=function(t,n,r){if(ht(t))return t(n,r);if(!Array.isArray(t))return n;var i=[];if(Ze(t[0]))i[0]=r?t[0]:Math.min(t[0],n[0]);else if(WD.test(t[0])){var a=+WD.exec(t[0])[1];i[0]=n[0]-a}else ht(t[0])?i[0]=t[0](n[0]):i[0]=n[0];if(Ze(t[1]))i[1]=r?t[1]:Math.max(t[1],n[1]);else if(YD.test(t[1])){var o=+YD.exec(t[1])[1];i[1]=n[1]+o}else ht(t[1])?i[1]=t[1](n[1]):i[1]=n[1];return i},k0=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 a=_3(n,function(m){return m.coordinate}),o=1/0,l=1,f=a.length;l<f;l++){var u=a[l],h=a[l-1];o=Math.min((u.coordinate||0)-(h.coordinate||0),o)}return o===1/0?0:o}return r?void 0:0},KD=function(t,n,r){return!t||!t.length||Ul(t,Ti(r,"type.defaultProps.domain"))?n:t},CF=function(t,n){var r=t.type.defaultProps?On(On({},t.type.defaultProps),t.props):t.props,i=r.dataKey,a=r.name,o=r.unit,l=r.formatter,f=r.tooltipType,u=r.chartType,h=r.hide;return On(On({},ot(t,!1)),{},{dataKey:i,unit:o,formatter:l,name:a||i,color:W3(t),value:hn(n,i),type:f,payload:n,chartType:u,hide:h})};function _m(e){"@babel/helpers - typeof";return _m=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},_m(e)}function ZD(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 Wo(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ZD(Object(n),!0).forEach(function(r){AF(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ZD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function AF(e,t,n){return t=qge(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qge(e){var t=Vge(e,"string");return _m(t)=="symbol"?t:t+""}function Vge(e,t){if(_m(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_m(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Hge(e,t){return Kge(e)||Yge(e,t)||Wge(e,t)||Gge()}function Gge(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Wge(e,t){if(e){if(typeof e=="string")return XD(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 XD(e,t)}}function XD(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 Yge(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function Kge(e){if(Array.isArray(e))return e}var D0=Math.PI/180,Zge=function(t){return t*180/Math.PI},cn=function(t,n,r,i){return{x:t+Math.cos(-D0*i)*r,y:n+Math.sin(-D0*i)*r}},EF=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(t-(r.left||0)-(r.right||0)),Math.abs(n-(r.top||0)-(r.bottom||0)))/2},Xge=function(t,n,r,i,a){var o=t.width,l=t.height,f=t.startAngle,u=t.endAngle,h=qr(t.cx,o,o/2),m=qr(t.cy,l,l/2),g=EF(o,l,r),_=qr(t.innerRadius,g,0),x=qr(t.outerRadius,g,g*.8),b=Object.keys(n);return b.reduce(function(S,C){var A=n[C],O=A.domain,P=A.reversed,j;if(pt(A.range))i==="angleAxis"?j=[f,u]:i==="radiusAxis"&&(j=[_,x]),P&&(j=[j[1],j[0]]);else{j=A.range;var R=j,U=Hge(R,2);f=U[0],u=U[1]}var V=wF(A,a),Y=V.realScaleType,K=V.scale;K.domain(O).range(j),_F(K);var W=xF(K,Wo(Wo({},A),{},{realScaleType:Y})),ee=Wo(Wo(Wo({},A),W),{},{range:j,radius:x,realScaleType:Y,scale:K,cx:h,cy:m,innerRadius:_,outerRadius:x,startAngle:f,endAngle:u});return Wo(Wo({},S),{},AF({},C,ee))},{})},Qge=function(t,n){var r=t.x,i=t.y,a=n.x,o=n.y;return Math.sqrt(Math.pow(r-a,2)+Math.pow(i-o,2))},Jge=function(t,n){var r=t.x,i=t.y,a=n.cx,o=n.cy,l=Qge({x:r,y:i},{x:a,y:o});if(l<=0)return{radius:l};var f=(r-a)/l,u=Math.acos(f);return i>o&&(u=2*Math.PI-u),{radius:l,angle:Zge(u),angleInRadian:u}},eve=function(t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),a=Math.floor(r/360),o=Math.min(i,a);return{startAngle:n-o*360,endAngle:r-o*360}},tve=function(t,n){var r=n.startAngle,i=n.endAngle,a=Math.floor(r/360),o=Math.floor(i/360),l=Math.min(a,o);return t+l*360},QD=function(t,n){var r=t.x,i=t.y,a=Jge({x:r,y:i},n),o=a.radius,l=a.angle,f=n.innerRadius,u=n.outerRadius;if(o<f||o>u)return!1;if(o===0)return!0;var h=eve(n),m=h.startAngle,g=h.endAngle,_=l,x;if(m<=g){for(;_>g;)_-=360;for(;_<m;)_+=360;x=_>=m&&_<=g}else{for(;_>m;)_-=360;for(;_<g;)_+=360;x=_>=g&&_<=m}return x?Wo(Wo({},n),{},{radius:o,angle:tve(_,n)}):null},OF=function(t){return!M.isValidElement(t)&&!ht(t)&&typeof t!="boolean"?t.className:""};function xm(e){"@babel/helpers - typeof";return xm=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},xm(e)}var nve=["offset"];function rve(e){return sve(e)||ove(e)||ave(e)||ive()}function ive(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ave(e,t){if(e){if(typeof e=="string")return nO(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 nO(e,t)}}function ove(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function sve(e){if(Array.isArray(e))return nO(e)}function nO(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 lve(e,t){if(e==null)return{};var n=uve(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function uve(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 JD(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 Yn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?JD(Object(n),!0).forEach(function(r){cve(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function cve(e,t,n){return t=fve(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fve(e){var t=dve(e,"string");return xm(t)=="symbol"?t:t+""}function dve(e,t){if(xm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(xm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Sm(){return Sm=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},Sm.apply(this,arguments)}var hve=function(t){var n=t.value,r=t.formatter,i=pt(t.children)?n:t.children;return ht(r)?r(i):i},pve=function(t,n){var r=Fr(n-t),i=Math.min(Math.abs(n-t),360);return r*i},mve=function(t,n,r){var i=t.position,a=t.viewBox,o=t.offset,l=t.className,f=a,u=f.cx,h=f.cy,m=f.innerRadius,g=f.outerRadius,_=f.startAngle,x=f.endAngle,b=f.clockWise,S=(m+g)/2,C=pve(_,x),A=C>=0?1:-1,O,P;i==="insideStart"?(O=_+A*o,P=b):i==="insideEnd"?(O=x-A*o,P=!b):i==="end"&&(O=x+A*o,P=b),P=C<=0?P:!P;var j=cn(u,h,S,O),R=cn(u,h,S,O+(P?1:-1)*359),U="M".concat(j.x,",").concat(j.y,`
|
||
A`).concat(S,",").concat(S,",0,1,").concat(P?0:1,`,
|
||
`).concat(R.x,",").concat(R.y),V=pt(t.id)?Yl("recharts-radial-line-"):t.id;return pe.createElement("text",Sm({},r,{dominantBaseline:"central",className:be("recharts-radial-bar-label",l)}),pe.createElement("defs",null,pe.createElement("path",{id:V,d:U})),pe.createElement("textPath",{xlinkHref:"#".concat(V)},n))},gve=function(t){var n=t.viewBox,r=t.offset,i=t.position,a=n,o=a.cx,l=a.cy,f=a.innerRadius,u=a.outerRadius,h=a.startAngle,m=a.endAngle,g=(h+m)/2;if(i==="outside"){var _=cn(o,l,u+r,g),x=_.x,b=_.y;return{x,y:b,textAnchor:x>=o?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:o,y:l,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:o,y:l,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:o,y:l,textAnchor:"middle",verticalAnchor:"end"};var S=(f+u)/2,C=cn(o,l,S,g),A=C.x,O=C.y;return{x:A,y:O,textAnchor:"middle",verticalAnchor:"middle"}},vve=function(t){var n=t.viewBox,r=t.parentViewBox,i=t.offset,a=t.position,o=n,l=o.x,f=o.y,u=o.width,h=o.height,m=h>=0?1:-1,g=m*i,_=m>0?"end":"start",x=m>0?"start":"end",b=u>=0?1:-1,S=b*i,C=b>0?"end":"start",A=b>0?"start":"end";if(a==="top"){var O={x:l+u/2,y:f-m*i,textAnchor:"middle",verticalAnchor:_};return Yn(Yn({},O),r?{height:Math.max(f-r.y,0),width:u}:{})}if(a==="bottom"){var P={x:l+u/2,y:f+h+g,textAnchor:"middle",verticalAnchor:x};return Yn(Yn({},P),r?{height:Math.max(r.y+r.height-(f+h),0),width:u}:{})}if(a==="left"){var j={x:l-S,y:f+h/2,textAnchor:C,verticalAnchor:"middle"};return Yn(Yn({},j),r?{width:Math.max(j.x-r.x,0),height:h}:{})}if(a==="right"){var R={x:l+u+S,y:f+h/2,textAnchor:A,verticalAnchor:"middle"};return Yn(Yn({},R),r?{width:Math.max(r.x+r.width-R.x,0),height:h}:{})}var U=r?{width:u,height:h}:{};return a==="insideLeft"?Yn({x:l+S,y:f+h/2,textAnchor:A,verticalAnchor:"middle"},U):a==="insideRight"?Yn({x:l+u-S,y:f+h/2,textAnchor:C,verticalAnchor:"middle"},U):a==="insideTop"?Yn({x:l+u/2,y:f+g,textAnchor:"middle",verticalAnchor:x},U):a==="insideBottom"?Yn({x:l+u/2,y:f+h-g,textAnchor:"middle",verticalAnchor:_},U):a==="insideTopLeft"?Yn({x:l+S,y:f+g,textAnchor:A,verticalAnchor:x},U):a==="insideTopRight"?Yn({x:l+u-S,y:f+g,textAnchor:C,verticalAnchor:x},U):a==="insideBottomLeft"?Yn({x:l+S,y:f+h-g,textAnchor:A,verticalAnchor:_},U):a==="insideBottomRight"?Yn({x:l+u-S,y:f+h-g,textAnchor:C,verticalAnchor:_},U):Id(a)&&(Ze(a.x)||Fu(a.x))&&(Ze(a.y)||Fu(a.y))?Yn({x:l+qr(a.x,u),y:f+qr(a.y,h),textAnchor:"end",verticalAnchor:"end"},U):Yn({x:l+u/2,y:f+h/2,textAnchor:"middle",verticalAnchor:"middle"},U)},yve=function(t){return"cx"in t&&Ze(t.cx)};function lr(e){var t=e.offset,n=t===void 0?5:t,r=lve(e,nve),i=Yn({offset:n},r),a=i.viewBox,o=i.position,l=i.value,f=i.children,u=i.content,h=i.className,m=h===void 0?"":h,g=i.textBreakAll;if(!a||pt(l)&&pt(f)&&!M.isValidElement(u)&&!ht(u))return null;if(M.isValidElement(u))return M.cloneElement(u,i);var _;if(ht(u)){if(_=M.createElement(u,i),M.isValidElement(_))return _}else _=hve(i);var x=yve(a),b=ot(i,!0);if(x&&(o==="insideStart"||o==="insideEnd"||o==="end"))return mve(i,_,b);var S=x?gve(i):vve(i);return pe.createElement(ac,Sm({className:be("recharts-label",m)},b,S,{breakAll:g}),_)}lr.displayName="Label";var TF=function(t){var n=t.cx,r=t.cy,i=t.angle,a=t.startAngle,o=t.endAngle,l=t.r,f=t.radius,u=t.innerRadius,h=t.outerRadius,m=t.x,g=t.y,_=t.top,x=t.left,b=t.width,S=t.height,C=t.clockWise,A=t.labelViewBox;if(A)return A;if(Ze(b)&&Ze(S)){if(Ze(m)&&Ze(g))return{x:m,y:g,width:b,height:S};if(Ze(_)&&Ze(x))return{x:_,y:x,width:b,height:S}}return Ze(m)&&Ze(g)?{x:m,y:g,width:0,height:0}:Ze(n)&&Ze(r)?{cx:n,cy:r,startAngle:a||i||0,endAngle:o||i||0,innerRadius:u||0,outerRadius:h||f||l||0,clockWise:C}:t.viewBox?t.viewBox:{}},bve=function(t,n){return t?t===!0?pe.createElement(lr,{key:"label-implicit",viewBox:n}):Kn(t)?pe.createElement(lr,{key:"label-implicit",viewBox:n,value:t}):M.isValidElement(t)?t.type===lr?M.cloneElement(t,{key:"label-implicit",viewBox:n}):pe.createElement(lr,{key:"label-implicit",content:t,viewBox:n}):ht(t)?pe.createElement(lr,{key:"label-implicit",content:t,viewBox:n}):Id(t)?pe.createElement(lr,Sm({viewBox:n},t,{key:"label-implicit"})):null:null},wve=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,a=TF(t),o=Gr(i,lr).map(function(f,u){return M.cloneElement(f,{viewBox:n||a,key:"label-".concat(u)})});if(!r)return o;var l=bve(t.label,n||a);return[l].concat(rve(o))};lr.parseViewBox=TF;lr.renderCallByParent=wve;var GC,e8;function _ve(){if(e8)return GC;e8=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return GC=e,GC}var xve=_ve();const Sve=zt(xve);function Cm(e){"@babel/helpers - typeof";return Cm=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},Cm(e)}var Cve=["valueAccessor"],Ave=["data","dataKey","clockWise","id","textBreakAll"];function Eve(e){return Pve(e)||jve(e)||Tve(e)||Ove()}function Ove(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Tve(e,t){if(e){if(typeof e=="string")return rO(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 rO(e,t)}}function jve(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Pve(e){if(Array.isArray(e))return rO(e)}function rO(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 I0(){return I0=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},I0.apply(this,arguments)}function t8(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 n8(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?t8(Object(n),!0).forEach(function(r){Rve(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):t8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Rve(e,t,n){return t=Mve(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mve(e){var t=Nve(e,"string");return Cm(t)=="symbol"?t:t+""}function Nve(e,t){if(Cm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Cm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function r8(e,t){if(e==null)return{};var n=Lve(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Lve(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 kve=function(t){return Array.isArray(t.value)?Sve(t.value):t.value};function xa(e){var t=e.valueAccessor,n=t===void 0?kve:t,r=r8(e,Cve),i=r.data,a=r.dataKey,o=r.clockWise,l=r.id,f=r.textBreakAll,u=r8(r,Ave);return!i||!i.length?null:pe.createElement(St,{className:"recharts-label-list"},i.map(function(h,m){var g=pt(a)?n(h,m):hn(h&&h.payload,a),_=pt(l)?{}:{id:"".concat(l,"-").concat(m)};return pe.createElement(lr,I0({},ot(h,!0),u,_,{parentViewBox:h.parentViewBox,value:g,textBreakAll:f,viewBox:lr.parseViewBox(pt(o)?h:n8(n8({},h),{},{clockWise:o})),key:"label-".concat(m),index:m}))}))}xa.displayName="LabelList";function Dve(e,t){return e?e===!0?pe.createElement(xa,{key:"labelList-implicit",data:t}):pe.isValidElement(e)||ht(e)?pe.createElement(xa,{key:"labelList-implicit",data:t,content:e}):Id(e)?pe.createElement(xa,I0({data:t},e,{key:"labelList-implicit"})):null:null}function Ive(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=Gr(r,xa).map(function(o,l){return M.cloneElement(o,{data:t,key:"labelList-".concat(l)})});if(!n)return i;var a=Dve(e.label,t);return[a].concat(Eve(i))}xa.renderCallByParent=Ive;function Am(e){"@babel/helpers - typeof";return Am=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},Am(e)}function iO(){return iO=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},iO.apply(this,arguments)}function i8(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 a8(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?i8(Object(n),!0).forEach(function(r){$ve(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $ve(e,t,n){return t=Bve(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Bve(e){var t=Uve(e,"string");return Am(t)=="symbol"?t:t+""}function Uve(e,t){if(Am(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Am(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zve=function(t,n){var r=Fr(n-t),i=Math.min(Math.abs(n-t),359.999);return r*i},uy=function(t){var n=t.cx,r=t.cy,i=t.radius,a=t.angle,o=t.sign,l=t.isExternal,f=t.cornerRadius,u=t.cornerIsExternal,h=f*(l?1:-1)+i,m=Math.asin(f/h)/D0,g=u?a:a+o*m,_=cn(n,r,h,g),x=cn(n,r,i,g),b=u?a-o*m:a,S=cn(n,r,h*Math.cos(m*D0),b);return{center:_,circleTangency:x,lineTangency:S,theta:m}},jF=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,a=t.outerRadius,o=t.startAngle,l=t.endAngle,f=zve(o,l),u=o+f,h=cn(n,r,a,o),m=cn(n,r,a,u),g="M ".concat(h.x,",").concat(h.y,`
|
||
A `).concat(a,",").concat(a,`,0,
|
||
`).concat(+(Math.abs(f)>180),",").concat(+(o>u),`,
|
||
`).concat(m.x,",").concat(m.y,`
|
||
`);if(i>0){var _=cn(n,r,i,o),x=cn(n,r,i,u);g+="L ".concat(x.x,",").concat(x.y,`
|
||
A `).concat(i,",").concat(i,`,0,
|
||
`).concat(+(Math.abs(f)>180),",").concat(+(o<=u),`,
|
||
`).concat(_.x,",").concat(_.y," Z")}else g+="L ".concat(n,",").concat(r," Z");return g},Fve=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,a=t.outerRadius,o=t.cornerRadius,l=t.forceCornerRadius,f=t.cornerIsExternal,u=t.startAngle,h=t.endAngle,m=Fr(h-u),g=uy({cx:n,cy:r,radius:a,angle:u,sign:m,cornerRadius:o,cornerIsExternal:f}),_=g.circleTangency,x=g.lineTangency,b=g.theta,S=uy({cx:n,cy:r,radius:a,angle:h,sign:-m,cornerRadius:o,cornerIsExternal:f}),C=S.circleTangency,A=S.lineTangency,O=S.theta,P=f?Math.abs(u-h):Math.abs(u-h)-b-O;if(P<0)return l?"M ".concat(x.x,",").concat(x.y,`
|
||
a`).concat(o,",").concat(o,",0,0,1,").concat(o*2,`,0
|
||
a`).concat(o,",").concat(o,",0,0,1,").concat(-o*2,`,0
|
||
`):jF({cx:n,cy:r,innerRadius:i,outerRadius:a,startAngle:u,endAngle:h});var j="M ".concat(x.x,",").concat(x.y,`
|
||
A`).concat(o,",").concat(o,",0,0,").concat(+(m<0),",").concat(_.x,",").concat(_.y,`
|
||
A`).concat(a,",").concat(a,",0,").concat(+(P>180),",").concat(+(m<0),",").concat(C.x,",").concat(C.y,`
|
||
A`).concat(o,",").concat(o,",0,0,").concat(+(m<0),",").concat(A.x,",").concat(A.y,`
|
||
`);if(i>0){var R=uy({cx:n,cy:r,radius:i,angle:u,sign:m,isExternal:!0,cornerRadius:o,cornerIsExternal:f}),U=R.circleTangency,V=R.lineTangency,Y=R.theta,K=uy({cx:n,cy:r,radius:i,angle:h,sign:-m,isExternal:!0,cornerRadius:o,cornerIsExternal:f}),W=K.circleTangency,ee=K.lineTangency,ie=K.theta,X=f?Math.abs(u-h):Math.abs(u-h)-Y-ie;if(X<0&&o===0)return"".concat(j,"L").concat(n,",").concat(r,"Z");j+="L".concat(ee.x,",").concat(ee.y,`
|
||
A`).concat(o,",").concat(o,",0,0,").concat(+(m<0),",").concat(W.x,",").concat(W.y,`
|
||
A`).concat(i,",").concat(i,",0,").concat(+(X>180),",").concat(+(m>0),",").concat(U.x,",").concat(U.y,`
|
||
A`).concat(o,",").concat(o,",0,0,").concat(+(m<0),",").concat(V.x,",").concat(V.y,"Z")}else j+="L".concat(n,",").concat(r,"Z");return j},qve={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},PF=function(t){var n=a8(a8({},qve),t),r=n.cx,i=n.cy,a=n.innerRadius,o=n.outerRadius,l=n.cornerRadius,f=n.forceCornerRadius,u=n.cornerIsExternal,h=n.startAngle,m=n.endAngle,g=n.className;if(o<a||h===m)return null;var _=be("recharts-sector",g),x=o-a,b=qr(l,x,0,!0),S;return b>0&&Math.abs(h-m)<360?S=Fve({cx:r,cy:i,innerRadius:a,outerRadius:o,cornerRadius:Math.min(b,x/2),forceCornerRadius:f,cornerIsExternal:u,startAngle:h,endAngle:m}):S=jF({cx:r,cy:i,innerRadius:a,outerRadius:o,startAngle:h,endAngle:m}),pe.createElement("path",iO({},ot(n,!0),{className:_,d:S,role:"img"}))};function Em(e){"@babel/helpers - typeof";return Em=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},Em(e)}function aO(){return aO=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},aO.apply(this,arguments)}function o8(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 s8(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?o8(Object(n),!0).forEach(function(r){Vve(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vve(e,t,n){return t=Hve(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hve(e){var t=Gve(e,"string");return Em(t)=="symbol"?t:t+""}function Gve(e,t){if(Em(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Em(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var l8={curveBasisClosed:fue,curveBasisOpen:due,curveBasis:cue,curveBumpX:Zle,curveBumpY:Xle,curveLinearClosed:hue,curveLinear:o1,curveMonotoneX:pue,curveMonotoneY:mue,curveNatural:gue,curveStep:vue,curveStepAfter:bue,curveStepBefore:yue},cy=function(t){return t.x===+t.x&&t.y===+t.y},fp=function(t){return t.x},dp=function(t){return t.y},Wve=function(t,n){if(ht(t))return t;var r="curve".concat(i1(t));return(r==="curveMonotone"||r==="curveBump")&&n?l8["".concat(r).concat(n==="vertical"?"Y":"X")]:l8[r]||o1},Yve=function(t){var n=t.type,r=n===void 0?"linear":n,i=t.points,a=i===void 0?[]:i,o=t.baseLine,l=t.layout,f=t.connectNulls,u=f===void 0?!1:f,h=Wve(r,l),m=u?a.filter(function(b){return cy(b)}):a,g;if(Array.isArray(o)){var _=u?o.filter(function(b){return cy(b)}):o,x=m.map(function(b,S){return s8(s8({},b),{},{base:_[S]})});return l==="vertical"?g=ty().y(dp).x1(fp).x0(function(b){return b.base.x}):g=ty().x(fp).y1(dp).y0(function(b){return b.base.y}),g.defined(cy).curve(h),g(x)}return l==="vertical"&&Ze(o)?g=ty().y(dp).x1(fp).x0(o):Ze(o)?g=ty().x(fp).y1(dp).y0(o):g=TU().x(fp).y(dp),g.defined(cy).curve(h),g(m)},El=function(t){var n=t.className,r=t.points,i=t.path,a=t.pathRef;if((!r||!r.length)&&!i)return null;var o=r&&r.length?Yve(t):i;return pe.createElement("path",aO({},ot(t,!1),f0(t),{className:be("recharts-curve",n),d:o,ref:a}))},Kve=Object.getOwnPropertyNames,Zve=Object.getOwnPropertySymbols,Xve=Object.prototype.hasOwnProperty;function u8(e,t){return function(r,i,a){return e(r,i,a)&&t(r,i,a)}}function fy(e){return function(n,r,i){if(!n||!r||typeof n!="object"||typeof r!="object")return e(n,r,i);var a=i.cache,o=a.get(n),l=a.get(r);if(o&&l)return o===r&&l===n;a.set(n,r),a.set(r,n);var f=e(n,r,i);return a.delete(n),a.delete(r),f}}function c8(e){return Kve(e).concat(Zve(e))}var Qve=Object.hasOwn||function(e,t){return Xve.call(e,t)};function gc(e,t){return e===t||!e&&!t&&e!==e&&t!==t}var Jve="__v",eye="__o",tye="_owner",f8=Object.getOwnPropertyDescriptor,d8=Object.keys;function nye(e,t,n){var 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 rye(e,t){return gc(e.getTime(),t.getTime())}function iye(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function aye(e,t){return e===t}function h8(e,t,n){var r=e.size;if(r!==t.size)return!1;if(!r)return!0;for(var i=new Array(r),a=e.entries(),o,l,f=0;(o=a.next())&&!o.done;){for(var u=t.entries(),h=!1,m=0;(l=u.next())&&!l.done;){if(i[m]){m++;continue}var g=o.value,_=l.value;if(n.equals(g[0],_[0],f,m,e,t,n)&&n.equals(g[1],_[1],g[0],_[0],e,t,n)){h=i[m]=!0;break}m++}if(!h)return!1;f++}return!0}var oye=gc;function sye(e,t,n){var r=d8(e),i=r.length;if(d8(t).length!==i)return!1;for(;i-- >0;)if(!RF(e,t,n,r[i]))return!1;return!0}function hp(e,t,n){var r=c8(e),i=r.length;if(c8(t).length!==i)return!1;for(var a,o,l;i-- >0;)if(a=r[i],!RF(e,t,n,a)||(o=f8(e,a),l=f8(t,a),(o||l)&&(!o||!l||o.configurable!==l.configurable||o.enumerable!==l.enumerable||o.writable!==l.writable)))return!1;return!0}function lye(e,t){return gc(e.valueOf(),t.valueOf())}function uye(e,t){return e.source===t.source&&e.flags===t.flags}function p8(e,t,n){var r=e.size;if(r!==t.size)return!1;if(!r)return!0;for(var i=new Array(r),a=e.values(),o,l;(o=a.next())&&!o.done;){for(var f=t.values(),u=!1,h=0;(l=f.next())&&!l.done;){if(!i[h]&&n.equals(o.value,l.value,o.value,l.value,e,t,n)){u=i[h]=!0;break}h++}if(!u)return!1}return!0}function cye(e,t){var n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function fye(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 RF(e,t,n,r){return(r===tye||r===eye||r===Jve)&&(e.$$typeof||t.$$typeof)?!0:Qve(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}var dye="[object Arguments]",hye="[object Boolean]",pye="[object Date]",mye="[object Error]",gye="[object Map]",vye="[object Number]",yye="[object Object]",bye="[object RegExp]",wye="[object Set]",_ye="[object String]",xye="[object URL]",Sye=Array.isArray,m8=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,g8=Object.assign,Cye=Object.prototype.toString.call.bind(Object.prototype.toString);function Aye(e){var t=e.areArraysEqual,n=e.areDatesEqual,r=e.areErrorsEqual,i=e.areFunctionsEqual,a=e.areMapsEqual,o=e.areNumbersEqual,l=e.areObjectsEqual,f=e.arePrimitiveWrappersEqual,u=e.areRegExpsEqual,h=e.areSetsEqual,m=e.areTypedArraysEqual,g=e.areUrlsEqual;return function(x,b,S){if(x===b)return!0;if(x==null||b==null)return!1;var C=typeof x;if(C!==typeof b)return!1;if(C!=="object")return C==="number"?o(x,b,S):C==="function"?i(x,b,S):!1;var A=x.constructor;if(A!==b.constructor)return!1;if(A===Object)return l(x,b,S);if(Sye(x))return t(x,b,S);if(m8!=null&&m8(x))return m(x,b,S);if(A===Date)return n(x,b,S);if(A===RegExp)return u(x,b,S);if(A===Map)return a(x,b,S);if(A===Set)return h(x,b,S);var O=Cye(x);return O===pye?n(x,b,S):O===bye?u(x,b,S):O===gye?a(x,b,S):O===wye?h(x,b,S):O===yye?typeof x.then!="function"&&typeof b.then!="function"&&l(x,b,S):O===xye?g(x,b,S):O===mye?r(x,b,S):O===dye?l(x,b,S):O===hye||O===vye||O===_ye?f(x,b,S):!1}}function Eye(e){var t=e.circular,n=e.createCustomConfig,r=e.strict,i={areArraysEqual:r?hp:nye,areDatesEqual:rye,areErrorsEqual:iye,areFunctionsEqual:aye,areMapsEqual:r?u8(h8,hp):h8,areNumbersEqual:oye,areObjectsEqual:r?hp:sye,arePrimitiveWrappersEqual:lye,areRegExpsEqual:uye,areSetsEqual:r?u8(p8,hp):p8,areTypedArraysEqual:r?hp:cye,areUrlsEqual:fye};if(n&&(i=g8({},i,n(i))),t){var a=fy(i.areArraysEqual),o=fy(i.areMapsEqual),l=fy(i.areObjectsEqual),f=fy(i.areSetsEqual);i=g8({},i,{areArraysEqual:a,areMapsEqual:o,areObjectsEqual:l,areSetsEqual:f})}return i}function Oye(e){return function(t,n,r,i,a,o,l){return e(t,n,l)}}function Tye(e){var t=e.circular,n=e.comparator,r=e.createState,i=e.equals,a=e.strict;if(r)return function(f,u){var h=r(),m=h.cache,g=m===void 0?t?new WeakMap:void 0:m,_=h.meta;return n(f,u,{cache:g,equals:i,meta:_,strict:a})};if(t)return function(f,u){return n(f,u,{cache:new WeakMap,equals:i,meta:void 0,strict:a})};var o={cache:void 0,equals:i,meta:void 0,strict:a};return function(f,u){return n(f,u,o)}}var jye=Xl();Xl({strict:!0});Xl({circular:!0});Xl({circular:!0,strict:!0});Xl({createInternalComparator:function(){return gc}});Xl({strict:!0,createInternalComparator:function(){return gc}});Xl({circular:!0,createInternalComparator:function(){return gc}});Xl({circular:!0,createInternalComparator:function(){return gc},strict:!0});function Xl(e){e===void 0&&(e={});var t=e.circular,n=t===void 0?!1:t,r=e.createInternalComparator,i=e.createState,a=e.strict,o=a===void 0?!1:a,l=Eye(e),f=Aye(l),u=r?r(f):Oye(f);return Tye({circular:n,comparator:f,createState:i,equals:u,strict:o})}function Pye(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function v8(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function i(a){n<0&&(n=a),a-n>t?(e(a),n=-1):Pye(i)};requestAnimationFrame(r)}function oO(e){"@babel/helpers - typeof";return oO=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},oO(e)}function Rye(e){return kye(e)||Lye(e)||Nye(e)||Mye()}function Mye(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Nye(e,t){if(e){if(typeof e=="string")return y8(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 y8(e,t)}}function y8(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 Lye(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function kye(e){if(Array.isArray(e))return e}function Dye(){var e={},t=function(){return null},n=!1,r=function i(a){if(!n){if(Array.isArray(a)){if(!a.length)return;var o=a,l=Rye(o),f=l[0],u=l.slice(1);if(typeof f=="number"){v8(i.bind(null,u),f);return}i(f),v8(i.bind(null,u));return}oO(a)==="object"&&(e=a,t(e)),typeof a=="function"&&a()}};return{stop:function(){n=!0},start:function(a){n=!1,r(a)},subscribe:function(a){return t=a,function(){t=function(){return null}}}}}function Om(e){"@babel/helpers - typeof";return Om=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},Om(e)}function b8(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 w8(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?b8(Object(n),!0).forEach(function(r){MF(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function MF(e,t,n){return t=Iye(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Iye(e){var t=$ye(e,"string");return Om(t)==="symbol"?t:String(t)}function $ye(e,t){if(Om(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Om(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Bye=function(t,n){return[Object.keys(t),Object.keys(n)].reduce(function(r,i){return r.filter(function(a){return i.includes(a)})})},Uye=function(t){return t},zye=function(t){return t.replace(/([A-Z])/g,function(n){return"-".concat(n.toLowerCase())})},Ip=function(t,n){return Object.keys(n).reduce(function(r,i){return w8(w8({},r),{},MF({},i,t(i,n[i])))},{})},_8=function(t,n,r){return t.map(function(i){return"".concat(zye(i)," ").concat(n,"ms ").concat(r)}).join(",")};function Fye(e,t){return Hye(e)||Vye(e,t)||NF(e,t)||qye()}function qye(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Vye(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function Hye(e){if(Array.isArray(e))return e}function Gye(e){return Kye(e)||Yye(e)||NF(e)||Wye()}function Wye(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function NF(e,t){if(e){if(typeof e=="string")return sO(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 sO(e,t)}}function Yye(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Kye(e){if(Array.isArray(e))return sO(e)}function sO(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 $0=1e-4,LF=function(t,n){return[0,3*t,3*n-6*t,3*t-3*n+1]},kF=function(t,n){return t.map(function(r,i){return r*Math.pow(n,i)}).reduce(function(r,i){return r+i})},x8=function(t,n){return function(r){var i=LF(t,n);return kF(i,r)}},Zye=function(t,n){return function(r){var i=LF(t,n),a=[].concat(Gye(i.map(function(o,l){return o*l}).slice(1)),[0]);return kF(a,r)}},S8=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0],a=n[1],o=n[2],l=n[3];if(n.length===1)switch(n[0]){case"linear":i=0,a=0,o=1,l=1;break;case"ease":i=.25,a=.1,o=.25,l=1;break;case"ease-in":i=.42,a=0,o=1,l=1;break;case"ease-out":i=.42,a=0,o=.58,l=1;break;case"ease-in-out":i=0,a=0,o=.58,l=1;break;default:{var f=n[0].split("(");if(f[0]==="cubic-bezier"&&f[1].split(")")[0].split(",").length===4){var u=f[1].split(")")[0].split(",").map(function(S){return parseFloat(S)}),h=Fye(u,4);i=h[0],a=h[1],o=h[2],l=h[3]}}}var m=x8(i,o),g=x8(a,l),_=Zye(i,o),x=function(C){return C>1?1:C<0?0:C},b=function(C){for(var A=C>1?1:C,O=A,P=0;P<8;++P){var j=m(O)-A,R=_(O);if(Math.abs(j-A)<$0||R<$0)return g(O);O=x(O-j/R)}return g(O)};return b.isStepper=!1,b},Xye=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,i=t.damping,a=i===void 0?8:i,o=t.dt,l=o===void 0?17:o,f=function(h,m,g){var _=-(h-m)*r,x=g*a,b=g+(_-x)*l/1e3,S=g*l/1e3+h;return Math.abs(S-m)<$0&&Math.abs(b)<$0?[m,0]:[S,b]};return f.isStepper=!0,f.dt=l,f},Qye=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 S8(i);case"spring":return Xye();default:if(i.split("(")[0]==="cubic-bezier")return S8(i)}return typeof i=="function"?i:null};function Tm(e){"@babel/helpers - typeof";return Tm=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},Tm(e)}function C8(e){return t0e(e)||e0e(e)||DF(e)||Jye()}function Jye(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function e0e(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function t0e(e){if(Array.isArray(e))return uO(e)}function A8(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?A8(Object(n),!0).forEach(function(r){lO(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):A8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lO(e,t,n){return t=n0e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function n0e(e){var t=r0e(e,"string");return Tm(t)==="symbol"?t:String(t)}function r0e(e,t){if(Tm(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Tm(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function i0e(e,t){return s0e(e)||o0e(e,t)||DF(e,t)||a0e()}function a0e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function DF(e,t){if(e){if(typeof e=="string")return uO(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 uO(e,t)}}function uO(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 o0e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function s0e(e){if(Array.isArray(e))return e}var B0=function(t,n,r){return t+(n-t)*r},cO=function(t){var n=t.from,r=t.to;return n!==r},l0e=function e(t,n,r){var i=Ip(function(a,o){if(cO(o)){var l=t(o.from,o.to,o.velocity),f=i0e(l,2),u=f[0],h=f[1];return br(br({},o),{},{from:u,velocity:h})}return o},n);return r<1?Ip(function(a,o){return cO(o)?br(br({},o),{},{velocity:B0(o.velocity,i[a].velocity,r),from:B0(o.from,i[a].from,r)}):o},n):e(t,i,r-1)};const u0e=function(e,t,n,r,i){var a=Bye(e,t),o=a.reduce(function(S,C){return br(br({},S),{},lO({},C,[e[C],t[C]]))},{}),l=a.reduce(function(S,C){return br(br({},S),{},lO({},C,{from:e[C],velocity:0,to:t[C]}))},{}),f=-1,u,h,m=function(){return null},g=function(){return Ip(function(C,A){return A.from},l)},_=function(){return!Object.values(l).filter(cO).length},x=function(C){u||(u=C);var A=C-u,O=A/n.dt;l=l0e(n,l,O),i(br(br(br({},e),t),g())),u=C,_()||(f=requestAnimationFrame(m))},b=function(C){h||(h=C);var A=(C-h)/r,O=Ip(function(j,R){return B0.apply(void 0,C8(R).concat([n(A)]))},o);if(i(br(br(br({},e),t),O)),A<1)f=requestAnimationFrame(m);else{var P=Ip(function(j,R){return B0.apply(void 0,C8(R).concat([n(1)]))},o);i(br(br(br({},e),t),P))}};return m=n.isStepper?x:b,function(){return requestAnimationFrame(m),function(){cancelAnimationFrame(f)}}};function id(e){"@babel/helpers - typeof";return id=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},id(e)}var c0e=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function f0e(e,t){if(e==null)return{};var n=d0e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function d0e(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,a;for(a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function WC(e){return g0e(e)||m0e(e)||p0e(e)||h0e()}function h0e(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function p0e(e,t){if(e){if(typeof e=="string")return fO(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 fO(e,t)}}function m0e(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function g0e(e){if(Array.isArray(e))return fO(e)}function fO(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 E8(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 ga(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?E8(Object(n),!0).forEach(function(r){Ep(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ep(e,t,n){return t=IF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function v0e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function y0e(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,IF(r.key),r)}}function b0e(e,t,n){return t&&y0e(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function IF(e){var t=w0e(e,"string");return id(t)==="symbol"?t:String(t)}function w0e(e,t){if(id(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(id(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function _0e(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&&dO(e,t)}function dO(e,t){return dO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},dO(e,t)}function x0e(e){var t=S0e();return function(){var r=U0(e),i;if(t){var a=U0(this).constructor;i=Reflect.construct(r,arguments,a)}else i=r.apply(this,arguments);return hO(this,i)}}function hO(e,t){if(t&&(id(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return pO(e)}function pO(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function S0e(){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 U0(e){return U0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},U0(e)}var ra=function(e){_0e(n,e);var t=x0e(n);function n(r,i){var a;v0e(this,n),a=t.call(this,r,i);var o=a.props,l=o.isActive,f=o.attributeName,u=o.from,h=o.to,m=o.steps,g=o.children,_=o.duration;if(a.handleStyleChange=a.handleStyleChange.bind(pO(a)),a.changeStyle=a.changeStyle.bind(pO(a)),!l||_<=0)return a.state={style:{}},typeof g=="function"&&(a.state={style:h}),hO(a);if(m&&m.length)a.state={style:m[0].style};else if(u){if(typeof g=="function")return a.state={style:u},hO(a);a.state={style:f?Ep({},f,u):u}}else a.state={style:{}};return a}return b0e(n,[{key:"componentDidMount",value:function(){var i=this.props,a=i.isActive,o=i.canBegin;this.mounted=!0,!(!a||!o)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var a=this.props,o=a.isActive,l=a.canBegin,f=a.attributeName,u=a.shouldReAnimate,h=a.to,m=a.from,g=this.state.style;if(l){if(!o){var _={style:f?Ep({},f,h):h};this.state&&g&&(f&&g[f]!==h||!f&&g!==h)&&this.setState(_);return}if(!(jye(i.to,h)&&i.canBegin&&i.isActive)){var x=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var b=x||u?m:i.to;if(this.state&&g){var S={style:f?Ep({},f,b):b};(f&&g[f]!==b||!f&&g!==b)&&this.setState(S)}this.runAnimation(ga(ga({},this.props),{},{from:b,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var i=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),i&&i()}},{key:"handleStyleChange",value:function(i){this.changeStyle(i)}},{key:"changeStyle",value:function(i){this.mounted&&this.setState({style:i})}},{key:"runJSAnimation",value:function(i){var a=this,o=i.from,l=i.to,f=i.duration,u=i.easing,h=i.begin,m=i.onAnimationEnd,g=i.onAnimationStart,_=u0e(o,l,Qye(u),f,this.changeStyle),x=function(){a.stopJSAnimation=_()};this.manager.start([g,h,x,f,m])}},{key:"runStepAnimation",value:function(i){var a=this,o=i.steps,l=i.begin,f=i.onAnimationStart,u=o[0],h=u.style,m=u.duration,g=m===void 0?0:m,_=function(b,S,C){if(C===0)return b;var A=S.duration,O=S.easing,P=O===void 0?"ease":O,j=S.style,R=S.properties,U=S.onAnimationEnd,V=C>0?o[C-1]:S,Y=R||Object.keys(j);if(typeof P=="function"||P==="spring")return[].concat(WC(b),[a.runJSAnimation.bind(a,{from:V.style,to:j,duration:A,easing:P}),A]);var K=_8(Y,A,P),W=ga(ga(ga({},V.style),j),{},{transition:K});return[].concat(WC(b),[W,A,U]).filter(Uye)};return this.manager.start([f].concat(WC(o.reduce(_,[h,Math.max(g,l)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=Dye());var a=i.begin,o=i.duration,l=i.attributeName,f=i.to,u=i.easing,h=i.onAnimationStart,m=i.onAnimationEnd,g=i.steps,_=i.children,x=this.manager;if(this.unSubscribe=x.subscribe(this.handleStyleChange),typeof u=="function"||typeof _=="function"||u==="spring"){this.runJSAnimation(i);return}if(g.length>1){this.runStepAnimation(i);return}var b=l?Ep({},l,f):f,S=_8(Object.keys(b),o,u);x.start([h,a,ga(ga({},b),{},{transition:S}),o,m])}},{key:"render",value:function(){var i=this.props,a=i.children;i.begin;var o=i.duration;i.attributeName,i.easing;var l=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var f=f0e(i,c0e),u=M.Children.count(a),h=this.state.style;if(typeof a=="function")return a(h);if(!l||u===0||o<=0)return a;var m=function(_){var x=_.props,b=x.style,S=b===void 0?{}:b,C=x.className,A=M.cloneElement(_,ga(ga({},f),{},{style:ga(ga({},S),h),className:C}));return A};return u===1?m(M.Children.only(a)):pe.createElement("div",null,M.Children.map(a,function(g){return m(g)}))}}]),n}(M.PureComponent);ra.displayName="Animate";ra.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};ra.propTypes={from:et.oneOfType([et.object,et.string]),to:et.oneOfType([et.object,et.string]),attributeName:et.string,duration:et.number,begin:et.number,easing:et.oneOfType([et.string,et.func]),steps:et.arrayOf(et.shape({duration:et.number.isRequired,style:et.object.isRequired,easing:et.oneOfType([et.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),et.func]),properties:et.arrayOf("string"),onAnimationEnd:et.func})),children:et.oneOfType([et.node,et.func]),isActive:et.bool,canBegin:et.bool,onAnimationEnd:et.func,shouldReAnimate:et.bool,onAnimationStart:et.func,onAnimationReStart:et.func};function jm(e){"@babel/helpers - typeof";return jm=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},jm(e)}function z0(){return z0=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},z0.apply(this,arguments)}function C0e(e,t){return T0e(e)||O0e(e,t)||E0e(e,t)||A0e()}function A0e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function E0e(e,t){if(e){if(typeof e=="string")return O8(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 O8(e,t)}}function O8(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 O0e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function T0e(e){if(Array.isArray(e))return e}function T8(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 j8(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?T8(Object(n),!0).forEach(function(r){j0e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function j0e(e,t,n){return t=P0e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P0e(e){var t=R0e(e,"string");return jm(t)=="symbol"?t:t+""}function R0e(e,t){if(jm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(jm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var P8=function(t,n,r,i,a){var o=Math.min(Math.abs(r)/2,Math.abs(i)/2),l=i>=0?1:-1,f=r>=0?1:-1,u=i>=0&&r>=0||i<0&&r<0?1:0,h;if(o>0&&a instanceof Array){for(var m=[0,0,0,0],g=0,_=4;g<_;g++)m[g]=a[g]>o?o:a[g];h="M".concat(t,",").concat(n+l*m[0]),m[0]>0&&(h+="A ".concat(m[0],",").concat(m[0],",0,0,").concat(u,",").concat(t+f*m[0],",").concat(n)),h+="L ".concat(t+r-f*m[1],",").concat(n),m[1]>0&&(h+="A ".concat(m[1],",").concat(m[1],",0,0,").concat(u,`,
|
||
`).concat(t+r,",").concat(n+l*m[1])),h+="L ".concat(t+r,",").concat(n+i-l*m[2]),m[2]>0&&(h+="A ".concat(m[2],",").concat(m[2],",0,0,").concat(u,`,
|
||
`).concat(t+r-f*m[2],",").concat(n+i)),h+="L ".concat(t+f*m[3],",").concat(n+i),m[3]>0&&(h+="A ".concat(m[3],",").concat(m[3],",0,0,").concat(u,`,
|
||
`).concat(t,",").concat(n+i-l*m[3])),h+="Z"}else if(o>0&&a===+a&&a>0){var x=Math.min(o,a);h="M ".concat(t,",").concat(n+l*x,`
|
||
A `).concat(x,",").concat(x,",0,0,").concat(u,",").concat(t+f*x,",").concat(n,`
|
||
L `).concat(t+r-f*x,",").concat(n,`
|
||
A `).concat(x,",").concat(x,",0,0,").concat(u,",").concat(t+r,",").concat(n+l*x,`
|
||
L `).concat(t+r,",").concat(n+i-l*x,`
|
||
A `).concat(x,",").concat(x,",0,0,").concat(u,",").concat(t+r-f*x,",").concat(n+i,`
|
||
L `).concat(t+f*x,",").concat(n+i,`
|
||
A `).concat(x,",").concat(x,",0,0,").concat(u,",").concat(t,",").concat(n+i-l*x," Z")}else h="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(i," h ").concat(-r," Z");return h},M0e=function(t,n){if(!t||!n)return!1;var r=t.x,i=t.y,a=n.x,o=n.y,l=n.width,f=n.height;if(Math.abs(l)>0&&Math.abs(f)>0){var u=Math.min(a,a+l),h=Math.max(a,a+l),m=Math.min(o,o+f),g=Math.max(o,o+f);return r>=u&&r<=h&&i>=m&&i<=g}return!1},N0e={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Y3=function(t){var n=j8(j8({},N0e),t),r=M.useRef(),i=M.useState(-1),a=C0e(i,2),o=a[0],l=a[1];M.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var P=r.current.getTotalLength();P&&l(P)}catch{}},[]);var f=n.x,u=n.y,h=n.width,m=n.height,g=n.radius,_=n.className,x=n.animationEasing,b=n.animationDuration,S=n.animationBegin,C=n.isAnimationActive,A=n.isUpdateAnimationActive;if(f!==+f||u!==+u||h!==+h||m!==+m||h===0||m===0)return null;var O=be("recharts-rectangle",_);return A?pe.createElement(ra,{canBegin:o>0,from:{width:h,height:m,x:f,y:u},to:{width:h,height:m,x:f,y:u},duration:b,animationEasing:x,isActive:A},function(P){var j=P.width,R=P.height,U=P.x,V=P.y;return pe.createElement(ra,{canBegin:o>0,from:"0px ".concat(o===-1?1:o,"px"),to:"".concat(o,"px 0px"),attributeName:"strokeDasharray",begin:S,duration:b,isActive:C,easing:x},pe.createElement("path",z0({},ot(n,!0),{className:O,d:P8(U,V,j,R,g),ref:r})))}):pe.createElement("path",z0({},ot(n,!0),{className:O,d:P8(f,u,h,m,g)}))},L0e=["points","className","baseLinePoints","connectNulls"];function Af(){return Af=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},Af.apply(this,arguments)}function k0e(e,t){if(e==null)return{};var n=D0e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function D0e(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 R8(e){return U0e(e)||B0e(e)||$0e(e)||I0e()}function I0e(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $0e(e,t){if(e){if(typeof e=="string")return mO(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 mO(e,t)}}function B0e(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function U0e(e){if(Array.isArray(e))return mO(e)}function mO(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 M8=function(t){return t&&t.x===+t.x&&t.y===+t.y},z0e=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],n=[[]];return t.forEach(function(r){M8(r)?n[n.length-1].push(r):n[n.length-1].length>0&&n.push([])}),M8(t[0])&&n[n.length-1].push(t[0]),n[n.length-1].length<=0&&(n=n.slice(0,-1)),n},$p=function(t,n){var r=z0e(t);n&&(r=[r.reduce(function(a,o){return[].concat(R8(a),R8(o))},[])]);var i=r.map(function(a){return a.reduce(function(o,l,f){return"".concat(o).concat(f===0?"M":"L").concat(l.x,",").concat(l.y)},"")}).join("");return r.length===1?"".concat(i,"Z"):i},F0e=function(t,n,r){var i=$p(t,r);return"".concat(i.slice(-1)==="Z"?i.slice(0,-1):i,"L").concat($p(n.reverse(),r).slice(1))},q0e=function(t){var n=t.points,r=t.className,i=t.baseLinePoints,a=t.connectNulls,o=k0e(t,L0e);if(!n||!n.length)return null;var l=be("recharts-polygon",r);if(i&&i.length){var f=o.stroke&&o.stroke!=="none",u=F0e(n,i,a);return pe.createElement("g",{className:l},pe.createElement("path",Af({},ot(o,!0),{fill:u.slice(-1)==="Z"?o.fill:"none",stroke:"none",d:u})),f?pe.createElement("path",Af({},ot(o,!0),{fill:"none",d:$p(n,a)})):null,f?pe.createElement("path",Af({},ot(o,!0),{fill:"none",d:$p(i,a)})):null)}var h=$p(n,a);return pe.createElement("path",Af({},ot(o,!0),{fill:h.slice(-1)==="Z"?o.fill:"none",className:l,d:h}))};function gO(){return gO=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},gO.apply(this,arguments)}var pg=function(t){var n=t.cx,r=t.cy,i=t.r,a=t.className,o=be("recharts-dot",a);return n===+n&&r===+r&&i===+i?pe.createElement("circle",gO({},ot(t,!1),f0(t),{className:o,cx:n,cy:r,r:i})):null};function Pm(e){"@babel/helpers - typeof";return Pm=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},Pm(e)}var V0e=["x","y","top","left","width","height","className"];function vO(){return vO=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},vO.apply(this,arguments)}function N8(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 H0e(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?N8(Object(n),!0).forEach(function(r){G0e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):N8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function G0e(e,t,n){return t=W0e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function W0e(e){var t=Y0e(e,"string");return Pm(t)=="symbol"?t:t+""}function Y0e(e,t){if(Pm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Pm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function K0e(e,t){if(e==null)return{};var n=Z0e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Z0e(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 X0e=function(t,n,r,i,a,o){return"M".concat(t,",").concat(a,"v").concat(i,"M").concat(o,",").concat(n,"h").concat(r)},Q0e=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,a=i===void 0?0:i,o=t.top,l=o===void 0?0:o,f=t.left,u=f===void 0?0:f,h=t.width,m=h===void 0?0:h,g=t.height,_=g===void 0?0:g,x=t.className,b=K0e(t,V0e),S=H0e({x:r,y:a,top:l,left:u,width:m,height:_},b);return!Ze(r)||!Ze(a)||!Ze(m)||!Ze(_)||!Ze(l)||!Ze(u)?null:pe.createElement("path",vO({},ot(S,!0),{className:be("recharts-cross",x),d:X0e(r,a,m,_,l,u)}))},YC,L8;function J0e(){if(L8)return YC;L8=1;var e=y1(),t=Qz(),n=vo();function r(i,a){return i&&i.length?e(i,n(a,2),t):void 0}return YC=r,YC}var ebe=J0e();const tbe=zt(ebe);var KC,k8;function nbe(){if(k8)return KC;k8=1;var e=y1(),t=vo(),n=Jz();function r(i,a){return i&&i.length?e(i,t(a,2),n):void 0}return KC=r,KC}var rbe=nbe();const ibe=zt(rbe);var abe=["cx","cy","angle","ticks","axisLine"],obe=["ticks","tick","angle","tickFormatter","stroke"];function ad(e){"@babel/helpers - typeof";return ad=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},ad(e)}function Bp(){return Bp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bp.apply(this,arguments)}function D8(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 ju(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?D8(Object(n),!0).forEach(function(r){x1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function I8(e,t){if(e==null)return{};var n=sbe(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function sbe(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 lbe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $8(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,BF(r.key),r)}}function ube(e,t,n){return t&&$8(e.prototype,t),n&&$8(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function cbe(e,t,n){return t=F0(t),fbe(e,$F()?Reflect.construct(t,n||[],F0(e).constructor):t.apply(e,n))}function fbe(e,t){if(t&&(ad(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return dbe(e)}function dbe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $F(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return($F=function(){return!!e})()}function F0(e){return F0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},F0(e)}function hbe(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&&yO(e,t)}function yO(e,t){return yO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},yO(e,t)}function x1(e,t,n){return t=BF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BF(e){var t=pbe(e,"string");return ad(t)=="symbol"?t:t+""}function pbe(e,t){if(ad(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ad(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var S1=function(e){function t(){return lbe(this,t),cbe(this,t,arguments)}return hbe(t,e),ube(t,[{key:"getTickValueCoord",value:function(r){var i=r.coordinate,a=this.props,o=a.angle,l=a.cx,f=a.cy;return cn(l,f,i,o)}},{key:"getTickTextAnchor",value:function(){var r=this.props.orientation,i;switch(r){case"left":i="end";break;case"right":i="start";break;default:i="middle";break}return i}},{key:"getViewBox",value:function(){var r=this.props,i=r.cx,a=r.cy,o=r.angle,l=r.ticks,f=tbe(l,function(h){return h.coordinate||0}),u=ibe(l,function(h){return h.coordinate||0});return{cx:i,cy:a,startAngle:o,endAngle:o,innerRadius:u.coordinate||0,outerRadius:f.coordinate||0}}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.cx,a=r.cy,o=r.angle,l=r.ticks,f=r.axisLine,u=I8(r,abe),h=l.reduce(function(x,b){return[Math.min(x[0],b.coordinate),Math.max(x[1],b.coordinate)]},[1/0,-1/0]),m=cn(i,a,h[0],o),g=cn(i,a,h[1],o),_=ju(ju(ju({},ot(u,!1)),{},{fill:"none"},ot(f,!1)),{},{x1:m.x,y1:m.y,x2:g.x,y2:g.y});return pe.createElement("line",Bp({className:"recharts-polar-radius-axis-line"},_))}},{key:"renderTicks",value:function(){var r=this,i=this.props,a=i.ticks,o=i.tick,l=i.angle,f=i.tickFormatter,u=i.stroke,h=I8(i,obe),m=this.getTickTextAnchor(),g=ot(h,!1),_=ot(o,!1),x=a.map(function(b,S){var C=r.getTickValueCoord(b),A=ju(ju(ju(ju({textAnchor:m,transform:"rotate(".concat(90-l,", ").concat(C.x,", ").concat(C.y,")")},g),{},{stroke:"none",fill:u},_),{},{index:S},C),{},{payload:b});return pe.createElement(St,Bp({className:be("recharts-polar-radius-axis-tick",OF(o)),key:"tick-".concat(b.coordinate)},Bl(r.props,b,S)),t.renderTickItem(o,A,f?f(b.value,S):b.value))});return pe.createElement(St,{className:"recharts-polar-radius-axis-ticks"},x)}},{key:"render",value:function(){var r=this.props,i=r.ticks,a=r.axisLine,o=r.tick;return!i||!i.length?null:pe.createElement(St,{className:be("recharts-polar-radius-axis",this.props.className)},a&&this.renderAxisLine(),o&&this.renderTicks(),lr.renderCallByParent(this.props,this.getViewBox()))}}],[{key:"renderTickItem",value:function(r,i,a){var o;return pe.isValidElement(r)?o=pe.cloneElement(r,i):ht(r)?o=r(i):o=pe.createElement(ac,Bp({},i,{className:"recharts-polar-radius-axis-tick-value"}),a),o}}])}(M.PureComponent);x1(S1,"displayName","PolarRadiusAxis");x1(S1,"axisType","radiusAxis");x1(S1,"defaultProps",{type:"number",radiusAxisId:0,cx:0,cy:0,angle:0,orientation:"right",stroke:"#ccc",axisLine:!0,tick:!0,tickCount:5,allowDataOverflow:!1,scale:"auto",allowDuplicatedCategory:!0});function od(e){"@babel/helpers - typeof";return od=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},od(e)}function Iu(){return Iu=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},Iu.apply(this,arguments)}function B8(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 Pu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?B8(Object(n),!0).forEach(function(r){C1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):B8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mbe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function U8(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,zF(r.key),r)}}function gbe(e,t,n){return t&&U8(e.prototype,t),n&&U8(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function vbe(e,t,n){return t=q0(t),ybe(e,UF()?Reflect.construct(t,n||[],q0(e).constructor):t.apply(e,n))}function ybe(e,t){if(t&&(od(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return bbe(e)}function bbe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UF(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(UF=function(){return!!e})()}function q0(e){return q0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},q0(e)}function wbe(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&&bO(e,t)}function bO(e,t){return bO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},bO(e,t)}function C1(e,t,n){return t=zF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zF(e){var t=_be(e,"string");return od(t)=="symbol"?t:t+""}function _be(e,t){if(od(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(od(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var xbe=Math.PI/180,Sbe=1e-5,A1=function(e){function t(){return mbe(this,t),vbe(this,t,arguments)}return wbe(t,e),gbe(t,[{key:"getTickLineCoord",value:function(r){var i=this.props,a=i.cx,o=i.cy,l=i.radius,f=i.orientation,u=i.tickSize,h=u||8,m=cn(a,o,l,r.coordinate),g=cn(a,o,l+(f==="inner"?-1:1)*h,r.coordinate);return{x1:m.x,y1:m.y,x2:g.x,y2:g.y}}},{key:"getTickTextAnchor",value:function(r){var i=this.props.orientation,a=Math.cos(-r.coordinate*xbe),o;return a>Sbe?o=i==="outer"?"start":"end":a<-1e-5?o=i==="outer"?"end":"start":o="middle",o}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.cx,a=r.cy,o=r.radius,l=r.axisLine,f=r.axisLineType,u=Pu(Pu({},ot(this.props,!1)),{},{fill:"none"},ot(l,!1));if(f==="circle")return pe.createElement(pg,Iu({className:"recharts-polar-angle-axis-line"},u,{cx:i,cy:a,r:o}));var h=this.props.ticks,m=h.map(function(g){return cn(i,a,o,g.coordinate)});return pe.createElement(q0e,Iu({className:"recharts-polar-angle-axis-line"},u,{points:m}))}},{key:"renderTicks",value:function(){var r=this,i=this.props,a=i.ticks,o=i.tick,l=i.tickLine,f=i.tickFormatter,u=i.stroke,h=ot(this.props,!1),m=ot(o,!1),g=Pu(Pu({},h),{},{fill:"none"},ot(l,!1)),_=a.map(function(x,b){var S=r.getTickLineCoord(x),C=r.getTickTextAnchor(x),A=Pu(Pu(Pu({textAnchor:C},h),{},{stroke:"none",fill:u},m),{},{index:b,payload:x,x:S.x2,y:S.y2});return pe.createElement(St,Iu({className:be("recharts-polar-angle-axis-tick",OF(o)),key:"tick-".concat(x.coordinate)},Bl(r.props,x,b)),l&&pe.createElement("line",Iu({className:"recharts-polar-angle-axis-tick-line"},g,S)),o&&t.renderTickItem(o,A,f?f(x.value,b):x.value))});return pe.createElement(St,{className:"recharts-polar-angle-axis-ticks"},_)}},{key:"render",value:function(){var r=this.props,i=r.ticks,a=r.radius,o=r.axisLine;return a<=0||!i||!i.length?null:pe.createElement(St,{className:be("recharts-polar-angle-axis",this.props.className)},o&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(r,i,a){var o;return pe.isValidElement(r)?o=pe.cloneElement(r,i):ht(r)?o=r(i):o=pe.createElement(ac,Iu({},i,{className:"recharts-polar-angle-axis-tick-value"}),a),o}}])}(M.PureComponent);C1(A1,"displayName","PolarAngleAxis");C1(A1,"axisType","angleAxis");C1(A1,"defaultProps",{type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,orientation:"outer",axisLine:!0,tickLine:!0,tickSize:8,tick:!0,hide:!1,allowDuplicatedCategory:!0});var ZC,z8;function Cbe(){if(z8)return ZC;z8=1;var e=XU(),t=e(Object.getPrototypeOf,Object);return ZC=t,ZC}var XC,F8;function Abe(){if(F8)return XC;F8=1;var e=hs(),t=Cbe(),n=ps(),r="[object Object]",i=Function.prototype,a=Object.prototype,o=i.toString,l=a.hasOwnProperty,f=o.call(Object);function u(h){if(!n(h)||e(h)!=r)return!1;var m=t(h);if(m===null)return!0;var g=l.call(m,"constructor")&&m.constructor;return typeof g=="function"&&g instanceof g&&o.call(g)==f}return XC=u,XC}var Ebe=Abe();const Obe=zt(Ebe);var QC,q8;function Tbe(){if(q8)return QC;q8=1;var e=hs(),t=ps(),n="[object Boolean]";function r(i){return i===!0||i===!1||t(i)&&e(i)==n}return QC=r,QC}var jbe=Tbe();const Pbe=zt(jbe);function Rm(e){"@babel/helpers - typeof";return Rm=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},Rm(e)}function V0(){return V0=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},V0.apply(this,arguments)}function Rbe(e,t){return kbe(e)||Lbe(e,t)||Nbe(e,t)||Mbe()}function Mbe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Nbe(e,t){if(e){if(typeof e=="string")return V8(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 V8(e,t)}}function V8(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 Lbe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function kbe(e){if(Array.isArray(e))return e}function H8(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 G8(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?H8(Object(n),!0).forEach(function(r){Dbe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):H8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Dbe(e,t,n){return t=Ibe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ibe(e){var t=$be(e,"string");return Rm(t)=="symbol"?t:t+""}function $be(e,t){if(Rm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Rm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var W8=function(t,n,r,i,a){var o=r-i,l;return l="M ".concat(t,",").concat(n),l+="L ".concat(t+r,",").concat(n),l+="L ".concat(t+r-o/2,",").concat(n+a),l+="L ".concat(t+r-o/2-i,",").concat(n+a),l+="L ".concat(t,",").concat(n," Z"),l},Bbe={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Ube=function(t){var n=G8(G8({},Bbe),t),r=M.useRef(),i=M.useState(-1),a=Rbe(i,2),o=a[0],l=a[1];M.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var O=r.current.getTotalLength();O&&l(O)}catch{}},[]);var f=n.x,u=n.y,h=n.upperWidth,m=n.lowerWidth,g=n.height,_=n.className,x=n.animationEasing,b=n.animationDuration,S=n.animationBegin,C=n.isUpdateAnimationActive;if(f!==+f||u!==+u||h!==+h||m!==+m||g!==+g||h===0&&m===0||g===0)return null;var A=be("recharts-trapezoid",_);return C?pe.createElement(ra,{canBegin:o>0,from:{upperWidth:0,lowerWidth:0,height:g,x:f,y:u},to:{upperWidth:h,lowerWidth:m,height:g,x:f,y:u},duration:b,animationEasing:x,isActive:C},function(O){var P=O.upperWidth,j=O.lowerWidth,R=O.height,U=O.x,V=O.y;return pe.createElement(ra,{canBegin:o>0,from:"0px ".concat(o===-1?1:o,"px"),to:"".concat(o,"px 0px"),attributeName:"strokeDasharray",begin:S,duration:b,easing:x},pe.createElement("path",V0({},ot(n,!0),{className:A,d:W8(U,V,P,j,R),ref:r})))}):pe.createElement("g",null,pe.createElement("path",V0({},ot(n,!0),{className:A,d:W8(f,u,h,m,g)})))},zbe=["option","shapeType","propTransformer","activeClassName","isActive"];function Mm(e){"@babel/helpers - typeof";return Mm=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},Mm(e)}function Fbe(e,t){if(e==null)return{};var n=qbe(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function qbe(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 Y8(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 H0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Y8(Object(n),!0).forEach(function(r){Vbe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Y8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vbe(e,t,n){return t=Hbe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hbe(e){var t=Gbe(e,"string");return Mm(t)=="symbol"?t:t+""}function Gbe(e,t){if(Mm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Mm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Wbe(e,t){return H0(H0({},t),e)}function Ybe(e,t){return e==="symbols"}function K8(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return pe.createElement(Y3,n);case"trapezoid":return pe.createElement(Ube,n);case"sector":return pe.createElement(PF,n);case"symbols":if(Ybe(t))return pe.createElement(l1,n);break;default:return null}}function Kbe(e){return M.isValidElement(e)?e.props:e}function G0(e){var t=e.option,n=e.shapeType,r=e.propTransformer,i=r===void 0?Wbe:r,a=e.activeClassName,o=a===void 0?"recharts-active-shape":a,l=e.isActive,f=Fbe(e,zbe),u;if(M.isValidElement(t))u=M.cloneElement(t,H0(H0({},f),Kbe(t)));else if(ht(t))u=t(f);else if(Obe(t)&&!Pbe(t)){var h=i(t,f);u=pe.createElement(K8,{shapeType:n,elementProps:h})}else{var m=f;u=pe.createElement(K8,{shapeType:n,elementProps:m})}return l?pe.createElement(St,{className:o},u):u}function E1(e,t){return t!=null&&"trapezoids"in e.props}function O1(e,t){return t!=null&&"sectors"in e.props}function Nm(e,t){return t!=null&&"points"in e.props}function Zbe(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,a=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return i&&a}function Xbe(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function Qbe(e,t){var n=e.x===t.x,r=e.y===t.y,i=e.z===t.z;return n&&r&&i}function Jbe(e,t){var n;return E1(e,t)?n=Zbe:O1(e,t)?n=Xbe:Nm(e,t)&&(n=Qbe),n}function e1e(e,t){var n;return E1(e,t)?n="trapezoids":O1(e,t)?n="sectors":Nm(e,t)&&(n="points"),n}function t1e(e,t){if(E1(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(O1(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 Nm(e,t)?t.payload:{}}function n1e(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,i=e1e(n,t),a=t1e(n,t),o=r.filter(function(f,u){var h=Ul(a,f),m=n.props[i].filter(function(x){var b=Jbe(n,t);return b(x,t)}),g=n.props[i].indexOf(m[m.length-1]),_=u===g;return h&&_}),l=r.indexOf(o[o.length-1]);return l}var Ny;function sd(e){"@babel/helpers - typeof";return sd=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},sd(e)}function Ef(){return Ef=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},Ef.apply(this,arguments)}function Z8(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 ln(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Z8(Object(n),!0).forEach(function(r){Ji(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Z8(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function r1e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function X8(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,qF(r.key),r)}}function i1e(e,t,n){return t&&X8(e.prototype,t),n&&X8(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function a1e(e,t,n){return t=W0(t),o1e(e,FF()?Reflect.construct(t,n||[],W0(e).constructor):t.apply(e,n))}function o1e(e,t){if(t&&(sd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return s1e(e)}function s1e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function FF(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(FF=function(){return!!e})()}function W0(e){return W0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},W0(e)}function l1e(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&&wO(e,t)}function wO(e,t){return wO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},wO(e,t)}function Ji(e,t,n){return t=qF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qF(e){var t=u1e(e,"string");return sd(t)=="symbol"?t:t+""}function u1e(e,t){if(sd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(sd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var uo=function(e){function t(n){var r;return r1e(this,t),r=a1e(this,t,[n]),Ji(r,"pieRef",null),Ji(r,"sectorRefs",[]),Ji(r,"id",Yl("recharts-pie-")),Ji(r,"handleAnimationEnd",function(){var i=r.props.onAnimationEnd;r.setState({isAnimationFinished:!0}),ht(i)&&i()}),Ji(r,"handleAnimationStart",function(){var i=r.props.onAnimationStart;r.setState({isAnimationFinished:!1}),ht(i)&&i()}),r.state={isAnimationFinished:!n.isAnimationActive,prevIsAnimationActive:n.isAnimationActive,prevAnimationId:n.animationId,sectorToFocus:0},r}return l1e(t,e),i1e(t,[{key:"isActiveIndex",value:function(r){var i=this.props.activeIndex;return Array.isArray(i)?i.indexOf(r)!==-1:r===i}},{key:"hasActiveIndex",value:function(){var r=this.props.activeIndex;return Array.isArray(r)?r.length!==0:r||r===0}},{key:"renderLabels",value:function(r){var i=this.props.isAnimationActive;if(i&&!this.state.isAnimationFinished)return null;var a=this.props,o=a.label,l=a.labelLine,f=a.dataKey,u=a.valueKey,h=ot(this.props,!1),m=ot(o,!1),g=ot(l,!1),_=o&&o.offsetRadius||20,x=r.map(function(b,S){var C=(b.startAngle+b.endAngle)/2,A=cn(b.cx,b.cy,b.outerRadius+_,C),O=ln(ln(ln(ln({},h),b),{},{stroke:"none"},m),{},{index:S,textAnchor:t.getTextAnchor(A.x,b.cx)},A),P=ln(ln(ln(ln({},h),b),{},{fill:"none",stroke:b.fill},g),{},{index:S,points:[cn(b.cx,b.cy,b.outerRadius,C),A]}),j=f;return pt(f)&&pt(u)?j="value":pt(f)&&(j=u),pe.createElement(St,{key:"label-".concat(b.startAngle,"-").concat(b.endAngle,"-").concat(b.midAngle,"-").concat(S)},l&&t.renderLabelLineItem(l,P,"line"),t.renderLabelItem(o,O,hn(b,j)))});return pe.createElement(St,{className:"recharts-pie-labels"},x)}},{key:"renderSectorsStatically",value:function(r){var i=this,a=this.props,o=a.activeShape,l=a.blendStroke,f=a.inactiveShape;return r.map(function(u,h){if((u==null?void 0:u.startAngle)===0&&(u==null?void 0:u.endAngle)===0&&r.length!==1)return null;var m=i.isActiveIndex(h),g=f&&i.hasActiveIndex()?f:null,_=m?o:g,x=ln(ln({},u),{},{stroke:l?u.fill:u.stroke,tabIndex:-1});return pe.createElement(St,Ef({ref:function(S){S&&!i.sectorRefs.includes(S)&&i.sectorRefs.push(S)},tabIndex:-1,className:"recharts-pie-sector"},Bl(i.props,u,h),{key:"sector-".concat(u==null?void 0:u.startAngle,"-").concat(u==null?void 0:u.endAngle,"-").concat(u.midAngle,"-").concat(h)}),pe.createElement(G0,Ef({option:_,isActive:m,shapeType:"sector"},x)))})}},{key:"renderSectorsWithAnimation",value:function(){var r=this,i=this.props,a=i.sectors,o=i.isAnimationActive,l=i.animationBegin,f=i.animationDuration,u=i.animationEasing,h=i.animationId,m=this.state,g=m.prevSectors,_=m.prevIsAnimationActive;return pe.createElement(ra,{begin:l,duration:f,isActive:o,easing:u,from:{t:0},to:{t:1},key:"pie-".concat(h,"-").concat(_),onAnimationStart:this.handleAnimationStart,onAnimationEnd:this.handleAnimationEnd},function(x){var b=x.t,S=[],C=a&&a[0],A=C.startAngle;return a.forEach(function(O,P){var j=g&&g[P],R=P>0?Ti(O,"paddingAngle",0):0;if(j){var U=Cn(j.endAngle-j.startAngle,O.endAngle-O.startAngle),V=ln(ln({},O),{},{startAngle:A+R,endAngle:A+U(b)+R});S.push(V),A=V.endAngle}else{var Y=O.endAngle,K=O.startAngle,W=Cn(0,Y-K),ee=W(b),ie=ln(ln({},O),{},{startAngle:A+R,endAngle:A+ee+R});S.push(ie),A=ie.endAngle}}),pe.createElement(St,null,r.renderSectorsStatically(S))})}},{key:"attachKeyboardHandlers",value:function(r){var i=this;r.onkeydown=function(a){if(!a.altKey)switch(a.key){case"ArrowLeft":{var o=++i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[o].focus(),i.setState({sectorToFocus:o});break}case"ArrowRight":{var l=--i.state.sectorToFocus<0?i.sectorRefs.length-1:i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[l].focus(),i.setState({sectorToFocus:l});break}case"Escape":{i.sectorRefs[i.state.sectorToFocus].blur(),i.setState({sectorToFocus:0});break}}}}},{key:"renderSectors",value:function(){var r=this.props,i=r.sectors,a=r.isAnimationActive,o=this.state.prevSectors;return a&&i&&i.length&&(!o||!Ul(o,i))?this.renderSectorsWithAnimation():this.renderSectorsStatically(i)}},{key:"componentDidMount",value:function(){this.pieRef&&this.attachKeyboardHandlers(this.pieRef)}},{key:"render",value:function(){var r=this,i=this.props,a=i.hide,o=i.sectors,l=i.className,f=i.label,u=i.cx,h=i.cy,m=i.innerRadius,g=i.outerRadius,_=i.isAnimationActive,x=this.state.isAnimationFinished;if(a||!o||!o.length||!Ze(u)||!Ze(h)||!Ze(m)||!Ze(g))return null;var b=be("recharts-pie",l);return pe.createElement(St,{tabIndex:this.props.rootTabIndex,className:b,ref:function(C){r.pieRef=C}},this.renderSectors(),f&&this.renderLabels(o),lr.renderCallByParent(this.props,null,!1),(!_||x)&&xa.renderCallByParent(this.props,o,!1))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return i.prevIsAnimationActive!==r.isAnimationActive?{prevIsAnimationActive:r.isAnimationActive,prevAnimationId:r.animationId,curSectors:r.sectors,prevSectors:[],isAnimationFinished:!0}:r.isAnimationActive&&r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curSectors:r.sectors,prevSectors:i.curSectors,isAnimationFinished:!0}:r.sectors!==i.curSectors?{curSectors:r.sectors,isAnimationFinished:!0}:null}},{key:"getTextAnchor",value:function(r,i){return r>i?"start":r<i?"end":"middle"}},{key:"renderLabelLineItem",value:function(r,i,a){if(pe.isValidElement(r))return pe.cloneElement(r,i);if(ht(r))return r(i);var o=be("recharts-pie-label-line",typeof r!="boolean"?r.className:"");return pe.createElement(El,Ef({},i,{key:a,type:"linear",className:o}))}},{key:"renderLabelItem",value:function(r,i,a){if(pe.isValidElement(r))return pe.cloneElement(r,i);var o=a;if(ht(r)&&(o=r(i),pe.isValidElement(o)))return o;var l=be("recharts-pie-label-text",typeof r!="boolean"&&!ht(r)?r.className:"");return pe.createElement(ac,Ef({},i,{alignmentBaseline:"middle",className:l}),o)}}])}(M.PureComponent);Ny=uo;Ji(uo,"displayName","Pie");Ji(uo,"defaultProps",{stroke:"#fff",fill:"#808080",legendType:"rect",cx:"50%",cy:"50%",startAngle:0,endAngle:360,innerRadius:0,outerRadius:"80%",paddingAngle:0,labelLine:!0,hide:!1,minAngle:0,isAnimationActive:!ms.isSsr,animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1,rootTabIndex:0});Ji(uo,"parseDeltaAngle",function(e,t){var n=Fr(t-e),r=Math.min(Math.abs(t-e),360);return n*r});Ji(uo,"getRealPieData",function(e){var t=e.data,n=e.children,r=ot(e,!1),i=Gr(n,Cl);return t&&t.length?t.map(function(a,o){return ln(ln(ln({payload:a},r),a),i&&i[o]&&i[o].props)}):i&&i.length?i.map(function(a){return ln(ln({},r),a.props)}):[]});Ji(uo,"parseCoordinateOfPie",function(e,t){var n=t.top,r=t.left,i=t.width,a=t.height,o=EF(i,a),l=r+qr(e.cx,i,i/2),f=n+qr(e.cy,a,a/2),u=qr(e.innerRadius,o,0),h=qr(e.outerRadius,o,o*.8),m=e.maxRadius||Math.sqrt(i*i+a*a)/2;return{cx:l,cy:f,innerRadius:u,outerRadius:h,maxRadius:m}});Ji(uo,"getComposedData",function(e){var t=e.item,n=e.offset,r=t.type.defaultProps!==void 0?ln(ln({},t.type.defaultProps),t.props):t.props,i=Ny.getRealPieData(r);if(!i||!i.length)return null;var a=r.cornerRadius,o=r.startAngle,l=r.endAngle,f=r.paddingAngle,u=r.dataKey,h=r.nameKey,m=r.valueKey,g=r.tooltipType,_=Math.abs(r.minAngle),x=Ny.parseCoordinateOfPie(r,n),b=Ny.parseDeltaAngle(o,l),S=Math.abs(b),C=u;pt(u)&&pt(m)?(_a(!1,`Use "dataKey" to specify the value of pie,
|
||
the props "valueKey" will be deprecated in 1.1.0`),C="value"):pt(u)&&(_a(!1,`Use "dataKey" to specify the value of pie,
|
||
the props "valueKey" will be deprecated in 1.1.0`),C=m);var A=i.filter(function(V){return hn(V,C,0)!==0}).length,O=(S>=360?A:A-1)*f,P=S-A*_-O,j=i.reduce(function(V,Y){var K=hn(Y,C,0);return V+(Ze(K)?K:0)},0),R;if(j>0){var U;R=i.map(function(V,Y){var K=hn(V,C,0),W=hn(V,h,Y),ee=(Ze(K)?K:0)/j,ie;Y?ie=U.endAngle+Fr(b)*f*(K!==0?1:0):ie=o;var X=ie+Fr(b)*((K!==0?_:0)+ee*P),ne=(ie+X)/2,H=(x.innerRadius+x.outerRadius)/2,I=[{name:W,value:K,payload:V,dataKey:C,type:g}],D=cn(x.cx,x.cy,H,ne);return U=ln(ln(ln({percent:ee,cornerRadius:a,name:W,tooltipPayload:I,midAngle:ne,middleRadius:H,tooltipPosition:D},V),x),{},{value:hn(V,C),startAngle:ie,endAngle:X,payload:V,paddingAngle:Fr(b)*f}),U})}return ln(ln({},x),{},{sectors:R,data:i})});var JC,Q8;function c1e(){if(Q8)return JC;Q8=1;var e=Math.ceil,t=Math.max;function n(r,i,a,o){for(var l=-1,f=t(e((i-r)/(a||1)),0),u=Array(f);f--;)u[o?f:++l]=r,r+=a;return u}return JC=n,JC}var eA,J8;function VF(){if(J8)return eA;J8=1;var e=hz(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-1/0){var a=i<0?-1:1;return a*n}return i===i?i:0}return eA=r,eA}var tA,eI;function f1e(){if(eI)return tA;eI=1;var e=c1e(),t=f1(),n=VF();function r(i){return function(a,o,l){return l&&typeof l!="number"&&t(a,o,l)&&(o=l=void 0),a=n(a),o===void 0?(o=a,a=0):o=n(o),l=l===void 0?a<o?1:-1:n(l),e(a,o,l,i)}}return tA=r,tA}var nA,tI;function d1e(){if(tI)return nA;tI=1;var e=f1e(),t=e();return nA=t,nA}var h1e=d1e();const Y0=zt(h1e);function Lm(e){"@babel/helpers - typeof";return Lm=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},Lm(e)}function nI(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 rI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?nI(Object(n),!0).forEach(function(r){HF(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function HF(e,t,n){return t=p1e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function p1e(e){var t=m1e(e,"string");return Lm(t)=="symbol"?t:t+""}function m1e(e,t){if(Lm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Lm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var g1e=["Webkit","Moz","O","ms"],v1e=function(t,n){var r=t.replace(/(\w)/,function(a){return a.toUpperCase()}),i=g1e.reduce(function(a,o){return rI(rI({},a),{},HF({},o+r,n))},{});return i[t]=n,i};function ld(e){"@babel/helpers - typeof";return ld=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},ld(e)}function K0(){return K0=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},K0.apply(this,arguments)}function iI(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 rA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?iI(Object(n),!0).forEach(function(r){bi(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function y1e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function aI(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,WF(r.key),r)}}function b1e(e,t,n){return t&&aI(e.prototype,t),n&&aI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function w1e(e,t,n){return t=Z0(t),_1e(e,GF()?Reflect.construct(t,n||[],Z0(e).constructor):t.apply(e,n))}function _1e(e,t){if(t&&(ld(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return x1e(e)}function x1e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function GF(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(GF=function(){return!!e})()}function Z0(e){return Z0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Z0(e)}function S1e(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&&_O(e,t)}function _O(e,t){return _O=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},_O(e,t)}function bi(e,t,n){return t=WF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function WF(e){var t=C1e(e,"string");return ld(t)=="symbol"?t:t+""}function C1e(e,t){if(ld(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ld(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var A1e=function(t){var n=t.data,r=t.startIndex,i=t.endIndex,a=t.x,o=t.width,l=t.travellerWidth;if(!n||!n.length)return{};var f=n.length,u=kp().domain(Y0(0,f)).range([a,a+o-l]),h=u.domain().map(function(m){return u(m)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:u(r),endX:u(i),scale:u,scaleValues:h}},oI=function(t){return t.changedTouches&&!!t.changedTouches.length},ud=function(e){function t(n){var r;return y1e(this,t),r=w1e(this,t,[n]),bi(r,"handleDrag",function(i){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(i):r.state.isSlideMoving&&r.handleSlideDrag(i)}),bi(r,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&r.handleDrag(i.changedTouches[0])}),bi(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=r.props,a=i.endIndex,o=i.onDragEnd,l=i.startIndex;o==null||o({endIndex:a,startIndex:l})}),r.detachDragEndListener()}),bi(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),bi(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),bi(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),bi(r,"handleSlideDragStart",function(i){var a=oI(i)?i.changedTouches[0]:i;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:a.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return S1e(t,e),b1e(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var i=r.startX,a=r.endX,o=this.state.scaleValues,l=this.props,f=l.gap,u=l.data,h=u.length-1,m=Math.min(i,a),g=Math.max(i,a),_=t.getIndexInRange(o,m),x=t.getIndexInRange(o,g);return{startIndex:_-_%f,endIndex:x===h?h:x-x%f}}},{key:"getTextOfTick",value:function(r){var i=this.props,a=i.data,o=i.tickFormatter,l=i.dataKey,f=hn(a[r],l,r);return ht(o)?o(f,r):f}},{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,a=i.slideMoveStartX,o=i.startX,l=i.endX,f=this.props,u=f.x,h=f.width,m=f.travellerWidth,g=f.startIndex,_=f.endIndex,x=f.onChange,b=r.pageX-a;b>0?b=Math.min(b,u+h-m-l,u+h-m-o):b<0&&(b=Math.max(b,u-o,u-l));var S=this.getIndex({startX:o+b,endX:l+b});(S.startIndex!==g||S.endIndex!==_)&&x&&x(S),this.setState({startX:o+b,endX:l+b,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,i){var a=oI(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:a.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var i=this.state,a=i.brushMoveStartX,o=i.movingTravellerId,l=i.endX,f=i.startX,u=this.state[o],h=this.props,m=h.x,g=h.width,_=h.travellerWidth,x=h.onChange,b=h.gap,S=h.data,C={startX:this.state.startX,endX:this.state.endX},A=r.pageX-a;A>0?A=Math.min(A,m+g-_-u):A<0&&(A=Math.max(A,m-u)),C[o]=u+A;var O=this.getIndex(C),P=O.startIndex,j=O.endIndex,R=function(){var V=S.length-1;return o==="startX"&&(l>f?P%b===0:j%b===0)||l<f&&j===V||o==="endX"&&(l>f?j%b===0:P%b===0)||l>f&&j===V};this.setState(bi(bi({},o,u+A),"brushMoveStartX",r.pageX),function(){x&&R()&&x(O)})}},{key:"handleTravellerMoveKeyboard",value:function(r,i){var a=this,o=this.state,l=o.scaleValues,f=o.startX,u=o.endX,h=this.state[i],m=l.indexOf(h);if(m!==-1){var g=m+r;if(!(g===-1||g>=l.length)){var _=l[g];i==="startX"&&_>=u||i==="endX"&&_<=f||this.setState(bi({},i,_),function(){a.props.onChange(a.getIndex({startX:a.state.startX,endX:a.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,i=r.x,a=r.y,o=r.width,l=r.height,f=r.fill,u=r.stroke;return pe.createElement("rect",{stroke:u,fill:f,x:i,y:a,width:o,height:l})}},{key:"renderPanorama",value:function(){var r=this.props,i=r.x,a=r.y,o=r.width,l=r.height,f=r.data,u=r.children,h=r.padding,m=M.Children.only(u);return m?pe.cloneElement(m,{x:i,y:a,width:o,height:l,margin:h,compact:!0,data:f}):null}},{key:"renderTravellerLayer",value:function(r,i){var a,o,l=this,f=this.props,u=f.y,h=f.travellerWidth,m=f.height,g=f.traveller,_=f.ariaLabel,x=f.data,b=f.startIndex,S=f.endIndex,C=Math.max(r,this.props.x),A=rA(rA({},ot(this.props,!1)),{},{x:C,y:u,width:h,height:m}),O=_||"Min value: ".concat((a=x[b])===null||a===void 0?void 0:a.name,", Max value: ").concat((o=x[S])===null||o===void 0?void 0:o.name);return pe.createElement(St,{tabIndex:0,role:"slider","aria-label":O,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(j){["ArrowLeft","ArrowRight"].includes(j.key)&&(j.preventDefault(),j.stopPropagation(),l.handleTravellerMoveKeyboard(j.key==="ArrowRight"?1:-1,i))},onFocus:function(){l.setState({isTravellerFocused:!0})},onBlur:function(){l.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(g,A))}},{key:"renderSlide",value:function(r,i){var a=this.props,o=a.y,l=a.height,f=a.stroke,u=a.travellerWidth,h=Math.min(r,i)+u,m=Math.max(Math.abs(i-r)-u,0);return pe.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:f,fillOpacity:.2,x:h,y:o,width:m,height:l})}},{key:"renderText",value:function(){var r=this.props,i=r.startIndex,a=r.endIndex,o=r.y,l=r.height,f=r.travellerWidth,u=r.stroke,h=this.state,m=h.startX,g=h.endX,_=5,x={pointerEvents:"none",fill:u};return pe.createElement(St,{className:"recharts-brush-texts"},pe.createElement(ac,K0({textAnchor:"end",verticalAnchor:"middle",x:Math.min(m,g)-_,y:o+l/2},x),this.getTextOfTick(i)),pe.createElement(ac,K0({textAnchor:"start",verticalAnchor:"middle",x:Math.max(m,g)+f+_,y:o+l/2},x),this.getTextOfTick(a)))}},{key:"render",value:function(){var r=this.props,i=r.data,a=r.className,o=r.children,l=r.x,f=r.y,u=r.width,h=r.height,m=r.alwaysShowText,g=this.state,_=g.startX,x=g.endX,b=g.isTextActive,S=g.isSlideMoving,C=g.isTravellerMoving,A=g.isTravellerFocused;if(!i||!i.length||!Ze(l)||!Ze(f)||!Ze(u)||!Ze(h)||u<=0||h<=0)return null;var O=be("recharts-brush",a),P=pe.Children.count(o)===1,j=v1e("userSelect","none");return pe.createElement(St,{className:O,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:j},this.renderBackground(),P&&this.renderPanorama(),this.renderSlide(_,x),this.renderTravellerLayer(_,"startX"),this.renderTravellerLayer(x,"endX"),(b||S||C||A||m)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var i=r.x,a=r.y,o=r.width,l=r.height,f=r.stroke,u=Math.floor(a+l/2)-1;return pe.createElement(pe.Fragment,null,pe.createElement("rect",{x:i,y:a,width:o,height:l,fill:f,stroke:"none"}),pe.createElement("line",{x1:i+1,y1:u,x2:i+o-1,y2:u,fill:"none",stroke:"#fff"}),pe.createElement("line",{x1:i+1,y1:u+2,x2:i+o-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,i){var a;return pe.isValidElement(r)?a=pe.cloneElement(r,i):ht(r)?a=r(i):a=t.renderDefaultTraveller(i),a}},{key:"getDerivedStateFromProps",value:function(r,i){var a=r.data,o=r.width,l=r.x,f=r.travellerWidth,u=r.updateId,h=r.startIndex,m=r.endIndex;if(a!==i.prevData||u!==i.prevUpdateId)return rA({prevData:a,prevTravellerWidth:f,prevUpdateId:u,prevX:l,prevWidth:o},a&&a.length?A1e({data:a,width:o,x:l,travellerWidth:f,startIndex:h,endIndex:m}):{scale:null,scaleValues:null});if(i.scale&&(o!==i.prevWidth||l!==i.prevX||f!==i.prevTravellerWidth)){i.scale.range([l,l+o-f]);var g=i.scale.domain().map(function(_){return i.scale(_)});return{prevData:a,prevTravellerWidth:f,prevUpdateId:u,prevX:l,prevWidth:o,startX:i.scale(r.startIndex),endX:i.scale(r.endIndex),scaleValues:g}}return null}},{key:"getIndexInRange",value:function(r,i){for(var a=r.length,o=0,l=a-1;l-o>1;){var f=Math.floor((o+l)/2);r[f]>i?l=f:o=f}return i>=r[l]?l:o}}])}(M.PureComponent);bi(ud,"displayName","Brush");bi(ud,"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 iA,sI;function E1e(){if(sI)return iA;sI=1;var e=w3();function t(n,r){var i;return e(n,function(a,o,l){return i=r(a,o,l),!i}),!!i}return iA=t,iA}var aA,lI;function O1e(){if(lI)return aA;lI=1;var e=VU(),t=vo(),n=E1e(),r=ri(),i=f1();function a(o,l,f){var u=r(o)?e:n;return f&&i(o,l,f)&&(l=void 0),u(o,t(l,3))}return aA=a,aA}var T1e=O1e();const j1e=zt(T1e);var oo=function(t,n){var r=t.alwaysShow,i=t.ifOverflow;return r&&(i="extendDomain"),i===n},oA,uI;function P1e(){if(uI)return oA;uI=1;var e=lz();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return oA=t,oA}var sA,cI;function R1e(){if(cI)return sA;cI=1;var e=P1e(),t=oz(),n=vo();function r(i,a){var o={};return a=n(a,3),t(i,function(l,f,u){e(o,f,a(l,f,u))}),o}return sA=r,sA}var M1e=R1e();const N1e=zt(M1e);var lA,fI;function L1e(){if(fI)return lA;fI=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 lA=e,lA}var uA,dI;function k1e(){if(dI)return uA;dI=1;var e=w3();function t(n,r){var i=!0;return e(n,function(a,o,l){return i=!!r(a,o,l),i}),i}return uA=t,uA}var cA,hI;function D1e(){if(hI)return cA;hI=1;var e=L1e(),t=k1e(),n=vo(),r=ri(),i=f1();function a(o,l,f){var u=r(o)?e:t;return f&&i(o,l,f)&&(l=void 0),u(o,n(l,3))}return cA=a,cA}var I1e=D1e();const YF=zt(I1e);var $1e=["x","y"];function km(e){"@babel/helpers - typeof";return km=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},km(e)}function xO(){return xO=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},xO.apply(this,arguments)}function pI(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 pp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pI(Object(n),!0).forEach(function(r){B1e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function B1e(e,t,n){return t=U1e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function U1e(e){var t=z1e(e,"string");return km(t)=="symbol"?t:t+""}function z1e(e,t){if(km(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(km(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function F1e(e,t){if(e==null)return{};var n=q1e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function q1e(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 V1e(e,t){var n=e.x,r=e.y,i=F1e(e,$1e),a="".concat(n),o=parseInt(a,10),l="".concat(r),f=parseInt(l,10),u="".concat(t.height||i.height),h=parseInt(u,10),m="".concat(t.width||i.width),g=parseInt(m,10);return pp(pp(pp(pp(pp({},t),i),o?{x:o}:{}),f?{y:f}:{}),{},{height:h,width:g,name:t.name,radius:t.radius})}function mI(e){return pe.createElement(G0,xO({shapeType:"rectangle",propTransformer:V1e,activeClassName:"recharts-active-bar"},e))}var H1e=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 a=typeof r=="number";return a?t(r,i):(a||sc(),n)}},G1e=["value","background"],KF;function cd(e){"@babel/helpers - typeof";return cd=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},cd(e)}function W1e(e,t){if(e==null)return{};var n=Y1e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Y1e(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 X0(){return X0=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},X0.apply(this,arguments)}function gI(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 Un(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gI(Object(n),!0).forEach(function(r){_l(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function K1e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function vI(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,XF(r.key),r)}}function Z1e(e,t,n){return t&&vI(e.prototype,t),n&&vI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function X1e(e,t,n){return t=Q0(t),Q1e(e,ZF()?Reflect.construct(t,n||[],Q0(e).constructor):t.apply(e,n))}function Q1e(e,t){if(t&&(cd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return J1e(e)}function J1e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZF(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ZF=function(){return!!e})()}function Q0(e){return Q0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Q0(e)}function ewe(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&&SO(e,t)}function SO(e,t){return SO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},SO(e,t)}function _l(e,t,n){return t=XF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function XF(e){var t=twe(e,"string");return cd(t)=="symbol"?t:t+""}function twe(e,t){if(cd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var ts=function(e){function t(){var n;K1e(this,t);for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];return n=X1e(this,t,[].concat(i)),_l(n,"state",{isAnimationFinished:!1}),_l(n,"id",Yl("recharts-bar-")),_l(n,"handleAnimationEnd",function(){var o=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),o&&o()}),_l(n,"handleAnimationStart",function(){var o=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),o&&o()}),n}return ewe(t,e),Z1e(t,[{key:"renderRectanglesStatically",value:function(r){var i=this,a=this.props,o=a.shape,l=a.dataKey,f=a.activeIndex,u=a.activeBar,h=ot(this.props,!1);return r&&r.map(function(m,g){var _=g===f,x=_?u:o,b=Un(Un(Un({},h),m),{},{isActive:_,option:x,index:g,dataKey:l,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return pe.createElement(St,X0({className:"recharts-bar-rectangle"},Bl(i.props,m,g),{key:"rectangle-".concat(m==null?void 0:m.x,"-").concat(m==null?void 0:m.y,"-").concat(m==null?void 0:m.value,"-").concat(g)}),pe.createElement(mI,b))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,i=this.props,a=i.data,o=i.layout,l=i.isAnimationActive,f=i.animationBegin,u=i.animationDuration,h=i.animationEasing,m=i.animationId,g=this.state.prevData;return pe.createElement(ra,{begin:f,duration:u,isActive:l,easing:h,from:{t:0},to:{t:1},key:"bar-".concat(m),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(_){var x=_.t,b=a.map(function(S,C){var A=g&&g[C];if(A){var O=Cn(A.x,S.x),P=Cn(A.y,S.y),j=Cn(A.width,S.width),R=Cn(A.height,S.height);return Un(Un({},S),{},{x:O(x),y:P(x),width:j(x),height:R(x)})}if(o==="horizontal"){var U=Cn(0,S.height),V=U(x);return Un(Un({},S),{},{y:S.y+S.height-V,height:V})}var Y=Cn(0,S.width),K=Y(x);return Un(Un({},S),{},{width:K})});return pe.createElement(St,null,r.renderRectanglesStatically(b))})}},{key:"renderRectangles",value:function(){var r=this.props,i=r.data,a=r.isAnimationActive,o=this.state.prevData;return a&&i&&i.length&&(!o||!Ul(o,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var r=this,i=this.props,a=i.data,o=i.dataKey,l=i.activeIndex,f=ot(this.props.background,!1);return a.map(function(u,h){u.value;var m=u.background,g=W1e(u,G1e);if(!m)return null;var _=Un(Un(Un(Un(Un({},g),{},{fill:"#eee"},m),f),Bl(r.props,u,h)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:o,index:h,className:"recharts-bar-background-rectangle"});return pe.createElement(mI,X0({key:"background-bar-".concat(h),option:r.props.background,isActive:h===l},_))})}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var a=this.props,o=a.data,l=a.xAxis,f=a.yAxis,u=a.layout,h=a.children,m=Gr(h,qd);if(!m)return null;var g=u==="vertical"?o[0].height/2:o[0].width/2,_=function(S,C){var A=Array.isArray(S.value)?S.value[1]:S.value;return{x:S.x,y:S.y,value:A,errorVal:hn(S,C)}},x={clipPath:r?"url(#clipPath-".concat(i,")"):null};return pe.createElement(St,x,m.map(function(b){return pe.cloneElement(b,{key:"error-bar-".concat(i,"-").concat(b.props.dataKey),data:o,xAxis:l,yAxis:f,layout:u,offset:g,dataPointFormatter:_})}))}},{key:"render",value:function(){var r=this.props,i=r.hide,a=r.data,o=r.className,l=r.xAxis,f=r.yAxis,u=r.left,h=r.top,m=r.width,g=r.height,_=r.isAnimationActive,x=r.background,b=r.id;if(i||!a||!a.length)return null;var S=this.state.isAnimationFinished,C=be("recharts-bar",o),A=l&&l.allowDataOverflow,O=f&&f.allowDataOverflow,P=A||O,j=pt(b)?this.id:b;return pe.createElement(St,{className:C},A||O?pe.createElement("defs",null,pe.createElement("clipPath",{id:"clipPath-".concat(j)},pe.createElement("rect",{x:A?u:u-m/2,y:O?h:h-g/2,width:A?m:m*2,height:O?g:g*2}))):null,pe.createElement(St,{className:"recharts-bar-rectangles",clipPath:P?"url(#clipPath-".concat(j,")"):null},x?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(P,j),(!_||S)&&xa.renderCallByParent(this.props,a))}}],[{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}}])}(M.PureComponent);KF=ts;_l(ts,"displayName","Bar");_l(ts,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!ms.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});_l(ts,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,i=e.bandSize,a=e.xAxis,o=e.yAxis,l=e.xAxisTicks,f=e.yAxisTicks,u=e.stackedData,h=e.dataStartIndex,m=e.displayedData,g=e.offset,_=Nge(r,n);if(!_)return null;var x=t.layout,b=n.type.defaultProps,S=b!==void 0?Un(Un({},b),n.props):n.props,C=S.dataKey,A=S.children,O=S.minPointSize,P=x==="horizontal"?o:a,j=u?P.scale.domain():null,R=Uge({numericAxis:P}),U=Gr(A,Cl),V=m.map(function(Y,K){var W,ee,ie,X,ne,H;u?W=Lge(u[h+K],j):(W=hn(Y,C),Array.isArray(W)||(W=[R,W]));var I=H1e(O,KF.defaultProps.minPointSize)(W[1],K);if(x==="horizontal"){var D,z=[o.scale(W[0]),o.scale(W[1])],N=z[0],B=z[1];ee=GD({axis:a,ticks:l,bandSize:i,offset:_.offset,entry:Y,index:K}),ie=(D=B??N)!==null&&D!==void 0?D:void 0,X=_.size;var Q=N-B;if(ne=Number.isNaN(Q)?0:Q,H={x:ee,y:o.y,width:X,height:o.height},Math.abs(I)>0&&Math.abs(ne)<Math.abs(I)){var G=Fr(ne||I)*(Math.abs(I)-Math.abs(ne));ie-=G,ne+=G}}else{var ae=[a.scale(W[0]),a.scale(W[1])],fe=ae[0],ce=ae[1];if(ee=fe,ie=GD({axis:o,ticks:f,bandSize:i,offset:_.offset,entry:Y,index:K}),X=ce-fe,ne=_.size,H={x:a.x,y:ie,width:a.width,height:ne},Math.abs(I)>0&&Math.abs(X)<Math.abs(I)){var ye=Fr(X||I)*(Math.abs(I)-Math.abs(X));X+=ye}}return Un(Un(Un({},Y),{},{x:ee,y:ie,width:X,height:ne,value:u?W:W[1],payload:Y,background:H},U&&U[K]&&U[K].props),{},{tooltipPayload:[CF(n,Y)],tooltipPosition:{x:ee+X/2,y:ie+ne/2}})});return Un({data:V,layout:x},g)});function Dm(e){"@babel/helpers - typeof";return Dm=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},Dm(e)}function nwe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function yI(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,QF(r.key),r)}}function rwe(e,t,n){return t&&yI(e.prototype,t),n&&yI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function bI(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 va(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?bI(Object(n),!0).forEach(function(r){T1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function T1(e,t,n){return t=QF(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function QF(e){var t=iwe(e,"string");return Dm(t)=="symbol"?t:t+""}function iwe(e,t){if(Dm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Dm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var JF=function(t,n,r,i,a){var o=t.width,l=t.height,f=t.layout,u=t.children,h=Object.keys(n),m={left:r.left,leftMirror:r.left,right:o-r.right,rightMirror:o-r.right,top:r.top,topMirror:r.top,bottom:l-r.bottom,bottomMirror:l-r.bottom},g=!!_i(u,ts);return h.reduce(function(_,x){var b=n[x],S=b.orientation,C=b.domain,A=b.padding,O=A===void 0?{}:A,P=b.mirror,j=b.reversed,R="".concat(S).concat(P?"Mirror":""),U,V,Y,K,W;if(b.type==="number"&&(b.padding==="gap"||b.padding==="no-gap")){var ee=C[1]-C[0],ie=1/0,X=b.categoricalDomain.sort(_le);if(X.forEach(function(ae,fe){fe>0&&(ie=Math.min((ae||0)-(X[fe-1]||0),ie))}),Number.isFinite(ie)){var ne=ie/ee,H=b.layout==="vertical"?r.height:r.width;if(b.padding==="gap"&&(U=ne*H/2),b.padding==="no-gap"){var I=qr(t.barCategoryGap,ne*H),D=ne*H/2;U=D-I-(D-I)/H*I}}}i==="xAxis"?V=[r.left+(O.left||0)+(U||0),r.left+r.width-(O.right||0)-(U||0)]:i==="yAxis"?V=f==="horizontal"?[r.top+r.height-(O.bottom||0),r.top+(O.top||0)]:[r.top+(O.top||0)+(U||0),r.top+r.height-(O.bottom||0)-(U||0)]:V=b.range,j&&(V=[V[1],V[0]]);var z=wF(b,a,g),N=z.scale,B=z.realScaleType;N.domain(C).range(V),_F(N);var Q=xF(N,va(va({},b),{},{realScaleType:B}));i==="xAxis"?(W=S==="top"&&!P||S==="bottom"&&P,Y=r.left,K=m[R]-W*b.height):i==="yAxis"&&(W=S==="left"&&!P||S==="right"&&P,Y=m[R]-W*b.width,K=r.top);var G=va(va(va({},b),Q),{},{realScaleType:B,x:Y,y:K,scale:N,width:i==="xAxis"?r.width:b.width,height:i==="yAxis"?r.height:b.height});return G.bandSize=k0(G,Q),!b.hide&&i==="xAxis"?m[R]+=(W?-1:1)*G.height:b.hide||(m[R]+=(W?-1:1)*G.width),va(va({},_),{},T1({},x,G))},{})},eq=function(t,n){var r=t.x,i=t.y,a=n.x,o=n.y;return{x:Math.min(r,a),y:Math.min(i,o),width:Math.abs(a-r),height:Math.abs(o-i)}},awe=function(t){var n=t.x1,r=t.y1,i=t.x2,a=t.y2;return eq({x:n,y:r},{x:i,y:a})},tq=function(){function e(t){nwe(this,e),this.scale=t}return rwe(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,a=r.position;if(n!==void 0){if(a)switch(a){case"start":return this.scale(n);case"middle":{var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+o}case"end":{var l=this.bandwidth?this.bandwidth():0;return this.scale(n)+l}default:return this.scale(n)}if(i){var f=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+f}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),i=r[0],a=r[r.length-1];return i<=a?n>=i&&n<=a:n>=a&&n<=i}}],[{key:"create",value:function(n){return new e(n)}}])}();T1(tq,"EPS",1e-4);var K3=function(t){var n=Object.keys(t).reduce(function(r,i){return va(va({},r),{},T1({},i,tq.create(t[i])))},{});return va(va({},n),{},{apply:function(i){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=a.bandAware,l=a.position;return N1e(i,function(f,u){return n[u].apply(f,{bandAware:o,position:l})})},isInRange:function(i){return YF(i,function(a,o){return n[o].isInRange(a)})}})};function owe(e){return(e%180+180)%180}var swe=function(t){var n=t.width,r=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,a=owe(i),o=a*Math.PI/180,l=Math.atan(r/n),f=o>l&&o<Math.PI-l?r/Math.sin(o):n/Math.cos(o);return Math.abs(f)},fA,wI;function lwe(){if(wI)return fA;wI=1;var e=vo(),t=ug(),n=u1();function r(i){return function(a,o,l){var f=Object(a);if(!t(a)){var u=e(o,3);a=n(a),o=function(m){return u(f[m],m,f)}}var h=i(a,o,l);return h>-1?f[u?a[h]:h]:void 0}}return fA=r,fA}var dA,_I;function uwe(){if(_I)return dA;_I=1;var e=VF();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return dA=t,dA}var hA,xI;function cwe(){if(xI)return hA;xI=1;var e=tz(),t=vo(),n=uwe(),r=Math.max;function i(a,o,l){var f=a==null?0:a.length;if(!f)return-1;var u=l==null?0:n(l);return u<0&&(u=r(f+u,0)),e(a,t(o,3),u)}return hA=i,hA}var pA,SI;function fwe(){if(SI)return pA;SI=1;var e=lwe(),t=cwe(),n=e(t);return pA=n,pA}var dwe=fwe();const hwe=zt(dwe);var pwe=gU();const mwe=zt(pwe);var gwe=mwe(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("")}),Z3=M.createContext(void 0),X3=M.createContext(void 0),nq=M.createContext(void 0),rq=M.createContext({}),iq=M.createContext(void 0),aq=M.createContext(0),oq=M.createContext(0),CI=function(t){var n=t.state,r=n.xAxisMap,i=n.yAxisMap,a=n.offset,o=t.clipPathId,l=t.children,f=t.width,u=t.height,h=gwe(a);return pe.createElement(Z3.Provider,{value:r},pe.createElement(X3.Provider,{value:i},pe.createElement(rq.Provider,{value:a},pe.createElement(nq.Provider,{value:h},pe.createElement(iq.Provider,{value:o},pe.createElement(aq.Provider,{value:u},pe.createElement(oq.Provider,{value:f},l)))))))},vwe=function(){return M.useContext(iq)},sq=function(t){var n=M.useContext(Z3);n==null&&sc();var r=n[t];return r==null&&sc(),r},ywe=function(){var t=M.useContext(Z3);return vl(t)},bwe=function(){var t=M.useContext(X3),n=hwe(t,function(r){return YF(r.domain,Number.isFinite)});return n||vl(t)},lq=function(t){var n=M.useContext(X3);n==null&&sc();var r=n[t];return r==null&&sc(),r},wwe=function(){var t=M.useContext(nq);return t},_we=function(){return M.useContext(rq)},Q3=function(){return M.useContext(oq)},J3=function(){return M.useContext(aq)};function fd(e){"@babel/helpers - typeof";return fd=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},fd(e)}function xwe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Swe(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,cq(r.key),r)}}function Cwe(e,t,n){return t&&Swe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Awe(e,t,n){return t=J0(t),Ewe(e,uq()?Reflect.construct(t,n||[],J0(e).constructor):t.apply(e,n))}function Ewe(e,t){if(t&&(fd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Owe(e)}function Owe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(uq=function(){return!!e})()}function J0(e){return J0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},J0(e)}function Twe(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&&CO(e,t)}function CO(e,t){return CO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},CO(e,t)}function AI(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 EI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?AI(Object(n),!0).forEach(function(r){e4(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):AI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function e4(e,t,n){return t=cq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cq(e){var t=jwe(e,"string");return fd(t)=="symbol"?t:t+""}function jwe(e,t){if(fd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(fd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Pwe(e,t){return Lwe(e)||Nwe(e,t)||Mwe(e,t)||Rwe()}function Rwe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Mwe(e,t){if(e){if(typeof e=="string")return OI(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 OI(e,t)}}function OI(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 Nwe(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function Lwe(e){if(Array.isArray(e))return e}function AO(){return AO=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},AO.apply(this,arguments)}var kwe=function(t,n){var r;return pe.isValidElement(t)?r=pe.cloneElement(t,n):ht(t)?r=t(n):r=pe.createElement("line",AO({},n,{className:"recharts-reference-line-line"})),r},Dwe=function(t,n,r,i,a,o,l,f,u){var h=a.x,m=a.y,g=a.width,_=a.height;if(r){var x=u.y,b=t.y.apply(x,{position:o});if(oo(u,"discard")&&!t.y.isInRange(b))return null;var S=[{x:h+g,y:b},{x:h,y:b}];return f==="left"?S.reverse():S}if(n){var C=u.x,A=t.x.apply(C,{position:o});if(oo(u,"discard")&&!t.x.isInRange(A))return null;var O=[{x:A,y:m+_},{x:A,y:m}];return l==="top"?O.reverse():O}if(i){var P=u.segment,j=P.map(function(R){return t.apply(R,{position:o})});return oo(u,"discard")&&j1e(j,function(R){return!t.isInRange(R)})?null:j}return null};function Iwe(e){var t=e.x,n=e.y,r=e.segment,i=e.xAxisId,a=e.yAxisId,o=e.shape,l=e.className,f=e.alwaysShow,u=vwe(),h=sq(i),m=lq(a),g=wwe();if(!u||!g)return null;_a(f===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var _=K3({x:h.scale,y:m.scale}),x=Kn(t),b=Kn(n),S=r&&r.length===2,C=Dwe(_,x,b,S,g,e.position,h.orientation,m.orientation,e);if(!C)return null;var A=Pwe(C,2),O=A[0],P=O.x,j=O.y,R=A[1],U=R.x,V=R.y,Y=oo(e,"hidden")?"url(#".concat(u,")"):void 0,K=EI(EI({clipPath:Y},ot(e,!0)),{},{x1:P,y1:j,x2:U,y2:V});return pe.createElement(St,{className:be("recharts-reference-line",l)},kwe(o,K),lr.renderCallByParent(e,awe({x1:P,y1:j,x2:U,y2:V})))}var t4=function(e){function t(){return xwe(this,t),Awe(this,t,arguments)}return Twe(t,e),Cwe(t,[{key:"render",value:function(){return pe.createElement(Iwe,this.props)}}])}(pe.Component);e4(t4,"displayName","ReferenceLine");e4(t4,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function EO(){return EO=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},EO.apply(this,arguments)}function dd(e){"@babel/helpers - typeof";return dd=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},dd(e)}function TI(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 jI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?TI(Object(n),!0).forEach(function(r){j1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):TI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $we(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Bwe(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,dq(r.key),r)}}function Uwe(e,t,n){return t&&Bwe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function zwe(e,t,n){return t=eb(t),Fwe(e,fq()?Reflect.construct(t,n||[],eb(e).constructor):t.apply(e,n))}function Fwe(e,t){if(t&&(dd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return qwe(e)}function qwe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(fq=function(){return!!e})()}function eb(e){return eb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},eb(e)}function Vwe(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&&OO(e,t)}function OO(e,t){return OO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},OO(e,t)}function j1(e,t,n){return t=dq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function dq(e){var t=Hwe(e,"string");return dd(t)=="symbol"?t:t+""}function Hwe(e,t){if(dd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(dd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Gwe=function(t){var n=t.x,r=t.y,i=t.xAxis,a=t.yAxis,o=K3({x:i.scale,y:a.scale}),l=o.apply({x:n,y:r},{bandAware:!0});return oo(t,"discard")&&!o.isInRange(l)?null:l},P1=function(e){function t(){return $we(this,t),zwe(this,t,arguments)}return Vwe(t,e),Uwe(t,[{key:"render",value:function(){var r=this.props,i=r.x,a=r.y,o=r.r,l=r.alwaysShow,f=r.clipPathId,u=Kn(i),h=Kn(a);if(_a(l===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!u||!h)return null;var m=Gwe(this.props);if(!m)return null;var g=m.x,_=m.y,x=this.props,b=x.shape,S=x.className,C=oo(this.props,"hidden")?"url(#".concat(f,")"):void 0,A=jI(jI({clipPath:C},ot(this.props,!0)),{},{cx:g,cy:_});return pe.createElement(St,{className:be("recharts-reference-dot",S)},t.renderDot(b,A),lr.renderCallByParent(this.props,{x:g-o,y:_-o,width:2*o,height:2*o}))}}])}(pe.Component);j1(P1,"displayName","ReferenceDot");j1(P1,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});j1(P1,"renderDot",function(e,t){var n;return pe.isValidElement(e)?n=pe.cloneElement(e,t):ht(e)?n=e(t):n=pe.createElement(pg,EO({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),n});function TO(){return TO=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},TO.apply(this,arguments)}function hd(e){"@babel/helpers - typeof";return hd=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},hd(e)}function PI(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 RI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?PI(Object(n),!0).forEach(function(r){R1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):PI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Wwe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ywe(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,pq(r.key),r)}}function Kwe(e,t,n){return t&&Ywe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Zwe(e,t,n){return t=tb(t),Xwe(e,hq()?Reflect.construct(t,n||[],tb(e).constructor):t.apply(e,n))}function Xwe(e,t){if(t&&(hd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Qwe(e)}function Qwe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function hq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(hq=function(){return!!e})()}function tb(e){return tb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},tb(e)}function Jwe(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&&jO(e,t)}function jO(e,t){return jO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},jO(e,t)}function R1(e,t,n){return t=pq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pq(e){var t=e_e(e,"string");return hd(t)=="symbol"?t:t+""}function e_e(e,t){if(hd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(hd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var t_e=function(t,n,r,i,a){var o=a.x1,l=a.x2,f=a.y1,u=a.y2,h=a.xAxis,m=a.yAxis;if(!h||!m)return null;var g=K3({x:h.scale,y:m.scale}),_={x:t?g.x.apply(o,{position:"start"}):g.x.rangeMin,y:r?g.y.apply(f,{position:"start"}):g.y.rangeMin},x={x:n?g.x.apply(l,{position:"end"}):g.x.rangeMax,y:i?g.y.apply(u,{position:"end"}):g.y.rangeMax};return oo(a,"discard")&&(!g.isInRange(_)||!g.isInRange(x))?null:eq(_,x)},mg=function(e){function t(){return Wwe(this,t),Zwe(this,t,arguments)}return Jwe(t,e),Kwe(t,[{key:"render",value:function(){var r=this.props,i=r.x1,a=r.x2,o=r.y1,l=r.y2,f=r.className,u=r.alwaysShow,h=r.clipPathId;_a(u===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var m=Kn(i),g=Kn(a),_=Kn(o),x=Kn(l),b=this.props.shape;if(!m&&!g&&!_&&!x&&!b)return null;var S=t_e(m,g,_,x,this.props);if(!S&&!b)return null;var C=oo(this.props,"hidden")?"url(#".concat(h,")"):void 0;return pe.createElement(St,{className:be("recharts-reference-area",f)},t.renderRect(b,RI(RI({clipPath:C},ot(this.props,!0)),S)),lr.renderCallByParent(this.props,S))}}])}(pe.Component);R1(mg,"displayName","ReferenceArea");R1(mg,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});R1(mg,"renderRect",function(e,t){var n;return pe.isValidElement(e)?n=pe.cloneElement(e,t):ht(e)?n=e(t):n=pe.createElement(Y3,TO({},t,{className:"recharts-reference-area-rect"})),n});function mq(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 n_e(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return swe(r,n)}function r_e(e,t,n){var r=n==="width",i=e.x,a=e.y,o=e.width,l=e.height;return t===1?{start:r?i:a,end:r?i+o:a+l}:{start:r?i+o:a+l,end:r?i:a}}function nb(e,t,n,r,i){if(e*t<e*r||e*t>e*i)return!1;var a=n();return e*(t-e*a/2-r)>=0&&e*(t+e*a/2-i)<=0}function i_e(e,t){return mq(e,t+1)}function a_e(e,t,n,r,i){for(var a=(r||[]).slice(),o=t.start,l=t.end,f=0,u=1,h=o,m=function(){var x=r==null?void 0:r[f];if(x===void 0)return{v:mq(r,u)};var b=f,S,C=function(){return S===void 0&&(S=n(x,b)),S},A=x.coordinate,O=f===0||nb(e,A,C,h,l);O||(f=0,h=o,u+=1),O&&(h=A+e*(C()/2+i),f+=u)},g;u<=a.length;)if(g=m(),g)return g.v;return[]}function Im(e){"@babel/helpers - typeof";return Im=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},Im(e)}function MI(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 jr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?MI(Object(n),!0).forEach(function(r){o_e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function o_e(e,t,n){return t=s_e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s_e(e){var t=l_e(e,"string");return Im(t)=="symbol"?t:t+""}function l_e(e,t){if(Im(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Im(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function u_e(e,t,n,r,i){for(var a=(r||[]).slice(),o=a.length,l=t.start,f=t.end,u=function(g){var _=a[g],x,b=function(){return x===void 0&&(x=n(_,g)),x};if(g===o-1){var S=e*(_.coordinate+e*b()/2-f);a[g]=_=jr(jr({},_),{},{tickCoord:S>0?_.coordinate-S*e:_.coordinate})}else a[g]=_=jr(jr({},_),{},{tickCoord:_.coordinate});var C=nb(e,_.tickCoord,b,l,f);C&&(f=_.tickCoord-e*(b()/2+i),a[g]=jr(jr({},_),{},{isShow:!0}))},h=o-1;h>=0;h--)u(h);return a}function c_e(e,t,n,r,i,a){var o=(r||[]).slice(),l=o.length,f=t.start,u=t.end;if(a){var h=r[l-1],m=n(h,l-1),g=e*(h.coordinate+e*m/2-u);o[l-1]=h=jr(jr({},h),{},{tickCoord:g>0?h.coordinate-g*e:h.coordinate});var _=nb(e,h.tickCoord,function(){return m},f,u);_&&(u=h.tickCoord-e*(m/2+i),o[l-1]=jr(jr({},h),{},{isShow:!0}))}for(var x=a?l-1:l,b=function(A){var O=o[A],P,j=function(){return P===void 0&&(P=n(O,A)),P};if(A===0){var R=e*(O.coordinate-e*j()/2-f);o[A]=O=jr(jr({},O),{},{tickCoord:R<0?O.coordinate-R*e:O.coordinate})}else o[A]=O=jr(jr({},O),{},{tickCoord:O.coordinate});var U=nb(e,O.tickCoord,j,f,u);U&&(f=O.tickCoord+e*(j()/2+i),o[A]=jr(jr({},O),{},{isShow:!0}))},S=0;S<x;S++)b(S);return o}function n4(e,t,n){var r=e.tick,i=e.ticks,a=e.viewBox,o=e.minTickGap,l=e.orientation,f=e.interval,u=e.tickFormatter,h=e.unit,m=e.angle;if(!i||!i.length||!r)return[];if(Ze(f)||ms.isSsr)return i_e(i,typeof f=="number"&&Ze(f)?f:0);var g=[],_=l==="top"||l==="bottom"?"width":"height",x=h&&_==="width"?Lp(h,{fontSize:t,letterSpacing:n}):{width:0,height:0},b=function(O,P){var j=ht(u)?u(O.value,P):O.value;return _==="width"?n_e(Lp(j,{fontSize:t,letterSpacing:n}),x,m):Lp(j,{fontSize:t,letterSpacing:n})[_]},S=i.length>=2?Fr(i[1].coordinate-i[0].coordinate):1,C=r_e(a,S,_);return f==="equidistantPreserveStart"?a_e(S,C,b,i,o):(f==="preserveStart"||f==="preserveStartEnd"?g=c_e(S,C,b,i,o,f==="preserveStartEnd"):g=u_e(S,C,b,i,o),g.filter(function(A){return A.isShow}))}var f_e=["viewBox"],d_e=["viewBox"],h_e=["ticks"];function pd(e){"@babel/helpers - typeof";return pd=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},pd(e)}function Of(){return Of=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},Of.apply(this,arguments)}function NI(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?NI(Object(n),!0).forEach(function(r){r4(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):NI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mA(e,t){if(e==null)return{};var n=p_e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function p_e(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 m_e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function LI(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,vq(r.key),r)}}function g_e(e,t,n){return t&&LI(e.prototype,t),n&&LI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function v_e(e,t,n){return t=rb(t),y_e(e,gq()?Reflect.construct(t,n||[],rb(e).constructor):t.apply(e,n))}function y_e(e,t){if(t&&(pd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return b_e(e)}function b_e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(gq=function(){return!!e})()}function rb(e){return rb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},rb(e)}function w_e(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&&PO(e,t)}function PO(e,t){return PO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},PO(e,t)}function r4(e,t,n){return t=vq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vq(e){var t=__e(e,"string");return pd(t)=="symbol"?t:t+""}function __e(e,t){if(pd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(pd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Vd=function(e){function t(n){var r;return m_e(this,t),r=v_e(this,t,[n]),r.state={fontSize:"",letterSpacing:""},r}return w_e(t,e),g_e(t,[{key:"shouldComponentUpdate",value:function(r,i){var a=r.viewBox,o=mA(r,f_e),l=this.props,f=l.viewBox,u=mA(l,d_e);return!kf(a,f)||!kf(o,u)||!kf(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,a=i.x,o=i.y,l=i.width,f=i.height,u=i.orientation,h=i.tickSize,m=i.mirror,g=i.tickMargin,_,x,b,S,C,A,O=m?-1:1,P=r.tickSize||h,j=Ze(r.tickCoord)?r.tickCoord:r.coordinate;switch(u){case"top":_=x=r.coordinate,S=o+ +!m*f,b=S-O*P,A=b-O*g,C=j;break;case"left":b=S=r.coordinate,x=a+ +!m*l,_=x-O*P,C=_-O*g,A=j;break;case"right":b=S=r.coordinate,x=a+ +m*l,_=x+O*P,C=_+O*g,A=j;break;default:_=x=r.coordinate,S=o+ +m*f,b=S+O*P,A=b+O*g,C=j;break}return{line:{x1:_,y1:b,x2:x,y2:S},tick:{x:C,y:A}}}},{key:"getTickTextAnchor",value:function(){var r=this.props,i=r.orientation,a=r.mirror,o;switch(i){case"left":o=a?"start":"end";break;case"right":o=a?"end":"start";break;default:o="middle";break}return o}},{key:"getTickVerticalAnchor",value:function(){var r=this.props,i=r.orientation,a=r.mirror,o="end";switch(i){case"left":case"right":o="middle";break;case"top":o=a?"start":"end";break;default:o=a?"end":"start";break}return o}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.x,a=r.y,o=r.width,l=r.height,f=r.orientation,u=r.mirror,h=r.axisLine,m=Br(Br(Br({},ot(this.props,!1)),ot(h,!1)),{},{fill:"none"});if(f==="top"||f==="bottom"){var g=+(f==="top"&&!u||f==="bottom"&&u);m=Br(Br({},m),{},{x1:i,y1:a+g*l,x2:i+o,y2:a+g*l})}else{var _=+(f==="left"&&!u||f==="right"&&u);m=Br(Br({},m),{},{x1:i+_*o,y1:a,x2:i+_*o,y2:a+l})}return pe.createElement("line",Of({},m,{className:be("recharts-cartesian-axis-line",Ti(h,"className"))}))}},{key:"renderTicks",value:function(r,i,a){var o=this,l=this.props,f=l.tickLine,u=l.stroke,h=l.tick,m=l.tickFormatter,g=l.unit,_=n4(Br(Br({},this.props),{},{ticks:r}),i,a),x=this.getTickTextAnchor(),b=this.getTickVerticalAnchor(),S=ot(this.props,!1),C=ot(h,!1),A=Br(Br({},S),{},{fill:"none"},ot(f,!1)),O=_.map(function(P,j){var R=o.getTickLineCoord(P),U=R.line,V=R.tick,Y=Br(Br(Br(Br({textAnchor:x,verticalAnchor:b},S),{},{stroke:"none",fill:u},C),V),{},{index:j,payload:P,visibleTicksCount:_.length,tickFormatter:m});return pe.createElement(St,Of({className:"recharts-cartesian-axis-tick",key:"tick-".concat(P.value,"-").concat(P.coordinate,"-").concat(P.tickCoord)},Bl(o.props,P,j)),f&&pe.createElement("line",Of({},A,U,{className:be("recharts-cartesian-axis-tick-line",Ti(f,"className"))})),h&&t.renderTickItem(h,Y,"".concat(ht(m)?m(P.value,j):P.value).concat(g||"")))});return pe.createElement("g",{className:"recharts-cartesian-axis-ticks"},O)}},{key:"render",value:function(){var r=this,i=this.props,a=i.axisLine,o=i.width,l=i.height,f=i.ticksGenerator,u=i.className,h=i.hide;if(h)return null;var m=this.props,g=m.ticks,_=mA(m,h_e),x=g;return ht(f)&&(x=g&&g.length>0?f(this.props):f(_)),o<=0||l<=0||!x||!x.length?null:pe.createElement(St,{className:be("recharts-cartesian-axis",u),ref:function(S){r.layerReference=S}},a&&this.renderAxisLine(),this.renderTicks(x,this.state.fontSize,this.state.letterSpacing),lr.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,i,a){var o;return pe.isValidElement(r)?o=pe.cloneElement(r,i):ht(r)?o=r(i):o=pe.createElement(ac,Of({},i,{className:"recharts-cartesian-axis-tick-value"}),a),o}}])}(M.Component);r4(Vd,"displayName","CartesianAxis");r4(Vd,"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 x_e=["x1","y1","x2","y2","key"],S_e=["offset"];function lc(e){"@babel/helpers - typeof";return lc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lc(e)}function kI(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 Pr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?kI(Object(n),!0).forEach(function(r){C_e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function C_e(e,t,n){return t=A_e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function A_e(e){var t=E_e(e,"string");return lc(t)=="symbol"?t:t+""}function E_e(e,t){if(lc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Hu(){return Hu=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},Hu.apply(this,arguments)}function DI(e,t){if(e==null)return{};var n=O_e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function O_e(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 T_e=function(t){var n=t.fill;if(!n||n==="none")return null;var r=t.fillOpacity,i=t.x,a=t.y,o=t.width,l=t.height,f=t.ry;return pe.createElement("rect",{x:i,y:a,ry:f,width:o,height:l,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function yq(e,t){var n;if(pe.isValidElement(e))n=pe.cloneElement(e,t);else if(ht(e))n=e(t);else{var r=t.x1,i=t.y1,a=t.x2,o=t.y2,l=t.key,f=DI(t,x_e),u=ot(f,!1);u.offset;var h=DI(u,S_e);n=pe.createElement("line",Hu({},h,{x1:r,y1:i,x2:a,y2:o,fill:"none",key:l}))}return n}function j_e(e){var t=e.x,n=e.width,r=e.horizontal,i=r===void 0?!0:r,a=e.horizontalPoints;if(!i||!a||!a.length)return null;var o=a.map(function(l,f){var u=Pr(Pr({},e),{},{x1:t,y1:l,x2:t+n,y2:l,key:"line-".concat(f),index:f});return yq(i,u)});return pe.createElement("g",{className:"recharts-cartesian-grid-horizontal"},o)}function P_e(e){var t=e.y,n=e.height,r=e.vertical,i=r===void 0?!0:r,a=e.verticalPoints;if(!i||!a||!a.length)return null;var o=a.map(function(l,f){var u=Pr(Pr({},e),{},{x1:l,y1:t,x2:l,y2:t+n,key:"line-".concat(f),index:f});return yq(i,u)});return pe.createElement("g",{className:"recharts-cartesian-grid-vertical"},o)}function R_e(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,i=e.y,a=e.width,o=e.height,l=e.horizontalPoints,f=e.horizontal,u=f===void 0?!0:f;if(!u||!t||!t.length)return null;var h=l.map(function(g){return Math.round(g+i-i)}).sort(function(g,_){return g-_});i!==h[0]&&h.unshift(0);var m=h.map(function(g,_){var x=!h[_+1],b=x?i+o-g:h[_+1]-g;if(b<=0)return null;var S=_%t.length;return pe.createElement("rect",{key:"react-".concat(_),y:g,x:r,height:b,width:a,stroke:"none",fill:t[S],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return pe.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},m)}function M_e(e){var t=e.vertical,n=t===void 0?!0:t,r=e.verticalFill,i=e.fillOpacity,a=e.x,o=e.y,l=e.width,f=e.height,u=e.verticalPoints;if(!n||!r||!r.length)return null;var h=u.map(function(g){return Math.round(g+a-a)}).sort(function(g,_){return g-_});a!==h[0]&&h.unshift(0);var m=h.map(function(g,_){var x=!h[_+1],b=x?a+l-g:h[_+1]-g;if(b<=0)return null;var S=_%r.length;return pe.createElement("rect",{key:"react-".concat(_),x:g,y:o,width:b,height:f,stroke:"none",fill:r[S],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return pe.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},m)}var N_e=function(t,n){var r=t.xAxis,i=t.width,a=t.height,o=t.offset;return bF(n4(Pr(Pr(Pr({},Vd.defaultProps),r),{},{ticks:Zo(r,!0),viewBox:{x:0,y:0,width:i,height:a}})),o.left,o.left+o.width,n)},L_e=function(t,n){var r=t.yAxis,i=t.width,a=t.height,o=t.offset;return bF(n4(Pr(Pr(Pr({},Vd.defaultProps),r),{},{ticks:Zo(r,!0),viewBox:{x:0,y:0,width:i,height:a}})),o.top,o.top+o.height,n)},gf={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function i4(e){var t,n,r,i,a,o,l=Q3(),f=J3(),u=_we(),h=Pr(Pr({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:gf.stroke,fill:(n=e.fill)!==null&&n!==void 0?n:gf.fill,horizontal:(r=e.horizontal)!==null&&r!==void 0?r:gf.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:gf.horizontalFill,vertical:(a=e.vertical)!==null&&a!==void 0?a:gf.vertical,verticalFill:(o=e.verticalFill)!==null&&o!==void 0?o:gf.verticalFill,x:Ze(e.x)?e.x:u.left,y:Ze(e.y)?e.y:u.top,width:Ze(e.width)?e.width:u.width,height:Ze(e.height)?e.height:u.height}),m=h.x,g=h.y,_=h.width,x=h.height,b=h.syncWithTicks,S=h.horizontalValues,C=h.verticalValues,A=ywe(),O=bwe();if(!Ze(_)||_<=0||!Ze(x)||x<=0||!Ze(m)||m!==+m||!Ze(g)||g!==+g)return null;var P=h.verticalCoordinatesGenerator||N_e,j=h.horizontalCoordinatesGenerator||L_e,R=h.horizontalPoints,U=h.verticalPoints;if((!R||!R.length)&&ht(j)){var V=S&&S.length,Y=j({yAxis:O?Pr(Pr({},O),{},{ticks:V?S:O.ticks}):void 0,width:l,height:f,offset:u},V?!0:b);_a(Array.isArray(Y),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(lc(Y),"]")),Array.isArray(Y)&&(R=Y)}if((!U||!U.length)&&ht(P)){var K=C&&C.length,W=P({xAxis:A?Pr(Pr({},A),{},{ticks:K?C:A.ticks}):void 0,width:l,height:f,offset:u},K?!0:b);_a(Array.isArray(W),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(lc(W),"]")),Array.isArray(W)&&(U=W)}return pe.createElement("g",{className:"recharts-cartesian-grid"},pe.createElement(T_e,{fill:h.fill,fillOpacity:h.fillOpacity,x:h.x,y:h.y,width:h.width,height:h.height,ry:h.ry}),pe.createElement(j_e,Hu({},h,{offset:u,horizontalPoints:R,xAxis:A,yAxis:O})),pe.createElement(P_e,Hu({},h,{offset:u,verticalPoints:U,xAxis:A,yAxis:O})),pe.createElement(R_e,Hu({},h,{horizontalPoints:R})),pe.createElement(M_e,Hu({},h,{verticalPoints:U})))}i4.displayName="CartesianGrid";var k_e=["type","layout","connectNulls","ref"],D_e=["key"];function md(e){"@babel/helpers - typeof";return md=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},md(e)}function II(e,t){if(e==null)return{};var n=I_e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function I_e(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 Up(){return Up=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},Up.apply(this,arguments)}function $I(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 vi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$I(Object(n),!0).forEach(function(r){ya(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$I(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vf(e){return z_e(e)||U_e(e)||B_e(e)||$_e()}function $_e(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function B_e(e,t){if(e){if(typeof e=="string")return RO(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 RO(e,t)}}function U_e(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function z_e(e){if(Array.isArray(e))return RO(e)}function RO(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 F_e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function BI(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,wq(r.key),r)}}function q_e(e,t,n){return t&&BI(e.prototype,t),n&&BI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function V_e(e,t,n){return t=ib(t),H_e(e,bq()?Reflect.construct(t,n||[],ib(e).constructor):t.apply(e,n))}function H_e(e,t){if(t&&(md(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return G_e(e)}function G_e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function bq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(bq=function(){return!!e})()}function ib(e){return ib=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ib(e)}function W_e(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&&MO(e,t)}function MO(e,t){return MO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},MO(e,t)}function ya(e,t,n){return t=wq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wq(e){var t=Y_e(e,"string");return md(t)=="symbol"?t:t+""}function Y_e(e,t){if(md(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(md(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Hd=function(e){function t(){var n;F_e(this,t);for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];return n=V_e(this,t,[].concat(i)),ya(n,"state",{isAnimationFinished:!0,totalLength:0}),ya(n,"generateSimpleStrokeDasharray",function(o,l){return"".concat(l,"px ").concat(o-l,"px")}),ya(n,"getStrokeDasharray",function(o,l,f){var u=f.reduce(function(C,A){return C+A});if(!u)return n.generateSimpleStrokeDasharray(l,o);for(var h=Math.floor(o/u),m=o%u,g=l-o,_=[],x=0,b=0;x<f.length;b+=f[x],++x)if(b+f[x]>m){_=[].concat(vf(f.slice(0,x)),[m-b]);break}var S=_.length%2===0?[0,g]:[g];return[].concat(vf(t.repeat(f,h)),vf(_),S).map(function(C){return"".concat(C,"px")}).join(", ")}),ya(n,"id",Yl("recharts-line-")),ya(n,"pathRef",function(o){n.mainCurve=o}),ya(n,"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),ya(n,"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return W_e(t,e),q_e(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 a=this.props,o=a.points,l=a.xAxis,f=a.yAxis,u=a.layout,h=a.children,m=Gr(h,qd);if(!m)return null;var g=function(b,S){return{x:b.x,y:b.y,value:b.value,errorVal:hn(b.payload,S)}},_={clipPath:r?"url(#clipPath-".concat(i,")"):null};return pe.createElement(St,_,m.map(function(x){return pe.cloneElement(x,{key:"bar-".concat(x.props.dataKey),data:o,xAxis:l,yAxis:f,layout:u,dataPointFormatter:g})}))}},{key:"renderDots",value:function(r,i,a){var o=this.props.isAnimationActive;if(o&&!this.state.isAnimationFinished)return null;var l=this.props,f=l.dot,u=l.points,h=l.dataKey,m=ot(this.props,!1),g=ot(f,!0),_=u.map(function(b,S){var C=vi(vi(vi({key:"dot-".concat(S),r:3},m),g),{},{index:S,cx:b.x,cy:b.y,value:b.value,dataKey:h,payload:b.payload,points:u});return t.renderDotItem(f,C)}),x={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(a,")"):null};return pe.createElement(St,Up({className:"recharts-line-dots",key:"dots"},x),_)}},{key:"renderCurveStatically",value:function(r,i,a,o){var l=this.props,f=l.type,u=l.layout,h=l.connectNulls;l.ref;var m=II(l,k_e),g=vi(vi(vi({},ot(m,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(a,")"):null,points:r},o),{},{type:f,layout:u,connectNulls:h});return pe.createElement(El,Up({},g,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(r,i){var a=this,o=this.props,l=o.points,f=o.strokeDasharray,u=o.isAnimationActive,h=o.animationBegin,m=o.animationDuration,g=o.animationEasing,_=o.animationId,x=o.animateNewValues,b=o.width,S=o.height,C=this.state,A=C.prevPoints,O=C.totalLength;return pe.createElement(ra,{begin:h,duration:m,isActive:u,easing:g,from:{t:0},to:{t:1},key:"line-".concat(_),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(P){var j=P.t;if(A){var R=A.length/l.length,U=l.map(function(ee,ie){var X=Math.floor(ie*R);if(A[X]){var ne=A[X],H=Cn(ne.x,ee.x),I=Cn(ne.y,ee.y);return vi(vi({},ee),{},{x:H(j),y:I(j)})}if(x){var D=Cn(b*2,ee.x),z=Cn(S/2,ee.y);return vi(vi({},ee),{},{x:D(j),y:z(j)})}return vi(vi({},ee),{},{x:ee.x,y:ee.y})});return a.renderCurveStatically(U,r,i)}var V=Cn(0,O),Y=V(j),K;if(f){var W="".concat(f).split(/[,\s]+/gim).map(function(ee){return parseFloat(ee)});K=a.getStrokeDasharray(Y,O,W)}else K=a.generateSimpleStrokeDasharray(O,Y);return a.renderCurveStatically(l,r,i,{strokeDasharray:K})})}},{key:"renderCurve",value:function(r,i){var a=this.props,o=a.points,l=a.isAnimationActive,f=this.state,u=f.prevPoints,h=f.totalLength;return l&&o&&o.length&&(!u&&h>0||!Ul(u,o))?this.renderCurveWithAnimation(r,i):this.renderCurveStatically(o,r,i)}},{key:"render",value:function(){var r,i=this.props,a=i.hide,o=i.dot,l=i.points,f=i.className,u=i.xAxis,h=i.yAxis,m=i.top,g=i.left,_=i.width,x=i.height,b=i.isAnimationActive,S=i.id;if(a||!l||!l.length)return null;var C=this.state.isAnimationFinished,A=l.length===1,O=be("recharts-line",f),P=u&&u.allowDataOverflow,j=h&&h.allowDataOverflow,R=P||j,U=pt(S)?this.id:S,V=(r=ot(o,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},Y=V.r,K=Y===void 0?3:Y,W=V.strokeWidth,ee=W===void 0?2:W,ie=_U(o)?o:{},X=ie.clipDot,ne=X===void 0?!0:X,H=K*2+ee;return pe.createElement(St,{className:O},P||j?pe.createElement("defs",null,pe.createElement("clipPath",{id:"clipPath-".concat(U)},pe.createElement("rect",{x:P?g:g-_/2,y:j?m:m-x/2,width:P?_:_*2,height:j?x:x*2})),!ne&&pe.createElement("clipPath",{id:"clipPath-dots-".concat(U)},pe.createElement("rect",{x:g-H/2,y:m-H/2,width:_+H,height:x+H}))):null,!A&&this.renderCurve(R,U),this.renderErrorBar(R,U),(A||o)&&this.renderDots(R,ne,U),(!b||C)&&xa.renderCallByParent(this.props,l))}}],[{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 a=r.length%2!==0?[].concat(vf(r),[0]):r,o=[],l=0;l<i;++l)o=[].concat(vf(o),vf(a));return o}},{key:"renderDotItem",value:function(r,i){var a;if(pe.isValidElement(r))a=pe.cloneElement(r,i);else if(ht(r))a=r(i);else{var o=i.key,l=II(i,D_e),f=be("recharts-line-dot",typeof r!="boolean"?r.className:"");a=pe.createElement(pg,Up({key:o},l,{className:f}))}return a}}])}(M.PureComponent);ya(Hd,"displayName","Line");ya(Hd,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!ms.isSsr,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1});ya(Hd,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,i=e.xAxisTicks,a=e.yAxisTicks,o=e.dataKey,l=e.bandSize,f=e.displayedData,u=e.offset,h=t.layout,m=f.map(function(g,_){var x=hn(g,o);return h==="horizontal"?{x:rd({axis:n,ticks:i,bandSize:l,entry:g,index:_}),y:pt(x)?null:r.scale(x),value:x,payload:g}:{x:pt(x)?null:n.scale(x),y:rd({axis:r,ticks:a,bandSize:l,entry:g,index:_}),value:x,payload:g}});return vi({points:m,layout:h},u)});var K_e=["layout","type","stroke","connectNulls","isRange","ref"],Z_e=["key"],_q;function gd(e){"@babel/helpers - typeof";return gd=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},gd(e)}function xq(e,t){if(e==null)return{};var n=X_e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function X_e(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 Gu(){return Gu=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},Gu.apply(this,arguments)}function UI(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 hl(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?UI(Object(n),!0).forEach(function(r){eo(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):UI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Q_e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function zI(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,Cq(r.key),r)}}function J_e(e,t,n){return t&&zI(e.prototype,t),n&&zI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function exe(e,t,n){return t=ab(t),txe(e,Sq()?Reflect.construct(t,n||[],ab(e).constructor):t.apply(e,n))}function txe(e,t){if(t&&(gd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return nxe(e)}function nxe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Sq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Sq=function(){return!!e})()}function ab(e){return ab=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ab(e)}function rxe(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&&NO(e,t)}function NO(e,t){return NO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},NO(e,t)}function eo(e,t,n){return t=Cq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Cq(e){var t=ixe(e,"string");return gd(t)=="symbol"?t:t+""}function ixe(e,t){if(gd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(gd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var vc=function(e){function t(){var n;Q_e(this,t);for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];return n=exe(this,t,[].concat(i)),eo(n,"state",{isAnimationFinished:!0}),eo(n,"id",Yl("recharts-area-")),eo(n,"handleAnimationEnd",function(){var o=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),ht(o)&&o()}),eo(n,"handleAnimationStart",function(){var o=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),ht(o)&&o()}),n}return rxe(t,e),J_e(t,[{key:"renderDots",value:function(r,i,a){var o=this.props.isAnimationActive,l=this.state.isAnimationFinished;if(o&&!l)return null;var f=this.props,u=f.dot,h=f.points,m=f.dataKey,g=ot(this.props,!1),_=ot(u,!0),x=h.map(function(S,C){var A=hl(hl(hl({key:"dot-".concat(C),r:3},g),_),{},{index:C,cx:S.x,cy:S.y,dataKey:m,value:S.value,payload:S.payload,points:h});return t.renderDotItem(u,A)}),b={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(a,")"):null};return pe.createElement(St,Gu({className:"recharts-area-dots"},b),x)}},{key:"renderHorizontalRect",value:function(r){var i=this.props,a=i.baseLine,o=i.points,l=i.strokeWidth,f=o[0].x,u=o[o.length-1].x,h=r*Math.abs(f-u),m=wl(o.map(function(g){return g.y||0}));return Ze(a)&&typeof a=="number"?m=Math.max(a,m):a&&Array.isArray(a)&&a.length&&(m=Math.max(wl(a.map(function(g){return g.y||0})),m)),Ze(m)?pe.createElement("rect",{x:f<u?f:f-h,y:0,width:h,height:Math.floor(m+(l?parseInt("".concat(l),10):1))}):null}},{key:"renderVerticalRect",value:function(r){var i=this.props,a=i.baseLine,o=i.points,l=i.strokeWidth,f=o[0].y,u=o[o.length-1].y,h=r*Math.abs(f-u),m=wl(o.map(function(g){return g.x||0}));return Ze(a)&&typeof a=="number"?m=Math.max(a,m):a&&Array.isArray(a)&&a.length&&(m=Math.max(wl(a.map(function(g){return g.x||0})),m)),Ze(m)?pe.createElement("rect",{x:0,y:f<u?f:f-h,width:m+(l?parseInt("".concat(l),10):1),height:Math.floor(h)}):null}},{key:"renderClipRect",value:function(r){var i=this.props.layout;return i==="vertical"?this.renderVerticalRect(r):this.renderHorizontalRect(r)}},{key:"renderAreaStatically",value:function(r,i,a,o){var l=this.props,f=l.layout,u=l.type,h=l.stroke,m=l.connectNulls,g=l.isRange;l.ref;var _=xq(l,K_e);return pe.createElement(St,{clipPath:a?"url(#clipPath-".concat(o,")"):null},pe.createElement(El,Gu({},ot(_,!0),{points:r,connectNulls:m,type:u,baseLine:i,layout:f,stroke:"none",className:"recharts-area-area"})),h!=="none"&&pe.createElement(El,Gu({},ot(this.props,!1),{className:"recharts-area-curve",layout:f,type:u,connectNulls:m,fill:"none",points:r})),h!=="none"&&g&&pe.createElement(El,Gu({},ot(this.props,!1),{className:"recharts-area-curve",layout:f,type:u,connectNulls:m,fill:"none",points:i})))}},{key:"renderAreaWithAnimation",value:function(r,i){var a=this,o=this.props,l=o.points,f=o.baseLine,u=o.isAnimationActive,h=o.animationBegin,m=o.animationDuration,g=o.animationEasing,_=o.animationId,x=this.state,b=x.prevPoints,S=x.prevBaseLine;return pe.createElement(ra,{begin:h,duration:m,isActive:u,easing:g,from:{t:0},to:{t:1},key:"area-".concat(_),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(C){var A=C.t;if(b){var O=b.length/l.length,P=l.map(function(V,Y){var K=Math.floor(Y*O);if(b[K]){var W=b[K],ee=Cn(W.x,V.x),ie=Cn(W.y,V.y);return hl(hl({},V),{},{x:ee(A),y:ie(A)})}return V}),j;if(Ze(f)&&typeof f=="number"){var R=Cn(S,f);j=R(A)}else if(pt(f)||$d(f)){var U=Cn(S,0);j=U(A)}else j=f.map(function(V,Y){var K=Math.floor(Y*O);if(S[K]){var W=S[K],ee=Cn(W.x,V.x),ie=Cn(W.y,V.y);return hl(hl({},V),{},{x:ee(A),y:ie(A)})}return V});return a.renderAreaStatically(P,j,r,i)}return pe.createElement(St,null,pe.createElement("defs",null,pe.createElement("clipPath",{id:"animationClipPath-".concat(i)},a.renderClipRect(A))),pe.createElement(St,{clipPath:"url(#animationClipPath-".concat(i,")")},a.renderAreaStatically(l,f,r,i)))})}},{key:"renderArea",value:function(r,i){var a=this.props,o=a.points,l=a.baseLine,f=a.isAnimationActive,u=this.state,h=u.prevPoints,m=u.prevBaseLine,g=u.totalLength;return f&&o&&o.length&&(!h&&g>0||!Ul(h,o)||!Ul(m,l))?this.renderAreaWithAnimation(r,i):this.renderAreaStatically(o,l,r,i)}},{key:"render",value:function(){var r,i=this.props,a=i.hide,o=i.dot,l=i.points,f=i.className,u=i.top,h=i.left,m=i.xAxis,g=i.yAxis,_=i.width,x=i.height,b=i.isAnimationActive,S=i.id;if(a||!l||!l.length)return null;var C=this.state.isAnimationFinished,A=l.length===1,O=be("recharts-area",f),P=m&&m.allowDataOverflow,j=g&&g.allowDataOverflow,R=P||j,U=pt(S)?this.id:S,V=(r=ot(o,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},Y=V.r,K=Y===void 0?3:Y,W=V.strokeWidth,ee=W===void 0?2:W,ie=_U(o)?o:{},X=ie.clipDot,ne=X===void 0?!0:X,H=K*2+ee;return pe.createElement(St,{className:O},P||j?pe.createElement("defs",null,pe.createElement("clipPath",{id:"clipPath-".concat(U)},pe.createElement("rect",{x:P?h:h-_/2,y:j?u:u-x/2,width:P?_:_*2,height:j?x:x*2})),!ne&&pe.createElement("clipPath",{id:"clipPath-dots-".concat(U)},pe.createElement("rect",{x:h-H/2,y:u-H/2,width:_+H,height:x+H}))):null,A?null:this.renderArea(R,U),(o||A)&&this.renderDots(R,ne,U),(!b||C)&&xa.renderCallByParent(this.props,l))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,curBaseLine:r.baseLine,prevPoints:i.curPoints,prevBaseLine:i.curBaseLine}:r.points!==i.curPoints||r.baseLine!==i.curBaseLine?{curPoints:r.points,curBaseLine:r.baseLine}:null}}])}(M.PureComponent);_q=vc;eo(vc,"displayName","Area");eo(vc,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!ms.isSsr,animationBegin:0,animationDuration:1500,animationEasing:"ease"});eo(vc,"getBaseValue",function(e,t,n,r){var i=e.layout,a=e.baseValue,o=t.props.baseValue,l=o??a;if(Ze(l)&&typeof l=="number")return l;var f=i==="horizontal"?r:n,u=f.scale.domain();if(f.type==="number"){var h=Math.max(u[0],u[1]),m=Math.min(u[0],u[1]);return l==="dataMin"?m:l==="dataMax"||h<0?h:Math.max(Math.min(u[0],u[1]),0)}return l==="dataMin"?u[0]:l==="dataMax"?u[1]:u[0]});eo(vc,"getComposedData",function(e){var t=e.props,n=e.item,r=e.xAxis,i=e.yAxis,a=e.xAxisTicks,o=e.yAxisTicks,l=e.bandSize,f=e.dataKey,u=e.stackedData,h=e.dataStartIndex,m=e.displayedData,g=e.offset,_=t.layout,x=u&&u.length,b=_q.getBaseValue(t,n,r,i),S=_==="horizontal",C=!1,A=m.map(function(P,j){var R;x?R=u[h+j]:(R=hn(P,f),Array.isArray(R)?C=!0:R=[b,R]);var U=R[1]==null||x&&hn(P,f)==null;return S?{x:rd({axis:r,ticks:a,bandSize:l,entry:P,index:j}),y:U?null:i.scale(R[1]),value:R,payload:P}:{x:U?null:r.scale(R[1]),y:rd({axis:i,ticks:o,bandSize:l,entry:P,index:j}),value:R,payload:P}}),O;return x||C?O=A.map(function(P){var j=Array.isArray(P.value)?P.value[0]:null;return S?{x:P.x,y:j!=null&&P.y!=null?i.scale(j):null}:{x:j!=null?r.scale(j):null,y:P.y}}):O=S?i.scale(b):r.scale(b),hl({points:A,baseLine:O,layout:_,isRange:C},g)});eo(vc,"renderDotItem",function(e,t){var n;if(pe.isValidElement(e))n=pe.cloneElement(e,t);else if(ht(e))n=e(t);else{var r=be("recharts-area-dot",typeof e!="boolean"?e.className:""),i=t.key,a=xq(t,Z_e);n=pe.createElement(pg,Gu({},a,{key:i,className:r}))}return n});function vd(e){"@babel/helpers - typeof";return vd=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},vd(e)}function axe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function oxe(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,Oq(r.key),r)}}function sxe(e,t,n){return t&&oxe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function lxe(e,t,n){return t=ob(t),uxe(e,Aq()?Reflect.construct(t,n||[],ob(e).constructor):t.apply(e,n))}function uxe(e,t){if(t&&(vd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return cxe(e)}function cxe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Aq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Aq=function(){return!!e})()}function ob(e){return ob=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ob(e)}function fxe(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&&LO(e,t)}function LO(e,t){return LO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},LO(e,t)}function Eq(e,t,n){return t=Oq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Oq(e){var t=dxe(e,"string");return vd(t)=="symbol"?t:t+""}function dxe(e,t){if(vd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(vd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var M1=function(e){function t(){return axe(this,t),lxe(this,t,arguments)}return fxe(t,e),sxe(t,[{key:"render",value:function(){return null}}])}(pe.Component);Eq(M1,"displayName","ZAxis");Eq(M1,"defaultProps",{zAxisId:0,range:[64,64],scale:"auto",type:"number"});var hxe=["option","isActive"];function zp(){return zp=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},zp.apply(this,arguments)}function pxe(e,t){if(e==null)return{};var n=mxe(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function mxe(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 gxe(e){var t=e.option,n=e.isActive,r=pxe(e,hxe);return typeof t=="string"?pe.createElement(G0,zp({option:pe.createElement(l1,zp({type:t},r)),isActive:n,shapeType:"symbols"},r)):pe.createElement(G0,zp({option:t,isActive:n,shapeType:"symbols"},r))}function yd(e){"@babel/helpers - typeof";return yd=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},yd(e)}function Fp(){return Fp=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},Fp.apply(this,arguments)}function FI(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 Zi(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?FI(Object(n),!0).forEach(function(r){xl(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vxe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function qI(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,jq(r.key),r)}}function yxe(e,t,n){return t&&qI(e.prototype,t),n&&qI(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function bxe(e,t,n){return t=sb(t),wxe(e,Tq()?Reflect.construct(t,n||[],sb(e).constructor):t.apply(e,n))}function wxe(e,t){if(t&&(yd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return _xe(e)}function _xe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Tq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Tq=function(){return!!e})()}function sb(e){return sb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},sb(e)}function xxe(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&&kO(e,t)}function kO(e,t){return kO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},kO(e,t)}function xl(e,t,n){return t=jq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jq(e){var t=Sxe(e,"string");return yd(t)=="symbol"?t:t+""}function Sxe(e,t){if(yd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var N1=function(e){function t(){var n;vxe(this,t);for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];return n=bxe(this,t,[].concat(i)),xl(n,"state",{isAnimationFinished:!1}),xl(n,"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0})}),xl(n,"handleAnimationStart",function(){n.setState({isAnimationFinished:!1})}),xl(n,"id",Yl("recharts-scatter-")),n}return xxe(t,e),yxe(t,[{key:"renderSymbolsStatically",value:function(r){var i=this,a=this.props,o=a.shape,l=a.activeShape,f=a.activeIndex,u=ot(this.props,!1);return r.map(function(h,m){var g=f===m,_=g?l:o,x=Zi(Zi({},u),h);return pe.createElement(St,Fp({className:"recharts-scatter-symbol",key:"symbol-".concat(h==null?void 0:h.cx,"-").concat(h==null?void 0:h.cy,"-").concat(h==null?void 0:h.size,"-").concat(m)},Bl(i.props,h,m),{role:"img"}),pe.createElement(gxe,Fp({option:_,isActive:g,key:"symbol-".concat(m)},x)))})}},{key:"renderSymbolsWithAnimation",value:function(){var r=this,i=this.props,a=i.points,o=i.isAnimationActive,l=i.animationBegin,f=i.animationDuration,u=i.animationEasing,h=i.animationId,m=this.state.prevPoints;return pe.createElement(ra,{begin:l,duration:f,isActive:o,easing:u,from:{t:0},to:{t:1},key:"pie-".concat(h),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(g){var _=g.t,x=a.map(function(b,S){var C=m&&m[S];if(C){var A=Cn(C.cx,b.cx),O=Cn(C.cy,b.cy),P=Cn(C.size,b.size);return Zi(Zi({},b),{},{cx:A(_),cy:O(_),size:P(_)})}var j=Cn(0,b.size);return Zi(Zi({},b),{},{size:j(_)})});return pe.createElement(St,null,r.renderSymbolsStatically(x))})}},{key:"renderSymbols",value:function(){var r=this.props,i=r.points,a=r.isAnimationActive,o=this.state.prevPoints;return a&&i&&i.length&&(!o||!Ul(o,i))?this.renderSymbolsWithAnimation():this.renderSymbolsStatically(i)}},{key:"renderErrorBar",value:function(){var r=this.props.isAnimationActive;if(r&&!this.state.isAnimationFinished)return null;var i=this.props,a=i.points,o=i.xAxis,l=i.yAxis,f=i.children,u=Gr(f,qd);return u?u.map(function(h,m){var g=h.props,_=g.direction,x=g.dataKey;return pe.cloneElement(h,{key:"".concat(_,"-").concat(x,"-").concat(a[m]),data:a,xAxis:o,yAxis:l,layout:_==="x"?"vertical":"horizontal",dataPointFormatter:function(S,C){return{x:S.cx,y:S.cy,value:_==="x"?+S.node.x:+S.node.y,errorVal:hn(S,C)}}})}):null}},{key:"renderLine",value:function(){var r=this.props,i=r.points,a=r.line,o=r.lineType,l=r.lineJointType,f=ot(this.props,!1),u=ot(a,!1),h,m;if(o==="joint")h=i.map(function(O){return{x:O.cx,y:O.cy}});else if(o==="fitting"){var g=wle(i),_=g.xmin,x=g.xmax,b=g.a,S=g.b,C=function(P){return b*P+S};h=[{x:_,y:C(_)},{x,y:C(x)}]}var A=Zi(Zi(Zi({},f),{},{fill:"none",stroke:f&&f.fill},u),{},{points:h});return pe.isValidElement(a)?m=pe.cloneElement(a,A):ht(a)?m=a(A):m=pe.createElement(El,Fp({},A,{type:l})),pe.createElement(St,{className:"recharts-scatter-line",key:"recharts-scatter-line"},m)}},{key:"render",value:function(){var r=this.props,i=r.hide,a=r.points,o=r.line,l=r.className,f=r.xAxis,u=r.yAxis,h=r.left,m=r.top,g=r.width,_=r.height,x=r.id,b=r.isAnimationActive;if(i||!a||!a.length)return null;var S=this.state.isAnimationFinished,C=be("recharts-scatter",l),A=f&&f.allowDataOverflow,O=u&&u.allowDataOverflow,P=A||O,j=pt(x)?this.id:x;return pe.createElement(St,{className:C,clipPath:P?"url(#clipPath-".concat(j,")"):null},A||O?pe.createElement("defs",null,pe.createElement("clipPath",{id:"clipPath-".concat(j)},pe.createElement("rect",{x:A?h:h-g/2,y:O?m:m-_/2,width:A?g:g*2,height:O?_:_*2}))):null,o&&this.renderLine(),this.renderErrorBar(),pe.createElement(St,{key:"recharts-scatter-symbols"},this.renderSymbols()),(!b||S)&&xa.renderCallByParent(this.props,a))}}],[{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}}])}(M.PureComponent);xl(N1,"displayName","Scatter");xl(N1,"defaultProps",{xAxisId:0,yAxisId:0,zAxisId:0,legendType:"circle",lineType:"joint",lineJointType:"linear",data:[],shape:"circle",hide:!1,isAnimationActive:!ms.isSsr,animationBegin:0,animationDuration:400,animationEasing:"linear"});xl(N1,"getComposedData",function(e){var t=e.xAxis,n=e.yAxis,r=e.zAxis,i=e.item,a=e.displayedData,o=e.xAxisTicks,l=e.yAxisTicks,f=e.offset,u=i.props.tooltipType,h=Gr(i.props.children,Cl),m=pt(t.dataKey)?i.props.dataKey:t.dataKey,g=pt(n.dataKey)?i.props.dataKey:n.dataKey,_=r&&r.dataKey,x=r?r.range:M1.defaultProps.range,b=x&&x[0],S=t.scale.bandwidth?t.scale.bandwidth():0,C=n.scale.bandwidth?n.scale.bandwidth():0,A=a.map(function(O,P){var j=hn(O,m),R=hn(O,g),U=!pt(_)&&hn(O,_)||"-",V=[{name:pt(t.dataKey)?i.props.name:t.name||t.dataKey,unit:t.unit||"",value:j,payload:O,dataKey:m,type:u},{name:pt(n.dataKey)?i.props.name:n.name||n.dataKey,unit:n.unit||"",value:R,payload:O,dataKey:g,type:u}];U!=="-"&&V.push({name:r.name||r.dataKey,unit:r.unit||"",value:U,payload:O,dataKey:_,type:u});var Y=rd({axis:t,ticks:o,bandSize:S,entry:O,index:P,dataKey:m}),K=rd({axis:n,ticks:l,bandSize:C,entry:O,index:P,dataKey:g}),W=U!=="-"?r.scale(U):b,ee=Math.sqrt(Math.max(W,0)/Math.PI);return Zi(Zi({},O),{},{cx:Y,cy:K,x:Y-ee,y:K-ee,xAxis:t,yAxis:n,zAxis:r,width:2*ee,height:2*ee,size:W,node:{x:j,y:R,z:U},tooltipPayload:V,tooltipPosition:{x:Y,y:K},payload:O},h&&h[P]&&h[P].props)});return Zi({points:A},f)});function bd(e){"@babel/helpers - typeof";return bd=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},bd(e)}function Cxe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Axe(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,Mq(r.key),r)}}function Exe(e,t,n){return t&&Axe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Oxe(e,t,n){return t=lb(t),Txe(e,Pq()?Reflect.construct(t,n||[],lb(e).constructor):t.apply(e,n))}function Txe(e,t){if(t&&(bd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return jxe(e)}function jxe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Pq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Pq=function(){return!!e})()}function lb(e){return lb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},lb(e)}function Pxe(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&&DO(e,t)}function DO(e,t){return DO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},DO(e,t)}function Rq(e,t,n){return t=Mq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mq(e){var t=Rxe(e,"string");return bd(t)=="symbol"?t:t+""}function Rxe(e,t){if(bd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function IO(){return IO=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},IO.apply(this,arguments)}function Mxe(e){var t=e.xAxisId,n=Q3(),r=J3(),i=sq(t);return i==null?null:pe.createElement(Vd,IO({},i,{className:be("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(o){return Zo(o,!0)}}))}var Gd=function(e){function t(){return Cxe(this,t),Oxe(this,t,arguments)}return Pxe(t,e),Exe(t,[{key:"render",value:function(){return pe.createElement(Mxe,this.props)}}])}(pe.Component);Rq(Gd,"displayName","XAxis");Rq(Gd,"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 wd(e){"@babel/helpers - typeof";return wd=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},wd(e)}function Nxe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Lxe(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,kq(r.key),r)}}function kxe(e,t,n){return t&&Lxe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Dxe(e,t,n){return t=ub(t),Ixe(e,Nq()?Reflect.construct(t,n||[],ub(e).constructor):t.apply(e,n))}function Ixe(e,t){if(t&&(wd(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $xe(e)}function $xe(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Nq(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Nq=function(){return!!e})()}function ub(e){return ub=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ub(e)}function Bxe(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&&$O(e,t)}function $O(e,t){return $O=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},$O(e,t)}function Lq(e,t,n){return t=kq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kq(e){var t=Uxe(e,"string");return wd(t)=="symbol"?t:t+""}function Uxe(e,t){if(wd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(wd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function BO(){return BO=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},BO.apply(this,arguments)}var zxe=function(t){var n=t.yAxisId,r=Q3(),i=J3(),a=lq(n);return a==null?null:pe.createElement(Vd,BO({},a,{className:be("recharts-".concat(a.axisType," ").concat(a.axisType),a.className),viewBox:{x:0,y:0,width:r,height:i},ticksGenerator:function(l){return Zo(l,!0)}}))},Wd=function(e){function t(){return Nxe(this,t),Dxe(this,t,arguments)}return Bxe(t,e),kxe(t,[{key:"render",value:function(){return pe.createElement(zxe,this.props)}}])}(pe.Component);Lq(Wd,"displayName","YAxis");Lq(Wd,"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 VI(e){return Hxe(e)||Vxe(e)||qxe(e)||Fxe()}function Fxe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qxe(e,t){if(e){if(typeof e=="string")return UO(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 UO(e,t)}}function Vxe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Hxe(e){if(Array.isArray(e))return UO(e)}function UO(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 zO=function(t,n,r,i,a){var o=Gr(t,t4),l=Gr(t,P1),f=[].concat(VI(o),VI(l)),u=Gr(t,mg),h="".concat(i,"Id"),m=i[0],g=n;if(f.length&&(g=f.reduce(function(b,S){if(S.props[h]===r&&oo(S.props,"extendDomain")&&Ze(S.props[m])){var C=S.props[m];return[Math.min(b[0],C),Math.max(b[1],C)]}return b},g)),u.length){var _="".concat(m,"1"),x="".concat(m,"2");g=u.reduce(function(b,S){if(S.props[h]===r&&oo(S.props,"extendDomain")&&Ze(S.props[_])&&Ze(S.props[x])){var C=S.props[_],A=S.props[x];return[Math.min(b[0],C,A),Math.max(b[1],C,A)]}return b},g)}return a&&a.length&&(g=a.reduce(function(b,S){return Ze(S)?[Math.min(b[0],S),Math.max(b[1],S)]:b},g)),g},gA={exports:{}},HI;function Gxe(){return HI||(HI=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(f,u,h){this.fn=f,this.context=u,this.once=h||!1}function a(f,u,h,m,g){if(typeof h!="function")throw new TypeError("The listener must be a function");var _=new i(h,m||f,g),x=n?n+u:u;return f._events[x]?f._events[x].fn?f._events[x]=[f._events[x],_]:f._events[x].push(_):(f._events[x]=_,f._eventsCount++),f}function o(f,u){--f._eventsCount===0?f._events=new r:delete f._events[u]}function l(){this._events=new r,this._eventsCount=0}l.prototype.eventNames=function(){var u=[],h,m;if(this._eventsCount===0)return u;for(m in h=this._events)t.call(h,m)&&u.push(n?m.slice(1):m);return Object.getOwnPropertySymbols?u.concat(Object.getOwnPropertySymbols(h)):u},l.prototype.listeners=function(u){var h=n?n+u:u,m=this._events[h];if(!m)return[];if(m.fn)return[m.fn];for(var g=0,_=m.length,x=new Array(_);g<_;g++)x[g]=m[g].fn;return x},l.prototype.listenerCount=function(u){var h=n?n+u:u,m=this._events[h];return m?m.fn?1:m.length:0},l.prototype.emit=function(u,h,m,g,_,x){var b=n?n+u:u;if(!this._events[b])return!1;var S=this._events[b],C=arguments.length,A,O;if(S.fn){switch(S.once&&this.removeListener(u,S.fn,void 0,!0),C){case 1:return S.fn.call(S.context),!0;case 2:return S.fn.call(S.context,h),!0;case 3:return S.fn.call(S.context,h,m),!0;case 4:return S.fn.call(S.context,h,m,g),!0;case 5:return S.fn.call(S.context,h,m,g,_),!0;case 6:return S.fn.call(S.context,h,m,g,_,x),!0}for(O=1,A=new Array(C-1);O<C;O++)A[O-1]=arguments[O];S.fn.apply(S.context,A)}else{var P=S.length,j;for(O=0;O<P;O++)switch(S[O].once&&this.removeListener(u,S[O].fn,void 0,!0),C){case 1:S[O].fn.call(S[O].context);break;case 2:S[O].fn.call(S[O].context,h);break;case 3:S[O].fn.call(S[O].context,h,m);break;case 4:S[O].fn.call(S[O].context,h,m,g);break;default:if(!A)for(j=1,A=new Array(C-1);j<C;j++)A[j-1]=arguments[j];S[O].fn.apply(S[O].context,A)}}return!0},l.prototype.on=function(u,h,m){return a(this,u,h,m,!1)},l.prototype.once=function(u,h,m){return a(this,u,h,m,!0)},l.prototype.removeListener=function(u,h,m,g){var _=n?n+u:u;if(!this._events[_])return this;if(!h)return o(this,_),this;var x=this._events[_];if(x.fn)x.fn===h&&(!g||x.once)&&(!m||x.context===m)&&o(this,_);else{for(var b=0,S=[],C=x.length;b<C;b++)(x[b].fn!==h||g&&!x[b].once||m&&x[b].context!==m)&&S.push(x[b]);S.length?this._events[_]=S.length===1?S[0]:S:o(this,_)}return this},l.prototype.removeAllListeners=function(u){var h;return u?(h=n?n+u:u,this._events[h]&&o(this,h)):(this._events=new r,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=n,l.EventEmitter=l,e.exports=l}(gA)),gA.exports}var Wxe=Gxe();const Yxe=zt(Wxe);var vA=new Yxe,yA="recharts.syncMouseEvents";function $m(e){"@babel/helpers - typeof";return $m=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},$m(e)}function Kxe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Zxe(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,Dq(r.key),r)}}function Xxe(e,t,n){return t&&Zxe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function bA(e,t,n){return t=Dq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Dq(e){var t=Qxe(e,"string");return $m(t)=="symbol"?t:t+""}function Qxe(e,t){if($m(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if($m(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Jxe=function(){function e(){Kxe(this,e),bA(this,"activeIndex",0),bA(this,"coordinateList",[]),bA(this,"layout","horizontal")}return Xxe(e,[{key:"setDetails",value:function(n){var r,i=n.coordinateList,a=i===void 0?null:i,o=n.container,l=o===void 0?null:o,f=n.layout,u=f===void 0?null:f,h=n.offset,m=h===void 0?null:h,g=n.mouseHandlerCallback,_=g===void 0?null:g;this.coordinateList=(r=a??this.coordinateList)!==null&&r!==void 0?r:[],this.container=l??this.container,this.layout=u??this.layout,this.offset=m??this.offset,this.mouseHandlerCallback=_??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(),a=i.x,o=i.y,l=i.height,f=this.coordinateList[this.activeIndex].coordinate,u=((n=window)===null||n===void 0?void 0:n.scrollX)||0,h=((r=window)===null||r===void 0?void 0:r.scrollY)||0,m=a+f+u,g=o+this.offset.top+l/2+h;this.mouseHandlerCallback({pageX:m,pageY:g})}}}])}();function e2e(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&&Ze(r)&&Ze(i))return!0}return!1}function t2e(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 Iq(e){var t=e.cx,n=e.cy,r=e.radius,i=e.startAngle,a=e.endAngle,o=cn(t,n,r,i),l=cn(t,n,r,a);return{points:[o,l],cx:t,cy:n,radius:r,startAngle:i,endAngle:a}}function n2e(e,t,n){var r,i,a,o;if(e==="horizontal")r=t.x,a=r,i=n.top,o=n.top+n.height;else if(e==="vertical")i=t.y,o=i,r=n.left,a=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var l=t.cx,f=t.cy,u=t.innerRadius,h=t.outerRadius,m=t.angle,g=cn(l,f,u,m),_=cn(l,f,h,m);r=g.x,i=g.y,a=_.x,o=_.y}else return Iq(t);return[{x:r,y:i},{x:a,y:o}]}function Bm(e){"@babel/helpers - typeof";return Bm=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},Bm(e)}function GI(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 dy(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?GI(Object(n),!0).forEach(function(r){r2e(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):GI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function r2e(e,t,n){return t=i2e(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i2e(e){var t=a2e(e,"string");return Bm(t)=="symbol"?t:t+""}function a2e(e,t){if(Bm(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Bm(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function o2e(e){var t,n,r=e.element,i=e.tooltipEventType,a=e.isActive,o=e.activeCoordinate,l=e.activePayload,f=e.offset,u=e.activeTooltipIndex,h=e.tooltipAxisBandSize,m=e.layout,g=e.chartName,_=(t=r.props.cursor)!==null&&t!==void 0?t:(n=r.type.defaultProps)===null||n===void 0?void 0:n.cursor;if(!r||!_||!a||!o||g!=="ScatterChart"&&i!=="axis")return null;var x,b=El;if(g==="ScatterChart")x=o,b=Q0e;else if(g==="BarChart")x=t2e(m,o,f,h),b=Y3;else if(m==="radial"){var S=Iq(o),C=S.cx,A=S.cy,O=S.radius,P=S.startAngle,j=S.endAngle;x={cx:C,cy:A,startAngle:P,endAngle:j,innerRadius:O,outerRadius:O},b=PF}else x={points:n2e(m,o,f)},b=El;var R=dy(dy(dy(dy({stroke:"#ccc",pointerEvents:"none"},f),x),ot(_,!1)),{},{payload:l,payloadIndex:u,className:be("recharts-tooltip-cursor",_.className)});return M.isValidElement(_)?M.cloneElement(_,R):M.createElement(b,R)}var s2e=["item"],l2e=["children","className","width","height","style","compact","title","desc"];function _d(e){"@babel/helpers - typeof";return _d=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},_d(e)}function Tf(){return Tf=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},Tf.apply(this,arguments)}function WI(e,t){return f2e(e)||c2e(e,t)||Bq(e,t)||u2e()}function u2e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function c2e(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,o,l=[],f=!0,u=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(f=(r=a.call(n)).done)&&(l.push(r.value),l.length!==t);f=!0);}catch(h){u=!0,i=h}finally{try{if(!f&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw i}}return l}}function f2e(e){if(Array.isArray(e))return e}function YI(e,t){if(e==null)return{};var n=d2e(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function d2e(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 h2e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function p2e(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,Uq(r.key),r)}}function m2e(e,t,n){return t&&p2e(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function g2e(e,t,n){return t=cb(t),v2e(e,$q()?Reflect.construct(t,n||[],cb(e).constructor):t.apply(e,n))}function v2e(e,t){if(t&&(_d(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return y2e(e)}function y2e(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $q(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return($q=function(){return!!e})()}function cb(e){return cb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},cb(e)}function b2e(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&&FO(e,t)}function FO(e,t){return FO=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},FO(e,t)}function xd(e){return x2e(e)||_2e(e)||Bq(e)||w2e()}function w2e(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Bq(e,t){if(e){if(typeof e=="string")return qO(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 qO(e,t)}}function _2e(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function x2e(e){if(Array.isArray(e))return qO(e)}function qO(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 KI(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 De(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?KI(Object(n),!0).forEach(function(r){gt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):KI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gt(e,t,n){return t=Uq(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Uq(e){var t=S2e(e,"string");return _d(t)=="symbol"?t:t+""}function S2e(e,t){if(_d(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_d(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var C2e={xAxis:["bottom","top"],yAxis:["left","right"]},A2e={width:"100%",height:"100%"},zq={x:0,y:0};function hy(e){return e}var E2e=function(t,n){return n==="horizontal"?t.x:n==="vertical"?t.y:n==="centric"?t.angle:t.radius},O2e=function(t,n,r,i){var a=n.find(function(h){return h&&h.index===r});if(a){if(t==="horizontal")return{x:a.coordinate,y:i.y};if(t==="vertical")return{x:i.x,y:a.coordinate};if(t==="centric"){var o=a.coordinate,l=i.radius;return De(De(De({},i),cn(i.cx,i.cy,l,o)),{},{angle:o,radius:l})}var f=a.coordinate,u=i.angle;return De(De(De({},i),cn(i.cx,i.cy,f,u)),{},{angle:u,radius:f})}return zq},L1=function(t,n){var r=n.graphicalItems,i=n.dataStartIndex,a=n.dataEndIndex,o=(r??[]).reduce(function(l,f){var u=f.props.data;return u&&u.length?[].concat(xd(l),xd(u)):l},[]);return o.length>0?o:t&&t.length&&Ze(i)&&Ze(a)?t.slice(i,a+1):[]};function Fq(e){return e==="number"?[0,"auto"]:void 0}var VO=function(t,n,r,i){var a=t.graphicalItems,o=t.tooltipAxis,l=L1(n,t);return r<0||!a||!a.length||r>=l.length?null:a.reduce(function(f,u){var h,m=(h=u.props.data)!==null&&h!==void 0?h:n;m&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=r&&(m=m.slice(t.dataStartIndex,t.dataEndIndex+1));var g;if(o.dataKey&&!o.allowDuplicatedCategory){var _=m===void 0?l:m;g=c0(_,o.dataKey,i)}else g=m&&m[r]||l[r];return g?[].concat(xd(f),[CF(u,g)]):f},[])},ZI=function(t,n,r,i){var a=i||{x:t.chartX,y:t.chartY},o=E2e(a,r),l=t.orderedTooltipTicks,f=t.tooltipAxis,u=t.tooltipTicks,h=Oge(o,l,u,f);if(h>=0&&u){var m=u[h]&&u[h].value,g=VO(t,n,h,m),_=O2e(r,l,h,a);return{activeTooltipIndex:h,activeLabel:m,activePayload:g,activeCoordinate:_}}return null},T2e=function(t,n){var r=n.axes,i=n.graphicalItems,a=n.axisType,o=n.axisIdKey,l=n.stackGroups,f=n.dataStartIndex,u=n.dataEndIndex,h=t.layout,m=t.children,g=t.stackOffset,_=yF(h,a);return r.reduce(function(x,b){var S,C=b.type.defaultProps!==void 0?De(De({},b.type.defaultProps),b.props):b.props,A=C.type,O=C.dataKey,P=C.allowDataOverflow,j=C.allowDuplicatedCategory,R=C.scale,U=C.ticks,V=C.includeHidden,Y=C[o];if(x[Y])return x;var K=L1(t.data,{graphicalItems:i.filter(function(Q){var G,ae=o in Q.props?Q.props[o]:(G=Q.type.defaultProps)===null||G===void 0?void 0:G[o];return ae===Y}),dataStartIndex:f,dataEndIndex:u}),W=K.length,ee,ie,X;e2e(C.domain,P,A)&&(ee=tO(C.domain,null,P),_&&(A==="number"||R!=="auto")&&(X=Dp(K,O,"category")));var ne=Fq(A);if(!ee||ee.length===0){var H,I=(H=C.domain)!==null&&H!==void 0?H:ne;if(O){if(ee=Dp(K,O,A),A==="category"&&_){var D=ble(ee);j&&D?(ie=ee,ee=Y0(0,W)):j||(ee=KD(I,ee,b).reduce(function(Q,G){return Q.indexOf(G)>=0?Q:[].concat(xd(Q),[G])},[]))}else if(A==="category")j?ee=ee.filter(function(Q){return Q!==""&&!pt(Q)}):ee=KD(I,ee,b).reduce(function(Q,G){return Q.indexOf(G)>=0||G===""||pt(G)?Q:[].concat(xd(Q),[G])},[]);else if(A==="number"){var z=Mge(K,i.filter(function(Q){var G,ae,fe=o in Q.props?Q.props[o]:(G=Q.type.defaultProps)===null||G===void 0?void 0:G[o],ce="hide"in Q.props?Q.props.hide:(ae=Q.type.defaultProps)===null||ae===void 0?void 0:ae.hide;return fe===Y&&(V||!ce)}),O,a,h);z&&(ee=z)}_&&(A==="number"||R!=="auto")&&(X=Dp(K,O,"category"))}else _?ee=Y0(0,W):l&&l[Y]&&l[Y].hasStack&&A==="number"?ee=g==="expand"?[0,1]:SF(l[Y].stackGroups,f,u):ee=vF(K,i.filter(function(Q){var G=o in Q.props?Q.props[o]:Q.type.defaultProps[o],ae="hide"in Q.props?Q.props.hide:Q.type.defaultProps.hide;return G===Y&&(V||!ae)}),A,h,!0);if(A==="number")ee=zO(m,ee,Y,a,U),I&&(ee=tO(I,ee,P));else if(A==="category"&&I){var N=I,B=ee.every(function(Q){return N.indexOf(Q)>=0});B&&(ee=N)}}return De(De({},x),{},gt({},Y,De(De({},C),{},{axisType:a,domain:ee,categoricalDomain:X,duplicateDomain:ie,originalDomain:(S=C.domain)!==null&&S!==void 0?S:ne,isCategorical:_,layout:h})))},{})},j2e=function(t,n){var r=n.graphicalItems,i=n.Axis,a=n.axisType,o=n.axisIdKey,l=n.stackGroups,f=n.dataStartIndex,u=n.dataEndIndex,h=t.layout,m=t.children,g=L1(t.data,{graphicalItems:r,dataStartIndex:f,dataEndIndex:u}),_=g.length,x=yF(h,a),b=-1;return r.reduce(function(S,C){var A=C.type.defaultProps!==void 0?De(De({},C.type.defaultProps),C.props):C.props,O=A[o],P=Fq("number");if(!S[O]){b++;var j;return x?j=Y0(0,_):l&&l[O]&&l[O].hasStack?(j=SF(l[O].stackGroups,f,u),j=zO(m,j,O,a)):(j=tO(P,vF(g,r.filter(function(R){var U,V,Y=o in R.props?R.props[o]:(U=R.type.defaultProps)===null||U===void 0?void 0:U[o],K="hide"in R.props?R.props.hide:(V=R.type.defaultProps)===null||V===void 0?void 0:V.hide;return Y===O&&!K}),"number",h),i.defaultProps.allowDataOverflow),j=zO(m,j,O,a)),De(De({},S),{},gt({},O,De(De({axisType:a},i.defaultProps),{},{hide:!0,orientation:Ti(C2e,"".concat(a,".").concat(b%2),null),domain:j,originalDomain:P,isCategorical:x,layout:h})))}return S},{})},P2e=function(t,n){var r=n.axisType,i=r===void 0?"xAxis":r,a=n.AxisComp,o=n.graphicalItems,l=n.stackGroups,f=n.dataStartIndex,u=n.dataEndIndex,h=t.children,m="".concat(i,"Id"),g=Gr(h,a),_={};return g&&g.length?_=T2e(t,{axes:g,graphicalItems:o,axisType:i,axisIdKey:m,stackGroups:l,dataStartIndex:f,dataEndIndex:u}):o&&o.length&&(_=j2e(t,{Axis:a,graphicalItems:o,axisType:i,axisIdKey:m,stackGroups:l,dataStartIndex:f,dataEndIndex:u})),_},R2e=function(t){var n=vl(t),r=Zo(n,!1,!0);return{tooltipTicks:r,orderedTooltipTicks:_3(r,function(i){return i.coordinate}),tooltipAxis:n,tooltipAxisBandSize:k0(n,r)}},XI=function(t){var n=t.children,r=t.defaultShowTooltip,i=_i(n,ud),a=0,o=0;return t.data&&t.data.length!==0&&(o=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(a=i.props.startIndex),i.props.endIndex>=0&&(o=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:a,dataEndIndex:o,activeTooltipIndex:-1,isTooltipActive:!!r}},M2e=function(t){return!t||!t.length?!1:t.some(function(n){var r=Jo(n&&n.type);return r&&r.indexOf("Bar")>=0})},QI=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"}},N2e=function(t,n){var r=t.props,i=t.graphicalItems,a=t.xAxisMap,o=a===void 0?{}:a,l=t.yAxisMap,f=l===void 0?{}:l,u=r.width,h=r.height,m=r.children,g=r.margin||{},_=_i(m,ud),x=_i(m,Df),b=Object.keys(f).reduce(function(j,R){var U=f[R],V=U.orientation;return!U.mirror&&!U.hide?De(De({},j),{},gt({},V,j[V]+U.width)):j},{left:g.left||0,right:g.right||0}),S=Object.keys(o).reduce(function(j,R){var U=o[R],V=U.orientation;return!U.mirror&&!U.hide?De(De({},j),{},gt({},V,Ti(j,"".concat(V))+U.height)):j},{top:g.top||0,bottom:g.bottom||0}),C=De(De({},S),b),A=C.bottom;_&&(C.bottom+=_.props.height||ud.defaultProps.height),x&&n&&(C=Pge(C,i,r,n));var O=u-C.left-C.right,P=h-C.top-C.bottom;return De(De({brushBottom:A},C),{},{width:Math.max(O,0),height:Math.max(P,0)})},L2e=function(t,n){if(n==="xAxis")return t[n].width;if(n==="yAxis")return t[n].height},a4=function(t){var n=t.chartName,r=t.GraphicalChild,i=t.defaultTooltipEventType,a=i===void 0?"axis":i,o=t.validateTooltipEventTypes,l=o===void 0?["axis"]:o,f=t.axisComponents,u=t.legendContent,h=t.formatAxisMap,m=t.defaultProps,g=function(C,A){var O=A.graphicalItems,P=A.stackGroups,j=A.offset,R=A.updateId,U=A.dataStartIndex,V=A.dataEndIndex,Y=C.barSize,K=C.layout,W=C.barGap,ee=C.barCategoryGap,ie=C.maxBarSize,X=QI(K),ne=X.numericAxisName,H=X.cateAxisName,I=M2e(O),D=[];return O.forEach(function(z,N){var B=L1(C.data,{graphicalItems:[z],dataStartIndex:U,dataEndIndex:V}),Q=z.type.defaultProps!==void 0?De(De({},z.type.defaultProps),z.props):z.props,G=Q.dataKey,ae=Q.maxBarSize,fe=Q["".concat(ne,"Id")],ce=Q["".concat(H,"Id")],ye={},F=f.reduce(function($e,ze){var _e=A["".concat(ze.axisType,"Map")],Se=Q["".concat(ze.axisType,"Id")];_e&&_e[Se]||ze.axisType==="zAxis"||sc();var ke=_e[Se];return De(De({},$e),{},gt(gt({},ze.axisType,ke),"".concat(ze.axisType,"Ticks"),Zo(ke)))},ye),q=F[H],te=F["".concat(H,"Ticks")],ue=P&&P[fe]&&P[fe].hasStack&&zge(z,P[fe].stackGroups),J=Jo(z.type).indexOf("Bar")>=0,se=k0(q,te),de=[],ve=I&&Tge({barSize:Y,stackGroups:P,totalSize:L2e(F,H)});if(J){var he,xe,Oe=pt(ae)?ie:ae,Le=(he=(xe=k0(q,te,!0))!==null&&xe!==void 0?xe:Oe)!==null&&he!==void 0?he:0;de=jge({barGap:W,barCategoryGap:ee,bandSize:Le!==se?Le:se,sizeList:ve[ce],maxBarSize:Oe}),Le!==se&&(de=de.map(function($e){return De(De({},$e),{},{position:De(De({},$e.position),{},{offset:$e.position.offset-Le/2})})}))}var He=z&&z.type&&z.type.getComposedData;He&&D.push({props:De(De({},He(De(De({},F),{},{displayedData:B,props:C,dataKey:G,item:z,bandSize:se,barPosition:de,offset:j,stackedData:ue,layout:K,dataStartIndex:U,dataEndIndex:V}))),{},gt(gt(gt({key:z.key||"item-".concat(N)},ne,F[ne]),H,F[H]),"animationId",R)),childIndex:Mle(z,C.children),item:z})}),D},_=function(C,A){var O=C.props,P=C.dataStartIndex,j=C.dataEndIndex,R=C.updateId;if(!c5({props:O}))return null;var U=O.children,V=O.layout,Y=O.stackOffset,K=O.data,W=O.reverseStackOrder,ee=QI(V),ie=ee.numericAxisName,X=ee.cateAxisName,ne=Gr(U,r),H=Bge(K,ne,"".concat(ie,"Id"),"".concat(X,"Id"),Y,W),I=f.reduce(function(Q,G){var ae="".concat(G.axisType,"Map");return De(De({},Q),{},gt({},ae,P2e(O,De(De({},G),{},{graphicalItems:ne,stackGroups:G.axisType===ie&&H,dataStartIndex:P,dataEndIndex:j}))))},{}),D=N2e(De(De({},I),{},{props:O,graphicalItems:ne}),A==null?void 0:A.legendBBox);Object.keys(I).forEach(function(Q){I[Q]=h(O,I[Q],D,Q.replace("Map",""),n)});var z=I["".concat(X,"Map")],N=R2e(z),B=g(O,De(De({},I),{},{dataStartIndex:P,dataEndIndex:j,updateId:R,graphicalItems:ne,stackGroups:H,offset:D}));return De(De({formattedGraphicalItems:B,graphicalItems:ne,offset:D,stackGroups:H},N),I)},x=function(S){function C(A){var O,P,j;return h2e(this,C),j=g2e(this,C,[A]),gt(j,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),gt(j,"accessibilityManager",new Jxe),gt(j,"handleLegendBBoxUpdate",function(R){if(R){var U=j.state,V=U.dataStartIndex,Y=U.dataEndIndex,K=U.updateId;j.setState(De({legendBBox:R},_({props:j.props,dataStartIndex:V,dataEndIndex:Y,updateId:K},De(De({},j.state),{},{legendBBox:R}))))}}),gt(j,"handleReceiveSyncEvent",function(R,U,V){if(j.props.syncId===R){if(V===j.eventEmitterSymbol&&typeof j.props.syncMethod!="function")return;j.applySyncEvent(U)}}),gt(j,"handleBrushChange",function(R){var U=R.startIndex,V=R.endIndex;if(U!==j.state.dataStartIndex||V!==j.state.dataEndIndex){var Y=j.state.updateId;j.setState(function(){return De({dataStartIndex:U,dataEndIndex:V},_({props:j.props,dataStartIndex:U,dataEndIndex:V,updateId:Y},j.state))}),j.triggerSyncEvent({dataStartIndex:U,dataEndIndex:V})}}),gt(j,"handleMouseEnter",function(R){var U=j.getMouseInfo(R);if(U){var V=De(De({},U),{},{isTooltipActive:!0});j.setState(V),j.triggerSyncEvent(V);var Y=j.props.onMouseEnter;ht(Y)&&Y(V,R)}}),gt(j,"triggeredAfterMouseMove",function(R){var U=j.getMouseInfo(R),V=U?De(De({},U),{},{isTooltipActive:!0}):{isTooltipActive:!1};j.setState(V),j.triggerSyncEvent(V);var Y=j.props.onMouseMove;ht(Y)&&Y(V,R)}),gt(j,"handleItemMouseEnter",function(R){j.setState(function(){return{isTooltipActive:!0,activeItem:R,activePayload:R.tooltipPayload,activeCoordinate:R.tooltipPosition||{x:R.cx,y:R.cy}}})}),gt(j,"handleItemMouseLeave",function(){j.setState(function(){return{isTooltipActive:!1}})}),gt(j,"handleMouseMove",function(R){R.persist(),j.throttleTriggeredAfterMouseMove(R)}),gt(j,"handleMouseLeave",function(R){j.throttleTriggeredAfterMouseMove.cancel();var U={isTooltipActive:!1};j.setState(U),j.triggerSyncEvent(U);var V=j.props.onMouseLeave;ht(V)&&V(U,R)}),gt(j,"handleOuterEvent",function(R){var U=Rle(R),V=Ti(j.props,"".concat(U));if(U&&ht(V)){var Y,K;/.*touch.*/i.test(U)?K=j.getMouseInfo(R.changedTouches[0]):K=j.getMouseInfo(R),V((Y=K)!==null&&Y!==void 0?Y:{},R)}}),gt(j,"handleClick",function(R){var U=j.getMouseInfo(R);if(U){var V=De(De({},U),{},{isTooltipActive:!0});j.setState(V),j.triggerSyncEvent(V);var Y=j.props.onClick;ht(Y)&&Y(V,R)}}),gt(j,"handleMouseDown",function(R){var U=j.props.onMouseDown;if(ht(U)){var V=j.getMouseInfo(R);U(V,R)}}),gt(j,"handleMouseUp",function(R){var U=j.props.onMouseUp;if(ht(U)){var V=j.getMouseInfo(R);U(V,R)}}),gt(j,"handleTouchMove",function(R){R.changedTouches!=null&&R.changedTouches.length>0&&j.throttleTriggeredAfterMouseMove(R.changedTouches[0])}),gt(j,"handleTouchStart",function(R){R.changedTouches!=null&&R.changedTouches.length>0&&j.handleMouseDown(R.changedTouches[0])}),gt(j,"handleTouchEnd",function(R){R.changedTouches!=null&&R.changedTouches.length>0&&j.handleMouseUp(R.changedTouches[0])}),gt(j,"handleDoubleClick",function(R){var U=j.props.onDoubleClick;if(ht(U)){var V=j.getMouseInfo(R);U(V,R)}}),gt(j,"handleContextMenu",function(R){var U=j.props.onContextMenu;if(ht(U)){var V=j.getMouseInfo(R);U(V,R)}}),gt(j,"triggerSyncEvent",function(R){j.props.syncId!==void 0&&vA.emit(yA,j.props.syncId,R,j.eventEmitterSymbol)}),gt(j,"applySyncEvent",function(R){var U=j.props,V=U.layout,Y=U.syncMethod,K=j.state.updateId,W=R.dataStartIndex,ee=R.dataEndIndex;if(R.dataStartIndex!==void 0||R.dataEndIndex!==void 0)j.setState(De({dataStartIndex:W,dataEndIndex:ee},_({props:j.props,dataStartIndex:W,dataEndIndex:ee,updateId:K},j.state)));else if(R.activeTooltipIndex!==void 0){var ie=R.chartX,X=R.chartY,ne=R.activeTooltipIndex,H=j.state,I=H.offset,D=H.tooltipTicks;if(!I)return;if(typeof Y=="function")ne=Y(D,R);else if(Y==="value"){ne=-1;for(var z=0;z<D.length;z++)if(D[z].value===R.activeLabel){ne=z;break}}var N=De(De({},I),{},{x:I.left,y:I.top}),B=Math.min(ie,N.x+N.width),Q=Math.min(X,N.y+N.height),G=D[ne]&&D[ne].value,ae=VO(j.state,j.props.data,ne),fe=D[ne]?{x:V==="horizontal"?D[ne].coordinate:B,y:V==="horizontal"?Q:D[ne].coordinate}:zq;j.setState(De(De({},R),{},{activeLabel:G,activeCoordinate:fe,activePayload:ae,activeTooltipIndex:ne}))}else j.setState(R)}),gt(j,"renderCursor",function(R){var U,V=j.state,Y=V.isTooltipActive,K=V.activeCoordinate,W=V.activePayload,ee=V.offset,ie=V.activeTooltipIndex,X=V.tooltipAxisBandSize,ne=j.getTooltipEventType(),H=(U=R.props.active)!==null&&U!==void 0?U:Y,I=j.props.layout,D=R.key||"_recharts-cursor";return pe.createElement(o2e,{key:D,activeCoordinate:K,activePayload:W,activeTooltipIndex:ie,chartName:n,element:R,isActive:H,layout:I,offset:ee,tooltipAxisBandSize:X,tooltipEventType:ne})}),gt(j,"renderPolarAxis",function(R,U,V){var Y=Ti(R,"type.axisType"),K=Ti(j.state,"".concat(Y,"Map")),W=R.type.defaultProps,ee=W!==void 0?De(De({},W),R.props):R.props,ie=K&&K[ee["".concat(Y,"Id")]];return M.cloneElement(R,De(De({},ie),{},{className:be(Y,ie.className),key:R.key||"".concat(U,"-").concat(V),ticks:Zo(ie,!0)}))}),gt(j,"renderPolarGrid",function(R){var U=R.props,V=U.radialLines,Y=U.polarAngles,K=U.polarRadius,W=j.state,ee=W.radiusAxisMap,ie=W.angleAxisMap,X=vl(ee),ne=vl(ie),H=ne.cx,I=ne.cy,D=ne.innerRadius,z=ne.outerRadius;return M.cloneElement(R,{polarAngles:Array.isArray(Y)?Y:Zo(ne,!0).map(function(N){return N.coordinate}),polarRadius:Array.isArray(K)?K:Zo(X,!0).map(function(N){return N.coordinate}),cx:H,cy:I,innerRadius:D,outerRadius:z,key:R.key||"polar-grid",radialLines:V})}),gt(j,"renderLegend",function(){var R=j.state.formattedGraphicalItems,U=j.props,V=U.children,Y=U.width,K=U.height,W=j.props.margin||{},ee=Y-(W.left||0)-(W.right||0),ie=mF({children:V,formattedGraphicalItems:R,legendWidth:ee,legendContent:u});if(!ie)return null;var X=ie.item,ne=YI(ie,s2e);return M.cloneElement(X,De(De({},ne),{},{chartWidth:Y,chartHeight:K,margin:W,onBBoxUpdate:j.handleLegendBBoxUpdate}))}),gt(j,"renderTooltip",function(){var R,U=j.props,V=U.children,Y=U.accessibilityLayer,K=_i(V,Xi);if(!K)return null;var W=j.state,ee=W.isTooltipActive,ie=W.activeCoordinate,X=W.activePayload,ne=W.activeLabel,H=W.offset,I=(R=K.props.active)!==null&&R!==void 0?R:ee;return M.cloneElement(K,{viewBox:De(De({},H),{},{x:H.left,y:H.top}),active:I,label:ne,payload:I?X:[],coordinate:ie,accessibilityLayer:Y})}),gt(j,"renderBrush",function(R){var U=j.props,V=U.margin,Y=U.data,K=j.state,W=K.offset,ee=K.dataStartIndex,ie=K.dataEndIndex,X=K.updateId;return M.cloneElement(R,{key:R.key||"_recharts-brush",onChange:ly(j.handleBrushChange,R.props.onChange),data:Y,x:Ze(R.props.x)?R.props.x:W.left,y:Ze(R.props.y)?R.props.y:W.top+W.height+W.brushBottom-(V.bottom||0),width:Ze(R.props.width)?R.props.width:W.width,startIndex:ee,endIndex:ie,updateId:"brush-".concat(X)})}),gt(j,"renderReferenceElement",function(R,U,V){if(!R)return null;var Y=j,K=Y.clipPathId,W=j.state,ee=W.xAxisMap,ie=W.yAxisMap,X=W.offset,ne=R.type.defaultProps||{},H=R.props,I=H.xAxisId,D=I===void 0?ne.xAxisId:I,z=H.yAxisId,N=z===void 0?ne.yAxisId:z;return M.cloneElement(R,{key:R.key||"".concat(U,"-").concat(V),xAxis:ee[D],yAxis:ie[N],viewBox:{x:X.left,y:X.top,width:X.width,height:X.height},clipPathId:K})}),gt(j,"renderActivePoints",function(R){var U=R.item,V=R.activePoint,Y=R.basePoint,K=R.childIndex,W=R.isRange,ee=[],ie=U.props.key,X=U.item.type.defaultProps!==void 0?De(De({},U.item.type.defaultProps),U.item.props):U.item.props,ne=X.activeDot,H=X.dataKey,I=De(De({index:K,dataKey:H,cx:V.x,cy:V.y,r:4,fill:W3(U.item),strokeWidth:2,stroke:"#fff",payload:V.payload,value:V.value},ot(ne,!1)),f0(ne));return ee.push(C.renderActiveDot(ne,I,"".concat(ie,"-activePoint-").concat(K))),Y?ee.push(C.renderActiveDot(ne,De(De({},I),{},{cx:Y.x,cy:Y.y}),"".concat(ie,"-basePoint-").concat(K))):W&&ee.push(null),ee}),gt(j,"renderGraphicChild",function(R,U,V){var Y=j.filterFormatItem(R,U,V);if(!Y)return null;var K=j.getTooltipEventType(),W=j.state,ee=W.isTooltipActive,ie=W.tooltipAxis,X=W.activeTooltipIndex,ne=W.activeLabel,H=j.props.children,I=_i(H,Xi),D=Y.props,z=D.points,N=D.isRange,B=D.baseLine,Q=Y.item.type.defaultProps!==void 0?De(De({},Y.item.type.defaultProps),Y.item.props):Y.item.props,G=Q.activeDot,ae=Q.hide,fe=Q.activeBar,ce=Q.activeShape,ye=!!(!ae&&ee&&I&&(G||fe||ce)),F={};K!=="axis"&&I&&I.props.trigger==="click"?F={onClick:ly(j.handleItemMouseEnter,R.props.onClick)}:K!=="axis"&&(F={onMouseLeave:ly(j.handleItemMouseLeave,R.props.onMouseLeave),onMouseEnter:ly(j.handleItemMouseEnter,R.props.onMouseEnter)});var q=M.cloneElement(R,De(De({},Y.props),F));function te(ze){return typeof ie.dataKey=="function"?ie.dataKey(ze.payload):null}if(ye)if(X>=0){var ue,J;if(ie.dataKey&&!ie.allowDuplicatedCategory){var se=typeof ie.dataKey=="function"?te:"payload.".concat(ie.dataKey.toString());ue=c0(z,se,ne),J=N&&B&&c0(B,se,ne)}else ue=z==null?void 0:z[X],J=N&&B&&B[X];if(ce||fe){var de=R.props.activeIndex!==void 0?R.props.activeIndex:X;return[M.cloneElement(R,De(De(De({},Y.props),F),{},{activeIndex:de})),null,null]}if(!pt(ue))return[q].concat(xd(j.renderActivePoints({item:Y,activePoint:ue,basePoint:J,childIndex:X,isRange:N})))}else{var ve,he=(ve=j.getItemByXY(j.state.activeCoordinate))!==null&&ve!==void 0?ve:{graphicalItem:q},xe=he.graphicalItem,Oe=xe.item,Le=Oe===void 0?R:Oe,He=xe.childIndex,$e=De(De(De({},Y.props),F),{},{activeIndex:He});return[M.cloneElement(Le,$e),null,null]}return N?[q,null,null]:[q,null]}),gt(j,"renderCustomized",function(R,U,V){return M.cloneElement(R,De(De({key:"recharts-customized-".concat(V)},j.props),j.state))}),gt(j,"renderMap",{CartesianGrid:{handler:hy,once:!0},ReferenceArea:{handler:j.renderReferenceElement},ReferenceLine:{handler:hy},ReferenceDot:{handler:j.renderReferenceElement},XAxis:{handler:hy},YAxis:{handler:hy},Brush:{handler:j.renderBrush,once:!0},Bar:{handler:j.renderGraphicChild},Line:{handler:j.renderGraphicChild},Area:{handler:j.renderGraphicChild},Radar:{handler:j.renderGraphicChild},RadialBar:{handler:j.renderGraphicChild},Scatter:{handler:j.renderGraphicChild},Pie:{handler:j.renderGraphicChild},Funnel:{handler:j.renderGraphicChild},Tooltip:{handler:j.renderCursor,once:!0},PolarGrid:{handler:j.renderPolarGrid,once:!0},PolarAngleAxis:{handler:j.renderPolarAxis},PolarRadiusAxis:{handler:j.renderPolarAxis},Customized:{handler:j.renderCustomized}}),j.clipPathId="".concat((O=A.id)!==null&&O!==void 0?O:Yl("recharts"),"-clip"),j.throttleTriggeredAfterMouseMove=pz(j.triggeredAfterMouseMove,(P=A.throttleDelay)!==null&&P!==void 0?P:1e3/60),j.state={},j}return b2e(C,S),m2e(C,[{key:"componentDidMount",value:function(){var O,P;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(O=this.props.margin.left)!==null&&O!==void 0?O:0,top:(P=this.props.margin.top)!==null&&P!==void 0?P:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var O=this.props,P=O.children,j=O.data,R=O.height,U=O.layout,V=_i(P,Xi);if(V){var Y=V.props.defaultIndex;if(!(typeof Y!="number"||Y<0||Y>this.state.tooltipTicks.length-1)){var K=this.state.tooltipTicks[Y]&&this.state.tooltipTicks[Y].value,W=VO(this.state,j,Y,K),ee=this.state.tooltipTicks[Y].coordinate,ie=(this.state.offset.top+R)/2,X=U==="horizontal",ne=X?{x:ee,y:ie}:{y:ee,x:ie},H=this.state.formattedGraphicalItems.find(function(D){var z=D.item;return z.type.name==="Scatter"});H&&(ne=De(De({},ne),H.props.points[Y].tooltipPosition),W=H.props.points[Y].tooltipPayload);var I={activeTooltipIndex:Y,isTooltipActive:!0,activeLabel:K,activePayload:W,activeCoordinate:ne};this.setState(I),this.renderCursor(V),this.accessibilityManager.setIndex(Y)}}}},{key:"getSnapshotBeforeUpdate",value:function(O,P){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==P.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==O.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==O.margin){var j,R;this.accessibilityManager.setDetails({offset:{left:(j=this.props.margin.left)!==null&&j!==void 0?j:0,top:(R=this.props.margin.top)!==null&&R!==void 0?R:0}})}return null}},{key:"componentDidUpdate",value:function(O){SE([_i(O.children,Xi)],[_i(this.props.children,Xi)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var O=_i(this.props.children,Xi);if(O&&typeof O.props.shared=="boolean"){var P=O.props.shared?"axis":"item";return l.indexOf(P)>=0?P:a}return a}},{key:"getMouseInfo",value:function(O){if(!this.container)return null;var P=this.container,j=P.getBoundingClientRect(),R=bde(j),U={chartX:Math.round(O.pageX-R.left),chartY:Math.round(O.pageY-R.top)},V=j.width/P.offsetWidth||1,Y=this.inRange(U.chartX,U.chartY,V);if(!Y)return null;var K=this.state,W=K.xAxisMap,ee=K.yAxisMap,ie=this.getTooltipEventType(),X=ZI(this.state,this.props.data,this.props.layout,Y);if(ie!=="axis"&&W&&ee){var ne=vl(W).scale,H=vl(ee).scale,I=ne&&ne.invert?ne.invert(U.chartX):null,D=H&&H.invert?H.invert(U.chartY):null;return De(De({},U),{},{xValue:I,yValue:D},X)}return X?De(De({},U),X):null}},{key:"inRange",value:function(O,P){var j=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,R=this.props.layout,U=O/j,V=P/j;if(R==="horizontal"||R==="vertical"){var Y=this.state.offset,K=U>=Y.left&&U<=Y.left+Y.width&&V>=Y.top&&V<=Y.top+Y.height;return K?{x:U,y:V}:null}var W=this.state,ee=W.angleAxisMap,ie=W.radiusAxisMap;if(ee&&ie){var X=vl(ee);return QD({x:U,y:V},X)}return null}},{key:"parseEventsOfWrapper",value:function(){var O=this.props.children,P=this.getTooltipEventType(),j=_i(O,Xi),R={};j&&P==="axis"&&(j.props.trigger==="click"?R={onClick:this.handleClick}:R={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 U=f0(this.props,this.handleOuterEvent);return De(De({},U),R)}},{key:"addListener",value:function(){vA.on(yA,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){vA.removeListener(yA,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(O,P,j){for(var R=this.state.formattedGraphicalItems,U=0,V=R.length;U<V;U++){var Y=R[U];if(Y.item===O||Y.props.key===O.key||P===Jo(Y.item.type)&&j===Y.childIndex)return Y}return null}},{key:"renderClipPath",value:function(){var O=this.clipPathId,P=this.state.offset,j=P.left,R=P.top,U=P.height,V=P.width;return pe.createElement("defs",null,pe.createElement("clipPath",{id:O},pe.createElement("rect",{x:j,y:R,height:U,width:V})))}},{key:"getXScales",value:function(){var O=this.state.xAxisMap;return O?Object.entries(O).reduce(function(P,j){var R=WI(j,2),U=R[0],V=R[1];return De(De({},P),{},gt({},U,V.scale))},{}):null}},{key:"getYScales",value:function(){var O=this.state.yAxisMap;return O?Object.entries(O).reduce(function(P,j){var R=WI(j,2),U=R[0],V=R[1];return De(De({},P),{},gt({},U,V.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(O){var P;return(P=this.state.xAxisMap)===null||P===void 0||(P=P[O])===null||P===void 0?void 0:P.scale}},{key:"getYScaleByAxisId",value:function(O){var P;return(P=this.state.yAxisMap)===null||P===void 0||(P=P[O])===null||P===void 0?void 0:P.scale}},{key:"getItemByXY",value:function(O){var P=this.state,j=P.formattedGraphicalItems,R=P.activeItem;if(j&&j.length)for(var U=0,V=j.length;U<V;U++){var Y=j[U],K=Y.props,W=Y.item,ee=W.type.defaultProps!==void 0?De(De({},W.type.defaultProps),W.props):W.props,ie=Jo(W.type);if(ie==="Bar"){var X=(K.data||[]).find(function(D){return M0e(O,D)});if(X)return{graphicalItem:Y,payload:X}}else if(ie==="RadialBar"){var ne=(K.data||[]).find(function(D){return QD(O,D)});if(ne)return{graphicalItem:Y,payload:ne}}else if(E1(Y,R)||O1(Y,R)||Nm(Y,R)){var H=n1e({graphicalItem:Y,activeTooltipItem:R,itemData:ee.data}),I=ee.activeIndex===void 0?H:ee.activeIndex;return{graphicalItem:De(De({},Y),{},{childIndex:I}),payload:Nm(Y,R)?ee.data[H]:Y.props.data[H]}}}return null}},{key:"render",value:function(){var O=this;if(!c5(this))return null;var P=this.props,j=P.children,R=P.className,U=P.width,V=P.height,Y=P.style,K=P.compact,W=P.title,ee=P.desc,ie=YI(P,l2e),X=ot(ie,!1);if(K)return pe.createElement(CI,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},pe.createElement(AE,Tf({},X,{width:U,height:V,title:W,desc:ee}),this.renderClipPath(),d5(j,this.renderMap)));if(this.props.accessibilityLayer){var ne,H;X.tabIndex=(ne=this.props.tabIndex)!==null&&ne!==void 0?ne:0,X.role=(H=this.props.role)!==null&&H!==void 0?H:"application",X.onKeyDown=function(D){O.accessibilityManager.keyboardEvent(D)},X.onFocus=function(){O.accessibilityManager.focus()}}var I=this.parseEventsOfWrapper();return pe.createElement(CI,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},pe.createElement("div",Tf({className:be("recharts-wrapper",R),style:De({position:"relative",cursor:"default",width:U,height:V},Y)},I,{ref:function(z){O.container=z}}),pe.createElement(AE,Tf({},X,{width:U,height:V,title:W,desc:ee,style:A2e}),this.renderClipPath(),d5(j,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(M.Component);gt(x,"displayName",n),gt(x,"defaultProps",De({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},m)),gt(x,"getDerivedStateFromProps",function(S,C){var A=S.dataKey,O=S.data,P=S.children,j=S.width,R=S.height,U=S.layout,V=S.stackOffset,Y=S.margin,K=C.dataStartIndex,W=C.dataEndIndex;if(C.updateId===void 0){var ee=XI(S);return De(De(De({},ee),{},{updateId:0},_(De(De({props:S},ee),{},{updateId:0}),C)),{},{prevDataKey:A,prevData:O,prevWidth:j,prevHeight:R,prevLayout:U,prevStackOffset:V,prevMargin:Y,prevChildren:P})}if(A!==C.prevDataKey||O!==C.prevData||j!==C.prevWidth||R!==C.prevHeight||U!==C.prevLayout||V!==C.prevStackOffset||!kf(Y,C.prevMargin)){var ie=XI(S),X={chartX:C.chartX,chartY:C.chartY,isTooltipActive:C.isTooltipActive},ne=De(De({},ZI(C,O,U)),{},{updateId:C.updateId+1}),H=De(De(De({},ie),X),ne);return De(De(De({},H),_(De({props:S},H),C)),{},{prevDataKey:A,prevData:O,prevWidth:j,prevHeight:R,prevLayout:U,prevStackOffset:V,prevMargin:Y,prevChildren:P})}if(!SE(P,C.prevChildren)){var I,D,z,N,B=_i(P,ud),Q=B&&(I=(D=B.props)===null||D===void 0?void 0:D.startIndex)!==null&&I!==void 0?I:K,G=B&&(z=(N=B.props)===null||N===void 0?void 0:N.endIndex)!==null&&z!==void 0?z:W,ae=Q!==K||G!==W,fe=!pt(O),ce=fe&&!ae?C.updateId:C.updateId+1;return De(De({updateId:ce},_(De(De({props:S},C),{},{updateId:ce,dataStartIndex:Q,dataEndIndex:G}),C)),{},{prevChildren:P,dataStartIndex:Q,dataEndIndex:G})}return null}),gt(x,"renderActiveDot",function(S,C,A){var O;return M.isValidElement(S)?O=M.cloneElement(S,C):ht(S)?O=S(C):O=pe.createElement(pg,C),pe.createElement(St,{className:"recharts-active-dot",key:A},O)});var b=M.forwardRef(function(C,A){return pe.createElement(x,Tf({},C,{ref:A}))});return b.displayName=x.displayName,b},k2e=a4({chartName:"LineChart",GraphicalChild:Hd,axisComponents:[{axisType:"xAxis",AxisComp:Gd},{axisType:"yAxis",AxisComp:Wd}],formatAxisMap:JF}),D2e=a4({chartName:"PieChart",GraphicalChild:uo,validateTooltipEventTypes:["item"],defaultTooltipEventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:A1},{axisType:"radiusAxis",AxisComp:S1}],formatAxisMap:Xge,defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"}}),I2e=a4({chartName:"ComposedChart",GraphicalChild:[Hd,vc,ts,N1],axisComponents:[{axisType:"xAxis",AxisComp:Gd},{axisType:"yAxis",AxisComp:Wd},{axisType:"zAxis",AxisComp:M1}],formatAxisMap:JF});function qq(e,t){const n=M.useRef(t);M.useEffect(function(){t!==n.current&&e.attributionControl!=null&&(n.current!=null&&e.attributionControl.removeAttribution(n.current),t!=null&&e.attributionControl.addAttribution(t)),n.current=t},[e,t])}const $2e=1;function B2e(e){return Object.freeze({__version:$2e,map:e})}function U2e(e,t){return Object.freeze({...e,...t})}const o4=M.createContext(null);function Vq(){const e=M.use(o4);if(e==null)throw new Error("No context provided: useLeafletContext() can only be used in a descendant of <MapContainer>");return e}function z2e(e){function t(n,r){const{instance:i,context:a}=e(n).current;M.useImperativeHandle(r,()=>i);const{children:o}=n;return o==null?null:pe.createElement(o4,{value:a},o)}return M.forwardRef(t)}function F2e(e){function t(n,r){const[i,a]=M.useState(!1),{instance:o}=e(n,a).current;M.useImperativeHandle(r,()=>o),M.useEffect(function(){i&&o.update()},[o,i,n.children]);const l=o._contentNode;return l?fc.createPortal(n.children,l):null}return M.forwardRef(t)}function q2e(e){function t(n,r){const{instance:i}=e(n).current;return M.useImperativeHandle(r,()=>i),null}return M.forwardRef(t)}function Hq(e,t){const n=M.useRef(void 0);M.useEffect(function(){return t!=null&&e.instance.on(t),n.current=t,function(){n.current!=null&&e.instance.off(n.current),n.current=null}},[e,t])}function s4(e,t){const n=e.pane??t.pane;return n?{...e,pane:n}:e}function V2e(e,t){return function(r,i){const a=Vq(),o=e(s4(r,a),a);return qq(a.map,r.attribution),Hq(o.current,r.eventHandlers),t(o.current,a,r,i),o}}var Op={exports:{}};/* @preserve
|
||
* Leaflet 1.9.4, a JS library for interactive maps. https://leafletjs.com
|
||
* (c) 2010-2023 Vladimir Agafonkin, (c) 2010-2011 CloudMade
|
||
*/var H2e=Op.exports,JI;function G2e(){return JI||(JI=1,function(e,t){(function(n,r){r(t)})(H2e,function(n){var r="1.9.4";function i(d){var y,E,$,Z;for(E=1,$=arguments.length;E<$;E++){Z=arguments[E];for(y in Z)d[y]=Z[y]}return d}var a=Object.create||function(){function d(){}return function(y){return d.prototype=y,new d}}();function o(d,y){var E=Array.prototype.slice;if(d.bind)return d.bind.apply(d,E.call(arguments,1));var $=E.call(arguments,2);return function(){return d.apply(y,$.length?$.concat(E.call(arguments)):arguments)}}var l=0;function f(d){return"_leaflet_id"in d||(d._leaflet_id=++l),d._leaflet_id}function u(d,y,E){var $,Z,oe,me;return me=function(){$=!1,Z&&(oe.apply(E,Z),Z=!1)},oe=function(){$?Z=arguments:(d.apply(E,arguments),setTimeout(me,y),$=!0)},oe}function h(d,y,E){var $=y[1],Z=y[0],oe=$-Z;return d===$&&E?d:((d-Z)%oe+oe)%oe+Z}function m(){return!1}function g(d,y){if(y===!1)return d;var E=Math.pow(10,y===void 0?6:y);return Math.round(d*E)/E}function _(d){return d.trim?d.trim():d.replace(/^\s+|\s+$/g,"")}function x(d){return _(d).split(/\s+/)}function b(d,y){Object.prototype.hasOwnProperty.call(d,"options")||(d.options=d.options?a(d.options):{});for(var E in y)d.options[E]=y[E];return d.options}function S(d,y,E){var $=[];for(var Z in d)$.push(encodeURIComponent(E?Z.toUpperCase():Z)+"="+encodeURIComponent(d[Z]));return(!y||y.indexOf("?")===-1?"?":"&")+$.join("&")}var C=/\{ *([\w_ -]+) *\}/g;function A(d,y){return d.replace(C,function(E,$){var Z=y[$];if(Z===void 0)throw new Error("No value provided for variable "+E);return typeof Z=="function"&&(Z=Z(y)),Z})}var O=Array.isArray||function(d){return Object.prototype.toString.call(d)==="[object Array]"};function P(d,y){for(var E=0;E<d.length;E++)if(d[E]===y)return E;return-1}var j="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";function R(d){return window["webkit"+d]||window["moz"+d]||window["ms"+d]}var U=0;function V(d){var y=+new Date,E=Math.max(0,16-(y-U));return U=y+E,window.setTimeout(d,E)}var Y=window.requestAnimationFrame||R("RequestAnimationFrame")||V,K=window.cancelAnimationFrame||R("CancelAnimationFrame")||R("CancelRequestAnimationFrame")||function(d){window.clearTimeout(d)};function W(d,y,E){if(E&&Y===V)d.call(y);else return Y.call(window,o(d,y))}function ee(d){d&&K.call(window,d)}var ie={__proto__:null,extend:i,create:a,bind:o,get lastId(){return l},stamp:f,throttle:u,wrapNum:h,falseFn:m,formatNum:g,trim:_,splitWords:x,setOptions:b,getParamString:S,template:A,isArray:O,indexOf:P,emptyImageUrl:j,requestFn:Y,cancelFn:K,requestAnimFrame:W,cancelAnimFrame:ee};function X(){}X.extend=function(d){var y=function(){b(this),this.initialize&&this.initialize.apply(this,arguments),this.callInitHooks()},E=y.__super__=this.prototype,$=a(E);$.constructor=y,y.prototype=$;for(var Z in this)Object.prototype.hasOwnProperty.call(this,Z)&&Z!=="prototype"&&Z!=="__super__"&&(y[Z]=this[Z]);return d.statics&&i(y,d.statics),d.includes&&(ne(d.includes),i.apply(null,[$].concat(d.includes))),i($,d),delete $.statics,delete $.includes,$.options&&($.options=E.options?a(E.options):{},i($.options,d.options)),$._initHooks=[],$.callInitHooks=function(){if(!this._initHooksCalled){E.callInitHooks&&E.callInitHooks.call(this),this._initHooksCalled=!0;for(var oe=0,me=$._initHooks.length;oe<me;oe++)$._initHooks[oe].call(this)}},y},X.include=function(d){var y=this.prototype.options;return i(this.prototype,d),d.options&&(this.prototype.options=y,this.mergeOptions(d.options)),this},X.mergeOptions=function(d){return i(this.prototype.options,d),this},X.addInitHook=function(d){var y=Array.prototype.slice.call(arguments,1),E=typeof d=="function"?d:function(){this[d].apply(this,y)};return this.prototype._initHooks=this.prototype._initHooks||[],this.prototype._initHooks.push(E),this};function ne(d){if(!(typeof L>"u"||!L||!L.Mixin)){d=O(d)?d:[d];for(var y=0;y<d.length;y++)d[y]===L.Mixin.Events&&console.warn("Deprecated include of L.Mixin.Events: this property will be removed in future releases, please inherit from L.Evented instead.",new Error().stack)}}var H={on:function(d,y,E){if(typeof d=="object")for(var $ in d)this._on($,d[$],y);else{d=x(d);for(var Z=0,oe=d.length;Z<oe;Z++)this._on(d[Z],y,E)}return this},off:function(d,y,E){if(!arguments.length)delete this._events;else if(typeof d=="object")for(var $ in d)this._off($,d[$],y);else{d=x(d);for(var Z=arguments.length===1,oe=0,me=d.length;oe<me;oe++)Z?this._off(d[oe]):this._off(d[oe],y,E)}return this},_on:function(d,y,E,$){if(typeof y!="function"){console.warn("wrong listener type: "+typeof y);return}if(this._listens(d,y,E)===!1){E===this&&(E=void 0);var Z={fn:y,ctx:E};$&&(Z.once=!0),this._events=this._events||{},this._events[d]=this._events[d]||[],this._events[d].push(Z)}},_off:function(d,y,E){var $,Z,oe;if(this._events&&($=this._events[d],!!$)){if(arguments.length===1){if(this._firingCount)for(Z=0,oe=$.length;Z<oe;Z++)$[Z].fn=m;delete this._events[d];return}if(typeof y!="function"){console.warn("wrong listener type: "+typeof y);return}var me=this._listens(d,y,E);if(me!==!1){var Ae=$[me];this._firingCount&&(Ae.fn=m,this._events[d]=$=$.slice()),$.splice(me,1)}}},fire:function(d,y,E){if(!this.listens(d,E))return this;var $=i({},y,{type:d,target:this,sourceTarget:y&&y.sourceTarget||this});if(this._events){var Z=this._events[d];if(Z){this._firingCount=this._firingCount+1||1;for(var oe=0,me=Z.length;oe<me;oe++){var Ae=Z[oe],Me=Ae.fn;Ae.once&&this.off(d,Me,Ae.ctx),Me.call(Ae.ctx||this,$)}this._firingCount--}}return E&&this._propagateEvent($),this},listens:function(d,y,E,$){typeof d!="string"&&console.warn('"string" type argument expected');var Z=y;typeof y!="function"&&($=!!y,Z=void 0,E=void 0);var oe=this._events&&this._events[d];if(oe&&oe.length&&this._listens(d,Z,E)!==!1)return!0;if($){for(var me in this._eventParents)if(this._eventParents[me].listens(d,y,E,$))return!0}return!1},_listens:function(d,y,E){if(!this._events)return!1;var $=this._events[d]||[];if(!y)return!!$.length;E===this&&(E=void 0);for(var Z=0,oe=$.length;Z<oe;Z++)if($[Z].fn===y&&$[Z].ctx===E)return Z;return!1},once:function(d,y,E){if(typeof d=="object")for(var $ in d)this._on($,d[$],y,!0);else{d=x(d);for(var Z=0,oe=d.length;Z<oe;Z++)this._on(d[Z],y,E,!0)}return this},addEventParent:function(d){return this._eventParents=this._eventParents||{},this._eventParents[f(d)]=d,this},removeEventParent:function(d){return this._eventParents&&delete this._eventParents[f(d)],this},_propagateEvent:function(d){for(var y in this._eventParents)this._eventParents[y].fire(d.type,i({layer:d.target,propagatedFrom:d.target},d),!0)}};H.addEventListener=H.on,H.removeEventListener=H.clearAllEventListeners=H.off,H.addOneTimeEventListener=H.once,H.fireEvent=H.fire,H.hasEventListeners=H.listens;var I=X.extend(H);function D(d,y,E){this.x=E?Math.round(d):d,this.y=E?Math.round(y):y}var z=Math.trunc||function(d){return d>0?Math.floor(d):Math.ceil(d)};D.prototype={clone:function(){return new D(this.x,this.y)},add:function(d){return this.clone()._add(N(d))},_add:function(d){return this.x+=d.x,this.y+=d.y,this},subtract:function(d){return this.clone()._subtract(N(d))},_subtract:function(d){return this.x-=d.x,this.y-=d.y,this},divideBy:function(d){return this.clone()._divideBy(d)},_divideBy:function(d){return this.x/=d,this.y/=d,this},multiplyBy:function(d){return this.clone()._multiplyBy(d)},_multiplyBy:function(d){return this.x*=d,this.y*=d,this},scaleBy:function(d){return new D(this.x*d.x,this.y*d.y)},unscaleBy:function(d){return new D(this.x/d.x,this.y/d.y)},round:function(){return this.clone()._round()},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},floor:function(){return this.clone()._floor()},_floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.clone()._ceil()},_ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},trunc:function(){return this.clone()._trunc()},_trunc:function(){return this.x=z(this.x),this.y=z(this.y),this},distanceTo:function(d){d=N(d);var y=d.x-this.x,E=d.y-this.y;return Math.sqrt(y*y+E*E)},equals:function(d){return d=N(d),d.x===this.x&&d.y===this.y},contains:function(d){return d=N(d),Math.abs(d.x)<=Math.abs(this.x)&&Math.abs(d.y)<=Math.abs(this.y)},toString:function(){return"Point("+g(this.x)+", "+g(this.y)+")"}};function N(d,y,E){return d instanceof D?d:O(d)?new D(d[0],d[1]):d==null?d:typeof d=="object"&&"x"in d&&"y"in d?new D(d.x,d.y):new D(d,y,E)}function B(d,y){if(d)for(var E=y?[d,y]:d,$=0,Z=E.length;$<Z;$++)this.extend(E[$])}B.prototype={extend:function(d){var y,E;if(!d)return this;if(d instanceof D||typeof d[0]=="number"||"x"in d)y=E=N(d);else if(d=Q(d),y=d.min,E=d.max,!y||!E)return this;return!this.min&&!this.max?(this.min=y.clone(),this.max=E.clone()):(this.min.x=Math.min(y.x,this.min.x),this.max.x=Math.max(E.x,this.max.x),this.min.y=Math.min(y.y,this.min.y),this.max.y=Math.max(E.y,this.max.y)),this},getCenter:function(d){return N((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,d)},getBottomLeft:function(){return N(this.min.x,this.max.y)},getTopRight:function(){return N(this.max.x,this.min.y)},getTopLeft:function(){return this.min},getBottomRight:function(){return this.max},getSize:function(){return this.max.subtract(this.min)},contains:function(d){var y,E;return typeof d[0]=="number"||d instanceof D?d=N(d):d=Q(d),d instanceof B?(y=d.min,E=d.max):y=E=d,y.x>=this.min.x&&E.x<=this.max.x&&y.y>=this.min.y&&E.y<=this.max.y},intersects:function(d){d=Q(d);var y=this.min,E=this.max,$=d.min,Z=d.max,oe=Z.x>=y.x&&$.x<=E.x,me=Z.y>=y.y&&$.y<=E.y;return oe&&me},overlaps:function(d){d=Q(d);var y=this.min,E=this.max,$=d.min,Z=d.max,oe=Z.x>y.x&&$.x<E.x,me=Z.y>y.y&&$.y<E.y;return oe&&me},isValid:function(){return!!(this.min&&this.max)},pad:function(d){var y=this.min,E=this.max,$=Math.abs(y.x-E.x)*d,Z=Math.abs(y.y-E.y)*d;return Q(N(y.x-$,y.y-Z),N(E.x+$,E.y+Z))},equals:function(d){return d?(d=Q(d),this.min.equals(d.getTopLeft())&&this.max.equals(d.getBottomRight())):!1}};function Q(d,y){return!d||d instanceof B?d:new B(d,y)}function G(d,y){if(d)for(var E=y?[d,y]:d,$=0,Z=E.length;$<Z;$++)this.extend(E[$])}G.prototype={extend:function(d){var y=this._southWest,E=this._northEast,$,Z;if(d instanceof fe)$=d,Z=d;else if(d instanceof G){if($=d._southWest,Z=d._northEast,!$||!Z)return this}else return d?this.extend(ce(d)||ae(d)):this;return!y&&!E?(this._southWest=new fe($.lat,$.lng),this._northEast=new fe(Z.lat,Z.lng)):(y.lat=Math.min($.lat,y.lat),y.lng=Math.min($.lng,y.lng),E.lat=Math.max(Z.lat,E.lat),E.lng=Math.max(Z.lng,E.lng)),this},pad:function(d){var y=this._southWest,E=this._northEast,$=Math.abs(y.lat-E.lat)*d,Z=Math.abs(y.lng-E.lng)*d;return new G(new fe(y.lat-$,y.lng-Z),new fe(E.lat+$,E.lng+Z))},getCenter:function(){return new fe((this._southWest.lat+this._northEast.lat)/2,(this._southWest.lng+this._northEast.lng)/2)},getSouthWest:function(){return this._southWest},getNorthEast:function(){return this._northEast},getNorthWest:function(){return new fe(this.getNorth(),this.getWest())},getSouthEast:function(){return new fe(this.getSouth(),this.getEast())},getWest:function(){return this._southWest.lng},getSouth:function(){return this._southWest.lat},getEast:function(){return this._northEast.lng},getNorth:function(){return this._northEast.lat},contains:function(d){typeof d[0]=="number"||d instanceof fe||"lat"in d?d=ce(d):d=ae(d);var y=this._southWest,E=this._northEast,$,Z;return d instanceof G?($=d.getSouthWest(),Z=d.getNorthEast()):$=Z=d,$.lat>=y.lat&&Z.lat<=E.lat&&$.lng>=y.lng&&Z.lng<=E.lng},intersects:function(d){d=ae(d);var y=this._southWest,E=this._northEast,$=d.getSouthWest(),Z=d.getNorthEast(),oe=Z.lat>=y.lat&&$.lat<=E.lat,me=Z.lng>=y.lng&&$.lng<=E.lng;return oe&&me},overlaps:function(d){d=ae(d);var y=this._southWest,E=this._northEast,$=d.getSouthWest(),Z=d.getNorthEast(),oe=Z.lat>y.lat&&$.lat<E.lat,me=Z.lng>y.lng&&$.lng<E.lng;return oe&&me},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(d,y){return d?(d=ae(d),this._southWest.equals(d.getSouthWest(),y)&&this._northEast.equals(d.getNorthEast(),y)):!1},isValid:function(){return!!(this._southWest&&this._northEast)}};function ae(d,y){return d instanceof G?d:new G(d,y)}function fe(d,y,E){if(isNaN(d)||isNaN(y))throw new Error("Invalid LatLng object: ("+d+", "+y+")");this.lat=+d,this.lng=+y,E!==void 0&&(this.alt=+E)}fe.prototype={equals:function(d,y){if(!d)return!1;d=ce(d);var E=Math.max(Math.abs(this.lat-d.lat),Math.abs(this.lng-d.lng));return E<=(y===void 0?1e-9:y)},toString:function(d){return"LatLng("+g(this.lat,d)+", "+g(this.lng,d)+")"},distanceTo:function(d){return F.distance(this,ce(d))},wrap:function(){return F.wrapLatLng(this)},toBounds:function(d){var y=180*d/40075017,E=y/Math.cos(Math.PI/180*this.lat);return ae([this.lat-y,this.lng-E],[this.lat+y,this.lng+E])},clone:function(){return new fe(this.lat,this.lng,this.alt)}};function ce(d,y,E){return d instanceof fe?d:O(d)&&typeof d[0]!="object"?d.length===3?new fe(d[0],d[1],d[2]):d.length===2?new fe(d[0],d[1]):null:d==null?d:typeof d=="object"&&"lat"in d?new fe(d.lat,"lng"in d?d.lng:d.lon,d.alt):y===void 0?null:new fe(d,y,E)}var ye={latLngToPoint:function(d,y){var E=this.projection.project(d),$=this.scale(y);return this.transformation._transform(E,$)},pointToLatLng:function(d,y){var E=this.scale(y),$=this.transformation.untransform(d,E);return this.projection.unproject($)},project:function(d){return this.projection.project(d)},unproject:function(d){return this.projection.unproject(d)},scale:function(d){return 256*Math.pow(2,d)},zoom:function(d){return Math.log(d/256)/Math.LN2},getProjectedBounds:function(d){if(this.infinite)return null;var y=this.projection.bounds,E=this.scale(d),$=this.transformation.transform(y.min,E),Z=this.transformation.transform(y.max,E);return new B($,Z)},infinite:!1,wrapLatLng:function(d){var y=this.wrapLng?h(d.lng,this.wrapLng,!0):d.lng,E=this.wrapLat?h(d.lat,this.wrapLat,!0):d.lat,$=d.alt;return new fe(E,y,$)},wrapLatLngBounds:function(d){var y=d.getCenter(),E=this.wrapLatLng(y),$=y.lat-E.lat,Z=y.lng-E.lng;if($===0&&Z===0)return d;var oe=d.getSouthWest(),me=d.getNorthEast(),Ae=new fe(oe.lat-$,oe.lng-Z),Me=new fe(me.lat-$,me.lng-Z);return new G(Ae,Me)}},F=i({},ye,{wrapLng:[-180,180],R:6371e3,distance:function(d,y){var E=Math.PI/180,$=d.lat*E,Z=y.lat*E,oe=Math.sin((y.lat-d.lat)*E/2),me=Math.sin((y.lng-d.lng)*E/2),Ae=oe*oe+Math.cos($)*Math.cos(Z)*me*me,Me=2*Math.atan2(Math.sqrt(Ae),Math.sqrt(1-Ae));return this.R*Me}}),q=6378137,te={R:q,MAX_LATITUDE:85.0511287798,project:function(d){var y=Math.PI/180,E=this.MAX_LATITUDE,$=Math.max(Math.min(E,d.lat),-E),Z=Math.sin($*y);return new D(this.R*d.lng*y,this.R*Math.log((1+Z)/(1-Z))/2)},unproject:function(d){var y=180/Math.PI;return new fe((2*Math.atan(Math.exp(d.y/this.R))-Math.PI/2)*y,d.x*y/this.R)},bounds:function(){var d=q*Math.PI;return new B([-d,-d],[d,d])}()};function ue(d,y,E,$){if(O(d)){this._a=d[0],this._b=d[1],this._c=d[2],this._d=d[3];return}this._a=d,this._b=y,this._c=E,this._d=$}ue.prototype={transform:function(d,y){return this._transform(d.clone(),y)},_transform:function(d,y){return y=y||1,d.x=y*(this._a*d.x+this._b),d.y=y*(this._c*d.y+this._d),d},untransform:function(d,y){return y=y||1,new D((d.x/y-this._b)/this._a,(d.y/y-this._d)/this._c)}};function J(d,y,E,$){return new ue(d,y,E,$)}var se=i({},F,{code:"EPSG:3857",projection:te,transformation:function(){var d=.5/(Math.PI*te.R);return J(d,.5,-d,.5)}()}),de=i({},se,{code:"EPSG:900913"});function ve(d){return document.createElementNS("http://www.w3.org/2000/svg",d)}function he(d,y){var E="",$,Z,oe,me,Ae,Me;for($=0,oe=d.length;$<oe;$++){for(Ae=d[$],Z=0,me=Ae.length;Z<me;Z++)Me=Ae[Z],E+=(Z?"L":"M")+Me.x+" "+Me.y;E+=y?lt.svg?"z":"x":""}return E||"M0 0"}var xe=document.documentElement.style,Oe="ActiveXObject"in window,Le=Oe&&!document.addEventListener,He="msLaunchUri"in navigator&&!("documentMode"in document),$e=Mn("webkit"),ze=Mn("android"),_e=Mn("android 2")||Mn("android 3"),Se=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),ke=ze&&Mn("Google")&&Se<537&&!("AudioNode"in window),Ne=!!window.opera,je=!He&&Mn("chrome"),Fe=Mn("gecko")&&!$e&&!Ne&&!Oe,Ge=!je&&Mn("safari"),Xe=Mn("phantom"),ft="OTransition"in xe,st=navigator.platform.indexOf("Win")===0,wt=Oe&&"transition"in xe,kt="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!_e,Dt="MozPerspective"in xe,It=!window.L_DISABLE_3D&&(wt||kt||Dt)&&!ft&&!Xe,Cr=typeof orientation<"u"||Mn("mobile"),Vn=Cr&&$e,ys=Cr&&kt,ii=!window.PointerEvent&&window.MSPointerEvent,bs=!!(window.PointerEvent||ii),La="ontouchstart"in window||!!window.TouchEvent,bc=!window.L_NO_TOUCH&&(La||bs),ws=Cr&&Ne,ka=Cr&&Fe,mn=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,fn=function(){var d=!1;try{var y=Object.defineProperty({},"passive",{get:function(){d=!0}});window.addEventListener("testPassiveEventSupport",m,y),window.removeEventListener("testPassiveEventSupport",m,y)}catch{}return d}(),Jn=function(){return!!document.createElement("canvas").getContext}(),Hn=!!(document.createElementNS&&ve("svg").createSVGRect),en=!!Hn&&function(){var d=document.createElement("div");return d.innerHTML="<svg/>",(d.firstChild&&d.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"}(),Mt=!Hn&&function(){try{var d=document.createElement("div");d.innerHTML='<v:shape adj="1"/>';var y=d.firstChild;return y.style.behavior="url(#default#VML)",y&&typeof y.adj=="object"}catch{return!1}}(),tn=navigator.platform.indexOf("Mac")===0,er=navigator.platform.indexOf("Linux")===0;function Mn(d){return navigator.userAgent.toLowerCase().indexOf(d)>=0}var lt={ie:Oe,ielt9:Le,edge:He,webkit:$e,android:ze,android23:_e,androidStock:ke,opera:Ne,chrome:je,gecko:Fe,safari:Ge,phantom:Xe,opera12:ft,win:st,ie3d:wt,webkit3d:kt,gecko3d:Dt,any3d:It,mobile:Cr,mobileWebkit:Vn,mobileWebkit3d:ys,msPointer:ii,pointer:bs,touch:bc,touchNative:La,mobileOpera:ws,mobileGecko:ka,retina:mn,passiveEvents:fn,canvas:Jn,svg:Hn,vml:Mt,inlineSvg:en,mac:tn,linux:er},Sg=lt.msPointer?"MSPointerDown":"pointerdown",Qd=lt.msPointer?"MSPointerMove":"pointermove",_s=lt.msPointer?"MSPointerUp":"pointerup",wc=lt.msPointer?"MSPointerCancel":"pointercancel",Da={touchstart:Sg,touchmove:Qd,touchend:_s,touchcancel:wc},yo={touchstart:Eg,touchmove:Jl,touchend:Jl,touchcancel:Jl},Ii={},bo=!1;function In(d,y,E){return y==="touchstart"&&V1(),yo[y]?(E=yo[y].bind(this,E),d.addEventListener(Da[y],E,!1),E):(console.warn("wrong event specified:",y),m)}function Cg(d,y,E){if(!Da[y]){console.warn("wrong event specified:",y);return}d.removeEventListener(Da[y],E,!1)}function Ag(d){Ii[d.pointerId]=d}function wo(d){Ii[d.pointerId]&&(Ii[d.pointerId]=d)}function _o(d){delete Ii[d.pointerId]}function V1(){bo||(document.addEventListener(Sg,Ag,!0),document.addEventListener(Qd,wo,!0),document.addEventListener(_s,_o,!0),document.addEventListener(wc,_o,!0),bo=!0)}function Jl(d,y){if(y.pointerType!==(y.MSPOINTER_TYPE_MOUSE||"mouse")){y.touches=[];for(var E in Ii)y.touches.push(Ii[E]);y.changedTouches=[y],d(y)}}function Eg(d,y){y.MSPOINTER_TYPE_TOUCH&&y.pointerType===y.MSPOINTER_TYPE_TOUCH&&An(y),Jl(d,y)}function H1(d){var y={},E,$;for($ in d)E=d[$],y[$]=E&&E.bind?E.bind(d):E;return d=y,y.type="dblclick",y.detail=2,y.isTrusted=!1,y._simulated=!0,y}var _c=200;function xc(d,y){d.addEventListener("dblclick",y);var E=0,$;function Z(oe){if(oe.detail!==1){$=oe.detail;return}if(!(oe.pointerType==="mouse"||oe.sourceCapabilities&&!oe.sourceCapabilities.firesTouchEvents)){var me=th(oe);if(!(me.some(function(Me){return Me instanceof HTMLLabelElement&&Me.attributes.for})&&!me.some(function(Me){return Me instanceof HTMLInputElement||Me instanceof HTMLSelectElement}))){var Ae=Date.now();Ae-E<=_c?($++,$===2&&y(H1(oe))):$=1,E=Ae}}}return d.addEventListener("click",Z),{dblclick:y,simDblclick:Z}}function aa(d,y){d.removeEventListener("dblclick",y.dblclick),d.removeEventListener("click",y.simDblclick)}var eu=As(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),xs=As(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),xo=xs==="webkitTransition"||xs==="OTransition"?xs+"End":"transitionend";function Sc(d){return typeof d=="string"?document.getElementById(d):d}function So(d,y){var E=d.style[y]||d.currentStyle&&d.currentStyle[y];if((!E||E==="auto")&&document.defaultView){var $=document.defaultView.getComputedStyle(d,null);E=$?$[y]:null}return E==="auto"?null:E}function Nt(d,y,E){var $=document.createElement(d);return $.className=y||"",E&&E.appendChild($),$}function nn(d){var y=d.parentNode;y&&y.removeChild(d)}function fr(d){for(;d.firstChild;)d.removeChild(d.firstChild)}function Co(d){var y=d.parentNode;y&&y.lastChild!==d&&y.appendChild(d)}function Ss(d){var y=d.parentNode;y&&y.firstChild!==d&&y.insertBefore(d,y.firstChild)}function Cs(d,y){if(d.classList!==void 0)return d.classList.contains(y);var E=dr(d);return E.length>0&&new RegExp("(^|\\s)"+y+"(\\s|$)").test(E)}function _t(d,y){if(d.classList!==void 0)for(var E=x(y),$=0,Z=E.length;$<Z;$++)d.classList.add(E[$]);else if(!Cs(d,y)){var oe=dr(d);Jd(d,(oe?oe+" ":"")+y)}}function rn(d,y){d.classList!==void 0?d.classList.remove(y):Jd(d,_((" "+dr(d)+" ").replace(" "+y+" "," ")))}function Jd(d,y){d.className.baseVal===void 0?d.className=y:d.className.baseVal=y}function dr(d){return d.correspondingElement&&(d=d.correspondingElement),d.className.baseVal===void 0?d.className:d.className.baseVal}function Ar(d,y){"opacity"in d.style?d.style.opacity=y:"filter"in d.style&&Og(d,y)}function Og(d,y){var E=!1,$="DXImageTransform.Microsoft.Alpha";try{E=d.filters.item($)}catch{if(y===1)return}y=Math.round(y*100),E?(E.Enabled=y!==100,E.Opacity=y):d.style.filter+=" progid:"+$+"(opacity="+y+")"}function As(d){for(var y=document.documentElement.style,E=0;E<d.length;E++)if(d[E]in y)return d[E];return!1}function Zr(d,y,E){var $=y||new D(0,0);d.style[eu]=(lt.ie3d?"translate("+$.x+"px,"+$.y+"px)":"translate3d("+$.x+"px,"+$.y+"px,0)")+(E?" scale("+E+")":"")}function _n(d,y){d._leaflet_pos=y,lt.any3d?Zr(d,y):(d.style.left=y.x+"px",d.style.top=y.y+"px")}function Ia(d){return d._leaflet_pos||new D(0,0)}var $i,tu,Cc;if("onselectstart"in document)$i=function(){bt(window,"selectstart",An)},tu=function(){$t(window,"selectstart",An)};else{var Es=As(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);$i=function(){if(Es){var d=document.documentElement.style;Cc=d[Es],d[Es]="none"}},tu=function(){Es&&(document.documentElement.style[Es]=Cc,Cc=void 0)}}function nu(){bt(window,"dragstart",An)}function eh(){$t(window,"dragstart",An)}var Ac,Os;function ru(d){for(;d.tabIndex===-1;)d=d.parentNode;d.style&&(Ts(),Ac=d,Os=d.style.outlineStyle,d.style.outlineStyle="none",bt(window,"keydown",Ts))}function Ts(){Ac&&(Ac.style.outlineStyle=Os,Ac=void 0,Os=void 0,$t(window,"keydown",Ts))}function Ao(d){do d=d.parentNode;while((!d.offsetWidth||!d.offsetHeight)&&d!==document.body);return d}function $a(d){var y=d.getBoundingClientRect();return{x:y.width/d.offsetWidth||1,y:y.height/d.offsetHeight||1,boundingClientRect:y}}var Tg={__proto__:null,TRANSFORM:eu,TRANSITION:xs,TRANSITION_END:xo,get:Sc,getStyle:So,create:Nt,remove:nn,empty:fr,toFront:Co,toBack:Ss,hasClass:Cs,addClass:_t,removeClass:rn,setClass:Jd,getClass:dr,setOpacity:Ar,testProp:As,setTransform:Zr,setPosition:_n,getPosition:Ia,get disableTextSelection(){return $i},get enableTextSelection(){return tu},disableImageDrag:nu,enableImageDrag:eh,preventOutline:ru,restoreOutline:Ts,getSizedParentNode:Ao,getScale:$a};function bt(d,y,E,$){if(y&&typeof y=="object")for(var Z in y)Eo(d,Z,y[Z],E);else{y=x(y);for(var oe=0,me=y.length;oe<me;oe++)Eo(d,y[oe],E,$)}return this}var ai="_leaflet_events";function $t(d,y,E,$){if(arguments.length===1)Bi(d),delete d[ai];else if(y&&typeof y=="object")for(var Z in y)Ui(d,Z,y[Z],E);else if(y=x(y),arguments.length===2)Bi(d,function(Ae){return P(y,Ae)!==-1});else for(var oe=0,me=y.length;oe<me;oe++)Ui(d,y[oe],E,$);return this}function Bi(d,y){for(var E in d[ai]){var $=E.split(/\d/)[0];(!y||y($))&&Ui(d,$,null,null,E)}}var iu={mouseenter:"mouseover",mouseleave:"mouseout",wheel:!("onwheel"in window)&&"mousewheel"};function Eo(d,y,E,$){var Z=y+f(E)+($?"_"+f($):"");if(d[ai]&&d[ai][Z])return this;var oe=function(Ae){return E.call($||d,Ae||window.event)},me=oe;!lt.touchNative&<.pointer&&y.indexOf("touch")===0?oe=In(d,y,oe):lt.touch&&y==="dblclick"?oe=xc(d,oe):"addEventListener"in d?y==="touchstart"||y==="touchmove"||y==="wheel"||y==="mousewheel"?d.addEventListener(iu[y]||y,oe,lt.passiveEvents?{passive:!1}:!1):y==="mouseenter"||y==="mouseleave"?(oe=function(Ae){Ae=Ae||window.event,To(d,Ae)&&me(Ae)},d.addEventListener(iu[y],oe,!1)):d.addEventListener(y,me,!1):d.attachEvent("on"+y,oe),d[ai]=d[ai]||{},d[ai][Z]=oe}function Ui(d,y,E,$,Z){Z=Z||y+f(E)+($?"_"+f($):"");var oe=d[ai]&&d[ai][Z];if(!oe)return this;!lt.touchNative&<.pointer&&y.indexOf("touch")===0?Cg(d,y,oe):lt.touch&&y==="dblclick"?aa(d,oe):"removeEventListener"in d?d.removeEventListener(iu[y]||y,oe,!1):d.detachEvent("on"+y,oe),d[ai][Z]=null}function oa(d){return d.stopPropagation?d.stopPropagation():d.originalEvent?d.originalEvent._stopped=!0:d.cancelBubble=!0,this}function js(d){return Eo(d,"wheel",oa),this}function Ps(d){return bt(d,"mousedown touchstart dblclick contextmenu",oa),d._leaflet_disable_click=!0,this}function An(d){return d.preventDefault?d.preventDefault():d.returnValue=!1,this}function zi(d){return An(d),oa(d),this}function th(d){if(d.composedPath)return d.composedPath();for(var y=[],E=d.target;E;)y.push(E),E=E.parentNode;return y}function hr(d,y){if(!y)return new D(d.clientX,d.clientY);var E=$a(y),$=E.boundingClientRect;return new D((d.clientX-$.left)/E.x-y.clientLeft,(d.clientY-$.top)/E.y-y.clientTop)}var Oo=lt.linux&<.chrome?window.devicePixelRatio:lt.mac?window.devicePixelRatio*3:window.devicePixelRatio>0?2*window.devicePixelRatio:1;function au(d){return lt.edge?d.wheelDeltaY/2:d.deltaY&&d.deltaMode===0?-d.deltaY/Oo:d.deltaY&&d.deltaMode===1?-d.deltaY*20:d.deltaY&&d.deltaMode===2?-d.deltaY*60:d.deltaX||d.deltaZ?0:d.wheelDelta?(d.wheelDeltaY||d.wheelDelta)/2:d.detail&&Math.abs(d.detail)<32765?-d.detail*20:d.detail?d.detail/-32765*60:0}function To(d,y){var E=y.relatedTarget;if(!E)return!0;try{for(;E&&E!==d;)E=E.parentNode}catch{return!1}return E!==d}var G1={__proto__:null,on:bt,off:$t,stopPropagation:oa,disableScrollPropagation:js,disableClickPropagation:Ps,preventDefault:An,stop:zi,getPropagationPath:th,getMousePosition:hr,getWheelDelta:au,isExternalTarget:To,addListener:bt,removeListener:$t},Ec=I.extend({run:function(d,y,E,$){this.stop(),this._el=d,this._inProgress=!0,this._duration=E||.25,this._easeOutPower=1/Math.max($||.5,.2),this._startPos=Ia(d),this._offset=y.subtract(this._startPos),this._startTime=+new Date,this.fire("start"),this._animate()},stop:function(){this._inProgress&&(this._step(!0),this._complete())},_animate:function(){this._animId=W(this._animate,this),this._step()},_step:function(d){var y=+new Date-this._startTime,E=this._duration*1e3;y<E?this._runFrame(this._easeOut(y/E),d):(this._runFrame(1),this._complete())},_runFrame:function(d,y){var E=this._startPos.add(this._offset.multiplyBy(d));y&&E._round(),_n(this._el,E),this.fire("step")},_complete:function(){ee(this._animId),this._inProgress=!1,this.fire("end")},_easeOut:function(d){return 1-Math.pow(1-d,this._easeOutPower)}}),Et=I.extend({options:{crs:se,center:void 0,zoom:void 0,minZoom:void 0,maxZoom:void 0,layers:[],maxBounds:void 0,renderer:void 0,zoomAnimation:!0,zoomAnimationThreshold:4,fadeAnimation:!0,markerZoomAnimation:!0,transform3DLimit:8388608,zoomSnap:1,zoomDelta:1,trackResize:!0},initialize:function(d,y){y=b(this,y),this._handlers=[],this._layers={},this._zoomBoundLayers={},this._sizeChanged=!0,this._initContainer(d),this._initLayout(),this._onResize=o(this._onResize,this),this._initEvents(),y.maxBounds&&this.setMaxBounds(y.maxBounds),y.zoom!==void 0&&(this._zoom=this._limitZoom(y.zoom)),y.center&&y.zoom!==void 0&&this.setView(ce(y.center),y.zoom,{reset:!0}),this.callInitHooks(),this._zoomAnimated=xs&<.any3d&&!lt.mobileOpera&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),bt(this._proxy,xo,this._catchTransitionEnd,this)),this._addLayers(this.options.layers)},setView:function(d,y,E){if(y=y===void 0?this._zoom:this._limitZoom(y),d=this._limitCenter(ce(d),y,this.options.maxBounds),E=E||{},this._stop(),this._loaded&&!E.reset&&E!==!0){E.animate!==void 0&&(E.zoom=i({animate:E.animate},E.zoom),E.pan=i({animate:E.animate,duration:E.duration},E.pan));var $=this._zoom!==y?this._tryAnimatedZoom&&this._tryAnimatedZoom(d,y,E.zoom):this._tryAnimatedPan(d,E.pan);if($)return clearTimeout(this._sizeTimer),this}return this._resetView(d,y,E.pan&&E.pan.noMoveStart),this},setZoom:function(d,y){return this._loaded?this.setView(this.getCenter(),d,{zoom:y}):(this._zoom=d,this)},zoomIn:function(d,y){return d=d||(lt.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom+d,y)},zoomOut:function(d,y){return d=d||(lt.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom-d,y)},setZoomAround:function(d,y,E){var $=this.getZoomScale(y),Z=this.getSize().divideBy(2),oe=d instanceof D?d:this.latLngToContainerPoint(d),me=oe.subtract(Z).multiplyBy(1-1/$),Ae=this.containerPointToLatLng(Z.add(me));return this.setView(Ae,y,{zoom:E})},_getBoundsCenterZoom:function(d,y){y=y||{},d=d.getBounds?d.getBounds():ae(d);var E=N(y.paddingTopLeft||y.padding||[0,0]),$=N(y.paddingBottomRight||y.padding||[0,0]),Z=this.getBoundsZoom(d,!1,E.add($));if(Z=typeof y.maxZoom=="number"?Math.min(y.maxZoom,Z):Z,Z===1/0)return{center:d.getCenter(),zoom:Z};var oe=$.subtract(E).divideBy(2),me=this.project(d.getSouthWest(),Z),Ae=this.project(d.getNorthEast(),Z),Me=this.unproject(me.add(Ae).divideBy(2).add(oe),Z);return{center:Me,zoom:Z}},fitBounds:function(d,y){if(d=ae(d),!d.isValid())throw new Error("Bounds are not valid.");var E=this._getBoundsCenterZoom(d,y);return this.setView(E.center,E.zoom,y)},fitWorld:function(d){return this.fitBounds([[-90,-180],[90,180]],d)},panTo:function(d,y){return this.setView(d,this._zoom,{pan:y})},panBy:function(d,y){if(d=N(d).round(),y=y||{},!d.x&&!d.y)return this.fire("moveend");if(y.animate!==!0&&!this.getSize().contains(d))return this._resetView(this.unproject(this.project(this.getCenter()).add(d)),this.getZoom()),this;if(this._panAnim||(this._panAnim=new Ec,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),y.noMoveStart||this.fire("movestart"),y.animate!==!1){_t(this._mapPane,"leaflet-pan-anim");var E=this._getMapPanePos().subtract(d).round();this._panAnim.run(this._mapPane,E,y.duration||.25,y.easeLinearity)}else this._rawPanBy(d),this.fire("move").fire("moveend");return this},flyTo:function(d,y,E){if(E=E||{},E.animate===!1||!lt.any3d)return this.setView(d,y,E);this._stop();var $=this.project(this.getCenter()),Z=this.project(d),oe=this.getSize(),me=this._zoom;d=ce(d),y=y===void 0?me:y;var Ae=Math.max(oe.x,oe.y),Me=Ae*this.getZoomScale(me,y),qe=Z.distanceTo($)||1,Qe=1.42,rt=Qe*Qe;function at(gn){var Vi=gn?-1:1,ua=gn?Me:Ae,qa=Me*Me-Ae*Ae+Vi*rt*rt*qe*qe,ca=2*ua*rt*qe,yu=qa/ca,Bc=Math.sqrt(yu*yu+1)-yu,bu=Bc<1e-9?-18:Math.log(Bc);return bu}function yt(gn){return(Math.exp(gn)-Math.exp(-gn))/2}function an(gn){return(Math.exp(gn)+Math.exp(-gn))/2}function xn(gn){return yt(gn)/an(gn)}var nr=at(0);function Xr(gn){return Ae*(an(nr)/an(nr+Qe*gn))}function Wg(gn){return Ae*(an(nr)*xn(nr+Qe*gn)-yt(nr))/rt}function Yg(gn){return 1-Math.pow(1-gn,1.5)}var vu=Date.now(),Fs=(at(1)-nr)/Qe,Kg=E.duration?1e3*E.duration:1e3*Fs*.8;function qs(){var gn=(Date.now()-vu)/Kg,Vi=Yg(gn)*Fs;gn<=1?(this._flyToFrame=W(qs,this),this._move(this.unproject($.add(Z.subtract($).multiplyBy(Wg(Vi)/qe)),me),this.getScaleZoom(Ae/Xr(Vi),me),{flyTo:!0})):this._move(d,y)._moveEnd(!0)}return this._moveStart(!0,E.noMoveStart),qs.call(this),this},flyToBounds:function(d,y){var E=this._getBoundsCenterZoom(d,y);return this.flyTo(E.center,E.zoom,y)},setMaxBounds:function(d){return d=ae(d),this.listens("moveend",this._panInsideMaxBounds)&&this.off("moveend",this._panInsideMaxBounds),d.isValid()?(this.options.maxBounds=d,this._loaded&&this._panInsideMaxBounds(),this.on("moveend",this._panInsideMaxBounds)):(this.options.maxBounds=null,this)},setMinZoom:function(d){var y=this.options.minZoom;return this.options.minZoom=d,this._loaded&&y!==d&&(this.fire("zoomlevelschange"),this.getZoom()<this.options.minZoom)?this.setZoom(d):this},setMaxZoom:function(d){var y=this.options.maxZoom;return this.options.maxZoom=d,this._loaded&&y!==d&&(this.fire("zoomlevelschange"),this.getZoom()>this.options.maxZoom)?this.setZoom(d):this},panInsideBounds:function(d,y){this._enforcingBounds=!0;var E=this.getCenter(),$=this._limitCenter(E,this._zoom,ae(d));return E.equals($)||this.panTo($,y),this._enforcingBounds=!1,this},panInside:function(d,y){y=y||{};var E=N(y.paddingTopLeft||y.padding||[0,0]),$=N(y.paddingBottomRight||y.padding||[0,0]),Z=this.project(this.getCenter()),oe=this.project(d),me=this.getPixelBounds(),Ae=Q([me.min.add(E),me.max.subtract($)]),Me=Ae.getSize();if(!Ae.contains(oe)){this._enforcingBounds=!0;var qe=oe.subtract(Ae.getCenter()),Qe=Ae.extend(oe).getSize().subtract(Me);Z.x+=qe.x<0?-Qe.x:Qe.x,Z.y+=qe.y<0?-Qe.y:Qe.y,this.panTo(this.unproject(Z),y),this._enforcingBounds=!1}return this},invalidateSize:function(d){if(!this._loaded)return this;d=i({animate:!1,pan:!0},d===!0?{animate:!0}:d);var y=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var E=this.getSize(),$=y.divideBy(2).round(),Z=E.divideBy(2).round(),oe=$.subtract(Z);return!oe.x&&!oe.y?this:(d.animate&&d.pan?this.panBy(oe):(d.pan&&this._rawPanBy(oe),this.fire("move"),d.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(o(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:y,newSize:E}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(d){if(d=this._locateOptions=i({timeout:1e4,watch:!1},d),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var y=o(this._handleGeolocationResponse,this),E=o(this._handleGeolocationError,this);return d.watch?this._locationWatchId=navigator.geolocation.watchPosition(y,E,d):navigator.geolocation.getCurrentPosition(y,E,d),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(d){if(this._container._leaflet_id){var y=d.code,E=d.message||(y===1?"permission denied":y===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:y,message:"Geolocation error: "+E+"."})}},_handleGeolocationResponse:function(d){if(this._container._leaflet_id){var y=d.coords.latitude,E=d.coords.longitude,$=new fe(y,E),Z=$.toBounds(d.coords.accuracy*2),oe=this._locateOptions;if(oe.setView){var me=this.getBoundsZoom(Z);this.setView($,oe.maxZoom?Math.min(me,oe.maxZoom):me)}var Ae={latlng:$,bounds:Z,timestamp:d.timestamp};for(var Me in d.coords)typeof d.coords[Me]=="number"&&(Ae[Me]=d.coords[Me]);this.fire("locationfound",Ae)}},addHandler:function(d,y){if(!y)return this;var E=this[d]=new y(this);return this._handlers.push(E),this.options[d]&&E.enable(),this},remove:function(){if(this._initEvents(!0),this.options.maxBounds&&this.off("moveend",this._panInsideMaxBounds),this._containerId!==this._container._leaflet_id)throw new Error("Map container is being reused by another instance");try{delete this._container._leaflet_id,delete this._containerId}catch{this._container._leaflet_id=void 0,this._containerId=void 0}this._locationWatchId!==void 0&&this.stopLocate(),this._stop(),nn(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(ee(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var d;for(d in this._layers)this._layers[d].remove();for(d in this._panes)nn(this._panes[d]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(d,y){var E="leaflet-pane"+(d?" leaflet-"+d.replace("Pane","")+"-pane":""),$=Nt("div",E,y||this._mapPane);return d&&(this._panes[d]=$),$},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var d=this.getPixelBounds(),y=this.unproject(d.getBottomLeft()),E=this.unproject(d.getTopRight());return new G(y,E)},getMinZoom:function(){return this.options.minZoom===void 0?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return this.options.maxZoom===void 0?this._layersMaxZoom===void 0?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(d,y,E){d=ae(d),E=N(E||[0,0]);var $=this.getZoom()||0,Z=this.getMinZoom(),oe=this.getMaxZoom(),me=d.getNorthWest(),Ae=d.getSouthEast(),Me=this.getSize().subtract(E),qe=Q(this.project(Ae,$),this.project(me,$)).getSize(),Qe=lt.any3d?this.options.zoomSnap:1,rt=Me.x/qe.x,at=Me.y/qe.y,yt=y?Math.max(rt,at):Math.min(rt,at);return $=this.getScaleZoom(yt,$),Qe&&($=Math.round($/(Qe/100))*(Qe/100),$=y?Math.ceil($/Qe)*Qe:Math.floor($/Qe)*Qe),Math.max(Z,Math.min(oe,$))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new D(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(d,y){var E=this._getTopLeftPoint(d,y);return new B(E,E.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(d){return this.options.crs.getProjectedBounds(d===void 0?this.getZoom():d)},getPane:function(d){return typeof d=="string"?this._panes[d]:d},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(d,y){var E=this.options.crs;return y=y===void 0?this._zoom:y,E.scale(d)/E.scale(y)},getScaleZoom:function(d,y){var E=this.options.crs;y=y===void 0?this._zoom:y;var $=E.zoom(d*E.scale(y));return isNaN($)?1/0:$},project:function(d,y){return y=y===void 0?this._zoom:y,this.options.crs.latLngToPoint(ce(d),y)},unproject:function(d,y){return y=y===void 0?this._zoom:y,this.options.crs.pointToLatLng(N(d),y)},layerPointToLatLng:function(d){var y=N(d).add(this.getPixelOrigin());return this.unproject(y)},latLngToLayerPoint:function(d){var y=this.project(ce(d))._round();return y._subtract(this.getPixelOrigin())},wrapLatLng:function(d){return this.options.crs.wrapLatLng(ce(d))},wrapLatLngBounds:function(d){return this.options.crs.wrapLatLngBounds(ae(d))},distance:function(d,y){return this.options.crs.distance(ce(d),ce(y))},containerPointToLayerPoint:function(d){return N(d).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(d){return N(d).add(this._getMapPanePos())},containerPointToLatLng:function(d){var y=this.containerPointToLayerPoint(N(d));return this.layerPointToLatLng(y)},latLngToContainerPoint:function(d){return this.layerPointToContainerPoint(this.latLngToLayerPoint(ce(d)))},mouseEventToContainerPoint:function(d){return hr(d,this._container)},mouseEventToLayerPoint:function(d){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(d))},mouseEventToLatLng:function(d){return this.layerPointToLatLng(this.mouseEventToLayerPoint(d))},_initContainer:function(d){var y=this._container=Sc(d);if(y){if(y._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");bt(y,"scroll",this._onScroll,this),this._containerId=f(y)},_initLayout:function(){var d=this._container;this._fadeAnimated=this.options.fadeAnimation&<.any3d,_t(d,"leaflet-container"+(lt.touch?" leaflet-touch":"")+(lt.retina?" leaflet-retina":"")+(lt.ielt9?" leaflet-oldie":"")+(lt.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var y=So(d,"position");y!=="absolute"&&y!=="relative"&&y!=="fixed"&&y!=="sticky"&&(d.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var d=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),_n(this._mapPane,new D(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(_t(d.markerPane,"leaflet-zoom-hide"),_t(d.shadowPane,"leaflet-zoom-hide"))},_resetView:function(d,y,E){_n(this._mapPane,new D(0,0));var $=!this._loaded;this._loaded=!0,y=this._limitZoom(y),this.fire("viewprereset");var Z=this._zoom!==y;this._moveStart(Z,E)._move(d,y)._moveEnd(Z),this.fire("viewreset"),$&&this.fire("load")},_moveStart:function(d,y){return d&&this.fire("zoomstart"),y||this.fire("movestart"),this},_move:function(d,y,E,$){y===void 0&&(y=this._zoom);var Z=this._zoom!==y;return this._zoom=y,this._lastCenter=d,this._pixelOrigin=this._getNewPixelOrigin(d),$?E&&E.pinch&&this.fire("zoom",E):((Z||E&&E.pinch)&&this.fire("zoom",E),this.fire("move",E)),this},_moveEnd:function(d){return d&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return ee(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(d){_n(this._mapPane,this._getMapPanePos().subtract(d))},_getZoomSpan:function(){return this.getMaxZoom()-this.getMinZoom()},_panInsideMaxBounds:function(){this._enforcingBounds||this.panInsideBounds(this.options.maxBounds)},_checkIfLoaded:function(){if(!this._loaded)throw new Error("Set map center and zoom first.")},_initEvents:function(d){this._targets={},this._targets[f(this._container)]=this;var y=d?$t:bt;y(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&y(window,"resize",this._onResize,this),lt.any3d&&this.options.transform3DLimit&&(d?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){ee(this._resizeRequest),this._resizeRequest=W(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var d=this._getMapPanePos();Math.max(Math.abs(d.x),Math.abs(d.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(d,y){for(var E=[],$,Z=y==="mouseout"||y==="mouseover",oe=d.target||d.srcElement,me=!1;oe;){if($=this._targets[f(oe)],$&&(y==="click"||y==="preclick")&&this._draggableMoved($)){me=!0;break}if($&&$.listens(y,!0)&&(Z&&!To(oe,d)||(E.push($),Z))||oe===this._container)break;oe=oe.parentNode}return!E.length&&!me&&!Z&&this.listens(y,!0)&&(E=[this]),E},_isClickDisabled:function(d){for(;d&&d!==this._container;){if(d._leaflet_disable_click)return!0;d=d.parentNode}},_handleDOMEvent:function(d){var y=d.target||d.srcElement;if(!(!this._loaded||y._leaflet_disable_events||d.type==="click"&&this._isClickDisabled(y))){var E=d.type;E==="mousedown"&&ru(y),this._fireDOMEvent(d,E)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(d,y,E){if(d.type==="click"){var $=i({},d);$.type="preclick",this._fireDOMEvent($,$.type,E)}var Z=this._findEventTargets(d,y);if(E){for(var oe=[],me=0;me<E.length;me++)E[me].listens(y,!0)&&oe.push(E[me]);Z=oe.concat(Z)}if(Z.length){y==="contextmenu"&&An(d);var Ae=Z[0],Me={originalEvent:d};if(d.type!=="keypress"&&d.type!=="keydown"&&d.type!=="keyup"){var qe=Ae.getLatLng&&(!Ae._radius||Ae._radius<=10);Me.containerPoint=qe?this.latLngToContainerPoint(Ae.getLatLng()):this.mouseEventToContainerPoint(d),Me.layerPoint=this.containerPointToLayerPoint(Me.containerPoint),Me.latlng=qe?Ae.getLatLng():this.layerPointToLatLng(Me.layerPoint)}for(me=0;me<Z.length;me++)if(Z[me].fire(y,Me,!0),Me.originalEvent._stopped||Z[me].options.bubblingMouseEvents===!1&&P(this._mouseEvents,y)!==-1)return}},_draggableMoved:function(d){return d=d.dragging&&d.dragging.enabled()?d:this,d.dragging&&d.dragging.moved()||this.boxZoom&&this.boxZoom.moved()},_clearHandlers:function(){for(var d=0,y=this._handlers.length;d<y;d++)this._handlers[d].disable()},whenReady:function(d,y){return this._loaded?d.call(y||this,{target:this}):this.on("load",d,y),this},_getMapPanePos:function(){return Ia(this._mapPane)||new D(0,0)},_moved:function(){var d=this._getMapPanePos();return d&&!d.equals([0,0])},_getTopLeftPoint:function(d,y){var E=d&&y!==void 0?this._getNewPixelOrigin(d,y):this.getPixelOrigin();return E.subtract(this._getMapPanePos())},_getNewPixelOrigin:function(d,y){var E=this.getSize()._divideBy(2);return this.project(d,y)._subtract(E)._add(this._getMapPanePos())._round()},_latLngToNewLayerPoint:function(d,y,E){var $=this._getNewPixelOrigin(E,y);return this.project(d,y)._subtract($)},_latLngBoundsToNewLayerBounds:function(d,y,E){var $=this._getNewPixelOrigin(E,y);return Q([this.project(d.getSouthWest(),y)._subtract($),this.project(d.getNorthWest(),y)._subtract($),this.project(d.getSouthEast(),y)._subtract($),this.project(d.getNorthEast(),y)._subtract($)])},_getCenterLayerPoint:function(){return this.containerPointToLayerPoint(this.getSize()._divideBy(2))},_getCenterOffset:function(d){return this.latLngToLayerPoint(d).subtract(this._getCenterLayerPoint())},_limitCenter:function(d,y,E){if(!E)return d;var $=this.project(d,y),Z=this.getSize().divideBy(2),oe=new B($.subtract(Z),$.add(Z)),me=this._getBoundsOffset(oe,E,y);return Math.abs(me.x)<=1&&Math.abs(me.y)<=1?d:this.unproject($.add(me),y)},_limitOffset:function(d,y){if(!y)return d;var E=this.getPixelBounds(),$=new B(E.min.add(d),E.max.add(d));return d.add(this._getBoundsOffset($,y))},_getBoundsOffset:function(d,y,E){var $=Q(this.project(y.getNorthEast(),E),this.project(y.getSouthWest(),E)),Z=$.min.subtract(d.min),oe=$.max.subtract(d.max),me=this._rebound(Z.x,-oe.x),Ae=this._rebound(Z.y,-oe.y);return new D(me,Ae)},_rebound:function(d,y){return d+y>0?Math.round(d-y)/2:Math.max(0,Math.ceil(d))-Math.max(0,Math.floor(y))},_limitZoom:function(d){var y=this.getMinZoom(),E=this.getMaxZoom(),$=lt.any3d?this.options.zoomSnap:1;return $&&(d=Math.round(d/$)*$),Math.max(y,Math.min(E,d))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){rn(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(d,y){var E=this._getCenterOffset(d)._trunc();return(y&&y.animate)!==!0&&!this.getSize().contains(E)?!1:(this.panBy(E,y),!0)},_createAnimProxy:function(){var d=this._proxy=Nt("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(d),this.on("zoomanim",function(y){var E=eu,$=this._proxy.style[E];Zr(this._proxy,this.project(y.center,y.zoom),this.getZoomScale(y.zoom,1)),$===this._proxy.style[E]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){nn(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var d=this.getCenter(),y=this.getZoom();Zr(this._proxy,this.project(d,y),this.getZoomScale(y,1))},_catchTransitionEnd:function(d){this._animatingZoom&&d.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(d,y,E){if(this._animatingZoom)return!0;if(E=E||{},!this._zoomAnimated||E.animate===!1||this._nothingToAnimate()||Math.abs(y-this._zoom)>this.options.zoomAnimationThreshold)return!1;var $=this.getZoomScale(y),Z=this._getCenterOffset(d)._divideBy(1-1/$);return E.animate!==!0&&!this.getSize().contains(Z)?!1:(W(function(){this._moveStart(!0,E.noMoveStart||!1)._animateZoom(d,y,!0)},this),!0)},_animateZoom:function(d,y,E,$){this._mapPane&&(E&&(this._animatingZoom=!0,this._animateToCenter=d,this._animateToZoom=y,_t(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:d,zoom:y,noUpdate:$}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(o(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&rn(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom,void 0,!0),this._tempFireZoomEvent&&this.fire("zoom"),delete this._tempFireZoomEvent,this.fire("move"),this._moveEnd(!0))}});function ou(d,y){return new Et(d,y)}var Er=X.extend({options:{position:"topright"},initialize:function(d){b(this,d)},getPosition:function(){return this.options.position},setPosition:function(d){var y=this._map;return y&&y.removeControl(this),this.options.position=d,y&&y.addControl(this),this},getContainer:function(){return this._container},addTo:function(d){this.remove(),this._map=d;var y=this._container=this.onAdd(d),E=this.getPosition(),$=d._controlCorners[E];return _t(y,"leaflet-control"),E.indexOf("bottom")!==-1?$.insertBefore(y,$.firstChild):$.appendChild(y),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(nn(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(d){this._map&&d&&d.screenX>0&&d.screenY>0&&this._map.getContainer().focus()}}),Rs=function(d){return new Er(d)};Et.include({addControl:function(d){return d.addTo(this),this},removeControl:function(d){return d.remove(),this},_initControlPos:function(){var d=this._controlCorners={},y="leaflet-",E=this._controlContainer=Nt("div",y+"control-container",this._container);function $(Z,oe){var me=y+Z+" "+y+oe;d[Z+oe]=Nt("div",me,E)}$("top","left"),$("top","right"),$("bottom","left"),$("bottom","right")},_clearControlPos:function(){for(var d in this._controlCorners)nn(this._controlCorners[d]);nn(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var jg=Er.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(d,y,E,$){return E<$?-1:$<E?1:0}},initialize:function(d,y,E){b(this,E),this._layerControlInputs=[],this._layers=[],this._lastZIndex=0,this._handlingClick=!1,this._preventClick=!1;for(var $ in d)this._addLayer(d[$],$);for($ in y)this._addLayer(y[$],$,!0)},onAdd:function(d){this._initLayout(),this._update(),this._map=d,d.on("zoomend",this._checkDisabledLayers,this);for(var y=0;y<this._layers.length;y++)this._layers[y].layer.on("add remove",this._onLayerChange,this);return this._container},addTo:function(d){return Er.prototype.addTo.call(this,d),this._expandIfNotCollapsed()},onRemove:function(){this._map.off("zoomend",this._checkDisabledLayers,this);for(var d=0;d<this._layers.length;d++)this._layers[d].layer.off("add remove",this._onLayerChange,this)},addBaseLayer:function(d,y){return this._addLayer(d,y),this._map?this._update():this},addOverlay:function(d,y){return this._addLayer(d,y,!0),this._map?this._update():this},removeLayer:function(d){d.off("add remove",this._onLayerChange,this);var y=this._getLayer(f(d));return y&&this._layers.splice(this._layers.indexOf(y),1),this._map?this._update():this},expand:function(){_t(this._container,"leaflet-control-layers-expanded"),this._section.style.height=null;var d=this._map.getSize().y-(this._container.offsetTop+50);return d<this._section.clientHeight?(_t(this._section,"leaflet-control-layers-scrollbar"),this._section.style.height=d+"px"):rn(this._section,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return rn(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var d="leaflet-control-layers",y=this._container=Nt("div",d),E=this.options.collapsed;y.setAttribute("aria-haspopup",!0),Ps(y),js(y);var $=this._section=Nt("section",d+"-list");E&&(this._map.on("click",this.collapse,this),bt(y,{mouseenter:this._expandSafely,mouseleave:this.collapse},this));var Z=this._layersLink=Nt("a",d+"-toggle",y);Z.href="#",Z.title="Layers",Z.setAttribute("role","button"),bt(Z,{keydown:function(oe){oe.keyCode===13&&this._expandSafely()},click:function(oe){An(oe),this._expandSafely()}},this),E||this.expand(),this._baseLayersList=Nt("div",d+"-base",$),this._separator=Nt("div",d+"-separator",$),this._overlaysList=Nt("div",d+"-overlays",$),y.appendChild($)},_getLayer:function(d){for(var y=0;y<this._layers.length;y++)if(this._layers[y]&&f(this._layers[y].layer)===d)return this._layers[y]},_addLayer:function(d,y,E){this._map&&d.on("add remove",this._onLayerChange,this),this._layers.push({layer:d,name:y,overlay:E}),this.options.sortLayers&&this._layers.sort(o(function($,Z){return this.options.sortFunction($.layer,Z.layer,$.name,Z.name)},this)),this.options.autoZIndex&&d.setZIndex&&(this._lastZIndex++,d.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;fr(this._baseLayersList),fr(this._overlaysList),this._layerControlInputs=[];var d,y,E,$,Z=0;for(E=0;E<this._layers.length;E++)$=this._layers[E],this._addItem($),y=y||$.overlay,d=d||!$.overlay,Z+=$.overlay?0:1;return this.options.hideSingleBase&&(d=d&&Z>1,this._baseLayersList.style.display=d?"":"none"),this._separator.style.display=y&&d?"":"none",this},_onLayerChange:function(d){this._handlingClick||this._update();var y=this._getLayer(f(d.target)),E=y.overlay?d.type==="add"?"overlayadd":"overlayremove":d.type==="add"?"baselayerchange":null;E&&this._map.fire(E,y)},_createRadioElement:function(d,y){var E='<input type="radio" class="leaflet-control-layers-selector" name="'+d+'"'+(y?' checked="checked"':"")+"/>",$=document.createElement("div");return $.innerHTML=E,$.firstChild},_addItem:function(d){var y=document.createElement("label"),E=this._map.hasLayer(d.layer),$;d.overlay?($=document.createElement("input"),$.type="checkbox",$.className="leaflet-control-layers-selector",$.defaultChecked=E):$=this._createRadioElement("leaflet-base-layers_"+f(this),E),this._layerControlInputs.push($),$.layerId=f(d.layer),bt($,"click",this._onInputClick,this);var Z=document.createElement("span");Z.innerHTML=" "+d.name;var oe=document.createElement("span");y.appendChild(oe),oe.appendChild($),oe.appendChild(Z);var me=d.overlay?this._overlaysList:this._baseLayersList;return me.appendChild(y),this._checkDisabledLayers(),y},_onInputClick:function(){if(!this._preventClick){var d=this._layerControlInputs,y,E,$=[],Z=[];this._handlingClick=!0;for(var oe=d.length-1;oe>=0;oe--)y=d[oe],E=this._getLayer(y.layerId).layer,y.checked?$.push(E):y.checked||Z.push(E);for(oe=0;oe<Z.length;oe++)this._map.hasLayer(Z[oe])&&this._map.removeLayer(Z[oe]);for(oe=0;oe<$.length;oe++)this._map.hasLayer($[oe])||this._map.addLayer($[oe]);this._handlingClick=!1,this._refocusOnMap()}},_checkDisabledLayers:function(){for(var d=this._layerControlInputs,y,E,$=this._map.getZoom(),Z=d.length-1;Z>=0;Z--)y=d[Z],E=this._getLayer(y.layerId).layer,y.disabled=E.options.minZoom!==void 0&&$<E.options.minZoom||E.options.maxZoom!==void 0&&$>E.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var d=this._section;this._preventClick=!0,bt(d,"click",An),this.expand();var y=this;setTimeout(function(){$t(d,"click",An),y._preventClick=!1})}}),W1=function(d,y,E){return new jg(d,y,E)},nh=Er.extend({options:{position:"topleft",zoomInText:'<span aria-hidden="true">+</span>',zoomInTitle:"Zoom in",zoomOutText:'<span aria-hidden="true">−</span>',zoomOutTitle:"Zoom out"},onAdd:function(d){var y="leaflet-control-zoom",E=Nt("div",y+" leaflet-bar"),$=this.options;return this._zoomInButton=this._createButton($.zoomInText,$.zoomInTitle,y+"-in",E,this._zoomIn),this._zoomOutButton=this._createButton($.zoomOutText,$.zoomOutTitle,y+"-out",E,this._zoomOut),this._updateDisabled(),d.on("zoomend zoomlevelschange",this._updateDisabled,this),E},onRemove:function(d){d.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(d){!this._disabled&&this._map._zoom<this._map.getMaxZoom()&&this._map.zoomIn(this._map.options.zoomDelta*(d.shiftKey?3:1))},_zoomOut:function(d){!this._disabled&&this._map._zoom>this._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(d.shiftKey?3:1))},_createButton:function(d,y,E,$,Z){var oe=Nt("a",E,$);return oe.innerHTML=d,oe.href="#",oe.title=y,oe.setAttribute("role","button"),oe.setAttribute("aria-label",y),Ps(oe),bt(oe,"click",zi),bt(oe,"click",Z,this),bt(oe,"click",this._refocusOnMap,this),oe},_updateDisabled:function(){var d=this._map,y="leaflet-disabled";rn(this._zoomInButton,y),rn(this._zoomOutButton,y),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||d._zoom===d.getMinZoom())&&(_t(this._zoomOutButton,y),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||d._zoom===d.getMaxZoom())&&(_t(this._zoomInButton,y),this._zoomInButton.setAttribute("aria-disabled","true"))}});Et.mergeOptions({zoomControl:!0}),Et.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new nh,this.addControl(this.zoomControl))});var rh=function(d){return new nh(d)},Pg=Er.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(d){var y="leaflet-control-scale",E=Nt("div",y),$=this.options;return this._addScales($,y+"-line",E),d.on($.updateWhenIdle?"moveend":"move",this._update,this),d.whenReady(this._update,this),E},onRemove:function(d){d.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(d,y,E){d.metric&&(this._mScale=Nt("div",y,E)),d.imperial&&(this._iScale=Nt("div",y,E))},_update:function(){var d=this._map,y=d.getSize().y/2,E=d.distance(d.containerPointToLatLng([0,y]),d.containerPointToLatLng([this.options.maxWidth,y]));this._updateScales(E)},_updateScales:function(d){this.options.metric&&d&&this._updateMetric(d),this.options.imperial&&d&&this._updateImperial(d)},_updateMetric:function(d){var y=this._getRoundNum(d),E=y<1e3?y+" m":y/1e3+" km";this._updateScale(this._mScale,E,y/d)},_updateImperial:function(d){var y=d*3.2808399,E,$,Z;y>5280?(E=y/5280,$=this._getRoundNum(E),this._updateScale(this._iScale,$+" mi",$/E)):(Z=this._getRoundNum(y),this._updateScale(this._iScale,Z+" ft",Z/y))},_updateScale:function(d,y,E){d.style.width=Math.round(this.options.maxWidth*E)+"px",d.innerHTML=y},_getRoundNum:function(d){var y=Math.pow(10,(Math.floor(d)+"").length-1),E=d/y;return E=E>=10?10:E>=5?5:E>=3?3:E>=2?2:1,y*E}}),Y1=function(d){return new Pg(d)},K1='<svg aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="12" height="8" viewBox="0 0 12 8" class="leaflet-attribution-flag"><path fill="#4C7BE1" d="M0 0h12v4H0z"/><path fill="#FFD500" d="M0 4h12v3H0z"/><path fill="#E0BC00" d="M0 7h12v1H0z"/></svg>',ih=Er.extend({options:{position:"bottomright",prefix:'<a href="https://leafletjs.com" title="A JavaScript library for interactive maps">'+(lt.inlineSvg?K1+" ":"")+"Leaflet</a>"},initialize:function(d){b(this,d),this._attributions={}},onAdd:function(d){d.attributionControl=this,this._container=Nt("div","leaflet-control-attribution"),Ps(this._container);for(var y in d._layers)d._layers[y].getAttribution&&this.addAttribution(d._layers[y].getAttribution());return this._update(),d.on("layeradd",this._addAttribution,this),this._container},onRemove:function(d){d.off("layeradd",this._addAttribution,this)},_addAttribution:function(d){d.layer.getAttribution&&(this.addAttribution(d.layer.getAttribution()),d.layer.once("remove",function(){this.removeAttribution(d.layer.getAttribution())},this))},setPrefix:function(d){return this.options.prefix=d,this._update(),this},addAttribution:function(d){return d?(this._attributions[d]||(this._attributions[d]=0),this._attributions[d]++,this._update(),this):this},removeAttribution:function(d){return d?(this._attributions[d]&&(this._attributions[d]--,this._update()),this):this},_update:function(){if(this._map){var d=[];for(var y in this._attributions)this._attributions[y]&&d.push(y);var E=[];this.options.prefix&&E.push(this.options.prefix),d.length&&E.push(d.join(", ")),this._container.innerHTML=E.join(' <span aria-hidden="true">|</span> ')}}});Et.mergeOptions({attributionControl:!0}),Et.addInitHook(function(){this.options.attributionControl&&new ih().addTo(this)});var Z1=function(d){return new ih(d)};Er.Layers=jg,Er.Zoom=nh,Er.Scale=Pg,Er.Attribution=ih,Rs.layers=W1,Rs.zoom=rh,Rs.scale=Y1,Rs.attribution=Z1;var oi=X.extend({initialize:function(d){this._map=d},enable:function(){return this._enabled?this:(this._enabled=!0,this.addHooks(),this)},disable:function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},enabled:function(){return!!this._enabled}});oi.addTo=function(d,y){return d.addHandler(y,this),this};var X1={Events:H},Rg=lt.touch?"touchstart mousedown":"mousedown",Ba=I.extend({options:{clickTolerance:3},initialize:function(d,y,E,$){b(this,$),this._element=d,this._dragStartTarget=y||d,this._preventOutline=E},enable:function(){this._enabled||(bt(this._dragStartTarget,Rg,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(Ba._dragging===this&&this.finishDrag(!0),$t(this._dragStartTarget,Rg,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(d){if(this._enabled&&(this._moved=!1,!Cs(this._element,"leaflet-zoom-anim"))){if(d.touches&&d.touches.length!==1){Ba._dragging===this&&this.finishDrag();return}if(!(Ba._dragging||d.shiftKey||d.which!==1&&d.button!==1&&!d.touches)&&(Ba._dragging=this,this._preventOutline&&ru(this._element),nu(),$i(),!this._moving)){this.fire("down");var y=d.touches?d.touches[0]:d,E=Ao(this._element);this._startPoint=new D(y.clientX,y.clientY),this._startPos=Ia(this._element),this._parentScale=$a(E);var $=d.type==="mousedown";bt(document,$?"mousemove":"touchmove",this._onMove,this),bt(document,$?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(d){if(this._enabled){if(d.touches&&d.touches.length>1){this._moved=!0;return}var y=d.touches&&d.touches.length===1?d.touches[0]:d,E=new D(y.clientX,y.clientY)._subtract(this._startPoint);!E.x&&!E.y||Math.abs(E.x)+Math.abs(E.y)<this.options.clickTolerance||(E.x/=this._parentScale.x,E.y/=this._parentScale.y,An(d),this._moved||(this.fire("dragstart"),this._moved=!0,_t(document.body,"leaflet-dragging"),this._lastTarget=d.target||d.srcElement,window.SVGElementInstance&&this._lastTarget instanceof window.SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),_t(this._lastTarget,"leaflet-drag-target")),this._newPos=this._startPos.add(E),this._moving=!0,this._lastEvent=d,this._updatePosition())}},_updatePosition:function(){var d={originalEvent:this._lastEvent};this.fire("predrag",d),_n(this._element,this._newPos),this.fire("drag",d)},_onUp:function(){this._enabled&&this.finishDrag()},finishDrag:function(d){rn(document.body,"leaflet-dragging"),this._lastTarget&&(rn(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null),$t(document,"mousemove touchmove",this._onMove,this),$t(document,"mouseup touchend touchcancel",this._onUp,this),eh(),tu();var y=this._moved&&this._moving;this._moving=!1,Ba._dragging=!1,y&&this.fire("dragend",{noInertia:d,distance:this._newPos.distanceTo(this._startPos)})}});function Mg(d,y,E){var $,Z=[1,4,2,8],oe,me,Ae,Me,qe,Qe,rt,at;for(oe=0,Qe=d.length;oe<Qe;oe++)d[oe]._code=jo(d[oe],y);for(Ae=0;Ae<4;Ae++){for(rt=Z[Ae],$=[],oe=0,Qe=d.length,me=Qe-1;oe<Qe;me=oe++)Me=d[oe],qe=d[me],Me._code&rt?qe._code&rt||(at=Tc(qe,Me,rt,y,E),at._code=jo(at,y),$.push(at)):(qe._code&rt&&(at=Tc(qe,Me,rt,y,E),at._code=jo(at,y),$.push(at)),$.push(Me));d=$}return d}function Oc(d,y){var E,$,Z,oe,me,Ae,Me,qe,Qe;if(!d||d.length===0)throw new Error("latlngs not passed");tr(d)||(console.warn("latlngs are not flat! Only the first ring will be used"),d=d[0]);var rt=ce([0,0]),at=ae(d),yt=at.getNorthWest().distanceTo(at.getSouthWest())*at.getNorthEast().distanceTo(at.getNorthWest());yt<1700&&(rt=ah(d));var an=d.length,xn=[];for(E=0;E<an;E++){var nr=ce(d[E]);xn.push(y.project(ce([nr.lat-rt.lat,nr.lng-rt.lng])))}for(Ae=Me=qe=0,E=0,$=an-1;E<an;$=E++)Z=xn[E],oe=xn[$],me=Z.y*oe.x-oe.y*Z.x,Me+=(Z.x+oe.x)*me,qe+=(Z.y+oe.y)*me,Ae+=me*3;Ae===0?Qe=xn[0]:Qe=[Me/Ae,qe/Ae];var Xr=y.unproject(N(Qe));return ce([Xr.lat+rt.lat,Xr.lng+rt.lng])}function ah(d){for(var y=0,E=0,$=0,Z=0;Z<d.length;Z++){var oe=ce(d[Z]);y+=oe.lat,E+=oe.lng,$++}return ce([y/$,E/$])}var Q1={__proto__:null,clipPolygon:Mg,polygonCenter:Oc,centroid:ah};function Ng(d,y){if(!y||!d.length)return d.slice();var E=y*y;return d=tw(d,E),d=ew(d,E),d}function oh(d,y,E){return Math.sqrt(Po(d,y,E,!0))}function J1(d,y,E){return Po(d,y,E)}function ew(d,y){var E=d.length,$=typeof Uint8Array<"u"?Uint8Array:Array,Z=new $(E);Z[0]=Z[E-1]=1,sh(d,Z,y,0,E-1);var oe,me=[];for(oe=0;oe<E;oe++)Z[oe]&&me.push(d[oe]);return me}function sh(d,y,E,$,Z){var oe=0,me,Ae,Me;for(Ae=$+1;Ae<=Z-1;Ae++)Me=Po(d[Ae],d[$],d[Z],!0),Me>oe&&(me=Ae,oe=Me);oe>E&&(y[me]=1,sh(d,y,E,$,me),sh(d,y,E,me,Z))}function tw(d,y){for(var E=[d[0]],$=1,Z=0,oe=d.length;$<oe;$++)nw(d[$],d[Z])>y&&(E.push(d[$]),Z=$);return Z<oe-1&&E.push(d[oe-1]),E}var Lg;function kg(d,y,E,$,Z){var oe=$?Lg:jo(d,E),me=jo(y,E),Ae,Me,qe;for(Lg=me;;){if(!(oe|me))return[d,y];if(oe&me)return!1;Ae=oe||me,Me=Tc(d,y,Ae,E,Z),qe=jo(Me,E),Ae===oe?(d=Me,oe=qe):(y=Me,me=qe)}}function Tc(d,y,E,$,Z){var oe=y.x-d.x,me=y.y-d.y,Ae=$.min,Me=$.max,qe,Qe;return E&8?(qe=d.x+oe*(Me.y-d.y)/me,Qe=Me.y):E&4?(qe=d.x+oe*(Ae.y-d.y)/me,Qe=Ae.y):E&2?(qe=Me.x,Qe=d.y+me*(Me.x-d.x)/oe):E&1&&(qe=Ae.x,Qe=d.y+me*(Ae.x-d.x)/oe),new D(qe,Qe,Z)}function jo(d,y){var E=0;return d.x<y.min.x?E|=1:d.x>y.max.x&&(E|=2),d.y<y.min.y?E|=4:d.y>y.max.y&&(E|=8),E}function nw(d,y){var E=y.x-d.x,$=y.y-d.y;return E*E+$*$}function Po(d,y,E,$){var Z=y.x,oe=y.y,me=E.x-Z,Ae=E.y-oe,Me=me*me+Ae*Ae,qe;return Me>0&&(qe=((d.x-Z)*me+(d.y-oe)*Ae)/Me,qe>1?(Z=E.x,oe=E.y):qe>0&&(Z+=me*qe,oe+=Ae*qe)),me=d.x-Z,Ae=d.y-oe,$?me*me+Ae*Ae:new D(Z,oe)}function tr(d){return!O(d[0])||typeof d[0][0]!="object"&&typeof d[0][0]<"u"}function Dg(d){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),tr(d)}function lh(d,y){var E,$,Z,oe,me,Ae,Me,qe;if(!d||d.length===0)throw new Error("latlngs not passed");tr(d)||(console.warn("latlngs are not flat! Only the first ring will be used"),d=d[0]);var Qe=ce([0,0]),rt=ae(d),at=rt.getNorthWest().distanceTo(rt.getSouthWest())*rt.getNorthEast().distanceTo(rt.getNorthWest());at<1700&&(Qe=ah(d));var yt=d.length,an=[];for(E=0;E<yt;E++){var xn=ce(d[E]);an.push(y.project(ce([xn.lat-Qe.lat,xn.lng-Qe.lng])))}for(E=0,$=0;E<yt-1;E++)$+=an[E].distanceTo(an[E+1])/2;if($===0)qe=an[0];else for(E=0,oe=0;E<yt-1;E++)if(me=an[E],Ae=an[E+1],Z=me.distanceTo(Ae),oe+=Z,oe>$){Me=(oe-$)/Z,qe=[Ae.x-Me*(Ae.x-me.x),Ae.y-Me*(Ae.y-me.y)];break}var nr=y.unproject(N(qe));return ce([nr.lat+Qe.lat,nr.lng+Qe.lng])}var Ig={__proto__:null,simplify:Ng,pointToSegmentDistance:oh,closestPointOnSegment:J1,clipSegment:kg,_getEdgeIntersection:Tc,_getBitCode:jo,_sqClosestPointOnSegment:Po,isFlat:tr,_flat:Dg,polylineCenter:lh},jc={project:function(d){return new D(d.lng,d.lat)},unproject:function(d){return new fe(d.y,d.x)},bounds:new B([-180,-90],[180,90])},Pc={R:6378137,R_MINOR:6356752314245179e-9,bounds:new B([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(d){var y=Math.PI/180,E=this.R,$=d.lat*y,Z=this.R_MINOR/E,oe=Math.sqrt(1-Z*Z),me=oe*Math.sin($),Ae=Math.tan(Math.PI/4-$/2)/Math.pow((1-me)/(1+me),oe/2);return $=-E*Math.log(Math.max(Ae,1e-10)),new D(d.lng*y*E,$)},unproject:function(d){for(var y=180/Math.PI,E=this.R,$=this.R_MINOR/E,Z=Math.sqrt(1-$*$),oe=Math.exp(-d.y/E),me=Math.PI/2-2*Math.atan(oe),Ae=0,Me=.1,qe;Ae<15&&Math.abs(Me)>1e-7;Ae++)qe=Z*Math.sin(me),qe=Math.pow((1-qe)/(1+qe),Z/2),Me=Math.PI/2-2*Math.atan(oe*qe)-me,me+=Me;return new fe(me*y,d.x*y/E)}},$g={__proto__:null,LonLat:jc,Mercator:Pc,SphericalMercator:te},Ms=i({},F,{code:"EPSG:3395",projection:Pc,transformation:function(){var d=.5/(Math.PI*Pc.R);return J(d,.5,-d,.5)}()}),Bg=i({},F,{code:"EPSG:4326",projection:jc,transformation:J(1/180,1,-1/180,.5)}),rw=i({},ye,{projection:jc,transformation:J(1,0,-1,0),scale:function(d){return Math.pow(2,d)},zoom:function(d){return Math.log(d)/Math.LN2},distance:function(d,y){var E=y.lng-d.lng,$=y.lat-d.lat;return Math.sqrt(E*E+$*$)},infinite:!0});ye.Earth=F,ye.EPSG3395=Ms,ye.EPSG3857=se,ye.EPSG900913=de,ye.EPSG4326=Bg,ye.Simple=rw;var si=I.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(d){return d.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(d){return d&&d.removeLayer(this),this},getPane:function(d){return this._map.getPane(d?this.options[d]||d:this.options.pane)},addInteractiveTarget:function(d){return this._map._targets[f(d)]=this,this},removeInteractiveTarget:function(d){return delete this._map._targets[f(d)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(d){var y=d.target;if(y.hasLayer(this)){if(this._map=y,this._zoomAnimated=y._zoomAnimated,this.getEvents){var E=this.getEvents();y.on(E,this),this.once("remove",function(){y.off(E,this)},this)}this.onAdd(y),this.fire("add"),y.fire("layeradd",{layer:this})}}});Et.include({addLayer:function(d){if(!d._layerAdd)throw new Error("The provided object is not a Layer.");var y=f(d);return this._layers[y]?this:(this._layers[y]=d,d._mapToAdd=this,d.beforeAdd&&d.beforeAdd(this),this.whenReady(d._layerAdd,d),this)},removeLayer:function(d){var y=f(d);return this._layers[y]?(this._loaded&&d.onRemove(this),delete this._layers[y],this._loaded&&(this.fire("layerremove",{layer:d}),d.fire("remove")),d._map=d._mapToAdd=null,this):this},hasLayer:function(d){return f(d)in this._layers},eachLayer:function(d,y){for(var E in this._layers)d.call(y,this._layers[E]);return this},_addLayers:function(d){d=d?O(d)?d:[d]:[];for(var y=0,E=d.length;y<E;y++)this.addLayer(d[y])},_addZoomLimit:function(d){(!isNaN(d.options.maxZoom)||!isNaN(d.options.minZoom))&&(this._zoomBoundLayers[f(d)]=d,this._updateZoomLevels())},_removeZoomLimit:function(d){var y=f(d);this._zoomBoundLayers[y]&&(delete this._zoomBoundLayers[y],this._updateZoomLevels())},_updateZoomLevels:function(){var d=1/0,y=-1/0,E=this._getZoomSpan();for(var $ in this._zoomBoundLayers){var Z=this._zoomBoundLayers[$].options;d=Z.minZoom===void 0?d:Math.min(d,Z.minZoom),y=Z.maxZoom===void 0?y:Math.max(y,Z.maxZoom)}this._layersMaxZoom=y===-1/0?void 0:y,this._layersMinZoom=d===1/0?void 0:d,E!==this._getZoomSpan()&&this.fire("zoomlevelschange"),this.options.maxZoom===void 0&&this._layersMaxZoom&&this.getZoom()>this._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()<this._layersMinZoom&&this.setZoom(this._layersMinZoom)}});var Ro=si.extend({initialize:function(d,y){b(this,y),this._layers={};var E,$;if(d)for(E=0,$=d.length;E<$;E++)this.addLayer(d[E])},addLayer:function(d){var y=this.getLayerId(d);return this._layers[y]=d,this._map&&this._map.addLayer(d),this},removeLayer:function(d){var y=d in this._layers?d:this.getLayerId(d);return this._map&&this._layers[y]&&this._map.removeLayer(this._layers[y]),delete this._layers[y],this},hasLayer:function(d){var y=typeof d=="number"?d:this.getLayerId(d);return y in this._layers},clearLayers:function(){return this.eachLayer(this.removeLayer,this)},invoke:function(d){var y=Array.prototype.slice.call(arguments,1),E,$;for(E in this._layers)$=this._layers[E],$[d]&&$[d].apply($,y);return this},onAdd:function(d){this.eachLayer(d.addLayer,d)},onRemove:function(d){this.eachLayer(d.removeLayer,d)},eachLayer:function(d,y){for(var E in this._layers)d.call(y,this._layers[E]);return this},getLayer:function(d){return this._layers[d]},getLayers:function(){var d=[];return this.eachLayer(d.push,d),d},setZIndex:function(d){return this.invoke("setZIndex",d)},getLayerId:function(d){return f(d)}}),Ug=function(d,y){return new Ro(d,y)},Nr=Ro.extend({addLayer:function(d){return this.hasLayer(d)?this:(d.addEventParent(this),Ro.prototype.addLayer.call(this,d),this.fire("layeradd",{layer:d}))},removeLayer:function(d){return this.hasLayer(d)?(d in this._layers&&(d=this._layers[d]),d.removeEventParent(this),Ro.prototype.removeLayer.call(this,d),this.fire("layerremove",{layer:d})):this},setStyle:function(d){return this.invoke("setStyle",d)},bringToFront:function(){return this.invoke("bringToFront")},bringToBack:function(){return this.invoke("bringToBack")},getBounds:function(){var d=new G;for(var y in this._layers){var E=this._layers[y];d.extend(E.getBounds?E.getBounds():E.getLatLng())}return d}}),su=function(d,y){return new Nr(d,y)},Ns=X.extend({options:{popupAnchor:[0,0],tooltipAnchor:[0,0],crossOrigin:!1},initialize:function(d){b(this,d)},createIcon:function(d){return this._createIcon("icon",d)},createShadow:function(d){return this._createIcon("shadow",d)},_createIcon:function(d,y){var E=this._getIconUrl(d);if(!E){if(d==="icon")throw new Error("iconUrl not set in Icon options (see the docs).");return null}var $=this._createImg(E,y&&y.tagName==="IMG"?y:null);return this._setIconStyles($,d),(this.options.crossOrigin||this.options.crossOrigin==="")&&($.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),$},_setIconStyles:function(d,y){var E=this.options,$=E[y+"Size"];typeof $=="number"&&($=[$,$]);var Z=N($),oe=N(y==="shadow"&&E.shadowAnchor||E.iconAnchor||Z&&Z.divideBy(2,!0));d.className="leaflet-marker-"+y+" "+(E.className||""),oe&&(d.style.marginLeft=-oe.x+"px",d.style.marginTop=-oe.y+"px"),Z&&(d.style.width=Z.x+"px",d.style.height=Z.y+"px")},_createImg:function(d,y){return y=y||document.createElement("img"),y.src=d,y},_getIconUrl:function(d){return lt.retina&&this.options[d+"RetinaUrl"]||this.options[d+"Url"]}});function Rc(d){return new Ns(d)}var Ls=Ns.extend({options:{iconUrl:"marker-icon.png",iconRetinaUrl:"marker-icon-2x.png",shadowUrl:"marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[16,-28],shadowSize:[41,41]},_getIconUrl:function(d){return typeof Ls.imagePath!="string"&&(Ls.imagePath=this._detectIconPath()),(this.options.imagePath||Ls.imagePath)+Ns.prototype._getIconUrl.call(this,d)},_stripUrl:function(d){var y=function(E,$,Z){var oe=$.exec(E);return oe&&oe[Z]};return d=y(d,/^url\((['"])?(.+)\1\)$/,2),d&&y(d,/^(.*)marker-icon\.png$/,1)},_detectIconPath:function(){var d=Nt("div","leaflet-default-icon-path",document.body),y=So(d,"background-image")||So(d,"backgroundImage");if(document.body.removeChild(d),y=this._stripUrl(y),y)return y;var E=document.querySelector('link[href$="leaflet.css"]');return E?E.href.substring(0,E.href.length-11-1):""}}),uh=oi.extend({initialize:function(d){this._marker=d},addHooks:function(){var d=this._marker._icon;this._draggable||(this._draggable=new Ba(d,d,!0)),this._draggable.on({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).enable(),_t(d,"leaflet-marker-draggable")},removeHooks:function(){this._draggable.off({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).disable(),this._marker._icon&&rn(this._marker._icon,"leaflet-marker-draggable")},moved:function(){return this._draggable&&this._draggable._moved},_adjustPan:function(d){var y=this._marker,E=y._map,$=this._marker.options.autoPanSpeed,Z=this._marker.options.autoPanPadding,oe=Ia(y._icon),me=E.getPixelBounds(),Ae=E.getPixelOrigin(),Me=Q(me.min._subtract(Ae).add(Z),me.max._subtract(Ae).subtract(Z));if(!Me.contains(oe)){var qe=N((Math.max(Me.max.x,oe.x)-Me.max.x)/(me.max.x-Me.max.x)-(Math.min(Me.min.x,oe.x)-Me.min.x)/(me.min.x-Me.min.x),(Math.max(Me.max.y,oe.y)-Me.max.y)/(me.max.y-Me.max.y)-(Math.min(Me.min.y,oe.y)-Me.min.y)/(me.min.y-Me.min.y)).multiplyBy($);E.panBy(qe,{animate:!1}),this._draggable._newPos._add(qe),this._draggable._startPos._add(qe),_n(y._icon,this._draggable._newPos),this._onDrag(d),this._panRequest=W(this._adjustPan.bind(this,d))}},_onDragStart:function(){this._oldLatLng=this._marker.getLatLng(),this._marker.closePopup&&this._marker.closePopup(),this._marker.fire("movestart").fire("dragstart")},_onPreDrag:function(d){this._marker.options.autoPan&&(ee(this._panRequest),this._panRequest=W(this._adjustPan.bind(this,d)))},_onDrag:function(d){var y=this._marker,E=y._shadow,$=Ia(y._icon),Z=y._map.layerPointToLatLng($);E&&_n(E,$),y._latlng=Z,d.latlng=Z,d.oldLatLng=this._oldLatLng,y.fire("move",d).fire("drag",d)},_onDragEnd:function(d){ee(this._panRequest),delete this._oldLatLng,this._marker.fire("moveend").fire("dragend",d)}}),ks=si.extend({options:{icon:new Ls,interactive:!0,keyboard:!0,title:"",alt:"Marker",zIndexOffset:0,opacity:1,riseOnHover:!1,riseOffset:250,pane:"markerPane",shadowPane:"shadowPane",bubblingMouseEvents:!1,autoPanOnFocus:!0,draggable:!1,autoPan:!1,autoPanPadding:[50,50],autoPanSpeed:10},initialize:function(d,y){b(this,y),this._latlng=ce(d)},onAdd:function(d){this._zoomAnimated=this._zoomAnimated&&d.options.markerZoomAnimation,this._zoomAnimated&&d.on("zoomanim",this._animateZoom,this),this._initIcon(),this.update()},onRemove:function(d){this.dragging&&this.dragging.enabled()&&(this.options.draggable=!0,this.dragging.removeHooks()),delete this.dragging,this._zoomAnimated&&d.off("zoomanim",this._animateZoom,this),this._removeIcon(),this._removeShadow()},getEvents:function(){return{zoom:this.update,viewreset:this.update}},getLatLng:function(){return this._latlng},setLatLng:function(d){var y=this._latlng;return this._latlng=ce(d),this.update(),this.fire("move",{oldLatLng:y,latlng:this._latlng})},setZIndexOffset:function(d){return this.options.zIndexOffset=d,this.update()},getIcon:function(){return this.options.icon},setIcon:function(d){return this.options.icon=d,this._map&&(this._initIcon(),this.update()),this._popup&&this.bindPopup(this._popup,this._popup.options),this},getElement:function(){return this._icon},update:function(){if(this._icon&&this._map){var d=this._map.latLngToLayerPoint(this._latlng).round();this._setPos(d)}return this},_initIcon:function(){var d=this.options,y="leaflet-zoom-"+(this._zoomAnimated?"animated":"hide"),E=d.icon.createIcon(this._icon),$=!1;E!==this._icon&&(this._icon&&this._removeIcon(),$=!0,d.title&&(E.title=d.title),E.tagName==="IMG"&&(E.alt=d.alt||"")),_t(E,y),d.keyboard&&(E.tabIndex="0",E.setAttribute("role","button")),this._icon=E,d.riseOnHover&&this.on({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&bt(E,"focus",this._panOnFocus,this);var Z=d.icon.createShadow(this._shadow),oe=!1;Z!==this._shadow&&(this._removeShadow(),oe=!0),Z&&(_t(Z,y),Z.alt=""),this._shadow=Z,d.opacity<1&&this._updateOpacity(),$&&this.getPane().appendChild(this._icon),this._initInteraction(),Z&&oe&&this.getPane(d.shadowPane).appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&$t(this._icon,"focus",this._panOnFocus,this),nn(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&nn(this._shadow),this._shadow=null},_setPos:function(d){this._icon&&_n(this._icon,d),this._shadow&&_n(this._shadow,d),this._zIndex=d.y+this.options.zIndexOffset,this._resetZIndex()},_updateZIndex:function(d){this._icon&&(this._icon.style.zIndex=this._zIndex+d)},_animateZoom:function(d){var y=this._map._latLngToNewLayerPoint(this._latlng,d.zoom,d.center).round();this._setPos(y)},_initInteraction:function(){if(this.options.interactive&&(_t(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),uh)){var d=this.options.draggable;this.dragging&&(d=this.dragging.enabled(),this.dragging.disable()),this.dragging=new uh(this),d&&this.dragging.enable()}},setOpacity:function(d){return this.options.opacity=d,this._map&&this._updateOpacity(),this},_updateOpacity:function(){var d=this.options.opacity;this._icon&&Ar(this._icon,d),this._shadow&&Ar(this._shadow,d)},_bringToFront:function(){this._updateZIndex(this.options.riseOffset)},_resetZIndex:function(){this._updateZIndex(0)},_panOnFocus:function(){var d=this._map;if(d){var y=this.options.icon.options,E=y.iconSize?N(y.iconSize):N(0,0),$=y.iconAnchor?N(y.iconAnchor):N(0,0);d.panInside(this._latlng,{paddingTopLeft:$,paddingBottomRight:E.subtract($)})}},_getPopupAnchor:function(){return this.options.icon.options.popupAnchor},_getTooltipAnchor:function(){return this.options.icon.options.tooltipAnchor}});function ch(d,y){return new ks(d,y)}var sa=si.extend({options:{stroke:!0,color:"#3388ff",weight:3,opacity:1,lineCap:"round",lineJoin:"round",dashArray:null,dashOffset:null,fill:!1,fillColor:null,fillOpacity:.2,fillRule:"evenodd",interactive:!0,bubblingMouseEvents:!0},beforeAdd:function(d){this._renderer=d.getRenderer(this)},onAdd:function(){this._renderer._initPath(this),this._reset(),this._renderer._addPath(this)},onRemove:function(){this._renderer._removePath(this)},redraw:function(){return this._map&&this._renderer._updatePath(this),this},setStyle:function(d){return b(this,d),this._renderer&&(this._renderer._updateStyle(this),this.options.stroke&&d&&Object.prototype.hasOwnProperty.call(d,"weight")&&this._updateBounds()),this},bringToFront:function(){return this._renderer&&this._renderer._bringToFront(this),this},bringToBack:function(){return this._renderer&&this._renderer._bringToBack(this),this},getElement:function(){return this._path},_reset:function(){this._project(),this._update()},_clickTolerance:function(){return(this.options.stroke?this.options.weight/2:0)+(this._renderer.options.tolerance||0)}}),lu=sa.extend({options:{fill:!0,radius:10},initialize:function(d,y){b(this,y),this._latlng=ce(d),this._radius=this.options.radius},setLatLng:function(d){var y=this._latlng;return this._latlng=ce(d),this.redraw(),this.fire("move",{oldLatLng:y,latlng:this._latlng})},getLatLng:function(){return this._latlng},setRadius:function(d){return this.options.radius=this._radius=d,this.redraw()},getRadius:function(){return this._radius},setStyle:function(d){var y=d&&d.radius||this._radius;return sa.prototype.setStyle.call(this,d),this.setRadius(y),this},_project:function(){this._point=this._map.latLngToLayerPoint(this._latlng),this._updateBounds()},_updateBounds:function(){var d=this._radius,y=this._radiusY||d,E=this._clickTolerance(),$=[d+E,y+E];this._pxBounds=new B(this._point.subtract($),this._point.add($))},_update:function(){this._map&&this._updatePath()},_updatePath:function(){this._renderer._updateCircle(this)},_empty:function(){return this._radius&&!this._renderer._bounds.intersects(this._pxBounds)},_containsPoint:function(d){return d.distanceTo(this._point)<=this._radius+this._clickTolerance()}});function zg(d,y){return new lu(d,y)}var fh=lu.extend({initialize:function(d,y,E){if(typeof y=="number"&&(y=i({},E,{radius:y})),b(this,y),this._latlng=ce(d),isNaN(this.options.radius))throw new Error("Circle radius cannot be NaN");this._mRadius=this.options.radius},setRadius:function(d){return this._mRadius=d,this.redraw()},getRadius:function(){return this._mRadius},getBounds:function(){var d=[this._radius,this._radiusY||this._radius];return new G(this._map.layerPointToLatLng(this._point.subtract(d)),this._map.layerPointToLatLng(this._point.add(d)))},setStyle:sa.prototype.setStyle,_project:function(){var d=this._latlng.lng,y=this._latlng.lat,E=this._map,$=E.options.crs;if($.distance===F.distance){var Z=Math.PI/180,oe=this._mRadius/F.R/Z,me=E.project([y+oe,d]),Ae=E.project([y-oe,d]),Me=me.add(Ae).divideBy(2),qe=E.unproject(Me).lat,Qe=Math.acos((Math.cos(oe*Z)-Math.sin(y*Z)*Math.sin(qe*Z))/(Math.cos(y*Z)*Math.cos(qe*Z)))/Z;(isNaN(Qe)||Qe===0)&&(Qe=oe/Math.cos(Math.PI/180*y)),this._point=Me.subtract(E.getPixelOrigin()),this._radius=isNaN(Qe)?0:Me.x-E.project([qe,d-Qe]).x,this._radiusY=Me.y-me.y}else{var rt=$.unproject($.project(this._latlng).subtract([this._mRadius,0]));this._point=E.latLngToLayerPoint(this._latlng),this._radius=this._point.x-E.latLngToLayerPoint(rt).x}this._updateBounds()}});function iw(d,y,E){return new fh(d,y,E)}var la=sa.extend({options:{smoothFactor:1,noClip:!1},initialize:function(d,y){b(this,y),this._setLatLngs(d)},getLatLngs:function(){return this._latlngs},setLatLngs:function(d){return this._setLatLngs(d),this.redraw()},isEmpty:function(){return!this._latlngs.length},closestLayerPoint:function(d){for(var y=1/0,E=null,$=Po,Z,oe,me=0,Ae=this._parts.length;me<Ae;me++)for(var Me=this._parts[me],qe=1,Qe=Me.length;qe<Qe;qe++){Z=Me[qe-1],oe=Me[qe];var rt=$(d,Z,oe,!0);rt<y&&(y=rt,E=$(d,Z,oe))}return E&&(E.distance=Math.sqrt(y)),E},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return lh(this._defaultShape(),this._map.options.crs)},getBounds:function(){return this._bounds},addLatLng:function(d,y){return y=y||this._defaultShape(),d=ce(d),y.push(d),this._bounds.extend(d),this.redraw()},_setLatLngs:function(d){this._bounds=new G,this._latlngs=this._convertLatLngs(d)},_defaultShape:function(){return tr(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(d){for(var y=[],E=tr(d),$=0,Z=d.length;$<Z;$++)E?(y[$]=ce(d[$]),this._bounds.extend(y[$])):y[$]=this._convertLatLngs(d[$]);return y},_project:function(){var d=new B;this._rings=[],this._projectLatlngs(this._latlngs,this._rings,d),this._bounds.isValid()&&d.isValid()&&(this._rawPxBounds=d,this._updateBounds())},_updateBounds:function(){var d=this._clickTolerance(),y=new D(d,d);this._rawPxBounds&&(this._pxBounds=new B([this._rawPxBounds.min.subtract(y),this._rawPxBounds.max.add(y)]))},_projectLatlngs:function(d,y,E){var $=d[0]instanceof fe,Z=d.length,oe,me;if($){for(me=[],oe=0;oe<Z;oe++)me[oe]=this._map.latLngToLayerPoint(d[oe]),E.extend(me[oe]);y.push(me)}else for(oe=0;oe<Z;oe++)this._projectLatlngs(d[oe],y,E)},_clipPoints:function(){var d=this._renderer._bounds;if(this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(d))){if(this.options.noClip){this._parts=this._rings;return}var y=this._parts,E,$,Z,oe,me,Ae,Me;for(E=0,Z=0,oe=this._rings.length;E<oe;E++)for(Me=this._rings[E],$=0,me=Me.length;$<me-1;$++)Ae=kg(Me[$],Me[$+1],d,$,!0),Ae&&(y[Z]=y[Z]||[],y[Z].push(Ae[0]),(Ae[1]!==Me[$+1]||$===me-2)&&(y[Z].push(Ae[1]),Z++))}},_simplifyPoints:function(){for(var d=this._parts,y=this.options.smoothFactor,E=0,$=d.length;E<$;E++)d[E]=Ng(d[E],y)},_update:function(){this._map&&(this._clipPoints(),this._simplifyPoints(),this._updatePath())},_updatePath:function(){this._renderer._updatePoly(this)},_containsPoint:function(d,y){var E,$,Z,oe,me,Ae,Me=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(d))return!1;for(E=0,oe=this._parts.length;E<oe;E++)for(Ae=this._parts[E],$=0,me=Ae.length,Z=me-1;$<me;Z=$++)if(!(!y&&$===0)&&oh(d,Ae[Z],Ae[$])<=Me)return!0;return!1}});function aw(d,y){return new la(d,y)}la._flat=Dg;var Ds=la.extend({options:{fill:!0},isEmpty:function(){return!this._latlngs.length||!this._latlngs[0].length},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return Oc(this._defaultShape(),this._map.options.crs)},_convertLatLngs:function(d){var y=la.prototype._convertLatLngs.call(this,d),E=y.length;return E>=2&&y[0]instanceof fe&&y[0].equals(y[E-1])&&y.pop(),y},_setLatLngs:function(d){la.prototype._setLatLngs.call(this,d),tr(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return tr(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var d=this._renderer._bounds,y=this.options.weight,E=new D(y,y);if(d=new B(d.min.subtract(E),d.max.add(E)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(d))){if(this.options.noClip){this._parts=this._rings;return}for(var $=0,Z=this._rings.length,oe;$<Z;$++)oe=Mg(this._rings[$],d,!0),oe.length&&this._parts.push(oe)}},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(d){var y=!1,E,$,Z,oe,me,Ae,Me,qe;if(!this._pxBounds||!this._pxBounds.contains(d))return!1;for(oe=0,Me=this._parts.length;oe<Me;oe++)for(E=this._parts[oe],me=0,qe=E.length,Ae=qe-1;me<qe;Ae=me++)$=E[me],Z=E[Ae],$.y>d.y!=Z.y>d.y&&d.x<(Z.x-$.x)*(d.y-$.y)/(Z.y-$.y)+$.x&&(y=!y);return y||la.prototype._containsPoint.call(this,d,!0)}});function Lr(d,y){return new Ds(d,y)}var kr=Nr.extend({initialize:function(d,y){b(this,y),this._layers={},d&&this.addData(d)},addData:function(d){var y=O(d)?d:d.features,E,$,Z;if(y){for(E=0,$=y.length;E<$;E++)Z=y[E],(Z.geometries||Z.geometry||Z.features||Z.coordinates)&&this.addData(Z);return this}var oe=this.options;if(oe.filter&&!oe.filter(d))return this;var me=uu(d,oe);return me?(me.feature=Is(d),me.defaultOptions=me.options,this.resetStyle(me),oe.onEachFeature&&oe.onEachFeature(d,me),this.addLayer(me)):this},resetStyle:function(d){return d===void 0?this.eachLayer(this.resetStyle,this):(d.options=i({},d.defaultOptions),this._setLayerStyle(d,this.options.style),this)},setStyle:function(d){return this.eachLayer(function(y){this._setLayerStyle(y,d)},this)},_setLayerStyle:function(d,y){d.setStyle&&(typeof y=="function"&&(y=y(d.feature)),d.setStyle(y))}});function uu(d,y){var E=d.type==="Feature"?d.geometry:d,$=E?E.coordinates:null,Z=[],oe=y&&y.pointToLayer,me=y&&y.coordsToLatLng||Mc,Ae,Me,qe,Qe;if(!$&&!E)return null;switch(E.type){case"Point":return Ae=me($),dh(oe,d,Ae,y);case"MultiPoint":for(qe=0,Qe=$.length;qe<Qe;qe++)Ae=me($[qe]),Z.push(dh(oe,d,Ae,y));return new Nr(Z);case"LineString":case"MultiLineString":return Me=cu($,E.type==="LineString"?0:1,me),new la(Me,y);case"Polygon":case"MultiPolygon":return Me=cu($,E.type==="Polygon"?1:2,me),new Ds(Me,y);case"GeometryCollection":for(qe=0,Qe=E.geometries.length;qe<Qe;qe++){var rt=uu({geometry:E.geometries[qe],type:"Feature",properties:d.properties},y);rt&&Z.push(rt)}return new Nr(Z);case"FeatureCollection":for(qe=0,Qe=E.features.length;qe<Qe;qe++){var at=uu(E.features[qe],y);at&&Z.push(at)}return new Nr(Z);default:throw new Error("Invalid GeoJSON object.")}}function dh(d,y,E,$){return d?d(y,E):new ks(E,$&&$.markersInheritOptions&&$)}function Mc(d){return new fe(d[1],d[0],d[2])}function cu(d,y,E){for(var $=[],Z=0,oe=d.length,me;Z<oe;Z++)me=y?cu(d[Z],y-1,E):(E||Mc)(d[Z]),$.push(me);return $}function fu(d,y){return d=ce(d),d.alt!==void 0?[g(d.lng,y),g(d.lat,y),g(d.alt,y)]:[g(d.lng,y),g(d.lat,y)]}function Nc(d,y,E,$){for(var Z=[],oe=0,me=d.length;oe<me;oe++)Z.push(y?Nc(d[oe],tr(d[oe])?0:y-1,E,$):fu(d[oe],$));return!y&&E&&Z.length>0&&Z.push(Z[0].slice()),Z}function li(d,y){return d.feature?i({},d.feature,{geometry:y}):Is(y)}function Is(d){return d.type==="Feature"||d.type==="FeatureCollection"?d:{type:"Feature",properties:{},geometry:d}}var Mo={toGeoJSON:function(d){return li(this,{type:"Point",coordinates:fu(this.getLatLng(),d)})}};ks.include(Mo),fh.include(Mo),lu.include(Mo),la.include({toGeoJSON:function(d){var y=!tr(this._latlngs),E=Nc(this._latlngs,y?1:0,!1,d);return li(this,{type:(y?"Multi":"")+"LineString",coordinates:E})}}),Ds.include({toGeoJSON:function(d){var y=!tr(this._latlngs),E=y&&!tr(this._latlngs[0]),$=Nc(this._latlngs,E?2:y?1:0,!0,d);return y||($=[$]),li(this,{type:(E?"Multi":"")+"Polygon",coordinates:$})}}),Ro.include({toMultiPoint:function(d){var y=[];return this.eachLayer(function(E){y.push(E.toGeoJSON(d).geometry.coordinates)}),li(this,{type:"MultiPoint",coordinates:y})},toGeoJSON:function(d){var y=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(y==="MultiPoint")return this.toMultiPoint(d);var E=y==="GeometryCollection",$=[];return this.eachLayer(function(Z){if(Z.toGeoJSON){var oe=Z.toGeoJSON(d);if(E)$.push(oe.geometry);else{var me=Is(oe);me.type==="FeatureCollection"?$.push.apply($,me.features):$.push(me)}}}),E?li(this,{geometries:$,type:"GeometryCollection"}):{type:"FeatureCollection",features:$}}});function Lc(d,y){return new kr(d,y)}var Fg=Lc,Fi=si.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(d,y,E){this._url=d,this._bounds=ae(y),b(this,E)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(_t(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){nn(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(d){return this.options.opacity=d,this._image&&this._updateOpacity(),this},setStyle:function(d){return d.opacity&&this.setOpacity(d.opacity),this},bringToFront:function(){return this._map&&Co(this._image),this},bringToBack:function(){return this._map&&Ss(this._image),this},setUrl:function(d){return this._url=d,this._image&&(this._image.src=d),this},setBounds:function(d){return this._bounds=ae(d),this._map&&this._reset(),this},getEvents:function(){var d={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(d.zoomanim=this._animateZoom),d},setZIndex:function(d){return this.options.zIndex=d,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var d=this._url.tagName==="IMG",y=this._image=d?this._url:Nt("img");if(_t(y,"leaflet-image-layer"),this._zoomAnimated&&_t(y,"leaflet-zoom-animated"),this.options.className&&_t(y,this.options.className),y.onselectstart=m,y.onmousemove=m,y.onload=o(this.fire,this,"load"),y.onerror=o(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(y.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),d){this._url=y.src;return}y.src=this._url,y.alt=this.options.alt},_animateZoom:function(d){var y=this._map.getZoomScale(d.zoom),E=this._map._latLngBoundsToNewLayerBounds(this._bounds,d.zoom,d.center).min;Zr(this._image,E,y)},_reset:function(){var d=this._image,y=new B(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),E=y.getSize();_n(d,y.min),d.style.width=E.x+"px",d.style.height=E.y+"px"},_updateOpacity:function(){Ar(this._image,this.options.opacity)},_updateZIndex:function(){this._image&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._image.style.zIndex=this.options.zIndex)},_overlayOnError:function(){this.fire("error");var d=this.options.errorOverlayUrl;d&&this._url!==d&&(this._url=d,this._image.src=d)},getCenter:function(){return this._bounds.getCenter()}}),$s=function(d,y,E){return new Fi(d,y,E)},kc=Fi.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var d=this._url.tagName==="VIDEO",y=this._image=d?this._url:Nt("video");if(_t(y,"leaflet-image-layer"),this._zoomAnimated&&_t(y,"leaflet-zoom-animated"),this.options.className&&_t(y,this.options.className),y.onselectstart=m,y.onmousemove=m,y.onloadeddata=o(this.fire,this,"load"),d){for(var E=y.getElementsByTagName("source"),$=[],Z=0;Z<E.length;Z++)$.push(E[Z].src);this._url=E.length>0?$:[y.src];return}O(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(y.style,"objectFit")&&(y.style.objectFit="fill"),y.autoplay=!!this.options.autoplay,y.loop=!!this.options.loop,y.muted=!!this.options.muted,y.playsInline=!!this.options.playsInline;for(var oe=0;oe<this._url.length;oe++){var me=Nt("source");me.src=this._url[oe],y.appendChild(me)}}});function qg(d,y,E){return new kc(d,y,E)}var Ua=Fi.extend({_initImage:function(){var d=this._image=this._url;_t(d,"leaflet-image-layer"),this._zoomAnimated&&_t(d,"leaflet-zoom-animated"),this.options.className&&_t(d,this.options.className),d.onselectstart=m,d.onmousemove=m}});function Vg(d,y,E){return new Ua(d,y,E)}var ui=si.extend({options:{interactive:!1,offset:[0,0],className:"",pane:void 0,content:""},initialize:function(d,y){d&&(d instanceof fe||O(d))?(this._latlng=ce(d),b(this,y)):(b(this,d),this._source=y),this.options.content&&(this._content=this.options.content)},openOn:function(d){return d=arguments.length?d:this._source._map,d.hasLayer(this)||d.addLayer(this),this},close:function(){return this._map&&this._map.removeLayer(this),this},toggle:function(d){return this._map?this.close():(arguments.length?this._source=d:d=this._source,this._prepareOpen(),this.openOn(d._map)),this},onAdd:function(d){this._zoomAnimated=d._zoomAnimated,this._container||this._initLayout(),d._fadeAnimated&&Ar(this._container,0),clearTimeout(this._removeTimeout),this.getPane().appendChild(this._container),this.update(),d._fadeAnimated&&Ar(this._container,1),this.bringToFront(),this.options.interactive&&(_t(this._container,"leaflet-interactive"),this.addInteractiveTarget(this._container))},onRemove:function(d){d._fadeAnimated?(Ar(this._container,0),this._removeTimeout=setTimeout(o(nn,void 0,this._container),200)):nn(this._container),this.options.interactive&&(rn(this._container,"leaflet-interactive"),this.removeInteractiveTarget(this._container))},getLatLng:function(){return this._latlng},setLatLng:function(d){return this._latlng=ce(d),this._map&&(this._updatePosition(),this._adjustPan()),this},getContent:function(){return this._content},setContent:function(d){return this._content=d,this.update(),this},getElement:function(){return this._container},update:function(){this._map&&(this._container.style.visibility="hidden",this._updateContent(),this._updateLayout(),this._updatePosition(),this._container.style.visibility="",this._adjustPan())},getEvents:function(){var d={zoom:this._updatePosition,viewreset:this._updatePosition};return this._zoomAnimated&&(d.zoomanim=this._animateZoom),d},isOpen:function(){return!!this._map&&this._map.hasLayer(this)},bringToFront:function(){return this._map&&Co(this._container),this},bringToBack:function(){return this._map&&Ss(this._container),this},_prepareOpen:function(d){var y=this._source;if(!y._map)return!1;if(y instanceof Nr){y=null;var E=this._source._layers;for(var $ in E)if(E[$]._map){y=E[$];break}if(!y)return!1;this._source=y}if(!d)if(y.getCenter)d=y.getCenter();else if(y.getLatLng)d=y.getLatLng();else if(y.getBounds)d=y.getBounds().getCenter();else throw new Error("Unable to get source layer LatLng.");return this.setLatLng(d),this._map&&this.update(),!0},_updateContent:function(){if(this._content){var d=this._contentNode,y=typeof this._content=="function"?this._content(this._source||this):this._content;if(typeof y=="string")d.innerHTML=y;else{for(;d.hasChildNodes();)d.removeChild(d.firstChild);d.appendChild(y)}this.fire("contentupdate")}},_updatePosition:function(){if(this._map){var d=this._map.latLngToLayerPoint(this._latlng),y=N(this.options.offset),E=this._getAnchor();this._zoomAnimated?_n(this._container,d.add(E)):y=y.add(d).add(E);var $=this._containerBottom=-y.y,Z=this._containerLeft=-Math.round(this._containerWidth/2)+y.x;this._container.style.bottom=$+"px",this._container.style.left=Z+"px"}},_getAnchor:function(){return[0,0]}});Et.include({_initOverlay:function(d,y,E,$){var Z=y;return Z instanceof d||(Z=new d($).setContent(y)),E&&Z.setLatLng(E),Z}}),si.include({_initOverlay:function(d,y,E,$){var Z=E;return Z instanceof d?(b(Z,$),Z._source=this):(Z=y&&!$?y:new d($,this),Z.setContent(E)),Z}});var du=ui.extend({options:{pane:"popupPane",offset:[0,7],maxWidth:300,minWidth:50,maxHeight:null,autoPan:!0,autoPanPaddingTopLeft:null,autoPanPaddingBottomRight:null,autoPanPadding:[5,5],keepInView:!1,closeButton:!0,autoClose:!0,closeOnEscapeKey:!0,className:""},openOn:function(d){return d=arguments.length?d:this._source._map,!d.hasLayer(this)&&d._popup&&d._popup.options.autoClose&&d.removeLayer(d._popup),d._popup=this,ui.prototype.openOn.call(this,d)},onAdd:function(d){ui.prototype.onAdd.call(this,d),d.fire("popupopen",{popup:this}),this._source&&(this._source.fire("popupopen",{popup:this},!0),this._source instanceof sa||this._source.on("preclick",oa))},onRemove:function(d){ui.prototype.onRemove.call(this,d),d.fire("popupclose",{popup:this}),this._source&&(this._source.fire("popupclose",{popup:this},!0),this._source instanceof sa||this._source.off("preclick",oa))},getEvents:function(){var d=ui.prototype.getEvents.call(this);return(this.options.closeOnClick!==void 0?this.options.closeOnClick:this._map.options.closePopupOnClick)&&(d.preclick=this.close),this.options.keepInView&&(d.moveend=this._adjustPan),d},_initLayout:function(){var d="leaflet-popup",y=this._container=Nt("div",d+" "+(this.options.className||"")+" leaflet-zoom-animated"),E=this._wrapper=Nt("div",d+"-content-wrapper",y);if(this._contentNode=Nt("div",d+"-content",E),Ps(y),js(this._contentNode),bt(y,"contextmenu",oa),this._tipContainer=Nt("div",d+"-tip-container",y),this._tip=Nt("div",d+"-tip",this._tipContainer),this.options.closeButton){var $=this._closeButton=Nt("a",d+"-close-button",y);$.setAttribute("role","button"),$.setAttribute("aria-label","Close popup"),$.href="#close",$.innerHTML='<span aria-hidden="true">×</span>',bt($,"click",function(Z){An(Z),this.close()},this)}},_updateLayout:function(){var d=this._contentNode,y=d.style;y.width="",y.whiteSpace="nowrap";var E=d.offsetWidth;E=Math.min(E,this.options.maxWidth),E=Math.max(E,this.options.minWidth),y.width=E+1+"px",y.whiteSpace="",y.height="";var $=d.offsetHeight,Z=this.options.maxHeight,oe="leaflet-popup-scrolled";Z&&$>Z?(y.height=Z+"px",_t(d,oe)):rn(d,oe),this._containerWidth=this._container.offsetWidth},_animateZoom:function(d){var y=this._map._latLngToNewLayerPoint(this._latlng,d.zoom,d.center),E=this._getAnchor();_n(this._container,y.add(E))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var d=this._map,y=parseInt(So(this._container,"marginBottom"),10)||0,E=this._container.offsetHeight+y,$=this._containerWidth,Z=new D(this._containerLeft,-E-this._containerBottom);Z._add(Ia(this._container));var oe=d.layerPointToContainerPoint(Z),me=N(this.options.autoPanPadding),Ae=N(this.options.autoPanPaddingTopLeft||me),Me=N(this.options.autoPanPaddingBottomRight||me),qe=d.getSize(),Qe=0,rt=0;oe.x+$+Me.x>qe.x&&(Qe=oe.x+$-qe.x+Me.x),oe.x-Qe-Ae.x<0&&(Qe=oe.x-Ae.x),oe.y+E+Me.y>qe.y&&(rt=oe.y+E-qe.y+Me.y),oe.y-rt-Ae.y<0&&(rt=oe.y-Ae.y),(Qe||rt)&&(this.options.keepInView&&(this._autopanning=!0),d.fire("autopanstart").panBy([Qe,rt]))}},_getAnchor:function(){return N(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),ow=function(d,y){return new du(d,y)};Et.mergeOptions({closePopupOnClick:!0}),Et.include({openPopup:function(d,y,E){return this._initOverlay(du,d,y,E).openOn(this),this},closePopup:function(d){return d=arguments.length?d:this._popup,d&&d.close(),this}}),si.include({bindPopup:function(d,y){return this._popup=this._initOverlay(du,this._popup,d,y),this._popupHandlersAdded||(this.on({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!0),this},unbindPopup:function(){return this._popup&&(this.off({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!1,this._popup=null),this},openPopup:function(d){return this._popup&&(this instanceof Nr||(this._popup._source=this),this._popup._prepareOpen(d||this._latlng)&&this._popup.openOn(this._map)),this},closePopup:function(){return this._popup&&this._popup.close(),this},togglePopup:function(){return this._popup&&this._popup.toggle(this),this},isPopupOpen:function(){return this._popup?this._popup.isOpen():!1},setPopupContent:function(d){return this._popup&&this._popup.setContent(d),this},getPopup:function(){return this._popup},_openPopup:function(d){if(!(!this._popup||!this._map)){zi(d);var y=d.layer||d.target;if(this._popup._source===y&&!(y instanceof sa)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(d.latlng);return}this._popup._source=y,this.openPopup(d.latlng)}},_movePopup:function(d){this._popup.setLatLng(d.latlng)},_onKeyPress:function(d){d.originalEvent.keyCode===13&&this._openPopup(d)}});var Dc=ui.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(d){ui.prototype.onAdd.call(this,d),this.setOpacity(this.options.opacity),d.fire("tooltipopen",{tooltip:this}),this._source&&(this.addEventParent(this._source),this._source.fire("tooltipopen",{tooltip:this},!0))},onRemove:function(d){ui.prototype.onRemove.call(this,d),d.fire("tooltipclose",{tooltip:this}),this._source&&(this.removeEventParent(this._source),this._source.fire("tooltipclose",{tooltip:this},!0))},getEvents:function(){var d=ui.prototype.getEvents.call(this);return this.options.permanent||(d.preclick=this.close),d},_initLayout:function(){var d="leaflet-tooltip",y=d+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=Nt("div",y),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+f(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(d){var y,E,$=this._map,Z=this._container,oe=$.latLngToContainerPoint($.getCenter()),me=$.layerPointToContainerPoint(d),Ae=this.options.direction,Me=Z.offsetWidth,qe=Z.offsetHeight,Qe=N(this.options.offset),rt=this._getAnchor();Ae==="top"?(y=Me/2,E=qe):Ae==="bottom"?(y=Me/2,E=0):Ae==="center"?(y=Me/2,E=qe/2):Ae==="right"?(y=0,E=qe/2):Ae==="left"?(y=Me,E=qe/2):me.x<oe.x?(Ae="right",y=0,E=qe/2):(Ae="left",y=Me+(Qe.x+rt.x)*2,E=qe/2),d=d.subtract(N(y,E,!0)).add(Qe).add(rt),rn(Z,"leaflet-tooltip-right"),rn(Z,"leaflet-tooltip-left"),rn(Z,"leaflet-tooltip-top"),rn(Z,"leaflet-tooltip-bottom"),_t(Z,"leaflet-tooltip-"+Ae),_n(Z,d)},_updatePosition:function(){var d=this._map.latLngToLayerPoint(this._latlng);this._setPosition(d)},setOpacity:function(d){this.options.opacity=d,this._container&&Ar(this._container,d)},_animateZoom:function(d){var y=this._map._latLngToNewLayerPoint(this._latlng,d.zoom,d.center);this._setPosition(y)},_getAnchor:function(){return N(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),sw=function(d,y){return new Dc(d,y)};Et.include({openTooltip:function(d,y,E){return this._initOverlay(Dc,d,y,E).openOn(this),this},closeTooltip:function(d){return d.close(),this}}),si.include({bindTooltip:function(d,y){return this._tooltip&&this.isTooltipOpen()&&this.unbindTooltip(),this._tooltip=this._initOverlay(Dc,this._tooltip,d,y),this._initTooltipInteractions(),this._tooltip.options.permanent&&this._map&&this._map.hasLayer(this)&&this.openTooltip(),this},unbindTooltip:function(){return this._tooltip&&(this._initTooltipInteractions(!0),this.closeTooltip(),this._tooltip=null),this},_initTooltipInteractions:function(d){if(!(!d&&this._tooltipHandlersAdded)){var y=d?"off":"on",E={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?E.add=this._openTooltip:(E.mouseover=this._openTooltip,E.mouseout=this.closeTooltip,E.click=this._openTooltip,this._map?this._addFocusListeners():E.add=this._addFocusListeners),this._tooltip.options.sticky&&(E.mousemove=this._moveTooltip),this[y](E),this._tooltipHandlersAdded=!d}},openTooltip:function(d){return this._tooltip&&(this instanceof Nr||(this._tooltip._source=this),this._tooltip._prepareOpen(d)&&(this._tooltip.openOn(this._map),this.getElement?this._setAriaDescribedByOnLayer(this):this.eachLayer&&this.eachLayer(this._setAriaDescribedByOnLayer,this))),this},closeTooltip:function(){if(this._tooltip)return this._tooltip.close()},toggleTooltip:function(){return this._tooltip&&this._tooltip.toggle(this),this},isTooltipOpen:function(){return this._tooltip.isOpen()},setTooltipContent:function(d){return this._tooltip&&this._tooltip.setContent(d),this},getTooltip:function(){return this._tooltip},_addFocusListeners:function(){this.getElement?this._addFocusListenersOnLayer(this):this.eachLayer&&this.eachLayer(this._addFocusListenersOnLayer,this)},_addFocusListenersOnLayer:function(d){var y=typeof d.getElement=="function"&&d.getElement();y&&(bt(y,"focus",function(){this._tooltip._source=d,this.openTooltip()},this),bt(y,"blur",this.closeTooltip,this))},_setAriaDescribedByOnLayer:function(d){var y=typeof d.getElement=="function"&&d.getElement();y&&y.setAttribute("aria-describedby",this._tooltip._container.id)},_openTooltip:function(d){if(!(!this._tooltip||!this._map)){if(this._map.dragging&&this._map.dragging.moving()&&!this._openOnceFlag){this._openOnceFlag=!0;var y=this;this._map.once("moveend",function(){y._openOnceFlag=!1,y._openTooltip(d)});return}this._tooltip._source=d.layer||d.target,this.openTooltip(this._tooltip.options.sticky?d.latlng:void 0)}},_moveTooltip:function(d){var y=d.latlng,E,$;this._tooltip.options.sticky&&d.originalEvent&&(E=this._map.mouseEventToContainerPoint(d.originalEvent),$=this._map.containerPointToLayerPoint(E),y=this._map.layerPointToLatLng($)),this._tooltip.setLatLng(y)}});var hh=Ns.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(d){var y=d&&d.tagName==="DIV"?d:document.createElement("div"),E=this.options;if(E.html instanceof Element?(fr(y),y.appendChild(E.html)):y.innerHTML=E.html!==!1?E.html:"",E.bgPos){var $=N(E.bgPos);y.style.backgroundPosition=-$.x+"px "+-$.y+"px"}return this._setIconStyles(y,"icon"),y},createShadow:function(){return null}});function Hg(d){return new hh(d)}Ns.Default=Ls;var No=si.extend({options:{tileSize:256,opacity:1,updateWhenIdle:lt.mobile,updateWhenZooming:!0,updateInterval:200,zIndex:1,bounds:null,minZoom:0,maxZoom:void 0,maxNativeZoom:void 0,minNativeZoom:void 0,noWrap:!1,pane:"tilePane",className:"",keepBuffer:2},initialize:function(d){b(this,d)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView()},beforeAdd:function(d){d._addZoomLimit(this)},onRemove:function(d){this._removeAllTiles(),nn(this._container),d._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(Co(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(Ss(this._container),this._setAutoZIndex(Math.min)),this},getContainer:function(){return this._container},setOpacity:function(d){return this.options.opacity=d,this._updateOpacity(),this},setZIndex:function(d){return this.options.zIndex=d,this._updateZIndex(),this},isLoading:function(){return this._loading},redraw:function(){if(this._map){this._removeAllTiles();var d=this._clampZoom(this._map.getZoom());d!==this._tileZoom&&(this._tileZoom=d,this._updateLevels()),this._update()}return this},getEvents:function(){var d={viewprereset:this._invalidateAll,viewreset:this._resetView,zoom:this._resetView,moveend:this._onMoveEnd};return this.options.updateWhenIdle||(this._onMove||(this._onMove=u(this._onMoveEnd,this.options.updateInterval,this)),d.move=this._onMove),this._zoomAnimated&&(d.zoomanim=this._animateZoom),d},createTile:function(){return document.createElement("div")},getTileSize:function(){var d=this.options.tileSize;return d instanceof D?d:new D(d,d)},_updateZIndex:function(){this._container&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(d){for(var y=this.getPane().children,E=-d(-1/0,1/0),$=0,Z=y.length,oe;$<Z;$++)oe=y[$].style.zIndex,y[$]!==this._container&&oe&&(E=d(E,+oe));isFinite(E)&&(this.options.zIndex=E+d(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!lt.ielt9){Ar(this._container,this.options.opacity);var d=+new Date,y=!1,E=!1;for(var $ in this._tiles){var Z=this._tiles[$];if(!(!Z.current||!Z.loaded)){var oe=Math.min(1,(d-Z.loaded)/200);Ar(Z.el,oe),oe<1?y=!0:(Z.active?E=!0:this._onOpaqueTile(Z),Z.active=!0)}}E&&!this._noPrune&&this._pruneTiles(),y&&(ee(this._fadeFrame),this._fadeFrame=W(this._updateOpacity,this))}},_onOpaqueTile:m,_initContainer:function(){this._container||(this._container=Nt("div","leaflet-layer "+(this.options.className||"")),this._updateZIndex(),this.options.opacity<1&&this._updateOpacity(),this.getPane().appendChild(this._container))},_updateLevels:function(){var d=this._tileZoom,y=this.options.maxZoom;if(d!==void 0){for(var E in this._levels)E=Number(E),this._levels[E].el.children.length||E===d?(this._levels[E].el.style.zIndex=y-Math.abs(d-E),this._onUpdateLevel(E)):(nn(this._levels[E].el),this._removeTilesAtZoom(E),this._onRemoveLevel(E),delete this._levels[E]);var $=this._levels[d],Z=this._map;return $||($=this._levels[d]={},$.el=Nt("div","leaflet-tile-container leaflet-zoom-animated",this._container),$.el.style.zIndex=y,$.origin=Z.project(Z.unproject(Z.getPixelOrigin()),d).round(),$.zoom=d,this._setZoomTransform($,Z.getCenter(),Z.getZoom()),m($.el.offsetWidth),this._onCreateLevel($)),this._level=$,$}},_onUpdateLevel:m,_onRemoveLevel:m,_onCreateLevel:m,_pruneTiles:function(){if(this._map){var d,y,E=this._map.getZoom();if(E>this.options.maxZoom||E<this.options.minZoom){this._removeAllTiles();return}for(d in this._tiles)y=this._tiles[d],y.retain=y.current;for(d in this._tiles)if(y=this._tiles[d],y.current&&!y.active){var $=y.coords;this._retainParent($.x,$.y,$.z,$.z-5)||this._retainChildren($.x,$.y,$.z,$.z+2)}for(d in this._tiles)this._tiles[d].retain||this._removeTile(d)}},_removeTilesAtZoom:function(d){for(var y in this._tiles)this._tiles[y].coords.z===d&&this._removeTile(y)},_removeAllTiles:function(){for(var d in this._tiles)this._removeTile(d)},_invalidateAll:function(){for(var d in this._levels)nn(this._levels[d].el),this._onRemoveLevel(Number(d)),delete this._levels[d];this._removeAllTiles(),this._tileZoom=void 0},_retainParent:function(d,y,E,$){var Z=Math.floor(d/2),oe=Math.floor(y/2),me=E-1,Ae=new D(+Z,+oe);Ae.z=+me;var Me=this._tileCoordsToKey(Ae),qe=this._tiles[Me];return qe&&qe.active?(qe.retain=!0,!0):(qe&&qe.loaded&&(qe.retain=!0),me>$?this._retainParent(Z,oe,me,$):!1)},_retainChildren:function(d,y,E,$){for(var Z=2*d;Z<2*d+2;Z++)for(var oe=2*y;oe<2*y+2;oe++){var me=new D(Z,oe);me.z=E+1;var Ae=this._tileCoordsToKey(me),Me=this._tiles[Ae];if(Me&&Me.active){Me.retain=!0;continue}else Me&&Me.loaded&&(Me.retain=!0);E+1<$&&this._retainChildren(Z,oe,E+1,$)}},_resetView:function(d){var y=d&&(d.pinch||d.flyTo);this._setView(this._map.getCenter(),this._map.getZoom(),y,y)},_animateZoom:function(d){this._setView(d.center,d.zoom,!0,d.noUpdate)},_clampZoom:function(d){var y=this.options;return y.minNativeZoom!==void 0&&d<y.minNativeZoom?y.minNativeZoom:y.maxNativeZoom!==void 0&&y.maxNativeZoom<d?y.maxNativeZoom:d},_setView:function(d,y,E,$){var Z=Math.round(y);this.options.maxZoom!==void 0&&Z>this.options.maxZoom||this.options.minZoom!==void 0&&Z<this.options.minZoom?Z=void 0:Z=this._clampZoom(Z);var oe=this.options.updateWhenZooming&&Z!==this._tileZoom;(!$||oe)&&(this._tileZoom=Z,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),Z!==void 0&&this._update(d),E||this._pruneTiles(),this._noPrune=!!E),this._setZoomTransforms(d,y)},_setZoomTransforms:function(d,y){for(var E in this._levels)this._setZoomTransform(this._levels[E],d,y)},_setZoomTransform:function(d,y,E){var $=this._map.getZoomScale(E,d.zoom),Z=d.origin.multiplyBy($).subtract(this._map._getNewPixelOrigin(y,E)).round();lt.any3d?Zr(d.el,Z,$):_n(d.el,Z)},_resetGrid:function(){var d=this._map,y=d.options.crs,E=this._tileSize=this.getTileSize(),$=this._tileZoom,Z=this._map.getPixelWorldBounds(this._tileZoom);Z&&(this._globalTileRange=this._pxBoundsToTileRange(Z)),this._wrapX=y.wrapLng&&!this.options.noWrap&&[Math.floor(d.project([0,y.wrapLng[0]],$).x/E.x),Math.ceil(d.project([0,y.wrapLng[1]],$).x/E.y)],this._wrapY=y.wrapLat&&!this.options.noWrap&&[Math.floor(d.project([y.wrapLat[0],0],$).y/E.x),Math.ceil(d.project([y.wrapLat[1],0],$).y/E.y)]},_onMoveEnd:function(){!this._map||this._map._animatingZoom||this._update()},_getTiledPixelBounds:function(d){var y=this._map,E=y._animatingZoom?Math.max(y._animateToZoom,y.getZoom()):y.getZoom(),$=y.getZoomScale(E,this._tileZoom),Z=y.project(d,this._tileZoom).floor(),oe=y.getSize().divideBy($*2);return new B(Z.subtract(oe),Z.add(oe))},_update:function(d){var y=this._map;if(y){var E=this._clampZoom(y.getZoom());if(d===void 0&&(d=y.getCenter()),this._tileZoom!==void 0){var $=this._getTiledPixelBounds(d),Z=this._pxBoundsToTileRange($),oe=Z.getCenter(),me=[],Ae=this.options.keepBuffer,Me=new B(Z.getBottomLeft().subtract([Ae,-Ae]),Z.getTopRight().add([Ae,-Ae]));if(!(isFinite(Z.min.x)&&isFinite(Z.min.y)&&isFinite(Z.max.x)&&isFinite(Z.max.y)))throw new Error("Attempted to load an infinite number of tiles");for(var qe in this._tiles){var Qe=this._tiles[qe].coords;(Qe.z!==this._tileZoom||!Me.contains(new D(Qe.x,Qe.y)))&&(this._tiles[qe].current=!1)}if(Math.abs(E-this._tileZoom)>1){this._setView(d,E);return}for(var rt=Z.min.y;rt<=Z.max.y;rt++)for(var at=Z.min.x;at<=Z.max.x;at++){var yt=new D(at,rt);if(yt.z=this._tileZoom,!!this._isValidTile(yt)){var an=this._tiles[this._tileCoordsToKey(yt)];an?an.current=!0:me.push(yt)}}if(me.sort(function(nr,Xr){return nr.distanceTo(oe)-Xr.distanceTo(oe)}),me.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var xn=document.createDocumentFragment();for(at=0;at<me.length;at++)this._addTile(me[at],xn);this._level.el.appendChild(xn)}}}},_isValidTile:function(d){var y=this._map.options.crs;if(!y.infinite){var E=this._globalTileRange;if(!y.wrapLng&&(d.x<E.min.x||d.x>E.max.x)||!y.wrapLat&&(d.y<E.min.y||d.y>E.max.y))return!1}if(!this.options.bounds)return!0;var $=this._tileCoordsToBounds(d);return ae(this.options.bounds).overlaps($)},_keyToBounds:function(d){return this._tileCoordsToBounds(this._keyToTileCoords(d))},_tileCoordsToNwSe:function(d){var y=this._map,E=this.getTileSize(),$=d.scaleBy(E),Z=$.add(E),oe=y.unproject($,d.z),me=y.unproject(Z,d.z);return[oe,me]},_tileCoordsToBounds:function(d){var y=this._tileCoordsToNwSe(d),E=new G(y[0],y[1]);return this.options.noWrap||(E=this._map.wrapLatLngBounds(E)),E},_tileCoordsToKey:function(d){return d.x+":"+d.y+":"+d.z},_keyToTileCoords:function(d){var y=d.split(":"),E=new D(+y[0],+y[1]);return E.z=+y[2],E},_removeTile:function(d){var y=this._tiles[d];y&&(nn(y.el),delete this._tiles[d],this.fire("tileunload",{tile:y.el,coords:this._keyToTileCoords(d)}))},_initTile:function(d){_t(d,"leaflet-tile");var y=this.getTileSize();d.style.width=y.x+"px",d.style.height=y.y+"px",d.onselectstart=m,d.onmousemove=m,lt.ielt9&&this.options.opacity<1&&Ar(d,this.options.opacity)},_addTile:function(d,y){var E=this._getTilePos(d),$=this._tileCoordsToKey(d),Z=this.createTile(this._wrapCoords(d),o(this._tileReady,this,d));this._initTile(Z),this.createTile.length<2&&W(o(this._tileReady,this,d,null,Z)),_n(Z,E),this._tiles[$]={el:Z,coords:d,current:!0},y.appendChild(Z),this.fire("tileloadstart",{tile:Z,coords:d})},_tileReady:function(d,y,E){y&&this.fire("tileerror",{error:y,tile:E,coords:d});var $=this._tileCoordsToKey(d);E=this._tiles[$],E&&(E.loaded=+new Date,this._map._fadeAnimated?(Ar(E.el,0),ee(this._fadeFrame),this._fadeFrame=W(this._updateOpacity,this)):(E.active=!0,this._pruneTiles()),y||(_t(E.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:E.el,coords:d})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),lt.ielt9||!this._map._fadeAnimated?W(this._pruneTiles,this):setTimeout(o(this._pruneTiles,this),250)))},_getTilePos:function(d){return d.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(d){var y=new D(this._wrapX?h(d.x,this._wrapX):d.x,this._wrapY?h(d.y,this._wrapY):d.y);return y.z=d.z,y},_pxBoundsToTileRange:function(d){var y=this.getTileSize();return new B(d.min.unscaleBy(y).floor(),d.max.unscaleBy(y).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var d in this._tiles)if(!this._tiles[d].loaded)return!1;return!0}});function ci(d){return new No(d)}var Lo=No.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1,referrerPolicy:!1},initialize:function(d,y){this._url=d,y=b(this,y),y.detectRetina&<.retina&&y.maxZoom>0?(y.tileSize=Math.floor(y.tileSize/2),y.zoomReverse?(y.zoomOffset--,y.minZoom=Math.min(y.maxZoom,y.minZoom+1)):(y.zoomOffset++,y.maxZoom=Math.max(y.minZoom,y.maxZoom-1)),y.minZoom=Math.max(0,y.minZoom)):y.zoomReverse?y.minZoom=Math.min(y.maxZoom,y.minZoom):y.maxZoom=Math.max(y.minZoom,y.maxZoom),typeof y.subdomains=="string"&&(y.subdomains=y.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(d,y){return this._url===d&&y===void 0&&(y=!0),this._url=d,y||this.redraw(),this},createTile:function(d,y){var E=document.createElement("img");return bt(E,"load",o(this._tileOnLoad,this,y,E)),bt(E,"error",o(this._tileOnError,this,y,E)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(E.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(E.referrerPolicy=this.options.referrerPolicy),E.alt="",E.src=this.getTileUrl(d),E},getTileUrl:function(d){var y={r:lt.retina?"@2x":"",s:this._getSubdomain(d),x:d.x,y:d.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var E=this._globalTileRange.max.y-d.y;this.options.tms&&(y.y=E),y["-y"]=E}return A(this._url,i(y,this.options))},_tileOnLoad:function(d,y){lt.ielt9?setTimeout(o(d,this,null,y),0):d(null,y)},_tileOnError:function(d,y,E){var $=this.options.errorTileUrl;$&&y.getAttribute("src")!==$&&(y.src=$),d(E,y)},_onTileRemove:function(d){d.tile.onload=null},_getZoomForUrl:function(){var d=this._tileZoom,y=this.options.maxZoom,E=this.options.zoomReverse,$=this.options.zoomOffset;return E&&(d=y-d),d+$},_getSubdomain:function(d){var y=Math.abs(d.x+d.y)%this.options.subdomains.length;return this.options.subdomains[y]},_abortLoading:function(){var d,y;for(d in this._tiles)if(this._tiles[d].coords.z!==this._tileZoom&&(y=this._tiles[d].el,y.onload=m,y.onerror=m,!y.complete)){y.src=j;var E=this._tiles[d].coords;nn(y),delete this._tiles[d],this.fire("tileabort",{tile:y,coords:E})}},_removeTile:function(d){var y=this._tiles[d];if(y)return y.el.setAttribute("src",j),No.prototype._removeTile.call(this,d)},_tileReady:function(d,y,E){if(!(!this._map||E&&E.getAttribute("src")===j))return No.prototype._tileReady.call(this,d,y,E)}});function Dr(d,y){return new Lo(d,y)}var Ir=Lo.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(d,y){this._url=d;var E=i({},this.defaultWmsParams);for(var $ in y)$ in this.options||(E[$]=y[$]);y=b(this,y);var Z=y.detectRetina&<.retina?2:1,oe=this.getTileSize();E.width=oe.x*Z,E.height=oe.y*Z,this.wmsParams=E},onAdd:function(d){this._crs=this.options.crs||d.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var y=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[y]=this._crs.code,Lo.prototype.onAdd.call(this,d)},getTileUrl:function(d){var y=this._tileCoordsToNwSe(d),E=this._crs,$=Q(E.project(y[0]),E.project(y[1])),Z=$.min,oe=$.max,me=(this._wmsVersion>=1.3&&this._crs===Bg?[Z.y,Z.x,oe.y,oe.x]:[Z.x,Z.y,oe.x,oe.y]).join(","),Ae=Lo.prototype.getTileUrl.call(this,d);return Ae+S(this.wmsParams,Ae,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+me},setParams:function(d,y){return i(this.wmsParams,d),y||this.redraw(),this}});function Bs(d,y){return new Ir(d,y)}Lo.WMS=Ir,Dr.wms=Bs;var fi=si.extend({options:{padding:.1},initialize:function(d){b(this,d),f(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),_t(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var d={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(d.zoomanim=this._onAnimZoom),d},_onAnimZoom:function(d){this._updateTransform(d.center,d.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(d,y){var E=this._map.getZoomScale(y,this._zoom),$=this._map.getSize().multiplyBy(.5+this.options.padding),Z=this._map.project(this._center,y),oe=$.multiplyBy(-E).add(Z).subtract(this._map._getNewPixelOrigin(d,y));lt.any3d?Zr(this._container,oe,E):_n(this._container,oe)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var d in this._layers)this._layers[d]._reset()},_onZoomEnd:function(){for(var d in this._layers)this._layers[d]._project()},_updatePaths:function(){for(var d in this._layers)this._layers[d]._update()},_update:function(){var d=this.options.padding,y=this._map.getSize(),E=this._map.containerPointToLayerPoint(y.multiplyBy(-d)).round();this._bounds=new B(E,E.add(y.multiplyBy(1+d*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),hu=fi.extend({options:{tolerance:0},getEvents:function(){var d=fi.prototype.getEvents.call(this);return d.viewprereset=this._onViewPreReset,d},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){fi.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var d=this._container=document.createElement("canvas");bt(d,"mousemove",this._onMouseMove,this),bt(d,"click dblclick mousedown mouseup contextmenu",this._onClick,this),bt(d,"mouseout",this._handleMouseOut,this),d._leaflet_disable_events=!0,this._ctx=d.getContext("2d")},_destroyContainer:function(){ee(this._redrawRequest),delete this._ctx,nn(this._container),$t(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var d;this._redrawBounds=null;for(var y in this._layers)d=this._layers[y],d._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){fi.prototype._update.call(this);var d=this._bounds,y=this._container,E=d.getSize(),$=lt.retina?2:1;_n(y,d.min),y.width=$*E.x,y.height=$*E.y,y.style.width=E.x+"px",y.style.height=E.y+"px",lt.retina&&this._ctx.scale(2,2),this._ctx.translate(-d.min.x,-d.min.y),this.fire("update")}},_reset:function(){fi.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(d){this._updateDashArray(d),this._layers[f(d)]=d;var y=d._order={layer:d,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=y),this._drawLast=y,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(d){this._requestRedraw(d)},_removePath:function(d){var y=d._order,E=y.next,$=y.prev;E?E.prev=$:this._drawLast=$,$?$.next=E:this._drawFirst=E,delete d._order,delete this._layers[f(d)],this._requestRedraw(d)},_updatePath:function(d){this._extendRedrawBounds(d),d._project(),d._update(),this._requestRedraw(d)},_updateStyle:function(d){this._updateDashArray(d),this._requestRedraw(d)},_updateDashArray:function(d){if(typeof d.options.dashArray=="string"){var y=d.options.dashArray.split(/[, ]+/),E=[],$,Z;for(Z=0;Z<y.length;Z++){if($=Number(y[Z]),isNaN($))return;E.push($)}d.options._dashArray=E}else d.options._dashArray=d.options.dashArray},_requestRedraw:function(d){this._map&&(this._extendRedrawBounds(d),this._redrawRequest=this._redrawRequest||W(this._redraw,this))},_extendRedrawBounds:function(d){if(d._pxBounds){var y=(d.options.weight||0)+1;this._redrawBounds=this._redrawBounds||new B,this._redrawBounds.extend(d._pxBounds.min.subtract([y,y])),this._redrawBounds.extend(d._pxBounds.max.add([y,y]))}},_redraw:function(){this._redrawRequest=null,this._redrawBounds&&(this._redrawBounds.min._floor(),this._redrawBounds.max._ceil()),this._clear(),this._draw(),this._redrawBounds=null},_clear:function(){var d=this._redrawBounds;if(d){var y=d.getSize();this._ctx.clearRect(d.min.x,d.min.y,y.x,y.y)}else this._ctx.save(),this._ctx.setTransform(1,0,0,1,0,0),this._ctx.clearRect(0,0,this._container.width,this._container.height),this._ctx.restore()},_draw:function(){var d,y=this._redrawBounds;if(this._ctx.save(),y){var E=y.getSize();this._ctx.beginPath(),this._ctx.rect(y.min.x,y.min.y,E.x,E.y),this._ctx.clip()}this._drawing=!0;for(var $=this._drawFirst;$;$=$.next)d=$.layer,(!y||d._pxBounds&&d._pxBounds.intersects(y))&&d._updatePath();this._drawing=!1,this._ctx.restore()},_updatePoly:function(d,y){if(this._drawing){var E,$,Z,oe,me=d._parts,Ae=me.length,Me=this._ctx;if(Ae){for(Me.beginPath(),E=0;E<Ae;E++){for($=0,Z=me[E].length;$<Z;$++)oe=me[E][$],Me[$?"lineTo":"moveTo"](oe.x,oe.y);y&&Me.closePath()}this._fillStroke(Me,d)}}},_updateCircle:function(d){if(!(!this._drawing||d._empty())){var y=d._point,E=this._ctx,$=Math.max(Math.round(d._radius),1),Z=(Math.max(Math.round(d._radiusY),1)||$)/$;Z!==1&&(E.save(),E.scale(1,Z)),E.beginPath(),E.arc(y.x,y.y/Z,$,0,Math.PI*2,!1),Z!==1&&E.restore(),this._fillStroke(E,d)}},_fillStroke:function(d,y){var E=y.options;E.fill&&(d.globalAlpha=E.fillOpacity,d.fillStyle=E.fillColor||E.color,d.fill(E.fillRule||"evenodd")),E.stroke&&E.weight!==0&&(d.setLineDash&&d.setLineDash(y.options&&y.options._dashArray||[]),d.globalAlpha=E.opacity,d.lineWidth=E.weight,d.strokeStyle=E.color,d.lineCap=E.lineCap,d.lineJoin=E.lineJoin,d.stroke())},_onClick:function(d){for(var y=this._map.mouseEventToLayerPoint(d),E,$,Z=this._drawFirst;Z;Z=Z.next)E=Z.layer,E.options.interactive&&E._containsPoint(y)&&(!(d.type==="click"||d.type==="preclick")||!this._map._draggableMoved(E))&&($=E);this._fireEvent($?[$]:!1,d)},_onMouseMove:function(d){if(!(!this._map||this._map.dragging.moving()||this._map._animatingZoom)){var y=this._map.mouseEventToLayerPoint(d);this._handleMouseHover(d,y)}},_handleMouseOut:function(d){var y=this._hoveredLayer;y&&(rn(this._container,"leaflet-interactive"),this._fireEvent([y],d,"mouseout"),this._hoveredLayer=null,this._mouseHoverThrottled=!1)},_handleMouseHover:function(d,y){if(!this._mouseHoverThrottled){for(var E,$,Z=this._drawFirst;Z;Z=Z.next)E=Z.layer,E.options.interactive&&E._containsPoint(y)&&($=E);$!==this._hoveredLayer&&(this._handleMouseOut(d),$&&(_t(this._container,"leaflet-interactive"),this._fireEvent([$],d,"mouseover"),this._hoveredLayer=$)),this._fireEvent(this._hoveredLayer?[this._hoveredLayer]:!1,d),this._mouseHoverThrottled=!0,setTimeout(o(function(){this._mouseHoverThrottled=!1},this),32)}},_fireEvent:function(d,y,E){this._map._fireDOMEvent(y,E||y.type,d)},_bringToFront:function(d){var y=d._order;if(y){var E=y.next,$=y.prev;if(E)E.prev=$;else return;$?$.next=E:E&&(this._drawFirst=E),y.prev=this._drawLast,this._drawLast.next=y,y.next=null,this._drawLast=y,this._requestRedraw(d)}},_bringToBack:function(d){var y=d._order;if(y){var E=y.next,$=y.prev;if($)$.next=E;else return;E?E.prev=$:$&&(this._drawLast=$),y.prev=null,y.next=this._drawFirst,this._drawFirst.prev=y,this._drawFirst=y,this._requestRedraw(d)}}});function pu(d){return lt.canvas?new hu(d):null}var ko=function(){try{return document.namespaces.add("lvml","urn:schemas-microsoft-com:vml"),function(d){return document.createElement("<lvml:"+d+' class="lvml">')}}catch{}return function(d){return document.createElement("<"+d+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),Us={_initContainer:function(){this._container=Nt("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(fi.prototype._update.call(this),this.fire("update"))},_initPath:function(d){var y=d._container=ko("shape");_t(y,"leaflet-vml-shape "+(this.options.className||"")),y.coordsize="1 1",d._path=ko("path"),y.appendChild(d._path),this._updateStyle(d),this._layers[f(d)]=d},_addPath:function(d){var y=d._container;this._container.appendChild(y),d.options.interactive&&d.addInteractiveTarget(y)},_removePath:function(d){var y=d._container;nn(y),d.removeInteractiveTarget(y),delete this._layers[f(d)]},_updateStyle:function(d){var y=d._stroke,E=d._fill,$=d.options,Z=d._container;Z.stroked=!!$.stroke,Z.filled=!!$.fill,$.stroke?(y||(y=d._stroke=ko("stroke")),Z.appendChild(y),y.weight=$.weight+"px",y.color=$.color,y.opacity=$.opacity,$.dashArray?y.dashStyle=O($.dashArray)?$.dashArray.join(" "):$.dashArray.replace(/( *, *)/g," "):y.dashStyle="",y.endcap=$.lineCap.replace("butt","flat"),y.joinstyle=$.lineJoin):y&&(Z.removeChild(y),d._stroke=null),$.fill?(E||(E=d._fill=ko("fill")),Z.appendChild(E),E.color=$.fillColor||$.color,E.opacity=$.fillOpacity):E&&(Z.removeChild(E),d._fill=null)},_updateCircle:function(d){var y=d._point.round(),E=Math.round(d._radius),$=Math.round(d._radiusY||E);this._setPath(d,d._empty()?"M0 0":"AL "+y.x+","+y.y+" "+E+","+$+" 0,"+65535*360)},_setPath:function(d,y){d._path.v=y},_bringToFront:function(d){Co(d._container)},_bringToBack:function(d){Ss(d._container)}},mu=lt.vml?ko:ve,za=fi.extend({_initContainer:function(){this._container=mu("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=mu("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){nn(this._container),$t(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){fi.prototype._update.call(this);var d=this._bounds,y=d.getSize(),E=this._container;(!this._svgSize||!this._svgSize.equals(y))&&(this._svgSize=y,E.setAttribute("width",y.x),E.setAttribute("height",y.y)),_n(E,d.min),E.setAttribute("viewBox",[d.min.x,d.min.y,y.x,y.y].join(" ")),this.fire("update")}},_initPath:function(d){var y=d._path=mu("path");d.options.className&&_t(y,d.options.className),d.options.interactive&&_t(y,"leaflet-interactive"),this._updateStyle(d),this._layers[f(d)]=d},_addPath:function(d){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(d._path),d.addInteractiveTarget(d._path)},_removePath:function(d){nn(d._path),d.removeInteractiveTarget(d._path),delete this._layers[f(d)]},_updatePath:function(d){d._project(),d._update()},_updateStyle:function(d){var y=d._path,E=d.options;y&&(E.stroke?(y.setAttribute("stroke",E.color),y.setAttribute("stroke-opacity",E.opacity),y.setAttribute("stroke-width",E.weight),y.setAttribute("stroke-linecap",E.lineCap),y.setAttribute("stroke-linejoin",E.lineJoin),E.dashArray?y.setAttribute("stroke-dasharray",E.dashArray):y.removeAttribute("stroke-dasharray"),E.dashOffset?y.setAttribute("stroke-dashoffset",E.dashOffset):y.removeAttribute("stroke-dashoffset")):y.setAttribute("stroke","none"),E.fill?(y.setAttribute("fill",E.fillColor||E.color),y.setAttribute("fill-opacity",E.fillOpacity),y.setAttribute("fill-rule",E.fillRule||"evenodd")):y.setAttribute("fill","none"))},_updatePoly:function(d,y){this._setPath(d,he(d._parts,y))},_updateCircle:function(d){var y=d._point,E=Math.max(Math.round(d._radius),1),$=Math.max(Math.round(d._radiusY),1)||E,Z="a"+E+","+$+" 0 1,0 ",oe=d._empty()?"M0 0":"M"+(y.x-E)+","+y.y+Z+E*2+",0 "+Z+-E*2+",0 ";this._setPath(d,oe)},_setPath:function(d,y){d._path.setAttribute("d",y)},_bringToFront:function(d){Co(d._path)},_bringToBack:function(d){Ss(d._path)}});lt.vml&&za.include(Us);function Do(d){return lt.svg||lt.vml?new za(d):null}Et.include({getRenderer:function(d){var y=d.options.renderer||this._getPaneRenderer(d.options.pane)||this.options.renderer||this._renderer;return y||(y=this._renderer=this._createRenderer()),this.hasLayer(y)||this.addLayer(y),y},_getPaneRenderer:function(d){if(d==="overlayPane"||d===void 0)return!1;var y=this._paneRenderers[d];return y===void 0&&(y=this._createRenderer({pane:d}),this._paneRenderers[d]=y),y},_createRenderer:function(d){return this.options.preferCanvas&&pu(d)||Do(d)}});var Gg=Ds.extend({initialize:function(d,y){Ds.prototype.initialize.call(this,this._boundsToLatLngs(d),y)},setBounds:function(d){return this.setLatLngs(this._boundsToLatLngs(d))},_boundsToLatLngs:function(d){return d=ae(d),[d.getSouthWest(),d.getNorthWest(),d.getNorthEast(),d.getSouthEast()]}});function $r(d,y){return new Gg(d,y)}za.create=mu,za.pointsToPath=he,kr.geometryToLayer=uu,kr.coordsToLatLng=Mc,kr.coordsToLatLngs=cu,kr.latLngToCoords=fu,kr.latLngsToCoords=Nc,kr.getFeature=li,kr.asFeature=Is,Et.mergeOptions({boxZoom:!0});var Ic=oi.extend({initialize:function(d){this._map=d,this._container=d._container,this._pane=d._panes.overlayPane,this._resetStateTimeout=0,d.on("unload",this._destroy,this)},addHooks:function(){bt(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){$t(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){nn(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){this._resetStateTimeout!==0&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(d){if(!d.shiftKey||d.which!==1&&d.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),$i(),nu(),this._startPoint=this._map.mouseEventToContainerPoint(d),bt(document,{contextmenu:zi,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(d){this._moved||(this._moved=!0,this._box=Nt("div","leaflet-zoom-box",this._container),_t(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(d);var y=new B(this._point,this._startPoint),E=y.getSize();_n(this._box,y.min),this._box.style.width=E.x+"px",this._box.style.height=E.y+"px"},_finish:function(){this._moved&&(nn(this._box),rn(this._container,"leaflet-crosshair")),tu(),eh(),$t(document,{contextmenu:zi,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(d){if(!(d.which!==1&&d.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(o(this._resetState,this),0);var y=new G(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(y).fire("boxzoomend",{boxZoomBounds:y})}},_onKeyDown:function(d){d.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});Et.addInitHook("addHandler","boxZoom",Ic),Et.mergeOptions({doubleClickZoom:!0});var qi=oi.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(d){var y=this._map,E=y.getZoom(),$=y.options.zoomDelta,Z=d.originalEvent.shiftKey?E-$:E+$;y.options.doubleClickZoom==="center"?y.setZoom(Z):y.setZoomAround(d.containerPoint,Z)}});Et.addInitHook("addHandler","doubleClickZoom",qi),Et.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var ph=oi.extend({addHooks:function(){if(!this._draggable){var d=this._map;this._draggable=new Ba(d._mapPane,d._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),d.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),d.on("zoomend",this._onZoomEnd,this),d.whenReady(this._onZoomEnd,this))}_t(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){rn(this._map._container,"leaflet-grab"),rn(this._map._container,"leaflet-touch-drag"),this._draggable.disable()},moved:function(){return this._draggable&&this._draggable._moved},moving:function(){return this._draggable&&this._draggable._moving},_onDragStart:function(){var d=this._map;if(d._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var y=ae(this._map.options.maxBounds);this._offsetLimit=Q(this._map.latLngToContainerPoint(y.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(y.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;d.fire("movestart").fire("dragstart"),d.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(d){if(this._map.options.inertia){var y=this._lastTime=+new Date,E=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(E),this._times.push(y),this._prunePositions(y)}this._map.fire("move",d).fire("drag",d)},_prunePositions:function(d){for(;this._positions.length>1&&d-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var d=this._map.getSize().divideBy(2),y=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=y.subtract(d).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(d,y){return d-(d-y)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var d=this._draggable._newPos.subtract(this._draggable._startPos),y=this._offsetLimit;d.x<y.min.x&&(d.x=this._viscousLimit(d.x,y.min.x)),d.y<y.min.y&&(d.y=this._viscousLimit(d.y,y.min.y)),d.x>y.max.x&&(d.x=this._viscousLimit(d.x,y.max.x)),d.y>y.max.y&&(d.y=this._viscousLimit(d.y,y.max.y)),this._draggable._newPos=this._draggable._startPos.add(d)}},_onPreDragWrap:function(){var d=this._worldWidth,y=Math.round(d/2),E=this._initialWorldOffset,$=this._draggable._newPos.x,Z=($-y+E)%d+y-E,oe=($+y+E)%d-y-E,me=Math.abs(Z+E)<Math.abs(oe+E)?Z:oe;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=me},_onDragEnd:function(d){var y=this._map,E=y.options,$=!E.inertia||d.noInertia||this._times.length<2;if(y.fire("dragend",d),$)y.fire("moveend");else{this._prunePositions(+new Date);var Z=this._lastPos.subtract(this._positions[0]),oe=(this._lastTime-this._times[0])/1e3,me=E.easeLinearity,Ae=Z.multiplyBy(me/oe),Me=Ae.distanceTo([0,0]),qe=Math.min(E.inertiaMaxSpeed,Me),Qe=Ae.multiplyBy(qe/Me),rt=qe/(E.inertiaDeceleration*me),at=Qe.multiplyBy(-rt/2).round();!at.x&&!at.y?y.fire("moveend"):(at=y._limitOffset(at,y.options.maxBounds),W(function(){y.panBy(at,{duration:rt,easeLinearity:me,noMoveStart:!0,animate:!0})}))}}});Et.addInitHook("addHandler","dragging",ph),Et.mergeOptions({keyboard:!0,keyboardPanDelta:80});var gu=oi.extend({keyCodes:{left:[37],right:[39],down:[40],up:[38],zoomIn:[187,107,61,171],zoomOut:[189,109,54,173]},initialize:function(d){this._map=d,this._setPanDelta(d.options.keyboardPanDelta),this._setZoomDelta(d.options.zoomDelta)},addHooks:function(){var d=this._map._container;d.tabIndex<=0&&(d.tabIndex="0"),bt(d,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.on({focus:this._addHooks,blur:this._removeHooks},this)},removeHooks:function(){this._removeHooks(),$t(this._map._container,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.off({focus:this._addHooks,blur:this._removeHooks},this)},_onMouseDown:function(){if(!this._focused){var d=document.body,y=document.documentElement,E=d.scrollTop||y.scrollTop,$=d.scrollLeft||y.scrollLeft;this._map._container.focus(),window.scrollTo($,E)}},_onFocus:function(){this._focused=!0,this._map.fire("focus")},_onBlur:function(){this._focused=!1,this._map.fire("blur")},_setPanDelta:function(d){var y=this._panKeys={},E=this.keyCodes,$,Z;for($=0,Z=E.left.length;$<Z;$++)y[E.left[$]]=[-1*d,0];for($=0,Z=E.right.length;$<Z;$++)y[E.right[$]]=[d,0];for($=0,Z=E.down.length;$<Z;$++)y[E.down[$]]=[0,d];for($=0,Z=E.up.length;$<Z;$++)y[E.up[$]]=[0,-1*d]},_setZoomDelta:function(d){var y=this._zoomKeys={},E=this.keyCodes,$,Z;for($=0,Z=E.zoomIn.length;$<Z;$++)y[E.zoomIn[$]]=d;for($=0,Z=E.zoomOut.length;$<Z;$++)y[E.zoomOut[$]]=-d},_addHooks:function(){bt(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){$t(document,"keydown",this._onKeyDown,this)},_onKeyDown:function(d){if(!(d.altKey||d.ctrlKey||d.metaKey)){var y=d.keyCode,E=this._map,$;if(y in this._panKeys){if(!E._panAnim||!E._panAnim._inProgress)if($=this._panKeys[y],d.shiftKey&&($=N($).multiplyBy(3)),E.options.maxBounds&&($=E._limitOffset(N($),E.options.maxBounds)),E.options.worldCopyJump){var Z=E.wrapLatLng(E.unproject(E.project(E.getCenter()).add($)));E.panTo(Z)}else E.panBy($)}else if(y in this._zoomKeys)E.setZoom(E.getZoom()+(d.shiftKey?3:1)*this._zoomKeys[y]);else if(y===27&&E._popup&&E._popup.options.closeOnEscapeKey)E.closePopup();else return;zi(d)}}});Et.addInitHook("addHandler","keyboard",gu),Et.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var Fa=oi.extend({addHooks:function(){bt(this._map._container,"wheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){$t(this._map._container,"wheel",this._onWheelScroll,this)},_onWheelScroll:function(d){var y=au(d),E=this._map.options.wheelDebounceTime;this._delta+=y,this._lastMousePos=this._map.mouseEventToContainerPoint(d),this._startTime||(this._startTime=+new Date);var $=Math.max(E-(+new Date-this._startTime),0);clearTimeout(this._timer),this._timer=setTimeout(o(this._performZoom,this),$),zi(d)},_performZoom:function(){var d=this._map,y=d.getZoom(),E=this._map.options.zoomSnap||0;d._stop();var $=this._delta/(this._map.options.wheelPxPerZoomLevel*4),Z=4*Math.log(2/(1+Math.exp(-Math.abs($))))/Math.LN2,oe=E?Math.ceil(Z/E)*E:Z,me=d._limitZoom(y+(this._delta>0?oe:-oe))-y;this._delta=0,this._startTime=null,me&&(d.options.scrollWheelZoom==="center"?d.setZoom(y+me):d.setZoomAround(this._lastMousePos,y+me))}});Et.addInitHook("addHandler","scrollWheelZoom",Fa);var mh=600;Et.mergeOptions({tapHold:lt.touchNative&<.safari&<.mobile,tapTolerance:15});var $c=oi.extend({addHooks:function(){bt(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){$t(this._map._container,"touchstart",this._onDown,this)},_onDown:function(d){if(clearTimeout(this._holdTimeout),d.touches.length===1){var y=d.touches[0];this._startPos=this._newPos=new D(y.clientX,y.clientY),this._holdTimeout=setTimeout(o(function(){this._cancel(),this._isTapValid()&&(bt(document,"touchend",An),bt(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",y))},this),mh),bt(document,"touchend touchcancel contextmenu",this._cancel,this),bt(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function d(){$t(document,"touchend",An),$t(document,"touchend touchcancel",d)},_cancel:function(){clearTimeout(this._holdTimeout),$t(document,"touchend touchcancel contextmenu",this._cancel,this),$t(document,"touchmove",this._onMove,this)},_onMove:function(d){var y=d.touches[0];this._newPos=new D(y.clientX,y.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(d,y){var E=new MouseEvent(d,{bubbles:!0,cancelable:!0,view:window,screenX:y.screenX,screenY:y.screenY,clientX:y.clientX,clientY:y.clientY});E._simulated=!0,y.target.dispatchEvent(E)}});Et.addInitHook("addHandler","tapHold",$c),Et.mergeOptions({touchZoom:lt.touch,bounceAtZoomLimits:!0});var Io=oi.extend({addHooks:function(){_t(this._map._container,"leaflet-touch-zoom"),bt(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){rn(this._map._container,"leaflet-touch-zoom"),$t(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(d){var y=this._map;if(!(!d.touches||d.touches.length!==2||y._animatingZoom||this._zooming)){var E=y.mouseEventToContainerPoint(d.touches[0]),$=y.mouseEventToContainerPoint(d.touches[1]);this._centerPoint=y.getSize()._divideBy(2),this._startLatLng=y.containerPointToLatLng(this._centerPoint),y.options.touchZoom!=="center"&&(this._pinchStartLatLng=y.containerPointToLatLng(E.add($)._divideBy(2))),this._startDist=E.distanceTo($),this._startZoom=y.getZoom(),this._moved=!1,this._zooming=!0,y._stop(),bt(document,"touchmove",this._onTouchMove,this),bt(document,"touchend touchcancel",this._onTouchEnd,this),An(d)}},_onTouchMove:function(d){if(!(!d.touches||d.touches.length!==2||!this._zooming)){var y=this._map,E=y.mouseEventToContainerPoint(d.touches[0]),$=y.mouseEventToContainerPoint(d.touches[1]),Z=E.distanceTo($)/this._startDist;if(this._zoom=y.getScaleZoom(Z,this._startZoom),!y.options.bounceAtZoomLimits&&(this._zoom<y.getMinZoom()&&Z<1||this._zoom>y.getMaxZoom()&&Z>1)&&(this._zoom=y._limitZoom(this._zoom)),y.options.touchZoom==="center"){if(this._center=this._startLatLng,Z===1)return}else{var oe=E._add($)._divideBy(2)._subtract(this._centerPoint);if(Z===1&&oe.x===0&&oe.y===0)return;this._center=y.unproject(y.project(this._pinchStartLatLng,this._zoom).subtract(oe),this._zoom)}this._moved||(y._moveStart(!0,!1),this._moved=!0),ee(this._animRequest);var me=o(y._move,y,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=W(me,this,!0),An(d)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,ee(this._animRequest),$t(document,"touchmove",this._onTouchMove,this),$t(document,"touchend touchcancel",this._onTouchEnd,this),this._map.options.zoomAnimation?this._map._animateZoom(this._center,this._map._limitZoom(this._zoom),!0,this._map.options.zoomSnap):this._map._resetView(this._center,this._map._limitZoom(this._zoom))}});Et.addInitHook("addHandler","touchZoom",Io),Et.BoxZoom=Ic,Et.DoubleClickZoom=qi,Et.Drag=ph,Et.Keyboard=gu,Et.ScrollWheelZoom=Fa,Et.TapHold=$c,Et.TouchZoom=Io,n.Bounds=B,n.Browser=lt,n.CRS=ye,n.Canvas=hu,n.Circle=fh,n.CircleMarker=lu,n.Class=X,n.Control=Er,n.DivIcon=hh,n.DivOverlay=ui,n.DomEvent=G1,n.DomUtil=Tg,n.Draggable=Ba,n.Evented=I,n.FeatureGroup=Nr,n.GeoJSON=kr,n.GridLayer=No,n.Handler=oi,n.Icon=Ns,n.ImageOverlay=Fi,n.LatLng=fe,n.LatLngBounds=G,n.Layer=si,n.LayerGroup=Ro,n.LineUtil=Ig,n.Map=Et,n.Marker=ks,n.Mixin=X1,n.Path=sa,n.Point=D,n.PolyUtil=Q1,n.Polygon=Ds,n.Polyline=la,n.Popup=du,n.PosAnimation=Ec,n.Projection=$g,n.Rectangle=Gg,n.Renderer=fi,n.SVG=za,n.SVGOverlay=Ua,n.TileLayer=Lo,n.Tooltip=Dc,n.Transformation=ue,n.Util=ie,n.VideoOverlay=kc,n.bind=o,n.bounds=Q,n.canvas=pu,n.circle=iw,n.circleMarker=zg,n.control=Rs,n.divIcon=Hg,n.extend=i,n.featureGroup=su,n.geoJSON=Lc,n.geoJson=Fg,n.gridLayer=ci,n.icon=Rc,n.imageOverlay=$s,n.latLng=ce,n.latLngBounds=ae,n.layerGroup=Ug,n.map=ou,n.marker=ch,n.point=N,n.polygon=Lr,n.polyline=aw,n.popup=ow,n.rectangle=$r,n.setOptions=b,n.stamp=f,n.svg=Do,n.svgOverlay=Vg,n.tileLayer=Dr,n.tooltip=sw,n.transformation=J,n.version=r,n.videoOverlay=qg;var zs=window.L;n.noConflict=function(){return window.L=zs,this},window.L=n})}(Op,Op.exports)),Op.exports}var gg=G2e();const e7=zt(gg);function l4(e,t,n){return Object.freeze({instance:e,context:t,container:n})}function u4(e,t){return t==null?function(r,i){const a=M.useRef(void 0);return a.current||(a.current=e(r,i)),a}:function(r,i){const a=M.useRef(void 0);a.current||(a.current=e(r,i));const o=M.useRef(r),{instance:l}=a.current;return M.useEffect(function(){o.current!==r&&(t(l,r,o.current),o.current=r)},[l,r,t]),a}}function W2e(e,t){M.useEffect(function(){return(t.layerContainer??t.map).addLayer(e.instance),function(){var a;(a=t.layerContainer)==null||a.removeLayer(e.instance),t.map.removeLayer(e.instance)}},[t,e])}function Gq(e){return function(n){const r=Vq(),i=e(s4(n,r),r);return qq(r.map,n.attribution),Hq(i.current,n.eventHandlers),W2e(i.current,r),i}}function Y2e(e,t){const n=u4(e,t),r=Gq(n);return z2e(r)}function K2e(e,t){const n=u4(e),r=V2e(n,t);return F2e(r)}function Z2e(e,t){const n=u4(e,t),r=Gq(n);return q2e(r)}function X2e(e,t,n){const{opacity:r,zIndex:i}=t;r!=null&&r!==n.opacity&&e.setOpacity(r),i!=null&&i!==n.zIndex&&e.setZIndex(i)}function Q2e({bounds:e,boundsOptions:t,center:n,children:r,className:i,id:a,placeholder:o,style:l,whenReady:f,zoom:u,...h},m){const[g]=M.useState({className:i,id:a,style:l}),[_,x]=M.useState(null),b=M.useRef(void 0);M.useImperativeHandle(m,()=>(_==null?void 0:_.map)??null,[_]);const S=M.useCallback(A=>{if(A!==null&&!b.current){const O=new gg.Map(A,h);b.current=O,n!=null&&u!=null?O.setView(n,u):e!=null&&O.fitBounds(e,t),f!=null&&O.whenReady(f),x(B2e(O))}},[]);M.useEffect(()=>()=>{_==null||_.map.remove()},[_]);const C=_?pe.createElement(o4,{value:_},r):o??null;return pe.createElement("div",{...g,ref:S},C)}const J2e=M.forwardRef(Q2e),eSe=Y2e(function({position:t,...n},r){const i=new gg.Marker(t,n);return l4(i,U2e(r,{overlayContainer:i}))},function(t,n,r){n.position!==r.position&&t.setLatLng(n.position),n.icon!=null&&n.icon!==r.icon&&t.setIcon(n.icon),n.zIndexOffset!=null&&n.zIndexOffset!==r.zIndexOffset&&t.setZIndexOffset(n.zIndexOffset),n.opacity!=null&&n.opacity!==r.opacity&&t.setOpacity(n.opacity),t.dragging!=null&&n.draggable!==r.draggable&&(n.draggable===!0?t.dragging.enable():t.dragging.disable())}),tSe=K2e(function(t,n){const r=new gg.Popup(t,n.overlayContainer);return l4(r,n)},function(t,n,{position:r},i){M.useEffect(function(){const{instance:o}=t;function l(u){u.popup===o&&(o.update(),i(!0))}function f(u){u.popup===o&&i(!1)}return n.map.on({popupopen:l,popupclose:f}),n.overlayContainer==null?(r!=null&&o.setLatLng(r),o.openOn(n.map)):n.overlayContainer.bindPopup(o),function(){var h;n.map.off({popupopen:l,popupclose:f}),(h=n.overlayContainer)==null||h.unbindPopup(),n.map.removeLayer(o)}},[t,n,i,r])}),nSe=Z2e(function({url:t,...n},r){const i=new gg.TileLayer(t,s4(n,r));return l4(i,r)},function(t,n,r){X2e(t,n,r);const{url:i}=n;i!=null&&i!==r.url&&t.setUrl(i)}),rSe={"Amazon Silk":"amazon_silk","Android Browser":"android",Bada:"bada",BlackBerry:"blackberry",Chrome:"chrome",Chromium:"chromium",Electron:"electron",Epiphany:"epiphany",Firefox:"firefox",Focus:"focus",Generic:"generic","Google Search":"google_search",Googlebot:"googlebot","Internet Explorer":"ie","K-Meleon":"k_meleon",Maxthon:"maxthon","Microsoft Edge":"edge","MZ Browser":"mz","NAVER Whale Browser":"naver",Opera:"opera","Opera Coast":"opera_coast",PhantomJS:"phantomjs",Puffin:"puffin",QupZilla:"qupzilla",QQ:"qq",QQLite:"qqlite",Safari:"safari",Sailfish:"sailfish","Samsung Internet for Android":"samsung_internet",SeaMonkey:"seamonkey",Sleipnir:"sleipnir",Swing:"swing",Tizen:"tizen","UC Browser":"uc",Vivaldi:"vivaldi","WebOS Browser":"webos",WeChat:"wechat","Yandex Browser":"yandex",Roku:"roku"},Wq={amazon_silk:"Amazon Silk",android:"Android Browser",bada:"Bada",blackberry:"BlackBerry",chrome:"Chrome",chromium:"Chromium",electron:"Electron",epiphany:"Epiphany",firefox:"Firefox",focus:"Focus",generic:"Generic",googlebot:"Googlebot",google_search:"Google Search",ie:"Internet Explorer",k_meleon:"K-Meleon",maxthon:"Maxthon",edge:"Microsoft Edge",mz:"MZ Browser",naver:"NAVER Whale Browser",opera:"Opera",opera_coast:"Opera Coast",phantomjs:"PhantomJS",puffin:"Puffin",qupzilla:"QupZilla",qq:"QQ Browser",qqlite:"QQ Browser Lite",safari:"Safari",sailfish:"Sailfish",samsung_internet:"Samsung Internet for Android",seamonkey:"SeaMonkey",sleipnir:"Sleipnir",swing:"Swing",tizen:"Tizen",uc:"UC Browser",vivaldi:"Vivaldi",webos:"WebOS Browser",wechat:"WeChat",yandex:"Yandex Browser"},kn={tablet:"tablet",mobile:"mobile",desktop:"desktop",tv:"tv"},Ur={WindowsPhone:"Windows Phone",Windows:"Windows",MacOS:"macOS",iOS:"iOS",Android:"Android",WebOS:"WebOS",BlackBerry:"BlackBerry",Bada:"Bada",Tizen:"Tizen",Linux:"Linux",ChromeOS:"Chrome OS",PlayStation4:"PlayStation 4",Roku:"Roku"},pl={EdgeHTML:"EdgeHTML",Blink:"Blink",Trident:"Trident",Presto:"Presto",Gecko:"Gecko",WebKit:"WebKit"};class Ve{static getFirstMatch(t,n){const r=n.match(t);return r&&r.length>0&&r[1]||""}static getSecondMatch(t,n){const r=n.match(t);return r&&r.length>1&&r[2]||""}static matchAndReturnConst(t,n,r){if(t.test(n))return r}static getWindowsVersionName(t){switch(t){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}}static getMacOSVersionName(t){const n=t.split(".").splice(0,2).map(r=>parseInt(r,10)||0);if(n.push(0),n[0]===10)switch(n[1]){case 5:return"Leopard";case 6:return"Snow Leopard";case 7:return"Lion";case 8:return"Mountain Lion";case 9:return"Mavericks";case 10:return"Yosemite";case 11:return"El Capitan";case 12:return"Sierra";case 13:return"High Sierra";case 14:return"Mojave";case 15:return"Catalina";default:return}}static getAndroidVersionName(t){const n=t.split(".").splice(0,2).map(r=>parseInt(r,10)||0);if(n.push(0),!(n[0]===1&&n[1]<5)){if(n[0]===1&&n[1]<6)return"Cupcake";if(n[0]===1&&n[1]>=6)return"Donut";if(n[0]===2&&n[1]<2)return"Eclair";if(n[0]===2&&n[1]===2)return"Froyo";if(n[0]===2&&n[1]>2)return"Gingerbread";if(n[0]===3)return"Honeycomb";if(n[0]===4&&n[1]<1)return"Ice Cream Sandwich";if(n[0]===4&&n[1]<4)return"Jelly Bean";if(n[0]===4&&n[1]>=4)return"KitKat";if(n[0]===5)return"Lollipop";if(n[0]===6)return"Marshmallow";if(n[0]===7)return"Nougat";if(n[0]===8)return"Oreo";if(n[0]===9)return"Pie"}}static getVersionPrecision(t){return t.split(".").length}static compareVersions(t,n,r=!1){const i=Ve.getVersionPrecision(t),a=Ve.getVersionPrecision(n);let o=Math.max(i,a),l=0;const f=Ve.map([t,n],u=>{const h=o-Ve.getVersionPrecision(u),m=u+new Array(h+1).join(".0");return Ve.map(m.split("."),g=>new Array(20-g.length).join("0")+g).reverse()});for(r&&(l=o-Math.min(i,a)),o-=1;o>=l;){if(f[0][o]>f[1][o])return 1;if(f[0][o]===f[1][o]){if(o===l)return 0;o-=1}else if(f[0][o]<f[1][o])return-1}}static map(t,n){const r=[];let i;if(Array.prototype.map)return Array.prototype.map.call(t,n);for(i=0;i<t.length;i+=1)r.push(n(t[i]));return r}static find(t,n){let r,i;if(Array.prototype.find)return Array.prototype.find.call(t,n);for(r=0,i=t.length;r<i;r+=1){const a=t[r];if(n(a,r))return a}}static assign(t,...n){const r=t;let i,a;if(Object.assign)return Object.assign(t,...n);for(i=0,a=n.length;i<a;i+=1){const o=n[i];typeof o=="object"&&o!==null&&Object.keys(o).forEach(f=>{r[f]=o[f]})}return t}static getBrowserAlias(t){return rSe[t]}static getBrowserTypeByAlias(t){return Wq[t]||""}}const Qt=/version\/(\d+(\.?_?\d+)+)/i,iSe=[{test:[/googlebot/i],describe(e){const t={name:"Googlebot"},n=Ve.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/opera/i],describe(e){const t={name:"Opera"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/opr\/|opios/i],describe(e){const t={name:"Opera"},n=Ve.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/SamsungBrowser/i],describe(e){const t={name:"Samsung Internet for Android"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/Whale/i],describe(e){const t={name:"NAVER Whale Browser"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/MZBrowser/i],describe(e){const t={name:"MZ Browser"},n=Ve.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/focus/i],describe(e){const t={name:"Focus"},n=Ve.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/swing/i],describe(e){const t={name:"Swing"},n=Ve.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/coast/i],describe(e){const t={name:"Opera Coast"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/opt\/\d+(?:.?_?\d+)+/i],describe(e){const t={name:"Opera Touch"},n=Ve.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/yabrowser/i],describe(e){const t={name:"Yandex Browser"},n=Ve.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/ucbrowser/i],describe(e){const t={name:"UC Browser"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/Maxthon|mxios/i],describe(e){const t={name:"Maxthon"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/epiphany/i],describe(e){const t={name:"Epiphany"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/puffin/i],describe(e){const t={name:"Puffin"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/sleipnir/i],describe(e){const t={name:"Sleipnir"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/k-meleon/i],describe(e){const t={name:"K-Meleon"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/micromessenger/i],describe(e){const t={name:"WeChat"},n=Ve.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/qqbrowser/i],describe(e){const t={name:/qqbrowserlite/i.test(e)?"QQ Browser Lite":"QQ Browser"},n=Ve.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/msie|trident/i],describe(e){const t={name:"Internet Explorer"},n=Ve.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/\sedg\//i],describe(e){const t={name:"Microsoft Edge"},n=Ve.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/edg([ea]|ios)/i],describe(e){const t={name:"Microsoft Edge"},n=Ve.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/vivaldi/i],describe(e){const t={name:"Vivaldi"},n=Ve.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/seamonkey/i],describe(e){const t={name:"SeaMonkey"},n=Ve.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/sailfish/i],describe(e){const t={name:"Sailfish"},n=Ve.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i,e);return n&&(t.version=n),t}},{test:[/silk/i],describe(e){const t={name:"Amazon Silk"},n=Ve.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/phantom/i],describe(e){const t={name:"PhantomJS"},n=Ve.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/slimerjs/i],describe(e){const t={name:"SlimerJS"},n=Ve.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe(e){const t={name:"BlackBerry"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/(web|hpw)[o0]s/i],describe(e){const t={name:"WebOS Browser"},n=Ve.getFirstMatch(Qt,e)||Ve.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/bada/i],describe(e){const t={name:"Bada"},n=Ve.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/tizen/i],describe(e){const t={name:"Tizen"},n=Ve.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/qupzilla/i],describe(e){const t={name:"QupZilla"},n=Ve.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/firefox|iceweasel|fxios/i],describe(e){const t={name:"Firefox"},n=Ve.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/electron/i],describe(e){const t={name:"Electron"},n=Ve.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/MiuiBrowser/i],describe(e){const t={name:"Miui"},n=Ve.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/chromium/i],describe(e){const t={name:"Chromium"},n=Ve.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,e)||Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/chrome|crios|crmo/i],describe(e){const t={name:"Chrome"},n=Ve.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/GSA/i],describe(e){const t={name:"Google Search"},n=Ve.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test(e){const t=!e.test(/like android/i),n=e.test(/android/i);return t&&n},describe(e){const t={name:"Android Browser"},n=Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/playstation 4/i],describe(e){const t={name:"PlayStation 4"},n=Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/safari|applewebkit/i],describe(e){const t={name:"Safari"},n=Ve.getFirstMatch(Qt,e);return n&&(t.version=n),t}},{test:[/.*/i],describe(e){const t=/^(.*)\/(.*) /,n=/^(.*)\/(.*)[ \t]\((.*)/,i=e.search("\\(")!==-1?n:t;return{name:Ve.getFirstMatch(i,e),version:Ve.getSecondMatch(i,e)}}}],aSe=[{test:[/Roku\/DVP/],describe(e){const t=Ve.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,e);return{name:Ur.Roku,version:t}}},{test:[/windows phone/i],describe(e){const t=Ve.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,e);return{name:Ur.WindowsPhone,version:t}}},{test:[/windows /i],describe(e){const t=Ve.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,e),n=Ve.getWindowsVersionName(t);return{name:Ur.Windows,version:t,versionName:n}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe(e){const t={name:Ur.iOS},n=Ve.getSecondMatch(/(Version\/)(\d[\d.]+)/,e);return n&&(t.version=n),t}},{test:[/macintosh/i],describe(e){const t=Ve.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,e).replace(/[_\s]/g,"."),n=Ve.getMacOSVersionName(t),r={name:Ur.MacOS,version:t};return n&&(r.versionName=n),r}},{test:[/(ipod|iphone|ipad)/i],describe(e){const t=Ve.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,e).replace(/[_\s]/g,".");return{name:Ur.iOS,version:t}}},{test(e){const t=!e.test(/like android/i),n=e.test(/android/i);return t&&n},describe(e){const t=Ve.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,e),n=Ve.getAndroidVersionName(t),r={name:Ur.Android,version:t};return n&&(r.versionName=n),r}},{test:[/(web|hpw)[o0]s/i],describe(e){const t=Ve.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,e),n={name:Ur.WebOS};return t&&t.length&&(n.version=t),n}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe(e){const t=Ve.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,e)||Ve.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,e)||Ve.getFirstMatch(/\bbb(\d+)/i,e);return{name:Ur.BlackBerry,version:t}}},{test:[/bada/i],describe(e){const t=Ve.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,e);return{name:Ur.Bada,version:t}}},{test:[/tizen/i],describe(e){const t=Ve.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,e);return{name:Ur.Tizen,version:t}}},{test:[/linux/i],describe(){return{name:Ur.Linux}}},{test:[/CrOS/],describe(){return{name:Ur.ChromeOS}}},{test:[/PlayStation 4/],describe(e){const t=Ve.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,e);return{name:Ur.PlayStation4,version:t}}}],oSe=[{test:[/googlebot/i],describe(){return{type:"bot",vendor:"Google"}}},{test:[/huawei/i],describe(e){const t=Ve.getFirstMatch(/(can-l01)/i,e)&&"Nova",n={type:kn.mobile,vendor:"Huawei"};return t&&(n.model=t),n}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe(){return{type:kn.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe(){return{type:kn.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe(){return{type:kn.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe(){return{type:kn.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe(){return{type:kn.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe(){return{type:kn.tablet}}},{test(e){const t=e.test(/ipod|iphone/i),n=e.test(/like (ipod|iphone)/i);return t&&!n},describe(e){const t=Ve.getFirstMatch(/(ipod|iphone)/i,e);return{type:kn.mobile,vendor:"Apple",model:t}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe(){return{type:kn.mobile,vendor:"Nexus"}}},{test:[/[^-]mobi/i],describe(){return{type:kn.mobile}}},{test(e){return e.getBrowserName(!0)==="blackberry"},describe(){return{type:kn.mobile,vendor:"BlackBerry"}}},{test(e){return e.getBrowserName(!0)==="bada"},describe(){return{type:kn.mobile}}},{test(e){return e.getBrowserName()==="windows phone"},describe(){return{type:kn.mobile,vendor:"Microsoft"}}},{test(e){const t=Number(String(e.getOSVersion()).split(".")[0]);return e.getOSName(!0)==="android"&&t>=3},describe(){return{type:kn.tablet}}},{test(e){return e.getOSName(!0)==="android"},describe(){return{type:kn.mobile}}},{test(e){return e.getOSName(!0)==="macos"},describe(){return{type:kn.desktop,vendor:"Apple"}}},{test(e){return e.getOSName(!0)==="windows"},describe(){return{type:kn.desktop}}},{test(e){return e.getOSName(!0)==="linux"},describe(){return{type:kn.desktop}}},{test(e){return e.getOSName(!0)==="playstation 4"},describe(){return{type:kn.tv}}},{test(e){return e.getOSName(!0)==="roku"},describe(){return{type:kn.tv}}}],sSe=[{test(e){return e.getBrowserName(!0)==="microsoft edge"},describe(e){if(/\sedg\//i.test(e))return{name:pl.Blink};const n=Ve.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,e);return{name:pl.EdgeHTML,version:n}}},{test:[/trident/i],describe(e){const t={name:pl.Trident},n=Ve.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test(e){return e.test(/presto/i)},describe(e){const t={name:pl.Presto},n=Ve.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test(e){const t=e.test(/gecko/i),n=e.test(/like gecko/i);return t&&!n},describe(e){const t={name:pl.Gecko},n=Ve.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/(apple)?webkit\/537\.36/i],describe(){return{name:pl.Blink}}},{test:[/(apple)?webkit/i],describe(e){const t={name:pl.WebKit},n=Ve.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}}];class t7{constructor(t,n=!1){if(t==null||t==="")throw new Error("UserAgent parameter can't be empty");this._ua=t,this.parsedResult={},n!==!0&&this.parse()}getUA(){return this._ua}test(t){return t.test(this._ua)}parseBrowser(){this.parsedResult.browser={};const t=Ve.find(iSe,n=>{if(typeof n.test=="function")return n.test(this);if(n.test instanceof Array)return n.test.some(r=>this.test(r));throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.browser=t.describe(this.getUA())),this.parsedResult.browser}getBrowser(){return this.parsedResult.browser?this.parsedResult.browser:this.parseBrowser()}getBrowserName(t){return t?String(this.getBrowser().name).toLowerCase()||"":this.getBrowser().name||""}getBrowserVersion(){return this.getBrowser().version}getOS(){return this.parsedResult.os?this.parsedResult.os:this.parseOS()}parseOS(){this.parsedResult.os={};const t=Ve.find(aSe,n=>{if(typeof n.test=="function")return n.test(this);if(n.test instanceof Array)return n.test.some(r=>this.test(r));throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.os=t.describe(this.getUA())),this.parsedResult.os}getOSName(t){const{name:n}=this.getOS();return t?String(n).toLowerCase()||"":n||""}getOSVersion(){return this.getOS().version}getPlatform(){return this.parsedResult.platform?this.parsedResult.platform:this.parsePlatform()}getPlatformType(t=!1){const{type:n}=this.getPlatform();return t?String(n).toLowerCase()||"":n||""}parsePlatform(){this.parsedResult.platform={};const t=Ve.find(oSe,n=>{if(typeof n.test=="function")return n.test(this);if(n.test instanceof Array)return n.test.some(r=>this.test(r));throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.platform=t.describe(this.getUA())),this.parsedResult.platform}getEngine(){return this.parsedResult.engine?this.parsedResult.engine:this.parseEngine()}getEngineName(t){return t?String(this.getEngine().name).toLowerCase()||"":this.getEngine().name||""}parseEngine(){this.parsedResult.engine={};const t=Ve.find(sSe,n=>{if(typeof n.test=="function")return n.test(this);if(n.test instanceof Array)return n.test.some(r=>this.test(r));throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.engine=t.describe(this.getUA())),this.parsedResult.engine}parse(){return this.parseBrowser(),this.parseOS(),this.parsePlatform(),this.parseEngine(),this}getResult(){return Ve.assign({},this.parsedResult)}satisfies(t){const n={};let r=0;const i={};let a=0;if(Object.keys(t).forEach(l=>{const f=t[l];typeof f=="string"?(i[l]=f,a+=1):typeof f=="object"&&(n[l]=f,r+=1)}),r>0){const l=Object.keys(n),f=Ve.find(l,h=>this.isOS(h));if(f){const h=this.satisfies(n[f]);if(h!==void 0)return h}const u=Ve.find(l,h=>this.isPlatform(h));if(u){const h=this.satisfies(n[u]);if(h!==void 0)return h}}if(a>0){const l=Object.keys(i),f=Ve.find(l,u=>this.isBrowser(u,!0));if(f!==void 0)return this.compareVersion(i[f])}}isBrowser(t,n=!1){const r=this.getBrowserName().toLowerCase();let i=t.toLowerCase();const a=Ve.getBrowserTypeByAlias(i);return n&&a&&(i=a.toLowerCase()),i===r}compareVersion(t){let n=[0],r=t,i=!1;const a=this.getBrowserVersion();if(typeof a=="string")return t[0]===">"||t[0]==="<"?(r=t.substr(1),t[1]==="="?(i=!0,r=t.substr(2)):n=[],t[0]===">"?n.push(1):n.push(-1)):t[0]==="="?r=t.substr(1):t[0]==="~"&&(i=!0,r=t.substr(1)),n.indexOf(Ve.compareVersions(a,r,i))>-1}isOS(t){return this.getOSName(!0)===String(t).toLowerCase()}isPlatform(t){return this.getPlatformType(!0)===String(t).toLowerCase()}isEngine(t){return this.getEngineName(!0)===String(t).toLowerCase()}is(t,n=!1){return this.isBrowser(t,n)||this.isOS(t)||this.isPlatform(t)}some(t=[]){return t.some(n=>this.is(n))}}/*!
|
||
* Bowser - a browser detector
|
||
* https://github.com/lancedikson/bowser
|
||
* MIT License | (c) Dustin Diaz 2012-2015
|
||
* MIT License | (c) Denis Demchenko 2015-2019
|
||
*/class lSe{static getParser(t,n=!1){if(typeof t!="string")throw new Error("UserAgent should be a string");return new t7(t,n)}static parse(t){return new t7(t).getResult()}static get BROWSER_MAP(){return Wq}static get ENGINE_MAP(){return pl}static get OS_MAP(){return Ur}static get PLATFORMS_MAP(){return kn}}var uSe=Object.defineProperty,cSe=(e,t,n)=>t in e?uSe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ol=(e,t,n)=>cSe(e,typeof t!="symbol"?t+"":t,n);const fSe=e=>(e==null?void 0:e.type)===XT.INVALID_ARGUMENT,dSe=e=>(e==null?void 0:e.type)===XT.INVALID_SHORT_URL_DELETION,hSe=e=>!!e&&typeof e=="object"&&["type","detail","title","status"].every(t=>t in e),Di=e=>hSe(e)?e:void 0,c4=e=>"error"in e,co=({errorData:e,fallbackMessage:t})=>v.jsxs(v.Fragment,{children:[(e==null?void 0:e.detail)??t,fSe(e)&&v.jsxs("p",{children:["Invalid elements: [",e.invalidElements.join(", "),"]"]})]}),Yq=M.createContext(""),pSe=Yq.Provider,vs=()=>M.useContext(Yq),Kq=M.createContext(void 0),{Provider:f4}=Kq,k1=()=>M.useContext(Kq),mSe=5,d4=()=>{const[e,t]=M.useState([]),n=M.useMemo(()=>e.length>=mSe,[e.length]),r=M.useCallback(l=>!n&&t(f=>[...f,l]),[n]),i=M.useCallback(l=>!n&&e.every(f=>f.name!==l),[e,n]),a=M.useCallback(l=>t(f=>f.filter(u=>u!==l)),[]),o=M.useCallback(()=>t([]),[]);return{itemsToCompare:e,addItemToCompare:r,removeItemToCompare:a,clearItemsToCompare:o,canAddItemWithName:i}},h4=({className:e,type:t})=>{const n=vs(),r=k1(),i=M.useMemo(()=>r?encodeURIComponent(r.itemsToCompare.map(f=>f.query).join(",")):"",[r]);if(!r||r.itemsToCompare.length===0)return null;const{itemsToCompare:a,clearItemsToCompare:o,removeItemToCompare:l}=r;return v.jsx("div",{className:be("tw:sticky tw:top-(--header-height) tw:z-10",e),children:v.jsxs(qt,{bodyClassName:"tw:flex tw:flex-col tw:lg:flex-row tw:gap-4 tw:items-center",children:[v.jsx("ul",{className:"tw:flex tw:flex-wrap tw:gap-1 tw:grow tw:items-center",children:a.map((f,u)=>{var h;return v.jsxs("li",{className:be("tw:flex tw:items-center tw:gap-1 tw:text-sm tw:font-bold tw:text-white tw:py-0.5 tw:px-1.5 tw:rounded",{"tw:bg-gray-500":!((h=f.style)!=null&&h.backgroundColor)}),style:f.style,children:[f.name,v.jsx(Vf,{label:`Remove ${f.name}`,className:"tw:text-xs",onClick:()=>l(f)})]},`${f.name}_${u}`)})}),v.jsxs("div",{className:"tw:flex tw:gap-2 tw:max-lg:w-full",children:[v.jsxs(Tn,{className:"tw:grow tw:whitespace-nowrap",disabled:a.length<2,to:a.length>1?`${n}/${t}/compare-visits?${t}=${i}`:void 0,children:[v.jsx(Ye,{icon:Ob}),"Compare (",a.length,"/5)",v.jsx(Ye,{icon:zy})]}),v.jsx(Tn,{"aria-label":"Close compare",variant:"secondary",onClick:o,children:v.jsx(Ye,{icon:Pb})})]})]})})},gSe=(e,{maxVersion:t,minVersion:n})=>{const r=!n||vE(e,n,">=");return(!t||vE(e,t,"<="))&&r},Zq={shortUrlVisitsDeletion:{minVersion:"3.6.0"},orphanVisitsDeletion:{minVersion:"3.7.0"},deviceLongUrls:{maxVersion:"3.*.*"},shortUrlRedirectRules:{minVersion:"4.0.0"},urlValidation:{maxVersion:"3.*.*"},ipRedirectCondition:{minVersion:"4.2.0"},geolocationRedirectCondition:{minVersion:"4.3.0"},filterShortUrlsByDomain:{minVersion:"4.3.0"}};Object.freeze(Zq);const dl=(e,t)=>gSe(t==="latest"?"999.99.99":t,Zq[e]),Xq=e=>({deviceLongUrls:dl("deviceLongUrls",e),shortUrlVisitsDeletion:dl("shortUrlVisitsDeletion",e),orphanVisitsDeletion:dl("orphanVisitsDeletion",e),shortUrlRedirectRules:dl("shortUrlRedirectRules",e),urlValidation:dl("urlValidation",e),ipRedirectCondition:dl("ipRedirectCondition",e),geolocationRedirectCondition:dl("geolocationRedirectCondition",e),filterShortUrlsByDomain:dl("filterShortUrlsByDomain",e)}),Qq=M.createContext(Xq("0.0.0")),vSe=Qq.Provider,ySe=e=>M.useMemo(()=>Xq(e),[e]),fo=e=>M.useContext(Qq)[e],Sd="DEFAULT",p4=(e,t,n=1)=>xB(n,e+1).map(t),bSe=e=>Array.isArray(e)&&e.length===0||typeof e=="string"&&e===""||typeof e=="object"&&Object.keys(e).length===0,$u=e=>e!=null&&!bSe(e),wA=e=>e||null,HO=e=>e?"true":"false",_A=e=>e===void 0?void 0:HO(e),xA=({children:e,onChange:t,infoTitle:n,...r})=>v.jsx(ta,{...r,onChange:i=>t(i.target.value),label:v.jsxs(v.Fragment,{children:[v.jsx(Ye,{className:"tw:mr-1.5",icon:Tb,title:n}),e]}),type:"url",placeholder:"No redirect"}),wSe=({isOpen:e,onClose:t,domain:n,editDomainRedirects:r})=>{var i,a,o;const[l,f]=M.useState(((i=n.redirects)==null?void 0:i.baseUrlRedirect)??""),[u,h]=M.useState(((a=n.redirects)==null?void 0:a.regular404Redirect)??""),[m,g]=M.useState(((o=n.redirects)==null?void 0:o.invalidShortUrlRedirect)??""),[_,x]=M.useState(!1),b=M.useCallback(async()=>{x(!0);try{await r({domain:n.domain,redirects:{baseUrlRedirect:wA(l),regular404Redirect:wA(u),invalidShortUrlRedirect:wA(m)}}),t()}finally{x(!1)}},[r,n.domain,l,u,m,t]);return v.jsx(Vl,{title:`Edit redirects for ${n.domain}`,open:e,onClose:t,onConfirm:b,confirmText:_?"Saving...":"Save",confirmDisabled:_,children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-3",children:[v.jsx(xA,{value:l,onChange:f,infoTitle:`Visitors accessing the base url, as in https://${n.domain}/, will be redirected to this URL.`,children:"Base URL"}),v.jsx(xA,{value:u,onChange:h,infoTitle:`Visitors accessing a url not matching a short URL pattern, as in https://${n.domain}/???/[...], will be redirected to this URL.`,children:"Regular 404"}),v.jsx(xA,{value:m,onChange:g,infoTitle:"Visitors accessing a url matching a short URL pattern, but not matching an existing short code, will be redirected to this URL.",children:"Invalid short URL"})]})})},_Se=({domain:e,editDomainRedirects:t})=>{const{flag:n,setToTrue:r,setToFalse:i}=wn(!1,!0),a=vs(),o=k1(),l=fo("filterShortUrlsByDomain");return v.jsxs(v.Fragment,{children:[v.jsxs(zn,{menuAlignment:"right",children:[v.jsxs(zn.Item,{className:"tw:gap-1.5",to:`${a}/domain/${e.domain}${e.isDefault?`_${Sd}`:""}/visits`,children:[v.jsx(Ye,{icon:gT,fixedWidth:!0})," Visit stats"]}),v.jsxs(zn.Item,{className:"tw:gap-1.5",disabled:!o||!o.canAddItemWithName(e.domain),onClick:()=>o==null?void 0:o.addItemToCompare({name:e.domain,query:e.domain}),children:[v.jsx(Ye,{icon:Ob,fixedWidth:!0})," Compare visits"]}),l&&v.jsxs(zn.Item,{className:"tw:gap-1.5",to:`${a}/list-short-urls/1?domain=${e.isDefault?Sd:e.domain}`,children:[v.jsx(Ye,{icon:pT,fixedWidth:!0})," Short URLs"]}),v.jsx(zn.Separator,{}),v.jsxs(zn.Item,{onClick:r,className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:mT,fixedWidth:!0})," Edit redirects"]})]}),v.jsx(wSe,{domain:e,isOpen:n,onClose:i,editDomainRedirects:t})]})},xSe=({status:e})=>{const{anchor:t,tooltip:n}=Hl();return e==="validating"?v.jsx(Ye,{fixedWidth:!0,icon:Ym,spin:!0}):v.jsxs("span",{...t,children:[v.jsx(Ye,{fixedWidth:!0,icon:e==="valid"?Zu:mX,className:be({"tw:text-danger":e!=="valid"})}),v.jsx(Gl,{...n,children:e==="valid"?v.jsxs(v.Fragment,{children:["Congratulations!",v.jsx("br",{}),"This domain is properly configured."]}):v.jsxs("span",{children:["Oops! There is some missing configuration, and short URLs shared with this domain will not work.",v.jsx("br",{}),"Check the ",v.jsx(Oi,{href:"https://slnk.to/multi-domain-docs",children:"documentation"})," in order to find out what is missing."]})})]})},SA=({fallback:e})=>v.jsxs("span",{className:"tw:text-gray-500 tw:dark:text-gray-400",children:[!e&&v.jsx("small",{children:"No redirect"}),e&&v.jsxs(v.Fragment,{children:[e," ",v.jsx("small",{children:"(as fallback)"})]})]}),SSe=()=>{const{anchor:e,tooltip:t}=Hl();return v.jsxs(v.Fragment,{children:[v.jsx(Ye,{...e,fixedWidth:!0,icon:kZ,className:"tw:text-lm-brand tw:dark:text-dm-brand","data-testid":"default-domain-icon"}),v.jsx(Gl,{...t,children:"Default domain foo"})]})},CSe=({domain:e,editDomainRedirects:t,checkDomainHealth:n,defaultRedirects:r})=>{const{domain:i,isDefault:a,redirects:o,status:l}=e;return M.useEffect(()=>{n(e.domain)},[n,e.domain]),v.jsxs(Je.Row,{className:"tw:relative",children:[v.jsx(Je.Cell,{columnName:"Is default domain:",children:a&&v.jsx(SSe,{})}),v.jsx(Je.Cell,{columnName:"Domain:",children:v.jsx("b",{children:i})}),v.jsx(Je.Cell,{columnName:"Base path redirect:",children:(o==null?void 0:o.baseUrlRedirect)??v.jsx(SA,{fallback:r==null?void 0:r.baseUrlRedirect})}),v.jsx(Je.Cell,{columnName:"Regular 404 redirect:",children:(o==null?void 0:o.regular404Redirect)??v.jsx(SA,{fallback:r==null?void 0:r.regular404Redirect})}),v.jsx(Je.Cell,{columnName:"Invalid short URL redirect:",children:(o==null?void 0:o.invalidShortUrlRedirect)??v.jsx(SA,{fallback:r==null?void 0:r.invalidShortUrlRedirect})}),v.jsx(Je.Cell,{className:"tw:lg:text-center tw:max-lg:border-none",columnName:"Status:",children:v.jsx(xSe,{status:l})}),v.jsx(Je.Cell,{className:"tw:text-right tw:max-lg:absolute tw:max-lg:top-1 tw:max-lg:right-1 tw:max-lg:p-0",children:v.jsx(_Se,{domain:e,editDomainRedirects:t})})]})},n7=[{value:"Is default domain",isHidden:!0},{value:"Domain",isHidden:!1},{value:"Base path redirect",isHidden:!1},{value:"Regular 404 redirect",isHidden:!1},{value:"Invalid short URL redirect",isHidden:!1},{value:"Domain status",isHidden:!0},{value:"Options",isHidden:!0}],ASe=({domainsList:e,filterDomains:t,editDomainRedirects:n,checkDomainHealth:r})=>{var i;const{filteredDomains:a,defaultRedirects:o,loading:l,error:f,errorData:u}=e,h=o??((i=a.find(({isDefault:g})=>g))==null?void 0:i.redirects),m=d4();return l?v.jsx(tc,{loading:!0}):v.jsx(f4,{value:m,children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-4",children:[v.jsx(ag,{onChange:t}),v.jsx(h4,{type:"domains"}),f&&v.jsx(Ei,{variant:"error",children:v.jsx(co,{errorData:u,fallbackMessage:"Error loading domains :("})}),!f&&v.jsx(qt,{className:"card",children:v.jsxs(Je,{header:v.jsx(Je.Row,{children:n7.map((g,_)=>v.jsx(Je.Cell,{children:v.jsx("span",{className:g.isHidden?"tw:sr-only":void 0,children:g.value})},_))}),children:[a.length<1&&v.jsx(Je.Row,{children:v.jsx(Je.Cell,{colSpan:n7.length,className:"tw:text-center",children:"No results found"})}),a.map(g=>v.jsx(CSe,{domain:g,editDomainRedirects:n,checkDomainHealth:r,defaultRedirects:h},g.domain))]})})]})})},Zn=(e,t)=>gB(e,t,{serializeError:n=>n}),ESe="shlink/domainRedirects/EDIT_DOMAIN_REDIRECTS",OSe=e=>Zn(ESe,async({domain:t,redirects:n})=>{const r=await e().editDomainRedirects({domain:t,...n});return{domain:t,redirects:r}}),py="shlink/domainsList",my={domains:[],filteredDomains:[],loading:!1,error:!1},r7=({domain:e,redirects:t})=>n=>n.domain!==e?n:{...n,redirects:t},i7=(e,t)=>n=>n.domain!==e?n:{...n,status:t},TSe=(e,t,n)=>{const r=Zn(`${py}/listDomains`,async()=>{const{data:l,defaultRedirects:f}=await e().listDomains();return{domains:l.map(u=>({...u,status:"validating"})),defaultRedirects:f}}),i=Zn(`${py}/checkDomainHealth`,async l=>{try{const{status:f}=await e().health({domain:l});return{domain:l,status:f==="pass"?"valid":"invalid"}}catch{return{domain:l,status:"invalid"}}}),a=Hr(`${py}/filterDomains`),{reducer:o}=Dn({name:py,initialState:my,reducers:{},extraReducers:l=>{l.addCase(r.pending,()=>({...my,loading:!0})),l.addCase(r.rejected,(f,{error:u})=>({...my,error:!0,errorData:Di(u)})),l.addCase(r.fulfilled,(f,{payload:u})=>({...my,...u,filteredDomains:u.domains})),l.addCase(i.fulfilled,({domains:f,filteredDomains:u,...h},{payload:m})=>({...h,domains:f.map(i7(m.domain,m.status)),filteredDomains:u.map(i7(m.domain,m.status))})),l.addCase(a,(f,{payload:u})=>({...f,filteredDomains:f.domains.filter(({domain:h})=>h.toLowerCase().match(u.toLowerCase()))})),l.addCase(t.fulfilled,(f,{payload:u})=>({...f,domains:f.domains.map(r7(u)),filteredDomains:f.filteredDomains.map(r7(u))})),l.addCase(n.fulfilled,(f,{payload:u})=>{u.domain===null||f.domains.some(h=>h.domain===u.domain)||f.domains.push({domain:u.domain,status:"validating",isDefault:!1,redirects:{baseUrlRedirect:null,regular404Redirect:null,invalidShortUrlRedirect:null}})})}});return{reducer:o,listDomains:r,checkDomainHealth:i,filterDomains:a}},jSe=(e,t)=>{e.serviceFactory("ManageDomains",()=>ASe),e.decorator("ManageDomains",t(["domainsList"],["filterDomains","editDomainRedirects","checkDomainHealth"])),e.serviceFactory("domainsListReducerCreator",TSe,"apiClientFactory","editDomainRedirects","createShortUrl"),e.serviceFactory("domainsListReducer",n=>n.reducer,"domainsListReducerCreator"),e.serviceFactory("listDomains",n=>n.listDomains,"domainsListReducerCreator"),e.serviceFactory("filterDomains",n=>n.filterDomains,"domainsListReducerCreator"),e.serviceFactory("editDomainRedirects",OSe,"apiClientFactory"),e.serviceFactory("checkDomainHealth",n=>n.checkDomainHealth,"domainsListReducerCreator")},a7="shlink/mercure",PSe={loading:!0,error:!1},RSe=e=>{const t=Zn(`${a7}/loadMercureInfo`,r=>{if(r&&r.realTimeUpdates&&!r.realTimeUpdates.enabled)throw new Error("Real time updates not enabled");return e().mercureInfo()}),{reducer:n}=Dn({name:a7,initialState:PSe,reducers:{},extraReducers:r=>{r.addCase(t.pending,i=>({...i,loading:!0,error:!1})),r.addCase(t.rejected,i=>({...i,loading:!1,error:!0})),r.addCase(t.fulfilled,(i,{payload:a})=>({...a,loading:!1,error:!1}))}});return{loadMercureInfo:t,reducer:n}},MSe=e=>{e.serviceFactory("mercureInfoReducerCreator",RSe,"apiClientFactory"),e.serviceFactory("mercureInfoReducer",t=>t.reducer,"mercureInfoReducerCreator"),e.serviceFactory("loadMercureInfo",t=>t.loadMercureInfo,"mercureInfoReducerCreator")};function Pn(e){return M.useMemo(()=>e,[e])}function Rn(e,t){return(n,r=globalThis.console)=>(t.forEach(i=>{const a=n[i];e[i]=a}),e)}const NSe=(e,t,n,r)=>{const{mercureHubUrl:i,token:a,loading:o,error:l}=e;if(o||l||!i)return;const f=({data:m})=>n(JSON.parse(m)),u=({status:m})=>m===401&&r(),h=t.map(m=>{const g=new URL(i);g.searchParams.append("topic",m);const _=new Oae.EventSourcePolyfill(g,{headers:{Authorization:`Bearer ${a}`}});return _.onmessage=f,_.onerror=u,_});return()=>h.forEach(m=>m.close())};function Ma(e,t){const n=new Set;return r=>{const{createNewVisits:i,loadMercureInfo:a,mercureInfo:o}=r,l=Td();return M.useEffect(()=>{const{interval:f}=o,u=_=>f?n.add(_):i([_]),h=t(l),m=NSe(o,h,u,a);if(!f)return m;const g=setInterval(()=>{i([...n]),n.clear()},f*1e3*60);return()=>{clearInterval(g),m==null||m()}},[i,a,o,l]),v.jsx(e,{...r})}}class Wr{}Ol(Wr,"visits","https://shlink.io/new-visit"),Ol(Wr,"orphanVisits","https://shlink.io/new-orphan-visit"),Ol(Wr,"shortUrlVisits",e=>`https://shlink.io/new-visit/${e}`);const Yd=Hr("shlink/visitCreation/createNewVisits",e=>({payload:{createdVisits:e}})),qp=(e,t,n)=>n==null?e.shortCode===t&&!e.domain:e.shortCode===t&&e.domain===n,LSe=(e,t)=>!e.domain&&t===Sd?!0:e.domain===t,kSe=(e,t)=>{const n=(t==null?void 0:t.validateUrls)??!1;return e?{longUrl:e.longUrl,tags:e.tags,title:e.title??void 0,domain:e.domain??void 0,validSince:e.meta.validSince??void 0,validUntil:e.meta.validUntil??void 0,maxVisits:e.meta.maxVisits??void 0,crawlable:e.crawlable,forwardQuery:e.forwardQuery,deviceLongUrls:e.deviceLongUrls&&{android:e.deviceLongUrls.android??void 0,ios:e.deviceLongUrls.ios??void 0,desktop:e.deviceLongUrls.desktop??void 0},validateUrl:n}:{longUrl:"",validateUrl:n}},Jq=e=>e.replaceAll("/","__"),m4=e=>e.replaceAll("__","/"),g4=({domain:e,shortCode:t})=>`${e??Sd}__${Jq(t)}`,eV=e=>{const[t,n]=e.split(/__(.+)/);if(!n)throw new Error(`It was not possible to parse domain and short code from "${e}"`);return{domain:t===Sd?null:t,shortCode:m4(n)}},v4="shlink/shortUrlDeletion",o7={shortCode:"",loading:!1,deleted:!1,error:!1},DSe=e=>Zn(`${v4}/deleteShortUrl`,async({shortCode:t,domain:n})=>(await e().deleteShortUrl({shortCode:t,domain:n}),{shortCode:t,domain:n})),tV=Hr(`${v4}/shortUrlDeleted`),ISe=e=>{const{actions:t,reducer:n}=Dn({name:v4,initialState:o7,reducers:{resetDeleteShortUrl:()=>o7},extraReducers:i=>{i.addCase(e.pending,a=>({...a,loading:!0,error:!1,deleted:!1})),i.addCase(e.rejected,(a,{error:o})=>({...a,errorData:Di(o),loading:!1,error:!0,deleted:!1})),i.addCase(e.fulfilled,(a,{payload:o})=>({...a,shortCode:o.shortCode,loading:!1,error:!1,deleted:!0}))}}),{resetDeleteShortUrl:r}=t;return{reducer:n,resetDeleteShortUrl:r}},nV="shlink/shortUrlsList",rV=5,$Se={loading:!0,error:!1},BSe=e=>Zn(`${nV}/listShortUrls`,t=>e().listShortUrls(t??{})),USe=(e,t,n)=>Dn({name:nV,initialState:$Se,reducers:{},extraReducers:r=>{r.addCase(e.pending,i=>({...i,loading:!0,error:!1})),r.addCase(e.rejected,()=>({loading:!1,error:!0})),r.addCase(e.fulfilled,(i,{payload:a})=>({loading:!1,error:!1,shortUrls:a})),r.addCase(n.fulfilled,(i,{payload:a})=>{i.shortUrls&&(i.shortUrls.data=[a,...i.shortUrls.data.slice(0,rV-1)],i.shortUrls.pagination.totalItems+=1)}),r.addCase(t.fulfilled,(i,{payload:a})=>{i.shortUrls&&(i.shortUrls.data=i.shortUrls.data.map(o=>{const{shortCode:l,domain:f}=a;return qp(o,l,f)?a:o}))}),r.addCase(tV,(i,{payload:a})=>{i.shortUrls&&(i.shortUrls.data=i.shortUrls.data.filter(o=>!qp(o,a.shortCode,a.domain)),i.shortUrls.pagination.totalItems-=1)}),r.addCase(Yd,(i,{payload:a})=>{i.shortUrls&&(i.shortUrls.data=i.shortUrls.data.map(o=>{var l;return((l=a.createdVisits.findLast(({shortUrl:f})=>f&&qp(o,f.shortCode,f.domain)))==null?void 0:l.shortUrl)??o}))})}}),GO=({children:e,title:t,link:n,tooltip:r})=>{const{anchor:i,tooltip:a}=Hl({placement:"bottom"});return v.jsxs(v.Fragment,{children:[v.jsx(ur,{to:n,className:"tw:no-underline tw:text-inherit",...i,children:v.jsxs(qt,{className:be("tw:text-center tw:border-t-3 tw:border-t-lm-main tw:dark:border-t-dm-main tw:relative"),children:[v.jsx(Ye,{icon:yte,size:"3x",className:"tw:absolute tw:right-[5px] tw:bottom-[5px] tw:opacity-10 tw:-rotate-45"}),v.jsx("div",{role:"heading","aria-level":5,className:"tw:text-xl tw:uppercase tw:text-placeholder tw:font-bold tw:mb-2",children:t}),v.jsx("div",{className:"tw:text-4xl tw:font-semibold",children:e})]})}),r&&v.jsx(Gl,{...a,children:r})]})},s7=({loading:e,excludeBots:t,visitsSummary:n,...r})=>v.jsx(GO,{tooltip:n.bots!==void 0?v.jsxs(v.Fragment,{children:[t?"Plus":"Including"," ",v.jsx("b",{"data-testid":"tooltip-amount",children:jn(n.bots)})," potential bot visits"]}):void 0,...r,children:e?"Loading...":jn(t&&n.nonBots!==void 0?n.nonBots:n.total)}),l7=({children:e,titleLinkText:t,titleLink:n,title:r})=>v.jsxs(Fn,{className:"card",children:[v.jsxs(Fn.Header,{className:"tw:flex tw:justify-between tw:items-center",children:[v.jsx("span",{className:"tw:sm:hidden",children:r}),v.jsx("h5",{className:"tw:hidden tw:sm:inline",children:r}),v.jsxs(ur,{to:n,children:[t," »"]})]}),v.jsx(Fn.Body,{children:e})]}),iV=Ma(({shortUrlsList:e,listShortUrls:t,tagsList:n,loadVisitsOverview:r,visitsOverview:i})=>{const{ShortUrlsTable:a,CreateShortUrl:o}=Pn(iV),{loading:l,shortUrls:f}=e,{loading:u}=n,{loading:h,nonOrphanVisits:m,orphanVisits:g}=i,_=vs(),x=po(),b=Xn("visits");return M.useEffect(()=>{t({itemsPerPage:rV,orderBy:{field:"dateCreated",dir:"DESC"}}),r()},[t,r]),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-4",children:[v.jsxs("div",{className:"tw:grid tw:grid-cols-1 tw:lg:grid-cols-2 tw:xl:grid-cols-4 tw:gap-4",children:[v.jsx(s7,{title:"Visits",link:`${_}/non-orphan-visits`,excludeBots:(b==null?void 0:b.excludeBots)??!1,loading:h,visitsSummary:m}),v.jsx(s7,{title:"Orphan visits",link:`${_}/orphan-visits`,excludeBots:(b==null?void 0:b.excludeBots)??!1,loading:h,visitsSummary:g}),v.jsx(GO,{title:"Short URLs",link:`${_}/list-short-urls/1`,children:l?"Loading...":jn((f==null?void 0:f.pagination.totalItems)??0)}),v.jsx(GO,{title:"Tags",link:`${_}/manage-tags`,children:u?"Loading...":jn(n.tags.length)})]}),v.jsx(l7,{title:"Create a short URL",titleLinkText:"Advanced options",titleLink:`${_}/create-short-url`,children:v.jsx(o,{basicMode:!0})}),v.jsx(l7,{title:"Recently created URLs",titleLinkText:"See all",titleLink:`${_}/list-short-urls/1`,children:v.jsx(a,{shortUrlsList:e,onTagClick:S=>x(`${_}/list-short-urls/1?tags=${encodeURIComponent(S)}`)})})]})},()=>[Wr.visits,Wr.orphanVisits]),zSe=Rn(iV,["ShortUrlsTable","CreateShortUrl"]);function FSe(e,t){e.factory("Overview",zSe),e.decorator("Overview",t(["shortUrlsList","tagsList","mercureInfo","visitsOverview"],["listShortUrls","createNewVisits","loadMercureInfo","loadVisitsOverview"]))}const aV="shlink/setShortUrlRedirectRules",u7={saving:!1,saved:!1,error:!1},qSe=e=>Zn(`${aV}/setShortUrlRedirectRules`,({shortUrl:t,data:n})=>{const{shortCode:r,domain:i}=t;return e().setShortUrlRedirectRules({shortCode:r,domain:i},n)}),VSe=e=>{const{reducer:t,actions:n}=Dn({name:aV,initialState:u7,reducers:{resetSetRules:()=>u7},extraReducers:i=>{i.addCase(e.pending,()=>({saving:!0,saved:!1,error:!1})),i.addCase(e.rejected,(a,{error:o})=>({saving:!1,saved:!1,error:!0,errorData:Di(o)})),i.addCase(e.fulfilled,()=>({saving:!1,error:!1,saved:!0}))}}),{resetSetRules:r}=n;return{reducer:t,resetSetRules:r}},oV="shlink/getShortUrlRedirectRules",HSe={loading:!0,error:!1},GSe=e=>Zn(`${oV}/getShortUrlRedirectRules`,({shortCode:t,domain:n})=>e().getShortUrlRedirectRules({shortCode:t,domain:n})),WSe=e=>Dn({name:oV,initialState:HSe,reducers:{},extraReducers:t=>{t.addCase(e.pending,()=>({loading:!0,error:!1})),t.addCase(e.rejected,()=>({loading:!1,error:!0})),t.addCase(e.fulfilled,(n,{payload:r})=>({loading:!1,error:!1,...r}))}});function Yr(e){e.preventDefault()}function Ql(e){e.stopPropagation()}function sV(){const e=new Map;return[function(t,n){e.get(t)&&e.get(t).forEach(r=>{r(n)})},function(t,n){const r=e.get(t)??[];r.push(n),e.set(t,r)}]}var[lV,uV]=sV();function YSe(e,t){return e.source===t.source&&e.flags.split("").sort().join("")===t.flags.split("").sort().join("")}function Um(e,t,n=!0,r=["__key"]){if(e===t)return!0;if(typeof t=="object"&&typeof e=="object"&&e!==null&&t!==null){if(e instanceof Map||e instanceof Set)return!1;if(e instanceof Date&&t instanceof Date)return e.getTime()===t.getTime();if(e instanceof RegExp&&t instanceof RegExp)return YSe(e,t);if(e===null||t===null)return!1;const i=e,a=t;if(Object.keys(i).length!==Object.keys(a).length)return!1;for(const o of r)if((o in i||o in a)&&i[o]!==a[o])return!1;for(const o in i)if(!(o in a)||i[o]!==a[o]&&!n||n&&!Um(i[o],a[o],n,r))return!1;return!0}return!1}function cV(e){return e.split(" ").filter(t=>t)}function Kd(e){return{x:e.clientX,y:e.clientY}}Array();var y4=typeof window<"u",Rr=new WeakMap,ho=new WeakMap;function fV(){if(!y4)return!1;if("userAgentData"in navigator)return navigator.userAgentData.mobile===!0;const e=navigator.userAgent,t=/android|iphone|ipod/i.test(e),n=/iPad/.test(e)||e.includes("Macintosh")&&navigator.maxTouchPoints>1;return t||n}var KSe={affectedNodes:[],coordinates:{x:0,y:0},currentTargetValue:void 0,on:uV,emit:lV,originalZIndex:void 0,pointerSelection:!1,preventEnter:!1,rootUserSelect:void 0,nodePointerdown:void 0,longPress:!1,scrolling:!1,longPressTimeout:void 0,remapJustFinished:!1,selectedNodes:[],selectedParent:void 0,preventSynthDrag:!1,pointerDown:void 0,lastScrollContainerX:null,lastScrollContainerY:null,rootScrollWidth:void 0,rootScrollHeight:void 0,dragItemRect:void 0,windowScrollX:void 0,windowScrollY:void 0,lastScrollDirectionX:void 0,lastScrollDirectionY:void 0,scrollDebounceTimeout:void 0,frameIdX:void 0,frameIdY:void 0},We=KSe,zl=!1,c7,CA;function ZSe(){We.scrollDebounceTimeout&&clearTimeout(We.scrollDebounceTimeout),We.longPressTimeout&&clearTimeout(We.longPressTimeout),We.frameIdX!==void 0&&cancelAnimationFrame(We.frameIdX),We.frameIdY!==void 0&&cancelAnimationFrame(We.frameIdY),We={affectedNodes:[],coordinates:{x:0,y:0},on:uV,emit:lV,currentTargetValue:void 0,originalZIndex:void 0,pointerId:void 0,preventEnter:!1,remapJustFinished:!1,selectedNodes:[],nodePointerdown:void 0,rootUserSelect:void 0,preventSynthDrag:!1,scrolling:!1,selectedParent:void 0,pointerSelection:!1,synthScrollDirection:void 0,draggedNodeDisplay:void 0,synthDragScrolling:!1,longPress:!1,pointerDown:void 0,longPressTimeout:void 0,lastScrollContainerX:null,lastScrollContainerY:null,rootScrollWidth:void 0,rootScrollHeight:void 0,dragItemRect:void 0,windowScrollX:void 0,windowScrollY:void 0,lastScrollDirectionX:void 0,lastScrollDirectionY:void 0,scrollDebounceTimeout:void 0,frameIdX:void 0,frameIdY:void 0}}function dV(e){return Object.assign(We,e),e.initialParent.data.emit("dragStarted",We),zl=!1,We.emit("dragStarted",We),We}function XSe(){We.activeState&&uc(We.activeState.parent,void 0,We),We.selectedState&&Ku(We.selectedState.nodes,We.selectedState.parent,We),We.selectedState=We.activeState=void 0}function QSe(){if(We.pointerDown&&(We.pointerDown.node.el.draggable=!0),We.pointerDown=void 0,!Li(We))return;const e=We.currentParent.data.config;Li(We)&&e.handleEnd(We)}function JSe(e){e.key==="Escape"&&(We.selectedState&&Ku(We.selectedState.nodes,We.selectedState.parent,We),We.activeState&&uc(We.activeState.parent,void 0,We),We.selectedState=We.activeState=void 0)}function eCe(e){if(!Kr(We))return;zl=!0;const t=We.initialParent.data.config.handleEnd;t(We)}function tCe(e){if(!Kr(We))return;Yr(e);const{x:t,y:n}=Kd(e);Kr(We)&&$1({x:t,y:n},e,We)}function nCe(e){if(!We.pointerDown||!We.pointerDown.validated)return;const t=We.pointerDown.parent.data.config;if(!(e.pointerType==="mouse"&&!fV()))if(Li(We))Li(We)&&f7(e,We);else{if(Yr(e),t.longPress&&!We.longPress){clearTimeout(We.longPressTimeout),We.longPress=!1;return}const n=t.draggedNodes(We.pointerDown);t.dragstartClasses(We.pointerDown.node,n,t,!0);const r=We.pointerDown.node.el.getBoundingClientRect(),i=RCe(We.pointerDown.node,We.pointerDown.parent,e,We,n,r);f7(e,i,!0)}}function rCe({parent:e,getValues:t,setValues:n,config:r={}}){var i,a,o;if(!y4)return;c7||(c7=fb(document,{dragover:tCe,pointerdown:XSe,pointerup:QSe,keydown:JSe,drop:eCe,pointermove:nCe,pointercancel:yi(r.handlePointercancel),touchmove:h=>{Kr(We)&&h.cancelable&&Yr(h)},contextmenu:h=>{Li(We)&&Yr(h)}})),pV(e);const[l,f]=sV(),u={getValues:t,setValues:n,config:{dragDropEffect:r.dragDropEffect??"move",dragEffectAllowed:r.dragEffectAllowed??"move",draggedNodes:gCe,dragstartClasses:wCe,handleNodeKeydown:xCe,handleDragstart:yCe,handleNodeDragover:NCe,handleParentDragover:LCe,handleNodeDrop:CCe,handleNodeFocus:ACe,handleNodeBlur:ECe,handlePointercancel:TCe,handleEnd:jCe,handleDragend:OCe,handleParentFocus:aCe,handleNodePointerup:PCe,handleNodePointerover:SCe,handleParentPointerover:kCe,handleParentScroll:vCe,handleNodePointerdown:bCe,handleNodeDragenter:ICe,handleNodeDragleave:$Ce,handleParentDrop:sCe,multiDrag:r.multiDrag??!1,nativeDrag:r.nativeDrag??!0,performSort:iCe,performTransfer:oCe,root:r.root??document,setupNode:uCe,setupNodeRemap:mV,reapplyDragClasses:cCe,tearDownNode:dCe,tearDownNodeRemap:fCe,remapFinished:pCe,threshold:{horizontal:0,vertical:0},...r},enabledNodes:[],abortControllers:{},privateClasses:[],on:f,emit:l};new MutationObserver(hCe).observe(e,{childList:!0}),Rr.set(e,u),(i=r.plugins)==null||i.forEach(h=>{var m,g;(g=(m=h(e))==null?void 0:m.tearDown)==null||g.call(m)}),(a=r.plugins)==null||a.forEach(h=>{var m,g;(g=(m=h(e))==null?void 0:m.tearDown)==null||g.call(m)}),(o=r.plugins)==null||o.forEach(h=>{var m,g;(g=(m=h(e))==null?void 0:m.setup)==null||g.call(m)}),lCe(e,u),D1(e,!0)}function hV(e,t,n,r,i,a){const{x:o,y:l}=Kd(n),f=e.el.getBoundingClientRect();return{affectedNodes:[],ascendingDirection:!1,clonedDraggedEls:[],coordinates:{x:o,y:l},draggedNode:{el:e.el,data:e.data},draggedNodes:r,incomingDirection:void 0,initialIndex:e.data.index,initialParent:{el:t.el,data:t.data},currentParent:{el:t.el,data:t.data},longPress:t.data.config.longPress??!1,longPressTimeout:void 0,currentTargetValue:e.data.value,scrollEls:[],startLeft:i||o-((f==null?void 0:f.left)??0),startTop:a||l-((f==null?void 0:f.top)??0),targetIndex:e.data.index,transferred:!1}}function iCe({parent:e,draggedNodes:t,targetNodes:n}){D1(e.el);const r=t.map(f=>f.data.value),i=Cd(e.el,e.data),a=t[0].data.index,o=[...e.data.enabledNodes],l=[...i.filter(f=>!r.some(u=>Um(f,u)))];l.splice(n[0].data.index,0,...r),"draggedNode"in We&&(We.currentTargetValue=n[0].data.value),WO(e.el,e.data,[...l]),e.data.config.onSort&&e.data.config.onSort({parent:{el:e.el,data:e.data},previousValues:[...i],previousNodes:[...o],nodes:[...e.data.enabledNodes],values:[...l],draggedNodes:t,previousPosition:a,position:n[0].data.index,targetNodes:n,state:We})}function uc(e,t,n){if(!t){n.activeState=void 0;return}n.activeState={node:t,parent:e}}function Ku(e,t,n){const r=t.data.config.selectedClass;if(!n.selectedState)return;const i=Array.from(e);Tl(e.map(a=>a.el),r);for(const a of i){a.el.setAttribute("aria-selected","false");const o=n.selectedState.nodes.findIndex(l=>l.el===a.el);o!==-1&&n.selectedState.nodes.splice(o,1)}}function gy(e,t,n,r,i=!1){r.pointerSelection=i;for(const a of t)a.el.setAttribute("aria-selected","true"),Bf([a.el],e.data.config.selectedClass,!0);r.selectedState={nodes:t,parent:e},uc(e,n,r)}function aCe(e,t){const n=e.targetData.parent.data.enabledNodes[0];n&&(t.selectedState&&t.selectedState.parent.el!==e.targetData.parent.el?uc(e.targetData.parent,n,t):t.selectedState||uc(e.targetData.parent,n,t))}function oCe({currentParent:e,targetParent:t,initialParent:n,draggedNodes:r,initialIndex:i,targetNodes:a,state:o}){D1(n.el);const l=r.map(g=>g.data.value),f=[...Cd(e.el,e.data).filter(g=>!l.some(_=>Um(g,_)))],u=Cd(t.el,t.data),h=n.el===t.el&&t.data.config.sortable===!1;let m;a.length?(h?m=i:t.data.config.sortable===!1?m=t.data.enabledNodes.length:m=a[0].data.index,u.splice(m,0,...l)):(m=h?i:t.data.enabledNodes.length,u.splice(m,0,...l)),WO(e.el,e.data,f),WO(t.el,t.data,u),t.data.config.onTransfer&&t.data.config.onTransfer({sourceParent:e,targetParent:t,initialParent:n,draggedNodes:r,targetIndex:m,state:o,targetNodes:a}),e.data.config.onTransfer&&e.data.config.onTransfer({sourceParent:e,targetParent:t,initialParent:n,draggedNodes:r,targetIndex:m,state:o,targetNodes:a||[]})}function Cd(e,t){return[...t.getValues(e)]}function WO(e,t,n){t.setValues(n,e)}function sCe(e,t){Ql(e.e),zl=!0;const n=t.initialParent.data.config.handleEnd;n(t)}function pV(e){const t=Rr.get(e);t&&t.abortControllers.mainParent&&t.abortControllers.mainParent.abort()}function Kr(e){return"draggedNode"in e&&!!e.draggedNode}function Li(e){return"synthDragging"in e&&!!e.synthDragging}function lCe(e,t){t.abortControllers.mainParent=fb(e,{dragover:vy(t.config.handleParentDragover),handleParentPointerover:t.config.handleParentPointerover,scroll:vy(t.config.handleParentScroll),drop:vy(t.config.handleParentDrop),hasNestedParent:n=>{const r=Rr.get(n.target);r&&(r.nestedParent=n.detail.parent)},focus:vy(t.config.handleParentFocus)}),t.config.externalDragHandle&&t.config.externalDragHandle.el&&t.config.externalDragHandle.callback&&(t.abortControllers.externalDragHandle=fb(t.config.externalDragHandle.el,{pointerdown:n=>{if(!t.config.externalDragHandle||!t.config.externalDragHandle.callback)return;const r=t.config.externalDragHandle.callback();if(!B1(r)){console.warn("No draggable item found from external drag handle callback");return}const i=ho.get(r);if(!i)return;const a=r.parentNode;if(!(a instanceof HTMLElement))return;const o=Rr.get(a);o&&(We.pointerDown={parent:{el:a,data:o},node:{el:r,data:i},validated:!0},r.draggable=!0)}}))}function uCe(e){var t;const n=e.parent.data.config;e.node.data.abortControllers.mainNode=fb(e.node.el,{keydown:yi(n.handleNodeKeydown),dragstart:yi(n.handleDragstart),dragover:yi(n.handleNodeDragover),dragenter:yi(n.handleNodeDragenter),dragleave:yi(n.handleNodeDragleave),dragend:yi(n.handleDragend),drop:yi(n.handleNodeDrop),focus:yi(n.handleNodeFocus),blur:yi(n.handleNodeBlur),pointerup:yi(n.handleNodePointerup),pointercancel:yi(n.handlePointercancel),pointerdown:yi(n.handleNodePointerdown),handleNodePointerover:n.handleNodePointerover,touchmove:r=>{Kr(We)&&r.cancelable&&Yr(r)},contextmenu:r=>{Li(We)&&Yr(r)}}),e.node.el.draggable=!0,n.reapplyDragClasses(e.node.el,e.parent.data),(t=e.parent.data.config.plugins)==null||t.forEach(r=>{var i,a;(a=(i=r(e.parent.el))==null?void 0:i.setupNode)==null||a.call(i,e)})}function mV(e){var t;ho.set(e.node.el,e.node.data),(t=e.parent.data.config.plugins)==null||t.forEach(n=>{var r,i;(i=(r=n(e.parent.el))==null?void 0:r.setupNodeRemap)==null||i.call(r,e)})}function cCe(e,t){if(!Kr(We))return;const n=Li(We)?t.config.synthDropZoneClass:t.config.dropZoneClass;We.draggedNode.el===e&&Bf([e],n,!0)}function fCe(e){var t;(t=e.parent.data.config.plugins)==null||t.forEach(n=>{var r,i;(i=(r=n(e.parent.el))==null?void 0:r.tearDownNodeRemap)==null||i.call(r,e)})}function dCe(e){var t,n,r,i,a;(t=e.parent.data.config.plugins)==null||t.forEach(o=>{var l,f;(f=(l=o(e.parent.el))==null?void 0:l.tearDownNode)==null||f.call(l,e)}),e.node.el.draggable=!1,(r=(n=e.node.data)==null?void 0:n.abortControllers)!=null&&r.mainNode&&((a=(i=e.node.data)==null?void 0:i.abortControllers)==null||a.mainNode.abort())}function hCe(e){if(e.length===1&&e[0].addedNodes.length===1&&!(e[0].addedNodes[0]instanceof HTMLElement))return;const t=e[0].target;!(t instanceof HTMLElement)||!Rr.get(t)||D1(t)}function D1(e,t){var n;const r=Rr.get(e);if(!r)return;r.privateClasses=Array.from(e.classList);const i=[],a=r.config;for(let f=0;f<e.children.length;f++){const u=e.children[f];if(!B1(u)||u.id==="dnd-dragged-node-clone")continue;const h=ho.get(u);(t||!h)&&a.tearDownNode({parent:{el:e,data:r},node:{el:u,data:h}}),!a.disabled&&(!a.draggable||a.draggable&&a.draggable(u))&&i.push(u)}if(i.length!==r.getValues(e).length&&!a.disabled){console.warn("The number of draggable items defined in the parent element does not match the number of values. This may cause unexpected behavior.");return}const o=r.getValues(e),l=[];for(let f=0;f<i.length;f++){const u=i[f],h=ho.get(u);if(a.draggableValue&&!a.draggableValue(o[f]))continue;const m=Object.assign(h??{privateClasses:[],abortControllers:{}},{value:o[f],index:f});if(!Kr(We)&&We.activeState&&Um(We.activeState.node.data.value,m.value)&&uc({data:r,el:e},{el:u,data:m},We),Kr(We)&&Um(We.draggedNode.data.value,m.value)){We.draggedNode.data=m,We.draggedNode.el=u;const g=We.draggedNodes.find(_=>_.data.value===m.value);g&&(g.el=u)}l.push({el:u,data:m}),(t||!h)&&a.setupNode({parent:{el:e,data:r},node:{el:u,data:m}}),mV({parent:{el:e,data:r},node:{el:u,data:m}})}Rr.set(e,{...r,enabledNodes:l}),a.remapFinished(r),(n=r.config.plugins)==null||n.forEach(f=>{var u,h;(h=(u=f(e))==null?void 0:u.remapFinished)==null||h.call(u)})}function pCe(){We.remapJustFinished=!0,"draggedNode"in We&&(We.affectedNodes=[])}function mCe(e){return!!e.targetData.parent.data.config.nativeDrag}function gCe(e){var t;if(e.parent.data.config.multiDrag){if(We.selectedState)return[e.node,...(t=We.selectedState)==null?void 0:t.nodes.filter(n=>n.el!==e.node.el)]}else return[e.node];return[]}function vCe(e){Kr(We)&&(We.emit("scrollStarted",We),!Li(We)&&(We.preventEnter=!0,CA&&clearTimeout(CA),CA=setTimeout(()=>{We.preventEnter=!1,We.emit("scrollEnded",We)},100)))}function yCe(e,t){const n=e.targetData.parent.data.config;if(!n.nativeDrag||!mCe(e)||!gV({x:e.e.clientX,y:e.e.clientY,node:e.targetData.node,config:n})){Yr(e.e);return}let r=n.draggedNodes({parent:e.targetData.parent,node:e.targetData.node});r.length===0&&(r=[e.targetData.node]),n.dragstartClasses(e.targetData.node,r,n);const i=_Ce(e,r);if(n.onDragstart){const a={parent:e.targetData.parent,values:Cd(e.targetData.parent.el,e.targetData.parent.data),draggedNode:i.draggedNode,draggedNodes:i.draggedNodes,position:i.initialIndex,state:i};n.onDragstart(a)}}function bCe(e,t){var n,r;if(Ql(e.e),t.pointerDown={parent:e.targetData.parent,node:e.targetData.node,validated:!1},!gV({x:e.e.clientX,y:e.e.clientY,node:e.targetData.node,config:e.targetData.parent.data.config}))return;t.pointerDown.validated=!0,MCe(e,t,e.targetData.node);const i=e.targetData.parent.data;let a=[e.targetData.node];const o=e.e.ctrlKey||e.e.metaKey,l=e.e.shiftKey,f=e.targetData.node;if(o&&i.config.multiDrag){t.selectedState?t.selectedState.nodes.findIndex(u=>u.el===f.el)===-1?a=[...t.selectedState.nodes,f]:a=t.selectedState.nodes.filter(u=>u.el!==f.el):a=[f],gy(e.targetData.parent,a,e.targetData.node,t,!0);return}if(l&&i.config.multiDrag){const u=e.targetData.parent.data.enabledNodes;if(t.selectedState&&t.activeState)if(t.selectedState.parent.el!==e.targetData.parent.el){Ku(t.selectedState.nodes,t.selectedState.parent,t),t.selectedState=void 0;for(let h=0;h<=f.data.index;h++)a.push(u[h])}else{const[h,m]=t.activeState.node.data.index<e.targetData.node.data.index?[t.activeState.node.data.index,e.targetData.node.data.index]:[e.targetData.node.data.index,t.activeState.node.data.index];a=u.slice(h,m+1)}else for(let h=0;h<=f.data.index;h++)a.push(u[h]);gy(e.targetData.parent,a,e.targetData.node,t,!0);return}(r=(n=t.selectedState)==null?void 0:n.nodes)!=null&&r.length?t.selectedState.nodes.findIndex(u=>u.el===e.targetData.node.el)===-1&&(t.selectedState.parent.el!==e.targetData.parent.el?Ku(t.selectedState.nodes,e.targetData.parent,t):i.config.multiDrag&&fV()?a.push(...t.selectedState.nodes):Ku(t.selectedState.nodes,e.targetData.parent,t),gy(e.targetData.parent,a,e.targetData.node,t,!0)):gy(e.targetData.parent,[e.targetData.node],e.targetData.node,t,!0)}function wCe(e,t,n,r=!1){Bf(t.map(i=>i.el),r?n.synthDraggingClass:n.draggingClass),setTimeout(()=>{Tl(t.map(i=>i.el),r?n.synthDraggingClass:n.draggingClass),Bf(t.map(i=>i.el),r?n.synthDragPlaceholderClass:n.dragPlaceholderClass),Bf(t.map(i=>i.el),r?n.synthDropZoneClass:n.dropZoneClass),Tl(t.map(i=>i.el),n.selectedClass)})}function _Ce(e,t){Ql(e.e);const n=dV(hV(e.targetData.node,e.targetData.parent,e.e,t));if(e.e.dataTransfer){const r=e.targetData.parent.data.config;e.e.dataTransfer.dropEffect=r.dragDropEffect,e.e.dataTransfer.effectAllowed=r.dragEffectAllowed;let i;if(e.e.dataTransfer.setData("text/plain",""),r.dragImage)i=r.dragImage(e,t);else{if(!r.multiDrag||t.length===1)return e.targetData.node.el.style.zIndex="9999",e.targetData.node.el.style.boxSizing="border-box",e.e.dataTransfer.setDragImage(e.targetData.node.el,e.e.offsetX,e.e.offsetY),n.originalZIndex=e.targetData.node.el.style.zIndex,n;{const a=document.createElement("div");a.setAttribute("id","dnd-dragged-node-clone"),a.setAttribute("popover","manual");for(const l of t){const f=l.el.cloneNode(!0);f.id=l.el.id+"-clone",f.style.pointerEvents="none",a.appendChild(f)}const{width:o}=t[0].el.getBoundingClientRect();Object.assign(a.style,{display:"flex",flexDirection:"column",width:`${o}px`,position:"absolute",pointerEvents:"none",zIndex:"9999",left:"-9999px",boxSizing:"border-box",background:"transparent",overflow:"hidden"}),e.targetData.parent.el.appendChild(a),a.showPopover(),a.getBoundingClientRect(),i=a,e.e.dataTransfer.setDragImage(i,e.e.offsetX,e.e.offsetY)}}setTimeout(()=>{i==null||i.remove()})}return n}function gV({x:e,y:t,node:n,config:r}){if(r.externalDragHandle)return!1;if(!r.dragHandle)return!0;const i=n.el.querySelectorAll(r.dragHandle);if(!i)return!1;const a=r.root.elementFromPoint(e,t);if(!a)return!1;for(const o of Array.from(i))if(a===o||o.contains(a))return!0;return!1}function xCe(e){}function SCe(e){e.detail.targetData.parent.el===e.detail.state.currentParent.el?yV(e.detail,e.detail.state):I1(e.detail,e.detail.state)}function CCe(e,t){const n=e.targetData.parent.data.config;n.nativeDrag&&(Ql(e.e),zl=!0,n.handleEnd(t))}function ACe(e){e.e.target!==e.e.currentTarget&&We.pointerDown&&(We.pointerDown.node.el.draggable=!1)}function ECe(e){e.e.target!==e.e.currentTarget&&We.pointerDown&&(We.pointerDown.node.el.draggable=!0)}function OCe(e,t){const n=e.targetData.parent.data.config;if(n.nativeDrag){if(Yr(e.e),Ql(e.e),zl){zl=!1;return}n.handleEnd(t)}}function TCe(e,t){var n;if(!Li(t))return;if(Yr(e.e),zl){zl=!1;return}const r=(n=Rr.get(t.initialParent.el))==null?void 0:n.config;r!=null&&r.onDragend&&r.onDragend({parent:t.currentParent,values:Cd(t.currentParent.el,t.currentParent.data),draggedNode:t.draggedNode,draggedNodes:t.draggedNodes,state:t}),r==null||r.handleEnd(t)}function jCe(e){var t,n,r,i,a;e.draggedNode&&(e.draggedNode.el.draggable=!0);const o=e.draggedNodes.map(b=>b.el),l=e.initialParent.data,f=Li(e),u=(t=Rr.get(e.initialParent.el))==null?void 0:t.config,h=f?u==null?void 0:u.synthDropZoneClass:u==null?void 0:u.dropZoneClass,m=(n=l==null?void 0:l.config)==null?void 0:n.longPressClass,g=f?(r=l==null?void 0:l.config)==null?void 0:r.synthDragPlaceholderClass:(i=l==null?void 0:l.config)==null?void 0:i.dragPlaceholderClass,_=e.originalZIndex;Li(e)&&(e.clonedDraggedNode&&e.clonedDraggedNode.remove(),e.longPressTimeout&&clearTimeout(e.longPressTimeout)),YO(e),e.lastScrollDirectionX=void 0,e.lastScrollDirectionY=void 0,e.preventEnter=!1,e.scrollDebounceTimeout&&(clearTimeout(e.scrollDebounceTimeout),e.scrollDebounceTimeout=void 0),_!==void 0&&e.draggedNode&&(e.draggedNode.el.style.zIndex=_),requestAnimationFrame(()=>{Tl(o,h),Tl(o,m),Tl(o,g)}),Ku(e.draggedNodes,e.currentParent,e),uc(e.currentParent,void 0,e);const x={...e};(a=u==null?void 0:u.onDragend)==null||a.call(u,{parent:x.currentParent,values:Cd(x.currentParent.el,x.currentParent.data),draggedNode:x.draggedNode,draggedNodes:x.draggedNodes,state:x}),e.emit("dragEnded",x),ZSe()}function PCe(e,t){Ql(e.e),!t.pointerSelection&&t.selectedState&&Ku(t.selectedState.nodes,e.targetData.parent,t);const n=e.targetData.parent.data.config;t.pointerSelection=!1,"longPressTimeout"in t&&t.longPressTimeout&&clearTimeout(t.longPressTimeout),t.longPress=!1,Tl(e.targetData.parent.data.enabledNodes.map(r=>r.el),n.longPressClass),Kr(t)&&n.handleEnd(t)}function RCe(e,t,n,r,i,a){var o,l;const f=t.data.config;let u,h;const m=["display","flexDirection","alignItems","justifyContent","padding","paddingTop","margin","marginTop","marginBottom","marginLeft","marginRight","paddingBottom","paddingLeft","paddingRight","border","borderRadius","background","backgroundColor","boxShadow","font","color","lineHeight","gap","width","height","boxSizing","overflow"],g=(b,S)=>{const C=window.getComputedStyle(b);m.forEach(A=>{S.style[A]=C[A]})},_=(b,S={})=>{Object.assign(b.style,{position:"absolute",zIndex:"9999",pointerEvents:"none",willChange:"transform",boxSizing:"border-box",opacity:"0",overflow:"hidden",width:`${a.width}px`,height:`${a.height}px`,...S})};if(f.synthDragImage)h=f.synthDragImage(e,t,n,i),u=h.dragImage,u.setAttribute("popover","manual"),_(u);else if(!f.multiDrag||i.length===1)u=e.el.cloneNode(!0),g(e.el,u),u.setAttribute("popover","manual"),_(u);else{const b=document.createElement("div");b.setAttribute("popover","manual"),i.forEach(S=>{const C=S.el.cloneNode(!0);g(S.el,C),C.style.pointerEvents="none",C.style.margin="0",b.append(C)}),b.style.display="flex",b.style.flexDirection="column",b.style.padding="0",b.style.margin="0",b.style.position="absolute",b.style.zIndex="9999",b.style.pointerEvents="none",u=b}u.id="dnd-dragged-node-clone",t.el.appendChild(u),u.showPopover();const x={clonedDraggedEls:[],clonedDraggedNode:u,synthDragScrolling:!1,synthDragging:!0,rootScrollWidth:(o=document.scrollingElement)==null?void 0:o.scrollWidth,rootScrollHeight:(l=document.scrollingElement)==null?void 0:l.scrollHeight};return dV({...hV(e,t,n,i,h==null?void 0:h.offsetX,h==null?void 0:h.offsetY),...x})}function MCe(e,t,n){const r=e.targetData.parent.data.config;t.longPressTimeout=setTimeout(()=>{t&&(t.longPress=!0,r.longPressClass&&e.e.cancelable&&Bf([n.el],r.longPressClass),Yr(e.e))},r.longPressDuration||1e3)}function YO(e,t=!0,n=!0){t&&(e.frameIdX!==void 0&&(cancelAnimationFrame(e.frameIdX),e.frameIdX=void 0),e.lastScrollDirectionX=void 0),n&&(e.frameIdY!==void 0&&(cancelAnimationFrame(e.frameIdY),e.frameIdY=void 0),e.lastScrollDirectionY=void 0),!e.frameIdX&&!e.frameIdY&&(e.preventEnter=!1)}function vV(e,t=!1){var n;const{x:r,y:i}=e.coordinates,a=e.startLeft??0,o=e.startTop??0,l=window.scrollX??0,f=window.scrollY??0,u=r-a+l,h=i-o+f;e.clonedDraggedNode.style.transform=`translate3d(${u}px, ${h}px, 0px)`,t&&(e.clonedDraggedNode.style.opacity="1",Tl(e.draggedNodes.map(m=>m.el),(n=e.initialParent.data.config)==null?void 0:n.longPressClass))}function f7(e,t,n=!1){const r=Kd(e);t.coordinates.x=r.x,t.coordinates.y=r.y,vV(t,n),t.scrollDebounceTimeout&&(clearTimeout(t.scrollDebounceTimeout),t.scrollDebounceTimeout=void 0),t.scrollDebounceTimeout=setTimeout(()=>{Li(t)&&$1(t.coordinates,e,t)},16);const i=FCe(r);if(!i){document.dispatchEvent(new CustomEvent("handleRootPointerover",{detail:{e,state:t}}));return}const a={e,targetData:i,state:t};"node"in i?i.node.el.dispatchEvent(new CustomEvent("handleNodePointerover",{detail:a})):i.parent.el.dispatchEvent(new CustomEvent("handleParentPointerover",{detail:a}))}function NCe(e,t){var n;if(!e.targetData.parent.data.config.nativeDrag)return;const{x:r,y:i}=Kd(e.e);t.coordinates.y=i,t.coordinates.x=r,Yr(e.e),Ql(e.e),Kr(t)&&$1({x:r,y:i},e.e,t),e.targetData.parent.el===((n=t.currentParent)==null?void 0:n.el)?yV(e,t):I1(e,t)}function LCe(e,t){if(!e.targetData.parent.data.config.nativeDrag)return;Yr(e.e),Ql(e.e);const{x:n,y:r}=Kd(e.e);Kr(t)&&$1({x:n,y:r},e.e,t),I1(e,t)}function kCe(e){e.detail.targetData.parent.el!==e.detail.state.currentParent.el&&I1(e.detail,e.detail.state)}function DCe({currentParent:e,targetParent:t,initialParent:n,draggedNodes:r,state:i}){if(t.el===e.el)return!1;const a=t.data.config;if(r[0].el.contains(t.el)||a.dropZone===!1)return!1;const o=n.data.config;return a.accepts?a.accepts(t,n,e,i):!(!a.group||a.group!==o.group)}function ICe(e,t){Yr(e.e)}function $Ce(e,t){Yr(e.e)}function BCe(e,t,n,r){var i;if(t.affectedNodes.map(m=>m.data.value).includes(e.targetData.node.data.value))return!1;if(t.remapJustFinished)return t.remapJustFinished=!1,(e.targetData.node.data.value===t.currentTargetValue||t.draggedNodes.map(m=>m.el).includes(e.targetData.node.el))&&(t.currentTargetValue=e.targetData.node.data.value),!1;if(t.preventEnter)return!1;if(t.draggedNodes.map(m=>m.el).includes(e.targetData.node.el))return t.currentTargetValue=void 0,!1;if(e.targetData.node.data.value===t.currentTargetValue||e.targetData.parent.el!==((i=t.currentParent)==null?void 0:i.el)||e.targetData.parent.data.config.sortable===!1||e.targetData.node.el.contains(t.draggedNodes[0].el))return!1;const a=e.targetData.node.el.getBoundingClientRect(),o=t.draggedNode.el.getBoundingClientRect(),l=a.y-o.y,f=a.x-o.x;let u;Math.abs(l)>Math.abs(f)?u=l>0?"above":"below":u=f>0?"left":"right";const h=t.currentParent.data.config.threshold;switch(u){case"left":if(n>a.x+a.width*h.horizontal)return t.incomingDirection="left",!0;break;case"right":if(n<a.x+a.width*(1-h.horizontal))return t.incomingDirection="right",!0;break;case"above":if(r>a.y+a.height*h.vertical)return t.incomingDirection="above",!0;break;case"below":if(r<a.y+a.height*(1-h.vertical))return t.incomingDirection="below",!0;break}return!1}function yV(e,t){const{x:n,y:r}=Kd(e.e);if(!BCe(e,t,n,r))return;const i=t.draggedNode.data.index>e.targetData.node.data.index?[e.targetData.node.data.index,t.draggedNode.data.index]:[t.draggedNode.data.index,e.targetData.node.data.index];t.targetIndex=e.targetData.node.data.index,t.affectedNodes=e.targetData.parent.data.enabledNodes.filter(a=>i[0]<=a.data.index&&a.data.index<=i[1]&&a.el!==t.draggedNode.el),e.targetData.parent.data.config.performSort({parent:e.targetData.parent,draggedNodes:t.draggedNodes,targetNodes:[e.targetData.node]})}function yi(e){function t(n){const r=ho.get(n);if(!r)return;const i=Rr.get(n.parentNode);if(i)return{node:{el:n,data:r},parent:{el:n.parentNode,data:i}}}return n=>{const r=t(n.currentTarget);if(r)return e({e:n,targetData:r},We)}}function I1(e,t){Yr(e.e),DCe({currentParent:t.currentParent,targetParent:e.targetData.parent,initialParent:t.initialParent,draggedNodes:t.draggedNodes,state:t})&&(e.targetData.parent.data.config.performTransfer({currentParent:t.currentParent,targetParent:e.targetData.parent,initialParent:t.initialParent,draggedNodes:t.draggedNodes,initialIndex:t.initialIndex,state:t,targetNodes:"node"in e.targetData?[e.targetData.node]:[]}),t.currentParent=e.targetData.parent,t.transferred=!0)}function vy(e){function t(n){const r=Rr.get(n);if(r)return{parent:{el:n,data:r}}}return n=>{const r=t(n.currentTarget);if(r)return e({e:n,targetData:r},We)}}function Bf(e,t,n=!1){function r(i,a){ho.set(i,a)}for(const i of e){const a=ho.get(i),o=UCe(i,t,a,n);o&&r(i,o)}}function UCe(e,t,n,r=!1){if(!t)return;const i=cV(t);if(!i.length)return;if(!n){e.classList.add(...i);return}const a=[];for(const o of i)e.classList.contains(o)?e.classList.contains(o)&&r===!1&&a.push(o):e.classList.add(o);return n.privateClasses=a,n}function Tl(e,t){if(!t)return;const n=cV(t);if(n.length)for(const r of e){if(!B1(r)){r.classList.remove(...n);continue}const i=ho.get(r)||Rr.get(r);if(i)for(const a of n)i.privateClasses.includes(a)||r.classList.remove(a)}}function d7(e,t,n,r,i){const a=i.axis==="x",o=e===document.scrollingElement,l=a?"scrollLeft":"scrollTop",f=a?"clientWidth":"clientHeight",u=a?"offsetWidth":"offsetHeight",h=a?"scrollWidth":"scrollHeight",m=a?t.clientX:t.clientY,g=a?r.left:r.top,_=a?n.overflowX:n.overflowY;if(o){const x=e[l],b=e[f],S=x>0,C=x+b<(a?i.state.rootScrollWidth||0:e[h]);return a?{left:S&&m<b*.075,right:C&&m>b*(1-.075)}:{up:S&&m<b*.075,down:C&&m>b*(1-.075)}}if((_==="auto"||_==="scroll")&&e!==document.body&&e!==document.documentElement){const x=e[h],b=e[u],S=e[l],C=S>0,A=S<x-b;return a?{left:C&&m<g+b*.075,right:A&&m>g+b*(1-.075)}:{up:C&&m<g+b*.075,down:A&&m>g+b*(1-.075)}}return a?{left:!1,right:!1}:{up:!1,down:!1}}function zCe(e,t,n,r){if(!Kr(n)||!n.draggedNode)return;n.preventEnter=!0;const i=r.axis==="x",a=r.direction==="positive"?1:-1,o=20,l=i?"lastScrollDirectionX":"lastScrollDirectionY",f=i?"frameIdX":"frameIdY";n[f]!==void 0&&(cancelAnimationFrame(n[f]),n[f]=void 0),n[l]=r.direction;const u=()=>{if(!Kr(n)||!n.draggedNode){n[f]!==void 0&&(cancelAnimationFrame(n[f]),n[f]=void 0);return}const h=i?"scrollLeft":"scrollTop",m=i?"clientWidth":"clientHeight",g=i?"scrollWidth":"scrollHeight",_=e[h],x=e[m],b=e[g];if(!(a>0?_+x<b:_>0)){n[f]=void 0,n[l]=void 0;return}e[h]+=o*a,Li(n)&&vV(n),n[f]=requestAnimationFrame(u)};n[f]=requestAnimationFrame(u)}function h7(e,t,n){const r=e.getBoundingClientRect();return t>=r.left&&t<=r.right&&n>=r.top&&n<=r.bottom}function $1(e,t,n){if(!Kr(n)||!n.draggedNode)return;YO(n);const{x:r,y:i}=e;let a=!1;const o=(f,u,h)=>{zCe(h,t,n,{axis:f,direction:u}),a=!0},l=f=>{const u=window.getComputedStyle(f),h=f.getBoundingClientRect(),m=d7(f,t,u,h,{axis:"x",state:n}),g=d7(f,t,u,h,{axis:"y"});(m.left||m.right)&&(n.lastScrollContainerX=f,o("x",m.right?"positive":"negative",f)),(g.up||g.down)&&(n.lastScrollContainerY=f,o("y",g.down?"positive":"negative",f))};if(n.lastScrollContainerX&&h7(n.lastScrollContainerX,r,i)&&l(n.lastScrollContainerX),!a&&n.lastScrollContainerY&&h7(n.lastScrollContainerY,r,i)&&l(n.lastScrollContainerY),!a){let f=document.elementFromPoint(r,i);for(;f&&!(a&&n.lastScrollContainerX&&n.lastScrollContainerY);)f instanceof HTMLElement&&l(f),f=f.parentElement}if(!a){const f=document.scrollingElement;f instanceof HTMLElement&&l(f)}a||YO(n)}function FCe(e){let t=document.elementFromPoint(e.x,e.y);if(!B1(t))return;let n,r=!0;for(;t&&r;){if(ho.has(t)||Rr.has(t)){r=!1,n=Rr.has(t);break}t=t.parentNode}if(n){const i=Rr.get(t);return i?{parent:{el:t,data:i}}:void 0}else{const i=ho.get(t);if(!i)return;const a=Rr.get(t.parentNode);return a?{node:{el:t,data:i},parent:{el:t.parentNode,data:a}}:void 0}}function B1(e){return e instanceof HTMLElement&&e.parentNode instanceof HTMLElement}function fb(e,t){const n=new AbortController;for(const r in t){const i=t[r];e.addEventListener(r,i,{signal:n.signal,passive:!1,capture:r==="focus"||r==="blur"})}return n}function qCe(e){if(e instanceof HTMLElement)return e;if("current"in e&&e.current instanceof HTMLElement)return e.current;console.warn("Invalid parent element",e)}function VCe(e,t){const n=qCe(e);n&&t(n)}var db=new WeakMap;function HCe(e){const t=db.get(e);return t?t[0]:(console.warn("No values found for parent element"),[])}function GCe(e,t){const n=db.get(t);n&&n[1](e),db.set(t,[e,n[1]])}function WCe(e,t){return n=>{db.set(n,t),rCe({parent:n,getValues:HCe,setValues:GCe,config:e})}}function p7(e){y4&&(Array.isArray(e)||(e=[e]),e.forEach(t=>{const{parent:n,state:r,...i}=t;VCe(n,WCe(i,r))}))}function YCe(e,t={}){const n=M.useRef(null),[r,i]=M.useState(e);function a(o={}){p7({parent:n,state:[r,i],...o})}return M.useEffect(()=>{p7({parent:n,state:[r,i],...t})},[r]),M.useEffect(()=>()=>{n.current&&pV(n.current)},[]),[n,r,i,a]}const U1=()=>{const e=po(),t=vs(),n=Pd(),r=M.useMemo(()=>{const{orderBy:a,tags:o,excludeBots:l,excludeMaxVisitsReached:f,excludePastValidUntil:u,...h}=n,m=a?YJ(a):void 0,g=(o==null?void 0:o.split(","))??[];return{...h,orderBy:m,tags:g,excludeBots:l!==void 0?l==="true":void 0,excludeMaxVisitsReached:f!==void 0?f==="true":void 0,excludePastValidUntil:u!==void 0?u==="true":void 0}},[n]),i=M.useCallback(a=>{const o={...r,...a},{orderBy:l,tags:f,excludeBots:u,excludeMaxVisitsReached:h,excludePastValidUntil:m,...g}=o,_={...g,orderBy:l&&WJ(l),tags:f.length>0?f.join(","):void 0,excludeBots:_A(u),excludeMaxVisitsReached:_A(h),excludePastValidUntil:_A(m)},x=PT(_),b=x?`?${x}`:"";e(`${t}/list-short-urls/1${b}`)},[r,e,t]);return[r,i]},b4=()=>{const{domain:e}=Pd(),{shortCode:t=""}=Td();return M.useMemo(()=>({shortCode:m4(t),domain:e}),[e,t])},z1=()=>{const e=KJ();return v.jsx(Zb,{size:"lg",className:"tw:[&]:p-1 tw:mr-4",onClick:e,"aria-label":"Go back",children:v.jsx(Ye,{icon:KZ})})},KCe={AF:"Afghanistan",AL:"Albania",DZ:"Algeria",AS:"American Samoa",AD:"Andorra",AO:"Angola",AI:"Anguilla",AQ:"Antarctica",AG:"Antigua and Barbuda",AR:"Argentina",AM:"Armenia",AW:"Aruba",AU:"Australia",AT:"Austria",AZ:"Azerbaijan",BS:"Bahamas",BH:"Bahrain",BD:"Bangladesh",BB:"Barbados",BY:"Belarus",BE:"Belgium",BZ:"Belize",BJ:"Benin",BM:"Bermuda",BT:"Bhutan",BO:"Bolivia",BA:"Bosnia and Herzegovina",BW:"Botswana",BR:"Brazil",IO:"British Indian Ocean Territory",VG:"British Virgin Islands",BN:"Brunei",BG:"Bulgaria",BF:"Burkina Faso",BI:"Burundi",KH:"Cambodia",CM:"Cameroon",CA:"Canada",CV:"Cape Verde",KY:"Cayman Islands",CF:"Central African Republic",TD:"Chad",CL:"Chile",CN:"China",CX:"Christmas Island",CC:"Cocos Islands",CO:"Colombia",KM:"Comoros",CK:"Cook Islands",CR:"Costa Rica",HR:"Croatia",CU:"Cuba",CW:"Curacao",CY:"Cyprus",CZ:"Czech Republic",CD:"Democratic Republic of the Congo",DK:"Denmark",DJ:"Djibouti",DM:"Dominica",DO:"Dominican Republic",TL:"East Timor",EC:"Ecuador",EG:"Egypt",SV:"El Salvador",GQ:"Equatorial Guinea",ER:"Eritrea",EE:"Estonia",ET:"Ethiopia",FK:"Falkland Islands",FO:"Faroe Islands",FJ:"Fiji",FI:"Finland",FR:"France",PF:"French Polynesia",GA:"Gabon",GM:"Gambia",GE:"Georgia",DE:"Germany",GH:"Ghana",GI:"Gibraltar",GR:"Greece",GL:"Greenland",GD:"Grenada",GU:"Guam",GT:"Guatemala",GG:"Guernsey",GN:"Guinea",GW:"Guinea-Bissau",GY:"Guyana",HT:"Haiti",HN:"Honduras",HK:"Hong Kong",HU:"Hungary",IS:"Iceland",IN:"India",ID:"Indonesia",IR:"Iran",IQ:"Iraq",IE:"Ireland",IM:"Isle of Man",IL:"Israel",IT:"Italy",CI:"Ivory Coast",JM:"Jamaica",JP:"Japan",JE:"Jersey",JO:"Jordan",KZ:"Kazakhstan",KE:"Kenya",KI:"Kiribati",XK:"Kosovo",KW:"Kuwait",KG:"Kyrgyzstan",LA:"Laos",LV:"Latvia",LB:"Lebanon",LS:"Lesotho",LR:"Liberia",LY:"Libya",LI:"Liechtenstein",LT:"Lithuania",LU:"Luxembourg",MO:"Macao",MK:"Macedonia",MG:"Madagascar",MW:"Malawi",MY:"Malaysia",MV:"Maldives",ML:"Mali",MT:"Malta",MH:"Marshall Islands",MR:"Mauritania",MU:"Mauritius",YT:"Mayotte",MX:"Mexico",FM:"Micronesia",MD:"Moldova",MC:"Monaco",MN:"Mongolia",ME:"Montenegro",MS:"Montserrat",MA:"Morocco",MZ:"Mozambique",MM:"Myanmar",NA:"Namibia",NR:"Nauru",NP:"Nepal",NL:"Netherlands",AN:"Netherlands Antilles",NC:"New Caledonia",NZ:"New Zealand",NI:"Nicaragua",NE:"Niger",NG:"Nigeria",NU:"Niue",KP:"North Korea",MP:"Northern Mariana Islands",NO:"Norway",OM:"Oman",PK:"Pakistan",PW:"Palau",PS:"Palestine",PA:"Panama",PG:"Papua New Guinea",PY:"Paraguay",PE:"Peru",PH:"Philippines",PN:"Pitcairn",PL:"Poland",PT:"Portugal",PR:"Puerto Rico",QA:"Qatar",CG:"Republic of the Congo",RE:"Reunion",RO:"Romania",RU:"Russia",RW:"Rwanda",BL:"Saint Barthelemy",SH:"Saint Helena",KN:"Saint Kitts and Nevis",LC:"Saint Lucia",MF:"Saint Martin",PM:"Saint Pierre and Miquelon",VC:"Saint Vincent and the Grenadines",WS:"Samoa",SM:"San Marino",ST:"Sao Tome and Principe",SA:"Saudi Arabia",SN:"Senegal",RS:"Serbia",SC:"Seychelles",SL:"Sierra Leone",SG:"Singapore",SX:"Sint Maarten",SK:"Slovakia",SI:"Slovenia",SB:"Solomon Islands",SO:"Somalia",ZA:"South Africa",KR:"South Korea",SS:"South Sudan",ES:"Spain",LK:"Sri Lanka",SD:"Sudan",SR:"Suriname",SJ:"Svalbard and Jan Mayen",SZ:"Swaziland",SE:"Sweden",CH:"Switzerland",SY:"Syria",TW:"Taiwan",TJ:"Tajikistan",TZ:"Tanzania",TH:"Thailand",TG:"Togo",TK:"Tokelau",TO:"Tonga",TT:"Trinidad and Tobago",TN:"Tunisia",TR:"Turkey",TM:"Turkmenistan",TC:"Turks and Caicos Islands",TV:"Tuvalu",VI:"U.S. Virgin Islands",UG:"Uganda",UA:"Ukraine",AE:"United Arab Emirates",GB:"United Kingdom",US:"United States",UY:"Uruguay",UZ:"Uzbekistan",VU:"Vanuatu",VA:"Vatican",VE:"Venezuela",VN:"Vietnam",WF:"Wallis and Futuna",EH:"Western Sahara",YE:"Yemen",ZM:"Zambia",ZW:"Zimbabwe"},ZCe={android:"Android",ios:"iOS",desktop:"Desktop"},XCe=({deviceType:e,onDeviceTypeChange:t})=>v.jsxs(KT,{label:"Device type:",value:e,onChange:n=>t(n.target.value),hiddenRequired:!0,children:[!e&&v.jsx("option",{value:"",children:"- Select type -"}),Object.entries(ZCe).map(([n,r])=>v.jsx("option",{value:n,children:r},n))]}),w4=({value:e,onValueChange:t,label:n,placeholder:r})=>v.jsx(ta,{label:`${n}:`,value:e??"",onChange:i=>t(i.target.value),placeholder:r,hiddenRequired:!0}),QCe=({language:e,onLanguageChange:t})=>v.jsx(w4,{value:e,onValueChange:t,label:"Language",placeholder:"en-US / en"}),JCe=({name:e,value:t,onNameChange:n,onValueChange:r})=>v.jsxs(v.Fragment,{children:[v.jsx(ta,{label:"Param name:",value:e??"",onChange:i=>n(i.target.value),placeholder:"hello",hiddenRequired:!0}),v.jsx(ta,{label:"Param value:",value:t??"",onChange:i=>r(i.target.value),placeholder:"world",hiddenRequired:!0})]}),eAe=({ipAddress:e,onIpAddressChange:t})=>v.jsx(w4,{value:e,onValueChange:t,label:"IP address",placeholder:"192.168.1.10"}),tAe=({countryCode:e,onCountryCodeChange:t})=>v.jsxs(KT,{label:"Country:",value:e,onChange:n=>t(n.target.value),hiddenRequired:!0,children:[!e&&v.jsx("option",{value:"",children:"- Select country -"}),Object.entries(KCe).map(([n,r])=>v.jsx("option",{value:n,children:r},n))]}),nAe=({cityName:e,onCityNameChange:t})=>v.jsx(w4,{value:e,onValueChange:t,label:"City name",placeholder:"New York"}),rAe=({condition:e,onConditionChange:t,onDelete:n})=>{const r=M.useCallback(u=>t({type:u,matchValue:"",matchKey:null}),[t]),i=M.useCallback(u=>t({...e,matchValue:u}),[e,t]),a=M.useCallback(u=>t({...e,matchKey:u}),[e,t]),o=fo("ipRedirectCondition"),l=fo("geolocationRedirectCondition"),f=M.useMemo(()=>{const u={device:"Device type",language:"Language","query-param":"Query param"};return o&&(u["ip-address"]="IP address"),l&&(u["geolocation-country-code"]="Country (geolocation)",u["geolocation-city-name"]="City name (geolocation)"),u},[l,o]);return v.jsxs("div",{className:be("tw:flex tw:flex-col tw:gap-2","tw:border tw:border-lm-border tw:dark:border-dm-border","tw:rounded-md tw:relative tw:p-4 tw:h-full"),children:[v.jsxs("div",{children:[v.jsx(Tn,{variant:"secondary","aria-label":"Remove condition",onClick:n,className:be("tw:absolute tw:-top-3.5 tw:-right-3.5 tw:[&]:px-2","tw:[&]:rounded-full tw:bg-lm-primary tw:dark:bg-dm-primary"),children:v.jsx(Ye,{icon:jb})}),v.jsx(KT,{label:"Type:",value:e.type,onChange:u=>r(u.target.value),hiddenRequired:!0,children:Object.entries(f).map(([u,h])=>v.jsx("option",{value:u,children:h},u))})]}),e.type==="device"&&v.jsx(XCe,{deviceType:e.matchValue,onDeviceTypeChange:i}),e.type==="language"&&v.jsx(QCe,{language:e.matchValue,onLanguageChange:i}),e.type==="query-param"&&v.jsx(JCe,{value:e.matchValue,name:e.matchKey??"",onNameChange:a,onValueChange:i}),e.type==="ip-address"&&v.jsx(eAe,{ipAddress:e.matchValue,onIpAddressChange:i}),e.type==="geolocation-country-code"&&v.jsx(tAe,{countryCode:e.matchValue,onCountryCodeChange:i}),e.type==="geolocation-city-name"&&v.jsx(nAe,{cityName:e.matchValue,onCityNameChange:i})]})},bV=({isOpen:e,onClose:t,onSave:n,initialData:r})=>{const[i,a]=M.useState(r??{longUrl:"",conditions:[]}),o=M.useCallback(()=>{i&&n(i),t()},[n,i,t]),l=M.useCallback(()=>a(({longUrl:g,conditions:_})=>({longUrl:g,conditions:[..._,{type:"device",matchValue:"",matchKey:null}]})),[]),f=M.useCallback((g,_)=>a(({longUrl:x,conditions:b})=>{const S=[...b];return S[g]=_,{longUrl:x,conditions:S}}),[]),u=M.useCallback(g=>a(({longUrl:_,conditions:x})=>{const b=[...x];return b.splice(g,1),{longUrl:_,conditions:b}}),[]),h=M.useRef(null),m=M.useCallback(()=>a(r??{longUrl:"",conditions:[]}),[r]);return M.useEffect(()=>{const g=new MutationObserver(()=>{h.current&&e&&(h.current.focus(),g.disconnect())});return g.observe(document.body,{childList:!0,subtree:!0}),()=>g.disconnect()},[e]),v.jsxs(Vl,{size:"xl",title:"Redirect rule",open:e,onClose:t,onClosed:m,onConfirm:o,confirmDisabled:i.conditions.length===0,confirmText:"Confirm",children:[v.jsx(ta,{label:"Long URL:",type:"url",placeholder:"https://www.example.com",value:i.longUrl,onChange:g=>a(_=>({..._,longUrl:g.target.value})),hiddenRequired:!0,ref:h}),v.jsx("hr",{}),v.jsxs("div",{className:"tw:flex tw:justify-between",children:[v.jsx("b",{children:"Conditions:"}),v.jsx(Tn,{className:"tw:[&]:px-1.5",variant:"secondary","aria-label":"Add condition",onClick:l,children:v.jsx(Ye,{icon:Km})})]}),i.conditions.length===0&&v.jsx("div",{className:"tw:text-center",children:v.jsx("i",{children:"Add conditions..."})}),i.conditions.length>0&&v.jsx("div",{className:"tw:pr-3 tw:mt-6 tw:grid tw:grid-cols-1 tw:md:grid-cols-2 tw:lg:grid-cols-3 tw:gap-6",children:i.conditions.map((g,_)=>v.jsx(rAe,{condition:g,onConditionChange:x=>f(_,x),onDelete:()=>u(_)},`${_}_${g.type}`))})]})},iAe=({priority:e,isLast:t,redirectRule:n,onDelete:r,onMoveUp:i,onMoveDown:a,onUpdate:o})=>{const{flag:l,setToTrue:f,setToFalse:u}=wn(!1,!0);return v.jsxs(qt,{children:[v.jsxs("div",{className:"tw:flex tw:align-center tw:gap-4",children:[v.jsx("div",{className:"tw:flex tw:flex-col tw:my-auto tw:hidden tw:md:block tw:cursor-grab drag-n-drop-handler",children:v.jsx(Ye,{icon:nX})}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:my-auto",children:[v.jsx(Tn,{variant:"secondary","aria-label":`Move rule with priority ${e} up`,disabled:e===1,onClick:i,className:"tw:[&]:px-2 tw:rounded-b-none tw:mb-[-1px]",children:v.jsx(Ye,{icon:pX})}),v.jsx(Tn,{variant:"secondary","aria-label":`Move rule with priority ${e} down`,disabled:t,onClick:a,className:"tw:[&]:px-2 tw:rounded-t-none",children:v.jsx(Ye,{icon:cX})})]}),v.jsxs("div",{className:"tw:grow",children:[v.jsxs("div",{className:"tw:mb-2",children:[v.jsx("b",{children:"Long URL:"})," ",v.jsx(Oi,{href:n.longUrl,"data-testid":"rule-long-url"})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row tw:gap-2",children:[v.jsx("b",{children:"Conditions:"}),n.conditions.map((h,m)=>v.jsxs("div",{className:"tw:rounded-sm tw:bg-gray-600 tw:px-1 tw:text-white",children:[h.type==="device"&&v.jsxs(v.Fragment,{children:["Device is ",h.matchValue]}),h.type==="language"&&v.jsxs(v.Fragment,{children:[h.matchValue," language is accepted"]}),h.type==="query-param"&&v.jsxs(v.Fragment,{children:["Query string contains ",h.matchKey,"=",h.matchValue]}),h.type==="ip-address"&&v.jsxs(v.Fragment,{children:["IP address matches ",h.matchValue]}),h.type==="geolocation-country-code"&&v.jsxs(v.Fragment,{children:["Country code is ",h.matchValue]}),h.type==="geolocation-city-name"&&v.jsxs(v.Fragment,{children:["City name is ",h.matchValue]})]},`${h.type}_${m}`))]})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:sm:flex-row tw:gap-1 tw:my-auto",children:[v.jsx(Tn,{className:"tw:[&]:px-1.5",variant:"secondary","aria-label":`Edit rule with priority ${e}`,onClick:f,children:v.jsx(Ye,{icon:R9})}),v.jsx(Tn,{className:"tw:[&]:px-2",variant:"danger","aria-label":`Delete rule with priority ${e}`,onClick:r,children:v.jsx(Ye,{icon:EZ})})]})]}),v.jsx(bV,{onSave:o,isOpen:l,onClose:u,initialData:n})]})},aAe=({shortUrlRedirectRules:e,getShortUrlRedirectRules:t,getShortUrlsDetails:n,shortUrlsDetails:r,setShortUrlRedirectRules:i,shortUrlRedirectRulesSaving:a,resetSetRules:o})=>{const l=b4(),{shortUrls:f}=r,u=l&&(f==null?void 0:f.get(l)),[h,m,g]=YCe([],{dragHandle:".drag-n-drop-handler",dropZoneClass:"tw:opacity-25"}),{saving:_,saved:x,errorData:b}=a,{flag:S,setToFalse:C,setToTrue:A}=wn(!1,!0),O=M.useCallback(K=>g((W=[])=>[...W,K]),[g]),P=M.useCallback(K=>g((W=[])=>{const ee=[...W];return ee.splice(K,1),ee}),[g]),j=M.useCallback((K,W)=>g((ee=[])=>{const ie=[...ee];return ie[K]=W,ie}),[g]),R=M.useCallback((K,W)=>g((ee=[])=>{if(!ee[W])return ee;const ie=[...ee],X=ie[W];return ie[W]=ie[K],ie[K]=X,ie}),[g]),U=M.useCallback(K=>R(K,K-1),[R]),V=M.useCallback(K=>R(K,K+1),[R]),Y=M.useCallback(K=>{K.preventDefault(),m&&i({shortUrl:l,data:{redirectRules:m}})},[l,m,i]);return M.useEffect(()=>(t(l),n([l]),o),[t,n,l,o]),M.useEffect(()=>{e.redirectRules&&g(e.redirectRules)},[g,e.redirectRules]),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx("header",{children:v.jsxs(qt,{children:[v.jsxs("h2",{className:"tw:sm:flex tw:justify-between tw:items-center",children:[v.jsx(z1,{}),v.jsxs("div",{className:"tw:text-center tw:grow",children:[r.loading&&v.jsx(v.Fragment,{children:"Loading..."}),!r.loading&&v.jsxs("small",{children:["Redirect rules for ",v.jsx(Oi,{href:(u==null?void 0:u.shortUrl)??""})]})]})]}),v.jsx("hr",{}),v.jsxs("div",{children:[v.jsx("p",{children:"Configure dynamic conditions that will be checked at runtime."}),v.jsxs("p",{children:["If no conditions match, visitors will be redirected to: ",v.jsx(Oi,{href:e.defaultLongUrl??""})]})]})]})}),v.jsx("div",{children:v.jsxs(Tn,{onClick:A,children:[v.jsx(Ye,{icon:Km})," Add rule"]})}),v.jsxs("form",{onSubmit:Y,children:[e.loading&&v.jsx(tc,{loading:!0}),m.length===0&&!e.loading&&v.jsx(qt,{className:"tw:text-center",children:v.jsx("i",{children:"This short URL has no dynamic redirect rules"})}),v.jsx("div",{className:"tw:flex tw:flex-col tw:gap-2",ref:h,children:m.map((K,W)=>v.jsx(iAe,{redirectRule:K,priority:W+1,isLast:W===m.length-1,onDelete:()=>P(W),onMoveUp:()=>U(W),onMoveDown:()=>V(W),onUpdate:ee=>j(W,ee)},`${K.longUrl}_${W}`))}),v.jsx("div",{className:"tw:text-center tw:mt-4",children:v.jsx(Tn,{type:"submit",inline:!0,className:"tw:max-md:w-full",disabled:_,"data-testid":"save-button",children:_?"Saving...":"Save rules"})})]}),b&&v.jsx(Ei,{variant:"error",children:v.jsx(co,{errorData:b,fallbackMessage:"An error occurred while saving short URL redirect rules :("})}),x&&v.jsx(Ei,{variant:"success",children:"Redirect rules properly saved."}),v.jsx(bV,{isOpen:S,onClose:C,onSave:O})]})},oAe=(e,t)=>{e.serviceFactory("ShortUrlRedirectRules",()=>aAe),e.decorator("ShortUrlRedirectRules",t(["shortUrlRedirectRules","shortUrlsDetails","shortUrlRedirectRulesSaving"],["getShortUrlRedirectRules","getShortUrlsDetails","setShortUrlRedirectRules","resetSetRules"])),e.serviceFactory("getShortUrlRedirectRules",GSe,"apiClientFactory"),e.serviceFactory("setShortUrlRedirectRules",qSe,"apiClientFactory"),e.serviceFactory("resetSetRules",n=>n.resetSetRules,"setShortUrlRedirectRulesReducerCreator"),e.serviceFactory("shortUrlRedirectRulesReducerCreator",WSe,"getShortUrlRedirectRules"),e.serviceFactory("shortUrlRedirectRulesReducer",n=>n.reducer,"shortUrlRedirectRulesReducerCreator"),e.serviceFactory("setShortUrlRedirectRulesReducerCreator",VSe,"setShortUrlRedirectRules"),e.serviceFactory("setShortUrlRedirectRulesReducer",n=>n.reducer,"setShortUrlRedirectRulesReducerCreator")},sAe=({creation:e,resetCreateShortUrl:t,canBeClosed:n=!1})=>{const{error:r,saved:i}=e;if(M.useEffect(()=>{t()},[t]),r)return v.jsxs(Ei,{variant:"error",className:"tw:mt-4 tw:relative",children:[n&&v.jsx("div",{className:"tw:absolute tw:right-1.5 tw:top-1.5","data-testid":"error-close-button",children:v.jsx(Vf,{onClick:t})}),v.jsx(co,{errorData:e.errorData,fallbackMessage:"An error occurred while creating the URL :("})]});if(!i)return null;const{shortUrl:a}=e.result;return v.jsxs(Ei,{variant:"success",className:"tw:mt-4 tw:relative",children:[n&&v.jsx("div",{className:"tw:absolute tw:right-1.5 tw:top-1.5","data-testid":"success-close-button",children:v.jsx(Vf,{onClick:t})}),v.jsxs("div",{className:"tw:flex tw:items-center tw:justify-center tw:gap-1",children:[v.jsxs("span",{children:[v.jsx("b",{children:"Great!"})," The short URL is ",v.jsx("b",{children:a})]}),v.jsx(KB,{text:a})]})]})},lAe=e=>({longUrl:"",tags:[],customSlug:"",title:void 0,shortCodeLength:void 0,domain:"",validSince:void 0,validUntil:void 0,maxVisits:void 0,findIfExists:!1,validateUrl:(e==null?void 0:e.validateUrls)??!1,forwardQuery:(e==null?void 0:e.forwardQuery)??!0}),wV=({createShortUrl:e,shortUrlCreation:t,resetCreateShortUrl:n,basicMode:r=!1})=>{const{ShortUrlForm:i}=Pn(wV),a=Xn("shortUrlCreation"),o=M.useMemo(()=>lAe(a),[a]);return v.jsxs(v.Fragment,{children:[v.jsx(i,{initialState:o,saving:t.saving,basicMode:r,onSave:async l=>(n(),e(l))}),v.jsx(sAe,{creation:t,resetCreateShortUrl:n,canBeClosed:r})]})},uAe=Rn(wV,["ShortUrlForm"]),_V=({shortUrlsDetails:e,getShortUrlsDetails:t,shortUrlEdition:n,editShortUrl:r})=>{const{ShortUrlForm:i}=Pn(_V),a=b4(),{loading:o,error:l,errorData:f,shortUrls:u}=e,h=a&&(u==null?void 0:u.get(a)),{saving:m,saved:g,error:_,errorData:x}=n,b=Xn("shortUrlCreation"),S=M.useMemo(()=>kSe(h,b),[h,b]);return M.useEffect(()=>{a&&t([a])},[t,a]),o?v.jsx(tc,{loading:!0}):l?v.jsx(Ei,{variant:"error",children:v.jsx(co,{errorData:f,fallbackMessage:"An error occurred while loading short URL detail :("})}):v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-4",children:[v.jsx("header",{children:v.jsx(qt,{children:v.jsxs("h2",{className:"tw:sm:flex tw:items-center",children:[v.jsx(z1,{}),v.jsx("div",{className:"tw:text-center tw:grow",children:v.jsxs("small",{children:["Edit ",v.jsx(Oi,{href:(h==null?void 0:h.shortUrl)??""})]})})]})})}),v.jsx(i,{initialState:S,saving:m,onSave:async C=>{h&&r({...h,data:C})}}),g&&_&&v.jsx(Ei,{variant:"error",children:v.jsx(co,{errorData:x,fallbackMessage:"An error occurred while updating short URL :("})}),g&&!_&&v.jsx(Ei,{variant:"success",children:"Short URL properly edited."})]})},cAe=Rn(_V,["ShortUrlForm"]),AA="delete",fAe=({shortUrl:e,onClose:t,isOpen:n,shortUrlDeletion:r,resetDeleteShortUrl:i,deleteShortUrl:a,shortUrlDeleted:o})=>{const[l,f]=M.useState("");M.useEffect(()=>i,[i]);const{loading:u,error:h,deleted:m,errorData:g}=r,_=M.useCallback(()=>{i(),t()},[i,t]),x=M.useCallback(()=>a(e).then(b=>!c4(b)&&t()),[a,e,t]);return v.jsx(Vl,{open:n,title:"Delete short URL",variant:"danger",confirmText:u?"Deleting...":"Delete",confirmDisabled:l!==AA||u,onConfirm:x,onClose:_,onClosed:()=>m&&o(e),children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-2",children:[v.jsxs("p",{children:[v.jsx("b",{className:"tw:text-danger",children:"Caution!"})," You are about to delete a short URL."]}),v.jsx("p",{children:"This action cannot be undone. Once you have deleted it, all the visits stats will be lost."}),v.jsx(ta,{label:v.jsxs(v.Fragment,{children:["Type ",v.jsx("b",{children:AA})," to confirm deletion."]}),type:"text",placeholder:AA,value:l,onChange:b=>f(b.target.value),onKeyDown:b=>b.key==="Enter"&&x()}),h&&v.jsx(Ei,{variant:dSe(g)?"warning":"error",size:"sm",className:"tw:mt-2",children:v.jsx(co,{errorData:g,fallbackMessage:"Something went wrong while deleting the URL :("})})]})})},xV=({amount:e=0,loading:t=!1,...n})=>v.jsxs(Tn,{...n,disabled:t,children:[v.jsx(Ye,{icon:RZ})," ",t?"Exporting...":v.jsxs(v.Fragment,{children:["Export (",jn(e),")"]})]}),m7=20,SV=({amount:e=0})=>{const{apiClientFactory:t,ReportExporter:n}=Pn(SV),[{tags:r,search:i,startDate:a,endDate:o,orderBy:l,tagsMode:f}]=U1(),[u,,h,m]=wn(),g=M.useCallback(async()=>{const _=e/m7,x=async(S=1)=>{const{data:C}=await t().listShortUrls({page:`${S}`,tags:r,searchTerm:i,startDate:a,endDate:o,orderBy:l,tagsMode:f,itemsPerPage:m7});return S>=_?C:C.concat(await x(S+1))};h();const b=await x();n.exportShortUrls(b.map(S=>{var C;const{hostname:A,pathname:O}=new URL(S.shortUrl),P=O.substring(1);return{createdAt:S.dateCreated,domain:A,shortCode:P,shortUrl:S.shortUrl,longUrl:S.longUrl,title:S.title??"",tags:S.tags.join("|"),visits:((C=S==null?void 0:S.visitsSummary)==null?void 0:C.total)??S.visitsCount??0}})),m()},[e,t,o,l,n,i,a,h,m,r,f]);return v.jsx(xV,{loading:u,className:"tw:max-lg:w-full",amount:e,onClick:g})},dAe=Rn(SV,["apiClientFactory","ReportExporter"]),hAe="yyyy-MM-dd",CV="yyyy-MM-dd HH:mm",Fl=()=>new Date,_4=e=>typeof e!="string",x4=(e,t)=>!e||!_4(e)?e:t?s0(e,t):Voe(e),ql=e=>x4(e,void 0),Sl=e=>x4(e,hAe),zm=e=>x4(e,CV),Si=e=>_4(e)?e:$l(e),vg=(e,t,n)=>{const r=Si(e),i=t&&Si(t),a=n&&Si(n);if(i&&a)try{return Woe(r,{start:i,end:a})}catch{return!1}return i?yE(r,i)||Goe(r,i):a?yE(r,a)||l0(r,a):!0},Ru=(e,t)=>yE(e,t)||l0(e,t),hb=({date:e,format:t=CV,relative:n=!1})=>{const r=_4(e)?e:$l(e);return v.jsx("time",{dateTime:`${Hoe(r)}000`,children:n?`${qoe(Fl(),r)} ago`:s0(r,t)})},AV=(e,{shortCode:t,domain:n},r)=>{const i=n?`?domain=${n}`:"";return`${e}/short-code/${Jq(t)}/${r}${i}`},EV=({shortUrl:e,suffix:t,asLink:n,children:r,...i})=>{const a=vs();return!n||!e?v.jsx("span",{...i,children:r}):v.jsx(ur,{to:AV(a,e,t),...i,children:r})},pAe=e=>{const{meta:t,visitsCount:n,visitsSummary:r}=e,{maxVisits:i,validSince:a,validUntil:o}=t,l=(r==null?void 0:r.total)??n??0;return i&&l>=i?{icon:xX,className:"tw:text-danger",description:`This short URL cannot be currently visited because it has reached the maximum amount of ${i} visit${i>1?"s":""}`}:o&&l0(Si(o),Fl())?{icon:nM,className:"tw:text-danger",description:`This short URL cannot be visited since ${zm(Si(o))}`}:a&&l0(Fl(),Si(a))?{icon:nM,className:"tw:text-warning",description:`This short URL will start working on ${zm(Si(a))}`}:{icon:Zu,className:"tw:text-lm-brand tw:dark:text-dm-brand",description:"This short URL can be visited normally"}},mAe=({shortUrl:e})=>{const{icon:t,className:n,description:r}=M.useMemo(()=>pAe(e),[e]);return v.jsx("span",{className:"tw:cursor-help",title:r,children:v.jsx(Ye,{icon:t,className:n})})},OV=({visitsCount:e,shortUrl:t,active:n=!1,asLink:r=!1})=>{const{anchor:i,tooltip:a}=Hl(),{maxVisits:o,validSince:l,validUntil:f}=(t==null?void 0:t.meta)??{},u=!!o||!!l||!!f,h=v.jsx(EV,{shortUrl:t,suffix:"visits",asLink:r,children:v.jsx("strong",{className:be("tw:inline-block tw:transition-all tw:duration-300",{"tw:scale-150":n}),children:jn(e)})});return u?v.jsxs(v.Fragment,{children:[v.jsxs("span",{className:"tw:whitespace-nowrap",children:[h,v.jsxs("small",{className:"tw:cursor-help",...i,children:[o&&v.jsxs(v.Fragment,{children:[" / ",jn(o)]}),v.jsx("sup",{className:"tw:ml-1",children:v.jsx(Ye,{icon:Tb})})]})]}),v.jsx(Gl,{...a,children:v.jsxs("ul",{className:"tw:flex tw:flex-col tw:gap-y-2",children:[o&&v.jsxs("li",{children:["This short URL will not accept more than ",v.jsx("b",{children:jn(o)})," visit",o===1?"":"s","."]}),l&&v.jsxs("li",{children:["This short URL will not accept visits before ",v.jsx("b",{className:"tw:whitespace-nowrap",children:zm(Si(l))}),"."]}),f&&v.jsxs("li",{children:["This short URL will not accept visits after ",v.jsx("b",{className:"tw:whitespace-nowrap",children:zm(Si(f))}),"."]})]})})]}):h},Ad=({className:e,...t})=>v.jsx("button",{type:"button",className:be("tw:rounded-sm tw:focus-ring tw:cursor-pointer",e),...t}),gAe=e=>!!e.onClose,vAe=e=>!!e.onClick,S4=e=>{const{text:t,children:n,className:r,colorGenerator:i}=e,a=vAe(e),o=gAe(e),l=a?Ad:"span",f=M.useMemo(()=>i.stylesForKey(t),[t,i]);return v.jsxs(l,{className:be("tw:inline-flex tw:items-center tw:gap-1","tw:font-bold tw:[&]:rounded-md",{"tw:text-sm tw:px-1.5 tw:py-0.5":!o,"tw:py-1 tw:px-2":o,"tw:cursor-pointer":a},r),style:f,onClick:a?e.onClick:void 0,"data-testid":"tag",children:[n??t,o&&v.jsx(Ad,{"aria-label":`Remove ${t}`,className:"tw:p-0 tw:text-lg tw:leading-5.5",onClick:e.onClose,children:v.jsx(Ye,{icon:Pb,size:"sm"})})]})},yAe=({tags:e,onTagClick:t,colorGenerator:n})=>e.length===0?v.jsx("i",{className:"tw:whitespace-nowrap",children:v.jsx("small",{children:"No tags"})}):v.jsx("div",{className:"tw:inline-flex tw:flex-wrap tw:gap-1 tw:items-center",children:e.map(r=>v.jsx(S4,{text:r,colorGenerator:n,onClick:()=>t==null?void 0:t(r)},r))}),TV=({shortUrl:e,onTagClick:t})=>{var n,r,i,a;const{ShortUrlsRowMenu:o,ColorGenerator:l,useTimeoutToggle:f}=Pn(TV),[u,h]=f(!1,500),m=M.useRef(!0),[{excludeBots:g}]=U1(),_=Xn("visits"),x=g??(_==null?void 0:_.excludeBots);return M.useEffect(()=>{m.current||h(),m.current=!1},[(n=e.visitsSummary)==null?void 0:n.total,(r=e.visitsSummary)==null?void 0:r.nonBots,e.visitsCount,h]),v.jsxs(Je.Row,{className:"tw:relative",children:[v.jsx(Je.Cell,{className:"tw:whitespace-nowrap",columnName:"Created at:",children:v.jsx(hb,{date:e.dateCreated})}),v.jsx(Je.Cell,{columnName:"Short URL:",children:v.jsxs("span",{className:"tw:lg:whitespace-nowrap tw:inline-flex tw:items-center tw:gap-x-2",children:[v.jsx(Oi,{href:e.shortUrl,className:"tw:max-md:break-all tw:lg:truncate tw:max-w-72"}),v.jsx(KB,{text:e.shortUrl})]})}),v.jsx(Je.Cell,{className:"tw:break-all",columnName:`${e.title?"Title":"Long URL"}:`,children:v.jsx(Oi,{href:e.longUrl,children:e.title??e.longUrl})}),e.title&&v.jsx(Je.Cell,{className:"tw:break-all tw:[&]:lg:hidden",columnName:"Long URL:",children:v.jsx(Oi,{href:e.longUrl})}),v.jsx(Je.Cell,{columnName:"Tags:",children:v.jsx(yAe,{tags:e.tags,colorGenerator:l,onTagClick:t})}),v.jsx(Je.Cell,{className:"tw:lg:text-right",columnName:"Visits:",children:v.jsx(OV,{visitsCount:(x?(i=e.visitsSummary)==null?void 0:i.nonBots:(a=e.visitsSummary)==null?void 0:a.total)??e.visitsCount??0,shortUrl:e,active:u,asLink:!0})}),v.jsx(Je.Cell,{columnName:"Status:",className:"tw:max-lg:border-none",children:v.jsxs("div",{className:"tw:inline-flex tw:gap-2",children:[v.jsx(mAe,{shortUrl:e}),e.hasRedirectRules&&v.jsx(EV,{asLink:!0,shortUrl:e,suffix:"redirect-rules",title:"This short URL has dynamic redirect rules",children:v.jsx(Ye,{icon:U9})})]})}),v.jsx(Je.Cell,{className:"tw:text-right tw:max-lg:absolute tw:max-lg:top-1 tw:max-lg:right-1 tw:max-lg:p-0",children:v.jsx(o,{shortUrl:e})})]})},bAe=Rn(TV,["ShortUrlsRowMenu","ColorGenerator","useTimeoutToggle"]),jV=M.forwardRef(({name:e,color:t,onChange:n,className:r},i)=>v.jsxs("div",{className:be("tw:relative tw:rounded tw:w-12",r),style:{backgroundColor:t,borderColor:t},children:[v.jsx(ti,{className:"tw:w-full tw:h-full tw:cursor-pointer tw:relative tw:z-1 tw:opacity-0",type:"color",value:t,onChange:a=>n(a.target.value),ref:i,name:e,"aria-label":e.replace("-"," ")}),v.jsx(Ye,{icon:HZ,className:"tw:absolute tw:top-1/2 tw:left-1/2 tw:-translate-1/2",style:{color:C$(t.substring(1))?"#000":"#fff"}})]})),g7=({color:e,onChange:t,name:n})=>{const r=M.useRef(null);return v.jsxs("div",{className:"tw:flex",children:[v.jsx(jV,{name:`${n}-picker`,color:e,onChange:t,className:"tw:rounded-r-none",ref:r}),v.jsx(ti,{readOnly:!0,value:e,onClick:()=>{var i;return(i=r.current)==null?void 0:i.click()},"aria-label":n,"data-testid":"text-input",className:"tw:grow tw:rounded-l-none"})]})};function wAe(e){switch(e){case"L":return 1;case"M":return .5;default:return .3}}const _Ae=M.forwardRef(({data:e,color:t="#000000",bgColor:n="#ffffff",margin:r=0,errorCorrection:i="L",size:a=300,drawType:o="canvas",logo:l},f)=>{const u=M.useRef(null),h=M.useRef(new dse),m=M.useCallback((_,x)=>h.current.download({name:_,extension:x}),[]),g=M.useCallback(_=>new Promise((x,b)=>{const S=h.current.getRawData(_),C=new FileReader;C.onload=()=>{const{result:A}=C;A&&x(A.toString())},C.onerror=b,S.then(A=>{A instanceof Blob?C.readAsDataURL(A):b(new Error("QR code image blob not available"))})}),[]);return M.useImperativeHandle(f,()=>({download:m,getDataUri:g}),[m,g]),M.useEffect(()=>{const _=u.current;h.current.append(_)},[]),M.useEffect(()=>{h.current.update({type:o,data:e,width:a+r,height:a+r,margin:r,dotsOptions:{color:t},backgroundOptions:{color:n},qrOptions:{errorCorrectionLevel:i},imageOptions:{margin:5,imageSize:wAe(i)},image:l})},[n,t,e,o,i,l,r,a]),v.jsxs(v.Fragment,{children:[v.jsx("style",{dangerouslySetInnerHTML:{__html:"#qr-code-canvas-container canvas { max-width: 100% }"}}),v.jsx("div",{ref:u,id:"qr-code-canvas-container"})]})}),xAe=async({text:e,onCopy:t},n=navigator)=>{var r;const i=typeof e=="string"?e:await e;return(r=n.clipboard)==null?void 0:r.writeText(i).then(()=>t==null?void 0:t({text:i,copied:!0})).catch(()=>t==null?void 0:t({text:i,copied:!1}))},v7=({name:e,value:t,step:n,min:r,max:i,onChange:a})=>{const o=M.useId();return v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1",children:[v.jsxs("label",{htmlFor:o,className:"tw:capitalize",children:[e,": ",t,"px"]}),v.jsx("input",{id:o,type:"range",value:t,step:n,min:r,max:i,onChange:l=>a(Number(l.target.value))})]})},SAe=({shortUrl:{shortUrl:e,shortCode:t},onClose:n,isOpen:r,qrDrawType:i})=>{const a=Xn("qrCodes",kd),[{size:o,margin:l,color:f,bgColor:u,errorCorrection:h,format:m},g]=M.useState(a),_=M.useCallback(V=>g(Y=>({...Y,...V})),[]),x=M.useRef(null),[b,S]=M.useState(),C=M.useCallback(V=>{var Y;const K=(Y=V.target.files)==null?void 0:Y[0];K&&S({url:URL.createObjectURL(new Blob([K],{type:K.type})),name:K.name})},[]),A=M.useRef(null),O=M.useCallback(()=>{var V;return(V=A.current)==null?void 0:V.download(`${t}-qr-code`,m)},[m,t]),[P,j]=jT(),R=M.useCallback(()=>{var V;const Y=((V=A.current)==null?void 0:V.getDataUri(m))??"";return xAe({text:Y,onCopy:j})},[m,j]),U=M.useCallback(()=>{g(a),S(void 0)},[a]);return v.jsx(Vl,{size:"lg",open:r,onClose:n,title:v.jsxs(v.Fragment,{children:["QR code for ",v.jsx(Oi,{href:e})]}),onClosed:U,children:v.jsxs("div",{className:"tw:flex tw:flex-col-reverse tw:lg:flex-row tw:gap-4",children:[v.jsx("div",{className:"tw:grow tw:flex tw:items-center tw:justify-around",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-1 tw:items-center","data-testid":"qr-code-container",children:[v.jsx(_Ae,{ref:A,data:e,size:o,margin:l,errorCorrection:h,color:f,bgColor:u,logo:b==null?void 0:b.url,drawType:i}),v.jsxs("div",{className:"tw:italic",children:["Preview (",o+l,"x",o+l,")"]})]})}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-2 tw:lg:w-64",children:[v.jsx(v7,{name:"size",value:o,onChange:V=>_({size:V}),step:10,min:50,max:1e3}),v.jsx(v7,{name:"margin",value:l,onChange:V=>_({margin:V}),step:1,min:0,max:100}),v.jsx(ZB,{errorCorrection:h,onChange:V=>_({errorCorrection:V})}),v.jsx(g7,{name:"color",color:f,onChange:V=>_({color:V})}),v.jsx(g7,{name:"background",color:u,onChange:V=>_({bgColor:V})}),!b&&v.jsxs(v.Fragment,{children:[v.jsxs(Tn,{variant:"secondary",onClick:()=>{var V;return(V=x.current)==null?void 0:V.click()},children:[v.jsx(Ye,{icon:gte}),"Select logo"]}),v.jsx("input",{ref:x,type:"file",accept:"image/*","aria-hidden":!0,tabIndex:-1,className:"tw:hidden",onChange:C,"data-testid":"logo-input"})]}),b&&v.jsxs(Tn,{variant:"secondary",onClick:()=>S(void 0),children:[v.jsx(Ye,{icon:jb}),v.jsxs("div",{className:"tw:truncate",children:["Clear logo (",b.name,")"]})]}),v.jsx("div",{className:"tw:my-auto",children:v.jsx("hr",{className:"tw:my-2"})}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-2",children:[v.jsx(XB,{format:m,onChange:V=>_({format:V})}),v.jsxs("div",{className:"tw:flex tw:items-center tw:gap-2",children:[v.jsx(Tn,{onClick:R,"aria-label":"Copy data URI",title:"Copy data URI",className:"tw:h-full",children:v.jsx(Ye,{icon:P?Zu:G$,fixedWidth:!0})}),v.jsxs(Tn,{solid:!0,onClick:O,className:"tw:grow",children:["Download ",v.jsx(Ye,{icon:D9})]})]})]})]})]})})},PV=({shortUrl:e,deleteShortUrl:t,shortUrlDeleted:n})=>{const{DeleteShortUrlModal:r}=Pn(PV),{flag:i,setToTrue:a,setToFalse:o}=wn(!1,!0),{flag:l,setToTrue:f,setToFalse:u}=wn(!1,!0),h=k1(),m=fo("shortUrlRedirectRules"),{confirmDeletions:g=!0}=Xn("shortUrlsList",{}),_=M.useCallback(async()=>{const S=await t(e);c4(S)||n(e)},[t,e,n]),x=vs(),b=M.useCallback(S=>AV(x,e,S),[x,e]);return v.jsxs(v.Fragment,{children:[v.jsxs(zn,{menuAlignment:"right",children:[v.jsxs(zn.Item,{to:b("visits"),className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:gT,fixedWidth:!0})," Visit stats"]}),h&&v.jsxs(v.Fragment,{children:[v.jsxs(zn.Item,{className:"tw:gap-1.5",disabled:!h.canAddItemWithName(e.shortUrl),onClick:()=>h.addItemToCompare({name:e.shortUrl,query:g4(e)}),children:[v.jsx(Ye,{icon:Ob,fixedWidth:!0})," Compare visits"]}),v.jsx(zn.Separator,{})]}),v.jsxs(zn.Item,{to:b("edit"),className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:mT,fixedWidth:!0})," Edit short URL"]}),m&&v.jsxs(zn.Item,{to:b("redirect-rules"),className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:U9,fixedWidth:!0})," Manage redirect rules"]}),v.jsxs(zn.Item,{onClick:a,className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:bX,fixedWidth:!0})," QR code"]}),v.jsx(zn.Separator,{}),v.jsxs(zn.Item,{className:"tw:[&]:text-danger tw:gap-1.5",onClick:g?f:_,children:[v.jsx(Ye,{icon:P9,fixedWidth:!0})," Delete short URL"]})]}),v.jsx(SAe,{shortUrl:e,isOpen:i,onClose:o}),v.jsx(r,{shortUrl:e,deleteShortUrl:t,shortUrlDeleted:n,isOpen:l,onClose:u})]})},CAe=Rn(PV,["DeleteShortUrlModal"]),RV="shlink/shortUrlCreation",y7={saving:!1,saved:!1,error:!1},AAe=e=>Zn(`${RV}/createShortUrl`,t=>e().createShortUrl(t)),EAe=e=>{const{reducer:t,actions:n}=Dn({name:RV,initialState:y7,reducers:{resetCreateShortUrl:()=>y7},extraReducers:i=>{i.addCase(e.pending,()=>({saving:!0,saved:!1,error:!1})),i.addCase(e.rejected,(a,{error:o})=>({saving:!1,saved:!1,error:!0,errorData:Di(o)})),i.addCase(e.fulfilled,(a,{payload:o})=>({result:o,saving:!1,saved:!0,error:!1}))}}),{resetCreateShortUrl:r}=n;return{reducer:t,resetCreateShortUrl:r}},MV="shlink/shortUrlEdition",OAe={saving:!1,saved:!1,error:!1},TAe=e=>Zn(`${MV}/editShortUrl`,({shortCode:t,domain:n,data:r})=>e().updateShortUrl({shortCode:t,domain:n},r)),jAe=e=>Dn({name:MV,initialState:OAe,reducers:{},extraReducers:t=>{t.addCase(e.pending,n=>({...n,saving:!0,error:!1,saved:!1})),t.addCase(e.rejected,(n,{error:r})=>({...n,saving:!1,error:!0,saved:!1,errorData:Di(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>({shortUrl:r,saving:!1,error:!1,saved:!0}))}}),b7="shlink/shortUrlsDetails",w7={loading:!1,error:!1},PAe=e=>{const t=Zn(`${b7}/getShortUrlsDetails`,async(r,{getState:i})=>{const{shortUrlsList:a}=i(),o=await Promise.all(r.map(async l=>{var f;const{shortCode:u,domain:h}=l,m=(f=a==null?void 0:a.shortUrls)==null?void 0:f.data.find(g=>qp(g,u,h));return[l,m??await e().getShortUrl({shortCode:u,domain:h})]}));return new Map(o)}),{reducer:n}=Dn({name:b7,initialState:w7,reducers:{},extraReducers:r=>{r.addCase(t.pending,()=>({loading:!0,error:!1})),r.addCase(t.rejected,(i,{error:a})=>({loading:!1,error:!0,errorData:Di(a)})),r.addCase(t.fulfilled,(i,{payload:a})=>({...w7,shortUrls:a}))}});return{reducer:n,getShortUrlsDetails:t}},RAe=({domains:e,value:t,onChange:n})=>{const{flag:r,setToTrue:i,setToFalse:a}=wn(!1,!0),o=!t,l=M.useCallback(()=>{n(""),a()},[n,a]),f=M.useCallback(()=>{n(""),i()},[n,i]);return r?v.jsxs("div",{className:"tw:flex",children:[v.jsx(ti,{value:t??"",placeholder:"Domain",onChange:u=>n(u.target.value),className:"tw:flex-grow tw:rounded-r-none tw:[&]:border-r-0"}),v.jsx(Tn,{variant:"secondary",type:"button",className:"tw:rounded-l-none","aria-label":"Back to domains list",title:"Existing domains",onClick:l,children:v.jsx(Ye,{icon:tX})})]}):v.jsxs(tt,{buttonContent:o?"Domain":`Domain: ${t}`,buttonClassName:be("tw:w-full",{"tw:text-placeholder":o}),children:[e.map(({domain:u,isDefault:h})=>v.jsxs(tt.Item,{selected:(t===u||h)&&o,onClick:()=>n(u),className:"tw:flex tw:justify-between tw:items-center",children:[u,h&&v.jsx(Hf,{children:"default"})]},u)),v.jsx(tt.Separator,{}),v.jsx(tt.Item,{onClick:f,children:v.jsx("i",{children:"New domain"})})]})},EA=({icon:e,className:t,...n})=>{const r=M.useRef(null);return v.jsxs("div",{className:"tw:relative",children:[v.jsx(ti,{className:be("tw:pr-11",t),ref:r,...n}),v.jsx(Ye,{icon:e,fixedWidth:!0,className:"tw:absolute tw:right-3 tw:top-1/2 tw:-translate-y-1/2 tw:cursor-pointer",onClick:()=>{var i;return(i=r.current)==null?void 0:i.focus()}})]})},MAe=({minDate:e,maxDate:t,value:n,onChange:r,withTime:i=!1,...a})=>{const o=M.useCallback(({target:f})=>{if(!f.value){r==null||r(null);return}r==null||r(Si(f.value))},[r]),l=M.useMemo(()=>i?zm:Sl,[i]);return v.jsx(ti,{...a,type:i?"datetime-local":"date",value:l(n)??"",max:l(t)??void 0,min:l(e)??void 0,onChange:o})},pb=({label:e,id:t,...n})=>{const r=M.useId();return v.jsxs(v.Fragment,{children:[v.jsxs("label",{htmlFor:t??r,className:"tw:mb-1",children:[e,":"]}),v.jsx(MAe,{id:t??r,...n})]})},NAe=({className:e,placement:t,children:n})=>{const{anchor:r,tooltip:i}=Hl({placement:t});return v.jsxs(v.Fragment,{children:[v.jsx("span",{className:e,...r,"data-placement":t,"data-testid":"tooltip-anchor",children:v.jsx(Ye,{icon:Tb})}),v.jsx(Gl,{...i,children:n})]})},OA=({children:e,infoTooltip:t,checked:n,onChange:r})=>v.jsxs("div",{className:"tw:flex tw:items-center tw:gap-x-2",children:[v.jsxs(mo,{className:"tw:inline-flex tw:items-center tw:gap-x-1.5",children:[v.jsx(VB,{checked:n,onChange:r}),e]}),v.jsx(NAe,{placement:"right",children:t})]}),LAe=e=>v.jsx(Vl,{...e,title:"Info",size:"lg",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-2",children:[v.jsxs("p",{children:["When the ",v.jsx("b",{children:v.jsx("i",{children:'"Use existing URL if found"'})})," checkbox is checked, the server will return an existing short URL if it matches provided params."]}),v.jsx("p",{children:"These are the checks performed by Shlink in order to determine if an existing short URL should be returned:"}),v.jsxs("ul",{className:"tw:list-disc tw:pl-5",children:[v.jsx("li",{children:"When only the long URL is provided: The most recent match will be returned, or a new short URL will be created if none is found."}),v.jsxs("li",{children:["When long URL and custom slug and/or domain are provided: Same as in previous case, but it will try to match the short URL using both the long URL and the slug, the long URL and the domain, or the three of them.",v.jsx("br",{}),"If the slug is being used by another long URL, an error will be returned."]}),v.jsx("li",{children:"When other params are provided: Same as in previous cases, but it will try to match existing short URLs with all provided data. If any of them does not match, a new short URL will be created"})]})]})}),kAe=()=>{const{flag:e,setToFalse:t,setToTrue:n}=wn(!1,!0);return v.jsxs(v.Fragment,{children:[v.jsx(Ad,{title:"What does this mean?",onClick:n,children:v.jsx(Ye,{icon:Tb})}),v.jsx(LAe,{open:e,onClose:t})]})},yy=e=>typeof e=="string"?$l(e):e,DAe=e=>"shortCodeLength"in e&&"customSlug"in e&&"domain"in e,NV=({basicMode:e=!1,saving:t,onSave:n,initialState:r,tagsList:i,domainsList:a})=>{var o,l,f;const{TagsSelector:u}=Pn(NV),[h,m]=M.useState(r),g=DAe(h),_=fo("deviceLongUrls"),x=fo("urlValidation"),b=x||g,S=M.useCallback(()=>m(r),[r]),C=M.useCallback((R,U)=>$u(R)?R:$u(U)?null:void 0,[]),A=M.useCallback((R,U)=>m(({deviceLongUrls:V={},...Y})=>{var K;return{...Y,deviceLongUrls:{...V,[R]:C(U,(K=r.deviceLongUrls)==null?void 0:K[R])}}}),[r.deviceLongUrls,C]),O=M.useCallback(R=>m(U=>({...U,tags:R})),[]),P=M.useCallback(async R=>(R.preventDefault(),n(h).then(U=>g&&!c4(U)&&S()).catch(()=>{})),[g,n,S,h]),j=M.useMemo(()=>v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(ti,{size:"lg",type:"url",placeholder:"URL to be shortened",required:!0,value:h.longUrl,onChange:R=>m(U=>({...U,longUrl:R.target.value}))}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row tw:gap-4",children:[e&&g&&v.jsx("div",{className:"tw:w-full tw:lg:w-1/2",children:v.jsx(ti,{size:"lg",placeholder:"Custom slug",value:h.customSlug??"",onChange:R=>m(U=>({...U,customSlug:R.target.value}))})}),v.jsx("div",{className:be("tw:w-full",{"tw:lg:w-1/2":e}),children:v.jsx(u,{tags:i.tags,selectedTags:h.tags??[],onChange:O})})]})]}),[u,e,O,g,h,i.tags]);return v.jsxs("form",{name:"shortUrlForm",onSubmit:P,className:"tw:flex tw:flex-col tw:gap-4",children:[e&&j,!e&&v.jsxs(v.Fragment,{children:[v.jsxs("div",{children:[v.jsx("div",{className:be({"tw:sm:w-1/2":_,"tw:w-full":!_}),children:v.jsx(qt,{title:"Main options",className:"card",children:j})}),_&&v.jsx("div",{className:"tw:w-full tw:sm:w-1/2",children:v.jsxs(qt,{title:"Device-specific long URLs",bodyClassName:"tw:flex tw:flex-col tw:gap-y-4",className:"card",children:[v.jsx(EA,{type:"url",icon:pse,placeholder:"Android-specific redirection",value:((o=h.deviceLongUrls)==null?void 0:o.android)??"",onChange:({target:R})=>A("android",R.value)}),v.jsx(EA,{type:"url",icon:hse,placeholder:"iOS-specific redirection",value:((l=h.deviceLongUrls)==null?void 0:l.ios)??"",onChange:({target:R})=>A("ios",R.value)}),v.jsx(EA,{type:"url",icon:SX,placeholder:"Desktop-specific redirection",value:((f=h.deviceLongUrls)==null?void 0:f.desktop)??"",onChange:({target:R})=>A("desktop",R.value)})]})})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:sm:flex-row tw:gap-4",children:[v.jsx("div",{className:"tw:w-full tw:sm:w-1/2",children:v.jsxs(qt,{title:"Customize the short URL",bodyClassName:"tw:flex tw:flex-col tw:gap-4",className:"card tw:h-full",children:[v.jsx(ti,{placeholder:"Title",value:h.title??"",onChange:({target:R})=>m(U=>({...U,title:C(R.value,r.title)}))}),g&&v.jsxs(v.Fragment,{children:[v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row tw:gap-4",children:[v.jsx("div",{className:"tw:lg:w-1/2",children:v.jsx(ti,{placeholder:"Custom slug",value:h.customSlug??"",onChange:R=>m(U=>({...U,customSlug:R.target.value})),disabled:$u(h.shortCodeLength)})}),v.jsx("div",{className:"tw:lg:w-1/2",children:v.jsx(ti,{type:"number",placeholder:"Short code length",value:h.shortCodeLength??"",onChange:R=>m(U=>({...U,shortCodeLength:R.target.value})),min:4,disabled:$u(h.customSlug)})})]}),v.jsx(RAe,{value:h.domain,onChange:R=>m(U=>({...U,domain:R})),domains:a.domains})]})]})}),v.jsx("div",{className:"tw:w-full tw:sm:w-1/2",children:v.jsxs(qt,{title:"Limit access to the short URL",className:"card tw:h-full",bodyClassName:"tw:flex tw:flex-col tw:gap-y-4",children:[v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row tw:gap-4",children:[v.jsx("div",{className:"tw:lg:w-1/2",children:v.jsx(pb,{label:"Enabled since",withTime:!0,maxDate:h.validUntil?yy(h.validUntil):void 0,value:h.validSince?yy(h.validSince):null,onChange:R=>m(U=>({...U,validSince:ql(R)}))})}),v.jsx("div",{className:"tw:lg:w-1/2",children:v.jsx(pb,{label:"Enabled until",withTime:!0,minDate:h.validSince?yy(h.validSince):void 0,value:h.validUntil?yy(h.validUntil):null,onChange:R=>m(U=>({...U,validUntil:ql(R)}))})})]}),v.jsx(ta,{label:"Maximum visits allowed:",type:"number",min:1,placeholder:"25...",value:h.maxVisits??"",onChange:R=>m(U=>({...U,maxVisits:$u(R.target.value)?Number(R.target.value):null}))})]})})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:sm:flex-row tw:gap-4",children:[b&&v.jsx("div",{className:"tw:w-full tw:sm:w-1/2",children:v.jsxs(qt,{title:"Extra checks",className:"tw:h-full",children:[x&&v.jsx(OA,{infoTooltip:"If checked, Shlink will try to reach the long URL, failing in case it's not publicly accessible.",checked:h.validateUrl,onChange:R=>m(U=>({...U,validateUrl:R})),children:"Validate URL"}),g&&v.jsxs("p",{className:"tw:inline-flex tw:items-center tw:gap-x-2",children:[v.jsxs(mo,{className:"tw:inline-flex tw:items-center tw:gap-x-1.5",children:[v.jsx(VB,{checked:h.findIfExists,onChange:R=>m(U=>({...U,findIfExists:R}))}),"Use existing URL if found"]}),v.jsx(kAe,{})]})]})}),v.jsx("div",{className:be("tw:w-full",{"tw:sm:w-1/2":b}),children:v.jsxs(qt,{title:"Configure behavior",children:[v.jsx(OA,{infoTooltip:"This short URL will be included in the robots.txt for your Shlink instance, allowing web crawlers (like Google) to index it.",checked:h.crawlable,onChange:R=>m(U=>({...U,crawlable:R})),children:"Make it crawlable"}),v.jsx(OA,{infoTooltip:"When this short URL is visited, any query params appended to it will be forwarded to the long URL.",checked:h.forwardQuery,onChange:R=>m(U=>({...U,forwardQuery:R})),children:"Forward query params on redirect"})]})})]})]}),v.jsx("div",{className:"tw:text-center",children:v.jsx(Tn,{type:"submit",inline:!0,disabled:t||!h.longUrl,className:"tw:max-md:w-full",children:t?"Saving...":"Save"})})]})},IAe=Rn(NV,["TagsSelector"]),$Ae=({startDate:e,endDate:t,disabled:n=!1,onStartDateChange:r,onEndDateChange:i})=>v.jsxs("div",{className:"tw:grid tw:grid-cols-1 tw:md:grid-cols-2 tw:gap-y-3 tw:gap-x-4",children:[v.jsx("div",{className:"tw:flex tw:flex-col",children:v.jsx(pb,{label:"Since",value:e,maxDate:t??void 0,disabled:n,onChange:r})}),v.jsx("div",{className:"tw:flex tw:flex-col",children:v.jsx(pb,{label:"Until",value:t,minDate:e??void 0,disabled:n,onChange:a=>i(a&&Wf(a))})})]}),F1="all",LV={today:"Today",yesterday:"Yesterday",last7Days:"Last 7 days",last30Days:"Last 30 days",last90Days:"Last 90 days",last180Days:"Last 180 days",last365Days:"Last 365 days",[F1]:void 0},kV=Object.keys(LV),BAe=e=>!e||!e.startDate&&!e.endDate,mb=e=>typeof e=="string"&&kV.includes(e),UAe=kV.filter(e=>e!==F1),_7=e=>e?Si(e):null,DV=(e,t)=>({startDate:_7(e),endDate:_7(t)}),zAe=e=>{if(!(!e||BAe(e)))return e.startDate&&!e.endDate?`Since ${Sl(e.startDate)}`:!e.startDate&&e.endDate?`Until ${Sl(e.endDate)}`:`${Sl(e.startDate)} - ${Sl(e.endDate)}`},x7=e=>{if(!(!e||e===F1))return mb(e)?LV[e]:zAe(e)},Qi=e=>rc(u0(Fl(),e)),yf=e=>({startDate:e,endDate:Wf(Fl())}),IV=e=>{var t;return((t=[[()=>e==="today",()=>yf(rc(Fl()))],[()=>e==="yesterday",()=>({startDate:Qi(1),endDate:Wf(u0(Fl(),1))})],[()=>e==="last7Days",()=>yf(Qi(7))],[()=>e==="last30Days",()=>yf(Qi(30))],[()=>e==="last90Days",()=>yf(Qi(90))],[()=>e==="last180Days",()=>yf(Qi(180))],[()=>e==="last365Days",()=>yf(Qi(365))]].find(([n])=>n()))==null?void 0:t[1]())??{}},FAe=e=>{var t;const n=Si(e);return((t=[[()=>Ru(rc(Fl()),n),"today"],[()=>Ru(Qi(1),n),"yesterday"],[()=>Ru(Qi(7),n),"last7Days"],[()=>Ru(Qi(30),n),"last30Days"],[()=>Ru(Qi(90),n),"last90Days"],[()=>Ru(Qi(180),n),"last180Days"],[()=>Ru(Qi(365),n),"last365Days"]].find(([r])=>r()))==null?void 0:t[1])??F1},$V=e=>mb(e)?IV(e):e,BV=e=>!!(e&&e.startDate),qAe=({startDate:e,endDate:t})=>{const n=oU(Wf(t??new Date),rc(e))+1,r=u0(rc(e),n),i=u0(Wf(e),1);return{startDate:r,endDate:i}},VAe=e=>{if(BV(e))return oU(e.endDate??new Date,e.startDate)},C4=({onDatesChange:e,dateRangeOrInterval:t,defaultText:n,disabled:r})=>{const i=M.useMemo(()=>x7(t)??n,[t,n]),[a,o]=M.useMemo(()=>mb(t)?[void 0,t]:[t,void 0],[t]),l=M.useCallback(f=>{mb(f)?e(IV(f),f):e(f)},[e]);return v.jsxs(tt,{buttonDisabled:r,buttonContent:i,containerClassName:"tw:[&]:block",buttonClassName:"tw:w-full",children:[v.jsx(tt.Item,{selected:o==="all",onClick:()=>l("all"),children:n}),v.jsx(tt.Separator,{}),UAe.map(f=>v.jsx(tt.Item,{selected:o===f,onClick:()=>l(f),children:x7(f)},f)),v.jsx(tt.Separator,{}),v.jsx(tt.Misc,{children:v.jsx($Ae,{...a,onStartDateChange:f=>l({...a,startDate:f}),onEndDateChange:f=>l({...a,endDate:f})})})]})},HAe={dateCreated:"Created at",shortCode:"Short URL",longUrl:"Long URL",title:"Title",visits:"Visits"},GAe=({onChange:e,selected:t={},domains:n})=>{const r=fo("filterShortUrlsByDomain"),{excludeBots:i=!1,excludeMaxVisitsReached:a=!1,excludePastValidUntil:o=!1,domain:l}=t,f=M.useCallback(h=>e({...t,...h}),[e,t]),u=M.useCallback(h=>f({[h]:!(t!=null&&t[h])}),[f,t]);return v.jsxs(tt,{buttonContent:"Filters",buttonClassName:"tw:w-full",menuAlignment:"right",children:[v.jsx(tt.Title,{children:"Visits:"}),v.jsx(tt.Item,{selected:i,onClick:()=>u("excludeBots"),children:"Ignore visits from bots"}),v.jsx(tt.Separator,{}),v.jsx(tt.Title,{children:"Short URLs:"}),v.jsx(tt.Item,{selected:a,onClick:()=>u("excludeMaxVisitsReached"),children:"Exclude with visits reached"}),v.jsx(tt.Item,{selected:o,onClick:()=>u("excludePastValidUntil"),children:"Exclude enabled in the past"}),r&&v.jsxs(v.Fragment,{children:[v.jsx(tt.Separator,{}),v.jsxs(tt.Title,{children:["Domain: ",!n&&v.jsx("i",{children:"loading..."})]}),n==null?void 0:n.map(h=>{const m=h.isDefault?Sd:h.domain,g=l===m;return v.jsx(tt.Item,{selected:g,onClick:()=>f({domain:g?void 0:m}),children:h.domain},h.domain)})]}),v.jsx(tt.Separator,{}),v.jsx(tt.Item,{disabled:t.excludeBots===void 0&&t.excludeMaxVisitsReached===void 0&&t.excludePastValidUntil===void 0&&t.domain===void 0,onClick:()=>e({excludeBots:void 0,excludeMaxVisitsReached:void 0,excludePastValidUntil:void 0,domain:void 0}),className:"tw:italic",children:"Reset to defaults"})]})},UV=({className:e,shortUrlsAmount:t,order:n,handleOrderBy:r,tagsList:i,domainsList:a})=>{const{ExportShortUrlsBtn:o,TagsSelector:l}=Pn(UV),[{search:f,tags:u,startDate:h,endDate:m,excludeBots:g,excludeMaxVisitsReached:_,excludePastValidUntil:x,domain:b,tagsMode:S="any"},C]=U1(),A=Xn("visits"),[O,P]=M.useState(),j=M.useCallback(({startDate:W,endDate:ee},ie)=>{C({startDate:ql(W)??void 0,endDate:ql(ee)??void 0}),P(ie)},[C]),R=M.useCallback(W=>C({search:W||void 0}),[C]),U=M.useCallback(W=>C({tags:W}),[C]),V=M.useCallback(()=>C({tagsMode:S==="any"?"all":"any"}),[S,C]),{anchor:Y,tooltip:K}=Hl({placement:"left"});return v.jsxs("div",{className:be("tw:flex tw:flex-col tw:gap-y-4",e),children:[v.jsx(ag,{defaultValue:f,onChange:R}),v.jsxs("div",{className:"tw:flex tw:w-full",children:[v.jsx("div",{className:"tw:flex-grow",children:v.jsx(l,{immutable:!0,placeholder:"With tags...",tags:i.tags,selectedTags:u,onChange:U,containerClassName:be(u.length>1&&"tw:[&]:rounded-r-none")})}),u.length>1&&v.jsxs(v.Fragment,{children:[v.jsx(Tn,{variant:"secondary",onClick:V,"aria-label":"Change tags mode",className:"tw:[&]:border-l-none tw:[&]:rounded-l-none",...Y,children:v.jsx(Ye,{className:"tw:text-2xl",icon:S==="all"?N9:QZ})}),v.jsx(Gl,{...K,children:S==="all"?v.jsxs(v.Fragment,{children:["With ",v.jsx("b",{children:"all"})," the tags"]}):v.jsxs(v.Fragment,{children:["With ",v.jsx("b",{children:"any"})," of the tags"]})})]})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row-reverse tw:gap-y-4",children:[v.jsxs("div",{className:"tw:lg:w-2/3 tw:xl:w-1/2 tw:inline-flex tw:flex-col tw:md:flex-row tw:gap-4",children:[v.jsx("div",{className:"tw:grow",children:v.jsx(C4,{defaultText:"All short URLs",dateRangeOrInterval:O??DV(h,m),onDatesChange:j})}),v.jsx(GAe,{selected:{excludeBots:g??(A==null?void 0:A.excludeBots),excludeMaxVisitsReached:_,excludePastValidUntil:x,domain:b},onChange:C,domains:a.loading?void 0:a.domains})]}),v.jsxs("div",{className:"tw:lg:w-1/3 tw:xl:w-1/2 tw:inline-flex tw:gap-3",children:[v.jsx("div",{className:"tw:max-lg:w-1/2 tw:lg:hidden",children:v.jsx(og,{containerClassName:"tw:[&]:block",buttonClassName:"tw:w-full",prefixed:!1,items:HAe,order:n,onChange:({field:W,dir:ee})=>r(W,ee)})}),v.jsx("div",{className:"tw:max-lg:w-1/2",children:v.jsx(o,{amount:t})})]})]})]})},WAe=Rn(UV,["ExportShortUrlsBtn","TagsSelector"]);function Vp({currentOrder:e,field:t,className:n="tw:ml-1"}){return!e.dir||e.field!==t?null:v.jsx(Ye,{icon:e.dir==="ASC"?VZ:vT,className:n})}const YAe=({paginator:e,currentQueryString:t=""})=>{const{currentPage:n=0,pagesCount:r=0}=e??{},i=vs(),a=M.useCallback(o=>`${i}/list-short-urls/${o}${t}`,[t,i]);return r<=1?v.jsx("div",{"data-testid":"empty-gap",className:"tw:pb-4"}):v.jsx("div",{"data-testid":"short-urls-paginator",className:be("tw:sticky tw:bottom-0 tw:py-4 tw:-mx-0.5","tw:flex tw:justify-around","tw:bg-lm-primary tw:dark:bg-dm-primary","tw:border-t tw:border-lm-border tw:dark:border-dm-border"),children:v.jsx(Xb,{urlForPage:a,currentPage:n,pagesCount:r})})},KAe={field:"dateCreated",dir:"DESC"},zV=Ma(({listShortUrls:e,shortUrlsList:t})=>{var n,r,i;const{ShortUrlsTable:a,ShortUrlsFilteringBar:o}=Pn(zV),{page:l}=Td(),f=Sr(),[{tags:u,search:h,startDate:m,endDate:g,orderBy:_,tagsMode:x,excludeBots:b,excludePastValidUntil:S,excludeMaxVisitsReached:C,domain:A},O]=U1(),P=ZT(),[j,R]=M.useState(_??((n=P.shortUrlsList)==null?void 0:n.defaultOrdering)??KAe),{pagination:U}=(t==null?void 0:t.shortUrls)??{},V=M.useMemo(()=>{var ne;return b??((ne=P.visits)==null?void 0:ne.excludeBots)},[b,(r=P.visits)==null?void 0:r.excludeBots]),Y=M.useCallback((ne,H)=>{O({orderBy:{field:ne,dir:H}}),R({field:ne,dir:H})},[O]),K=ne=>()=>Y(ne,Db(ne,j.field,j.dir)),W=ne=>v.jsx(Vp,{currentOrder:j,field:ne}),ee=M.useCallback(ne=>O({tags:[...new Set([...u,ne])]}),[u,O]),ie=M.useCallback(({field:ne,dir:H})=>V&&ne==="visits"?{field:"nonBotVisits",dir:H}:{field:ne,dir:H},[V]),X=d4();return M.useEffect(()=>{e({page:l,searchTerm:h,tags:u,startDate:m,endDate:g,orderBy:ie(j),tagsMode:x,excludePastValidUntil:S,excludeMaxVisitsReached:C,domain:A})},[e,ie,l,h,u,m,g,j,x,S,C,A]),v.jsxs(f4,{value:X,children:[v.jsx(o,{shortUrlsAmount:(i=t.shortUrls)==null?void 0:i.pagination.totalItems,order:j,handleOrderBy:Y,className:"tw:mb-4"}),v.jsx(h4,{type:"short-urls",className:"tw:mb-4"}),v.jsxs(qt,{bodyClassName:be({"tw:pb-0":!t.loading}),children:[v.jsx(a,{shortUrlsList:t,orderByColumn:K,renderOrderIcon:W,onTagClick:ee}),!t.loading&&v.jsx(YAe,{paginator:U,currentQueryString:f.search})]})]})},()=>[Wr.visits]),ZAe=Rn(zV,["ShortUrlsTable","ShortUrlsFilteringBar"]),TA=({children:e,danger:t})=>v.jsx(Je.Row,{children:v.jsx(Je.Cell,{colSpan:6,className:be("tw:text-center",{"tw:text-danger tw:font-bold":t}),children:e})}),XAe=({shortUrlsList:e,onTagClick:t,ShortUrlsRow:n})=>{const{error:r,loading:i,shortUrls:a}=e;return r?v.jsx(TA,{danger:!0,children:"Something went wrong while loading short URLs :("}):i?v.jsx(TA,{children:"Loading..."}):!a||a.data.length===0?v.jsx(TA,{children:"No results found"}):a==null?void 0:a.data.map(o=>v.jsx(n,{shortUrl:o,onTagClick:t},o.shortUrl))},FV=({orderByColumn:e,renderOrderIcon:t,shortUrlsList:n,onTagClick:r})=>{const{ShortUrlsRow:i}=Pn(FV),a=be({"tw:cursor-pointer":!!e});return v.jsx(Je,{className:"tw:mb-[-1px] tw:w-full",header:v.jsxs(Je.Row,{children:[v.jsxs(Je.Cell,{className:a,onClick:e==null?void 0:e("dateCreated"),children:["Created at ",t==null?void 0:t("dateCreated")]}),v.jsxs(Je.Cell,{className:a,onClick:e==null?void 0:e("shortCode"),children:["Short URL ",t==null?void 0:t("shortCode")]}),v.jsxs(Je.Cell,{children:[v.jsxs(Ad,{className:be("tw:p-0",a),onClick:e==null?void 0:e("title"),children:["Title ",t==null?void 0:t("title")]})," / ",v.jsxs(Ad,{className:be("tw:p-0",a),onClick:e==null?void 0:e("longUrl"),children:[v.jsx("span",{className:"tw:whitespace-nowrap",children:"Long URL"})," ",t==null?void 0:t("longUrl")]})]}),v.jsx(Je.Cell,{children:"Tags"}),v.jsx(Je.Cell,{className:a,onClick:e==null?void 0:e("visits"),children:v.jsxs("span",{className:"tw:whitespace-nowrap",children:["Visits ",t==null?void 0:t("visits")]})}),v.jsx(Je.Cell,{colSpan:2,"aria-hidden":!0})]}),children:v.jsx(XAe,{ShortUrlsRow:i,shortUrlsList:n,onTagClick:r})})},QAe=Rn(FV,["ShortUrlsRow"]),JAe=(e,t)=>{e.factory("ShortUrlsList",ZAe),e.decorator("ShortUrlsList",t(["mercureInfo","shortUrlsList"],["listShortUrls","createNewVisits","loadMercureInfo"])),e.factory("ShortUrlsTable",QAe),e.factory("ShortUrlsRow",bAe),e.factory("ShortUrlsRowMenu",CAe),e.decorator("ShortUrlsRowMenu",t(null,["shortUrlDeleted","deleteShortUrl"])),e.factory("ShortUrlForm",IAe),e.decorator("ShortUrlForm",t(["tagsList","domainsList"])),e.factory("CreateShortUrl",uAe),e.decorator("CreateShortUrl",t(["shortUrlCreation"],["createShortUrl","resetCreateShortUrl"])),e.factory("EditShortUrl",cAe),e.decorator("EditShortUrl",t(["shortUrlsDetails","shortUrlEdition"],["getShortUrlsDetails","editShortUrl"])),e.serviceFactory("DeleteShortUrlModal",()=>fAe),e.decorator("DeleteShortUrlModal",t(["shortUrlDeletion"],["resetDeleteShortUrl"])),e.factory("ExportShortUrlsBtn",dAe),e.factory("ShortUrlsFilteringBar",WAe),e.decorator("ShortUrlsFilteringBar",t(["tagsList","domainsList"])),e.serviceFactory("shortUrlsListReducerCreator",USe,"listShortUrls","editShortUrl","createShortUrl"),e.serviceFactory("shortUrlsListReducer",n=>n.reducer,"shortUrlsListReducerCreator"),e.serviceFactory("shortUrlCreationReducerCreator",EAe,"createShortUrl"),e.serviceFactory("shortUrlCreationReducer",n=>n.reducer,"shortUrlCreationReducerCreator"),e.serviceFactory("shortUrlEditionReducerCreator",jAe,"editShortUrl"),e.serviceFactory("shortUrlEditionReducer",n=>n.reducer,"shortUrlEditionReducerCreator"),e.serviceFactory("shortUrlDeletionReducerCreator",ISe,"deleteShortUrl"),e.serviceFactory("shortUrlDeletionReducer",n=>n.reducer,"shortUrlDeletionReducerCreator"),e.serviceFactory("shortUrlsDetailsReducerCreator",PAe,"apiClientFactory"),e.serviceFactory("shortUrlsDetailsReducer",n=>n.reducer,"shortUrlsDetailsReducerCreator"),e.serviceFactory("listShortUrls",BSe,"apiClientFactory"),e.serviceFactory("createShortUrl",AAe,"apiClientFactory"),e.serviceFactory("resetCreateShortUrl",n=>n.resetCreateShortUrl,"shortUrlCreationReducerCreator"),e.serviceFactory("deleteShortUrl",DSe,"apiClientFactory"),e.serviceFactory("resetDeleteShortUrl",n=>n.resetDeleteShortUrl,"shortUrlDeletionReducerCreator"),e.serviceFactory("shortUrlDeleted",()=>tV),e.serviceFactory("getShortUrlsDetails",n=>n.getShortUrlsDetails,"shortUrlsDetailsReducerCreator"),e.serviceFactory("editShortUrl",TAe,"apiClientFactory")},eEe=({tag:e,onClose:t,isOpen:n,deleteTag:r,tagDelete:i,tagDeleted:a})=>{const{deleting:o,error:l,deleted:f,errorData:u}=i;return v.jsxs(Vl,{title:"Delete tag",variant:"danger",open:n,onClose:t,onClosed:()=>f&&a(e),onConfirm:async()=>{await r(e),t()},confirmText:o?"Deleting tag...":"Delete tag",confirmDisabled:o,children:["Are you sure you want to delete tag ",v.jsx("b",{children:e}),"?",l&&v.jsx(Ei,{variant:"error",size:"sm",className:"tw:mt-2",children:v.jsx(co,{errorData:u,fallbackMessage:"Something went wrong while deleting the tag :("})})]})},qV=({tag:e,editTag:t,onClose:n,tagEdited:r,isOpen:i,tagEdit:a})=>{const{ColorGenerator:o}=Pn(qV),[l,f]=M.useState(e),[u,h]=M.useState(o.getColorForKey(e)),{editing:m,error:g,edited:_,errorData:x}=a,b=M.useCallback(async()=>{await t({oldName:e,newName:l,color:u}),n()},[u,t,l,n,e]),S=M.useCallback(()=>_&&r({oldName:e,newName:l,color:u}),[u,_,l,e,r]);return v.jsxs(Vl,{title:"Edit tag",open:i,onClose:n,onClosed:S,onConfirm:b,confirmText:m?"Saving...":"Save",confirmDisabled:m,children:[v.jsxs("div",{className:"tw:flex",children:[v.jsx(jV,{color:u,onChange:h,className:"tw:rounded-r-none",name:"tag-color"}),v.jsx(ti,{className:"tw:grow tw:[&]:rounded-l-none",value:l,placeholder:"Tag",required:!0,onChange:({target:C})=>f(C.value)})]}),g&&v.jsx(Ei,{variant:"error",size:"sm",className:"tw:mt-2",children:v.jsx(co,{errorData:x,fallbackMessage:"Something went wrong while editing the tag :("})})]})},tEe=Rn(qV,["ColorGenerator"]),VV=({onChange:e,placeholder:t,...n})=>{const{ColorGenerator:r}=Pn(VV),i=Xn("shortUrlCreation"),a=(i==null?void 0:i.tagFilteringMode)??"startsWith";return v.jsx($ie,{...n,onTagsChange:e,getColorForTag:o=>r.getColorForKey(o),size:"lg",placeholder:t??"Add tags to the URL",searchMode:a})},nEe=Rn(VV,["ColorGenerator"]),KO="shlink/tagDelete",rEe={deleting:!1,deleted:!1,error:!1},HV=Hr(`${KO}/tagDeleted`),iEe=e=>{const t=Zn(`${KO}/deleteTag`,async r=>{await e().deleteTags([r])}),{reducer:n}=Dn({name:KO,initialState:rEe,reducers:{},extraReducers:r=>{r.addCase(t.pending,()=>({deleting:!0,deleted:!1,error:!1})),r.addCase(t.rejected,(i,{error:a})=>({deleting:!1,deleted:!1,error:!0,errorData:Di(a)})),r.addCase(t.fulfilled,()=>({deleting:!1,deleted:!0,error:!1}))}});return{reducer:n,deleteTag:t}},A4="shlink/tagEdit",aEe={editing:!1,edited:!1,error:!1},GV=Hr(`${A4}/tagEdited`),oEe=(e,t)=>Zn(`${A4}/editTag`,async({oldName:n,newName:r,color:i})=>(await e().editTag({oldName:n,newName:r}),t.setColorForKey(r,i),{oldName:n,newName:r,color:i})),sEe=e=>Dn({name:A4,initialState:aEe,reducers:{},extraReducers:t=>{t.addCase(e.pending,()=>({editing:!0,edited:!1,error:!1})),t.addCase(e.rejected,(n,{error:r})=>({editing:!1,edited:!1,error:!0,errorData:Di(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>{const{oldName:i,newName:a}=r;return{oldName:i,newName:a,editing:!1,edited:!0,error:!1}})}}),E4="shlink/tagsList",jA={tags:[],filteredTags:[],stats:{},loading:!1,error:!1},S7=(e,t)=>n=>n===e?t:n,C7=(e,t)=>e.filter(n=>n!==t),lEe=(e,t)=>e.reduce((n,[r,i])=>{if(!n[r])return n;const{bots:a,nonBots:o}=i,l=n[r];return{...n,[r]:{...l,visitsSummary:l.visitsSummary&&{total:l.visitsSummary.total+a+o,bots:l.visitsSummary.bots+a,nonBots:l.visitsSummary.nonBots+o},visitsCount:(l.visitsCount??0)+a+o}}},{...t}),uEe=e=>Object.entries(e.reduce((t,{shortUrl:n,visit:r})=>(n==null||n.tags.forEach(i=>{t[i]||(t[i]={bots:0,nonBots:0}),r.potentialBot?t[i].bots+=1:t[i].nonBots+=1}),t),{})),cEe=e=>Zn(`${E4}/listTags`,async()=>{const{data:t}=await e().tagsStats(),n=t.reduce((r,{tag:i,...a})=>(r[i]=a,r),{});return{tags:Object.keys(n),stats:n}}),WV=Hr(`${E4}/filterTags`),fEe=(e,t)=>Dn({name:E4,initialState:jA,reducers:{},extraReducers:n=>{n.addCase(WV,(r,{payload:i})=>({...r,filteredTags:r.tags.filter(a=>a.toLowerCase().match(i.toLowerCase()))})),n.addCase(e.pending,r=>({...r,loading:!0,error:!1})),n.addCase(e.rejected,(r,{error:i})=>({...jA,error:!0,errorData:Di(i)})),n.addCase(e.fulfilled,(r,{payload:i})=>({...jA,stats:i.stats,tags:i.tags,filteredTags:i.tags})),n.addCase(HV,({tags:r,filteredTags:i,...a},{payload:o})=>({...a,tags:C7(r,o),filteredTags:C7(i,o)})),n.addCase(GV,({tags:r,filteredTags:i,stats:a,...o},{payload:l})=>({...o,stats:{...a,[l.newName]:a[l.oldName]},tags:r.map(S7(l.oldName,l.newName)).sort(),filteredTags:i.map(S7(l.oldName,l.newName)).sort()})),n.addCase(Yd,(r,{payload:i})=>({...r,stats:lEe(uEe(i.createdVisits),r.stats)})),n.addCase(t.fulfilled,({tags:r,...i},{payload:a})=>({...i,tags:r.concat(a.tags.filter(o=>!r.includes(o)))}))}}),dEe={tag:"Tag",shortUrls:"Short URLs",visits:"Visits"},YV=Ma(({filterTags:e,tagsList:t})=>{var n,r;const{TagsTable:i}=Pn(YV),a=ZT(),[o,l]=M.useState(((n=a.tags)==null?void 0:n.defaultOrdering)??{}),f=M.useMemo(()=>{const h=t.filteredTags.map(m=>{var g,_,x;const b=t.stats[m],S=((g=a.visits)!=null&&g.excludeBots?(_=b==null?void 0:b.visitsSummary)==null?void 0:_.nonBots:(x=b==null?void 0:b.visitsSummary)==null?void 0:x.total)??(b==null?void 0:b.visitsCount)??0;return{tag:m,visits:S,shortUrls:(b==null?void 0:b.shortUrlsCount)??0}});return O$(h,o)},[o,(r=a.visits)==null?void 0:r.excludeBots,t.filteredTags,t.stats]),u=d4();return t.loading?v.jsx(tc,{loading:!0}):t.error?v.jsx(Ei,{variant:"error",children:v.jsx(co,{errorData:t.errorData,fallbackMessage:"Error loading tags :("})}):v.jsx(f4,{value:u,children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(ag,{onChange:e}),v.jsx("div",{className:"tw:flex tw:flex-col tw:lg:flex-row tw:lg:justify-end",children:v.jsx("div",{className:"tw:lg:w-1/2",children:v.jsx(og,{containerClassName:"tw:[&]:block",buttonClassName:"tw:w-full",items:dEe,order:o,onChange:l})})}),v.jsx(h4,{type:"tags"}),v.jsx(i,{sortedTags:f,currentOrder:o,orderByColumn:h=>()=>l(E$({currentField:o.field,currentOrderDir:o.dir,newField:h}))})]})})},()=>[Wr.visits]),hEe=Rn(YV,["TagsTable"]),pEe=(e,t)=>{const n=r=>i=>{i.event.composedPath().some(({classList:a})=>a==null?void 0:a.contains("visits-table"))||document.querySelector(".modal")||r()};return Ase({delta:40,onSwipedLeft:n(t),onSwipedRight:n(e)})},mEe=(e,t)=>{const[n,r]=M.useState(t),i=M.useCallback(a=>{const{location:o,history:l}=window,f=T$(o.search);f[e]=a,l.pushState(null,"",`${o.pathname}?${PT(f)}`),r(a)},[e]);return[n,i]},O4=e=>{const t=Pd();return M.useMemo(()=>{var n;return((n=t[e])==null?void 0:n.split(",").filter(Boolean))??[]},[e,t])},gEe=(e,t)=>{const n=M.useCallback(()=>t(`(max-width: ${e}px)`).matches,[t,e]),[r,i]=M.useState(n());return M.useEffect(()=>{const a=()=>i(n());return window.addEventListener("resize",a),()=>window.removeEventListener("resize",a)},[n]),r},vEe=(e,t,n)=>{M.useEffect(()=>{if(!n)return()=>{};const r=new AbortController;return document.addEventListener("keydown",i=>i.key===e&&t(),{signal:r.signal}),()=>r.abort()},[n,t,e])},yEe=20,KV=({sortedTags:e,orderByColumn:t,currentOrder:n})=>{const{TagsTableRow:r}=Pn(KV),i=M.useRef(!0),{page:a=1}=Pd(),[o,l]=mEe("page",Number(a)),f=M.useCallback(_=>{l(_),scrollTo(0,0)},[l]),u=Mf(e,yEe),h=u.length>1,m=u[o-1]??[];M.useEffect(()=>{i.current||f(1),i.current=!1},[f,e]);const g="tw:cursor-pointer tw:top-(--header-height) tw:sticky-cell";return v.jsxs(qt,{bodyClassName:h?"tw:pb-1":"",children:[v.jsxs(Je,{header:v.jsxs(Je.Row,{children:[v.jsxs(Je.Cell,{onClick:t("tag"),className:g,children:["Tag ",v.jsx(Vp,{currentOrder:n,field:"tag"})]}),v.jsxs(Je.Cell,{onClick:t("shortUrls"),className:`tw:lg:text-right ${g}`,children:["Short URLs ",v.jsx(Vp,{currentOrder:n,field:"shortUrls"})]}),v.jsxs(Je.Cell,{onClick:t("visits"),className:`tw:lg:text-right ${g}`,children:["Visits ",v.jsx(Vp,{currentOrder:n,field:"visits"})]}),v.jsx(Je.Cell,{className:g,children:v.jsx("span",{className:"tw:sr-only",children:"Options"})})]}),children:[m.length===0&&v.jsx(Je.Row,{children:v.jsx(Je.Cell,{colSpan:4,className:"tw:text-center",children:"No tags found"})}),m.map(_=>v.jsx(r,{tag:_},_.tag))]}),h&&v.jsx("div",{className:be("tw:sticky tw:bottom-0 tw:py-4 tw:-mx-0.5","tw:flex tw:justify-around","tw:bg-lm-primary tw:dark:bg-dm-primary","tw:border-t tw:border-lm-border tw:dark:border-dm-border"),"data-testid":"tags-paginator",children:v.jsx(Xb,{pagesCount:u.length,currentPage:o,onPageChange:f})})]},o)},bEe=Rn(KV,["TagsTableRow"]),T4=({color:e,testId:t})=>v.jsx("div",{"data-testid":t,style:{backgroundColor:e},className:be("tw:inline-block tw:w-[20px] tw:h-[20px] tw:rounded-full","tw:align-[-4px] tw:mr-1.5")}),wEe=({tag:e,colorGenerator:t})=>v.jsx(T4,{color:t.getColorForKey(e)}),ZV=({tag:e})=>{const{DeleteTagConfirmModal:t,EditTagModal:n,ColorGenerator:r}=Pn(ZV),{flag:i,setToFalse:a,setToTrue:o}=wn(!1,!0),{flag:l,setToFalse:f,setToTrue:u}=wn(!1,!0),h=vs(),m=k1();return v.jsxs(Je.Row,{className:"tw:max-lg:relative",children:[v.jsxs(Je.Cell,{columnName:"Tag",children:[v.jsx(wEe,{tag:e.tag,colorGenerator:r})," ",e.tag]}),v.jsx(Je.Cell,{className:"tw:lg:text-right",columnName:"Short URLs",children:v.jsx(ur,{to:`${h}/list-short-urls/1?tags=${encodeURIComponent(e.tag)}`,children:jn(e.shortUrls)})}),v.jsx(Je.Cell,{className:"tw:lg:text-right",columnName:"Visits",children:v.jsx(ur,{to:`${h}/tag/${e.tag}/visits`,children:jn(e.visits)})}),v.jsx(Je.Cell,{className:"tw:lg:text-right tw:max-lg:absolute tw:max-lg:top-[-19px] tw:max-lg:right-0 tw:max-lg:p-0",children:v.jsxs(zn,{menuAlignment:"right",children:[v.jsxs(zn.Item,{onClick:u,className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:R9,fixedWidth:!0})," Edit"]}),v.jsxs(zn.Item,{className:"tw:gap-1.5",disabled:!m||!m.canAddItemWithName(e.tag),onClick:()=>m==null?void 0:m.addItemToCompare({name:e.tag,query:e.tag,style:r.stylesForKey(e.tag)}),children:[v.jsx(Ye,{icon:Ob,fixedWidth:!0})," Compare visits"]}),v.jsx(zn.Separator,{}),v.jsxs(zn.Item,{className:"tw:[&]:text-danger tw:gap-1.5",onClick:o,children:[v.jsx(Ye,{icon:YZ,fixedWidth:!0})," Delete tag"]})]})}),v.jsx(n,{tag:e.tag,onClose:f,isOpen:l}),v.jsx(t,{tag:e.tag,onClose:a,isOpen:i})]})},_Ee=Rn(ZV,["DeleteTagConfirmModal","EditTagModal","ColorGenerator"]),xEe=(e,t)=>{e.factory("TagsSelector",nEe),e.serviceFactory("DeleteTagConfirmModal",()=>eEe),e.decorator("DeleteTagConfirmModal",t(["tagDelete"],["deleteTag","tagDeleted"])),e.factory("EditTagModal",tEe),e.decorator("EditTagModal",t(["tagEdit"],["editTag","tagEdited"])),e.factory("TagsTableRow",_Ee),e.factory("TagsTable",bEe),e.factory("TagsList",hEe),e.decorator("TagsList",t(["tagsList","mercureInfo"],["filterTags","createNewVisits","loadMercureInfo"])),e.serviceFactory("tagEditReducerCreator",sEe,"editTag"),e.serviceFactory("tagEditReducer",n=>n.reducer,"tagEditReducerCreator"),e.serviceFactory("tagDeleteReducerCreator",iEe,"apiClientFactory"),e.serviceFactory("tagDeleteReducer",n=>n.reducer,"tagDeleteReducerCreator"),e.serviceFactory("tagsListReducerCreator",fEe,"listTags","createShortUrl"),e.serviceFactory("tagsListReducer",n=>n.reducer,"tagsListReducerCreator"),e.serviceFactory("listTags",cEe,"apiClientFactory"),e.serviceFactory("filterTags",()=>WV),e.serviceFactory("deleteTag",n=>n.deleteTag,"tagDeleteReducerCreator"),e.serviceFactory("tagDeleted",()=>HV),e.serviceFactory("editTag",oEe,"apiClientFactory","ColorGenerator"),e.serviceFactory("tagEdited",()=>GV)},SEe=new hU,CEe=e=>SEe.parse(e),AEe=6,A7="0123456789ABCDEF";function EEe(){return`#${p4(AEe,()=>A7[Math.floor(Math.random()*A7.length)]).join("")}`}const E7=e=>e.toLowerCase().trim();class OEe{constructor(t){Ol(this,"colors"),Ol(this,"lights");var n;this.storage=t,this.colors=((n=this.storage)==null?void 0:n.getTagColors())??{},this.lights={}}getColorForKey(t){const n=E7(t);return this.colors[n]||this.setColorForKey(n,EEe())}setColorForKey(t,n){var r;const i=E7(t);return this.colors[i]=n,(r=this.storage)==null||r.storeTagColors(this.colors),n}stylesForKey(t){const n=this.getColorForKey(t);return{backgroundColor:n,color:this.isLightColor(n)?"#222":"#fff"}}isLightColor(t){const n=t.substring(1);return this.lights[n]===void 0&&(this.lights[n]=C$(n)),this.lights[n]}}const XV=({document:e},t,n)=>{const r=e.createElement("a");r.setAttribute("href",t),r.setAttribute("download",n),r.style.visibility="hidden",e.body.appendChild(r),r.click(),e.body.removeChild(r)},TEe=(e,t,n)=>{const r=new Blob([t],{type:"text/csv;charset=utf-8;"}),i=URL.createObjectURL(r);XV(e,i,n)};class jEe{constructor(t,n){this.fetch=t,this.window=n}async saveImage(t,n){const r=await this.fetch(t).then(a=>a.blob()),i=URL.createObjectURL(r);XV(this.window,i,n)}}class PEe{constructor(t,n){Ol(this,"exportVisits",(r,i)=>{i.length&&this.exportCsv(r,i)}),Ol(this,"exportShortUrls",r=>{r.length&&this.exportCsv("short_urls.csv",r)}),Ol(this,"exportCsv",(r,i)=>{const a=this.jsonToCsv(i);TEe(this.window,a,r)}),this.window=t,this.jsonToCsv=n}}function REe(e){e.constant("window",window),e.constant("fetch",window.fetch.bind(window)),e.service("ImageDownloader",jEe,"fetch","window"),e.service("ColorGenerator",OEe,"TagColorsStorage"),e.constant("jsonToCsv",CEe),e.service("ReportExporter",PEe,"window","jsonToCsv"),e.serviceFactory("useTimeoutToggle",()=>jT)}const yg=({visits:e,shortUrl:t,children:n,title:r})=>v.jsx("header",{children:v.jsxs(qt,{children:[v.jsxs("h2",{className:"tw:flex tw:justify-between tw:items-center",children:[v.jsx(z1,{}),v.jsx("span",{className:"tw:text-center tw:hidden tw:sm:block",children:v.jsx("small",{children:r})}),v.jsxs("span",{className:be("tw:px-3 tw:py-1.5 tw:rounded-md tw:ml-3","tw:font-bold tw:text-white tw:text-2xl","tw:bg-lm-main tw:dark:bg-dm-main"),"data-testid":"badge",children:["Visits:"," ",v.jsx(OV,{visitsCount:e.length,shortUrl:t})]})]}),v.jsx("h3",{className:"tw:text-center tw:block tw:sm:hidden tw:mt-3",children:v.jsx("small",{children:r})}),n&&v.jsx("div",{className:"tw:md:mt-3",children:n})]})}),j4=({children:e,className:t})=>v.jsx("div",{className:be("tw:flex tw:justify-between tw:items-center",t),children:e}),QV=({title:e,footer:t,children:n})=>v.jsxs(Fn,{role:"document",children:[v.jsx(Fn.Header,{children:e}),v.jsx(Fn.Body,{children:n}),t&&v.jsx(Fn.Footer,{className:"tw:sticky tw:bottom-0",children:t})]}),JV=M.createContext(null),{Provider:f4e}=JV,P4=e=>{const t=M.useContext(JV)??void 0,n=M.useMemo(()=>t?{}:{width:"100%",height:e},[e,t]);return{ChartWrapper:t?M.Fragment:dde,dimensions:t,wrapperDimensions:n}},eH={color:"white",background:"rgb(0 0 0 / .9)",border:"none",borderRadius:"5px"},MEe={marginBottom:"5px",fontWeight:"bold"},tH={contentStyle:eH,labelStyle:MEe,itemStyle:{padding:0}},O7=["#97BBCD","#F7464A","#46BFBD","#FDB45C","#949FB1","#57A773","#414066","#08B2E3","#B6C454","#DCDCDC","#463730"],nH=e=>O7[e%O7.length],gb=()=>Qm()?"#46e587":"#1DAA58",NEe=()=>Qm()?"rgba(70, 229, 135, 0.4)":"rgba(29, 170, 88, 0.4)",LEe=({chartData:e,showNumbers:t})=>v.jsx("ul",{className:"tw:space-y-1",children:e.map(({name:n,color:r,value:i},a)=>v.jsxs("li",{className:"tw:flex tw:items-center",children:[v.jsx(T4,{color:r,testId:`color-bullet-${a}`}),v.jsxs("small",{className:"tw:truncate tw:grow","data-testid":`name-${a}`,children:[n,t&&v.jsxs("b",{children:[" (",jn(i),")"]})]})]},n))}),T7=e=>M.useMemo(()=>Object.entries(e).map(([t,n],r)=>({name:t,value:n,color:nH(r)})),[e]),kEe=({stats:e,prevStats:t,showNumbersInLegend:n})=>{const r=T7(e),i=T7(t),a=i.length>0,o=Qm()?JJ:QJ,{ChartWrapper:l,dimensions:f,wrapperDimensions:u}=P4(300);return v.jsxs("div",{className:"tw:flex tw:flex-col tw:md:flex-row tw:md:items-center tw:gap-y-4",children:[v.jsx("div",{className:"tw:md:flex-7",children:v.jsx("div",{style:u,children:v.jsx(l,{children:v.jsxs(D2e,{...f,children:[v.jsx(Xi,{formatter:jn,contentStyle:eH,itemStyle:{color:"white"}}),v.jsx(uo,{data:r,dataKey:"value",nameKey:"name",startAngle:360,endAngle:0,outerRadius:"100%",innerRadius:a?"65%":"50%",animationBegin:0,children:r.map((h,m)=>v.jsx(Cl,{fill:h.color,stroke:o},`${h.name}-${m}`))}),a&&v.jsx(uo,{data:i,dataKey:"value",nameKey:"name",startAngle:360,endAngle:0,outerRadius:"55%",innerRadius:"20%",animationBegin:0,stroke:o,fill:gb()})]})})})}),v.jsx("div",{className:"tw:md:flex-5",children:v.jsx(LEe,{chartData:r,showNumbers:n})})]})},j7=({title:e,...t})=>{const{flag:n,toggle:r}=wn(!1,!0);return v.jsx(QV,{title:v.jsxs(j4,{children:[e,v.jsx(os,{checked:n,onChange:r,children:"Show numbers"})]}),children:v.jsx(kEe,{...t,showNumbersInLegend:n})})},DEe=M.forwardRef(({visitsGroups:e},t)=>{const n=M.useMemo(()=>Object.entries(e),[e]);return n.length===0?null:v.jsx("ul",{className:"tw:mt-2 tw:flex tw:flex-wrap tw:justify-center tw:gap-4",ref:t,children:n.map(([r,i],a)=>v.jsxs("li",{className:"tw:inline",children:[v.jsx(T4,{color:rH(i)}),v.jsxs("strong",{children:[r," (",jn(i.length),")"]})]},`${r}${a}`))})}),IEe={monthly:"Month",weekly:"Week",daily:"Day",hourly:"Hour"},$Ee={hourly:e=>({hours:e}),daily:e=>({days:e}),weekly:e=>({weeks:e}),monthly:e=>({months:e})},BEe={hourly:Iae,daily:Qb,weekly:Dae,monthly:o0},R4={hourly:e=>s0(e,"yyyy-MM-dd HH:00"),daily:e=>Sl(e),weekly(e){const t=Sl(im(e)),n=Sl(Hae(e));return`${t} - ${n}`},monthly:e=>s0(e,"yyyy-MM")},UEe=e=>{var t;const n=Object.values(e).filter(o=>o.length>0);if(n.length===0)return"monthly";const r=new Date,i=n.map(o=>$l(o[o.length-1].date)),a=aU(i);return((t=[[()=>Qb(r,a)<=2,"hourly"],[()=>o0(r,a)<=1,"daily"],[()=>o0(r,a)<=6,"weekly"]].find(([o])=>o()))==null?void 0:t[1])??"monthly"},zEe=(e,t)=>Object.keys(t).reduce((n,r)=>(n[r]=bB(t[r],i=>R4[e]($l(i.date))),n),{}),FEe=(e,t)=>t.reduce((n,r)=>{const i=R4[e]($l(r.date));return n[i]=n[i]??[],n[i].push(r),n},{}),qEe=(e,t)=>{const n=Object.values(t).filter(h=>h.length>0).map(h=>[...h].reverse());if(n.length===0)return[];const r=BEe[e],i=R4[e],a=$Ee[e],o=n.flat(),l=$l(o[0].date),f=$l(o[o.length-1].date),u=r(f,l)||1;return[{formattedDate:i(l),date:l},...p4(u,h=>{const m=Pae(l,a(h));return{formattedDate:i(m),date:m}})]},rH=e=>{if(e.color)return e.color;const t={main:Yp,highlighted:rE,previous:gb()};return e.type?t[e.type]:Yp},P7=(e,t)=>M.useMemo(()=>Object.values(e).find(n=>n.type===t)??[],[e,t]),VEe=(e,t,n)=>{const r=P7(e,"main"),i=P7(e,"highlighted"),a=M.useMemo(()=>n?FEe(t,r):{},[n,t,r]),o=M.useCallback((l,{payload:f})=>{const u=a[f.formattedDate]??[];n==null||n(u===i?[]:u)},[a,i,n]);return n&&{cursor:"pointer",onClick:o}},R7=e=>{var t,n;return(n=(t=e.activePayload)==null?void 0:t[0])==null?void 0:n.payload},iH=({visitsGroups:e,setSelectedVisits:t,matchMedia:n,onDateRangeChange:r})=>{const[i,a]=M.useState(UEe(e)),o=gEe(767,n??window.matchMedia),l=M.useMemo(()=>{const W=zEe(i,e),ee=Object.keys(W);return qEe(i,e).map(({formattedDate:ie,date:X})=>({date:X,formattedDate:ie,...ee.reduce((ne,H)=>(ne[H]=W[H][ie]??0,ne),{})}))},[i,e]),f=VEe(e,i,t),{flag:u,toggle:h,setToFalse:m}=wn(!1,!0),g=M.useId(),_=M.useRef(null),[x,b]=M.useState(o?300:400);M.useLayoutEffect(()=>{if(!u)return b(o?300:400),()=>{};const W=new ResizeObserver(()=>{const ee=window.innerHeight,{height:ie}=_.current.getBoundingClientRect();b(ee-ie-98)});return W.observe(_.current),()=>W.disconnect()},[u,o,_]),vEe("Escape",m,u);const{ChartWrapper:S,dimensions:C,wrapperDimensions:A}=P4(x),[O,P]=M.useState(),[j,R]=M.useState(),U=M.useCallback(()=>{P(void 0),R(void 0)},[]),V=M.useCallback((W,ee)=>{const ie=R7(W);ee.button===0&&ie&&P(ie)},[]),Y=M.useCallback(W=>{const ee=R7(W);O&&ee&&R(ee)},[O]),K=M.useCallback(()=>{if(!O||!j)return;const W=[O.date,j.date],ee=Nae(W),ie=aU(W);U(),r({startDate:ee,endDate:ie})},[r,U,j,O]);return v.jsxs(Fn,{className:be({"tw:fixed tw:top-0 tw:bottom-0 tw:left-0 tw:right-0 tw:z-1030":u}),"data-testid":"line-chart-card",children:[v.jsxs(Fn.Header,{role:"heading","aria-level":4,className:"tw:flex tw:justify-between tw:items-center",children:["Visits over time",v.jsxs("div",{className:"tw:flex tw:content-center tw:gap-1",children:[v.jsx(Zb,{"aria-label":u?"Collapse":"Expand","aria-expanded":u,"aria-controls":g,size:"sm",onClick:h,children:v.jsx(Ye,{icon:u?OZ:_X})}),v.jsx(tt,{buttonContent:"Group by",buttonSize:"sm",buttonVariant:"link",buttonClassName:"tw:[&]:p-0",menuAlignment:"right",menuClassName:"tw:w-40",children:Object.entries(IEe).map(([W,ee])=>v.jsx(tt.Item,{selected:i===W,onClick:()=>a(W),children:ee},W))})]})]}),v.jsxs(Fn.Body,{id:g,children:[v.jsx(S,{...A,children:v.jsxs(k2e,{className:"tw:select-none",data:l,...C,onMouseDown:V,onMouseMove:Y,onMouseUp:K,children:[v.jsx(Gd,{dataKey:"formattedDate"}),v.jsx(Wd,{tickFormatter:jn,yAxisId:"1"}),v.jsx(Xi,{formatter:jn,...tH}),v.jsx(i4,{strokeOpacity:Qm()?.1:.9}),Object.entries(e).map(([W,ee])=>ee.length>0&&v.jsx(Hd,{yAxisId:"1",dataKey:W,type:"monotone",stroke:rH(ee),strokeWidth:2,activeDot:ee.type==="previous"?void 0:f,strokeDasharray:ee.type==="previous"?"8 3":void 0},W)),O&&j&&v.jsx(mg,{yAxisId:"1",x1:O.formattedDate,x2:j.formattedDate})]})}),v.jsx(DEe,{visitsGroups:e,ref:_})]})]})},HEe=({ranges:e,value:t,setValue:n})=>v.jsxs(tt,{buttonContent:"Paginate",buttonVariant:"link",buttonClassName:"tw:[&]:p-0",buttonSize:"sm",menuAlignment:"right",children:[e.map(r=>v.jsxs(tt.Item,{selected:r===t,onClick:()=>n(r),children:[v.jsx("b",{children:r})," items per page"]},r)),v.jsx(tt.Separator,{}),v.jsx(tt.Item,{disabled:t===1/0,onClick:()=>n(1/0),children:v.jsx("i",{children:"Clear pagination"})})]}),M7=e=>e.startsWith("hidden_"),GEe=({stats:e,prevStats:t,highlightedStats:n,highlightedLabel:r,max:i,onClick:a})=>{const o=M.useMemo(()=>Object.entries(e).map(([m,g])=>{const _=(n==null?void 0:n[m])??0,x=(t==null?void 0:t[m])??0,b=M7(m);return{name:m,amount:Math.max(g,x),nonHighlightedAmount:b?null:g-_,highlightedAmount:b?null:_,prevAmount:b?null:x}}),[e,t,n]),l=M.useMemo(()=>{const m=o.reduce((g,{name:_})=>g>_.length?g:_.length,0);return Math.min(150,m*7)},[o]),{ChartWrapper:f,dimensions:u,wrapperDimensions:h}=P4(Math.max(300,o.length*(t?44:22)));return v.jsx(f,{...h,children:v.jsxs(I2e,{layout:"vertical",data:o,barCategoryGap:3,...u,children:[v.jsx(Gd,{type:"number",dataKey:"amount",tickFormatter:jn,domain:i?[0,i]:void 0}),v.jsx(Wd,{type:"category",dataKey:"name",width:l,interval:0,style:{fontSize:".8rem"},tickFormatter:m=>M7(m)?"":m}),v.jsx(i4,{strokeOpacity:Qm()?.05:.9}),v.jsx(Xi,{filterNull:!0,...tH,formatter:(m,g)=>[jn(m),g==="highlightedAmount"?r:g==="prevAmount"?"Previous period":n?"Non-selected":"Visits"]}),v.jsx(ts,{dataKey:"nonHighlightedAmount",stackId:"main",cursor:"pointer",fill:Yp,onClick:({name:m})=>a==null?void 0:a(m),children:o.map(m=>v.jsx(Cl,{fill:ZJ,stroke:Yp,strokeWidth:2},m.name))}),n&&v.jsx(ts,{dataKey:"highlightedAmount",stackId:"main",cursor:"pointer",fill:rE,onClick:({name:m})=>a==null?void 0:a(m),children:o.map(m=>v.jsx(Cl,{fill:XJ,stroke:rE,strokeWidth:2},m.name))}),t&&v.jsx(ts,{dataKey:"prevAmount",fill:gb(),children:o.map(m=>v.jsx(Cl,{fill:NEe(),stroke:gb(),strokeWidth:2},m.name))})]})})},WEe=e=>typeof e=="string"?e.toLowerCase():e,YEe=([e])=>e,KEe=([,e])=>e,by=({stats:e,prevStats:t,highlightedStats:n,title:r,sortingItems:i,extraHeaderContent:a,withPagination:o=!0,...l})=>{const[f,u]=M.useState({}),[h,m]=M.useState(1),[g,_]=M.useState(50),x=M.useCallback((V,Y)=>{const K=Object.entries(V),W=f.field?Qne(K,([ee,ie])=>WEe(f.field===Object.keys(Y)[0]?ee:ie)):K;return!f.dir||f.dir==="ASC"?W:[...W].reverse()},[f.dir,f.field]),b=M.useCallback(V=>{const Y=V[h-1];if(h<V.length)return Y;const K=V[0].length;return[...Y,...p4(K-Y.length,W=>[`hidden_${W}`,0])]},[h]),S=M.useCallback(V=>v.jsx(Xb,{currentPage:h,pagesCount:V,onPageChange:m}),[h]),C=M.useCallback((V,Y,K,W)=>{const ee=x(V,Y),ie=ee.map(YEe),X=K&&Object.entries({...d6(ie,ie.map(()=>0)),...K}),ne=W&&Object.entries({...d6(ie,ie.map(()=>0)),...W});if(ee.length<=g)return{currentPageStats:Object.fromEntries(ee),currentPageHighlightedStats:X&&Object.fromEntries(X),currentPagePrevStats:ne&&Object.fromEntries(ne)};const H=Mf(ee,g),I=X&&Mf(X,g),D=ne&&Mf(ne,g);return{currentPageStats:Object.fromEntries(b(H)),currentPageHighlightedStats:I&&Object.fromEntries(b(I)),currentPagePrevStats:D&&Object.fromEntries(b(D)),pagination:S(H.length),max:Kie(Math.max(...ee.map(KEe)))}},[b,x,g,S]),{currentPageStats:A,currentPagePrevStats:O,currentPageHighlightedStats:P,pagination:j,max:R}=M.useMemo(()=>C(e,i,n&&Object.keys(n).length>0?n:void 0,t&&Object.keys(t).length>0?t:void 0),[C,n,t,i,e]),U=M.useMemo(()=>Object.keys(A),[A]);return v.jsx(QV,{title:v.jsxs(j4,{children:[r,v.jsxs("div",{className:"tw:flex tw:items-center tw:gap-3",children:[a==null?void 0:a(j?U:void 0),o&&Object.keys(e).length>50&&v.jsx(HEe,{ranges:[50,100,200,500],value:g,setValue:V=>{_(V),m(1)}}),v.jsx(og,{buttonVariant:"link",menuAlignment:"right",buttonSize:"sm",buttonClassName:"tw:[&]:p-0",items:i,order:f,onChange:V=>{u(V),m(1)}})]})]}),footer:j&&v.jsx("div",{className:"tw:flex tw:justify-around tw:items-center","data-testid":"chart-paginator",children:j}),children:v.jsx(GEe,{stats:A,prevStats:O,highlightedStats:P,max:R,...l})})},M4=e=>e.type!==void 0,ZEe=e=>e.type!==void 0,XEe=e=>{const t=wB(e,n=>M4(n.visit)?"orphanVisits":"nonOrphanVisits");return{orphanVisits:[],nonOrphanVisits:[],...t}},aH=(e,{shortCode:t,domain:n},{endDate:r,startDate:i}={})=>e.filter(({shortUrl:a,visit:o})=>a&&qp(a,t,n)&&vg(o.date,i,r)),oH=(e,t,{endDate:n,startDate:r}={})=>e.filter(({shortUrl:i,visit:a})=>i&&LSe(i,t)&&vg(a.date,r,n)),sH=(e,t,{endDate:n,startDate:r}={})=>e.filter(({shortUrl:i,visit:a})=>(i==null?void 0:i.tags.includes(t))&&vg(a.date,r,n)),wy=(e,t)=>bB(e,n=>n[t]),QEe=e=>{const t=((e==null?void 0:e.startDate)&&ql(e==null?void 0:e.startDate))??void 0,n=((e==null?void 0:e.endDate)&&ql(e==null?void 0:e.endDate))??void 0;return{startDate:t,endDate:n}},ZO=({filter:e,dateRange:t})=>{const{startDate:n,endDate:r}=QEe(t),i=(e==null?void 0:e.excludeBots)||void 0;return{startDate:n,endDate:r,excludeBots:i}},JEe=e=>BV(e.dateRange),eOe=({dateRange:e,...t})=>({...t,dateRange:qAe(e)}),N7=(e,t)=>{if(!(!t||!(e in t)))return t[e]&&ql(t[e])||""},lH=()=>{const e=po(),t=Pd(),{startDate:n,endDate:r,orphanVisitsType:i,excludeBots:a,loadPrevInterval:o,...l}=t,f=M.useMemo(()=>({dateRange:n!=null||r!=null?DV(n,r):void 0,visitsFilter:{orphanVisitsType:i,excludeBots:a!==void 0?a==="true":void 0},loadPrevInterval:o!==void 0?o==="true":void 0}),[r,a,o,i,n]),u=M.useCallback(h=>{const{dateRange:m,visitsFilter:g={},loadPrevInterval:_}=Gb(f,h),{excludeBots:x,orphanVisitsType:b}=g,S={...l,startDate:N7("startDate",m),endDate:N7("endDate",m),excludeBots:x===void 0?void 0:HO(x),orphanVisitsType:b,loadPrevInterval:_===void 0?void 0:HO(_)},C=PT(S),A=C?`?${C}`:"";e(A,{replace:!0,relative:"route"})},[f,e,l]);return[f,u]},tOe=()=>v.jsx(nSe,{attribution:'© <a href="https://osm.org/copyright">OpenStreetMap</a> contributors',url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"}),nOe=e=>{if(e.length===0)return{};if(e.length>1)return{bounds:e.map(({latLong:n})=>n)};const[{latLong:t}]=e;return{zoom:10,center:t}},uH=({toggle:e,isOpen:t,title:n,locations:r=[]})=>v.jsx(Vl,{open:t,onClose:e,title:n,variant:"cover",children:v.jsxs(J2e,{...nOe(r),className:"tw:h-full tw:w-full",children:[v.jsx(tOe,{}),r.map(({cityName:i,latLong:a,count:o},l)=>v.jsx(eSe,{position:a,children:v.jsxs(tSe,{children:[v.jsx("b",{children:o})," visit",o>1?"s":""," from ",v.jsx("b",{children:i})]})},l))]})}),rOe=({modalTitle:e,activeCities:t,locations:n=[]})=>{const{flag:r,setToTrue:i,setToFalse:a}=wn(!1,!0),[o,l]=M.useState([]),f=M.useCallback(u=>{l(u?n.filter(u):n),i()},[n,i]);return v.jsxs(v.Fragment,{children:[!t&&v.jsx(Zb,{onClick:()=>f(),"aria-label":"Show in map",title:"Show in map",className:"tw:[&]:p-0",children:v.jsx(Ye,{icon:IA})}),t&&v.jsxs(tt,{buttonContent:v.jsx(Ye,{icon:IA,title:"Show in map"}),buttonLabel:"Show in map",buttonVariant:"link",buttonClassName:"tw:[&]:p-0",menuAlignment:"right",caretless:!0,children:[v.jsx(tt.Item,{onClick:()=>f(),children:"Show all locations"}),v.jsx(tt.Item,{onClick:()=>f(({cityName:u})=>t.includes(u)),children:"Show locations in current page"})]}),v.jsx(uH,{toggle:a,isOpen:r,title:e,locations:o})]})},cH=({onChange:e,selected:t={},isOrphanVisits:n=!1,withPrevInterval:r=!1,disabled:i})=>{const{orphanVisitsType:a,excludeBots:o=!1,loadPrevInterval:l=!1}=t,f=m=>({selected:a===m,onClick:()=>e({...t,orphanVisitsType:m===a?void 0:m})}),u=M.useCallback(()=>e({...t,excludeBots:!o}),[o,e,t]),h=M.useCallback(()=>e({...t,loadPrevInterval:!l}),[l,e,t]);return v.jsxs(tt,{buttonDisabled:i,buttonContent:"More",buttonClassName:"tw:w-full",menuAlignment:"right",children:[r&&v.jsxs(v.Fragment,{children:[v.jsx(tt.Item,{selected:l,onClick:h,children:"Compare with previous period"}),v.jsx(tt.Separator,{})]}),v.jsx(tt.Title,{children:"Bots:"}),v.jsx(tt.Item,{selected:o,onClick:u,children:"Exclude potential bots"}),n&&v.jsxs(v.Fragment,{children:[v.jsx(tt.Separator,{}),v.jsx(tt.Title,{children:"Orphan visits type:"}),v.jsx(tt.Item,{...f("base_url"),children:"Base URL"}),v.jsx(tt.Item,{...f("invalid_short_url"),children:"Invalid short URL"}),v.jsx(tt.Item,{...f("regular_404"),children:"Regular 404"})]}),v.jsx(tt.Separator,{}),v.jsx(tt.Item,{disabled:t.excludeBots===void 0&&t.loadPrevInterval===void 0&&t.orphanVisitsType===void 0,onClick:()=>e({excludeBots:void 0,loadPrevInterval:void 0,orphanVisitsType:void 0}),children:v.jsx("i",{children:"Reset to defaults"})})]})},iOe=({className:e,value:t,...n})=>{const r=Math.min(100,Math.max(0,t));return v.jsx("div",{className:be("tw:flex tw:h-4 tw:bg-gray-100 tw:overflow-hidden tw:rounded-md",e),...n,children:v.jsx("div",{role:"progressbar","aria-valuemax":100,"aria-valuemin":0,"aria-valuenow":r,className:"tw:bg-lm-brand tw:dark:bg-dm-brand tw:transition-[width]",style:{width:`${r}%`}})})},fH=({info:e})=>{const{loading:t,errorData:n,progress:r}=e;return v.jsxs(v.Fragment,{children:[t&&r===null&&v.jsx(tc,{loading:!0}),t&&r!==null&&v.jsxs(tc,{loading:!0,children:["This is going to take a while... :S",v.jsx(iOe,{value:r,className:"tw:mt-4"})]}),n&&v.jsx(Ei,{variant:"error",children:v.jsx(co,{errorData:n,fallbackMessage:"An error occurred while loading visits :("})})]})},Ly=({children:e,showFallback:t})=>v.jsxs(v.Fragment,{children:[t&&v.jsx(tc,{children:"There are no visits matching current filter"}),!t&&v.jsx(v.Fragment,{children:e})]}),aOe=({visitsDeletion:e,deleteVisits:t})=>{const{deleting:n}=e,{flag:r,setToTrue:i}=wn(!1,!0);return v.jsx(qt,{title:v.jsx("span",{className:"tw:text-danger tw:font-bold tw:text-base",children:"Danger zone"}),children:v.jsxs(j4,{children:[v.jsxs("dl",{className:"tw:m-0 tw:mr-3",children:[v.jsx("dt",{children:"Delete visits."}),v.jsxs("dd",{className:"tw:m-0",children:["This will delete ",v.jsx("b",{children:"all"})," visits, not only the ones matching current filter."]})]}),!r&&v.jsx(Tn,{variant:"danger",solid:!0,className:"tw:whitespace-nowrap",onClick:i,children:"Delete visits"}),r&&v.jsxs(Tn,{solid:!0,variant:"danger",disabled:n,className:"tw:whitespace-nowrap",onClick:t,autoFocus:!0,children:[!n&&v.jsx(v.Fragment,{children:"Click again to confirm"}),n&&v.jsx(v.Fragment,{children:"Deleting..."})]})]})})},_y="Others",oOe=["Android Browser","Chrome","Chromium","Firefox","Internet Explorer","Microsoft Edge","Opera","Safari","Samsung Internet for Android","Vivaldi","WeChat"],sOe=e=>{if(!$u(e))return{browser:_y,os:_y};const{browser:{name:t},os:{name:n}}=lSe.parse(e);return{os:n??_y,browser:t&&oOe.includes(t)?t:_y}},lOe=e=>{var t;return $u(e)?((t=e.split("/")[e.includes("://")?2:0])==null?void 0:t.split(":")[0])??"":"Direct"},dH=(e,t)=>e[t]!==void 0,L7=e=>typeof e=="number"?e:e?parseFloat(e):0,uOe=(e,{os:t})=>{e[t]=(e[t]||0)+1},cOe=(e,{browser:t})=>{e[t]=(e[t]||0)+1},fOe=(e,{referer:t})=>{e[t]=(e[t]||0)+1},hH=e=>(t,n)=>{const r=dH(n,e)?n[e]:"Unknown";t[r]=(t[r]||0)+1},dOe=hH("country"),hOe=hH("city"),pOe=(e,t)=>{if(!dH(t,"city")||t.city==="Unknown")return;const{city:n,latitude:r,longitude:i}=t,a=e[n]||{cityName:n,count:0,latLong:[L7(r),L7(i)]};a.count+=1,e[n]=a},mOe=(e,t)=>{if(!ZEe(t))return;const{visitedUrl:n}=t;e[n]=(e[n]||0)+1},XO=e=>e.reduce((t,n)=>(uOe(t.os,n),cOe(t.browsers,n),fOe(t.referrers,n),dOe(t.countries,n),hOe(t.cities,n),pOe(t.citiesForMap,n),mOe(t.visitedUrls,n),t),{os:{},browsers:{},referrers:{},countries:{},cities:{},citiesForMap:{},visitedUrls:{}}),vb=e=>e.map(t=>{const{userAgent:n,date:r,referer:i,visitLocation:a,potentialBot:o}=t;return{date:r,potentialBot:o,userAgent:n,...sOe(n),referer:lOe(i),country:(a==null?void 0:a.countryName)||"Unknown",city:(a==null?void 0:a.cityName)||"Unknown",latitude:a==null?void 0:a.latitude,longitude:a==null?void 0:a.longitude,visitedUrl:t.visitedUrl,type:M4(t)?t.type:void 0}}),gOe=Object.freeze(Object.defineProperty({__proto__:null,normalizeVisits:vb,processStatsFromVisits:XO},Symbol.toStringTag,{value:"Module"})),Tp=20,vOe=({browser:e,os:t,referer:n,country:r,city:i,userAgent:a,...o},l,f)=>{const u=f?a:`${r} ${i}`;return`${e} ${t} ${n} ${u} ${o.visitedUrl}`.toLowerCase().includes(l.toLowerCase())},yOe=(e,t,n)=>t.filter(r=>vOe(r,e,n)),bOe=(e,t)=>O$(t,e),wOe=({visits:e,searchTerm:t,order:n,searchInRawUserAgent:r})=>{const i=t?yOe(t,e,r):[...e],a=bOe(n,i),o=a.length;return{visitsGroups:Mf(a,Tp),total:o}},Ya="tw:cursor-pointer tw:md:sticky-cell-separated tw:md:top-[calc(var(--header-height)+41px)]",_Oe=()=>{const{anchor:e,tooltip:t}=Hl({placement:"right"});return v.jsxs(v.Fragment,{children:[v.jsx(Ye,{icon:$9,...e}),v.jsx(Gl,{...t,children:"Potentially a visit from a bot or crawler"})]})},xOe=({visits:e,selectedVisits:t=[],setSelectedVisits:n})=>{var r;const[i,a]=M.useState(),o=M.useCallback(R=>{a(R),x(1),n([])},[n]),[l,f]=M.useState({}),{flag:u,toggle:h}=wn(!1,!0),m=M.useCallback(()=>{h(),f({})},[h]),g=M.useMemo(()=>wOe({visits:e,searchTerm:i,order:l,searchInRawUserAgent:u}),[e,i,l,u]),[_,x]=M.useState(1),b=_*Tp,S=b-Tp,C=M.useMemo(()=>{var R,U;return!!((U=(R=g.visitsGroups[_-1])==null?void 0:R[0])!=null&&U.visitedUrl)},[_,g.visitsGroups]),A=6+Number(C)+(u?1:2),O=g.total>0,P=R=>f({field:R,dir:Db(R,l.field,l.dir)}),j=R=>v.jsx(Vp,{currentOrder:l,field:R,className:"tw:float-right tw:mt-[5px] tw:ml-[5px]"});return v.jsx(qt,{bodyClassName:"tw:[&]:p-0 tw:[&]:pb-1",title:v.jsxs("span",{className:"tw:flex tw:justify-between tw:items-center tw:text-base",children:["Visits list",v.jsx(os,{checked:u,onChange:m,children:"Show user agent"})]}),children:v.jsxs(Je,{responsive:!1,size:"sm",className:"tw:w-full tw:relative tw:overflow-y-hidden tw:bg-lm-primary tw:dark:bg-dm-primary",header:v.jsxs(v.Fragment,{children:[v.jsxs(Je.Row,{children:[v.jsxs(Je.Cell,{className:be(Ya,"tw:text-center"),onClick:()=>n(t.length<g.total?g.visitsGroups.flat():[]),children:[v.jsx("span",{className:"tw:sr-only",children:"Is selected"}),v.jsx(Ye,{icon:Zu,className:be({"tw:text-lm-brand tw:dark:text-dm-brand":t.length>0})})]}),v.jsxs(Je.Cell,{className:be(Ya,"tw:text-center"),onClick:()=>P("potentialBot"),children:[v.jsx("span",{className:"tw:sr-only",children:"Is bot"}),v.jsx(Ye,{icon:$9}),j("potentialBot")]}),v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("date"),children:["Date",j("date")]}),v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("country"),children:["Country",j("country")]}),v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("city"),children:["City",j("city")]}),u?v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("userAgent"),children:["User agent",j("userAgent")]}):v.jsxs(v.Fragment,{children:[v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("browser"),children:["Browser",j("browser")]}),v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("os"),children:["OS",j("os")]})]}),v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("referer"),children:["Referrer",j("referer")]}),C&&v.jsxs(Je.Cell,{className:Ya,onClick:()=>P("visitedUrl"),children:["Visited URL",j("visitedUrl")]})]}),v.jsx(Je.Row,{children:v.jsx(Je.Cell,{colSpan:A,className:"tw:[&]:p-0",children:v.jsx(ag,{size:"md",borderless:!0,onChange:o})})})]}),footer:g.total>Tp?v.jsx(Je.Row,{children:v.jsx(Je.Cell,{type:"td",colSpan:A,className:"tw:md:sticky-cell-separated tw:bottom-0",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:md:flex-row tw:justify-between tw:items-center tw:gap-4 tw:p-1",children:[v.jsx(Xb,{pagesCount:Math.ceil(g.total/Tp),currentPage:_,onPageChange:x}),v.jsxs("div",{children:["Visits ",v.jsx("b",{children:jn(S+1)})," to"," ",v.jsx("b",{children:jn(Math.min(b,g.total))})," of"," ",v.jsx("b",{children:jn(g.total)})]})]})})}):void 0,children:[!O&&v.jsx(Je.Row,{children:v.jsx(Je.Cell,{colSpan:A,className:"tw:text-center",children:"There are no visits matching current filter"})}),(r=g.visitsGroups[_-1])==null?void 0:r.map((R,U)=>{const V=t.includes(R);return v.jsxs(Je.Row,{className:be("tw:cursor-pointer",V&&["tw:bg-lm-table-highlight tw:hover:[&]:bg-lm-table-highlight","tw:dark:bg-dm-table-highlight tw:dark:hover:[&]:bg-dm-table-highlight"]),onClick:()=>n(V?t.filter(Y=>Y!==R):[...t,R]),children:[v.jsx(Je.Cell,{className:"tw:text-center",children:V&&v.jsx(Ye,{icon:Zu,className:"tw:text-lm-brand tw:dark:text-dm-brand"})}),v.jsx(Je.Cell,{className:"tw:text-center",children:R.potentialBot&&v.jsx(_Oe,{})}),v.jsx(Je.Cell,{children:v.jsx(hb,{date:R.date})}),v.jsx(Je.Cell,{children:R.country}),v.jsx(Je.Cell,{children:R.city}),u?v.jsx(Je.Cell,{children:R.userAgent}):v.jsxs(v.Fragment,{children:[v.jsx(Je.Cell,{children:R.browser}),v.jsx(Je.Cell,{children:R.os})]}),v.jsx(Je.Cell,{children:R.referer}),C&&v.jsx(Je.Cell,{children:R.visitedUrl??""})]},U)})]})})},ml={byTime:{title:"By time",subPath:"by-time",icon:jZ},byContext:{title:"By context",subPath:"by-context",icon:gT},byLocation:{title:"By location",subPath:"by-location",icon:IA},list:{title:"List",subPath:"list",icon:pT},options:{title:"Options",subPath:"options",icon:B9,shouldRender:({deletion:e})=>!!e}};Object.freeze(ml);const PA=({display:e})=>e&&v.jsx("div",{className:"tw:mx-auto tw:w-3/4",children:v.jsx(qt,{children:v.jsxs("div",{className:"tw:flex tw:gap-2",children:[v.jsx(Ye,{icon:AX,className:"tw:mt-1"}),v.jsx("i",{children:"Could not calculate previous period because selected one does not have a strictly defined start date."})]})})}),bg=e=>{const{children:t,visitsInfo:n,getVisits:r,cancelGetVisits:i,deletion:a,exportCsv:o,isOrphanVisits:l=!1}=e,{visits:f,prevVisits:u,loading:h,errorData:m,fallbackInterval:g}=n,[{dateRange:_,visitsFilter:x,loadPrevInterval:b},S]=lH(),C=Xn("visits"),[A,O]=M.useState(),P=M.useCallback(({startDate:te,endDate:ue},J)=>{S({dateRange:{startDate:te??void 0,endDate:ue??void 0}}),O(J)},[S]),[j,R]=M.useState(g??(C==null?void 0:C.defaultInterval)??"last30Days"),[U,V]=M.useState([]),[Y,K]=M.useState(),W=M.useRef(!0),{search:ee}=Sr(),ie=M.useCallback(te=>te?`../${te}${ee}`:ee,[ee]),X=M.useMemo(()=>vb(f),[f]),ne=M.useMemo(()=>u&&vb(u),[u]),{os:H,browsers:I,referrers:D,countries:z,cities:N,citiesForMap:B,visitedUrls:Q}=M.useMemo(()=>XO(X),[X]),G=M.useMemo(()=>XO(ne??[]),[ne]),ae=M.useMemo(()=>Object.fromEntries([["Visits",Object.assign(X,{type:"main"})],ne&&["Previous period",Object.assign(ne,{type:"previous"})],U.length>0&&[Y??"Selected",Object.assign(U,{type:"highlighted"})]].filter(Boolean)),[Y,U,ne,X]),fe=M.useMemo(()=>({...x,excludeBots:x.excludeBots??(C==null?void 0:C.excludeBots),loadPrevInterval:b??(C==null?void 0:C.loadPrevInterval)}),[b,x,C==null?void 0:C.excludeBots,C==null?void 0:C.loadPrevInterval]),ce=M.useMemo(()=>Object.values(B),[B]),ye=M.useRef(void 0),F=M.useCallback(te=>{ye.current=void 0,V(te)},[]),q=M.useCallback((te,ue)=>{const J=`${te}_${ue}`;ye.current===J?(V([]),K(void 0),ye.current=void 0):(V(X.filter(se=>se[te]===ue)),K(ue),ye.current=J)},[X]);return M.useEffect(()=>i,[i]),M.useEffect(()=>{const te=_??$V(j),{loadPrevInterval:ue,...J}=fe,se={doIntervalFallback:W.current,loadPrevInterval:ue};r({dateRange:te,filter:J},se),F([]),W.current=!1},[j,_,r,fe,F]),M.useEffect(()=>{g&&j===((C==null?void 0:C.defaultInterval)??"last30Days")&&R(g)},[j,g,C==null?void 0:C.defaultInterval]),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-4",children:[t,v.jsxs("section",{className:"tw:flex tw:flex-col tw:lg:flex-row-reverse tw:gap-4",children:[v.jsxs("div",{className:"tw:lg:flex-3 tw:flex tw:flex-col tw:md:flex-row tw:gap-x-2 tw:gap-y-4",children:[v.jsx("div",{className:"tw:grow",children:v.jsx(C4,{disabled:h,dateRangeOrInterval:A??_??j,defaultText:"All visits",onDatesChange:P})}),v.jsx(cH,{disabled:h,isOrphanVisits:l,withPrevInterval:!0,selected:fe,onChange:({loadPrevInterval:te,...ue})=>S({visitsFilter:ue,loadPrevInterval:te})})]}),v.jsx("div",{className:"tw:lg:flex-2 tw:xl:flex-3 tw:flex tw:gap-2",children:f.length>0&&v.jsxs(v.Fragment,{children:[v.jsx(xV,{className:"tw:max-lg:w-full",amount:X.length,onClick:()=>o(X)}),v.jsxs(Tn,{variant:"secondary",disabled:U.length===0,className:"tw:max-lg:w-full",onClick:()=>F([]),children:["Clear selection ",U.length>0&&v.jsxs(v.Fragment,{children:["(",jn(U.length),")"]})]})]})})]}),v.jsxs("section",{className:"tw:flex tw:flex-col tw:gap-4",children:[v.jsx(fH,{info:n}),!h&&!m&&v.jsxs(v.Fragment,{children:[v.jsx(Du,{fill:!0,className:"tw:sticky tw:top-(--header-height) tw:z-2",children:Object.values(ml).map(({title:te,icon:ue,subPath:J,shouldRender:se},de)=>!se||se(e)?v.jsxs(Du.Pill,{to:ie(J),replace:!0,children:[v.jsx(Ye,{icon:ue}),v.jsx("span",{className:"tw:ml-2 tw:max-lg:sr-only",children:te})]},de):void 0).filter(Boolean)}),v.jsxs(Sb,{children:[v.jsx(xt,{path:ml.byTime.subPath,element:v.jsxs(Ly,{showFallback:f.length===0,children:[v.jsx("div",{"data-testid":"line-chart-container",children:v.jsx(iH,{visitsGroups:ae,setSelectedVisits:F,onDateRangeChange:P})}),v.jsx(PA,{display:!!fe.loadPrevInterval&&!u})]})}),v.jsx(xt,{path:ml.byContext.subPath,element:v.jsxs(Ly,{showFallback:f.length===0,children:[v.jsxs("div",{className:be("tw:grid tw:grid-cols-1 tw:gap-4",{"tw:lg:grid-cols-2":l,"tw:xl:grid-cols-3":!l}),children:[v.jsx(j7,{title:"Operating systems",stats:H,prevStats:G.os}),v.jsx(j7,{title:"Browsers",stats:I,prevStats:G.browsers}),v.jsx(by,{title:"Referrers",withPagination:!1,stats:D,prevStats:G.referrers,highlightedStats:wy(U,"referer"),highlightedLabel:Y,sortingItems:{name:"Referrer name",amount:"Visits amount"},onClick:te=>q("referer",te)}),l&&v.jsx(by,{title:"Visited URLs",stats:Q,prevStats:G.visitedUrls,highlightedStats:wy(U,"visitedUrl"),highlightedLabel:Y,sortingItems:{visitedUrl:"Visited URL",amount:"Visits amount"},onClick:te=>q("visitedUrl",te)})]}),v.jsx(PA,{display:!!fe.loadPrevInterval&&!u})]})}),v.jsx(xt,{path:ml.byLocation.subPath,element:v.jsxs(Ly,{showFallback:f.length===0,children:[v.jsxs("div",{className:"tw:grid tw:grid-cols-1 tw:lg:grid-cols-2 tw:gap-4",children:[v.jsx(by,{title:"Countries",stats:z,prevStats:G.countries,highlightedStats:wy(U,"country"),highlightedLabel:Y,sortingItems:{name:"Country name",amount:"Visits amount"},onClick:te=>q("country",te)}),v.jsx(by,{title:"Cities",stats:N,prevStats:G.cities,highlightedStats:wy(U,"city"),highlightedLabel:Y,extraHeaderContent:te=>ce.length>0&&v.jsx(rOe,{modalTitle:"Cities",locations:ce,activeCities:te}),sortingItems:{name:"City name",amount:"Visits amount"},onClick:te=>q("city",te)})]}),v.jsx(PA,{display:!!fe.loadPrevInterval&&!u})]})}),v.jsx(xt,{path:ml.list.subPath,element:v.jsx(xOe,{visits:X,selectedVisits:U,setSelectedVisits:F})}),a&&v.jsx(xt,{path:ml.options.subPath,element:v.jsx(aOe,{...a})}),v.jsx(xt,{path:"*",element:v.jsx(aT,{replace:!0,to:ie(ml.byTime.subPath)})})]})]})]})]})},pH=Ma(({getDomainVisits:e,domainVisits:t,cancelGetDomainVisits:n})=>{const{ReportExporter:r}=Pn(pH),{domain:i=""}=Td(),[a,o=a]=i.split("_"),l=M.useCallback((u,h)=>e({domain:o,options:h,params:u}),[o,e]),f=M.useCallback(u=>r.exportVisits(`domain_${a}_visits.csv`,u),[a,r]);return v.jsx(bg,{getVisits:l,cancelGetVisits:n,visitsInfo:t,exportCsv:f,children:v.jsx(yg,{visits:t.visits,title:`"${a}" visits`})})},()=>[Wr.visits]),SOe=Rn(pH,["ReportExporter"]),mH=Ma(({getNonOrphanVisits:e,nonOrphanVisits:t,cancelGetNonOrphanVisits:n})=>{const{ReportExporter:r}=Pn(mH),i=M.useCallback(o=>r.exportVisits("non_orphan_visits.csv",o),[r]),a=M.useCallback((o,l)=>e({options:l,params:o}),[e]);return v.jsx(bg,{getVisits:a,cancelGetVisits:n,visitsInfo:t,exportCsv:i,children:v.jsx(yg,{title:"Non-orphan visits",visits:t.visits})})},()=>[Wr.visits]),COe=Rn(mH,["ReportExporter"]),gH=Ma(({getOrphanVisits:e,orphanVisits:t,cancelGetOrphanVisits:n,deleteOrphanVisits:r,orphanVisitsDeletion:i})=>{const a=fo("orphanVisitsDeletion"),{ReportExporter:o}=Pn(gH),l=M.useCallback(h=>o.exportVisits("orphan_visits.csv",h),[o]),f=M.useCallback((h,m)=>{var g;return e({options:m,params:h,orphanVisitsType:(g=h.filter)==null?void 0:g.orphanVisitsType})},[e]),u=M.useMemo(()=>a?{deleteVisits:r,visitsDeletion:i}:void 0,[r,i,a]);return v.jsx(bg,{getVisits:f,cancelGetVisits:n,visitsInfo:t,exportCsv:l,deletion:u,isOrphanVisits:!0,children:v.jsx(yg,{title:"Orphan visits",visits:t.visits})})},()=>[Wr.orphanVisits]),AOe=Rn(gH,["ReportExporter"]),k7=5e3,EOe=2,OOe=4,TOe=({currentPage:e,pagesCount:t})=>e>=t,jOe=(e,t)=>t*100/e,vH=({visitsLoader:e,shouldCancel:t,progressChanged:n,batchSize:r})=>{const i=async(o,l)=>Promise.all(l.map(async f=>e({...o,page:f,itemsPerPage:k7}).then(({data:u})=>u))).then(f=>f.flat()),a=async(o,l,f=0)=>{if(t())return[];const u=await i(o,l[f]);return n(jOe(l.length,f+1)),f<l.length-1?u.concat(await a(o,l,f+1)):u};return async o=>{const{pagination:l,data:f}=await e({...o,page:1,itemsPerPage:k7});if(TOe(l))return f;const u=xB(EOe,l.pagesCount+1),h=Mf(u,r);return l.pagesCount-1>r&&n(0),f.concat(await a(o,h))}},wg=(e,t)=>async n=>e?t({page:1,itemsPerPage:1,excludeBots:n}).then(({data:r})=>r[0]):Promise.resolve(void 0),_g=({typePrefix:e,createLoaders:t,shouldCancel:n})=>{const r=Hr(`${e}/progressChanged`),i=Hr(`${e}/fallbackToInterval`),a=Zn(e,async(o,{getState:l,dispatch:f})=>{var u;const{params:h,options:m}=o,{visitsLoader:g,lastVisitLoader:_}=t(o),x=VAe(h.dateRange),b=ZO(h),S=m.loadPrevInterval&&JEe(h)?ZO(eOe(h)):void 0,C=OOe/(S?2:1),A=S?{main:0,prev:0}:{main:0},O=(V,Y)=>{A[V]=Y;const K=Object.values(A),W=K.reduce((ee,ie)=>ee+ie,0);f(r(W/K.length))},P=vH({visitsLoader:g,shouldCancel:()=>n(l),progressChanged:V=>O("main",V),batchSize:C}),[j,R,U]=await Promise.all([P(b),_((u=h.filter)==null?void 0:u.excludeBots),S?P(S).then(V=>V.map(Y=>{if(x===void 0)return Y;const{date:K,...W}=Y,ee=e3(Si(K),x);return{...W,date:ql(ee)}})):Promise.resolve(void 0)]);return!j.length&&R&&f(i(FAe(R.date))),{...o,visits:j,prevVisits:U}});return Object.assign(a,{progressChanged:r,fallbackToInterval:i})},xg=({name:e,asyncThunkCreator:t,initialState:n,filterCreatedVisits:r,extraReducers:i})=>{const{pending:a,rejected:o,fulfilled:l,progressChanged:f,fallbackToInterval:u}=t,{reducer:h,actions:m}=Dn({name:e,initialState:n,reducers:{cancelGetVisits:_=>({..._,cancelLoad:!0})},extraReducers:_=>{_.addCase(a,()=>({...n,loading:!0})),_.addCase(o,(x,{error:b})=>({...n,errorData:Di(b)??null})),_.addCase(l,(x,{payload:b})=>({...x,...b,loading:!1,progress:null,errorData:null})),_.addCase(f,(x,{payload:b})=>({...x,progress:b})),_.addCase(u,(x,{payload:b})=>({...x,fallbackInterval:b})),_.addCase(Yd,(x,{payload:b})=>{const{visits:S}=x,C=r(x,b.createdVisits).map(({visit:A})=>A);return C.length?{...x,visits:[...C,...S]}:x}),i==null||i(_)}}),{cancelGetVisits:g}=m;return{reducer:h,cancelGetVisits:g}},yH="shlink/domainVisits",POe={visits:[],domain:"",loading:!1,cancelLoad:!1,errorData:null,progress:null},ROe=e=>_g({typePrefix:`${yH}/getDomainVisits`,createLoaders:({domain:t,options:n})=>{const r=e(),{doIntervalFallback:i=!1}=n,a=l=>r.getDomainVisits(t,l),o=wg(i,l=>r.getDomainVisits(t,l));return{visitsLoader:a,lastVisitLoader:o}},shouldCancel:t=>t().domainVisits.cancelLoad}),MOe=e=>xg({name:yH,initialState:POe,asyncThunkCreator:e,filterCreatedVisits:({domain:t,params:n},r)=>oH(r,t,n==null?void 0:n.dateRange)}),bH="shlink/orphanVisits",NOe={visits:[],loading:!1,cancelLoad:!1,errorData:null,progress:null},LOe=e=>_g({typePrefix:`${bH}/getNonOrphanVisits`,createLoaders:({options:t})=>{const n=e(),{doIntervalFallback:r=!1}=t,i=async o=>n.getNonOrphanVisits(o),a=wg(r,o=>n.getNonOrphanVisits(o));return{visitsLoader:i,lastVisitLoader:a}},shouldCancel:t=>t().orphanVisits.cancelLoad}),kOe=e=>xg({name:bH,initialState:NOe,asyncThunkCreator:e,filterCreatedVisits:({params:t},n)=>{const{startDate:r,endDate:i}=(t==null?void 0:t.dateRange)??{};return n.filter(({visit:a})=>vg(a.date,r,i))}}),wH="shlink/orphanVisits",DOe={visits:[],loading:!1,cancelLoad:!1,errorData:null,progress:null},IOe=(e,t)=>!t||t===e.type,$Oe=({data:e,...t},n)=>{const r=e.filter(i=>M4(i)&&IOe(i,n));return{...t,data:r}},BOe=e=>_g({typePrefix:`${wH}/getOrphanVisits`,createLoaders:({orphanVisitsType:t,options:n})=>{const r=e(),{doIntervalFallback:i=!1}=n,a=async l=>r.getOrphanVisits({...l,type:t}).then(f=>$Oe(f,t)),o=wg(i,l=>r.getOrphanVisits(l));return{visitsLoader:a,lastVisitLoader:o}},shouldCancel:t=>t().orphanVisits.cancelLoad}),UOe=(e,t)=>xg({name:wH,initialState:DOe,asyncThunkCreator:e,extraReducers:n=>{n.addCase(t.fulfilled,r=>({...r,visits:[]}))},filterCreatedVisits:({params:n},r)=>{const{startDate:i,endDate:a}=(n==null?void 0:n.dateRange)??{};return r.filter(({visit:o,shortUrl:l})=>!l&&vg(o.date,i,a))}}),_H="shlink/orphanVisitsDeletion",D7={deletedVisits:0,deleting:!1,error:!1},zOe=e=>Zn(`${_H}/deleteOrphanVisits`,()=>e().deleteOrphanVisits()),FOe=e=>Dn({name:_H,initialState:D7,reducers:{},extraReducers:t=>{t.addCase(e.pending,n=>({...n,deleting:!0,error:!1})),t.addCase(e.rejected,(n,{error:r})=>({...n,deleting:!1,error:!0,errorData:Di(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>{const{deletedVisits:i}=r;return{...D7,deletedVisits:i}})}}),xH="shlink/shortUrlVisits",qOe={visits:[],shortCode:"",loading:!1,errorData:null,cancelLoad:!1,progress:null},VOe=e=>_g({typePrefix:`${xH}/getShortUrlVisits`,createLoaders:({shortCode:t,domain:n,options:r})=>{const i=e(),{doIntervalFallback:a=!1}=r,o=f=>i.getShortUrlVisits({shortCode:t,domain:n},f),l=wg(a,f=>i.getShortUrlVisits({shortCode:t,domain:n},f));return{visitsLoader:o,lastVisitLoader:l}},shouldCancel:t=>t().shortUrlVisits.cancelLoad}),HOe=(e,t)=>xg({name:xH,initialState:qOe,asyncThunkCreator:e,extraReducers:n=>{n.addCase(t.fulfilled,(r,{payload:i})=>r.shortCode===i.shortCode&&r.domain===i.domain?{...r,visits:[]}:r)},filterCreatedVisits:({shortCode:n,domain:r,params:i},a)=>aH(a,{shortCode:n,domain:r},i==null?void 0:i.dateRange)}),SH="shlink/shortUrlVisitsDeletion",I7={shortCode:"",deletedVisits:0,deleting:!1,error:!1},GOe=e=>Zn(`${SH}/deleteShortUrlVisits`,async({shortCode:t,domain:n})=>({...await e().deleteShortUrlVisits({shortCode:t,domain:n}),shortCode:t,domain:n})),WOe=e=>Dn({name:SH,initialState:I7,reducers:{},extraReducers:t=>{t.addCase(e.pending,n=>({...n,deleting:!0,error:!1})),t.addCase(e.rejected,(n,{error:r})=>({...n,deleting:!1,error:!0,errorData:Di(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>{const{shortCode:i,domain:a,deletedVisits:o}=r;return{...I7,shortCode:i,domain:a,deletedVisits:o}})}}),CH="shlink/tagVisits",YOe={visits:[],tag:"",loading:!1,cancelLoad:!1,errorData:null,progress:null},KOe=e=>_g({typePrefix:`${CH}/getTagVisits`,createLoaders:({tag:t,options:n})=>{const r=e(),{doIntervalFallback:i=!1}=n,a=l=>r.getTagVisits(t,l),o=wg(i,async l=>r.getTagVisits(t,l));return{visitsLoader:a,lastVisitLoader:o}},shouldCancel:t=>t().tagVisits.cancelLoad}),ZOe=e=>xg({name:CH,initialState:YOe,asyncThunkCreator:e,filterCreatedVisits:({tag:t,params:n},r)=>sH(r,t,n==null?void 0:n.dateRange)}),AH="shlink/visitsOverview",xy={nonOrphanVisits:{total:0},orphanVisits:{total:0},loading:!1,error:!1},$7=e=>e.filter(({visit:t})=>t.potentialBot).length,XOe=e=>Zn(`${AH}/loadVisitsOverview`,()=>e().getVisitsOverview().then(({nonOrphanVisits:t,visitsCount:n=0,orphanVisits:r,orphanVisitsCount:i=0})=>({nonOrphanVisits:{total:(t==null?void 0:t.total)??n,nonBots:t==null?void 0:t.nonBots,bots:t==null?void 0:t.bots},orphanVisits:{total:(r==null?void 0:r.total)??i,nonBots:r==null?void 0:r.nonBots,bots:r==null?void 0:r.bots}}))),QOe=e=>Dn({name:AH,initialState:xy,reducers:{},extraReducers:t=>{t.addCase(e.pending,()=>({...xy,loading:!0})),t.addCase(e.rejected,()=>({...xy,error:!0})),t.addCase(e.fulfilled,(n,{payload:r})=>({...xy,...r})),t.addCase(Yd,({nonOrphanVisits:n,orphanVisits:r,...i},{payload:a})=>{const{nonOrphanVisits:o,orphanVisits:l}=XEe(a.createdVisits),f=o.length,u=$7(o),h=f-u,m=l.length,g=$7(l),_=m-g;return{...i,nonOrphanVisits:{total:n.total+f,bots:n.bots&&n.bots+u,nonBots:n.nonBots&&n.nonBots+h},orphanVisits:{total:r.total+m,bots:r.bots&&r.bots+g,nonBots:r.nonBots&&r.nonBots+_}}})}}),JOe=({shortUrl:e})=>{const{anchor:t,tooltip:n}=Hl({placement:"bottom"});return e?v.jsxs("span",{children:[v.jsx("b",{className:"tw:cursor-default",...t,children:v.jsx(hb,{date:e.dateCreated,relative:!0})}),v.jsx(Gl,{...n,children:v.jsx(hb,{date:e.dateCreated})})]}):v.jsx("small",{children:"Loading..."})},eTe=({shortUrl:e,loading:t,shortUrlVisits:n})=>{const{visits:r}=n,i=(e==null?void 0:e.shortUrl)??"",a=(e==null?void 0:e.longUrl)??"",o=e==null?void 0:e.title;return v.jsxs(yg,{title:v.jsxs(v.Fragment,{children:["Visits for ",v.jsx(Oi,{href:i})]}),visits:r,shortUrl:e,children:[v.jsx("hr",{}),v.jsxs("div",{children:["Created: ",v.jsx(JOe,{shortUrl:e})]}),v.jsxs("div",{"data-testid":"long-url-container",children:[`${o?"Title":"Long URL"}: `,t&&v.jsx("small",{children:"Loading..."}),!t&&v.jsx(Oi,{href:a,children:o??a})]})]})},EH=Ma(({shortUrlVisits:e,shortUrlVisitsDeletion:t,shortUrlsDetails:n,getShortUrlVisits:r,getShortUrlsDetails:i,deleteShortUrlVisits:a,cancelGetShortUrlVisits:o})=>{const l=fo("shortUrlVisitsDeletion"),{ReportExporter:f}=Pn(EH),u=b4(),h=M.useMemo(()=>{var x;return(x=n.shortUrls)==null?void 0:x.get(u)},[u,n.shortUrls]),m=M.useCallback((x,b)=>r({...u,options:b,params:x}),[r,u]),g=M.useCallback(x=>f.exportVisits(`short-url_${h==null?void 0:h.shortUrl.replace(/https?:\/\//g,"")}_visits.csv`,x),[f,h==null?void 0:h.shortUrl]),_=M.useMemo(()=>l?{deleteVisits:()=>a(u),visitsDeletion:t}:void 0,[a,u,t,l]);return M.useEffect(()=>{i([u])},[u,i]),v.jsx(bg,{getVisits:m,cancelGetVisits:o,visitsInfo:e,exportCsv:g,deletion:_,children:v.jsx(eTe,{shortUrl:h,loading:n.loading,shortUrlVisits:e})})},e=>e.shortCode?[Wr.shortUrlVisits(m4(e.shortCode))]:[]),tTe=Rn(EH,["ReportExporter"]),nTe=({tagVisits:e,colorGenerator:t})=>{const{visits:n,tag:r}=e;return v.jsx(yg,{title:v.jsxs("span",{className:"tw:flex tw:items-center tw:justify-center",children:[v.jsx("span",{className:"tw:mr-2",children:"Visits for"}),v.jsx(S4,{text:r,colorGenerator:t})]}),visits:n})},OH=Ma(({getTagVisits:e,tagVisits:t,cancelGetTagVisits:n})=>{const{ColorGenerator:r,ReportExporter:i}=Pn(OH),{tag:a=""}=Td(),o=M.useCallback((f,u)=>e({tag:a,params:f,options:u}),[e,a]),l=M.useCallback(f=>i.exportVisits(`tag_${a}_visits.csv`,f),[i,a]);return v.jsx(bg,{getVisits:o,cancelGetVisits:n,visitsInfo:t,exportCsv:l,children:v.jsx(nTe,{tagVisits:t,colorGenerator:r})})},()=>[Wr.visits]),rTe=Rn(OH,["ColorGenerator","ReportExporter"]),N4=({title:e,colors:t,getVisitsForComparison:n,visitsComparisonInfo:r,cancelGetVisitsComparison:i})=>{const{loading:a,visitsGroups:o}=r,l=Xn("visits"),f=M.useMemo(()=>Object.keys(o).reduce((A,O,P)=>(A[O]=Object.assign(vb(o[O]),{color:(t==null?void 0:t[O])??nH(P)}),A),{}),[t,o]),u=M.useMemo(()=>Object.values(o).every(A=>A.length===0),[o]),[{dateRange:h,visitsFilter:m},g]=lH(),[_,x]=M.useState(),b=M.useCallback(({startDate:A,endDate:O},P)=>{g({dateRange:{startDate:A??void 0,endDate:O??void 0}}),x(P)},[g]),[S]=M.useState(()=>h??(l==null?void 0:l.defaultInterval)??"last30Days"),C=M.useMemo(()=>({...m,excludeBots:m.excludeBots??(l==null?void 0:l.excludeBots)}),[m,l==null?void 0:l.excludeBots]);return M.useEffect(()=>{const A=h??$V(S);return n({params:{dateRange:A,filter:C}}),i},[i,h,n,S,C]),v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-4",children:[v.jsxs(qt,{bodyClassName:"tw:flex tw:items-center",children:[v.jsx(z1,{}),v.jsx("h3",{className:"tw:grow tw:text-center",children:e})]}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:lg:flex-row-reverse tw:gap-4",children:[v.jsxs("div",{className:"tw:lg:flex-3 tw:flex tw:flex-col tw:md:flex-row tw:gap-x-2 tw:gap-y-4",children:[v.jsx("div",{className:"tw:grow",children:v.jsx(C4,{disabled:a,defaultText:"All visits",dateRangeOrInterval:_??h??S,onDatesChange:b})}),v.jsx(cH,{disabled:a,selected:C,onChange:({orphanVisitsType:A,excludeBots:O})=>g({visitsFilter:{orphanVisitsType:A,excludeBots:O}})})]}),v.jsx("div",{className:"tw:hidden tw:lg:block tw:lg:flex-2 tw:xl:flex-3"})]}),v.jsx(fH,{info:r}),!a&&v.jsx(Ly,{showFallback:u,children:v.jsx(iH,{visitsGroups:f,onDateRangeChange:b})})]})},iTe=Ma(({getDomainVisitsForComparison:e,domainVisitsComparison:t,cancelGetDomainVisitsComparison:n})=>{const r=O4("domains"),i=M.useCallback(a=>e({...a,domains:r}),[r,e]);return v.jsx(N4,{title:`Comparing "${r.join('", "')}"`,getVisitsForComparison:i,visitsComparisonInfo:t,cancelGetVisitsComparison:n})},()=>[Wr.visits]),aTe=({visitsLoaders:e,shouldCancel:t,progressChanged:n})=>{const r=Object.keys(e),i=Math.max(1,Math.round(4/r.length)),a=Object.fromEntries(r.map(f=>[f,0])),o=(f,u)=>{a[f]=u;const h=Object.values(a),m=h.reduce((g,_)=>g+_,0);n(m/h.length)},l=Object.entries(e).map(([f,u])=>[f,vH({visitsLoader:u,batchSize:i,shouldCancel:t,progressChanged:h=>o(f,h)})]);return async f=>{const u=await Promise.all(l.map(async([h,m])=>{const g=await m(f);return[h,g]}));return Object.fromEntries(u)}},L4=({typePrefix:e,createLoaders:t,shouldCancel:n})=>{const r=Hr(`${e}/progressChanged`),i=Zn(e,async(a,{getState:o,dispatch:l})=>{const f=t(a),u=await aTe({visitsLoaders:f,shouldCancel:()=>n(o),progressChanged:h=>l(r(h))})(ZO(a.params));return{...a,visitsGroups:u}});return Object.assign(i,{progressChanged:r})},k4=({name:e,asyncThunkCreator:t,initialState:n,filterCreatedVisitsForGroup:r})=>{const{pending:i,rejected:a,fulfilled:o,progressChanged:l}=t,{reducer:f,actions:u}=Dn({name:e,initialState:n,reducers:{cancelGetVisits:m=>({...m,cancelLoad:!0})},extraReducers:m=>{m.addCase(i,()=>({...n,loading:!0})),m.addCase(a,(g,{error:_})=>({...n,errorData:Di(_)??null})),m.addCase(o,(g,{payload:_})=>({...g,..._,loading:!1,progress:null,errorData:null})),m.addCase(l,(g,{payload:_})=>({...g,progress:_})),m.addCase(Yd,(g,{payload:_})=>{const{visitsGroups:x,...b}=g,S=Object.keys(x).map(A=>{const O=r({...b,groupKey:A},_.createdVisits).map(({visit:P})=>P);return[A,[...O,...x[A]]]}),C=Object.fromEntries(S);return{...b,visitsGroups:C}})}}),{cancelGetVisits:h}=u;return{reducer:f,cancelGetVisits:h}},TH="shlink/domainVisitsComparison",oTe={visitsGroups:{},loading:!1,cancelLoad:!1,errorData:null,progress:null},sTe=e=>L4({typePrefix:`${TH}/getDomainVisitsForComparison`,createLoaders:({domains:t})=>{const n=e(),r=t.map(i=>[i,a=>n.getDomainVisits(i,a)]);return Object.fromEntries(r)},shouldCancel:t=>t().domainVisitsComparison.cancelLoad}),lTe=e=>k4({name:TH,initialState:oTe,asyncThunkCreator:e,filterCreatedVisitsForGroup:({groupKey:t,params:n},r)=>oH(r,t,n==null?void 0:n.dateRange)}),jH="shlink/shortUrlVisitsComparison",uTe={visitsGroups:{},loading:!1,cancelLoad:!1,errorData:null,progress:null},cTe=e=>L4({typePrefix:`${jH}/getShortUrlVisitsForComparison`,createLoaders:({shortUrls:t})=>{const n=e(),r=t.map(i=>[g4(i),a=>n.getShortUrlVisits(i,a)]);return Object.fromEntries(r)},shouldCancel:t=>t().shortUrlVisitsComparison.cancelLoad}),fTe=e=>k4({name:jH,initialState:uTe,asyncThunkCreator:e,filterCreatedVisitsForGroup:({groupKey:t,params:n},r)=>aH(r,eV(t),n==null?void 0:n.dateRange)}),PH="shlink/tagVisitsComparison",dTe={visitsGroups:{},loading:!1,cancelLoad:!1,errorData:null,progress:null},hTe=e=>L4({typePrefix:`${PH}/getTagVisitsForComparison`,createLoaders:({tags:t})=>{const n=e(),r=t.map(i=>[i,a=>n.getTagVisits(i,a)]);return Object.fromEntries(r)},shouldCancel:t=>t().tagVisitsComparison.cancelLoad}),pTe=e=>k4({name:PH,initialState:dTe,asyncThunkCreator:e,filterCreatedVisitsForGroup:({groupKey:t,params:n},r)=>sH(r,t,n==null?void 0:n.dateRange)}),mTe=Ma(({getShortUrlVisitsForComparison:e,shortUrlVisitsComparison:t,cancelGetShortUrlVisitsComparison:n,shortUrlsDetails:r,getShortUrlsDetails:i})=>{const a=O4("short-urls"),o=M.useMemo(()=>a.map(eV),[a]),l=M.useCallback(h=>e({...h,shortUrls:o}),[e,o]),f=M.useMemo(()=>{var h;return[...((h=r.shortUrls)==null?void 0:h.values())??[]]},[r.shortUrls]),u=M.useMemo(()=>{const{visitsGroups:h,loading:m,...g}=t,_=f.reduce((x,b)=>(x[b.shortUrl]=h[g4(b)]??[],x),{});return{...g,visitsGroups:_,loading:m||r.loading}},[t,r.loading,f]);return M.useEffect(()=>{o.length>0&&i(o)},[i,o]),v.jsx(N4,{title:v.jsx("span",{"data-testid":"title",children:r.loading?"Loading...":`Comparing ${f.length} short URLs`}),getVisitsForComparison:l,visitsComparisonInfo:u,cancelGetVisitsComparison:n})},()=>[Wr.visits]),RH=Ma(({getTagVisitsForComparison:e,tagVisitsComparison:t,cancelGetTagVisitsComparison:n})=>{const{ColorGenerator:r}=Pn(RH),i=O4("tags"),a=M.useCallback(f=>e({...f,tags:i}),[e,i]),{visitsGroups:o}=t,l=M.useMemo(()=>Object.keys(o).reduce((f,u)=>(f[u]=r.getColorForKey(u),f),{}),[r,o]);return v.jsx(N4,{title:v.jsxs(v.Fragment,{children:["Comparing ",i.map(f=>v.jsx(S4,{colorGenerator:r,text:f},f))]}),getVisitsForComparison:a,visitsComparisonInfo:t,cancelGetVisitsComparison:n,colors:l})},()=>[Wr.visits]),gTe=Rn(RH,["ColorGenerator"]),vTe=(e,t)=>{const n=(r,i)=>t([...r,"mercureInfo"],[...i,"createNewVisits","loadMercureInfo"]);e.serviceFactory("MapModal",()=>uH),e.factory("ShortUrlVisits",tTe),e.decorator("ShortUrlVisits",t(["shortUrlVisits","shortUrlVisitsDeletion","shortUrlsDetails","mercureInfo"],["getShortUrlVisits","deleteShortUrlVisits","getShortUrlsDetails","cancelGetShortUrlVisits","createNewVisits","loadMercureInfo"])),e.factory("TagVisits",rTe),e.decorator("TagVisits",n(["tagVisits"],["getTagVisits","cancelGetTagVisits"])),e.factory("TagVisitsComparison",gTe),e.decorator("TagVisitsComparison",n(["tagVisitsComparison"],["getTagVisitsForComparison","cancelGetTagVisitsForComparison"])),e.serviceFactory("DomainVisitsComparison",()=>iTe),e.decorator("DomainVisitsComparison",n(["domainVisitsComparison"],["getDomainVisitsForComparison","cancelGetDomainVisitsForComparison"])),e.serviceFactory("ShortUrlVisitsComparison",()=>mTe),e.decorator("ShortUrlVisitsComparison",n(["shortUrlVisitsComparison","shortUrlsDetails"],["getShortUrlVisitsForComparison","cancelGetShortUrlVisitsForComparison","getShortUrlsDetails"])),e.factory("DomainVisits",SOe),e.decorator("DomainVisits",n(["domainVisits"],["getDomainVisits","cancelGetDomainVisits"])),e.factory("OrphanVisits",AOe),e.decorator("OrphanVisits",n(["orphanVisits","orphanVisitsDeletion"],["getOrphanVisits","cancelGetOrphanVisits","deleteOrphanVisits"])),e.factory("NonOrphanVisits",COe),e.decorator("NonOrphanVisits",n(["nonOrphanVisits"],["getNonOrphanVisits","cancelGetNonOrphanVisits"])),e.serviceFactory("VisitsParser",()=>gOe),e.serviceFactory("getShortUrlVisits",VOe,"apiClientFactory"),e.serviceFactory("cancelGetShortUrlVisits",r=>r.cancelGetVisits,"shortUrlVisitsReducerCreator"),e.serviceFactory("getShortUrlVisitsForComparison",cTe,"apiClientFactory"),e.serviceFactory("cancelGetShortUrlVisitsForComparison",r=>r.cancelGetVisits,"shortUrlVisitsComparisonReducerCreator"),e.serviceFactory("deleteShortUrlVisits",GOe,"apiClientFactory"),e.serviceFactory("getTagVisits",KOe,"apiClientFactory"),e.serviceFactory("cancelGetTagVisits",r=>r.cancelGetVisits,"tagVisitsReducerCreator"),e.serviceFactory("getTagVisitsForComparison",hTe,"apiClientFactory"),e.serviceFactory("cancelGetTagVisitsForComparison",r=>r.cancelGetVisits,"tagVisitsComparisonReducerCreator"),e.serviceFactory("getDomainVisits",ROe,"apiClientFactory"),e.serviceFactory("cancelGetDomainVisits",r=>r.cancelGetVisits,"domainVisitsReducerCreator"),e.serviceFactory("getDomainVisitsForComparison",sTe,"apiClientFactory"),e.serviceFactory("cancelGetDomainVisitsForComparison",r=>r.cancelGetVisits,"domainVisitsComparisonReducerCreator"),e.serviceFactory("getOrphanVisits",BOe,"apiClientFactory"),e.serviceFactory("cancelGetOrphanVisits",r=>r.cancelGetVisits,"orphanVisitsReducerCreator"),e.serviceFactory("deleteOrphanVisits",zOe,"apiClientFactory"),e.serviceFactory("getNonOrphanVisits",LOe,"apiClientFactory"),e.serviceFactory("cancelGetNonOrphanVisits",r=>r.cancelGetVisits,"nonOrphanVisitsReducerCreator"),e.serviceFactory("createNewVisits",()=>Yd),e.serviceFactory("loadVisitsOverview",XOe,"apiClientFactory"),e.serviceFactory("visitsOverviewReducerCreator",QOe,"loadVisitsOverview"),e.serviceFactory("visitsOverviewReducer",r=>r.reducer,"visitsOverviewReducerCreator"),e.serviceFactory("domainVisitsReducerCreator",MOe,"getDomainVisits"),e.serviceFactory("domainVisitsReducer",r=>r.reducer,"domainVisitsReducerCreator"),e.serviceFactory("nonOrphanVisitsReducerCreator",kOe,"getNonOrphanVisits"),e.serviceFactory("nonOrphanVisitsReducer",r=>r.reducer,"nonOrphanVisitsReducerCreator"),e.serviceFactory("orphanVisitsReducerCreator",UOe,"getOrphanVisits","deleteOrphanVisits"),e.serviceFactory("orphanVisitsReducer",r=>r.reducer,"orphanVisitsReducerCreator"),e.serviceFactory("orphanVisitsDeletionReducerCreator",FOe,"deleteOrphanVisits"),e.serviceFactory("orphanVisitsDeletionReducer",r=>r.reducer,"orphanVisitsDeletionReducerCreator"),e.serviceFactory("shortUrlVisitsReducerCreator",HOe,"getShortUrlVisits","deleteShortUrlVisits"),e.serviceFactory("shortUrlVisitsReducer",r=>r.reducer,"shortUrlVisitsReducerCreator"),e.serviceFactory("shortUrlVisitsDeletionReducerCreator",WOe,"deleteShortUrlVisits"),e.serviceFactory("shortUrlVisitsDeletionReducer",r=>r.reducer,"shortUrlVisitsDeletionReducerCreator"),e.serviceFactory("tagVisitsReducerCreator",ZOe,"getTagVisits"),e.serviceFactory("tagVisitsReducer",r=>r.reducer,"tagVisitsReducerCreator"),e.serviceFactory("tagVisitsComparisonReducerCreator",pTe,"getTagVisitsForComparison"),e.serviceFactory("tagVisitsComparisonReducer",r=>r.reducer,"tagVisitsComparisonReducerCreator"),e.serviceFactory("domainVisitsComparisonReducerCreator",lTe,"getDomainVisitsForComparison"),e.serviceFactory("domainVisitsComparisonReducer",r=>r.reducer,"domainVisitsComparisonReducerCreator"),e.serviceFactory("shortUrlVisitsComparisonReducerCreator",fTe,"getShortUrlVisitsForComparison"),e.serviceFactory("shortUrlVisitsComparisonReducer",r=>r.reducer,"shortUrlVisitsComparisonReducerCreator")},mp=({children:e,to:t,active:n,...r})=>v.jsx(Ab,{...r,className:({isActive:i})=>be("tw:flex tw:items-center tw:gap-2","tw:no-underline tw:rounded-none tw:px-5 tw:py-2.5",{"tw:text-white tw:bg-lm-main tw:dark:bg-dm-main":i||n,"tw:highlight:bg-lm-secondary tw:highlight:dark:bg-dm-secondary":!i&&!n}),to:t,children:e}),yTe=({routePrefix:e,showOnMobile:t=!1})=>{const{pathname:n}=Sr(),r=i=>`${e}${i}`;return v.jsx("aside",{className:be("tw:w-(--aside-menu-width) tw:bg-lm-primary tw:dark:bg-dm-primary","tw:pt-[15px] tw:md:pt-[30px] tw:pb-[10px]","tw:fixed! tw:bottom-0 tw:top-(--header-height) tw:z-890 tw:transition-[left] tw:duration-300","tw:shadow-aside-menu-mobile tw:md:shadow-aside-menu",{"tw:left-0":t,"tw:max-md:left-[calc(-1*(var(--aside-menu-width)+35px))]":!t}),children:v.jsxs("nav",{className:"tw:flex tw:flex-col tw:h-full",children:[v.jsxs(mp,{to:r("/overview"),children:[v.jsx(Ye,{fixedWidth:!0,icon:aX}),"Overview"]}),v.jsxs(mp,{to:r("/list-short-urls/1"),active:n.match("/list-short-urls")!==null,children:[v.jsx(Ye,{fixedWidth:!0,icon:pT}),"List short URLs"]}),v.jsxs(mp,{to:r("/create-short-url"),children:[v.jsx(Ye,{fixedWidth:!0,icon:fX,flip:"horizontal"}),"Create short URL"]}),v.jsxs(mp,{to:r("/manage-tags"),children:[v.jsx(Ye,{fixedWidth:!0,icon:N9}),"Manage tags"]}),v.jsxs(mp,{to:r("/manage-domains"),children:[v.jsx(Ye,{fixedWidth:!0,icon:BZ}),"Manage domains"]})]})})},MH=({createNotFound:e})=>{const{TagsList:t,ShortUrlsList:n,CreateShortUrl:r,ShortUrlVisits:i,TagVisits:a,DomainVisits:o,OrphanVisits:l,NonOrphanVisits:f,Overview:u,EditShortUrl:h,ManageDomains:m,TagVisitsComparison:g,DomainVisitsComparison:_,ShortUrlVisitsComparison:x,ShortUrlRedirectRules:b}=Pn(MH),S=Sr(),C=vs(),{flag:A,toggle:O,setToTrue:P,setToFalse:j}=wn(!1,!0);M.useEffect(()=>j(),[S,j]);const R=pEe(P,j),U=fo("shortUrlRedirectRules");return v.jsxs(v.Fragment,{children:[v.jsx(Ad,{"aria-label":"Toggle sidebar",className:be("tw:fixed tw:top-4 tw:left-3 tw:z-1035","tw:md:hidden tw:transition-colors",{"tw:text-white/50":!A,"tw:text-white":A}),onClick:O,children:v.jsx(Ye,{icon:NZ,size:"xl"})}),v.jsx("div",{...R,className:"tw:h-full",children:v.jsxs("div",{className:"tw:h-full",children:[v.jsx(yTe,{routePrefix:C,showOnMobile:A}),v.jsx("div",{className:"tw:min-h-full tw:pt-[20px] tw:md:pt-[30px] tw:md:pl-(--aside-menu-width)",onPointerDown:j,children:v.jsx("div",{className:"tw:container tw:mx-auto tw:px-3",children:v.jsxs(Sb,{children:[v.jsx(xt,{index:!0,element:v.jsx(aT,{replace:!0,to:"overview"})}),v.jsx(xt,{path:"/overview",element:v.jsx(u,{})}),v.jsx(xt,{path:"/list-short-urls/:page",element:v.jsx(n,{})}),v.jsx(xt,{path:"/create-short-url",element:v.jsx(r,{})}),v.jsx(xt,{path:"/short-code/:shortCode/visits",children:["","*"].map(V=>v.jsx(xt,{path:V,element:v.jsx(i,{})},V))}),v.jsx(xt,{path:"/short-code/:shortCode/edit",element:v.jsx(h,{})}),U&&v.jsx(xt,{path:"/short-code/:shortCode/redirect-rules",element:v.jsx(b,{})}),v.jsx(xt,{path:"/short-urls/compare-visits",element:v.jsx(x,{})}),v.jsx(xt,{path:"/tag/:tag/visits",children:["","*"].map(V=>v.jsx(xt,{path:V,element:v.jsx(a,{})},V))}),v.jsx(xt,{path:"/tags/compare-visits",element:v.jsx(g,{})}),v.jsx(xt,{path:"/domain/:domain/visits",children:["","*"].map(V=>v.jsx(xt,{path:V,element:v.jsx(o,{})},V))}),v.jsx(xt,{path:"/orphan-visits",children:["","*"].map(V=>v.jsx(xt,{path:V,element:v.jsx(l,{})},V))}),v.jsx(xt,{path:"/non-orphan-visits",children:["","*"].map(V=>v.jsx(xt,{path:V,element:v.jsx(f,{})},V))}),v.jsx(xt,{path:"/manage-tags",element:v.jsx(t,{})}),v.jsx(xt,{path:"/manage-domains",element:v.jsx(m,{})}),v.jsx(xt,{path:"/domains/compare-visits",element:v.jsx(_,{})}),e&&v.jsx(xt,{path:"*",element:e("/list-short-urls/1")})]})})})]})})]})},bTe=Rn(MH,["TagsList","ShortUrlsList","CreateShortUrl","ShortUrlVisits","TagVisits","DomainVisits","OrphanVisits","NonOrphanVisits","Overview","EditShortUrl","ManageDomains","TagVisitsComparison","DomainVisitsComparison","ShortUrlVisitsComparison","ShortUrlRedirectRules"]),wTe=e=>pB({devTools:!1,reducer:UT({mercureInfo:e.mercureInfoReducer,shortUrlsList:e.shortUrlsListReducer,shortUrlCreation:e.shortUrlCreationReducer,shortUrlDeletion:e.shortUrlDeletionReducer,shortUrlEdition:e.shortUrlEditionReducer,shortUrlsDetails:e.shortUrlsDetailsReducer,shortUrlVisits:e.shortUrlVisitsReducer,shortUrlVisitsDeletion:e.shortUrlVisitsDeletionReducer,shortUrlVisitsComparison:e.shortUrlVisitsComparisonReducer,tagVisits:e.tagVisitsReducer,tagVisitsComparison:e.tagVisitsComparisonReducer,domainVisits:e.domainVisitsReducer,domainVisitsComparison:e.domainVisitsComparisonReducer,orphanVisits:e.orphanVisitsReducer,orphanVisitsDeletion:e.orphanVisitsDeletionReducer,nonOrphanVisits:e.nonOrphanVisitsReducer,tagsList:e.tagsListReducer,tagDelete:e.tagDeleteReducer,tagEdit:e.tagEditReducer,domainsList:e.domainsListReducer,visitsOverview:e.visitsOverviewReducer,shortUrlRedirectRules:e.shortUrlRedirectRulesReducer,shortUrlRedirectRulesSaving:e.setShortUrlRedirectRulesReducer}),middleware:t=>t({immutableCheck:!1,serializableCheck:!1})}),_Te=e=>{e.factory("Main",bTe),e.factory("store",wTe)},Na=new O9,{container:xTe}=Na,STe=e=>t=>Object.fromEntries(e.map(n=>[n,t[n]])),CTe=(e,t)=>(...n)=>e[t](...n),ATe=(e,t)=>({...e,[t]:CTe(xTe,t)}),Zd=(e,t=[])=>e9(e?STe(e):null,t.reduce(ATe,{}));_Te(Na);JAe(Na,Zd);xEe(Na,Zd);vTe(Na,Zd);MSe(Na);jSe(Na,Zd);FSe(Na,Zd);REe(Na);oAe(Na,Zd);let B7;const ETe=e=>({serverVersion:t,apiClient:n,settings:r,routesPrefix:i="",createNotFound:a,tagColorsStorage:o})=>{const l=ySe(t),f=M.useRef(void 0),[u,h]=M.useState(),m=cc(),g=M.useMemo(()=>m?M.Fragment:p9,[m]);return M.useEffect(()=>{B7=n,e.value("apiClientFactory",()=>B7),o&&e.value("TagColorsStorage",o);const{container:_}=e,{Main:x,store:b,loadMercureInfo:S,listTags:C,listDomains:A}=_;f.current=v.jsx(x,{createNotFound:a}),h(b),b.dispatch(S(r)),b.dispatch(C()),b.dispatch(A())},[n,a,r,o]),u?v.jsx(t9,{store:u,children:v.jsx(tU,{value:r??{},children:v.jsx(vSe,{value:l,children:v.jsx(pSe,{value:i,children:v.jsx(g,{children:f.current})})})})}):v.jsx(v.Fragment,{})},OTe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=",TTe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABSCAMAAAAhFXfZAAAC91BMVEVMaXEzeak2f7I4g7g3g7cua5gzeKg8hJo3grY4g7c3grU0gLI2frE0daAubJc2gbQwd6QzeKk2gLMtd5sxdKIua5g1frA2f7IydaM0e6w2fq41fK01eqo3grgubJgta5cxdKI1f7AydaQydaMxc6EubJgvbJkwcZ4ubZkwcJwubZgubJcydqUydKIxapgubJctbJcubZcubJcvbJYubJcvbZkubJctbJctbZcubJg2f7AubJcrbZcubJcubJcua5g3grY0fq8ubJcubJdEkdEwhsw6i88vhswuhcsuhMtBjMgthMsrg8srgss6is8qgcs8i9A9iMYtg8spgcoogMo7hcMngMonf8olfso4gr8kfck5iM8jfMk4iM8he8k1fro7itAgesk2hs8eecgzfLcofssdeMg0hc4cd8g2hcsxeLQbdsgZdcgxeLImfcszhM0vda4xgckzhM4xg84wf8Yxgs4udKsvfcQucqhUndROmdM1fK0wcZ8vb5w0eqpQm9MzeKhXoNVcpdYydKNWn9VZotVKltJFjsIwcJ1Rms9OlslLmtH///8+kc9epdYzd6dbo9VHkMM2f7FHmNBClM8ydqVcpNY9hro3gLM9hLczealQmcw3fa46f7A8gLMxc6I3eagyc6FIldJMl9JSnNRSntNNl9JPnNJFi75UnM9ZodVKksg8kM45jc09e6ZHltFBk883gbRBh7pDk9EwcaBzn784g7dKkcY2i81Om9M7j85Llc81is09g7Q4grY/j9A0eqxKmdFFltBEjcXf6fFImdBCiLxJl9FGlNFBi78yiMxVndEvbpo6js74+vx+psPP3+o/ks5HkcpGmNCjwdZCkNDM3ehYoNJEls+lxNkxh8xHks0+jdC1zd5Lg6r+/v/H2ufz9/o3jM3t8/edvdM/k89Th61OiLBSjbZklbaTt9BfptdjmL1AicBHj8hGk9FAgK1dkLNTjLRekrdClc/k7fM0icy0y9tgp9c4jc2NtM9Dlc8zicxeXZn3AAAAQ3RSTlMAHDdTb4yPA+LtnEQmC4L2EmHqB7XA0d0sr478x4/Yd5i1zOfyPkf1sLVq4Nh3FvjxopQ2/STNuFzUwFIwxKaejILpIBEV9wAABhVJREFUeF6s1NdyFEcYBeBeoQIhRAkLlRDGrhIgY3BJL8CVeKzuyXFzzjkn5ZxzzuScg3PO8cKzu70JkO0LfxdTU//pM9vTu7Xgf6KqOVTb9X7toRrVEfBf1HTVjZccrT/2by1VV928Yty9ZbVuucdz90frG8DBjl9pVApbOstvmMuvVgaNXSfAAd6pGxpy6yxf5ph43pS/4f3uoaGm2rdu72S9xzOvMymkZFq/ptDrk90mhW7e4zl7HLzhxGWPR20xmSxJ/VqldG5m9XhaVOA1DadsNh3Pu5L2N6QtPO/32JpqQBVVk20oy/Pi2s23WEvyfHbe1thadVQttvm7Llf65gGmXK67XtupyoM7HQhmXdLS8oGWJNeOJ3C5fG5XCEJnkez3/oFdsvgJ4l2ANZwhrJKk/7OSXa+3Vw2WJMlKnGkobouYk6T0TyX30klOUnTD9HJ5qpckL3EW/w4XF3Xd0FGywXUrstrclVsqz5Pd/sXFYyDnPdrLcQODmGOK47IZb4CmibmMn+MYRzFZ5jg33ZL/EJrWcszHmANy3ARBK/IXtciJy8VsitPSdE3uuHxzougojcUdr8/32atnz/ev3f/K5wtpxUTpcaI45zusVDpYtZi+jg0oU9b3x74h7+n9ABvYEZeKaVq0sh0AtLKsFtqNBdeT0MrSzwwlq9+x6xAO4tgOtSzbCjrNQQiNvQUbUEubvzBUeGw26yDCsRHCoLkTHDa7IdOLIThs/gHvChszh2CimE8peRs47cxANI0lYNB5y1DljpOF0IhzBDPOZnDOqYYbeGKECbPzWnXludPphw5c2YBq5zlwXphIbO4VDCZ0gnPfUO1TwZoYwAs2ExPCedAu9DAjfQUjzITQb3jNj0KG2Sgt6BHaQUdYzWz+XmBktOHwanXjaSTcwwziBcuMOtwBmqPrTOxFQR/DRKKPqyur0aiW6cULYsx6tBm0jXpR/AUWR6HRq9WVW6MRhIq5jLyjbaCTDCijyYJNpCajdyobP/eTw0iexBAKkJ3gA5KcQb2zBXsIBckn+xVv8jkZSaEFHE+jFEleAEfayRU0MouNoBmB/L50Ai/HSLIHxcrpCvnhSQAuakKp2C/YbCylJjXRVy/z3+Kv/RrNcCo+WUzlVEhzKffnTQnxeN9fWF88fiNCUdSTsaufaChKWInHeysygfpIqagoakW+vV20J8uyl6TyNKEZWV4oRSPyCkWpgOLSbkCObT8o2r6tlG58HQquf6O0v50tB7JM7F4EORd2dx/K0w/KHsVkLPaoYrwgP/y7krr3SSMA4zj+OBgmjYkxcdIJQyQRKgg2viX9Hddi9UBb29LrKR7CVVEEEXWojUkXNyfTNDE14W9gbHJNuhjDettN3ZvbOvdOqCD3Jp/9l+/wJE+9PkYGjx/fqkys3S2rMozM/o2106rfMUINo6hVqz+eu/hd1c4xTg0TAfy5kV+4UG6+IthHTU9woWmxuKNbTfuCSfovBCxq7EtHqvYL4Sm6F8GVxsSXHMQ07TOi1DKtZxjWaaIyi4CXWjxPccUw8WVbMYY5wxC1mzEyXMJWkllpRloi+Kkoq69sxBTlElF6aAxYUbjXNlhlDZilDnM4U5SlN5biRsRHnbx3mbeWjEh4mEyiuJDl5XcWVmX5GvNkFgLWZM5qwsop4/AWfLhU1cR7k1VVvcYCWRkOI6Xy5gmnphCYIkvzuNYzHzosq2oNk2RtSs8khfUOfHIDgR6ysYBaMpl4uEgk2U/oJTs9AaTSwma7dT69geAE2ZpEjUsn2ieJNHeKfrI3EcAGJ2ZaNgVuC8EBctCLc57P5u5led6IOBkIYkuQMrmmjChs4VkfOerHqSBkPzZlhe06RslZ3zMjk2sscqKwY0RcjKK+LWbzd7KiHhkncs/siFJ+V5eXxD34B8nVuJEpGJNmxN2gH3vSvp7J70tF+D1Ej8qUJD1TkErAND2GZwTFg/LubvmgiBG3SOvdlsqFQrkEzJCL1rstlnVFROixZoDDSuXQFHESwVGlcuQcMb/b42NgjLowh5MTDFE3vNB5qStRIErdCQEh6pLPR92anSUb/wAIhldAaDMpGgAAAABJRU5ErkJggg==",jTe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACkAAAApCAQAAAACach9AAACMUlEQVR4Ae3ShY7jQBAE0Aoz/f9/HTMzhg1zrdKUrJbdx+Kd2nD8VNudfsL/Th///dyQN2TH6f3y/BGpC379rV+S+qqetBOxImNQXL8JCAr2V4iMQXHGNJxeCfZXhSRBcQMfvkOWUdtfzlLgAENmZDcmo2TVmt8OSM2eXxBp3DjHSMFutqS7SbmemzBiR+xpKCNUIRkdkkYxhAkyGoBvyQFEJEefwSmmvBfJuJ6aKqKWnAkvGZOaZXTUgFqYULWNSHUckZuR1HIIimUExutRxwzOLROIG4vKmCKQt364mIlhSyzAf1m9lHZHJZrlAOMMztRRiKimp/rpdJDc9Awry5xTZCte7FHtuS8wJgeYGrex28xNTd086Dik7vUMscQOa8y4DoGtCCSkAKlNwpgNtphjrC6MIHUkR6YWxxs6Sc5xqn222mmCRFzIt8lEdKx+ikCtg91qS2WpwVfBelJCiQJwvzixfI9cxZQWgiSJelKnwBElKYtDOb2MFbhmUigbReQBV0Cg4+qMXSxXSyGUn4UbF8l+7qdSGnTC0XLCmahIgUHLhLOhpVCtw4CzYXvLQWQbJNmxoCsOKAxSgBJno75avolkRw8iIAFcsdc02e9iyCd8tHwmeSSoKTowIgvscSGZUOA7PuCN5b2BX9mQM7S0wYhMNU74zgsPBj3HU7wguAfnxxjFQGBE6pwN+GjME9zHY7zGp8wVxMShYX9NXvEWD3HbwJf4giO4CFIQxXScH1/TM+04kkBiAAAAAElFTkSuQmCC",PTe=()=>{delete e7.Icon.Default.prototype._getIconUrl,e7.Icon.Default.mergeOptions({iconRetinaUrl:TTe,iconUrl:OTe,shadowUrl:jTe})};PTe();const RTe=ETe(Na);function yb(e){return t=>{const{resetSelectedServer:n}=t;return M.useEffect(()=>{n()},[n]),v.jsx(e,{...t})}}let MTe=class extends M.Component{constructor(t){super(t),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}componentDidCatch(t){const{console:n=globalThis.console}=this.props;n.error(t)}render(){const{hasError:t}=this.state,{location:n=globalThis.location}=this.props;if(t)return v.jsxs(tB,{title:"Oops! This is awkward :S",children:[v.jsx("p",{children:"It seems that something went wrong. Try refreshing the page or just click this button."}),v.jsx("br",{}),v.jsx(Pi,{size:"lg",onClick:()=>n.reload(),children:"Take me back"})]});const{children:r}=this.props;return r}};const NTe=({id:e,name:t})=>v.jsxs(ur,{to:`/server/${e}`,className:be("servers-list__server-item","tw:flex tw:items-center tw:justify-between tw:gap-x-2 tw:px-4 tw:py-3","tw:rounded-none tw:hover:bg-lm-secondary tw:hover:dark:bg-dm-secondary","tw:border-b tw:last:border-0 tw:border-lm-border tw:dark:border-dm-border"),children:[v.jsx("span",{className:"tw:truncate",children:t}),v.jsx(Ye,{icon:zy})]}),NH=({servers:e,borderless:t})=>v.jsx(v.Fragment,{children:e.length>0&&v.jsx("div",{"data-testid":"list",className:be("tw:w-full tw:border-lm-border tw:dark:border-dm-border","tw:md:max-h-56 tw:md:overflow-y-auto tw:-mb-1 tw:scroll-thin",{"tw:border-y":!t}),children:e.map(({id:n,name:r})=>v.jsx(NTe,{id:n,name:r},n))})}),LH=({color:e=Yp,className:t})=>v.jsx("svg",{className:t,viewBox:"0 0 512 512",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:v.jsxs("g",{fill:e,children:[v.jsx("path",{d:" M 23.71 85.08 C 17.22 49.81 49.44 14.86 85.08 18.12 C 118.83 19.21 145.72 53.33 139.45 86.37 C 155.64 102.30 171.32 118.83 187.87 134.36 C 198.32 111.73 208.84 89.12 219.57 66.62 C 226.05 53.84 243.47 48.74 255.73 56.27 C 263.76 62.10 270.34 69.69 277.25 76.75 C 286.28 86.61 285.72 102.89 276.31 112.31 C 223.38 165.37 170.38 218.37 117.35 271.34 C 107.72 280.99 91.01 281.25 81.11 271.86 C 74.39 264.94 66.82 258.69 61.24 250.77 C 53.72 238.52 58.85 221.07 71.64 214.62 C 94.11 203.87 116.72 193.38 139.33 182.91 C 123.81 166.36 107.30 150.68 91.37 134.49 C 60.20 140.28 27.37 116.78 23.71 85.08 Z"}),v.jsx("path",{d:" M 205.21 201.23 C 225.32 181.36 260.88 181.11 281.14 200.86 C 299.25 218.75 317.37 236.65 335.10 254.93 C 356.73 278.01 352.01 318.70 326.03 336.56 C 320.07 330.47 313.73 324.65 308.12 318.28 C 323.86 309.39 328.76 286.18 316.63 272.39 C 301.73 256.95 286.30 242.03 271.24 226.75 C 264.49 219.65 256.80 212.00 246.37 211.52 C 224.65 208.64 205.52 233.36 214.49 253.58 C 221.09 266.81 234.22 275.12 243.62 286.24 C 240.43 295.96 238.09 306.13 238.29 316.46 C 225.55 304.29 213.16 291.73 200.89 279.09 C 180.97 257.57 183.10 220.45 205.21 201.23 Z"}),v.jsx("path",{d:" M 273.90 352.07 C 252.28 328.99 256.98 288.31 282.96 270.46 C 288.93 276.54 295.26 282.36 300.88 288.72 C 285.14 297.62 280.23 320.82 292.38 334.61 C 307.27 350.05 322.70 364.96 337.75 380.25 C 344.51 387.35 352.20 395.00 362.64 395.48 C 384.35 398.37 403.49 373.64 394.51 353.42 C 387.92 340.18 374.78 331.88 365.38 320.76 C 368.56 311.04 370.91 300.86 370.71 290.54 C 383.45 302.70 395.84 315.27 408.11 327.91 C 428.03 349.43 425.90 386.55 403.78 405.77 C 383.68 425.64 348.13 425.89 327.86 406.14 C 309.75 388.25 291.60 370.37 273.90 352.07 Z"}),v.jsx("path",{d:" M 422.11 403.83 C 431.96 394.07 441.60 384.06 451.66 374.51 C 460.90 383.74 471.89 392.70 474.89 406.11 C 480.16 429.97 484.08 454.13 488.76 478.12 C 490.00 483.41 484.47 488.29 479.35 486.63 C 454.66 481.52 429.55 478.12 405.14 471.84 C 393.17 467.97 385.20 457.75 376.55 449.27 C 386.39 439.49 396.13 429.60 406.06 419.91 C 416.37 433.45 435.74 414.00 422.11 403.83 Z"})]})}),LTe=({servers:e})=>{const t=po(),n=Object.values(e),r=n.length>0;return M.useEffect(()=>{const i=n.find(({autoConnect:a})=>a);i&&t(`/server/${i.id}`)},[n,t]),v.jsx("div",{className:"tw:px-3 tw:w-full",children:v.jsx(zr,{className:"tw:mx-auto tw:max-w-[720px] tw:overflow-hidden",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:md:flex-row",children:[v.jsx("div",{className:"tw:p-6 tw:hidden tw:md:flex tw:items-center tw:w-[40%]",children:v.jsx("div",{className:"tw:w-full",children:v.jsx(LH,{})})}),v.jsxs("div",{className:"tw:md:border-l tw:border-lm-border tw:dark:border-dm-border tw:flex-grow",children:[v.jsx("h1",{className:be("tw:p-4 tw:text-center tw:border-lm-border tw:dark:border-dm-border",{"tw:border-b":!r}),children:"Welcome!"}),r?v.jsx(NH,{servers:n}):v.jsxs("div",{className:"tw:p-6 tw:text-center tw:flex tw:flex-col tw:gap-12 tw:text-xl",children:[v.jsx("p",{children:"This application will help you manage your Shlink servers."}),v.jsx("p",{children:v.jsxs(Pi,{to:"/server/create",size:"lg",inline:!0,children:[v.jsx(Ye,{icon:Km})," Add a server"]})}),v.jsx("p",{children:v.jsx(Oi,{href:"https://shlink.io/documentation",children:v.jsxs("small",{children:[v.jsx("span",{className:"tw:mr-2",children:"Learn more about Shlink"}),v.jsx(Ye,{icon:XZ})]})})})]})]})]})})})},kH=()=>{const{ServersDropdown:e}=ja(kH),{pathname:t}=Sr(),n="/settings";return v.jsxs(sE,{className:"tw:[&]:fixed tw:top-0 tw:z-900",brand:v.jsxs(ur,{to:"/",className:"tw:[&]:text-white tw:no-underline tw:flex tw:items-center tw:gap-2",children:[v.jsx(LH,{className:"tw:w-7",color:"white"})," ",v.jsx("small",{className:"tw:font-normal",children:"Shlink"})]}),children:[v.jsxs(sE.MenuItem,{to:n,active:t.startsWith(n),className:"tw:flex tw:items-center tw:gap-1.5",children:[v.jsx(Ye,{icon:yX})," Settings"]}),v.jsx(e,{})]})},kTe=Pa(kH,["ServersDropdown"]),DTe=({children:e})=>{const t=Sr();return M.useEffect(()=>{scrollTo(0,0)},[t]),v.jsx(v.Fragment,{children:e})},DH=_B(e=>e,e=>{try{return vE(e,e,"=")}catch{return!1}}),IH=e=>DH(e)?`v${e}`:e,$H=(e,t="latest")=>DH(e)?e:t,ITe="%_VERSION_%",$Te=e=>IH($H(e)),U7=({project:e,version:t})=>v.jsx(Oi,{href:`https://github.com/shlinkio/${e}/releases/${t}`,className:"tw:text-gray-500",children:v.jsx("b",{children:t})}),BTe=({selectedServer:e,clientVersion:t=ITe})=>{const n=$Te(t);return v.jsxs("small",{className:"tw:text-gray-500",children:[hT(e)&&v.jsxs(v.Fragment,{children:["Server: ",v.jsx(U7,{project:"shlink",version:e.printableVersion})," - "]}),"Client: ",v.jsx(U7,{project:"shlink-web-client",version:n})]})},UTe=({selectedServer:e})=>v.jsx("div",{className:be("tw:text-center",{"tw:md:ml-(--aside-menu-width)":hT(e)}),children:v.jsx(BTe,{selectedServer:e})}),Xd=({children:e,className:t})=>v.jsx("div",{className:be("tw:container tw:mx-auto tw:p-5 tw:pt-8 tw:max-md:p-3 tw:max-md:py-4",t),children:e});function BH(e){const t=n=>{const{ServerError:r}=ja(t),i=Td(),{selectServer:a,selectedServer:o}=n;return M.useEffect(()=>{i.serverId&&a(i.serverId)},[i.serverId,a]),o?vZ(o)?v.jsx(r,{}):v.jsx(e,{...n}):v.jsx(Xd,{children:v.jsx(X$,{loading:!0})})};return t}const UH=BH(M.memo(({selectedServer:e,settings:t})=>{const{buildShlinkApiClient:n,TagColorsStorage:r,ShlinkWebComponent:i,ServerError:a}=ja(UH);if(!hT(e))return v.jsx(a,{});const o=`/server/${e.id}`;return v.jsx(i,{serverVersion:e.version,apiClient:n(e),settings:t,routesPrefix:o,tagColorsStorage:r,createNotFound:l=>v.jsx(nB,{to:`${o}${l}`,children:"List short URLs"})})})),zTe=Pa(UH,["buildShlinkApiClient","TagColorsStorage","ShlinkWebComponent","ServerError"]),FTe=(e,t)=>{e.constant("window",window),e.constant("console",console),e.constant("fetch",window.fetch.bind(window)),e.service("HttpClient",Xne,"fetch"),e.serviceFactory("ScrollToTop",()=>DTe),e.factory("MainHeader",kTe),e.serviceFactory("Home",()=>LTe),e.decorator("Home",yb),e.decorator("Home",t(["servers"],["resetSelectedServer"])),e.serviceFactory("ShlinkWebComponent",()=>RTe),e.factory("ShlinkWebComponentContainer",zTe),e.decorator("ShlinkWebComponentContainer",t(["selectedServer","settings"],["selectServer"])),e.serviceFactory("ShlinkVersionsContainer",()=>UTe),e.decorator("ShlinkVersionsContainer",t(["selectedServer"])),e.serviceFactory("ErrorHandler",()=>MTe)},zH=()=>{const e=po();return M.useCallback(()=>e(-1),[e])};function qTe(e){let t=e.url;try{const{host:n,pathname:r}=new URL(t);t=n;const i=r.substring(1);i.length>0&&(t=`${t} ${i}`)}catch{}return`${e.name} ${t}`.toLowerCase().replace(/[^a-zA-Z0-9-_.~]/g,"-")}function VTe(e){const t={};return e.forEach(n=>{t[n.id]=n}),t}const HTe=(e,{url:t,apiKey:n})=>e.some(r=>r.url===t&&r.apiKey===n);function GTe(e,t){const n=Object.values(e),{duplicatedServers:r=[],newServers:i=[]}=wB(t,a=>HTe(n,a)?"duplicatedServers":"newServers");return{duplicatedServers:r,newServers:i}}function bb(e,t){const n=new Set(Object.keys(e)),r=[];return t.forEach(i=>{const a=qTe(i);let o=a,l=1;for(;n.has(o);)o=`${a}-${l}`,l++;r.push({...i,id:o}),n.add(o)}),r}const FH=({open:e,duplicatedServers:t,onClose:n,onConfirm:r})=>{const i=t.length>1;return v.jsxs(Z$,{size:"lg",title:`Duplicated server${i?"s":""}`,open:e,onClose:n,onConfirm:r,confirmText:`Save duplicate${i?"s":""}`,cancelText:i?"Ignore duplicates":"Discard",children:[v.jsx("p",{children:i?"The next servers already exist:":"There is already a server with:"}),v.jsx("ul",{className:"tw:list-disc tw:mt-4",children:t.map(({url:a,apiKey:o},l)=>i?v.jsxs("li",{children:[v.jsx("b",{children:a})," - ",v.jsx("b",{children:o})]},l):v.jsxs(M.Fragment,{children:[v.jsxs("li",{children:["URL: ",v.jsx("b",{children:a})]}),v.jsxs("li",{children:["API key: ",v.jsx("b",{children:o})]})]},l))}),v.jsxs("span",{children:[i?"Do you want to save duplicated servers":"Do you want to save this server","?"]})]})},WTe=e=>M.useCallback(t=>{t.preventDefault(),e(t)},[e]),qH=({onSubmit:e,initialValues:t,children:n,title:r})=>{const[i,a]=M.useState((t==null?void 0:t.name)??""),[o,l]=M.useState((t==null?void 0:t.url)??""),[f,u]=M.useState((t==null?void 0:t.apiKey)??""),{flag:h,toggle:m}=wn((t==null?void 0:t.forwardCredentials)??!1,!0),g=WTe(()=>e({name:i,url:o,apiKey:f,forwardCredentials:h}));return v.jsxs("form",{name:"serverForm",onSubmit:g,children:[v.jsxs(Ub,{className:"tw:mb-4",bodyClassName:"tw:flex tw:flex-col tw:gap-y-3",title:r,children:[v.jsx(QM,{label:"Name",value:i,onChange:_=>a(_.target.value),required:!0}),v.jsx(QM,{label:"URL",type:"url",value:o,onChange:_=>l(_.target.value),required:!0}),v.jsx(Lte,{label:"API key",value:f,onChange:_=>u(_.target.value),required:!0}),v.jsx(wte,{summary:"Advanced options",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-0.5",children:[v.jsxs(zb,{className:"tw:flex tw:items-center tw:gap-x-1.5 tw:cursor-pointer",children:[v.jsx(Mte,{onChange:m,checked:h}),"Forward credentials to this server on every request."]}),v.jsxs("small",{className:"tw:pl-5.5 tw:text-gray-600 tw:dark:text-gray-400 tw:mt-0.5",children:['"',"Credentials",'"'," here means cookies, TLS client certificates, or authentication headers containing a username and password."]}),v.jsxs("small",{className:"tw:pl-5.5 tw:text-gray-600 tw:dark:text-gray-400",children:[v.jsx("b",{children:"Important!"})," If you are not sure what this means, leave it unchecked. Enabling this option will make all requests fail for Shlink older than v4.5.0, as it requires the server to set a more strict value for ",v.jsx("code",{className:"tw:whitespace-nowrap",children:"Access-Control-Allow-Origin"})," than ",v.jsx("code",{children:"*"}),"."]})]})})]}),v.jsx("div",{className:"tw:flex tw:items-center tw:justify-end tw:gap-x-2",children:n})]})},z7=4e3,F7=({variant:e})=>v.jsx("div",{className:"tw:mt-4",children:v.jsxs(Q$,{variant:e,children:[e==="success"&&"Servers properly imported. You can now select one from the list :)",e==="error"&&"The servers could not be imported. Make sure the format is correct."]})}),VH=({servers:e,createServers:t})=>{const{ImportServersBtn:n,useTimeoutToggle:r}=ja(VH),i=po(),a=zH(),o=!!Object.keys(e).length,[l,f]=r(!1,z7),[u,h]=r(!1,z7),[m,g]=wn(),[_,x]=M.useState(),b=M.useCallback(C=>{const[A]=bb(e,[C]);t([A]),i(`/server/${A.id}`)},[t,i,e]),S=M.useCallback(C=>{x(C),Object.values(e).some(({url:O,apiKey:P})=>C.url===O&&C.apiKey===P)?g():b(C)},[b,e,g]);return v.jsxs(Xd,{children:[v.jsxs(qH,{title:"Add new server",onSubmit:S,children:[!o&&v.jsx(n,{tooltipPlacement:"top",onImport:f,onError:h}),o&&v.jsx(Pi,{variant:"secondary",onClick:a,children:"Cancel"}),v.jsx(Pi,{type:"submit",children:"Create server"})]}),l&&v.jsx(F7,{variant:"success"}),u&&v.jsx(F7,{variant:"error"}),v.jsx(FH,{open:m,duplicatedServers:_?[_]:[],onClose:a,onConfirm:()=>_&&b(_)})]})},YTe=Pa(VH,["ImportServersBtn","useTimeoutToggle"]),HH=({server:e,children:t})=>{const{DeleteServerModal:n}=ja(HH),[r,,i,a]=wn(),o=po(),l=M.useCallback(f=>{a(),f&&o("/")},[a,o]);return v.jsxs(v.Fragment,{children:[v.jsx("button",{type:"button",className:"tw:text-danger tw:hover:underline",onClick:i,children:t}),v.jsx(n,{server:e,open:r,onClose:l})]})},KTe=Pa(HH,["DeleteServerModal"]),ZTe=({server:e,onClose:t,open:n,deleteServer:r})=>{const i=M.useCallback(a=>{a==="confirm"&&r(e)},[r,e]);return v.jsx(Z$,{open:n,title:"Remove server",variant:"danger",onClose:()=>t(!1),onConfirm:()=>t(!0),onClosed:i,confirmText:"Delete",children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:gap-y-4",children:[v.jsxs("p",{children:["Are you sure you want to remove ",v.jsx("b",{children:e?e.name:""}),"?"]}),v.jsx("p",{children:v.jsx("i",{children:"No data will be deleted, only the access to this server will be removed from this device. You can create it again at any moment."})})]})})},XTe=BH(({editServer:e,selectedServer:t,selectServer:n})=>{const r=zH(),{reconnect:i}=Pd();if(!Pp(t))return null;const a=o=>{e(t.id,o),i==="true"&&n(t.id),r()};return v.jsx(Xd,{children:v.jsxs(qH,{title:v.jsxs(v.Fragment,{children:['Edit "',t.name,'"']}),initialValues:t,onSubmit:a,children:[v.jsx(Pi,{variant:"secondary",onClick:r,children:"Cancel"}),v.jsx(Pi,{type:"submit",children:"Save"})]})})}),QTe=Pa(XTe,["ServerError"]),GH=({createServers:e,servers:t,children:n,onImport:r,onError:i=()=>{},tooltipPlacement:a="bottom",className:o=""})=>{const{ServersImporter:l}=ja(GH),f=M.useRef(null),{anchor:u,tooltip:h}=J$({placement:a}),[m,g]=M.useState([]),{flag:_,setToTrue:x,setToFalse:b}=wn(!1,!0),S=M.useRef(!1),C=M.useCallback(async({target:P})=>{var j;return l.importServersFromFile((j=P.files)==null?void 0:j[0]).then(R=>{const{duplicatedServers:U,newServers:V}=GTe(t,R);S.current=V.length>0,e(bb(t,V)),U.length>0?(g(U),x()):r==null||r()}).then(()=>{P.value=null}).catch(i)},[e,i,r,t,l,x]),A=M.useCallback(()=>{e(bb(t,m)),b(),r==null||r()},[e,m,b,r,t]),O=M.useCallback(()=>{b(),S.current&&(r==null||r())},[b,r]);return v.jsxs(v.Fragment,{children:[v.jsxs(Pi,{variant:"secondary",className:o,onClick:()=>{var P;return(P=f.current)==null?void 0:P.click()},...u,children:[v.jsx(Ye,{icon:FZ,fixedWidth:!0})," ",n??"Import from file"]}),v.jsxs(eB,{...h,children:["You can create servers by importing a CSV file with ",v.jsx("b",{children:"name"}),", ",v.jsx("b",{children:"apiKey"})," and ",v.jsx("b",{children:"url"})," columns."]}),v.jsx("input",{type:"file",accept:".csv",className:"tw:hidden","aria-hidden":!0,tabIndex:-1,ref:f,onChange:C,"data-testid":"csv-file-input"}),v.jsx(FH,{open:_,duplicatedServers:m,onClose:O,onConfirm:A})]})},JTe=Pa(GH,["ServersImporter"]),WH=({servers:e,selectedServer:t})=>{const{DeleteServerButton:n}=ja(WH);return v.jsx(Xd,{children:v.jsxs("div",{className:"tw:flex tw:flex-col tw:items-center tw:gap-y-4 tw:md:gap-y-8",children:[v.jsxs(X$,{className:"tw:w-full tw:lg:w-[80%]",variant:"error",children:[!Pp(t)&&"Could not find this Shlink server.",Pp(t)&&v.jsxs(v.Fragment,{children:[v.jsx("p",{children:"Oops! Could not connect to this Shlink server."}),"Make sure you have internet connection, and the server is properly configured and on-line."]})]}),v.jsxs("p",{className:"tw:text-xl",children:["These are the Shlink servers currently configured. Choose one of them or ",v.jsx(ur,{to:"/server/create",children:"add a new one"}),"."]}),v.jsx(zr,{className:"tw:w-full tw:max-w-100 tw:overflow-hidden",children:v.jsx(NH,{borderless:!0,servers:Object.values(e)})}),Pp(t)&&v.jsxs("p",{className:"tw:text-xl",children:["Alternatively, if you think you may have misconfigured this server, you can ",v.jsx(n,{server:t,children:"remove it"})," or ",v.jsx(ur,{to:`/server/${t.id}/edit?reconnect=true`,children:"edit it"}),"."]})]})})},e3e=Pa(WH,["DeleteServerButton"]),t3e=4e3,YH=({servers:e})=>{const{ServersExporter:t,ImportServersBtn:n,useTimeoutToggle:r,ManageServersRow:i}=ja(YH),[a,o]=M.useState(""),l=M.useMemo(()=>Object.values(e),[e]),f=M.useMemo(()=>l.filter(({name:g,url:_})=>`${g} ${_}`.toLowerCase().match(a.toLowerCase())),[l,a]),u=l.some(({autoConnect:g})=>!!g),[h,m]=r(!1,t3e);return v.jsxs(Xd,{className:"tw:flex tw:flex-col tw:gap-y-4",children:[v.jsx(Y$,{onChange:o}),v.jsxs("div",{className:"tw:flex tw:flex-col tw:md:flex-row tw:gap-2",children:[v.jsxs("div",{className:"tw:flex tw:gap-2",children:[v.jsx(n,{className:"tw:flex-grow",onError:m,children:"Import servers"}),f.length>0&&v.jsxs(Pi,{variant:"secondary",className:"tw:flex-grow",onClick:async()=>t.exportServers(),children:[v.jsx(Ye,{icon:D9})," Export servers"]})]}),v.jsxs(Pi,{className:"tw:md:ml-auto",to:"/server/create",children:[v.jsx(Ye,{icon:Km})," Add a server"]})]}),v.jsx(Ub,{className:"card",children:v.jsxs(wi,{header:v.jsxs(wi.Row,{children:[u&&v.jsx(wi.Cell,{className:"tw:w-[35px]",children:v.jsx("span",{className:"tw:sr-only",children:"Auto-connect"})}),v.jsx(wi.Cell,{children:"Name"}),v.jsx(wi.Cell,{children:"Base URL"}),v.jsx(wi.Cell,{children:v.jsx("span",{className:"sr-only",children:"Options"})})]}),children:[!f.length&&v.jsx(wi.Row,{className:"tw:text-center",children:v.jsx(wi.Cell,{colSpan:4,children:"No servers found."})}),f.map(g=>v.jsx(i,{server:g,hasAutoConnect:u},g.id))]})}),h&&v.jsx("div",{children:v.jsx(Q$,{variant:"error",children:"The servers could not be imported. Make sure the format is correct."})})]})},n3e=Pa(YH,["ServersExporter","ImportServersBtn","useTimeoutToggle","ManageServersRow"]),KH=({server:e,hasAutoConnect:t})=>{const{ManageServersRowDropdown:n}=ja(KH),{anchor:r,tooltip:i}=J$();return v.jsxs(wi.Row,{className:"tw:relative",children:[t&&v.jsx(wi.Cell,{columnName:"Auto-connect",children:e.autoConnect&&v.jsxs(v.Fragment,{children:[v.jsx(Ye,{icon:Zu,className:"tw:text-lm-brand tw:dark:text-dm-brand",...r}),v.jsx(eB,{...i,children:"Auto-connect to this server"})]})}),v.jsx(wi.Cell,{className:"tw:font-bold",columnName:"Name",children:v.jsx(ur,{to:`/server/${e.id}`,children:e.name})}),v.jsx(wi.Cell,{columnName:"Base URL",className:"tw:max-lg:border-b-0",children:e.url}),v.jsx(wi.Cell,{className:"tw:text-right tw:max-lg:absolute tw:right-0 tw:-top-1 tw:mx-lg:pt-0",children:v.jsx(n,{server:e})})]})},r3e=Pa(KH,["ManageServersRowDropdown"]),ZH=({server:e,setAutoConnect:t})=>{const{DeleteServerModal:n}=ja(ZH),{flag:r,setToTrue:i,setToFalse:a}=wn(!1,!0),o=`/server/${e.id}`,{autoConnect:l}=e,f=l?UZ:bte;return v.jsxs(v.Fragment,{children:[v.jsxs(cf,{menuAlignment:"right",children:[v.jsxs(cf.Item,{to:o,className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:IZ,fixedWidth:!0})," Connect"]}),v.jsxs(cf.Item,{to:`${o}/edit`,className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:mT,fixedWidth:!0})," Edit server"]}),v.jsxs(cf.Item,{onClick:()=>t(e,!l),className:"tw:gap-1.5",children:[v.jsx(Ye,{icon:f,fixedWidth:!0})," ",l?"Do not a":"A","uto-connect"]}),v.jsx(cf.Separator,{}),v.jsxs(cf.Item,{className:"tw:[&]:text-danger tw:gap-1.5",onClick:i,children:[v.jsx(Ye,{icon:P9,fixedWidth:!0})," Remove server"]})]}),v.jsx(n,{server:e,open:r,onClose:a})]})},i3e=Pa(ZH,["DeleteServerModal"]),XH=(e,t)=>gB(e,t,{serializeError:n=>n}),a3e={},{actions:o3e,reducer:s3e}=Dn({name:"shlink/servers",initialState:a3e,reducers:{editServer:{prepare:(e,t)=>({payload:{serverId:e,serverData:t}}),reducer:(e,{payload:t})=>{const{serverId:n,serverData:r}=t;return e[n]?{...e,[n]:{...e[n],...r}}:e}},deleteServer:(e,{payload:t})=>(delete e[t.id],e),setAutoConnect:{prepare:({id:e},t)=>({payload:{serverId:e,autoConnect:t}}),reducer:(e,{payload:t})=>{const{serverId:n,autoConnect:r}=t;return e[n]?r?Object.fromEntries(Object.entries(e).map(([i,a])=>[i,{...a,autoConnect:i===n}])):{...e,[n]:{...e[n],autoConnect:r}}:e}},createServers:{prepare:e=>({payload:VTe(e)}),reducer:(e,{payload:t})=>({...e,...t})}}}),{editServer:l3e,deleteServer:u3e,setAutoConnect:c3e,createServers:QH}=o3e,f3e=s3e,d3e=e=>bb({},Array.isArray(e)?e.filter(j9):[]),h3e=e=>XH("shlink/remoteServers/fetchServers",async(t,{dispatch:n})=>{const r=await e.jsonRequest(`${Iy.homepage}/servers.json`),i=d3e(r);n(QH(i))}),D4="shlink/selectedServer",p3e="1.0.0",m3e="999.999.999",g3e="latest",v3e=e=>$H(e===g3e?m3e:e,p3e),y3e=_B(e=>`${e.id}_${e.url}_${e.apiKey}`,async(e,t)=>t().then(({version:n})=>({version:v3e(n),printableVersion:IH(n)}))),q7=null,I4=Hr(`${D4}/resetSelectedServer`),b3e=e=>XH(`${D4}/selectServer`,async(t,{dispatch:n,getState:r})=>{n(I4());const{servers:i}=r(),a=i[t];if(!a)return{serverNotFound:!0};try{const o=e(a),{version:l,printableVersion:f}=await y3e(a,()=>o.health());return{...a,version:l,printableVersion:f}}catch{return{...a,serverNotReachable:!0}}}),w3e=e=>Dn({name:D4,initialState:q7,reducers:{},extraReducers:t=>{t.addCase(I4,()=>q7),t.addCase(e.fulfilled,(n,{payload:r})=>r)}}),_3e=({servers:e,selectedServer:t})=>{const n=Object.values(e);return v.jsx(sE.Dropdown,{buttonContent:v.jsxs("span",{className:"tw:flex tw:items-center tw:gap-1.5",children:[v.jsx(Ye,{icon:tM,fixedWidth:!0})," Servers"]}),children:n.length===0?v.jsxs(Qa.Item,{to:"/server/create",children:[v.jsx(Ye,{icon:Km})," Add a server"]}):v.jsxs(v.Fragment,{children:[n.map(({name:r,id:i})=>v.jsx(Qa.Item,{to:`/server/${i}`,selected:yZ(t)===i,children:r},i)),v.jsx(Qa.Separator,{}),v.jsxs(Qa.Item,{to:"/manage-servers",children:[v.jsx(Ye,{icon:tM})," Manage servers"]})]})})},x3e=({document:e},t,n)=>{const r=e.createElement("a");r.setAttribute("href",t),r.setAttribute("download",n),r.style.visibility="hidden",e.body.appendChild(r),r.click(),e.body.removeChild(r)},S3e=(e,t,n)=>{const r=new Blob([t],{type:"text/csv;charset=utf-8;"}),i=URL.createObjectURL(r);x3e(e,i,n)},C3e="shlink-servers.csv";var Fm,qm,Vm;class A3e{constructor(t,n,r){Zh(this,Fm);Zh(this,qm);Zh(this,Vm);lf(this,"exportServers",async()=>{const t=Object.values(Kh(this,Fm).get("servers")??{}).map(bZ);try{const n=Kh(this,Vm).call(this,t);S3e(Kh(this,qm),n,C3e)}catch(n){console.error(n)}});Xh(this,Fm,t),Xh(this,qm,n),Xh(this,Vm,r)}}Fm=new WeakMap,qm=new WeakMap,Vm=new WeakMap;const E3e=e=>{if(!Array.isArray(e))throw new Error("Provided file does not have the right format.");return e.map(_Z)};var Hm;class O3e{constructor(t){Zh(this,Hm);Xh(this,Hm,t)}async importServersFromFile(t){if(!t)throw new Error("No file provided");const n=await t.text(),r=await Kh(this,Hm).call(this,n);return E3e(r)}}Hm=new WeakMap;const T3e=(e,t)=>{e.factory("ManageServers",n3e),e.decorator("ManageServers",yb),e.decorator("ManageServers",t(["selectedServer","servers"],["resetSelectedServer"])),e.factory("ManageServersRow",r3e),e.factory("ManageServersRowDropdown",i3e),e.decorator("ManageServersRowDropdown",t(null,["setAutoConnect"])),e.factory("CreateServer",YTe),e.decorator("CreateServer",yb),e.decorator("CreateServer",t(["selectedServer","servers"],["createServers","resetSelectedServer"])),e.factory("EditServer",QTe),e.decorator("EditServer",t(["selectedServer"],["editServer","selectServer","resetSelectedServer"])),e.serviceFactory("ServersDropdown",()=>_3e),e.decorator("ServersDropdown",t(["servers","selectedServer"])),e.serviceFactory("DeleteServerModal",()=>ZTe),e.decorator("DeleteServerModal",t(null,["deleteServer"])),e.factory("DeleteServerButton",KTe),e.factory("ImportServersBtn",JTe),e.decorator("ImportServersBtn",t(["servers"],["createServers"])),e.factory("ServerError",e3e),e.decorator("ServerError",t(["servers","selectedServer"])),e.service("ServersImporter",O3e,"csvToJson"),e.service("ServersExporter",A3e,"Storage","window","jsonToCsv"),e.serviceFactory("selectServer",b3e,"buildShlinkApiClient","loadMercureInfo"),e.serviceFactory("createServers",()=>QH),e.serviceFactory("deleteServer",()=>u3e),e.serviceFactory("editServer",()=>l3e),e.serviceFactory("setAutoConnect",()=>c3e),e.serviceFactory("fetchServers",h3e,"HttpClient"),e.serviceFactory("resetSelectedServer",()=>I4),e.serviceFactory("selectedServerReducerCreator",w3e,"selectServer"),e.serviceFactory("selectedServerReducer",n=>n.reducer,"selectedServerReducerCreator")},JH={field:"dateCreated",dir:"DESC"},j3e={realTimeUpdates:{enabled:!0},shortUrlCreation:{validateUrls:!1},ui:{theme:RT()},visits:{defaultInterval:"last30Days"},shortUrlsList:{defaultOrdering:JH}},{reducer:P3e,actions:R3e}=Dn({name:"shlink/settings",initialState:j3e,reducers:{setSettings:(e,{payload:t})=>Gb(e,t)}}),{setSettings:M3e}=R3e,N3e=P3e,L3e=({settings:e,setSettings:t})=>v.jsx(Xd,{children:v.jsx(bae,{settings:e,updateSettings:t,defaultShortUrlsListOrdering:JH})}),k3e=(e,t)=>{e.serviceFactory("Settings",()=>L3e),e.decorator("Settings",yb),e.decorator("Settings",t(["settings"],["setSettings","resetSelectedServer"])),e.serviceFactory("setSettings",()=>M3e)};var RA,V7;function D3e(){return V7||(V7=1,RA=function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(r,i,a){n.o(r,i)||Object.defineProperty(r,i,{enumerable:!0,get:a})},n.r=function(r){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(r,"__esModule",{value:!0})},n.t=function(r,i){if(1&i&&(r=n(r)),8&i||4&i&&typeof r=="object"&&r&&r.__esModule)return r;var a=Object.create(null);if(n.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:r}),2&i&&typeof r!="string")for(var o in r)n.d(a,o,(function(l){return r[l]}).bind(null,o));return a},n.n=function(r){var i=r&&r.__esModule?function(){return r.default}:function(){return r};return n.d(i,"a",i),i},n.o=function(r,i){return Object.prototype.hasOwnProperty.call(r,i)},n.p="",n(n.s=32)}([function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch{typeof window=="object"&&(n=window)}e.exports=n},function(e,t,n){var r=n(6),i=Object.keys||function(x){var b=[];for(var S in x)b.push(S);return b};e.exports=m;var a=n(5);a.inherits=n(2);var o=n(23),l=n(14);a.inherits(m,o);for(var f=i(l.prototype),u=0;u<f.length;u++){var h=f[u];m.prototype[h]||(m.prototype[h]=l.prototype[h])}function m(x){if(!(this instanceof m))return new m(x);o.call(this,x),l.call(this,x),x&&x.readable===!1&&(this.readable=!1),x&&x.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,x&&x.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",g)}function g(){this.allowHalfOpen||this._writableState.ended||r.nextTick(_,this)}function _(x){x.end()}Object.defineProperty(m.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(m.prototype,"destroyed",{get:function(){return this._readableState!==void 0&&this._writableState!==void 0&&this._readableState.destroyed&&this._writableState.destroyed},set:function(x){this._readableState!==void 0&&this._writableState!==void 0&&(this._readableState.destroyed=x,this._writableState.destroyed=x)}}),m.prototype._destroy=function(x,b){this.push(null),this.end(),r.nextTick(b,x)}},function(e,t){typeof Object.create=="function"?e.exports=function(n,r){n.super_=r,n.prototype=Object.create(r.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(n,r){n.super_=r;var i=function(){};i.prototype=r.prototype,n.prototype=new i,n.prototype.constructor=n}},function(e,t,n){(function(r){/*!
|
||
* The buffer module from node.js, for the browser.
|
||
*
|
||
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
|
||
* @license MIT
|
||
*/var i=n(38),a=n(39),o=n(40);function l(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function f(F,q){if(l()<q)throw new RangeError("Invalid typed array length");return u.TYPED_ARRAY_SUPPORT?(F=new Uint8Array(q)).__proto__=u.prototype:(F===null&&(F=new u(q)),F.length=q),F}function u(F,q,te){if(!(u.TYPED_ARRAY_SUPPORT||this instanceof u))return new u(F,q,te);if(typeof F=="number"){if(typeof q=="string")throw new Error("If encoding is specified then the first argument must be a string");return g(this,F)}return h(this,F,q,te)}function h(F,q,te,ue){if(typeof q=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer<"u"&&q instanceof ArrayBuffer?function(J,se,de,ve){if(se.byteLength,de<0||se.byteLength<de)throw new RangeError("'offset' is out of bounds");if(se.byteLength<de+(ve||0))throw new RangeError("'length' is out of bounds");return se=de===void 0&&ve===void 0?new Uint8Array(se):ve===void 0?new Uint8Array(se,de):new Uint8Array(se,de,ve),u.TYPED_ARRAY_SUPPORT?(J=se).__proto__=u.prototype:J=_(J,se),J}(F,q,te,ue):typeof q=="string"?function(J,se,de){if(typeof de=="string"&&de!==""||(de="utf8"),!u.isEncoding(de))throw new TypeError('"encoding" must be a valid string encoding');var ve=0|b(se,de),he=(J=f(J,ve)).write(se,de);return he!==ve&&(J=J.slice(0,he)),J}(F,q,te):function(J,se){if(u.isBuffer(se)){var de=0|x(se.length);return(J=f(J,de)).length===0||se.copy(J,0,0,de),J}if(se){if(typeof ArrayBuffer<"u"&&se.buffer instanceof ArrayBuffer||"length"in se)return typeof se.length!="number"||function(ve){return ve!=ve}(se.length)?f(J,0):_(J,se);if(se.type==="Buffer"&&o(se.data))return _(J,se.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(F,q)}function m(F){if(typeof F!="number")throw new TypeError('"size" argument must be a number');if(F<0)throw new RangeError('"size" argument must not be negative')}function g(F,q){if(m(q),F=f(F,q<0?0:0|x(q)),!u.TYPED_ARRAY_SUPPORT)for(var te=0;te<q;++te)F[te]=0;return F}function _(F,q){var te=q.length<0?0:0|x(q.length);F=f(F,te);for(var ue=0;ue<te;ue+=1)F[ue]=255&q[ue];return F}function x(F){if(F>=l())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+l().toString(16)+" bytes");return 0|F}function b(F,q){if(u.isBuffer(F))return F.length;if(typeof ArrayBuffer<"u"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(F)||F instanceof ArrayBuffer))return F.byteLength;typeof F!="string"&&(F=""+F);var te=F.length;if(te===0)return 0;for(var ue=!1;;)switch(q){case"ascii":case"latin1":case"binary":return te;case"utf8":case"utf-8":case void 0:return fe(F).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*te;case"hex":return te>>>1;case"base64":return ce(F).length;default:if(ue)return fe(F).length;q=(""+q).toLowerCase(),ue=!0}}function S(F,q,te){var ue=F[q];F[q]=F[te],F[te]=ue}function C(F,q,te,ue,J){if(F.length===0)return-1;if(typeof te=="string"?(ue=te,te=0):te>2147483647?te=2147483647:te<-2147483648&&(te=-2147483648),te=+te,isNaN(te)&&(te=J?0:F.length-1),te<0&&(te=F.length+te),te>=F.length){if(J)return-1;te=F.length-1}else if(te<0){if(!J)return-1;te=0}if(typeof q=="string"&&(q=u.from(q,ue)),u.isBuffer(q))return q.length===0?-1:A(F,q,te,ue,J);if(typeof q=="number")return q&=255,u.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?J?Uint8Array.prototype.indexOf.call(F,q,te):Uint8Array.prototype.lastIndexOf.call(F,q,te):A(F,[q],te,ue,J);throw new TypeError("val must be string, number or Buffer")}function A(F,q,te,ue,J){var se,de=1,ve=F.length,he=q.length;if(ue!==void 0&&((ue=String(ue).toLowerCase())==="ucs2"||ue==="ucs-2"||ue==="utf16le"||ue==="utf-16le")){if(F.length<2||q.length<2)return-1;de=2,ve/=2,he/=2,te/=2}function xe($e,ze){return de===1?$e[ze]:$e.readUInt16BE(ze*de)}if(J){var Oe=-1;for(se=te;se<ve;se++)if(xe(F,se)===xe(q,Oe===-1?0:se-Oe)){if(Oe===-1&&(Oe=se),se-Oe+1===he)return Oe*de}else Oe!==-1&&(se-=se-Oe),Oe=-1}else for(te+he>ve&&(te=ve-he),se=te;se>=0;se--){for(var Le=!0,He=0;He<he;He++)if(xe(F,se+He)!==xe(q,He)){Le=!1;break}if(Le)return se}return-1}function O(F,q,te,ue){te=Number(te)||0;var J=F.length-te;ue?(ue=Number(ue))>J&&(ue=J):ue=J;var se=q.length;if(se%2!=0)throw new TypeError("Invalid hex string");ue>se/2&&(ue=se/2);for(var de=0;de<ue;++de){var ve=parseInt(q.substr(2*de,2),16);if(isNaN(ve))return de;F[te+de]=ve}return de}function P(F,q,te,ue){return ye(fe(q,F.length-te),F,te,ue)}function j(F,q,te,ue){return ye(function(J){for(var se=[],de=0;de<J.length;++de)se.push(255&J.charCodeAt(de));return se}(q),F,te,ue)}function R(F,q,te,ue){return j(F,q,te,ue)}function U(F,q,te,ue){return ye(ce(q),F,te,ue)}function V(F,q,te,ue){return ye(function(J,se){for(var de,ve,he,xe=[],Oe=0;Oe<J.length&&!((se-=2)<0);++Oe)ve=(de=J.charCodeAt(Oe))>>8,he=de%256,xe.push(he),xe.push(ve);return xe}(q,F.length-te),F,te,ue)}function Y(F,q,te){return q===0&&te===F.length?i.fromByteArray(F):i.fromByteArray(F.slice(q,te))}function K(F,q,te){te=Math.min(F.length,te);for(var ue=[],J=q;J<te;){var se,de,ve,he,xe=F[J],Oe=null,Le=xe>239?4:xe>223?3:xe>191?2:1;if(J+Le<=te)switch(Le){case 1:xe<128&&(Oe=xe);break;case 2:(192&(se=F[J+1]))==128&&(he=(31&xe)<<6|63&se)>127&&(Oe=he);break;case 3:se=F[J+1],de=F[J+2],(192&se)==128&&(192&de)==128&&(he=(15&xe)<<12|(63&se)<<6|63&de)>2047&&(he<55296||he>57343)&&(Oe=he);break;case 4:se=F[J+1],de=F[J+2],ve=F[J+3],(192&se)==128&&(192&de)==128&&(192&ve)==128&&(he=(15&xe)<<18|(63&se)<<12|(63&de)<<6|63&ve)>65535&&he<1114112&&(Oe=he)}Oe===null?(Oe=65533,Le=1):Oe>65535&&(Oe-=65536,ue.push(Oe>>>10&1023|55296),Oe=56320|1023&Oe),ue.push(Oe),J+=Le}return function(He){var $e=He.length;if($e<=W)return String.fromCharCode.apply(String,He);for(var ze="",_e=0;_e<$e;)ze+=String.fromCharCode.apply(String,He.slice(_e,_e+=W));return ze}(ue)}t.Buffer=u,t.SlowBuffer=function(F){return+F!=F&&(F=0),u.alloc(+F)},t.INSPECT_MAX_BYTES=50,u.TYPED_ARRAY_SUPPORT=r.TYPED_ARRAY_SUPPORT!==void 0?r.TYPED_ARRAY_SUPPORT:function(){try{var F=new Uint8Array(1);return F.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},F.foo()===42&&typeof F.subarray=="function"&&F.subarray(1,1).byteLength===0}catch{return!1}}(),t.kMaxLength=l(),u.poolSize=8192,u._augment=function(F){return F.__proto__=u.prototype,F},u.from=function(F,q,te){return h(null,F,q,te)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,typeof Symbol<"u"&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(F,q,te){return function(ue,J,se,de){return m(J),J<=0?f(ue,J):se!==void 0?typeof de=="string"?f(ue,J).fill(se,de):f(ue,J).fill(se):f(ue,J)}(null,F,q,te)},u.allocUnsafe=function(F){return g(null,F)},u.allocUnsafeSlow=function(F){return g(null,F)},u.isBuffer=function(F){return!(F==null||!F._isBuffer)},u.compare=function(F,q){if(!u.isBuffer(F)||!u.isBuffer(q))throw new TypeError("Arguments must be Buffers");if(F===q)return 0;for(var te=F.length,ue=q.length,J=0,se=Math.min(te,ue);J<se;++J)if(F[J]!==q[J]){te=F[J],ue=q[J];break}return te<ue?-1:ue<te?1:0},u.isEncoding=function(F){switch(String(F).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(F,q){if(!o(F))throw new TypeError('"list" argument must be an Array of Buffers');if(F.length===0)return u.alloc(0);var te;if(q===void 0)for(q=0,te=0;te<F.length;++te)q+=F[te].length;var ue=u.allocUnsafe(q),J=0;for(te=0;te<F.length;++te){var se=F[te];if(!u.isBuffer(se))throw new TypeError('"list" argument must be an Array of Buffers');se.copy(ue,J),J+=se.length}return ue},u.byteLength=b,u.prototype._isBuffer=!0,u.prototype.swap16=function(){var F=this.length;if(F%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var q=0;q<F;q+=2)S(this,q,q+1);return this},u.prototype.swap32=function(){var F=this.length;if(F%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var q=0;q<F;q+=4)S(this,q,q+3),S(this,q+1,q+2);return this},u.prototype.swap64=function(){var F=this.length;if(F%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var q=0;q<F;q+=8)S(this,q,q+7),S(this,q+1,q+6),S(this,q+2,q+5),S(this,q+3,q+4);return this},u.prototype.toString=function(){var F=0|this.length;return F===0?"":arguments.length===0?K(this,0,F):(function(q,te,ue){var J=!1;if((te===void 0||te<0)&&(te=0),te>this.length||((ue===void 0||ue>this.length)&&(ue=this.length),ue<=0)||(ue>>>=0)<=(te>>>=0))return"";for(q||(q="utf8");;)switch(q){case"hex":return X(this,te,ue);case"utf8":case"utf-8":return K(this,te,ue);case"ascii":return ee(this,te,ue);case"latin1":case"binary":return ie(this,te,ue);case"base64":return Y(this,te,ue);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ne(this,te,ue);default:if(J)throw new TypeError("Unknown encoding: "+q);q=(q+"").toLowerCase(),J=!0}}).apply(this,arguments)},u.prototype.equals=function(F){if(!u.isBuffer(F))throw new TypeError("Argument must be a Buffer");return this===F||u.compare(this,F)===0},u.prototype.inspect=function(){var F="",q=t.INSPECT_MAX_BYTES;return this.length>0&&(F=this.toString("hex",0,q).match(/.{2}/g).join(" "),this.length>q&&(F+=" ... ")),"<Buffer "+F+">"},u.prototype.compare=function(F,q,te,ue,J){if(!u.isBuffer(F))throw new TypeError("Argument must be a Buffer");if(q===void 0&&(q=0),te===void 0&&(te=F?F.length:0),ue===void 0&&(ue=0),J===void 0&&(J=this.length),q<0||te>F.length||ue<0||J>this.length)throw new RangeError("out of range index");if(ue>=J&&q>=te)return 0;if(ue>=J)return-1;if(q>=te)return 1;if(q>>>=0,te>>>=0,ue>>>=0,J>>>=0,this===F)return 0;for(var se=J-ue,de=te-q,ve=Math.min(se,de),he=this.slice(ue,J),xe=F.slice(q,te),Oe=0;Oe<ve;++Oe)if(he[Oe]!==xe[Oe]){se=he[Oe],de=xe[Oe];break}return se<de?-1:de<se?1:0},u.prototype.includes=function(F,q,te){return this.indexOf(F,q,te)!==-1},u.prototype.indexOf=function(F,q,te){return C(this,F,q,te,!0)},u.prototype.lastIndexOf=function(F,q,te){return C(this,F,q,te,!1)},u.prototype.write=function(F,q,te,ue){if(q===void 0)ue="utf8",te=this.length,q=0;else if(te===void 0&&typeof q=="string")ue=q,te=this.length,q=0;else{if(!isFinite(q))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");q|=0,isFinite(te)?(te|=0,ue===void 0&&(ue="utf8")):(ue=te,te=void 0)}var J=this.length-q;if((te===void 0||te>J)&&(te=J),F.length>0&&(te<0||q<0)||q>this.length)throw new RangeError("Attempt to write outside buffer bounds");ue||(ue="utf8");for(var se=!1;;)switch(ue){case"hex":return O(this,F,q,te);case"utf8":case"utf-8":return P(this,F,q,te);case"ascii":return j(this,F,q,te);case"latin1":case"binary":return R(this,F,q,te);case"base64":return U(this,F,q,te);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return V(this,F,q,te);default:if(se)throw new TypeError("Unknown encoding: "+ue);ue=(""+ue).toLowerCase(),se=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var W=4096;function ee(F,q,te){var ue="";te=Math.min(F.length,te);for(var J=q;J<te;++J)ue+=String.fromCharCode(127&F[J]);return ue}function ie(F,q,te){var ue="";te=Math.min(F.length,te);for(var J=q;J<te;++J)ue+=String.fromCharCode(F[J]);return ue}function X(F,q,te){var ue=F.length;(!q||q<0)&&(q=0),(!te||te<0||te>ue)&&(te=ue);for(var J="",se=q;se<te;++se)J+=ae(F[se]);return J}function ne(F,q,te){for(var ue=F.slice(q,te),J="",se=0;se<ue.length;se+=2)J+=String.fromCharCode(ue[se]+256*ue[se+1]);return J}function H(F,q,te){if(F%1!=0||F<0)throw new RangeError("offset is not uint");if(F+q>te)throw new RangeError("Trying to access beyond buffer length")}function I(F,q,te,ue,J,se){if(!u.isBuffer(F))throw new TypeError('"buffer" argument must be a Buffer instance');if(q>J||q<se)throw new RangeError('"value" argument is out of bounds');if(te+ue>F.length)throw new RangeError("Index out of range")}function D(F,q,te,ue){q<0&&(q=65535+q+1);for(var J=0,se=Math.min(F.length-te,2);J<se;++J)F[te+J]=(q&255<<8*(ue?J:1-J))>>>8*(ue?J:1-J)}function z(F,q,te,ue){q<0&&(q=4294967295+q+1);for(var J=0,se=Math.min(F.length-te,4);J<se;++J)F[te+J]=q>>>8*(ue?J:3-J)&255}function N(F,q,te,ue,J,se){if(te+ue>F.length)throw new RangeError("Index out of range");if(te<0)throw new RangeError("Index out of range")}function B(F,q,te,ue,J){return J||N(F,0,te,4),a.write(F,q,te,ue,23,4),te+4}function Q(F,q,te,ue,J){return J||N(F,0,te,8),a.write(F,q,te,ue,52,8),te+8}u.prototype.slice=function(F,q){var te,ue=this.length;if(F=~~F,q=q===void 0?ue:~~q,F<0?(F+=ue)<0&&(F=0):F>ue&&(F=ue),q<0?(q+=ue)<0&&(q=0):q>ue&&(q=ue),q<F&&(q=F),u.TYPED_ARRAY_SUPPORT)(te=this.subarray(F,q)).__proto__=u.prototype;else{var J=q-F;te=new u(J,void 0);for(var se=0;se<J;++se)te[se]=this[se+F]}return te},u.prototype.readUIntLE=function(F,q,te){F|=0,q|=0,te||H(F,q,this.length);for(var ue=this[F],J=1,se=0;++se<q&&(J*=256);)ue+=this[F+se]*J;return ue},u.prototype.readUIntBE=function(F,q,te){F|=0,q|=0,te||H(F,q,this.length);for(var ue=this[F+--q],J=1;q>0&&(J*=256);)ue+=this[F+--q]*J;return ue},u.prototype.readUInt8=function(F,q){return q||H(F,1,this.length),this[F]},u.prototype.readUInt16LE=function(F,q){return q||H(F,2,this.length),this[F]|this[F+1]<<8},u.prototype.readUInt16BE=function(F,q){return q||H(F,2,this.length),this[F]<<8|this[F+1]},u.prototype.readUInt32LE=function(F,q){return q||H(F,4,this.length),(this[F]|this[F+1]<<8|this[F+2]<<16)+16777216*this[F+3]},u.prototype.readUInt32BE=function(F,q){return q||H(F,4,this.length),16777216*this[F]+(this[F+1]<<16|this[F+2]<<8|this[F+3])},u.prototype.readIntLE=function(F,q,te){F|=0,q|=0,te||H(F,q,this.length);for(var ue=this[F],J=1,se=0;++se<q&&(J*=256);)ue+=this[F+se]*J;return ue>=(J*=128)&&(ue-=Math.pow(2,8*q)),ue},u.prototype.readIntBE=function(F,q,te){F|=0,q|=0,te||H(F,q,this.length);for(var ue=q,J=1,se=this[F+--ue];ue>0&&(J*=256);)se+=this[F+--ue]*J;return se>=(J*=128)&&(se-=Math.pow(2,8*q)),se},u.prototype.readInt8=function(F,q){return q||H(F,1,this.length),128&this[F]?-1*(255-this[F]+1):this[F]},u.prototype.readInt16LE=function(F,q){q||H(F,2,this.length);var te=this[F]|this[F+1]<<8;return 32768&te?4294901760|te:te},u.prototype.readInt16BE=function(F,q){q||H(F,2,this.length);var te=this[F+1]|this[F]<<8;return 32768&te?4294901760|te:te},u.prototype.readInt32LE=function(F,q){return q||H(F,4,this.length),this[F]|this[F+1]<<8|this[F+2]<<16|this[F+3]<<24},u.prototype.readInt32BE=function(F,q){return q||H(F,4,this.length),this[F]<<24|this[F+1]<<16|this[F+2]<<8|this[F+3]},u.prototype.readFloatLE=function(F,q){return q||H(F,4,this.length),a.read(this,F,!0,23,4)},u.prototype.readFloatBE=function(F,q){return q||H(F,4,this.length),a.read(this,F,!1,23,4)},u.prototype.readDoubleLE=function(F,q){return q||H(F,8,this.length),a.read(this,F,!0,52,8)},u.prototype.readDoubleBE=function(F,q){return q||H(F,8,this.length),a.read(this,F,!1,52,8)},u.prototype.writeUIntLE=function(F,q,te,ue){F=+F,q|=0,te|=0,ue||I(this,F,q,te,Math.pow(2,8*te)-1,0);var J=1,se=0;for(this[q]=255&F;++se<te&&(J*=256);)this[q+se]=F/J&255;return q+te},u.prototype.writeUIntBE=function(F,q,te,ue){F=+F,q|=0,te|=0,ue||I(this,F,q,te,Math.pow(2,8*te)-1,0);var J=te-1,se=1;for(this[q+J]=255&F;--J>=0&&(se*=256);)this[q+J]=F/se&255;return q+te},u.prototype.writeUInt8=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,1,255,0),u.TYPED_ARRAY_SUPPORT||(F=Math.floor(F)),this[q]=255&F,q+1},u.prototype.writeUInt16LE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[q]=255&F,this[q+1]=F>>>8):D(this,F,q,!0),q+2},u.prototype.writeUInt16BE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[q]=F>>>8,this[q+1]=255&F):D(this,F,q,!1),q+2},u.prototype.writeUInt32LE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[q+3]=F>>>24,this[q+2]=F>>>16,this[q+1]=F>>>8,this[q]=255&F):z(this,F,q,!0),q+4},u.prototype.writeUInt32BE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[q]=F>>>24,this[q+1]=F>>>16,this[q+2]=F>>>8,this[q+3]=255&F):z(this,F,q,!1),q+4},u.prototype.writeIntLE=function(F,q,te,ue){if(F=+F,q|=0,!ue){var J=Math.pow(2,8*te-1);I(this,F,q,te,J-1,-J)}var se=0,de=1,ve=0;for(this[q]=255&F;++se<te&&(de*=256);)F<0&&ve===0&&this[q+se-1]!==0&&(ve=1),this[q+se]=(F/de>>0)-ve&255;return q+te},u.prototype.writeIntBE=function(F,q,te,ue){if(F=+F,q|=0,!ue){var J=Math.pow(2,8*te-1);I(this,F,q,te,J-1,-J)}var se=te-1,de=1,ve=0;for(this[q+se]=255&F;--se>=0&&(de*=256);)F<0&&ve===0&&this[q+se+1]!==0&&(ve=1),this[q+se]=(F/de>>0)-ve&255;return q+te},u.prototype.writeInt8=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,1,127,-128),u.TYPED_ARRAY_SUPPORT||(F=Math.floor(F)),F<0&&(F=255+F+1),this[q]=255&F,q+1},u.prototype.writeInt16LE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[q]=255&F,this[q+1]=F>>>8):D(this,F,q,!0),q+2},u.prototype.writeInt16BE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[q]=F>>>8,this[q+1]=255&F):D(this,F,q,!1),q+2},u.prototype.writeInt32LE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[q]=255&F,this[q+1]=F>>>8,this[q+2]=F>>>16,this[q+3]=F>>>24):z(this,F,q,!0),q+4},u.prototype.writeInt32BE=function(F,q,te){return F=+F,q|=0,te||I(this,F,q,4,2147483647,-2147483648),F<0&&(F=4294967295+F+1),u.TYPED_ARRAY_SUPPORT?(this[q]=F>>>24,this[q+1]=F>>>16,this[q+2]=F>>>8,this[q+3]=255&F):z(this,F,q,!1),q+4},u.prototype.writeFloatLE=function(F,q,te){return B(this,F,q,!0,te)},u.prototype.writeFloatBE=function(F,q,te){return B(this,F,q,!1,te)},u.prototype.writeDoubleLE=function(F,q,te){return Q(this,F,q,!0,te)},u.prototype.writeDoubleBE=function(F,q,te){return Q(this,F,q,!1,te)},u.prototype.copy=function(F,q,te,ue){if(te||(te=0),ue||ue===0||(ue=this.length),q>=F.length&&(q=F.length),q||(q=0),ue>0&&ue<te&&(ue=te),ue===te||F.length===0||this.length===0)return 0;if(q<0)throw new RangeError("targetStart out of bounds");if(te<0||te>=this.length)throw new RangeError("sourceStart out of bounds");if(ue<0)throw new RangeError("sourceEnd out of bounds");ue>this.length&&(ue=this.length),F.length-q<ue-te&&(ue=F.length-q+te);var J,se=ue-te;if(this===F&&te<q&&q<ue)for(J=se-1;J>=0;--J)F[J+q]=this[J+te];else if(se<1e3||!u.TYPED_ARRAY_SUPPORT)for(J=0;J<se;++J)F[J+q]=this[J+te];else Uint8Array.prototype.set.call(F,this.subarray(te,te+se),q);return se},u.prototype.fill=function(F,q,te,ue){if(typeof F=="string"){if(typeof q=="string"?(ue=q,q=0,te=this.length):typeof te=="string"&&(ue=te,te=this.length),F.length===1){var J=F.charCodeAt(0);J<256&&(F=J)}if(ue!==void 0&&typeof ue!="string")throw new TypeError("encoding must be a string");if(typeof ue=="string"&&!u.isEncoding(ue))throw new TypeError("Unknown encoding: "+ue)}else typeof F=="number"&&(F&=255);if(q<0||this.length<q||this.length<te)throw new RangeError("Out of range index");if(te<=q)return this;var se;if(q>>>=0,te=te===void 0?this.length:te>>>0,F||(F=0),typeof F=="number")for(se=q;se<te;++se)this[se]=F;else{var de=u.isBuffer(F)?F:fe(new u(F,ue).toString()),ve=de.length;for(se=0;se<te-q;++se)this[se+q]=de[se%ve]}return this};var G=/[^+\/0-9A-Za-z-_]/g;function ae(F){return F<16?"0"+F.toString(16):F.toString(16)}function fe(F,q){var te;q=q||1/0;for(var ue=F.length,J=null,se=[],de=0;de<ue;++de){if((te=F.charCodeAt(de))>55295&&te<57344){if(!J){if(te>56319){(q-=3)>-1&&se.push(239,191,189);continue}if(de+1===ue){(q-=3)>-1&&se.push(239,191,189);continue}J=te;continue}if(te<56320){(q-=3)>-1&&se.push(239,191,189),J=te;continue}te=65536+(J-55296<<10|te-56320)}else J&&(q-=3)>-1&&se.push(239,191,189);if(J=null,te<128){if((q-=1)<0)break;se.push(te)}else if(te<2048){if((q-=2)<0)break;se.push(te>>6|192,63&te|128)}else if(te<65536){if((q-=3)<0)break;se.push(te>>12|224,te>>6&63|128,63&te|128)}else{if(!(te<1114112))throw new Error("Invalid code point");if((q-=4)<0)break;se.push(te>>18|240,te>>12&63|128,te>>6&63|128,63&te|128)}}return se}function ce(F){return i.toByteArray(function(q){if((q=function(te){return te.trim?te.trim():te.replace(/^\s+|\s+$/g,"")}(q).replace(G,"")).length<2)return"";for(;q.length%4!=0;)q+="=";return q}(F))}function ye(F,q,te,ue){for(var J=0;J<ue&&!(J+te>=q.length||J>=F.length);++J)q[J+te]=F[J];return J}}).call(this,n(0))},function(e,t){var n,r,i=e.exports={};function a(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function l(S){if(n===setTimeout)return setTimeout(S,0);if((n===a||!n)&&setTimeout)return n=setTimeout,setTimeout(S,0);try{return n(S,0)}catch{try{return n.call(null,S,0)}catch{return n.call(this,S,0)}}}(function(){try{n=typeof setTimeout=="function"?setTimeout:a}catch{n=a}try{r=typeof clearTimeout=="function"?clearTimeout:o}catch{r=o}})();var f,u=[],h=!1,m=-1;function g(){h&&f&&(h=!1,f.length?u=f.concat(u):m=-1,u.length&&_())}function _(){if(!h){var S=l(g);h=!0;for(var C=u.length;C;){for(f=u,u=[];++m<C;)f&&f[m].run();m=-1,C=u.length}f=null,h=!1,function(A){if(r===clearTimeout)return clearTimeout(A);if((r===o||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(A);try{r(A)}catch{try{return r.call(null,A)}catch{return r.call(this,A)}}}(S)}}function x(S,C){this.fun=S,this.array=C}function b(){}i.nextTick=function(S){var C=new Array(arguments.length-1);if(arguments.length>1)for(var A=1;A<arguments.length;A++)C[A-1]=arguments[A];u.push(new x(S,C)),u.length!==1||h||l(_)},x.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=b,i.addListener=b,i.once=b,i.off=b,i.removeListener=b,i.removeAllListeners=b,i.emit=b,i.prependListener=b,i.prependOnceListener=b,i.listeners=function(S){return[]},i.binding=function(S){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(S){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,n){(function(r){function i(a){return Object.prototype.toString.call(a)}t.isArray=function(a){return Array.isArray?Array.isArray(a):i(a)==="[object Array]"},t.isBoolean=function(a){return typeof a=="boolean"},t.isNull=function(a){return a===null},t.isNullOrUndefined=function(a){return a==null},t.isNumber=function(a){return typeof a=="number"},t.isString=function(a){return typeof a=="string"},t.isSymbol=function(a){return typeof a=="symbol"},t.isUndefined=function(a){return a===void 0},t.isRegExp=function(a){return i(a)==="[object RegExp]"},t.isObject=function(a){return typeof a=="object"&&a!==null},t.isDate=function(a){return i(a)==="[object Date]"},t.isError=function(a){return i(a)==="[object Error]"||a instanceof Error},t.isFunction=function(a){return typeof a=="function"},t.isPrimitive=function(a){return a===null||typeof a=="boolean"||typeof a=="number"||typeof a=="string"||typeof a=="symbol"||a===void 0},t.isBuffer=r.isBuffer}).call(this,n(3).Buffer)},function(e,t,n){(function(r){!r.version||r.version.indexOf("v0.")===0||r.version.indexOf("v1.")===0&&r.version.indexOf("v1.8.")!==0?e.exports={nextTick:function(i,a,o,l){if(typeof i!="function")throw new TypeError('"callback" argument must be a function');var f,u,h=arguments.length;switch(h){case 0:case 1:return r.nextTick(i);case 2:return r.nextTick(function(){i.call(null,a)});case 3:return r.nextTick(function(){i.call(null,a,o)});case 4:return r.nextTick(function(){i.call(null,a,o,l)});default:for(f=new Array(h-1),u=0;u<f.length;)f[u++]=arguments[u];return r.nextTick(function(){i.apply(null,f)})}}}:e.exports=r}).call(this,n(4))},function(e,t,n){var r=n(3),i=r.Buffer;function a(l,f){for(var u in l)f[u]=l[u]}function o(l,f,u){return i(l,f,u)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=r:(a(r,t),t.Buffer=o),a(i,o),o.from=function(l,f,u){if(typeof l=="number")throw new TypeError("Argument must not be a number");return i(l,f,u)},o.alloc=function(l,f,u){if(typeof l!="number")throw new TypeError("Argument must be a number");var h=i(l);return f!==void 0?typeof u=="string"?h.fill(f,u):h.fill(f):h.fill(0),h},o.allocUnsafe=function(l){if(typeof l!="number")throw new TypeError("Argument must be a number");return i(l)},o.allocUnsafeSlow=function(l){if(typeof l!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(l)}},function(e,t,n){var r=n(17)(Object,"create");e.exports=r},function(e,t,n){var r=n(31);e.exports=function(i,a){for(var o=i.length;o--;)if(r(i[o][0],a))return o;return-1}},function(e,t,n){var r=n(96);e.exports=function(i,a){var o=i.__data__;return r(a)?o[typeof a=="string"?"string":"hash"]:o.map}},function(e,t,n){(function(r){var i=r!==void 0&&r||typeof self<"u"&&self||window,a=Function.prototype.apply;function o(l,f){this._id=l,this._clearFn=f}t.setTimeout=function(){return new o(a.call(setTimeout,i,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,i,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(l){l&&l.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(i,this._id)},t.enroll=function(l,f){clearTimeout(l._idleTimeoutId),l._idleTimeout=f},t.unenroll=function(l){clearTimeout(l._idleTimeoutId),l._idleTimeout=-1},t._unrefActive=t.active=function(l){clearTimeout(l._idleTimeoutId);var f=l._idleTimeout;f>=0&&(l._idleTimeoutId=setTimeout(function(){l._onTimeout&&l._onTimeout()},f))},n(35),t.setImmediate=typeof self<"u"&&self.setImmediate||r!==void 0&&r.setImmediate||this&&this.setImmediate,t.clearImmediate=typeof self<"u"&&self.clearImmediate||r!==void 0&&r.clearImmediate||this&&this.clearImmediate}).call(this,n(0))},function(e,t){function n(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function r(o){return typeof o=="function"}function i(o){return typeof o=="object"&&o!==null}function a(o){return o===void 0}e.exports=n,n.EventEmitter=n,n.prototype._events=void 0,n.prototype._maxListeners=void 0,n.defaultMaxListeners=10,n.prototype.setMaxListeners=function(o){if(!function(l){return typeof l=="number"}(o)||o<0||isNaN(o))throw TypeError("n must be a positive number");return this._maxListeners=o,this},n.prototype.emit=function(o){var l,f,u,h,m,g;if(this._events||(this._events={}),o==="error"&&(!this._events.error||i(this._events.error)&&!this._events.error.length)){if((l=arguments[1])instanceof Error)throw l;var _=new Error('Uncaught, unspecified "error" event. ('+l+")");throw _.context=l,_}if(a(f=this._events[o]))return!1;if(r(f))switch(arguments.length){case 1:f.call(this);break;case 2:f.call(this,arguments[1]);break;case 3:f.call(this,arguments[1],arguments[2]);break;default:h=Array.prototype.slice.call(arguments,1),f.apply(this,h)}else if(i(f))for(h=Array.prototype.slice.call(arguments,1),u=(g=f.slice()).length,m=0;m<u;m++)g[m].apply(this,h);return!0},n.prototype.addListener=function(o,l){var f;if(!r(l))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",o,r(l.listener)?l.listener:l),this._events[o]?i(this._events[o])?this._events[o].push(l):this._events[o]=[this._events[o],l]:this._events[o]=l,i(this._events[o])&&!this._events[o].warned&&(f=a(this._maxListeners)?n.defaultMaxListeners:this._maxListeners)&&f>0&&this._events[o].length>f&&(this._events[o].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[o].length),typeof console.trace=="function"&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(o,l){if(!r(l))throw TypeError("listener must be a function");var f=!1;function u(){this.removeListener(o,u),f||(f=!0,l.apply(this,arguments))}return u.listener=l,this.on(o,u),this},n.prototype.removeListener=function(o,l){var f,u,h,m;if(!r(l))throw TypeError("listener must be a function");if(!this._events||!this._events[o])return this;if(h=(f=this._events[o]).length,u=-1,f===l||r(f.listener)&&f.listener===l)delete this._events[o],this._events.removeListener&&this.emit("removeListener",o,l);else if(i(f)){for(m=h;m-- >0;)if(f[m]===l||f[m].listener&&f[m].listener===l){u=m;break}if(u<0)return this;f.length===1?(f.length=0,delete this._events[o]):f.splice(u,1),this._events.removeListener&&this.emit("removeListener",o,l)}return this},n.prototype.removeAllListeners=function(o){var l,f;if(!this._events)return this;if(!this._events.removeListener)return arguments.length===0?this._events={}:this._events[o]&&delete this._events[o],this;if(arguments.length===0){for(l in this._events)l!=="removeListener"&&this.removeAllListeners(l);return this.removeAllListeners("removeListener"),this._events={},this}if(r(f=this._events[o]))this.removeListener(o,f);else if(f)for(;f.length;)this.removeListener(o,f[f.length-1]);return delete this._events[o],this},n.prototype.listeners=function(o){return this._events&&this._events[o]?r(this._events[o])?[this._events[o]]:this._events[o].slice():[]},n.prototype.listenerCount=function(o){if(this._events){var l=this._events[o];if(r(l))return 1;if(l)return l.length}return 0},n.listenerCount=function(o,l){return o.listenerCount(l)}},function(e,t,n){(t=e.exports=n(23)).Stream=t,t.Readable=t,t.Writable=n(14),t.Duplex=n(1),t.Transform=n(27),t.PassThrough=n(45)},function(e,t,n){(function(r,i,a){var o=n(6);function l(K){var W=this;this.next=null,this.entry=null,this.finish=function(){(function(ee,ie,X){var ne=ee.entry;for(ee.entry=null;ne;){var H=ne.callback;ie.pendingcb--,H(void 0),ne=ne.next}ie.corkedRequestsFree?ie.corkedRequestsFree.next=ee:ie.corkedRequestsFree=ee})(W,K)}}e.exports=O;var f,u=!r.browser&&["v0.10","v0.9."].indexOf(r.version.slice(0,5))>-1?i:o.nextTick;O.WritableState=A;var h=n(5);h.inherits=n(2);var m,g={deprecate:n(44)},_=n(24),x=n(7).Buffer,b=a.Uint8Array||function(){},S=n(25);function C(){}function A(K,W){f=f||n(1),K=K||{};var ee=W instanceof f;this.objectMode=!!K.objectMode,ee&&(this.objectMode=this.objectMode||!!K.writableObjectMode);var ie=K.highWaterMark,X=K.writableHighWaterMark,ne=this.objectMode?16:16384;this.highWaterMark=ie||ie===0?ie:ee&&(X||X===0)?X:ne,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var H=K.decodeStrings===!1;this.decodeStrings=!H,this.defaultEncoding=K.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(I){(function(D,z){var N=D._writableState,B=N.sync,Q=N.writecb;if(function(ae){ae.writing=!1,ae.writecb=null,ae.length-=ae.writelen,ae.writelen=0}(N),z)(function(ae,fe,ce,ye,F){--fe.pendingcb,ce?(o.nextTick(F,ye),o.nextTick(Y,ae,fe),ae._writableState.errorEmitted=!0,ae.emit("error",ye)):(F(ye),ae._writableState.errorEmitted=!0,ae.emit("error",ye),Y(ae,fe))})(D,N,B,z,Q);else{var G=U(N);G||N.corked||N.bufferProcessing||!N.bufferedRequest||R(D,N),B?u(j,D,N,G,Q):j(D,N,G,Q)}})(W,I)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new l(this)}function O(K){if(f=f||n(1),!(m.call(O,this)||this instanceof f))return new O(K);this._writableState=new A(K,this),this.writable=!0,K&&(typeof K.write=="function"&&(this._write=K.write),typeof K.writev=="function"&&(this._writev=K.writev),typeof K.destroy=="function"&&(this._destroy=K.destroy),typeof K.final=="function"&&(this._final=K.final)),_.call(this)}function P(K,W,ee,ie,X,ne,H){W.writelen=ie,W.writecb=H,W.writing=!0,W.sync=!0,ee?K._writev(X,W.onwrite):K._write(X,ne,W.onwrite),W.sync=!1}function j(K,W,ee,ie){ee||function(X,ne){ne.length===0&&ne.needDrain&&(ne.needDrain=!1,X.emit("drain"))}(K,W),W.pendingcb--,ie(),Y(K,W)}function R(K,W){W.bufferProcessing=!0;var ee=W.bufferedRequest;if(K._writev&&ee&&ee.next){var ie=W.bufferedRequestCount,X=new Array(ie),ne=W.corkedRequestsFree;ne.entry=ee;for(var H=0,I=!0;ee;)X[H]=ee,ee.isBuf||(I=!1),ee=ee.next,H+=1;X.allBuffers=I,P(K,W,!0,W.length,X,"",ne.finish),W.pendingcb++,W.lastBufferedRequest=null,ne.next?(W.corkedRequestsFree=ne.next,ne.next=null):W.corkedRequestsFree=new l(W),W.bufferedRequestCount=0}else{for(;ee;){var D=ee.chunk,z=ee.encoding,N=ee.callback;if(P(K,W,!1,W.objectMode?1:D.length,D,z,N),ee=ee.next,W.bufferedRequestCount--,W.writing)break}ee===null&&(W.lastBufferedRequest=null)}W.bufferedRequest=ee,W.bufferProcessing=!1}function U(K){return K.ending&&K.length===0&&K.bufferedRequest===null&&!K.finished&&!K.writing}function V(K,W){K._final(function(ee){W.pendingcb--,ee&&K.emit("error",ee),W.prefinished=!0,K.emit("prefinish"),Y(K,W)})}function Y(K,W){var ee=U(W);return ee&&(function(ie,X){X.prefinished||X.finalCalled||(typeof ie._final=="function"?(X.pendingcb++,X.finalCalled=!0,o.nextTick(V,ie,X)):(X.prefinished=!0,ie.emit("prefinish")))}(K,W),W.pendingcb===0&&(W.finished=!0,K.emit("finish"))),ee}h.inherits(O,_),A.prototype.getBuffer=function(){for(var K=this.bufferedRequest,W=[];K;)W.push(K),K=K.next;return W},function(){try{Object.defineProperty(A.prototype,"buffer",{get:g.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}(),typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(m=Function.prototype[Symbol.hasInstance],Object.defineProperty(O,Symbol.hasInstance,{value:function(K){return!!m.call(this,K)||this===O&&K&&K._writableState instanceof A}})):m=function(K){return K instanceof this},O.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},O.prototype.write=function(K,W,ee){var ie=this._writableState,X=!1,ne=!ie.objectMode&&function(H){return x.isBuffer(H)||H instanceof b}(K);return ne&&!x.isBuffer(K)&&(K=function(H){return x.from(H)}(K)),typeof W=="function"&&(ee=W,W=null),ne?W="buffer":W||(W=ie.defaultEncoding),typeof ee!="function"&&(ee=C),ie.ended?function(H,I){var D=new Error("write after end");H.emit("error",D),o.nextTick(I,D)}(this,ee):(ne||function(H,I,D,z){var N=!0,B=!1;return D===null?B=new TypeError("May not write null values to stream"):typeof D=="string"||D===void 0||I.objectMode||(B=new TypeError("Invalid non-string/buffer chunk")),B&&(H.emit("error",B),o.nextTick(z,B),N=!1),N}(this,ie,K,ee))&&(ie.pendingcb++,X=function(H,I,D,z,N,B){if(!D){var Q=function(ce,ye,F){return ce.objectMode||ce.decodeStrings===!1||typeof ye!="string"||(ye=x.from(ye,F)),ye}(I,z,N);z!==Q&&(D=!0,N="buffer",z=Q)}var G=I.objectMode?1:z.length;I.length+=G;var ae=I.length<I.highWaterMark;if(ae||(I.needDrain=!0),I.writing||I.corked){var fe=I.lastBufferedRequest;I.lastBufferedRequest={chunk:z,encoding:N,isBuf:D,callback:B,next:null},fe?fe.next=I.lastBufferedRequest:I.bufferedRequest=I.lastBufferedRequest,I.bufferedRequestCount+=1}else P(H,I,!1,G,z,N,B);return ae}(this,ie,ne,K,W,ee)),X},O.prototype.cork=function(){this._writableState.corked++},O.prototype.uncork=function(){var K=this._writableState;K.corked&&(K.corked--,K.writing||K.corked||K.finished||K.bufferProcessing||!K.bufferedRequest||R(this,K))},O.prototype.setDefaultEncoding=function(K){if(typeof K=="string"&&(K=K.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((K+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+K);return this._writableState.defaultEncoding=K,this},Object.defineProperty(O.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),O.prototype._write=function(K,W,ee){ee(new Error("_write() is not implemented"))},O.prototype._writev=null,O.prototype.end=function(K,W,ee){var ie=this._writableState;typeof K=="function"?(ee=K,K=null,W=null):typeof W=="function"&&(ee=W,W=null),K!=null&&this.write(K,W),ie.corked&&(ie.corked=1,this.uncork()),ie.ending||ie.finished||function(X,ne,H){ne.ending=!0,Y(X,ne),H&&(ne.finished?o.nextTick(H):X.once("finish",H)),ne.ended=!0,X.writable=!1}(this,ie,ee)},Object.defineProperty(O.prototype,"destroyed",{get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(K){this._writableState&&(this._writableState.destroyed=K)}}),O.prototype.destroy=S.destroy,O.prototype._undestroy=S.undestroy,O.prototype._destroy=function(K,W){this.end(),W(K)}}).call(this,n(4),n(11).setImmediate,n(0))},function(e,t,n){(function(r,i,a){e.exports=function o(l,f,u){function h(_,x){if(!f[_]){if(!l[_]){var b=typeof _dereq_=="function"&&_dereq_;if(!x&&b)return b(_,!0);if(m)return m(_,!0);var S=new Error("Cannot find module '"+_+"'");throw S.code="MODULE_NOT_FOUND",S}var C=f[_]={exports:{}};l[_][0].call(C.exports,function(A){return h(l[_][1][A]||A)},C,C.exports,o,l,f,u)}return f[_].exports}for(var m=typeof _dereq_=="function"&&_dereq_,g=0;g<u.length;g++)h(u[g]);return h}({1:[function(o,l,f){l.exports=function(u){var h=u._SomePromiseArray;function m(g){var _=new h(g),x=_.promise();return _.setHowMany(1),_.setUnwrap(),_.init(),x}u.any=function(g){return m(g)},u.prototype.any=function(){return m(this)}}},{}],2:[function(o,l,f){var u;try{throw new Error}catch(C){u=C}var h=o("./schedule"),m=o("./queue"),g=o("./util");function _(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new m(16),this._normalQueue=new m(16),this._haveDrainedQueues=!1,this._trampolineEnabled=!0;var C=this;this.drainQueues=function(){C._drainQueues()},this._schedule=h}function x(C,A,O){this._lateQueue.push(C,A,O),this._queueTick()}function b(C,A,O){this._normalQueue.push(C,A,O),this._queueTick()}function S(C){this._normalQueue._pushOne(C),this._queueTick()}_.prototype.setScheduler=function(C){var A=this._schedule;return this._schedule=C,this._customScheduler=!0,A},_.prototype.hasCustomScheduler=function(){return this._customScheduler},_.prototype.enableTrampoline=function(){this._trampolineEnabled=!0},_.prototype.disableTrampolineIfNecessary=function(){g.hasDevTools&&(this._trampolineEnabled=!1)},_.prototype.haveItemsQueued=function(){return this._isTickUsed||this._haveDrainedQueues},_.prototype.fatalError=function(C,A){A?(r.stderr.write("Fatal "+(C instanceof Error?C.stack:C)+`
|
||
`),r.exit(2)):this.throwLater(C)},_.prototype.throwLater=function(C,A){if(arguments.length===1&&(A=C,C=function(){throw A}),typeof setTimeout<"u")setTimeout(function(){C(A)},0);else try{this._schedule(function(){C(A)})}catch{throw new Error(`No async scheduler available
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`)}},g.hasDevTools?(_.prototype.invokeLater=function(C,A,O){this._trampolineEnabled?x.call(this,C,A,O):this._schedule(function(){setTimeout(function(){C.call(A,O)},100)})},_.prototype.invoke=function(C,A,O){this._trampolineEnabled?b.call(this,C,A,O):this._schedule(function(){C.call(A,O)})},_.prototype.settlePromises=function(C){this._trampolineEnabled?S.call(this,C):this._schedule(function(){C._settlePromises()})}):(_.prototype.invokeLater=x,_.prototype.invoke=b,_.prototype.settlePromises=S),_.prototype._drainQueue=function(C){for(;C.length()>0;){var A=C.shift();if(typeof A=="function"){var O=C.shift(),P=C.shift();A.call(O,P)}else A._settlePromises()}},_.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,this._drainQueue(this._lateQueue)},_.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},_.prototype._reset=function(){this._isTickUsed=!1},l.exports=_,l.exports.firstLineError=u},{"./queue":26,"./schedule":29,"./util":36}],3:[function(o,l,f){l.exports=function(u,h,m,g){var _=!1,x=function(A,O){this._reject(O)},b=function(A,O){O.promiseRejectionQueued=!0,O.bindingPromise._then(x,x,null,this,A)},S=function(A,O){(50397184&this._bitField)==0&&this._resolveCallback(O.target)},C=function(A,O){O.promiseRejectionQueued||this._reject(A)};u.prototype.bind=function(A){_||(_=!0,u.prototype._propagateFrom=g.propagateFromFunction(),u.prototype._boundValue=g.boundValueFunction());var O=m(A),P=new u(h);P._propagateFrom(this,1);var j=this._target();if(P._setBoundTo(O),O instanceof u){var R={promiseRejectionQueued:!1,promise:P,target:j,bindingPromise:O};j._then(h,b,void 0,P,R),O._then(S,C,void 0,P,R),P._setOnCancel(O)}else P._resolveCallback(j);return P},u.prototype._setBoundTo=function(A){A!==void 0?(this._bitField=2097152|this._bitField,this._boundTo=A):this._bitField=-2097153&this._bitField},u.prototype._isBound=function(){return(2097152&this._bitField)==2097152},u.bind=function(A,O){return u.resolve(O).bind(A)}}},{}],4:[function(o,l,f){var u;typeof Promise<"u"&&(u=Promise);var h=o("./promise")();h.noConflict=function(){try{Promise===h&&(Promise=u)}catch{}return h},l.exports=h},{"./promise":22}],5:[function(o,l,f){var u=Object.create;if(u){var h=u(null),m=u(null);h[" size"]=m[" size"]=0}l.exports=function(g){var _=o("./util"),x=_.canEvaluate;function b(A){return function(O,P){var j;if(O!=null&&(j=O[P]),typeof j!="function"){var R="Object "+_.classString(O)+" has no method '"+_.toString(P)+"'";throw new g.TypeError(R)}return j}(A,this.pop()).apply(A,this)}function S(A){return A[this]}function C(A){var O=+this;return O<0&&(O=Math.max(0,O+A.length)),A[O]}_.isIdentifier,g.prototype.call=function(A){var O=[].slice.call(arguments,1);return O.push(A),this._then(b,void 0,void 0,O,void 0)},g.prototype.get=function(A){var O;if(typeof A=="number")O=C;else if(x){var P=(void 0)(A);O=P!==null?P:S}else O=S;return this._then(O,void 0,void 0,A,void 0)}}},{"./util":36}],6:[function(o,l,f){l.exports=function(u,h,m,g){var _=o("./util"),x=_.tryCatch,b=_.errorObj,S=u._async;u.prototype.break=u.prototype.cancel=function(){if(!g.cancellation())return this._warn("cancellation is disabled");for(var C=this,A=C;C._isCancellable();){if(!C._cancelBy(A)){A._isFollowing()?A._followee().cancel():A._cancelBranched();break}var O=C._cancellationParent;if(O==null||!O._isCancellable()){C._isFollowing()?C._followee().cancel():C._cancelBranched();break}C._isFollowing()&&C._followee().cancel(),C._setWillBeCancelled(),A=C,C=O}},u.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},u.prototype._enoughBranchesHaveCancelled=function(){return this._branchesRemainingToCancel===void 0||this._branchesRemainingToCancel<=0},u.prototype._cancelBy=function(C){return C===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),!!this._enoughBranchesHaveCancelled()&&(this._invokeOnCancel(),!0))},u.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},u.prototype._cancel=function(){this._isCancellable()&&(this._setCancelled(),S.invoke(this._cancelPromises,this,void 0))},u.prototype._cancelPromises=function(){this._length()>0&&this._settlePromises()},u.prototype._unsetOnCancel=function(){this._onCancelField=void 0},u.prototype._isCancellable=function(){return this.isPending()&&!this._isCancelled()},u.prototype.isCancellable=function(){return this.isPending()&&!this.isCancelled()},u.prototype._doInvokeOnCancel=function(C,A){if(_.isArray(C))for(var O=0;O<C.length;++O)this._doInvokeOnCancel(C[O],A);else if(C!==void 0)if(typeof C=="function"){if(!A){var P=x(C).call(this._boundValue());P===b&&(this._attachExtraTrace(P.e),S.throwLater(P.e))}}else C._resultCancelled(this)},u.prototype._invokeOnCancel=function(){var C=this._onCancel();this._unsetOnCancel(),S.invoke(this._doInvokeOnCancel,this,C)},u.prototype._invokeInternalOnCancel=function(){this._isCancellable()&&(this._doInvokeOnCancel(this._onCancel(),!0),this._unsetOnCancel())},u.prototype._resultCancelled=function(){this.cancel()}}},{"./util":36}],7:[function(o,l,f){l.exports=function(u){var h=o("./util"),m=o("./es5").keys,g=h.tryCatch,_=h.errorObj;return function(x,b,S){return function(C){var A=S._boundValue();e:for(var O=0;O<x.length;++O){var P=x[O];if(P===Error||P!=null&&P.prototype instanceof Error){if(C instanceof P)return g(b).call(A,C)}else if(typeof P=="function"){var j=g(P).call(A,C);if(j===_)return j;if(j)return g(b).call(A,C)}else if(h.isObject(C)){for(var R=m(P),U=0;U<R.length;++U){var V=R[U];if(P[V]!=C[V])continue e}return g(b).call(A,C)}}return u}}}},{"./es5":13,"./util":36}],8:[function(o,l,f){l.exports=function(u){var h=!1,m=[];function g(){this._trace=new g.CapturedTrace(_())}function _(){var x=m.length-1;if(x>=0)return m[x]}return u.prototype._promiseCreated=function(){},u.prototype._pushContext=function(){},u.prototype._popContext=function(){return null},u._peekContext=u.prototype._peekContext=function(){},g.prototype._pushContext=function(){this._trace!==void 0&&(this._trace._promiseCreated=null,m.push(this._trace))},g.prototype._popContext=function(){if(this._trace!==void 0){var x=m.pop(),b=x._promiseCreated;return x._promiseCreated=null,b}return null},g.CapturedTrace=null,g.create=function(){if(h)return new g},g.deactivateLongStackTraces=function(){},g.activateLongStackTraces=function(){var x=u.prototype._pushContext,b=u.prototype._popContext,S=u._peekContext,C=u.prototype._peekContext,A=u.prototype._promiseCreated;g.deactivateLongStackTraces=function(){u.prototype._pushContext=x,u.prototype._popContext=b,u._peekContext=S,u.prototype._peekContext=C,u.prototype._promiseCreated=A,h=!1},h=!0,u.prototype._pushContext=g.prototype._pushContext,u.prototype._popContext=g.prototype._popContext,u._peekContext=u.prototype._peekContext=_,u.prototype._promiseCreated=function(){var O=this._peekContext();O&&O._promiseCreated==null&&(O._promiseCreated=this)}},g}},{}],9:[function(o,l,f){l.exports=function(u,h){var m,g,_,x=u._getDomain,b=u._async,S=o("./errors").Warning,C=o("./util"),A=C.canAttachTrace,O=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,P=/\((?:timers\.js):\d+:\d+\)/,j=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,R=null,U=null,V=!1,Y=C.env("BLUEBIRD_DEBUG")!=0,K=!(C.env("BLUEBIRD_WARNINGS")==0||!Y&&!C.env("BLUEBIRD_WARNINGS")),W=!(C.env("BLUEBIRD_LONG_STACK_TRACES")==0||!Y&&!C.env("BLUEBIRD_LONG_STACK_TRACES")),ee=C.env("BLUEBIRD_W_FORGOTTEN_RETURN")!=0&&(K||!!C.env("BLUEBIRD_W_FORGOTTEN_RETURN"));u.prototype.suppressUnhandledRejections=function(){var _e=this._target();_e._bitField=-1048577&_e._bitField|524288},u.prototype._ensurePossibleRejectionHandled=function(){if((524288&this._bitField)==0){this._setRejectionIsUnhandled();var _e=this;setTimeout(function(){_e._notifyUnhandledRejection()},1)}},u.prototype._notifyUnhandledRejectionIsHandled=function(){de("rejectionHandled",m,void 0,this)},u.prototype._setReturnedNonUndefined=function(){this._bitField=268435456|this._bitField},u.prototype._returnedNonUndefined=function(){return(268435456&this._bitField)!=0},u.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var _e=this._settledValue();this._setUnhandledRejectionIsNotified(),de("unhandledRejection",g,_e,this)}},u.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=262144|this._bitField},u.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=-262145&this._bitField},u.prototype._isUnhandledRejectionNotified=function(){return(262144&this._bitField)>0},u.prototype._setRejectionIsUnhandled=function(){this._bitField=1048576|this._bitField},u.prototype._unsetRejectionIsUnhandled=function(){this._bitField=-1048577&this._bitField,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},u.prototype._isRejectionUnhandled=function(){return(1048576&this._bitField)>0},u.prototype._warn=function(_e,Se,ke){return te(_e,Se,ke||this)},u.onPossiblyUnhandledRejection=function(_e){var Se=x();g=typeof _e=="function"?Se===null?_e:C.domainBind(Se,_e):void 0},u.onUnhandledRejectionHandled=function(_e){var Se=x();m=typeof _e=="function"?Se===null?_e:C.domainBind(Se,_e):void 0};var ie=function(){};u.longStackTraces=function(){if(b.haveItemsQueued()&&!ze.longStackTraces)throw new Error(`cannot enable long stack traces after promises have been created
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);if(!ze.longStackTraces&&he()){var _e=u.prototype._captureStackTrace,Se=u.prototype._attachExtraTrace;ze.longStackTraces=!0,ie=function(){if(b.haveItemsQueued()&&!ze.longStackTraces)throw new Error(`cannot enable long stack traces after promises have been created
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);u.prototype._captureStackTrace=_e,u.prototype._attachExtraTrace=Se,h.deactivateLongStackTraces(),b.enableTrampoline(),ze.longStackTraces=!1},u.prototype._captureStackTrace=F,u.prototype._attachExtraTrace=q,h.activateLongStackTraces(),b.disableTrampolineIfNecessary()}},u.hasLongStackTraces=function(){return ze.longStackTraces&&he()};var X=function(){try{if(typeof CustomEvent=="function"){var _e=new CustomEvent("CustomEvent");return C.global.dispatchEvent(_e),function(Se,ke){var Ne=new CustomEvent(Se.toLowerCase(),{detail:ke,cancelable:!0});return!C.global.dispatchEvent(Ne)}}return typeof Event=="function"?(_e=new Event("CustomEvent"),C.global.dispatchEvent(_e),function(Se,ke){var Ne=new Event(Se.toLowerCase(),{cancelable:!0});return Ne.detail=ke,!C.global.dispatchEvent(Ne)}):((_e=document.createEvent("CustomEvent")).initCustomEvent("testingtheevent",!1,!0,{}),C.global.dispatchEvent(_e),function(Se,ke){var Ne=document.createEvent("CustomEvent");return Ne.initCustomEvent(Se.toLowerCase(),!1,!0,ke),!C.global.dispatchEvent(Ne)})}catch{}return function(){return!1}}(),ne=C.isNode?function(){return r.emit.apply(r,arguments)}:C.global?function(_e){var Se="on"+_e.toLowerCase(),ke=C.global[Se];return!!ke&&(ke.apply(C.global,[].slice.call(arguments,1)),!0)}:function(){return!1};function H(_e,Se){return{promise:Se}}var I={promiseCreated:H,promiseFulfilled:H,promiseRejected:H,promiseResolved:H,promiseCancelled:H,promiseChained:function(_e,Se,ke){return{promise:Se,child:ke}},warning:function(_e,Se){return{warning:Se}},unhandledRejection:function(_e,Se,ke){return{reason:Se,promise:ke}},rejectionHandled:H},D=function(_e){var Se=!1;try{Se=ne.apply(null,arguments)}catch(Ne){b.throwLater(Ne),Se=!0}var ke=!1;try{ke=X(_e,I[_e].apply(null,arguments))}catch(Ne){b.throwLater(Ne),ke=!0}return ke||Se};function z(){return!1}function N(_e,Se,ke){var Ne=this;try{_e(Se,ke,function(je){if(typeof je!="function")throw new TypeError("onCancel must be a function, got: "+C.toString(je));Ne._attachCancellationCallback(je)})}catch(je){return je}}function B(_e){if(!this._isCancellable())return this;var Se=this._onCancel();Se!==void 0?C.isArray(Se)?Se.push(_e):this._setOnCancel([Se,_e]):this._setOnCancel(_e)}function Q(){return this._onCancelField}function G(_e){this._onCancelField=_e}function ae(){this._cancellationParent=void 0,this._onCancelField=void 0}function fe(_e,Se){if((1&Se)!=0){this._cancellationParent=_e;var ke=_e._branchesRemainingToCancel;ke===void 0&&(ke=0),_e._branchesRemainingToCancel=ke+1}(2&Se)!=0&&_e._isBound()&&this._setBoundTo(_e._boundTo)}u.config=function(_e){if("longStackTraces"in(_e=Object(_e))&&(_e.longStackTraces?u.longStackTraces():!_e.longStackTraces&&u.hasLongStackTraces()&&ie()),"warnings"in _e){var Se=_e.warnings;ze.warnings=!!Se,ee=ze.warnings,C.isObject(Se)&&"wForgottenReturn"in Se&&(ee=!!Se.wForgottenReturn)}if("cancellation"in _e&&_e.cancellation&&!ze.cancellation){if(b.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");u.prototype._clearCancellationData=ae,u.prototype._propagateFrom=fe,u.prototype._onCancel=Q,u.prototype._setOnCancel=G,u.prototype._attachCancellationCallback=B,u.prototype._execute=N,ce=fe,ze.cancellation=!0}return"monitoring"in _e&&(_e.monitoring&&!ze.monitoring?(ze.monitoring=!0,u.prototype._fireEvent=D):!_e.monitoring&&ze.monitoring&&(ze.monitoring=!1,u.prototype._fireEvent=z)),u},u.prototype._fireEvent=z,u.prototype._execute=function(_e,Se,ke){try{_e(Se,ke)}catch(Ne){return Ne}},u.prototype._onCancel=function(){},u.prototype._setOnCancel=function(_e){},u.prototype._attachCancellationCallback=function(_e){},u.prototype._captureStackTrace=function(){},u.prototype._attachExtraTrace=function(){},u.prototype._clearCancellationData=function(){},u.prototype._propagateFrom=function(_e,Se){};var ce=function(_e,Se){(2&Se)!=0&&_e._isBound()&&this._setBoundTo(_e._boundTo)};function ye(){var _e=this._boundTo;return _e!==void 0&&_e instanceof u?_e.isFulfilled()?_e.value():void 0:_e}function F(){this._trace=new He(this._peekContext())}function q(_e,Se){if(A(_e)){var ke=this._trace;if(ke!==void 0&&Se&&(ke=ke._parent),ke!==void 0)ke.attachExtraTrace(_e);else if(!_e.__stackCleaned__){var Ne=J(_e);C.notEnumerableProp(_e,"stack",Ne.message+`
|
||
`+Ne.stack.join(`
|
||
`)),C.notEnumerableProp(_e,"__stackCleaned__",!0)}}}function te(_e,Se,ke){if(ze.warnings){var Ne,je=new S(_e);if(Se)ke._attachExtraTrace(je);else if(ze.longStackTraces&&(Ne=u._peekContext()))Ne.attachExtraTrace(je);else{var Fe=J(je);je.stack=Fe.message+`
|
||
`+Fe.stack.join(`
|
||
`)}D("warning",je)||se(je,"",!0)}}function ue(_e){for(var Se=[],ke=0;ke<_e.length;++ke){var Ne=_e[ke],je=Ne===" (No stack trace)"||R.test(Ne),Fe=je&&xe(Ne);je&&!Fe&&(V&&Ne.charAt(0)!==" "&&(Ne=" "+Ne),Se.push(Ne))}return Se}function J(_e){var Se=_e.stack,ke=_e.toString();return Se=typeof Se=="string"&&Se.length>0?function(Ne){for(var je=Ne.stack.replace(/\s+$/g,"").split(`
|
||
`),Fe=0;Fe<je.length;++Fe){var Ge=je[Fe];if(Ge===" (No stack trace)"||R.test(Ge))break}return Fe>0&&Ne.name!="SyntaxError"&&(je=je.slice(Fe)),je}(_e):[" (No stack trace)"],{message:ke,stack:_e.name=="SyntaxError"?Se:ue(Se)}}function se(_e,Se,ke){if(typeof console<"u"){var Ne;if(C.isObject(_e)){var je=_e.stack;Ne=Se+U(je,_e)}else Ne=Se+String(_e);typeof _=="function"?_(Ne,ke):typeof console.log!="function"&&typeof console.log!="object"||console.log(Ne)}}function de(_e,Se,ke,Ne){var je=!1;try{typeof Se=="function"&&(je=!0,_e==="rejectionHandled"?Se(Ne):Se(ke,Ne))}catch(Fe){b.throwLater(Fe)}_e==="unhandledRejection"?D(_e,ke,Ne)||je||se(ke,"Unhandled rejection "):D(_e,Ne)}function ve(_e){var Se;if(typeof _e=="function")Se="[function "+(_e.name||"anonymous")+"]";else{if(Se=_e&&typeof _e.toString=="function"?_e.toString():C.toString(_e),/\[object [a-zA-Z0-9$_]+\]/.test(Se))try{Se=JSON.stringify(_e)}catch{}Se.length===0&&(Se="(empty array)")}return"(<"+function(ke){return ke.length<41?ke:ke.substr(0,38)+"..."}(Se)+">, no stack trace)"}function he(){return typeof $e=="function"}var xe=function(){return!1},Oe=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;function Le(_e){var Se=_e.match(Oe);if(Se)return{fileName:Se[1],line:parseInt(Se[2],10)}}function He(_e){this._parent=_e,this._promisesCreated=0;var Se=this._length=1+(_e===void 0?0:_e._length);$e(this,He),Se>32&&this.uncycle()}C.inherits(He,Error),h.CapturedTrace=He,He.prototype.uncycle=function(){var _e=this._length;if(!(_e<2)){for(var Se=[],ke={},Ne=0,je=this;je!==void 0;++Ne)Se.push(je),je=je._parent;for(Ne=(_e=this._length=Ne)-1;Ne>=0;--Ne){var Fe=Se[Ne].stack;ke[Fe]===void 0&&(ke[Fe]=Ne)}for(Ne=0;Ne<_e;++Ne){var Ge=ke[Se[Ne].stack];if(Ge!==void 0&&Ge!==Ne){Ge>0&&(Se[Ge-1]._parent=void 0,Se[Ge-1]._length=1),Se[Ne]._parent=void 0,Se[Ne]._length=1;var Xe=Ne>0?Se[Ne-1]:this;Ge<_e-1?(Xe._parent=Se[Ge+1],Xe._parent.uncycle(),Xe._length=Xe._parent._length+1):(Xe._parent=void 0,Xe._length=1);for(var ft=Xe._length+1,st=Ne-2;st>=0;--st)Se[st]._length=ft,ft++;return}}}},He.prototype.attachExtraTrace=function(_e){if(!_e.__stackCleaned__){this.uncycle();for(var Se=J(_e),ke=Se.message,Ne=[Se.stack],je=this;je!==void 0;)Ne.push(ue(je.stack.split(`
|
||
`))),je=je._parent;(function(Fe){for(var Ge=Fe[0],Xe=1;Xe<Fe.length;++Xe){for(var ft=Fe[Xe],st=Ge.length-1,wt=Ge[st],kt=-1,Dt=ft.length-1;Dt>=0;--Dt)if(ft[Dt]===wt){kt=Dt;break}for(Dt=kt;Dt>=0;--Dt){var It=ft[Dt];if(Ge[st]!==It)break;Ge.pop(),st--}Ge=ft}})(Ne),function(Fe){for(var Ge=0;Ge<Fe.length;++Ge)(Fe[Ge].length===0||Ge+1<Fe.length&&Fe[Ge][0]===Fe[Ge+1][0])&&(Fe.splice(Ge,1),Ge--)}(Ne),C.notEnumerableProp(_e,"stack",function(Fe,Ge){for(var Xe=0;Xe<Ge.length-1;++Xe)Ge[Xe].push("From previous event:"),Ge[Xe]=Ge[Xe].join(`
|
||
`);return Xe<Ge.length&&(Ge[Xe]=Ge[Xe].join(`
|
||
`)),Fe+`
|
||
`+Ge.join(`
|
||
`)}(ke,Ne)),C.notEnumerableProp(_e,"__stackCleaned__",!0)}};var $e=function(){var _e=/^\s*at\s*/,Se=function(Fe,Ge){return typeof Fe=="string"?Fe:Ge.name!==void 0&&Ge.message!==void 0?Ge.toString():ve(Ge)};if(typeof Error.stackTraceLimit=="number"&&typeof Error.captureStackTrace=="function"){Error.stackTraceLimit+=6,R=_e,U=Se;var ke=Error.captureStackTrace;return xe=function(Fe){return O.test(Fe)},function(Fe,Ge){Error.stackTraceLimit+=6,ke(Fe,Ge),Error.stackTraceLimit-=6}}var Ne,je=new Error;if(typeof je.stack=="string"&&je.stack.split(`
|
||
`)[0].indexOf("stackDetection@")>=0)return R=/@/,U=Se,V=!0,function(Fe){Fe.stack=new Error().stack};try{throw new Error}catch(Fe){Ne="stack"in Fe}return"stack"in je||!Ne||typeof Error.stackTraceLimit!="number"?(U=function(Fe,Ge){return typeof Fe=="string"?Fe:typeof Ge!="object"&&typeof Ge!="function"||Ge.name===void 0||Ge.message===void 0?ve(Ge):Ge.toString()},null):(R=_e,U=Se,function(Fe){Error.stackTraceLimit+=6;try{throw new Error}catch(Ge){Fe.stack=Ge.stack}Error.stackTraceLimit-=6})}();typeof console<"u"&&console.warn!==void 0&&(_=function(_e){console.warn(_e)},C.isNode&&r.stderr.isTTY?_=function(_e,Se){var ke=Se?"\x1B[33m":"\x1B[31m";console.warn(ke+_e+`\x1B[0m
|
||
`)}:C.isNode||typeof new Error().stack!="string"||(_=function(_e,Se){console.warn("%c"+_e,Se?"color: darkorange":"color: red")}));var ze={warnings:K,longStackTraces:!1,cancellation:!1,monitoring:!1};return W&&u.longStackTraces(),{longStackTraces:function(){return ze.longStackTraces},warnings:function(){return ze.warnings},cancellation:function(){return ze.cancellation},monitoring:function(){return ze.monitoring},propagateFromFunction:function(){return ce},boundValueFunction:function(){return ye},checkForgottenReturns:function(_e,Se,ke,Ne,je){if(_e===void 0&&Se!==null&&ee){if(je!==void 0&&je._returnedNonUndefined()||(65535&Ne._bitField)==0)return;ke&&(ke+=" ");var Fe="",Ge="";if(Se._trace){for(var Xe=Se._trace.stack.split(`
|
||
`),ft=ue(Xe),st=ft.length-1;st>=0;--st){var wt=ft[st];if(!P.test(wt)){var kt=wt.match(j);kt&&(Fe="at "+kt[1]+":"+kt[2]+":"+kt[3]+" ");break}}if(ft.length>0){var Dt=ft[0];for(st=0;st<Xe.length;++st)if(Xe[st]===Dt){st>0&&(Ge=`
|
||
`+Xe[st-1]);break}}}var It="a promise was created in a "+ke+"handler "+Fe+"but was not returned from it, see http://goo.gl/rRqMUw"+Ge;Ne._warn(It,!0,Se)}},setBounds:function(_e,Se){if(he()){for(var ke,Ne,je=_e.stack.split(`
|
||
`),Fe=Se.stack.split(`
|
||
`),Ge=-1,Xe=-1,ft=0;ft<je.length;++ft)if(st=Le(je[ft])){ke=st.fileName,Ge=st.line;break}for(ft=0;ft<Fe.length;++ft){var st;if(st=Le(Fe[ft])){Ne=st.fileName,Xe=st.line;break}}Ge<0||Xe<0||!ke||!Ne||ke!==Ne||Ge>=Xe||(xe=function(wt){if(O.test(wt))return!0;var kt=Le(wt);return!!(kt&&kt.fileName===ke&&Ge<=kt.line&&kt.line<=Xe)})}},warn:te,deprecated:function(_e,Se){var ke=_e+" is deprecated and will be removed in a future version.";return Se&&(ke+=" Use "+Se+" instead."),te(ke)},CapturedTrace:He,fireDomEvent:X,fireGlobalEvent:ne}}},{"./errors":12,"./util":36}],10:[function(o,l,f){l.exports=function(u){function h(){return this.value}function m(){throw this.reason}u.prototype.return=u.prototype.thenReturn=function(g){return g instanceof u&&g.suppressUnhandledRejections(),this._then(h,void 0,void 0,{value:g},void 0)},u.prototype.throw=u.prototype.thenThrow=function(g){return this._then(m,void 0,void 0,{reason:g},void 0)},u.prototype.catchThrow=function(g){if(arguments.length<=1)return this._then(void 0,m,void 0,{reason:g},void 0);var _=arguments[1];return this.caught(g,function(){throw _})},u.prototype.catchReturn=function(g){if(arguments.length<=1)return g instanceof u&&g.suppressUnhandledRejections(),this._then(void 0,h,void 0,{value:g},void 0);var _=arguments[1];return _ instanceof u&&_.suppressUnhandledRejections(),this.caught(g,function(){return _})}}},{}],11:[function(o,l,f){l.exports=function(u,h){var m=u.reduce,g=u.all;function _(){return g(this)}u.prototype.each=function(x){return m(this,x,h,0)._then(_,void 0,void 0,this,void 0)},u.prototype.mapSeries=function(x){return m(this,x,h,h)},u.each=function(x,b){return m(x,b,h,0)._then(_,void 0,void 0,x,void 0)},u.mapSeries=function(x,b){return m(x,b,h,h)}}},{}],12:[function(o,l,f){var u,h,m=o("./es5"),g=m.freeze,_=o("./util"),x=_.inherits,b=_.notEnumerableProp;function S(K,W){function ee(ie){if(!(this instanceof ee))return new ee(ie);b(this,"message",typeof ie=="string"?ie:W),b(this,"name",K),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)}return x(ee,Error),ee}var C=S("Warning","warning"),A=S("CancellationError","cancellation error"),O=S("TimeoutError","timeout error"),P=S("AggregateError","aggregate error");try{u=TypeError,h=RangeError}catch{u=S("TypeError","type error"),h=S("RangeError","range error")}for(var j="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),R=0;R<j.length;++R)typeof Array.prototype[j[R]]=="function"&&(P.prototype[j[R]]=Array.prototype[j[R]]);m.defineProperty(P.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0}),P.prototype.isOperational=!0;var U=0;function V(K){if(!(this instanceof V))return new V(K);b(this,"name","OperationalError"),b(this,"message",K),this.cause=K,this.isOperational=!0,K instanceof Error?(b(this,"message",K.message),b(this,"stack",K.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}P.prototype.toString=function(){var K=Array(4*U+1).join(" "),W=`
|
||
`+K+`AggregateError of:
|
||
`;U++,K=Array(4*U+1).join(" ");for(var ee=0;ee<this.length;++ee){for(var ie=this[ee]===this?"[Circular AggregateError]":this[ee]+"",X=ie.split(`
|
||
`),ne=0;ne<X.length;++ne)X[ne]=K+X[ne];W+=(ie=X.join(`
|
||
`))+`
|
||
`}return U--,W},x(V,Error);var Y=Error.__BluebirdErrorTypes__;Y||(Y=g({CancellationError:A,TimeoutError:O,OperationalError:V,RejectionError:V,AggregateError:P}),m.defineProperty(Error,"__BluebirdErrorTypes__",{value:Y,writable:!1,enumerable:!1,configurable:!1})),l.exports={Error,TypeError:u,RangeError:h,CancellationError:Y.CancellationError,OperationalError:Y.OperationalError,TimeoutError:Y.TimeoutError,AggregateError:Y.AggregateError,Warning:C}},{"./es5":13,"./util":36}],13:[function(o,l,f){var u=function(){return this===void 0}();if(u)l.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:u,propertyIsWritable:function(x,b){var S=Object.getOwnPropertyDescriptor(x,b);return!(S&&!S.writable&&!S.set)}};else{var h={}.hasOwnProperty,m={}.toString,g={}.constructor.prototype,_=function(x){var b=[];for(var S in x)h.call(x,S)&&b.push(S);return b};l.exports={isArray:function(x){try{return m.call(x)==="[object Array]"}catch{return!1}},keys:_,names:_,defineProperty:function(x,b,S){return x[b]=S.value,x},getDescriptor:function(x,b){return{value:x[b]}},freeze:function(x){return x},getPrototypeOf:function(x){try{return Object(x).constructor.prototype}catch{return g}},isES5:u,propertyIsWritable:function(){return!0}}}},{}],14:[function(o,l,f){l.exports=function(u,h){var m=u.map;u.prototype.filter=function(g,_){return m(this,g,_,h)},u.filter=function(g,_,x){return m(g,_,x,h)}}},{}],15:[function(o,l,f){l.exports=function(u,h,m){var g=o("./util"),_=u.CancellationError,x=g.errorObj,b=o("./catch_filter")(m);function S(R,U,V){this.promise=R,this.type=U,this.handler=V,this.called=!1,this.cancelPromise=null}function C(R){this.finallyHandler=R}function A(R,U){return R.cancelPromise!=null&&(arguments.length>1?R.cancelPromise._reject(U):R.cancelPromise._cancel(),R.cancelPromise=null,!0)}function O(){return j.call(this,this.promise._target()._settledValue())}function P(R){if(!A(this,R))return x.e=R,x}function j(R){var U=this.promise,V=this.handler;if(!this.called){this.called=!0;var Y=this.isFinallyHandler()?V.call(U._boundValue()):V.call(U._boundValue(),R);if(Y===m)return Y;if(Y!==void 0){U._setReturnedNonUndefined();var K=h(Y,U);if(K instanceof u){if(this.cancelPromise!=null){if(K._isCancelled()){var W=new _("late cancellation observer");return U._attachExtraTrace(W),x.e=W,x}K.isPending()&&K._attachCancellationCallback(new C(this))}return K._then(O,P,void 0,this,void 0)}}}return U.isRejected()?(A(this),x.e=R,x):(A(this),R)}return S.prototype.isFinallyHandler=function(){return this.type===0},C.prototype._resultCancelled=function(){A(this.finallyHandler)},u.prototype._passThrough=function(R,U,V,Y){return typeof R!="function"?this.then():this._then(V,Y,void 0,new S(this,U,R),void 0)},u.prototype.lastly=u.prototype.finally=function(R){return this._passThrough(R,0,j,j)},u.prototype.tap=function(R){return this._passThrough(R,1,j)},u.prototype.tapCatch=function(R){var U=arguments.length;if(U===1)return this._passThrough(R,1,void 0,j);var V,Y=new Array(U-1),K=0;for(V=0;V<U-1;++V){var W=arguments[V];if(!g.isObject(W))return u.reject(new TypeError("tapCatch statement predicate: expecting an object but got "+g.classString(W)));Y[K++]=W}Y.length=K;var ee=arguments[V];return this._passThrough(b(Y,ee,this),1,void 0,j)},S}},{"./catch_filter":7,"./util":36}],16:[function(o,l,f){l.exports=function(u,h,m,g,_,x){var b=o("./errors").TypeError,S=o("./util"),C=S.errorObj,A=S.tryCatch,O=[];function P(j,R,U,V){if(x.cancellation()){var Y=new u(m),K=this._finallyPromise=new u(m);this._promise=Y.lastly(function(){return K}),Y._captureStackTrace(),Y._setOnCancel(this)}else(this._promise=new u(m))._captureStackTrace();this._stack=V,this._generatorFunction=j,this._receiver=R,this._generator=void 0,this._yieldHandlers=typeof U=="function"?[U].concat(O):O,this._yieldedPromise=null,this._cancellationPhase=!1}S.inherits(P,_),P.prototype._isResolved=function(){return this._promise===null},P.prototype._cleanup=function(){this._promise=this._generator=null,x.cancellation()&&this._finallyPromise!==null&&(this._finallyPromise._fulfill(),this._finallyPromise=null)},P.prototype._promiseCancelled=function(){if(!this._isResolved()){var j;if(this._generator.return!==void 0)this._promise._pushContext(),j=A(this._generator.return).call(this._generator,void 0),this._promise._popContext();else{var R=new u.CancellationError("generator .return() sentinel");u.coroutine.returnSentinel=R,this._promise._attachExtraTrace(R),this._promise._pushContext(),j=A(this._generator.throw).call(this._generator,R),this._promise._popContext()}this._cancellationPhase=!0,this._yieldedPromise=null,this._continue(j)}},P.prototype._promiseFulfilled=function(j){this._yieldedPromise=null,this._promise._pushContext();var R=A(this._generator.next).call(this._generator,j);this._promise._popContext(),this._continue(R)},P.prototype._promiseRejected=function(j){this._yieldedPromise=null,this._promise._attachExtraTrace(j),this._promise._pushContext();var R=A(this._generator.throw).call(this._generator,j);this._promise._popContext(),this._continue(R)},P.prototype._resultCancelled=function(){if(this._yieldedPromise instanceof u){var j=this._yieldedPromise;this._yieldedPromise=null,j.cancel()}},P.prototype.promise=function(){return this._promise},P.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._promiseFulfilled(void 0)},P.prototype._continue=function(j){var R=this._promise;if(j===C)return this._cleanup(),this._cancellationPhase?R.cancel():R._rejectCallback(j.e,!1);var U=j.value;if(j.done===!0)return this._cleanup(),this._cancellationPhase?R.cancel():R._resolveCallback(U);var V=g(U,this._promise);if(V instanceof u||(V=function(K,W,ee){for(var ie=0;ie<W.length;++ie){ee._pushContext();var X=A(W[ie])(K);if(ee._popContext(),X===C){ee._pushContext();var ne=u.reject(C.e);return ee._popContext(),ne}var H=g(X,ee);if(H instanceof u)return H}return null}(V,this._yieldHandlers,this._promise))!==null){var Y=(V=V._target())._bitField;(50397184&Y)==0?(this._yieldedPromise=V,V._proxy(this,null)):(33554432&Y)!=0?u._async.invoke(this._promiseFulfilled,this,V._value()):(16777216&Y)!=0?u._async.invoke(this._promiseRejected,this,V._reason()):this._promiseCancelled()}else this._promiseRejected(new b(`A value %s was yielded that could not be treated as a promise
|
||
|
||
See http://goo.gl/MqrFmX
|
||
|
||
`.replace("%s",String(U))+`From coroutine:
|
||
`+this._stack.split(`
|
||
`).slice(1,-7).join(`
|
||
`)))},u.coroutine=function(j,R){if(typeof j!="function")throw new b(`generatorFunction must be a function
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);var U=Object(R).yieldHandler,V=P,Y=new Error().stack;return function(){var K=j.apply(this,arguments),W=new V(void 0,void 0,U,Y),ee=W.promise();return W._generator=K,W._promiseFulfilled(void 0),ee}},u.coroutine.addYieldHandler=function(j){if(typeof j!="function")throw new b("expecting a function but got "+S.classString(j));O.push(j)},u.spawn=function(j){if(x.deprecated("Promise.spawn()","Promise.coroutine()"),typeof j!="function")return h(`generatorFunction must be a function
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);var R=new P(j,this),U=R.promise();return R._run(u.spawn),U}}},{"./errors":12,"./util":36}],17:[function(o,l,f){l.exports=function(u,h,m,g,_,x){var b=o("./util");b.canEvaluate,b.tryCatch,b.errorObj,u.join=function(){var S,C=arguments.length-1;C>0&&typeof arguments[C]=="function"&&(S=arguments[C]);var A=[].slice.call(arguments);S&&A.pop();var O=new h(A).promise();return S!==void 0?O.spread(S):O}}},{"./util":36}],18:[function(o,l,f){l.exports=function(u,h,m,g,_,x){var b=u._getDomain,S=o("./util"),C=S.tryCatch,A=S.errorObj,O=u._async;function P(R,U,V,Y){this.constructor$(R),this._promise._captureStackTrace();var K=b();this._callback=K===null?U:S.domainBind(K,U),this._preservedValues=Y===_?new Array(this.length()):null,this._limit=V,this._inFlight=0,this._queue=[],O.invoke(this._asyncInit,this,void 0)}function j(R,U,V,Y){if(typeof U!="function")return m("expecting a function but got "+S.classString(U));var K=0;if(V!==void 0){if(typeof V!="object"||V===null)return u.reject(new TypeError("options argument must be an object but it is "+S.classString(V)));if(typeof V.concurrency!="number")return u.reject(new TypeError("'concurrency' must be a number but it is "+S.classString(V.concurrency)));K=V.concurrency}return new P(R,U,K=typeof K=="number"&&isFinite(K)&&K>=1?K:0,Y).promise()}S.inherits(P,h),P.prototype._asyncInit=function(){this._init$(void 0,-2)},P.prototype._init=function(){},P.prototype._promiseFulfilled=function(R,U){var V=this._values,Y=this.length(),K=this._preservedValues,W=this._limit;if(U<0){if(V[U=-1*U-1]=R,W>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(W>=1&&this._inFlight>=W)return V[U]=R,this._queue.push(U),!1;K!==null&&(K[U]=R);var ee=this._promise,ie=this._callback,X=ee._boundValue();ee._pushContext();var ne=C(ie).call(X,R,U,Y),H=ee._popContext();if(x.checkForgottenReturns(ne,H,K!==null?"Promise.filter":"Promise.map",ee),ne===A)return this._reject(ne.e),!0;var I=g(ne,this._promise);if(I instanceof u){var D=(I=I._target())._bitField;if((50397184&D)==0)return W>=1&&this._inFlight++,V[U]=I,I._proxy(this,-1*(U+1)),!1;if((33554432&D)==0)return(16777216&D)!=0?(this._reject(I._reason()),!0):(this._cancel(),!0);ne=I._value()}V[U]=ne}return++this._totalResolved>=Y&&(K!==null?this._filter(V,K):this._resolve(V),!0)},P.prototype._drainQueue=function(){for(var R=this._queue,U=this._limit,V=this._values;R.length>0&&this._inFlight<U;){if(this._isResolved())return;var Y=R.pop();this._promiseFulfilled(V[Y],Y)}},P.prototype._filter=function(R,U){for(var V=U.length,Y=new Array(V),K=0,W=0;W<V;++W)R[W]&&(Y[K++]=U[W]);Y.length=K,this._resolve(Y)},P.prototype.preservedValues=function(){return this._preservedValues},u.prototype.map=function(R,U){return j(this,R,U,null)},u.map=function(R,U,V,Y){return j(R,U,V,Y)}}},{"./util":36}],19:[function(o,l,f){l.exports=function(u,h,m,g,_){var x=o("./util"),b=x.tryCatch;u.method=function(S){if(typeof S!="function")throw new u.TypeError("expecting a function but got "+x.classString(S));return function(){var C=new u(h);C._captureStackTrace(),C._pushContext();var A=b(S).apply(this,arguments),O=C._popContext();return _.checkForgottenReturns(A,O,"Promise.method",C),C._resolveFromSyncValue(A),C}},u.attempt=u.try=function(S){if(typeof S!="function")return g("expecting a function but got "+x.classString(S));var C,A=new u(h);if(A._captureStackTrace(),A._pushContext(),arguments.length>1){_.deprecated("calling Promise.try with more than 1 argument");var O=arguments[1],P=arguments[2];C=x.isArray(O)?b(S).apply(P,O):b(S).call(P,O)}else C=b(S)();var j=A._popContext();return _.checkForgottenReturns(C,j,"Promise.try",A),A._resolveFromSyncValue(C),A},u.prototype._resolveFromSyncValue=function(S){S===x.errorObj?this._rejectCallback(S.e,!1):this._resolveCallback(S,!0)}}},{"./util":36}],20:[function(o,l,f){var u=o("./util"),h=u.maybeWrapAsError,m=o("./errors").OperationalError,g=o("./es5"),_=/^(?:name|message|stack|cause)$/;function x(b){var S;if(function(P){return P instanceof Error&&g.getPrototypeOf(P)===Error.prototype}(b)){(S=new m(b)).name=b.name,S.message=b.message,S.stack=b.stack;for(var C=g.keys(b),A=0;A<C.length;++A){var O=C[A];_.test(O)||(S[O]=b[O])}return S}return u.markAsOriginatingFromRejection(b),b}l.exports=function(b,S){return function(C,A){if(b!==null){if(C){var O=x(h(C));b._attachExtraTrace(O),b._reject(O)}else if(S){var P=[].slice.call(arguments,1);b._fulfill(P)}else b._fulfill(A);b=null}}}},{"./errors":12,"./es5":13,"./util":36}],21:[function(o,l,f){l.exports=function(u){var h=o("./util"),m=u._async,g=h.tryCatch,_=h.errorObj;function x(C,A){if(!h.isArray(C))return b.call(this,C,A);var O=g(A).apply(this._boundValue(),[null].concat(C));O===_&&m.throwLater(O.e)}function b(C,A){var O=this._boundValue(),P=C===void 0?g(A).call(O,null):g(A).call(O,null,C);P===_&&m.throwLater(P.e)}function S(C,A){if(!C){var O=new Error(C+"");O.cause=C,C=O}var P=g(A).call(this._boundValue(),C);P===_&&m.throwLater(P.e)}u.prototype.asCallback=u.prototype.nodeify=function(C,A){if(typeof C=="function"){var O=b;A!==void 0&&Object(A).spread&&(O=x),this._then(O,S,void 0,this,C)}return this}}},{"./util":36}],22:[function(o,l,f){l.exports=function(){var u=function(){return new P(`circular promise resolution chain
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`)},h=function(){return new z.PromiseInspection(this._target())},m=function(G){return z.reject(new P(G))};function g(){}var _,x={},b=o("./util");_=b.isNode?function(){var G=r.domain;return G===void 0&&(G=null),G}:function(){return null},b.notEnumerableProp(z,"_getDomain",_);var S=o("./es5"),C=o("./async"),A=new C;S.defineProperty(z,"_async",{value:A});var O=o("./errors"),P=z.TypeError=O.TypeError;z.RangeError=O.RangeError;var j=z.CancellationError=O.CancellationError;z.TimeoutError=O.TimeoutError,z.OperationalError=O.OperationalError,z.RejectionError=O.OperationalError,z.AggregateError=O.AggregateError;var R=function(){},U={},V={},Y=o("./thenables")(z,R),K=o("./promise_array")(z,R,Y,m,g),W=o("./context")(z),ee=W.create,ie=o("./debuggability")(z,W),X=(ie.CapturedTrace,o("./finally")(z,Y,V)),ne=o("./catch_filter")(V),H=o("./nodeback"),I=b.errorObj,D=b.tryCatch;function z(G){G!==R&&function(ae,fe){if(ae==null||ae.constructor!==z)throw new P(`the promise constructor cannot be invoked directly
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);if(typeof fe!="function")throw new P("expecting a function but got "+b.classString(fe))}(this,G),this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._resolveFromExecutor(G),this._promiseCreated(),this._fireEvent("promiseCreated",this)}function N(G){this.promise._resolveCallback(G)}function B(G){this.promise._rejectCallback(G,!1)}function Q(G){var ae=new z(R);ae._fulfillmentHandler0=G,ae._rejectionHandler0=G,ae._promise0=G,ae._receiver0=G}return z.prototype.toString=function(){return"[object Promise]"},z.prototype.caught=z.prototype.catch=function(G){var ae=arguments.length;if(ae>1){var fe,ce=new Array(ae-1),ye=0;for(fe=0;fe<ae-1;++fe){var F=arguments[fe];if(!b.isObject(F))return m("Catch statement predicate: expecting an object but got "+b.classString(F));ce[ye++]=F}return ce.length=ye,G=arguments[fe],this.then(void 0,ne(ce,G,this))}return this.then(void 0,G)},z.prototype.reflect=function(){return this._then(h,h,void 0,this,void 0)},z.prototype.then=function(G,ae){if(ie.warnings()&&arguments.length>0&&typeof G!="function"&&typeof ae!="function"){var fe=".then() only accepts functions but was passed: "+b.classString(G);arguments.length>1&&(fe+=", "+b.classString(ae)),this._warn(fe)}return this._then(G,ae,void 0,void 0,void 0)},z.prototype.done=function(G,ae){this._then(G,ae,void 0,void 0,void 0)._setIsFinal()},z.prototype.spread=function(G){return typeof G!="function"?m("expecting a function but got "+b.classString(G)):this.all()._then(G,void 0,void 0,U,void 0)},z.prototype.toJSON=function(){var G={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(G.fulfillmentValue=this.value(),G.isFulfilled=!0):this.isRejected()&&(G.rejectionReason=this.reason(),G.isRejected=!0),G},z.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new K(this).promise()},z.prototype.error=function(G){return this.caught(b.originatesFromRejection,G)},z.getNewLibraryCopy=l.exports,z.is=function(G){return G instanceof z},z.fromNode=z.fromCallback=function(G){var ae=new z(R);ae._captureStackTrace();var fe=arguments.length>1&&!!Object(arguments[1]).multiArgs,ce=D(G)(H(ae,fe));return ce===I&&ae._rejectCallback(ce.e,!0),ae._isFateSealed()||ae._setAsyncGuaranteed(),ae},z.all=function(G){return new K(G).promise()},z.cast=function(G){var ae=Y(G);return ae instanceof z||((ae=new z(R))._captureStackTrace(),ae._setFulfilled(),ae._rejectionHandler0=G),ae},z.resolve=z.fulfilled=z.cast,z.reject=z.rejected=function(G){var ae=new z(R);return ae._captureStackTrace(),ae._rejectCallback(G,!0),ae},z.setScheduler=function(G){if(typeof G!="function")throw new P("expecting a function but got "+b.classString(G));return A.setScheduler(G)},z.prototype._then=function(G,ae,fe,ce,ye){var F=ye!==void 0,q=F?ye:new z(R),te=this._target(),ue=te._bitField;F||(q._propagateFrom(this,3),q._captureStackTrace(),ce===void 0&&(2097152&this._bitField)!=0&&(ce=(50397184&ue)!=0?this._boundValue():te===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,q));var J=_();if((50397184&ue)!=0){var se,de,ve=te._settlePromiseCtx;(33554432&ue)!=0?(de=te._rejectionHandler0,se=G):(16777216&ue)!=0?(de=te._fulfillmentHandler0,se=ae,te._unsetRejectionIsUnhandled()):(ve=te._settlePromiseLateCancellationObserver,de=new j("late cancellation observer"),te._attachExtraTrace(de),se=ae),A.invoke(ve,te,{handler:J===null?se:typeof se=="function"&&b.domainBind(J,se),promise:q,receiver:ce,value:de})}else te._addCallbacks(G,ae,q,ce,J);return q},z.prototype._length=function(){return 65535&this._bitField},z.prototype._isFateSealed=function(){return(117506048&this._bitField)!=0},z.prototype._isFollowing=function(){return(67108864&this._bitField)==67108864},z.prototype._setLength=function(G){this._bitField=-65536&this._bitField|65535&G},z.prototype._setFulfilled=function(){this._bitField=33554432|this._bitField,this._fireEvent("promiseFulfilled",this)},z.prototype._setRejected=function(){this._bitField=16777216|this._bitField,this._fireEvent("promiseRejected",this)},z.prototype._setFollowing=function(){this._bitField=67108864|this._bitField,this._fireEvent("promiseResolved",this)},z.prototype._setIsFinal=function(){this._bitField=4194304|this._bitField},z.prototype._isFinal=function(){return(4194304&this._bitField)>0},z.prototype._unsetCancelled=function(){this._bitField=-65537&this._bitField},z.prototype._setCancelled=function(){this._bitField=65536|this._bitField,this._fireEvent("promiseCancelled",this)},z.prototype._setWillBeCancelled=function(){this._bitField=8388608|this._bitField},z.prototype._setAsyncGuaranteed=function(){A.hasCustomScheduler()||(this._bitField=134217728|this._bitField)},z.prototype._receiverAt=function(G){var ae=G===0?this._receiver0:this[4*G-4+3];if(ae!==x)return ae===void 0&&this._isBound()?this._boundValue():ae},z.prototype._promiseAt=function(G){return this[4*G-4+2]},z.prototype._fulfillmentHandlerAt=function(G){return this[4*G-4+0]},z.prototype._rejectionHandlerAt=function(G){return this[4*G-4+1]},z.prototype._boundValue=function(){},z.prototype._migrateCallback0=function(G){G._bitField;var ae=G._fulfillmentHandler0,fe=G._rejectionHandler0,ce=G._promise0,ye=G._receiverAt(0);ye===void 0&&(ye=x),this._addCallbacks(ae,fe,ce,ye,null)},z.prototype._migrateCallbackAt=function(G,ae){var fe=G._fulfillmentHandlerAt(ae),ce=G._rejectionHandlerAt(ae),ye=G._promiseAt(ae),F=G._receiverAt(ae);F===void 0&&(F=x),this._addCallbacks(fe,ce,ye,F,null)},z.prototype._addCallbacks=function(G,ae,fe,ce,ye){var F=this._length();if(F>=65531&&(F=0,this._setLength(0)),F===0)this._promise0=fe,this._receiver0=ce,typeof G=="function"&&(this._fulfillmentHandler0=ye===null?G:b.domainBind(ye,G)),typeof ae=="function"&&(this._rejectionHandler0=ye===null?ae:b.domainBind(ye,ae));else{var q=4*F-4;this[q+2]=fe,this[q+3]=ce,typeof G=="function"&&(this[q+0]=ye===null?G:b.domainBind(ye,G)),typeof ae=="function"&&(this[q+1]=ye===null?ae:b.domainBind(ye,ae))}return this._setLength(F+1),F},z.prototype._proxy=function(G,ae){this._addCallbacks(void 0,void 0,ae,G,null)},z.prototype._resolveCallback=function(G,ae){if((117506048&this._bitField)==0){if(G===this)return this._rejectCallback(u(),!1);var fe=Y(G,this);if(!(fe instanceof z))return this._fulfill(G);ae&&this._propagateFrom(fe,2);var ce=fe._target();if(ce!==this){var ye=ce._bitField;if((50397184&ye)==0){var F=this._length();F>0&&ce._migrateCallback0(this);for(var q=1;q<F;++q)ce._migrateCallbackAt(this,q);this._setFollowing(),this._setLength(0),this._setFollowee(ce)}else if((33554432&ye)!=0)this._fulfill(ce._value());else if((16777216&ye)!=0)this._reject(ce._reason());else{var te=new j("late cancellation observer");ce._attachExtraTrace(te),this._reject(te)}}else this._reject(u())}},z.prototype._rejectCallback=function(G,ae,fe){var ce=b.ensureErrorObject(G),ye=ce===G;if(!ye&&!fe&&ie.warnings()){var F="a promise was rejected with a non-error: "+b.classString(G);this._warn(F,!0)}this._attachExtraTrace(ce,!!ae&&ye),this._reject(G)},z.prototype._resolveFromExecutor=function(G){if(G!==R){var ae=this;this._captureStackTrace(),this._pushContext();var fe=!0,ce=this._execute(G,function(ye){ae._resolveCallback(ye)},function(ye){ae._rejectCallback(ye,fe)});fe=!1,this._popContext(),ce!==void 0&&ae._rejectCallback(ce,!0)}},z.prototype._settlePromiseFromHandler=function(G,ae,fe,ce){var ye=ce._bitField;if((65536&ye)==0){var F;ce._pushContext(),ae===U?fe&&typeof fe.length=="number"?F=D(G).apply(this._boundValue(),fe):(F=I).e=new P("cannot .spread() a non-array: "+b.classString(fe)):F=D(G).call(ae,fe);var q=ce._popContext();(65536&(ye=ce._bitField))==0&&(F===V?ce._reject(fe):F===I?ce._rejectCallback(F.e,!1):(ie.checkForgottenReturns(F,q,"",ce,this),ce._resolveCallback(F)))}},z.prototype._target=function(){for(var G=this;G._isFollowing();)G=G._followee();return G},z.prototype._followee=function(){return this._rejectionHandler0},z.prototype._setFollowee=function(G){this._rejectionHandler0=G},z.prototype._settlePromise=function(G,ae,fe,ce){var ye=G instanceof z,F=this._bitField,q=(134217728&F)!=0;(65536&F)!=0?(ye&&G._invokeInternalOnCancel(),fe instanceof X&&fe.isFinallyHandler()?(fe.cancelPromise=G,D(ae).call(fe,ce)===I&&G._reject(I.e)):ae===h?G._fulfill(h.call(fe)):fe instanceof g?fe._promiseCancelled(G):ye||G instanceof K?G._cancel():fe.cancel()):typeof ae=="function"?ye?(q&&G._setAsyncGuaranteed(),this._settlePromiseFromHandler(ae,fe,ce,G)):ae.call(fe,ce,G):fe instanceof g?fe._isResolved()||((33554432&F)!=0?fe._promiseFulfilled(ce,G):fe._promiseRejected(ce,G)):ye&&(q&&G._setAsyncGuaranteed(),(33554432&F)!=0?G._fulfill(ce):G._reject(ce))},z.prototype._settlePromiseLateCancellationObserver=function(G){var ae=G.handler,fe=G.promise,ce=G.receiver,ye=G.value;typeof ae=="function"?fe instanceof z?this._settlePromiseFromHandler(ae,ce,ye,fe):ae.call(ce,ye,fe):fe instanceof z&&fe._reject(ye)},z.prototype._settlePromiseCtx=function(G){this._settlePromise(G.promise,G.handler,G.receiver,G.value)},z.prototype._settlePromise0=function(G,ae,fe){var ce=this._promise0,ye=this._receiverAt(0);this._promise0=void 0,this._receiver0=void 0,this._settlePromise(ce,G,ye,ae)},z.prototype._clearCallbackDataAtIndex=function(G){var ae=4*G-4;this[ae+2]=this[ae+3]=this[ae+0]=this[ae+1]=void 0},z.prototype._fulfill=function(G){var ae=this._bitField;if(!((117506048&ae)>>>16)){if(G===this){var fe=u();return this._attachExtraTrace(fe),this._reject(fe)}this._setFulfilled(),this._rejectionHandler0=G,(65535&ae)>0&&((134217728&ae)!=0?this._settlePromises():A.settlePromises(this))}},z.prototype._reject=function(G){var ae=this._bitField;if(!((117506048&ae)>>>16)){if(this._setRejected(),this._fulfillmentHandler0=G,this._isFinal())return A.fatalError(G,b.isNode);(65535&ae)>0?A.settlePromises(this):this._ensurePossibleRejectionHandled()}},z.prototype._fulfillPromises=function(G,ae){for(var fe=1;fe<G;fe++){var ce=this._fulfillmentHandlerAt(fe),ye=this._promiseAt(fe),F=this._receiverAt(fe);this._clearCallbackDataAtIndex(fe),this._settlePromise(ye,ce,F,ae)}},z.prototype._rejectPromises=function(G,ae){for(var fe=1;fe<G;fe++){var ce=this._rejectionHandlerAt(fe),ye=this._promiseAt(fe),F=this._receiverAt(fe);this._clearCallbackDataAtIndex(fe),this._settlePromise(ye,ce,F,ae)}},z.prototype._settlePromises=function(){var G=this._bitField,ae=65535&G;if(ae>0){if((16842752&G)!=0){var fe=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,fe,G),this._rejectPromises(ae,fe)}else{var ce=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,ce,G),this._fulfillPromises(ae,ce)}this._setLength(0)}this._clearCancellationData()},z.prototype._settledValue=function(){var G=this._bitField;return(33554432&G)!=0?this._rejectionHandler0:(16777216&G)!=0?this._fulfillmentHandler0:void 0},z.defer=z.pending=function(){return ie.deprecated("Promise.defer","new Promise"),{promise:new z(R),resolve:N,reject:B}},b.notEnumerableProp(z,"_makeSelfResolutionError",u),o("./method")(z,R,Y,m,ie),o("./bind")(z,R,Y,ie),o("./cancel")(z,K,m,ie),o("./direct_resolve")(z),o("./synchronous_inspection")(z),o("./join")(z,K,Y,R,A,_),z.Promise=z,z.version="3.5.1",o("./map.js")(z,K,m,Y,R,ie),o("./call_get.js")(z),o("./using.js")(z,m,Y,ee,R,ie),o("./timers.js")(z,R,ie),o("./generators.js")(z,m,R,Y,g,ie),o("./nodeify.js")(z),o("./promisify.js")(z,R),o("./props.js")(z,K,Y,m),o("./race.js")(z,R,Y,m),o("./reduce.js")(z,K,m,Y,R,ie),o("./settle.js")(z,K,ie),o("./some.js")(z,K,m),o("./filter.js")(z,R),o("./each.js")(z,R),o("./any.js")(z),b.toFastProperties(z),b.toFastProperties(z.prototype),Q({a:1}),Q({b:2}),Q({c:3}),Q(1),Q(function(){}),Q(void 0),Q(!1),Q(new z(R)),ie.setBounds(C.firstLineError,b.lastLineError),z}},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36}],23:[function(o,l,f){l.exports=function(u,h,m,g,_){var x=o("./util");function b(S){var C=this._promise=new u(h);S instanceof u&&C._propagateFrom(S,3),C._setOnCancel(this),this._values=S,this._length=0,this._totalResolved=0,this._init(void 0,-2)}return x.isArray,x.inherits(b,_),b.prototype.length=function(){return this._length},b.prototype.promise=function(){return this._promise},b.prototype._init=function S(C,A){var O=m(this._values,this._promise);if(O instanceof u){var P=(O=O._target())._bitField;if(this._values=O,(50397184&P)==0)return this._promise._setAsyncGuaranteed(),O._then(S,this._reject,void 0,this,A);if((33554432&P)==0)return(16777216&P)!=0?this._reject(O._reason()):this._cancel();O=O._value()}if((O=x.asArray(O))!==null)O.length!==0?this._iterate(O):A===-5?this._resolveEmptyArray():this._resolve(function(R){switch(A){case-2:return[];case-3:return{};case-6:return new Map}}());else{var j=g("expecting an array or an iterable object but got "+x.classString(O)).reason();this._promise._rejectCallback(j,!1)}},b.prototype._iterate=function(S){var C=this.getActualLength(S.length);this._length=C,this._values=this.shouldCopyValues()?new Array(C):this._values;for(var A=this._promise,O=!1,P=null,j=0;j<C;++j){var R=m(S[j],A);P=R instanceof u?(R=R._target())._bitField:null,O?P!==null&&R.suppressUnhandledRejections():P!==null?(50397184&P)==0?(R._proxy(this,j),this._values[j]=R):O=(33554432&P)!=0?this._promiseFulfilled(R._value(),j):(16777216&P)!=0?this._promiseRejected(R._reason(),j):this._promiseCancelled(j):O=this._promiseFulfilled(R,j)}O||A._setAsyncGuaranteed()},b.prototype._isResolved=function(){return this._values===null},b.prototype._resolve=function(S){this._values=null,this._promise._fulfill(S)},b.prototype._cancel=function(){!this._isResolved()&&this._promise._isCancellable()&&(this._values=null,this._promise._cancel())},b.prototype._reject=function(S){this._values=null,this._promise._rejectCallback(S,!1)},b.prototype._promiseFulfilled=function(S,C){return this._values[C]=S,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},b.prototype._promiseCancelled=function(){return this._cancel(),!0},b.prototype._promiseRejected=function(S){return this._totalResolved++,this._reject(S),!0},b.prototype._resultCancelled=function(){if(!this._isResolved()){var S=this._values;if(this._cancel(),S instanceof u)S.cancel();else for(var C=0;C<S.length;++C)S[C]instanceof u&&S[C].cancel()}},b.prototype.shouldCopyValues=function(){return!0},b.prototype.getActualLength=function(S){return S},b}},{"./util":36}],24:[function(o,l,f){l.exports=function(u,h){var m={},g=o("./util"),_=o("./nodeback"),x=g.withAppended,b=g.maybeWrapAsError,S=g.canEvaluate,C=o("./errors").TypeError,A={__isPromisified__:!0},O=new RegExp("^(?:"+["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"].join("|")+")$"),P=function(ee){return g.isIdentifier(ee)&&ee.charAt(0)!=="_"&&ee!=="constructor"};function j(ee){return!O.test(ee)}function R(ee){try{return ee.__isPromisified__===!0}catch{return!1}}function U(ee,ie,X){var ne=g.getDataPropertyOrDefault(ee,ie+X,A);return!!ne&&R(ne)}function V(ee,ie,X,ne){for(var H=g.inheritedDataKeys(ee),I=[],D=0;D<H.length;++D){var z=H[D],N=ee[z],B=ne===P||P(z);typeof N!="function"||R(N)||U(ee,z,ie)||!ne(z,N,ee,B)||I.push(z,N)}return function(Q,G,ae){for(var fe=0;fe<Q.length;fe+=2){var ce=Q[fe];if(ae.test(ce)){for(var ye=ce.replace(ae,""),F=0;F<Q.length;F+=2)if(Q[F]===ye)throw new C(`Cannot promisify an API that has normal methods with '%s'-suffix
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`.replace("%s",G))}}}(I,ie,X),I}var Y=function(ee){return ee.replace(/([$])/,"\\$")},K=S?void 0:function(ee,ie,X,ne,H,I){var D=function(){return this}(),z=ee;function N(){var B=ie;ie===m&&(B=this);var Q=new u(h);Q._captureStackTrace();var G=typeof z=="string"&&this!==D?this[z]:ee,ae=_(Q,I);try{G.apply(B,x(arguments,ae))}catch(fe){Q._rejectCallback(b(fe),!0,!0)}return Q._isFateSealed()||Q._setAsyncGuaranteed(),Q}return typeof z=="string"&&(ee=ne),g.notEnumerableProp(N,"__isPromisified__",!0),N};function W(ee,ie,X,ne,H){for(var I=new RegExp(Y(ie)+"$"),D=V(ee,ie,I,X),z=0,N=D.length;z<N;z+=2){var B=D[z],Q=D[z+1],G=B+ie;if(ne===K)ee[G]=K(B,m,B,Q,ie,H);else{var ae=ne(Q,function(){return K(B,m,B,Q,ie,H)});g.notEnumerableProp(ae,"__isPromisified__",!0),ee[G]=ae}}return g.toFastProperties(ee),ee}u.promisify=function(ee,ie){if(typeof ee!="function")throw new C("expecting a function but got "+g.classString(ee));if(R(ee))return ee;var X=(ie=Object(ie)).context===void 0?m:ie.context,ne=!!ie.multiArgs,H=function(I,D,z){return K(I,D,void 0,I,null,ne)}(ee,X);return g.copyDescriptors(ee,H,j),H},u.promisifyAll=function(ee,ie){if(typeof ee!="function"&&typeof ee!="object")throw new C(`the target of promisifyAll must be an object or a function
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);var X=!!(ie=Object(ie)).multiArgs,ne=ie.suffix;typeof ne!="string"&&(ne="Async");var H=ie.filter;typeof H!="function"&&(H=P);var I=ie.promisifier;if(typeof I!="function"&&(I=K),!g.isIdentifier(ne))throw new RangeError(`suffix must be a valid identifier
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);for(var D=g.inheritedDataKeys(ee),z=0;z<D.length;++z){var N=ee[D[z]];D[z]!=="constructor"&&g.isClass(N)&&(W(N.prototype,ne,H,I,X),W(N,ne,H,I,X))}return W(ee,ne,H,I,X)}}},{"./errors":12,"./nodeback":20,"./util":36}],25:[function(o,l,f){l.exports=function(u,h,m,g){var _,x=o("./util"),b=x.isObject,S=o("./es5");typeof Map=="function"&&(_=Map);var C=function(){var P=0,j=0;function R(U,V){this[P]=U,this[P+j]=V,P++}return function(U){j=U.size,P=0;var V=new Array(2*U.size);return U.forEach(R,V),V}}();function A(P){var j,R=!1;if(_!==void 0&&P instanceof _)j=C(P),R=!0;else{var U=S.keys(P),V=U.length;j=new Array(2*V);for(var Y=0;Y<V;++Y){var K=U[Y];j[Y]=P[K],j[Y+V]=K}}this.constructor$(j),this._isMap=R,this._init$(void 0,R?-6:-3)}function O(P){var j,R=m(P);return b(R)?(j=R instanceof u?R._then(u.props,void 0,void 0,void 0,void 0):new A(R).promise(),R instanceof u&&j._propagateFrom(R,2),j):g(`cannot await properties of a non-object
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`)}x.inherits(A,h),A.prototype._init=function(){},A.prototype._promiseFulfilled=function(P,j){if(this._values[j]=P,++this._totalResolved>=this._length){var R;if(this._isMap)R=function(K){for(var W=new _,ee=K.length/2|0,ie=0;ie<ee;++ie){var X=K[ee+ie],ne=K[ie];W.set(X,ne)}return W}(this._values);else{R={};for(var U=this.length(),V=0,Y=this.length();V<Y;++V)R[this._values[V+U]]=this._values[V]}return this._resolve(R),!0}return!1},A.prototype.shouldCopyValues=function(){return!1},A.prototype.getActualLength=function(P){return P>>1},u.prototype.props=function(){return O(this)},u.props=function(P){return O(P)}}},{"./es5":13,"./util":36}],26:[function(o,l,f){function u(h){this._capacity=h,this._length=0,this._front=0}u.prototype._willBeOverCapacity=function(h){return this._capacity<h},u.prototype._pushOne=function(h){var m=this.length();this._checkCapacity(m+1),this[this._front+m&this._capacity-1]=h,this._length=m+1},u.prototype.push=function(h,m,g){var _=this.length()+3;if(this._willBeOverCapacity(_))return this._pushOne(h),this._pushOne(m),void this._pushOne(g);var x=this._front+_-3;this._checkCapacity(_);var b=this._capacity-1;this[x+0&b]=h,this[x+1&b]=m,this[x+2&b]=g,this._length=_},u.prototype.shift=function(){var h=this._front,m=this[h];return this[h]=void 0,this._front=h+1&this._capacity-1,this._length--,m},u.prototype.length=function(){return this._length},u.prototype._checkCapacity=function(h){this._capacity<h&&this._resizeTo(this._capacity<<1)},u.prototype._resizeTo=function(h){var m=this._capacity;this._capacity=h,function(g,_,x,b,S){for(var C=0;C<S;++C)x[C+b]=g[C+0],g[C+0]=void 0}(this,0,this,m,this._front+this._length&m-1)},l.exports=u},{}],27:[function(o,l,f){l.exports=function(u,h,m,g){var _=o("./util"),x=function(S){return S.then(function(C){return b(C,S)})};function b(S,C){var A=m(S);if(A instanceof u)return x(A);if((S=_.asArray(S))===null)return g("expecting an array or an iterable object but got "+_.classString(S));var O=new u(h);C!==void 0&&O._propagateFrom(C,3);for(var P=O._fulfill,j=O._reject,R=0,U=S.length;R<U;++R){var V=S[R];(V!==void 0||R in S)&&u.cast(V)._then(P,j,void 0,O,null)}return O}u.race=function(S){return b(S,void 0)},u.prototype.race=function(){return b(this,void 0)}}},{"./util":36}],28:[function(o,l,f){l.exports=function(u,h,m,g,_,x){var b=u._getDomain,S=o("./util"),C=S.tryCatch;function A(U,V,Y,K){this.constructor$(U);var W=b();this._fn=W===null?V:S.domainBind(W,V),Y!==void 0&&(Y=u.resolve(Y))._attachCancellationCallback(this),this._initialValue=Y,this._currentCancellable=null,this._eachValues=K===_?Array(this._length):K===0?null:void 0,this._promise._captureStackTrace(),this._init$(void 0,-5)}function O(U,V){this.isFulfilled()?V._resolve(U):V._reject(U)}function P(U,V,Y,K){return typeof V!="function"?m("expecting a function but got "+S.classString(V)):new A(U,V,Y,K).promise()}function j(U){this.accum=U,this.array._gotAccum(U);var V=g(this.value,this.array._promise);return V instanceof u?(this.array._currentCancellable=V,V._then(R,void 0,void 0,this,void 0)):R.call(this,V)}function R(U){var V,Y=this.array,K=Y._promise,W=C(Y._fn);K._pushContext(),(V=Y._eachValues!==void 0?W.call(K._boundValue(),U,this.index,this.length):W.call(K._boundValue(),this.accum,U,this.index,this.length))instanceof u&&(Y._currentCancellable=V);var ee=K._popContext();return x.checkForgottenReturns(V,ee,Y._eachValues!==void 0?"Promise.each":"Promise.reduce",K),V}S.inherits(A,h),A.prototype._gotAccum=function(U){this._eachValues!==void 0&&this._eachValues!==null&&U!==_&&this._eachValues.push(U)},A.prototype._eachComplete=function(U){return this._eachValues!==null&&this._eachValues.push(U),this._eachValues},A.prototype._init=function(){},A.prototype._resolveEmptyArray=function(){this._resolve(this._eachValues!==void 0?this._eachValues:this._initialValue)},A.prototype.shouldCopyValues=function(){return!1},A.prototype._resolve=function(U){this._promise._resolveCallback(U),this._values=null},A.prototype._resultCancelled=function(U){if(U===this._initialValue)return this._cancel();this._isResolved()||(this._resultCancelled$(),this._currentCancellable instanceof u&&this._currentCancellable.cancel(),this._initialValue instanceof u&&this._initialValue.cancel())},A.prototype._iterate=function(U){var V,Y;this._values=U;var K=U.length;if(this._initialValue!==void 0?(V=this._initialValue,Y=0):(V=u.resolve(U[0]),Y=1),this._currentCancellable=V,!V.isRejected())for(;Y<K;++Y){var W={accum:null,value:U[Y],index:Y,length:K,array:this};V=V._then(j,void 0,void 0,W,void 0)}this._eachValues!==void 0&&(V=V._then(this._eachComplete,void 0,void 0,this,void 0)),V._then(O,O,void 0,V,this)},u.prototype.reduce=function(U,V){return P(this,U,V,null)},u.reduce=function(U,V,Y,K){return P(U,V,Y,K)}}},{"./util":36}],29:[function(o,l,f){var u,h=o("./util"),m=h.getNativePromise();if(h.isNode&&typeof MutationObserver>"u"){var g=i.setImmediate,_=r.nextTick;u=h.isRecentNode?function(b){g.call(i,b)}:function(b){_.call(r,b)}}else if(typeof m=="function"&&typeof m.resolve=="function"){var x=m.resolve();u=function(b){x.then(b)}}else u=typeof MutationObserver>"u"||typeof window<"u"&&window.navigator&&(window.navigator.standalone||window.cordova)?a!==void 0?function(b){a(b)}:typeof setTimeout<"u"?function(b){setTimeout(b,0)}:function(){throw new Error(`No async scheduler available
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`)}:function(){var b=document.createElement("div"),S={attributes:!0},C=!1,A=document.createElement("div");return new MutationObserver(function(){b.classList.toggle("foo"),C=!1}).observe(A,S),function(O){var P=new MutationObserver(function(){P.disconnect(),O()});P.observe(b,S),C||(C=!0,A.classList.toggle("foo"))}}();l.exports=u},{"./util":36}],30:[function(o,l,f){l.exports=function(u,h,m){var g=u.PromiseInspection;function _(x){this.constructor$(x)}o("./util").inherits(_,h),_.prototype._promiseResolved=function(x,b){return this._values[x]=b,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},_.prototype._promiseFulfilled=function(x,b){var S=new g;return S._bitField=33554432,S._settledValueField=x,this._promiseResolved(b,S)},_.prototype._promiseRejected=function(x,b){var S=new g;return S._bitField=16777216,S._settledValueField=x,this._promiseResolved(b,S)},u.settle=function(x){return m.deprecated(".settle()",".reflect()"),new _(x).promise()},u.prototype.settle=function(){return u.settle(this)}}},{"./util":36}],31:[function(o,l,f){l.exports=function(u,h,m){var g=o("./util"),_=o("./errors").RangeError,x=o("./errors").AggregateError,b=g.isArray,S={};function C(O){this.constructor$(O),this._howMany=0,this._unwrap=!1,this._initialized=!1}function A(O,P){if((0|P)!==P||P<0)return m(`expecting a positive integer
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);var j=new C(O),R=j.promise();return j.setHowMany(P),j.init(),R}g.inherits(C,h),C.prototype._init=function(){if(this._initialized)if(this._howMany!==0){this._init$(void 0,-5);var O=b(this._values);!this._isResolved()&&O&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}else this._resolve([])},C.prototype.init=function(){this._initialized=!0,this._init()},C.prototype.setUnwrap=function(){this._unwrap=!0},C.prototype.howMany=function(){return this._howMany},C.prototype.setHowMany=function(O){this._howMany=O},C.prototype._promiseFulfilled=function(O){return this._addFulfilled(O),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),this.howMany()===1&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)},C.prototype._promiseRejected=function(O){return this._addRejected(O),this._checkOutcome()},C.prototype._promiseCancelled=function(){return this._values instanceof u||this._values==null?this._cancel():(this._addRejected(S),this._checkOutcome())},C.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var O=new x,P=this.length();P<this._values.length;++P)this._values[P]!==S&&O.push(this._values[P]);return O.length>0?this._reject(O):this._cancel(),!0}return!1},C.prototype._fulfilled=function(){return this._totalResolved},C.prototype._rejected=function(){return this._values.length-this.length()},C.prototype._addRejected=function(O){this._values.push(O)},C.prototype._addFulfilled=function(O){this._values[this._totalResolved++]=O},C.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},C.prototype._getRangeError=function(O){var P="Input array must contain at least "+this._howMany+" items but contains only "+O+" items";return new _(P)},C.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},u.some=function(O,P){return A(O,P)},u.prototype.some=function(O){return A(this,O)},u._SomePromiseArray=C}},{"./errors":12,"./util":36}],32:[function(o,l,f){l.exports=function(u){function h(C){C!==void 0?(C=C._target(),this._bitField=C._bitField,this._settledValueField=C._isFateSealed()?C._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}h.prototype._settledValue=function(){return this._settledValueField};var m=h.prototype.value=function(){if(!this.isFulfilled())throw new TypeError(`cannot get fulfillment value of a non-fulfilled promise
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);return this._settledValue()},g=h.prototype.error=h.prototype.reason=function(){if(!this.isRejected())throw new TypeError(`cannot get rejection reason of a non-rejected promise
|
||
|
||
See http://goo.gl/MqrFmX
|
||
`);return this._settledValue()},_=h.prototype.isFulfilled=function(){return(33554432&this._bitField)!=0},x=h.prototype.isRejected=function(){return(16777216&this._bitField)!=0},b=h.prototype.isPending=function(){return(50397184&this._bitField)==0},S=h.prototype.isResolved=function(){return(50331648&this._bitField)!=0};h.prototype.isCancelled=function(){return(8454144&this._bitField)!=0},u.prototype.__isCancelled=function(){return(65536&this._bitField)==65536},u.prototype._isCancelled=function(){return this._target().__isCancelled()},u.prototype.isCancelled=function(){return(8454144&this._target()._bitField)!=0},u.prototype.isPending=function(){return b.call(this._target())},u.prototype.isRejected=function(){return x.call(this._target())},u.prototype.isFulfilled=function(){return _.call(this._target())},u.prototype.isResolved=function(){return S.call(this._target())},u.prototype.value=function(){return m.call(this._target())},u.prototype.reason=function(){var C=this._target();return C._unsetRejectionIsUnhandled(),g.call(C)},u.prototype._value=function(){return this._settledValue()},u.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},u.PromiseInspection=h}},{}],33:[function(o,l,f){l.exports=function(u,h){var m=o("./util"),g=m.errorObj,_=m.isObject,x={}.hasOwnProperty;return function(b,S){if(_(b)){if(b instanceof u)return b;var C=function(O){try{return function(P){return P.then}(O)}catch(P){return g.e=P,g}}(b);if(C===g){S&&S._pushContext();var A=u.reject(C.e);return S&&S._popContext(),A}if(typeof C=="function")return function(O){try{return x.call(O,"_promise0")}catch{return!1}}(b)?(A=new u(h),b._then(A._fulfill,A._reject,void 0,A,null),A):function(O,P,j){var R=new u(h),U=R;j&&j._pushContext(),R._captureStackTrace(),j&&j._popContext();var V=!0,Y=m.tryCatch(P).call(O,function(K){R&&(R._resolveCallback(K),R=null)},function(K){R&&(R._rejectCallback(K,V,!0),R=null)});return V=!1,R&&Y===g&&(R._rejectCallback(Y.e,!0,!0),R=null),U}(b,C,S)}return b}}},{"./util":36}],34:[function(o,l,f){l.exports=function(u,h,m){var g=o("./util"),_=u.TimeoutError;function x(O){this.handle=O}x.prototype._resultCancelled=function(){clearTimeout(this.handle)};var b=function(O){return S(+this).thenReturn(O)},S=u.delay=function(O,P){var j,R;return P!==void 0?(j=u.resolve(P)._then(b,null,null,O,void 0),m.cancellation()&&P instanceof u&&j._setOnCancel(P)):(j=new u(h),R=setTimeout(function(){j._fulfill()},+O),m.cancellation()&&j._setOnCancel(new x(R)),j._captureStackTrace()),j._setAsyncGuaranteed(),j};function C(O){return clearTimeout(this.handle),O}function A(O){throw clearTimeout(this.handle),O}u.prototype.delay=function(O){return S(O,this)},u.prototype.timeout=function(O,P){var j,R;O=+O;var U=new x(setTimeout(function(){j.isPending()&&function(V,Y,K){var W;W=typeof Y!="string"?Y instanceof Error?Y:new _("operation timed out"):new _(Y),g.markAsOriginatingFromRejection(W),V._attachExtraTrace(W),V._reject(W),K!=null&&K.cancel()}(j,P,R)},O));return m.cancellation()?(R=this.then(),(j=R._then(C,A,void 0,U,void 0))._setOnCancel(U)):j=this._then(C,A,void 0,U,void 0),j}}},{"./util":36}],35:[function(o,l,f){l.exports=function(u,h,m,g,_,x){var b=o("./util"),S=o("./errors").TypeError,C=o("./util").inherits,A=b.errorObj,O=b.tryCatch,P={};function j(W){setTimeout(function(){throw W},0)}function R(W,ee){var ie=0,X=W.length,ne=new u(_);return function H(){if(ie>=X)return ne._fulfill();var I=function(D){var z=m(D);return z!==D&&typeof D._isDisposable=="function"&&typeof D._getDisposer=="function"&&D._isDisposable()&&z._setDisposable(D._getDisposer()),z}(W[ie++]);if(I instanceof u&&I._isDisposable()){try{I=m(I._getDisposer().tryDispose(ee),W.promise)}catch(D){return j(D)}if(I instanceof u)return I._then(H,j,null,null,null)}H()}(),ne}function U(W,ee,ie){this._data=W,this._promise=ee,this._context=ie}function V(W,ee,ie){this.constructor$(W,ee,ie)}function Y(W){return U.isDisposer(W)?(this.resources[this.index]._setDisposable(W),W.promise()):W}function K(W){this.length=W,this.promise=null,this[W-1]=null}U.prototype.data=function(){return this._data},U.prototype.promise=function(){return this._promise},U.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():P},U.prototype.tryDispose=function(W){var ee=this.resource(),ie=this._context;ie!==void 0&&ie._pushContext();var X=ee!==P?this.doDispose(ee,W):null;return ie!==void 0&&ie._popContext(),this._promise._unsetDisposable(),this._data=null,X},U.isDisposer=function(W){return W!=null&&typeof W.resource=="function"&&typeof W.tryDispose=="function"},C(V,U),V.prototype.doDispose=function(W,ee){return this.data().call(W,W,ee)},K.prototype._resultCancelled=function(){for(var W=this.length,ee=0;ee<W;++ee){var ie=this[ee];ie instanceof u&&ie.cancel()}},u.using=function(){var W=arguments.length;if(W<2)return h("you must pass at least 2 arguments to Promise.using");var ee,ie=arguments[W-1];if(typeof ie!="function")return h("expecting a function but got "+b.classString(ie));var X=!0;W===2&&Array.isArray(arguments[0])?(W=(ee=arguments[0]).length,X=!1):(ee=arguments,W--);for(var ne=new K(W),H=0;H<W;++H){var I=ee[H];if(U.isDisposer(I)){var D=I;(I=I.promise())._setDisposable(D)}else{var z=m(I);z instanceof u&&(I=z._then(Y,null,null,{resources:ne,index:H},void 0))}ne[H]=I}var N=new Array(ne.length);for(H=0;H<N.length;++H)N[H]=u.resolve(ne[H]).reflect();var B=u.all(N).then(function(G){for(var ae=0;ae<G.length;++ae){var fe=G[ae];if(fe.isRejected())return A.e=fe.error(),A;if(!fe.isFulfilled())return void B.cancel();G[ae]=fe.value()}Q._pushContext(),ie=O(ie);var ce=X?ie.apply(void 0,G):ie(G),ye=Q._popContext();return x.checkForgottenReturns(ce,ye,"Promise.using",Q),ce}),Q=B.lastly(function(){var G=new u.PromiseInspection(B);return R(ne,G)});return ne.promise=Q,Q._setOnCancel(ne),Q},u.prototype._setDisposable=function(W){this._bitField=131072|this._bitField,this._disposer=W},u.prototype._isDisposable=function(){return(131072&this._bitField)>0},u.prototype._getDisposer=function(){return this._disposer},u.prototype._unsetDisposable=function(){this._bitField=-131073&this._bitField,this._disposer=void 0},u.prototype.disposer=function(W){if(typeof W=="function")return new V(W,this,g());throw new S}}},{"./errors":12,"./util":36}],36:[function(o,l,f){var u,h=o("./es5"),m=typeof navigator>"u",g={e:{}},_=typeof self<"u"?self:typeof window<"u"?window:i!==void 0?i:this!==void 0?this:null;function x(){try{var X=u;return u=null,X.apply(this,arguments)}catch(ne){return g.e=ne,g}}function b(X){return X==null||X===!0||X===!1||typeof X=="string"||typeof X=="number"}function S(X,ne,H){if(b(X))return X;var I={value:H,configurable:!0,enumerable:!1,writable:!0};return h.defineProperty(X,ne,I),X}var C=function(){var X=[Array.prototype,Object.prototype,Function.prototype],ne=function(D){for(var z=0;z<X.length;++z)if(X[z]===D)return!0;return!1};if(h.isES5){var H=Object.getOwnPropertyNames;return function(D){for(var z=[],N=Object.create(null);D!=null&&!ne(D);){var B;try{B=H(D)}catch{return z}for(var Q=0;Q<B.length;++Q){var G=B[Q];if(!N[G]){N[G]=!0;var ae=Object.getOwnPropertyDescriptor(D,G);ae!=null&&ae.get==null&&ae.set==null&&z.push(G)}}D=h.getPrototypeOf(D)}return z}}var I={}.hasOwnProperty;return function(D){if(ne(D))return[];var z=[];e:for(var N in D)if(I.call(D,N))z.push(N);else{for(var B=0;B<X.length;++B)if(I.call(X[B],N))continue e;z.push(N)}return z}}(),A=/this\s*\.\s*\S+\s*=/,O=/^[a-z$_][a-z$_0-9]*$/i;function P(X){try{return X+""}catch{return"[no string representation]"}}function j(X){return X instanceof Error||X!==null&&typeof X=="object"&&typeof X.message=="string"&&typeof X.name=="string"}function R(X){return j(X)&&h.propertyIsWritable(X,"stack")}var U="stack"in new Error?function(X){return R(X)?X:new Error(P(X))}:function(X){if(R(X))return X;try{throw new Error(P(X))}catch(ne){return ne}};function V(X){return{}.toString.call(X)}var Y=function(X){return h.isArray(X)?X:null};if(typeof Symbol<"u"&&Symbol.iterator){var K=typeof Array.from=="function"?function(X){return Array.from(X)}:function(X){for(var ne,H=[],I=X[Symbol.iterator]();!(ne=I.next()).done;)H.push(ne.value);return H};Y=function(X){return h.isArray(X)?X:X!=null&&typeof X[Symbol.iterator]=="function"?K(X):null}}var W=r!==void 0&&V(r).toLowerCase()==="[object process]",ee=r!==void 0&&r.env!==void 0,ie={isClass:function(X){try{if(typeof X=="function"){var ne=h.names(X.prototype),H=h.isES5&&ne.length>1,I=ne.length>0&&!(ne.length===1&&ne[0]==="constructor"),D=A.test(X+"")&&h.names(X).length>0;if(H||I||D)return!0}return!1}catch{return!1}},isIdentifier:function(X){return O.test(X)},inheritedDataKeys:C,getDataPropertyOrDefault:function(X,ne,H){if(!h.isES5)return{}.hasOwnProperty.call(X,ne)?X[ne]:void 0;var I=Object.getOwnPropertyDescriptor(X,ne);return I!=null?I.get==null&&I.set==null?I.value:H:void 0},thrower:function(X){throw X},isArray:h.isArray,asArray:Y,notEnumerableProp:S,isPrimitive:b,isObject:function(X){return typeof X=="function"||typeof X=="object"&&X!==null},isError:j,canEvaluate:m,errorObj:g,tryCatch:function(X){return u=X,x},inherits:function(X,ne){var H={}.hasOwnProperty;function I(){for(var D in this.constructor=X,this.constructor$=ne,ne.prototype)H.call(ne.prototype,D)&&D.charAt(D.length-1)!=="$"&&(this[D+"$"]=ne.prototype[D])}return I.prototype=ne.prototype,X.prototype=new I,X.prototype},withAppended:function(X,ne){var H,I=X.length,D=new Array(I+1);for(H=0;H<I;++H)D[H]=X[H];return D[H]=ne,D},maybeWrapAsError:function(X){return b(X)?new Error(P(X)):X},toFastProperties:function(X){return X},filledRange:function(X,ne,H){for(var I=new Array(X),D=0;D<X;++D)I[D]=ne+D+H;return I},toString:P,canAttachTrace:R,ensureErrorObject:U,originatesFromRejection:function(X){return X!=null&&(X instanceof Error.__BluebirdErrorTypes__.OperationalError||X.isOperational===!0)},markAsOriginatingFromRejection:function(X){try{S(X,"isOperational",!0)}catch{}},classString:V,copyDescriptors:function(X,ne,H){for(var I=h.names(X),D=0;D<I.length;++D){var z=I[D];if(H(z))try{h.defineProperty(ne,z,h.getDescriptor(X,z))}catch{}}},hasDevTools:typeof chrome<"u"&&chrome&&typeof chrome.loadTimes=="function",isNode:W,hasEnvVariables:ee,env:function(X){return ee?r.env[X]:void 0},global:_,getNativePromise:function(){if(typeof Promise=="function")try{var X=new Promise(function(){});if({}.toString.call(X)==="[object Promise]")return Promise}catch{}},domainBind:function(X,ne){return X.bind(ne)}};ie.isRecentNode=ie.isNode&&function(){var X=r.versions.node.split(".").map(Number);return X[0]===0&&X[1]>10||X[0]>0}(),ie.isNode&&ie.toFastProperties(r);try{throw new Error}catch(X){ie.lastLineError=X}l.exports=ie},{"./es5":13}]},{},[4])(4),typeof window<"u"&&window!==null?window.P=window.Promise:typeof self<"u"&&self!==null&&(self.P=self.Promise)}).call(this,n(4),n(0),n(11).setImmediate)},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(r,i){if(!i.eol&&r){for(var a=0,o=r.length;a<o;a++)if(r[a]==="\r"){if(r[a+1]===`
|
||
`){i.eol=`\r
|
||
`;break}if(r[a+1]){i.eol="\r";break}}else if(r[a]===`
|
||
`){i.eol=`
|
||
`;break}}return i.eol||`
|
||
`}},function(e,t,n){var r=n(65),i=n(73);e.exports=function(a,o){var l=i(a,o);return r(l)?l:void 0}},function(e,t,n){var r=n(19).Symbol;e.exports=r},function(e,t,n){var r=n(67),i=typeof self=="object"&&self&&self.Object===Object&&self,a=r||i||Function("return this")();e.exports=a},function(e,t){e.exports=function(n){var r=typeof n;return n!=null&&(r=="object"||r=="function")}},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){var r=n(30),i=n(76);e.exports=function(a){return typeof a=="symbol"||i(a)&&r(a)=="[object Symbol]"}},function(e,t,n){(function(r,i){var a=n(6);e.exports=P;var o,l=n(37);P.ReadableState=O,n(12).EventEmitter;var f=function(N,B){return N.listeners(B).length},u=n(24),h=n(7).Buffer,m=r.Uint8Array||function(){},g=n(5);g.inherits=n(2);var _=n(41),x=void 0;x=_&&_.debuglog?_.debuglog("stream"):function(){};var b,S=n(42),C=n(25);g.inherits(P,u);var A=["error","close","destroy","pause","resume"];function O(N,B){o=o||n(1),N=N||{};var Q=B instanceof o;this.objectMode=!!N.objectMode,Q&&(this.objectMode=this.objectMode||!!N.readableObjectMode);var G=N.highWaterMark,ae=N.readableHighWaterMark,fe=this.objectMode?16:16384;this.highWaterMark=G||G===0?G:Q&&(ae||ae===0)?ae:fe,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new S,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=N.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,N.encoding&&(b||(b=n(26).StringDecoder),this.decoder=new b(N.encoding),this.encoding=N.encoding)}function P(N){if(o=o||n(1),!(this instanceof P))return new P(N);this._readableState=new O(N,this),this.readable=!0,N&&(typeof N.read=="function"&&(this._read=N.read),typeof N.destroy=="function"&&(this._destroy=N.destroy)),u.call(this)}function j(N,B,Q,G,ae){var fe,ce=N._readableState;return B===null?(ce.reading=!1,function(ye,F){if(!F.ended){if(F.decoder){var q=F.decoder.end();q&&q.length&&(F.buffer.push(q),F.length+=F.objectMode?1:q.length)}F.ended=!0,Y(ye)}}(N,ce)):(ae||(fe=function(ye,F){var q;return function(te){return h.isBuffer(te)||te instanceof m}(F)||typeof F=="string"||F===void 0||ye.objectMode||(q=new TypeError("Invalid non-string/buffer chunk")),q}(ce,B)),fe?N.emit("error",fe):ce.objectMode||B&&B.length>0?(typeof B=="string"||ce.objectMode||Object.getPrototypeOf(B)===h.prototype||(B=function(ye){return h.from(ye)}(B)),G?ce.endEmitted?N.emit("error",new Error("stream.unshift() after end event")):R(N,ce,B,!0):ce.ended?N.emit("error",new Error("stream.push() after EOF")):(ce.reading=!1,ce.decoder&&!Q?(B=ce.decoder.write(B),ce.objectMode||B.length!==0?R(N,ce,B,!1):W(N,ce)):R(N,ce,B,!1))):G||(ce.reading=!1)),function(ye){return!ye.ended&&(ye.needReadable||ye.length<ye.highWaterMark||ye.length===0)}(ce)}function R(N,B,Q,G){B.flowing&&B.length===0&&!B.sync?(N.emit("data",Q),N.read(0)):(B.length+=B.objectMode?1:Q.length,G?B.buffer.unshift(Q):B.buffer.push(Q),B.needReadable&&Y(N)),W(N,B)}Object.defineProperty(P.prototype,"destroyed",{get:function(){return this._readableState!==void 0&&this._readableState.destroyed},set:function(N){this._readableState&&(this._readableState.destroyed=N)}}),P.prototype.destroy=C.destroy,P.prototype._undestroy=C.undestroy,P.prototype._destroy=function(N,B){this.push(null),B(N)},P.prototype.push=function(N,B){var Q,G=this._readableState;return G.objectMode?Q=!0:typeof N=="string"&&((B=B||G.defaultEncoding)!==G.encoding&&(N=h.from(N,B),B=""),Q=!0),j(this,N,B,!1,Q)},P.prototype.unshift=function(N){return j(this,N,null,!0,!1)},P.prototype.isPaused=function(){return this._readableState.flowing===!1},P.prototype.setEncoding=function(N){return b||(b=n(26).StringDecoder),this._readableState.decoder=new b(N),this._readableState.encoding=N,this};var U=8388608;function V(N,B){return N<=0||B.length===0&&B.ended?0:B.objectMode?1:N!=N?B.flowing&&B.length?B.buffer.head.data.length:B.length:(N>B.highWaterMark&&(B.highWaterMark=function(Q){return Q>=U?Q=U:(Q--,Q|=Q>>>1,Q|=Q>>>2,Q|=Q>>>4,Q|=Q>>>8,Q|=Q>>>16,Q++),Q}(N)),N<=B.length?N:B.ended?B.length:(B.needReadable=!0,0))}function Y(N){var B=N._readableState;B.needReadable=!1,B.emittedReadable||(x("emitReadable",B.flowing),B.emittedReadable=!0,B.sync?a.nextTick(K,N):K(N))}function K(N){x("emit readable"),N.emit("readable"),ne(N)}function W(N,B){B.readingMore||(B.readingMore=!0,a.nextTick(ee,N,B))}function ee(N,B){for(var Q=B.length;!B.reading&&!B.flowing&&!B.ended&&B.length<B.highWaterMark&&(x("maybeReadMore read 0"),N.read(0),Q!==B.length);)Q=B.length;B.readingMore=!1}function ie(N){x("readable nexttick read 0"),N.read(0)}function X(N,B){B.reading||(x("resume read 0"),N.read(0)),B.resumeScheduled=!1,B.awaitDrain=0,N.emit("resume"),ne(N),B.flowing&&!B.reading&&N.read(0)}function ne(N){var B=N._readableState;for(x("flow",B.flowing);B.flowing&&N.read()!==null;);}function H(N,B){return B.length===0?null:(B.objectMode?Q=B.buffer.shift():!N||N>=B.length?(Q=B.decoder?B.buffer.join(""):B.buffer.length===1?B.buffer.head.data:B.buffer.concat(B.length),B.buffer.clear()):Q=function(G,ae,fe){var ce;return G<ae.head.data.length?(ce=ae.head.data.slice(0,G),ae.head.data=ae.head.data.slice(G)):ce=G===ae.head.data.length?ae.shift():fe?function(ye,F){var q=F.head,te=1,ue=q.data;for(ye-=ue.length;q=q.next;){var J=q.data,se=ye>J.length?J.length:ye;if(se===J.length?ue+=J:ue+=J.slice(0,ye),(ye-=se)==0){se===J.length?(++te,q.next?F.head=q.next:F.head=F.tail=null):(F.head=q,q.data=J.slice(se));break}++te}return F.length-=te,ue}(G,ae):function(ye,F){var q=h.allocUnsafe(ye),te=F.head,ue=1;for(te.data.copy(q),ye-=te.data.length;te=te.next;){var J=te.data,se=ye>J.length?J.length:ye;if(J.copy(q,q.length-ye,0,se),(ye-=se)==0){se===J.length?(++ue,te.next?F.head=te.next:F.head=F.tail=null):(F.head=te,te.data=J.slice(se));break}++ue}return F.length-=ue,q}(G,ae),ce}(N,B.buffer,B.decoder),Q);var Q}function I(N){var B=N._readableState;if(B.length>0)throw new Error('"endReadable()" called on non-empty stream');B.endEmitted||(B.ended=!0,a.nextTick(D,B,N))}function D(N,B){N.endEmitted||N.length!==0||(N.endEmitted=!0,B.readable=!1,B.emit("end"))}function z(N,B){for(var Q=0,G=N.length;Q<G;Q++)if(N[Q]===B)return Q;return-1}P.prototype.read=function(N){x("read",N),N=parseInt(N,10);var B=this._readableState,Q=N;if(N!==0&&(B.emittedReadable=!1),N===0&&B.needReadable&&(B.length>=B.highWaterMark||B.ended))return x("read: emitReadable",B.length,B.ended),B.length===0&&B.ended?I(this):Y(this),null;if((N=V(N,B))===0&&B.ended)return B.length===0&&I(this),null;var G,ae=B.needReadable;return x("need readable",ae),(B.length===0||B.length-N<B.highWaterMark)&&x("length less than watermark",ae=!0),B.ended||B.reading?x("reading or ended",ae=!1):ae&&(x("do read"),B.reading=!0,B.sync=!0,B.length===0&&(B.needReadable=!0),this._read(B.highWaterMark),B.sync=!1,B.reading||(N=V(Q,B))),(G=N>0?H(N,B):null)===null?(B.needReadable=!0,N=0):B.length-=N,B.length===0&&(B.ended||(B.needReadable=!0),Q!==N&&B.ended&&I(this)),G!==null&&this.emit("data",G),G},P.prototype._read=function(N){this.emit("error",new Error("_read() is not implemented"))},P.prototype.pipe=function(N,B){var Q=this,G=this._readableState;switch(G.pipesCount){case 0:G.pipes=N;break;case 1:G.pipes=[G.pipes,N];break;default:G.pipes.push(N)}G.pipesCount+=1,x("pipe count=%d opts=%j",G.pipesCount,B);var ae=B&&B.end===!1||N===i.stdout||N===i.stderr?se:fe;function fe(){x("onend"),N.end()}G.endEmitted?a.nextTick(ae):Q.once("end",ae),N.on("unpipe",function de(ve,he){x("onunpipe"),ve===Q&&he&&he.hasUnpiped===!1&&(he.hasUnpiped=!0,x("cleanup"),N.removeListener("close",ue),N.removeListener("finish",J),N.removeListener("drain",ce),N.removeListener("error",te),N.removeListener("unpipe",de),Q.removeListener("end",fe),Q.removeListener("end",se),Q.removeListener("data",q),ye=!0,!G.awaitDrain||N._writableState&&!N._writableState.needDrain||ce())});var ce=function(de){return function(){var ve=de._readableState;x("pipeOnDrain",ve.awaitDrain),ve.awaitDrain&&ve.awaitDrain--,ve.awaitDrain===0&&f(de,"data")&&(ve.flowing=!0,ne(de))}}(Q);N.on("drain",ce);var ye=!1,F=!1;function q(de){x("ondata"),F=!1,N.write(de)!==!1||F||((G.pipesCount===1&&G.pipes===N||G.pipesCount>1&&z(G.pipes,N)!==-1)&&!ye&&(x("false write response, pause",Q._readableState.awaitDrain),Q._readableState.awaitDrain++,F=!0),Q.pause())}function te(de){x("onerror",de),se(),N.removeListener("error",te),f(N,"error")===0&&N.emit("error",de)}function ue(){N.removeListener("finish",J),se()}function J(){x("onfinish"),N.removeListener("close",ue),se()}function se(){x("unpipe"),Q.unpipe(N)}return Q.on("data",q),function(de,ve,he){if(typeof de.prependListener=="function")return de.prependListener(ve,he);de._events&&de._events[ve]?l(de._events[ve])?de._events[ve].unshift(he):de._events[ve]=[he,de._events[ve]]:de.on(ve,he)}(N,"error",te),N.once("close",ue),N.once("finish",J),N.emit("pipe",Q),G.flowing||(x("pipe resume"),Q.resume()),N},P.prototype.unpipe=function(N){var B=this._readableState,Q={hasUnpiped:!1};if(B.pipesCount===0)return this;if(B.pipesCount===1)return N&&N!==B.pipes?this:(N||(N=B.pipes),B.pipes=null,B.pipesCount=0,B.flowing=!1,N&&N.emit("unpipe",this,Q),this);if(!N){var G=B.pipes,ae=B.pipesCount;B.pipes=null,B.pipesCount=0,B.flowing=!1;for(var fe=0;fe<ae;fe++)G[fe].emit("unpipe",this,Q);return this}var ce=z(B.pipes,N);return ce===-1?this:(B.pipes.splice(ce,1),B.pipesCount-=1,B.pipesCount===1&&(B.pipes=B.pipes[0]),N.emit("unpipe",this,Q),this)},P.prototype.on=function(N,B){var Q=u.prototype.on.call(this,N,B);if(N==="data")this._readableState.flowing!==!1&&this.resume();else if(N==="readable"){var G=this._readableState;G.endEmitted||G.readableListening||(G.readableListening=G.needReadable=!0,G.emittedReadable=!1,G.reading?G.length&&Y(this):a.nextTick(ie,this))}return Q},P.prototype.addListener=P.prototype.on,P.prototype.resume=function(){var N=this._readableState;return N.flowing||(x("resume"),N.flowing=!0,function(B,Q){Q.resumeScheduled||(Q.resumeScheduled=!0,a.nextTick(X,B,Q))}(this,N)),this},P.prototype.pause=function(){return x("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(x("pause"),this._readableState.flowing=!1,this.emit("pause")),this},P.prototype.wrap=function(N){var B=this,Q=this._readableState,G=!1;for(var ae in N.on("end",function(){if(x("wrapped end"),Q.decoder&&!Q.ended){var ce=Q.decoder.end();ce&&ce.length&&B.push(ce)}B.push(null)}),N.on("data",function(ce){x("wrapped data"),Q.decoder&&(ce=Q.decoder.write(ce)),(!Q.objectMode||ce!=null)&&(Q.objectMode||ce&&ce.length)&&(B.push(ce)||(G=!0,N.pause()))}),N)this[ae]===void 0&&typeof N[ae]=="function"&&(this[ae]=function(ce){return function(){return N[ce].apply(N,arguments)}}(ae));for(var fe=0;fe<A.length;fe++)N.on(A[fe],this.emit.bind(this,A[fe]));return this._read=function(ce){x("wrapped _read",ce),G&&(G=!1,N.resume())},this},Object.defineProperty(P.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),P._fromList=H}).call(this,n(0),n(4))},function(e,t,n){e.exports=n(12).EventEmitter},function(e,t,n){var r=n(6);function i(a,o){a.emit("error",o)}e.exports={destroy:function(a,o){var l=this,f=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return f||u?(o?o(a):!a||this._writableState&&this._writableState.errorEmitted||r.nextTick(i,this,a),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(a||null,function(h){!o&&h?(r.nextTick(i,l,h),l._writableState&&(l._writableState.errorEmitted=!0)):o&&o(h)}),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},function(e,t,n){var r=n(7).Buffer,i=r.isEncoding||function(x){switch((x=""+x)&&x.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function a(x){var b;switch(this.encoding=function(S){var C=function(A){if(!A)return"utf8";for(var O;;)switch(A){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return A;default:if(O)return;A=(""+A).toLowerCase(),O=!0}}(S);if(typeof C!="string"&&(r.isEncoding===i||!i(S)))throw new Error("Unknown encoding: "+S);return C||S}(x),this.encoding){case"utf16le":this.text=f,this.end=u,b=4;break;case"utf8":this.fillLast=l,b=4;break;case"base64":this.text=h,this.end=m,b=3;break;default:return this.write=g,void(this.end=_)}this.lastNeed=0,this.lastTotal=0,this.lastChar=r.allocUnsafe(b)}function o(x){return x<=127?0:x>>5==6?2:x>>4==14?3:x>>3==30?4:x>>6==2?-1:-2}function l(x){var b=this.lastTotal-this.lastNeed,S=function(C,A,O){if((192&A[0])!=128)return C.lastNeed=0,"<22>";if(C.lastNeed>1&&A.length>1){if((192&A[1])!=128)return C.lastNeed=1,"<22>";if(C.lastNeed>2&&A.length>2&&(192&A[2])!=128)return C.lastNeed=2,"<22>"}}(this,x);return S!==void 0?S:this.lastNeed<=x.length?(x.copy(this.lastChar,b,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(x.copy(this.lastChar,b,0,x.length),void(this.lastNeed-=x.length))}function f(x,b){if((x.length-b)%2==0){var S=x.toString("utf16le",b);if(S){var C=S.charCodeAt(S.length-1);if(C>=55296&&C<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=x[x.length-2],this.lastChar[1]=x[x.length-1],S.slice(0,-1)}return S}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=x[x.length-1],x.toString("utf16le",b,x.length-1)}function u(x){var b=x&&x.length?this.write(x):"";if(this.lastNeed){var S=this.lastTotal-this.lastNeed;return b+this.lastChar.toString("utf16le",0,S)}return b}function h(x,b){var S=(x.length-b)%3;return S===0?x.toString("base64",b):(this.lastNeed=3-S,this.lastTotal=3,S===1?this.lastChar[0]=x[x.length-1]:(this.lastChar[0]=x[x.length-2],this.lastChar[1]=x[x.length-1]),x.toString("base64",b,x.length-S))}function m(x){var b=x&&x.length?this.write(x):"";return this.lastNeed?b+this.lastChar.toString("base64",0,3-this.lastNeed):b}function g(x){return x.toString(this.encoding)}function _(x){return x&&x.length?this.write(x):""}t.StringDecoder=a,a.prototype.write=function(x){if(x.length===0)return"";var b,S;if(this.lastNeed){if((b=this.fillLast(x))===void 0)return"";S=this.lastNeed,this.lastNeed=0}else S=0;return S<x.length?b?b+this.text(x,S):this.text(x,S):b||""},a.prototype.end=function(x){var b=x&&x.length?this.write(x):"";return this.lastNeed?b+"<22>":b},a.prototype.text=function(x,b){var S=function(A,O,P){var j=O.length-1;if(j<P)return 0;var R=o(O[j]);return R>=0?(R>0&&(A.lastNeed=R-1),R):--j<P||R===-2?0:(R=o(O[j]))>=0?(R>0&&(A.lastNeed=R-2),R):--j<P||R===-2?0:(R=o(O[j]))>=0?(R>0&&(R===2?R=0:A.lastNeed=R-3),R):0}(this,x,b);if(!this.lastNeed)return x.toString("utf8",b);this.lastTotal=S;var C=x.length-(S-this.lastNeed);return x.copy(this.lastChar,0,C),x.toString("utf8",b,C)},a.prototype.fillLast=function(x){if(this.lastNeed<=x.length)return x.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);x.copy(this.lastChar,this.lastTotal-this.lastNeed,0,x.length),this.lastNeed-=x.length}},function(e,t,n){e.exports=a;var r=n(1),i=n(5);function a(f){if(!(this instanceof a))return new a(f);r.call(this,f),this._transformState={afterTransform:(function(u,h){var m=this._transformState;m.transforming=!1;var g=m.writecb;if(!g)return this.emit("error",new Error("write callback called multiple times"));m.writechunk=null,m.writecb=null,h!=null&&this.push(h),g(u);var _=this._readableState;_.reading=!1,(_.needReadable||_.length<_.highWaterMark)&&this._read(_.highWaterMark)}).bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,f&&(typeof f.transform=="function"&&(this._transform=f.transform),typeof f.flush=="function"&&(this._flush=f.flush)),this.on("prefinish",o)}function o(){var f=this;typeof this._flush=="function"?this._flush(function(u,h){l(f,u,h)}):l(this,null,null)}function l(f,u,h){if(u)return f.emit("error",u);if(h!=null&&f.push(h),f._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(f._transformState.transforming)throw new Error("Calling transform done when still transforming");return f.push(null)}i.inherits=n(2),i.inherits(a,r),a.prototype.push=function(f,u){return this._transformState.needTransform=!1,r.prototype.push.call(this,f,u)},a.prototype._transform=function(f,u,h){throw new Error("_transform() is not implemented")},a.prototype._write=function(f,u,h){var m=this._transformState;if(m.writecb=h,m.writechunk=f,m.writeencoding=u,!m.transforming){var g=this._readableState;(m.needTransform||g.needReadable||g.length<g.highWaterMark)&&this._read(g.highWaterMark)}},a.prototype._read=function(f){var u=this._transformState;u.writechunk!==null&&u.writecb&&!u.transforming?(u.transforming=!0,this._transform(u.writechunk,u.writeencoding,u.afterTransform)):u.needTransform=!0},a.prototype._destroy=function(f,u){var h=this;r.prototype._destroy.call(this,f,function(m){u(m),h.emit("close")})}},function(e,t,n){(function(r){Object.defineProperty(t,"__esModule",{value:!0}),t.bufFromString=function(i){var a=r.byteLength(i),o=r.allocUnsafe?r.allocUnsafe(a):new r(a);return o.write(i),o},t.emptyBuffer=function(){return r.allocUnsafe?r.allocUnsafe(0):new r(0)},t.filterArray=function(i,a){for(var o=[],l=0;l<i.length;l++)a.indexOf(l)>-1&&o.push(i[l]);return o},t.trimLeft=String.prototype.trimLeft?function(i){return i.trimLeft()}:function(i){return i.replace(/^\s+/,"")},t.trimRight=String.prototype.trimRight?function(i){return i.trimRight()}:function(i){return i.replace(/\s+$/,"")}}).call(this,n(3).Buffer)},function(e,t,n){var r=this&&this.__extends||function(){var a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,l){o.__proto__=l}||function(o,l){for(var f in l)l.hasOwnProperty(f)&&(o[f]=l[f])};return function(o,l){function f(){this.constructor=o}a(o,l),o.prototype=l===null?Object.create(l):(f.prototype=l.prototype,new f)}}();Object.defineProperty(t,"__esModule",{value:!0});var i=function(a){function o(l,f,u){var h=a.call(this,"Error: "+l+". JSON Line number: "+f+(u?" near: "+u:""))||this;return h.err=l,h.line=f,h.extra=u,h.name="CSV Parse Error",h}return r(o,a),o.column_mismatched=function(l,f){return new o("column_mismatched",l,f)},o.unclosed_quote=function(l,f){return new o("unclosed_quote",l,f)},o.fromJSON=function(l){return new o(l.err,l.line,l.extra)},o.prototype.toJSON=function(){return{err:this.err,line:this.line,extra:this.extra}},o}(Error);t.default=i},function(e,t,n){var r=n(18),i=n(68),a=n(69),o=r?r.toStringTag:void 0;e.exports=function(l){return l==null?l===void 0?"[object Undefined]":"[object Null]":o&&o in Object(l)?i(l):a(l)}},function(e,t){e.exports=function(n,r){return n===r||n!=n&&r!=r}},function(e,t,n){e.exports=n(33)},function(e,t,n){var r=n(34),i=function(a,o){return new r.Converter(a,o)};i.csv=i,i.Converter=r.Converter,e.exports=i},function(e,t,n){(function(r){var i=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,b){x.__proto__=b}||function(x,b){for(var S in b)b.hasOwnProperty(S)&&(x[S]=b[S])};return function(x,b){function S(){this.constructor=x}_(x,b),x.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}}(),a=this&&this.__importDefault||function(_){return _&&_.__esModule?_:{default:_}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(36),l=n(50),f=n(51),u=a(n(15)),h=n(52),m=n(105),g=function(_){function x(b,S){S===void 0&&(S={});var C=_.call(this,S)||this;return C.options=S,C.params=l.mergeParams(b),C.runtime=f.initParseRuntime(C),C.result=new m.Result(C),C.processor=new h.ProcessorLocal(C),C.once("error",function(A){r(function(){C.result.processError(A),C.emit("done",A)})}),C.once("done",function(){C.processor.destroy()}),C}return i(x,_),x.prototype.preRawData=function(b){return this.runtime.preRawDataHook=b,this},x.prototype.preFileLine=function(b){return this.runtime.preFileLineHook=b,this},x.prototype.subscribe=function(b,S,C){return this.parseRuntime.subscribe={onNext:b,onError:S,onCompleted:C},this},x.prototype.fromFile=function(b,S){var C=this,A=n(!function(){var O=new Error("Cannot find module 'fs'");throw O.code="MODULE_NOT_FOUND",O}());return A.exists(b,function(O){O?A.createReadStream(b,S).pipe(C):C.emit("error",new Error("File does not exist. Check to make sure the file path to your csv is correct."))}),this},x.prototype.fromStream=function(b){return b.pipe(this),this},x.prototype.fromString=function(b){b.toString();var S=new o.Readable,C=0;return S._read=function(A){if(C>=b.length)this.push(null);else{var O=b.substr(C,A);this.push(O),C+=A}},this.fromStream(S)},x.prototype.then=function(b,S){var C=this;return new u.default(function(A,O){C.parseRuntime.then={onfulfilled:function(P){A(b?b(P):P)},onrejected:function(P){S?A(S(P)):O(P)}}})},Object.defineProperty(x.prototype,"parseParam",{get:function(){return this.params},enumerable:!0,configurable:!0}),Object.defineProperty(x.prototype,"parseRuntime",{get:function(){return this.runtime},enumerable:!0,configurable:!0}),x.prototype._transform=function(b,S,C){var A=this;this.processor.process(b).then(function(O){if(O.length>0)return A.runtime.started=!0,A.result.processResult(O)}).then(function(){A.emit("drained"),C()},function(O){A.runtime.hasError=!0,A.runtime.error=O,A.emit("error",O),C()})},x.prototype._flush=function(b){var S=this;this.processor.flush().then(function(C){if(C.length>0)return S.result.processResult(C)}).then(function(){S.processEnd(b)},function(C){S.emit("error",C),b()})},x.prototype.processEnd=function(b){this.result.endProcess(),this.emit("done"),b()},Object.defineProperty(x.prototype,"parsedLineNumber",{get:function(){return this.runtime.parsedLineNumber},enumerable:!0,configurable:!0}),x}(o.Transform);t.Converter=g}).call(this,n(11).setImmediate)},function(e,t,n){(function(r,i){(function(a,o){if(!a.setImmediate){var l,f=1,u={},h=!1,m=a.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(a);g=g&&g.setTimeout?g:a,{}.toString.call(a.process)==="[object process]"?l=function(b){i.nextTick(function(){x(b)})}:function(){if(a.postMessage&&!a.importScripts){var b=!0,S=a.onmessage;return a.onmessage=function(){b=!1},a.postMessage("","*"),a.onmessage=S,b}}()?function(){var b="setImmediate$"+Math.random()+"$",S=function(C){C.source===a&&typeof C.data=="string"&&C.data.indexOf(b)===0&&x(+C.data.slice(b.length))};a.addEventListener?a.addEventListener("message",S,!1):a.attachEvent("onmessage",S),l=function(C){a.postMessage(b+C,"*")}}():a.MessageChannel?function(){var b=new MessageChannel;b.port1.onmessage=function(S){x(S.data)},l=function(S){b.port2.postMessage(S)}}():m&&"onreadystatechange"in m.createElement("script")?function(){var b=m.documentElement;l=function(S){var C=m.createElement("script");C.onreadystatechange=function(){x(S),C.onreadystatechange=null,b.removeChild(C),C=null},b.appendChild(C)}}():l=function(b){setTimeout(x,0,b)},g.setImmediate=function(b){typeof b!="function"&&(b=new Function(""+b));for(var S=new Array(arguments.length-1),C=0;C<S.length;C++)S[C]=arguments[C+1];var A={callback:b,args:S};return u[f]=A,l(f),f++},g.clearImmediate=_}function _(b){delete u[b]}function x(b){if(h)setTimeout(x,0,b);else{var S=u[b];if(S){h=!0;try{(function(C){var A=C.callback,O=C.args;switch(O.length){case 0:A();break;case 1:A(O[0]);break;case 2:A(O[0],O[1]);break;case 3:A(O[0],O[1],O[2]);break;default:A.apply(o,O)}})(S)}finally{_(b),h=!1}}}}})(typeof self>"u"?r===void 0?this:r:self)}).call(this,n(0),n(4))},function(e,t,n){e.exports=i;var r=n(12).EventEmitter;function i(){r.call(this)}n(2)(i,r),i.Readable=n(13),i.Writable=n(46),i.Duplex=n(47),i.Transform=n(48),i.PassThrough=n(49),i.Stream=i,i.prototype.pipe=function(a,o){var l=this;function f(b){a.writable&&a.write(b)===!1&&l.pause&&l.pause()}function u(){l.readable&&l.resume&&l.resume()}l.on("data",f),a.on("drain",u),a._isStdio||o&&o.end===!1||(l.on("end",m),l.on("close",g));var h=!1;function m(){h||(h=!0,a.end())}function g(){h||(h=!0,typeof a.destroy=="function"&&a.destroy())}function _(b){if(x(),r.listenerCount(this,"error")===0)throw b}function x(){l.removeListener("data",f),a.removeListener("drain",u),l.removeListener("end",m),l.removeListener("close",g),l.removeListener("error",_),a.removeListener("error",_),l.removeListener("end",x),l.removeListener("close",x),a.removeListener("close",x)}return l.on("error",_),a.on("error",_),l.on("end",x),l.on("close",x),a.on("close",x),a.emit("pipe",l),a}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(r){return n.call(r)=="[object Array]"}},function(e,t,n){t.byteLength=function(g){var _=u(g),x=_[0],b=_[1];return 3*(x+b)/4-b},t.toByteArray=function(g){for(var _,x=u(g),b=x[0],S=x[1],C=new a(3*(b+S)/4-S),A=0,O=S>0?b-4:b,P=0;P<O;P+=4)_=i[g.charCodeAt(P)]<<18|i[g.charCodeAt(P+1)]<<12|i[g.charCodeAt(P+2)]<<6|i[g.charCodeAt(P+3)],C[A++]=_>>16&255,C[A++]=_>>8&255,C[A++]=255&_;return S===2&&(_=i[g.charCodeAt(P)]<<2|i[g.charCodeAt(P+1)]>>4,C[A++]=255&_),S===1&&(_=i[g.charCodeAt(P)]<<10|i[g.charCodeAt(P+1)]<<4|i[g.charCodeAt(P+2)]>>2,C[A++]=_>>8&255,C[A++]=255&_),C},t.fromByteArray=function(g){for(var _,x=g.length,b=x%3,S=[],C=0,A=x-b;C<A;C+=16383)S.push(m(g,C,C+16383>A?A:C+16383));return b===1?(_=g[x-1],S.push(r[_>>2]+r[_<<4&63]+"==")):b===2&&(_=(g[x-2]<<8)+g[x-1],S.push(r[_>>10]+r[_>>4&63]+r[_<<2&63]+"=")),S.join("")};for(var r=[],i=[],a=typeof Uint8Array<"u"?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=0,f=o.length;l<f;++l)r[l]=o[l],i[o.charCodeAt(l)]=l;function u(g){var _=g.length;if(_%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var x=g.indexOf("=");return x===-1&&(x=_),[x,x===_?0:4-x%4]}function h(g){return r[g>>18&63]+r[g>>12&63]+r[g>>6&63]+r[63&g]}function m(g,_,x){for(var b,S=[],C=_;C<x;C+=3)b=(g[C]<<16&16711680)+(g[C+1]<<8&65280)+(255&g[C+2]),S.push(h(b));return S.join("")}i[45]=62,i[95]=63},function(e,t){t.read=function(n,r,i,a,o){var l,f,u=8*o-a-1,h=(1<<u)-1,m=h>>1,g=-7,_=i?o-1:0,x=i?-1:1,b=n[r+_];for(_+=x,l=b&(1<<-g)-1,b>>=-g,g+=u;g>0;l=256*l+n[r+_],_+=x,g-=8);for(f=l&(1<<-g)-1,l>>=-g,g+=a;g>0;f=256*f+n[r+_],_+=x,g-=8);if(l===0)l=1-m;else{if(l===h)return f?NaN:1/0*(b?-1:1);f+=Math.pow(2,a),l-=m}return(b?-1:1)*f*Math.pow(2,l-a)},t.write=function(n,r,i,a,o,l){var f,u,h,m=8*l-o-1,g=(1<<m)-1,_=g>>1,x=o===23?Math.pow(2,-24)-Math.pow(2,-77):0,b=a?0:l-1,S=a?1:-1,C=r<0||r===0&&1/r<0?1:0;for(r=Math.abs(r),isNaN(r)||r===1/0?(u=isNaN(r)?1:0,f=g):(f=Math.floor(Math.log(r)/Math.LN2),r*(h=Math.pow(2,-f))<1&&(f--,h*=2),(r+=f+_>=1?x/h:x*Math.pow(2,1-_))*h>=2&&(f++,h/=2),f+_>=g?(u=0,f=g):f+_>=1?(u=(r*h-1)*Math.pow(2,o),f+=_):(u=r*Math.pow(2,_-1)*Math.pow(2,o),f=0));o>=8;n[i+b]=255&u,b+=S,u/=256,o-=8);for(f=f<<o|u,m+=o;m>0;n[i+b]=255&f,b+=S,f/=256,m-=8);n[i+b-S]|=128*C}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(r){return n.call(r)=="[object Array]"}},function(e,t){},function(e,t,n){var r=n(7).Buffer,i=n(43);function a(o,l,f){o.copy(l,f)}e.exports=function(){function o(){(function(l,f){if(!(l instanceof f))throw new TypeError("Cannot call a class as a function")})(this,o),this.head=null,this.tail=null,this.length=0}return o.prototype.push=function(l){var f={data:l,next:null};this.length>0?this.tail.next=f:this.head=f,this.tail=f,++this.length},o.prototype.unshift=function(l){var f={data:l,next:this.head};this.length===0&&(this.tail=f),this.head=f,++this.length},o.prototype.shift=function(){if(this.length!==0){var l=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,l}},o.prototype.clear=function(){this.head=this.tail=null,this.length=0},o.prototype.join=function(l){if(this.length===0)return"";for(var f=this.head,u=""+f.data;f=f.next;)u+=l+f.data;return u},o.prototype.concat=function(l){if(this.length===0)return r.alloc(0);if(this.length===1)return this.head.data;for(var f=r.allocUnsafe(l>>>0),u=this.head,h=0;u;)a(u.data,f,h),h+=u.data.length,u=u.next;return f},o}(),i&&i.inspect&&i.inspect.custom&&(e.exports.prototype[i.inspect.custom]=function(){var o=i.inspect({length:this.length});return this.constructor.name+" "+o})},function(e,t){},function(e,t,n){(function(r){function i(a){try{if(!r.localStorage)return!1}catch{return!1}var o=r.localStorage[a];return o!=null&&String(o).toLowerCase()==="true"}e.exports=function(a,o){if(i("noDeprecation"))return a;var l=!1;return function(){if(!l){if(i("throwDeprecation"))throw new Error(o);i("traceDeprecation")?console.trace(o):console.warn(o),l=!0}return a.apply(this,arguments)}}}).call(this,n(0))},function(e,t,n){e.exports=a;var r=n(27),i=n(5);function a(o){if(!(this instanceof a))return new a(o);r.call(this,o)}i.inherits=n(2),i.inherits(a,r),a.prototype._transform=function(o,l,f){f(null,o)}},function(e,t,n){e.exports=n(14)},function(e,t,n){e.exports=n(1)},function(e,t,n){e.exports=n(13).Transform},function(e,t,n){e.exports=n(13).PassThrough},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.mergeParams=function(r){var i={delimiter:",",ignoreColumns:void 0,includeColumns:void 0,quote:'"',trim:!0,checkType:!1,ignoreEmpty:!1,noheader:!1,headers:void 0,flatKeys:!1,maxRowLength:0,checkColumn:!1,escape:'"',colParser:{},eol:void 0,alwaysSplitAtEOL:!1,output:"json",nullObject:!1,downstreamFormat:"line",needEmitAll:!0};for(var a in r||(r={}),r)r.hasOwnProperty(a)&&(Array.isArray(r[a])?i[a]=[].concat(r[a]):i[a]=r[a]);return i}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.initParseRuntime=function(r){var i=r.parseParam,a={needProcessIgnoreColumn:!1,needProcessIncludeColumn:!1,selectedColumns:void 0,ended:!1,hasError:!1,error:void 0,delimiter:r.parseParam.delimiter,eol:r.parseParam.eol,columnConv:[],headerType:[],headerTitle:[],headerFlag:[],headers:void 0,started:!1,parsedLineNumber:0,columnValueSetter:[]};return i.ignoreColumns&&(a.needProcessIgnoreColumn=!0),i.includeColumns&&(a.needProcessIncludeColumn=!0),a}},function(e,t,n){(function(r){var i=this&&this.__extends||function(){var S=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(C,A){C.__proto__=A}||function(C,A){for(var O in A)A.hasOwnProperty(O)&&(C[O]=A[O])};return function(C,A){function O(){this.constructor=C}S(C,A),C.prototype=A===null?Object.create(A):(O.prototype=A.prototype,new O)}}(),a=this&&this.__importDefault||function(S){return S&&S.__esModule?S:{default:S}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(53),l=a(n(15)),f=n(54),u=a(n(16)),h=n(57),m=n(28),g=n(58),_=a(n(59)),x=a(n(29)),b=function(S){function C(){var A=S!==null&&S.apply(this,arguments)||this;return A.rowSplit=new g.RowSplit(A.converter),A.eolEmitted=!1,A._needEmitEol=void 0,A.headEmitted=!1,A._needEmitHead=void 0,A}return i(C,S),C.prototype.flush=function(){var A=this;if(this.runtime.csvLineBuffer&&this.runtime.csvLineBuffer.length>0){var O=this.runtime.csvLineBuffer;return this.runtime.csvLineBuffer=void 0,this.process(O,!0).then(function(P){return A.runtime.csvLineBuffer&&A.runtime.csvLineBuffer.length>0?l.default.reject(x.default.unclosed_quote(A.runtime.parsedLineNumber,A.runtime.csvLineBuffer.toString())):l.default.resolve(P)})}return l.default.resolve([])},C.prototype.destroy=function(){return l.default.resolve()},Object.defineProperty(C.prototype,"needEmitEol",{get:function(){return this._needEmitEol===void 0&&(this._needEmitEol=this.converter.listeners("eol").length>0),this._needEmitEol},enumerable:!0,configurable:!0}),Object.defineProperty(C.prototype,"needEmitHead",{get:function(){return this._needEmitHead===void 0&&(this._needEmitHead=this.converter.listeners("header").length>0),this._needEmitHead},enumerable:!0,configurable:!0}),C.prototype.process=function(A,O){var P,j=this;return O===void 0&&(O=!1),P=O?A.toString():f.prepareData(A,this.converter.parseRuntime),l.default.resolve().then(function(){return j.runtime.preRawDataHook?j.runtime.preRawDataHook(P):P}).then(function(R){return R&&R.length>0?j.processCSV(R,O):l.default.resolve([])})},C.prototype.processCSV=function(A,O){var P=this,j=this.params,R=this.runtime;R.eol||u.default(A,R),this.needEmitEol&&!this.eolEmitted&&R.eol&&(this.converter.emit("eol",R.eol),this.eolEmitted=!0),j.ignoreEmpty&&!R.started&&(A=m.trimLeft(A));var U=h.stringToLines(A,R);return O?(U.lines.push(U.partial),U.partial=""):this.prependLeftBuf(m.bufFromString(U.partial)),U.lines.length>0?(R.preFileLineHook?this.runPreLineHook(U.lines):l.default.resolve(U.lines)).then(function(V){return R.started||P.runtime.headers?P.processCSVBody(V):P.processDataWithHead(V)}):l.default.resolve([])},C.prototype.processDataWithHead=function(A){if(this.params.noheader)this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=[];else{for(var O="",P=[];A.length;){var j=O+A.shift(),R=this.rowSplit.parse(j);if(R.closed){P=R.cells,O="";break}O=j+u.default(j,this.runtime)}if(this.prependLeftBuf(m.bufFromString(O)),P.length===0)return[];this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=P}return(this.runtime.needProcessIgnoreColumn||this.runtime.needProcessIncludeColumn)&&this.filterHeader(),this.needEmitHead&&!this.headEmitted&&(this.converter.emit("header",this.runtime.headers),this.headEmitted=!0),this.processCSVBody(A)},C.prototype.filterHeader=function(){if(this.runtime.selectedColumns=[],this.runtime.headers){for(var A=this.runtime.headers,O=0;O<A.length;O++)if(this.params.ignoreColumns)if(this.params.ignoreColumns.test(A[O])){if(!this.params.includeColumns||!this.params.includeColumns.test(A[O]))continue;this.runtime.selectedColumns.push(O)}else this.runtime.selectedColumns.push(O);else this.params.includeColumns?this.params.includeColumns.test(A[O])&&this.runtime.selectedColumns.push(O):this.runtime.selectedColumns.push(O);this.runtime.headers=m.filterArray(this.runtime.headers,this.runtime.selectedColumns)}},C.prototype.processCSVBody=function(A){if(this.params.output==="line")return A;var O=this.rowSplit.parseMultiLines(A);return this.prependLeftBuf(m.bufFromString(O.partial)),this.params.output==="csv"?O.rowsCells:_.default(O.rowsCells,this.converter)},C.prototype.prependLeftBuf=function(A){A&&(this.runtime.csvLineBuffer?this.runtime.csvLineBuffer=r.concat([A,this.runtime.csvLineBuffer]):this.runtime.csvLineBuffer=A)},C.prototype.runPreLineHook=function(A){var O=this;return new l.default(function(P,j){(function R(U,V,Y,K){if(Y>=U.length)K();else if(V.preFileLineHook){var W=U[Y],ee=V.preFileLineHook(W,V.parsedLineNumber+Y);if(Y++,ee&&ee.then)ee.then(function(ie){U[Y-1]=ie,R(U,V,Y,K)});else{for(U[Y-1]=ee;Y<U.length;)U[Y]=V.preFileLineHook(U[Y],V.parsedLineNumber+Y),Y++;K()}}else K()})(A,O.runtime,0,function(R){R?j(R):P(A)})})},C}(o.Processor);t.ProcessorLocal=b}).call(this,n(3).Buffer)},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(i){this.converter=i,this.params=i.parseParam,this.runtime=i.parseRuntime};t.Processor=r},function(e,t,n){(function(r){var i=this&&this.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(n(55));t.prepareData=function(o,l){var f=function(h,m){return m.csvLineBuffer&&m.csvLineBuffer.length>0?r.concat([m.csvLineBuffer,h]):h}(o,l);l.csvLineBuffer=void 0;var u=function(h,m){var g=h.length-1;if((128&h[g])!=0){for(;(192&h[g])==128;)g--;g--}return g!=h.length-1?(m.csvLineBuffer=h.slice(g+1),h.slice(0,g+1)):h}(f,l).toString("utf8");return l.started===!1?a.default(u):u}}).call(this,n(3).Buffer)},function(e,t,n){(function(r){var i=n(56);e.exports=function(a){return typeof a=="string"&&a.charCodeAt(0)===65279?a.slice(1):r.isBuffer(a)&&i(a)&&a[0]===239&&a[1]===187&&a[2]===191?a.slice(3):a}}).call(this,n(3).Buffer)},function(e,t){e.exports=function(n){for(var r=0;r<n.length;)if(n[r]==9||n[r]==10||n[r]==13||32<=n[r]&&n[r]<=126)r+=1;else if(194<=n[r]&&n[r]<=223&&128<=n[r+1]&&n[r+1]<=191)r+=2;else if(n[r]==224&&160<=n[r+1]&&n[r+1]<=191&&128<=n[r+2]&&n[r+2]<=191||(225<=n[r]&&n[r]<=236||n[r]==238||n[r]==239)&&128<=n[r+1]&&n[r+1]<=191&&128<=n[r+2]&&n[r+2]<=191||n[r]==237&&128<=n[r+1]&&n[r+1]<=159&&128<=n[r+2]&&n[r+2]<=191)r+=3;else{if(!(n[r]==240&&144<=n[r+1]&&n[r+1]<=191&&128<=n[r+2]&&n[r+2]<=191&&128<=n[r+3]&&n[r+3]<=191||241<=n[r]&&n[r]<=243&&128<=n[r+1]&&n[r+1]<=191&&128<=n[r+2]&&n[r+2]<=191&&128<=n[r+3]&&n[r+3]<=191||n[r]==244&&128<=n[r+1]&&n[r+1]<=143&&128<=n[r+2]&&n[r+2]<=191&&128<=n[r+3]&&n[r+3]<=191))return!1;r+=4}return!0}},function(e,t,n){var r=this&&this.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});var i=r(n(16));t.stringToLines=function(a,o){var l=i.default(a,o),f=a.split(l);return{lines:f,partial:f.pop()||""}}},function(e,t,n){var r=this&&this.__importDefault||function(f){return f&&f.__esModule?f:{default:f}};Object.defineProperty(t,"__esModule",{value:!0});var i=r(n(16)),a=n(28),o=[",","|"," ",";",":"],l=function(){function f(u){this.conv=u,this.cachedRegExp={},this.delimiterEmitted=!1,this._needEmitDelimiter=void 0,this.quote=u.parseParam.quote,this.trim=u.parseParam.trim,this.escape=u.parseParam.escape}return Object.defineProperty(f.prototype,"needEmitDelimiter",{get:function(){return this._needEmitDelimiter===void 0&&(this._needEmitDelimiter=this.conv.listeners("delimiter").length>0),this._needEmitDelimiter},enumerable:!0,configurable:!0}),f.prototype.parse=function(u){if(u.length===0||this.conv.parseParam.ignoreEmpty&&u.trim().length===0)return{cells:[],closed:!0};var h=this.quote,m=this.trim;this.escape,(this.conv.parseRuntime.delimiter instanceof Array||this.conv.parseRuntime.delimiter.toLowerCase()==="auto")&&(this.conv.parseRuntime.delimiter=this.getDelimiter(u)),this.needEmitDelimiter&&!this.delimiterEmitted&&(this.conv.emit("delimiter",this.conv.parseRuntime.delimiter),this.delimiterEmitted=!0);var g=this.conv.parseRuntime.delimiter,_=u.split(g);if(h==="off"){if(m)for(var x=0;x<_.length;x++)_[x]=_[x].trim();return{cells:_,closed:!0}}return this.toCSVRow(_,m,h,g)},f.prototype.toCSVRow=function(u,h,m,g){for(var _=[],x=!1,b="",S=0,C=u.length;S<C;S++){var A=u[S];!x&&h&&(A=a.trimLeft(A));var O=A.length;if(x)this.isQuoteClose(A)?(x=!1,b+=g+(A=A.substr(0,O-1)),b=this.escapeQuote(b),h&&(b=a.trimRight(b)),_.push(b),b=""):b+=g+A;else{if(O===2&&A===this.quote+this.quote){_.push("");continue}if(this.isQuoteOpen(A)){if(A=A.substr(1),this.isQuoteClose(A)){A=A.substring(0,A.lastIndexOf(m)),A=this.escapeQuote(A),_.push(A);continue}if(A.indexOf(m)!==-1){for(var P=0,j="",R=0,U=A;R<U.length;R++){var V=U[R];V===m&&j!==this.escape?(P++,j=""):j=V}if(P%2==1){h&&(A=a.trimRight(A)),_.push(m+A);continue}x=!0,b+=A;continue}x=!0,b+=A;continue}h&&(A=a.trimRight(A)),_.push(A)}}return{cells:_,closed:!x}},f.prototype.getDelimiter=function(u){var h;if(this.conv.parseParam.delimiter==="auto")h=o;else{if(!(this.conv.parseParam.delimiter instanceof Array))return this.conv.parseParam.delimiter;h=this.conv.parseParam.delimiter}var m=0,g=",";return h.forEach(function(_){var x=u.split(_).length;x>m&&(g=_,m=x)}),g},f.prototype.isQuoteOpen=function(u){var h=this.quote,m=this.escape;return u[0]===h&&(u[1]!==h||u[1]===m&&(u[2]===h||u.length===2))},f.prototype.isQuoteClose=function(u){var h=this.quote,m=this.escape;this.conv.parseParam.trim&&(u=a.trimRight(u));for(var g=0,_=u.length-1;u[_]===h||u[_]===m;)_--,g++;return g%2!=0},f.prototype.escapeQuote=function(u){var h="es|"+this.quote+"|"+this.escape;this.cachedRegExp[h]===void 0&&(this.cachedRegExp[h]=new RegExp("\\"+this.escape+"\\"+this.quote,"g"));var m=this.cachedRegExp[h];return u.replace(m,this.quote)},f.prototype.parseMultiLines=function(u){for(var h=[],m="";u.length;){var g=m+u.shift(),_=this.parse(g);_.cells.length===0&&this.conv.parseParam.ignoreEmpty||(_.closed||this.conv.parseParam.alwaysSplitAtEOL?(this.conv.parseRuntime.selectedColumns?h.push(a.filterArray(_.cells,this.conv.parseRuntime.selectedColumns)):h.push(_.cells),m=""):m=g+(i.default(g,this.conv.parseRuntime)||`
|
||
`))}return{rowsCells:h,partial:m}},f}();t.RowSplit=l},function(e,t,n){var r=this&&this.__importDefault||function(C){return C&&C.__esModule?C:{default:C}};Object.defineProperty(t,"__esModule",{value:!0});var i=r(n(29)),a=r(n(60)),o=/^[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?$/;function l(C,A,O){if(A.parseParam.checkColumn&&A.parseRuntime.headers&&C.length!==A.parseRuntime.headers.length)throw i.default.column_mismatched(A.parseRuntime.parsedLineNumber+O);return function(P,j,R){for(var U=!1,V={},Y=0,K=P.length;Y<K;Y++){var W=P[Y];if(!R.parseParam.ignoreEmpty||W!==""){U=!0;var ee=j[Y];ee&&ee!==""||(ee=j[Y]="field"+(Y+1));var ie=u(ee,Y,R);if(ie){var X=ie(W,ee,V,P,Y);X!==void 0&&h(V,ee,X,R,Y)}else R.parseParam.checkType&&(W=_(W,ee,Y,R)(W)),W!==void 0&&h(V,ee,W,R,Y)}}return U?V:null}(C,A.parseRuntime.headers||[],A)||null}t.default=function(C,A){for(var O=[],P=0,j=C.length;P<j;P++){var R=l(C[P],A,P);R&&O.push(R)}return O};var f={string:b,number:x,omit:function(){}};function u(C,A,O){if(O.parseRuntime.columnConv[A]!==void 0)return O.parseRuntime.columnConv[A];var P=O.parseParam.colParser[C];if(P===void 0)return O.parseRuntime.columnConv[A]=null;if(typeof P=="object"&&(P=P.cellParser||"string"),typeof P=="string"){P=P.trim().toLowerCase();var j=f[P];return O.parseRuntime.columnConv[A]=j||null}return O.parseRuntime.columnConv[A]=typeof P=="function"?P:null}function h(C,A,O,P,j){if(!P.parseRuntime.columnValueSetter[j])if(P.parseParam.flatKeys)P.parseRuntime.columnValueSetter[j]=m;else if(A.indexOf(".")>-1){for(var R=A.split("."),U=!0;R.length>0;)if(R.shift().length===0){U=!1;break}!U||P.parseParam.colParser[A]&&P.parseParam.colParser[A].flat?P.parseRuntime.columnValueSetter[j]=m:P.parseRuntime.columnValueSetter[j]=g}else P.parseRuntime.columnValueSetter[j]=m;P.parseParam.nullObject===!0&&O==="null"&&(O=null),P.parseRuntime.columnValueSetter[j](C,A,O)}function m(C,A,O){C[A]=O}function g(C,A,O){a.default(C,A,O)}function _(C,A,O,P){return P.parseRuntime.headerType[O]?P.parseRuntime.headerType[O]:A.indexOf("number#!")>-1?P.parseRuntime.headerType[O]=x:A.indexOf("string#!")>-1?P.parseRuntime.headerType[O]=b:P.parseParam.checkType?P.parseRuntime.headerType[O]=S:P.parseRuntime.headerType[O]=b}function x(C){var A=parseFloat(C);return isNaN(A)?C:A}function b(C){return C.toString()}function S(C){var A=C.trim();return A===""?b(C):o.test(A)?x(C):A.length===5&&A.toLowerCase()==="false"||A.length===4&&A.toLowerCase()==="true"?function(O){var P=O.trim();return P.length!==5||P.toLowerCase()!=="false"}(C):A[0]==="{"&&A[A.length-1]==="}"||A[0]==="["&&A[A.length-1]==="]"?function(O){try{return JSON.parse(O)}catch{return O}}(C):b(C)}},function(e,t,n){var r=n(61);e.exports=function(i,a,o){return i==null?i:r(i,a,o)}},function(e,t,n){var r=n(62),i=n(74),a=n(103),o=n(20),l=n(104);e.exports=function(f,u,h,m){if(!o(f))return f;for(var g=-1,_=(u=i(u,f)).length,x=_-1,b=f;b!=null&&++g<_;){var S=l(u[g]),C=h;if(g!=x){var A=b[S];(C=m?m(A,S,b):void 0)===void 0&&(C=o(A)?A:a(u[g+1])?[]:{})}r(b,S,C),b=b[S]}return f}},function(e,t,n){var r=n(63),i=n(31),a=Object.prototype.hasOwnProperty;e.exports=function(o,l,f){var u=o[l];a.call(o,l)&&i(u,f)&&(f!==void 0||l in o)||r(o,l,f)}},function(e,t,n){var r=n(64);e.exports=function(i,a,o){a=="__proto__"&&r?r(i,a,{configurable:!0,enumerable:!0,value:o,writable:!0}):i[a]=o}},function(e,t,n){var r=n(17),i=function(){try{var a=r(Object,"defineProperty");return a({},"",{}),a}catch{}}();e.exports=i},function(e,t,n){var r=n(66),i=n(70),a=n(20),o=n(72),l=/^\[object .+?Constructor\]$/,f=Function.prototype,u=Object.prototype,h=f.toString,m=u.hasOwnProperty,g=RegExp("^"+h.call(m).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(_){return!(!a(_)||i(_))&&(r(_)?g:l).test(o(_))}},function(e,t,n){var r=n(30),i=n(20);e.exports=function(a){if(!i(a))return!1;var o=r(a);return o=="[object Function]"||o=="[object GeneratorFunction]"||o=="[object AsyncFunction]"||o=="[object Proxy]"}},function(e,t,n){(function(r){var i=typeof r=="object"&&r&&r.Object===Object&&r;e.exports=i}).call(this,n(0))},function(e,t,n){var r=n(18),i=Object.prototype,a=i.hasOwnProperty,o=i.toString,l=r?r.toStringTag:void 0;e.exports=function(f){var u=a.call(f,l),h=f[l];try{f[l]=void 0;var m=!0}catch{}var g=o.call(f);return m&&(u?f[l]=h:delete f[l]),g}},function(e,t){var n=Object.prototype.toString;e.exports=function(r){return n.call(r)}},function(e,t,n){var r=n(71),i=function(){var a=/[^.]+$/.exec(r&&r.keys&&r.keys.IE_PROTO||"");return a?"Symbol(src)_1."+a:""}();e.exports=function(a){return!!i&&i in a}},function(e,t,n){var r=n(19)["__core-js_shared__"];e.exports=r},function(e,t){var n=Function.prototype.toString;e.exports=function(r){if(r!=null){try{return n.call(r)}catch{}try{return r+""}catch{}}return""}},function(e,t){e.exports=function(n,r){return n==null?void 0:n[r]}},function(e,t,n){var r=n(21),i=n(75),a=n(77),o=n(100);e.exports=function(l,f){return r(l)?l:i(l,f)?[l]:a(o(l))}},function(e,t,n){var r=n(21),i=n(22),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,o=/^\w*$/;e.exports=function(l,f){if(r(l))return!1;var u=typeof l;return!(u!="number"&&u!="symbol"&&u!="boolean"&&l!=null&&!i(l))||o.test(l)||!a.test(l)||f!=null&&l in Object(f)}},function(e,t){e.exports=function(n){return n!=null&&typeof n=="object"}},function(e,t,n){var r=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=n(78)(function(o){var l=[];return o.charCodeAt(0)===46&&l.push(""),o.replace(r,function(f,u,h,m){l.push(h?m.replace(i,"$1"):u||f)}),l});e.exports=a},function(e,t,n){var r=n(79);e.exports=function(i){var a=r(i,function(l){return o.size===500&&o.clear(),l}),o=a.cache;return a}},function(e,t,n){var r=n(80),i="Expected a function";function a(o,l){if(typeof o!="function"||l!=null&&typeof l!="function")throw new TypeError(i);var f=function(){var u=arguments,h=l?l.apply(this,u):u[0],m=f.cache;if(m.has(h))return m.get(h);var g=o.apply(this,u);return f.cache=m.set(h,g)||m,g};return f.cache=new(a.Cache||r),f}a.Cache=r,e.exports=a},function(e,t,n){var r=n(81),i=n(95),a=n(97),o=n(98),l=n(99);function f(u){var h=-1,m=u==null?0:u.length;for(this.clear();++h<m;){var g=u[h];this.set(g[0],g[1])}}f.prototype.clear=r,f.prototype.delete=i,f.prototype.get=a,f.prototype.has=o,f.prototype.set=l,e.exports=f},function(e,t,n){var r=n(82),i=n(88),a=n(94);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||i),string:new r}}},function(e,t,n){var r=n(83),i=n(84),a=n(85),o=n(86),l=n(87);function f(u){var h=-1,m=u==null?0:u.length;for(this.clear();++h<m;){var g=u[h];this.set(g[0],g[1])}}f.prototype.clear=r,f.prototype.delete=i,f.prototype.get=a,f.prototype.has=o,f.prototype.set=l,e.exports=f},function(e,t,n){var r=n(8);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},function(e,t){e.exports=function(n){var r=this.has(n)&&delete this.__data__[n];return this.size-=r?1:0,r}},function(e,t,n){var r=n(8),i=Object.prototype.hasOwnProperty;e.exports=function(a){var o=this.__data__;if(r){var l=o[a];return l==="__lodash_hash_undefined__"?void 0:l}return i.call(o,a)?o[a]:void 0}},function(e,t,n){var r=n(8),i=Object.prototype.hasOwnProperty;e.exports=function(a){var o=this.__data__;return r?o[a]!==void 0:i.call(o,a)}},function(e,t,n){var r=n(8);e.exports=function(i,a){var o=this.__data__;return this.size+=this.has(i)?0:1,o[i]=r&&a===void 0?"__lodash_hash_undefined__":a,this}},function(e,t,n){var r=n(89),i=n(90),a=n(91),o=n(92),l=n(93);function f(u){var h=-1,m=u==null?0:u.length;for(this.clear();++h<m;){var g=u[h];this.set(g[0],g[1])}}f.prototype.clear=r,f.prototype.delete=i,f.prototype.get=a,f.prototype.has=o,f.prototype.set=l,e.exports=f},function(e,t){e.exports=function(){this.__data__=[],this.size=0}},function(e,t,n){var r=n(9),i=Array.prototype.splice;e.exports=function(a){var o=this.__data__,l=r(o,a);return!(l<0||(l==o.length-1?o.pop():i.call(o,l,1),--this.size,0))}},function(e,t,n){var r=n(9);e.exports=function(i){var a=this.__data__,o=r(a,i);return o<0?void 0:a[o][1]}},function(e,t,n){var r=n(9);e.exports=function(i){return r(this.__data__,i)>-1}},function(e,t,n){var r=n(9);e.exports=function(i,a){var o=this.__data__,l=r(o,i);return l<0?(++this.size,o.push([i,a])):o[l][1]=a,this}},function(e,t,n){var r=n(17)(n(19),"Map");e.exports=r},function(e,t,n){var r=n(10);e.exports=function(i){var a=r(this,i).delete(i);return this.size-=a?1:0,a}},function(e,t){e.exports=function(n){var r=typeof n;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?n!=="__proto__":n===null}},function(e,t,n){var r=n(10);e.exports=function(i){return r(this,i).get(i)}},function(e,t,n){var r=n(10);e.exports=function(i){return r(this,i).has(i)}},function(e,t,n){var r=n(10);e.exports=function(i,a){var o=r(this,i),l=o.size;return o.set(i,a),this.size+=o.size==l?0:1,this}},function(e,t,n){var r=n(101);e.exports=function(i){return i==null?"":r(i)}},function(e,t,n){var r=n(18),i=n(102),a=n(21),o=n(22),l=r?r.prototype:void 0,f=l?l.toString:void 0;e.exports=function u(h){if(typeof h=="string")return h;if(a(h))return i(h,u)+"";if(o(h))return f?f.call(h):"";var m=h+"";return m=="0"&&1/h==-1/0?"-0":m}},function(e,t){e.exports=function(n,r){for(var i=-1,a=n==null?0:n.length,o=Array(a);++i<a;)o[i]=r(n[i],i,n);return o}},function(e,t){var n=/^(?:0|[1-9]\d*)$/;e.exports=function(r,i){var a=typeof r;return!!(i=i??9007199254740991)&&(a=="number"||a!="symbol"&&n.test(r))&&r>-1&&r%1==0&&r<i}},function(e,t,n){var r=n(22);e.exports=function(i){if(typeof i=="string"||r(i))return i;var a=i+"";return a=="0"&&1/i==-1/0?"-0":a}},function(e,t,n){var r=this&&this.__importDefault||function(f){return f&&f.__esModule?f:{default:f}};Object.defineProperty(t,"__esModule",{value:!0});var i=r(n(15)),a=n(106),o=function(){function f(u){this.converter=u,this.finalResult=[]}return Object.defineProperty(f.prototype,"needEmitLine",{get:function(){return!!this.converter.parseRuntime.subscribe&&!!this.converter.parseRuntime.subscribe.onNext||this.needPushDownstream},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"needPushDownstream",{get:function(){return this._needPushDownstream===void 0&&(this._needPushDownstream=this.converter.listeners("data").length>0||this.converter.listeners("readable").length>0),this._needPushDownstream},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"needEmitAll",{get:function(){return!!this.converter.parseRuntime.then&&this.converter.parseParam.needEmitAll},enumerable:!0,configurable:!0}),f.prototype.processResult=function(u){var h=this,m=this.converter.parseRuntime.parsedLineNumber;return this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&m===0&&l(this.converter,"["+a.EOL),new i.default(function(g,_){h.needEmitLine?function x(b,S,C,A,O){if(C>=b.length)O();else if(S.parseRuntime.subscribe&&S.parseRuntime.subscribe.onNext){var P=S.parseRuntime.subscribe.onNext,j=b[C],R=P(j,S.parseRuntime.parsedLineNumber+C);if(C++,R&&R.then)R.then(function(){(function(V,Y,K,W,ee,ie,X){ee&&l(K,X),x(V,K,W,ee,ie)})(b,0,S,C,A,O,j)},O);else{for(A&&l(S,j);C<b.length;){var U=b[C];P(U,S.parseRuntime.parsedLineNumber+C),C++,A&&l(S,U)}O()}}else{if(A)for(;C<b.length;)U=b[C++],l(S,U);O()}}(u,h.converter,0,h.needPushDownstream,function(x){x?_(x):(h.appendFinalResult(u),g())}):(h.appendFinalResult(u),g())})},f.prototype.appendFinalResult=function(u){this.needEmitAll&&(this.finalResult=this.finalResult.concat(u)),this.converter.parseRuntime.parsedLineNumber+=u.length},f.prototype.processError=function(u){this.converter.parseRuntime.subscribe&&this.converter.parseRuntime.subscribe.onError&&this.converter.parseRuntime.subscribe.onError(u),this.converter.parseRuntime.then&&this.converter.parseRuntime.then.onrejected&&this.converter.parseRuntime.then.onrejected(u)},f.prototype.endProcess=function(){this.converter.parseRuntime.then&&this.converter.parseRuntime.then.onfulfilled&&(this.needEmitAll?this.converter.parseRuntime.then.onfulfilled(this.finalResult):this.converter.parseRuntime.then.onfulfilled([])),this.converter.parseRuntime.subscribe&&this.converter.parseRuntime.subscribe.onCompleted&&this.converter.parseRuntime.subscribe.onCompleted(),this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&l(this.converter,"]"+a.EOL)},f}();function l(f,u){if(typeof u!="object"||f.options.objectMode)f.push(u);else{var h=JSON.stringify(u);f.push(h+(f.parseParam.downstreamFormat==="array"?","+a.EOL:a.EOL),"utf8")}}t.Result=o},function(e,t){t.endianness=function(){return"LE"},t.hostname=function(){return typeof location<"u"?location.hostname:""},t.loadavg=function(){return[]},t.uptime=function(){return 0},t.freemem=function(){return Number.MAX_VALUE},t.totalmem=function(){return Number.MAX_VALUE},t.cpus=function(){return[]},t.type=function(){return"Browser"},t.release=function(){return typeof navigator<"u"?navigator.appVersion:""},t.networkInterfaces=t.getNetworkInterfaces=function(){return{}},t.arch=function(){return"javascript"},t.platform=function(){return"browser"},t.tmpdir=t.tmpDir=function(){return"/tmp"},t.EOL=`
|
||
`,t.homedir=function(){return"/"}}])),RA}var I3e=D3e();const $3e=zt(I3e),B3e=e=>new Promise(t=>{$3e().fromString(e).then(t)}),U3e=new hU,z3e=e=>U3e.parse(e),F3e="shlink",H7=e=>`${F3e}.${e}`;class q3e{constructor(t){lf(this,"get",t=>{const n=this.localStorage.getItem(H7(t));return n?JSON.parse(n):void 0});lf(this,"set",(t,n)=>this.localStorage.setItem(H7(t),JSON.stringify(n)));this.localStorage=t}}class V3e{constructor(t){this.storage=t}getTagColors(){return this.storage.get("colors")??{}}storeTagColors(t){this.storage.set("colors",t)}}const H3e=e=>{e.constant("localStorage",window.localStorage),e.service("Storage",q3e,"localStorage"),e.service("TagColorsStorage",V3e,"Storage"),e.constant("csvToJson",B3e),e.constant("jsonToCsv",z3e),e.serviceFactory("useTimeoutToggle",()=>jT)},yc=new O9,{container:$4}=yc,G3e=(e,t)=>(...n)=>e[t](...n),W3e=(e,t)=>({...e,[t]:G3e($4,t)}),Y3e=e=>t=>Object.fromEntries(e.map(n=>[n,t[n]])),q1=(e,t=[])=>e9(e?Y3e(e):null,t.reduce(W3e,{}));Yne(yc,q1);FTe(yc,q1);AZ(yc);T3e(yc,q1);H3e(yc);k3e(yc,q1);var MA={},Sy={exports:{}},G7;function K3e(){return G7||(G7=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.isPlainObject=t.clone=t.recursive=t.merge=t.main=void 0,e.exports=t=n,t.default=n;function n(){for(var u=[],h=0;h<arguments.length;h++)u[h]=arguments[h];return r.apply(void 0,u)}t.main=n,n.clone=a,n.isPlainObject=o,n.recursive=i;function r(){for(var u=[],h=0;h<arguments.length;h++)u[h]=arguments[h];return f(u[0]===!0,!1,u)}t.merge=r;function i(){for(var u=[],h=0;h<arguments.length;h++)u[h]=arguments[h];return f(u[0]===!0,!0,u)}t.recursive=i;function a(u){if(Array.isArray(u)){for(var h=[],m=0;m<u.length;++m)h.push(a(u[m]));return h}else if(o(u)){var h={};for(var m in u)h[m]=a(u[m]);return h}else return u}t.clone=a;function o(u){return u&&typeof u=="object"&&!Array.isArray(u)}t.isPlainObject=o;function l(u,h){if(!o(u))return h;for(var m in h)m==="__proto__"||m==="constructor"||m==="prototype"||(u[m]=o(u[m])&&o(h[m])?l(u[m],h[m]):h[m]);return u}function f(u,h,m){var g;(u||!o(g=m.shift()))&&(g={});for(var _=0;_<m.length;++_){var x=m[_];if(o(x)){for(var b in x)if(!(b==="__proto__"||b==="constructor"||b==="prototype")){var S=u?a(x[b]):x[b];g[b]=h?l(g[b],S):S}}}return g}}(Sy,Sy.exports)),Sy.exports}var W7;function Z3e(){return W7||(W7=1,function(e){var t=n(K3e());Object.defineProperty(e,"__esModule",{value:!0}),e.clear=ie,e.combineLoads=ee,e.load=W,e.save=K;function n(z){return z&&z.__esModule?z:{default:z}}function r(z,N){return f(z)||l(z,N)||a(z,N)||i()}function i(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function a(z,N){if(z){if(typeof z=="string")return o(z,N);var B=Object.prototype.toString.call(z).slice(8,-1);return B==="Object"&&z.constructor&&(B=z.constructor.name),B==="Map"||B==="Set"?Array.from(z):B==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(B)?o(z,N):void 0}}function o(z,N){(N==null||N>z.length)&&(N=z.length);for(var B=0,Q=Array(N);B<N;B++)Q[B]=z[B];return Q}function l(z,N){var B=z==null?null:typeof Symbol<"u"&&z[Symbol.iterator]||z["@@iterator"];if(B!=null){var Q,G,ae=[],fe=!0,ce=!1;try{for(B=B.call(z);!(fe=(Q=B.next()).done)&&(ae.push(Q.value),!(N&&ae.length===N));fe=!0);}catch(ye){ce=!0,G=ye}finally{try{fe||B.return==null||B.return()}finally{if(ce)throw G}}return ae}}function f(z){if(Array.isArray(z))return z}function u(z){"@babel/helpers - typeof";return u=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(N){return typeof N}:function(N){return N&&typeof Symbol=="function"&&N.constructor===Symbol&&N!==Symbol.prototype?"symbol":typeof N},u(z)}function h(z,N,B){return N in z?Object.defineProperty(z,N,{value:B,enumerable:!0,configurable:!0,writable:!0}):z[N]=B,z}var m="[Redux-LocalStorage-Simple]",g="redux_localstorage_simple",_="_",x=[],b=[],S=0,C=!1,A=!1,O=new Map;function P(z){console.warn(m,z)}function j(){}var R=function(z){return z?j:P};function U(z,N){return N===void 0?null:z.length===1?N[z[0]]:U(z.slice(1),N[z[0]])}function V(z){function N(Q,G){return Q.length===0?G:N(Q.slice(1),h({},Q[0],G))}var B=1<arguments.length&&arguments[1]!==void 0?arguments[1]:{};return N(z.split(".").reverse(),B)}function Y(z){this.warnFn=z||P}Object.defineProperty(Y.prototype,"length",{get:function(){try{return localStorage.length}catch(z){this.warnFn(z)}return 0},configurable:!0,enumerable:!0}),Y.prototype.key=function(z){try{return localStorage.key(z)}catch(N){this.warnFn(N)}return null},Y.prototype.setItem=function(z,N){try{localStorage.setItem(z,JSON.stringify(N))}catch(B){this.warnFn(B)}},Y.prototype.getItem=function(z){try{return JSON.parse(localStorage.getItem(z))}catch(N){this.warnFn(N)}return null},Y.prototype.removeItem=function(z){try{localStorage.removeItem(z)}catch(N){this.warnFn(N)}};function K(){var z=0<arguments.length&&arguments[0]!==void 0?arguments[0]:{},N=z.states,B=N===void 0?x:N,Q=z.ignoreStates,G=Q===void 0?b:Q,ae=z.namespace,fe=ae===void 0?g:ae,ce=z.namespaceSeparator,ye=ce===void 0?_:ce,F=z.debounce,q=F===void 0?S:F,te=z.disableWarnings,ue=te===void 0?A:te;return function(J){return function(se){return function(de){function ve($e,ze){return 1<$e.split(".").length?U($e.split("."),ze):U([$e],ze)}function he(){B.length===0?He.setItem(fe,xe):B.forEach(function($e){var ze=fe+ye+$e,_e=ve($e,xe);_e?He.setItem(ze,_e):He.removeItem(ze)})}var xe,Oe=R(ue),Le=se(de);X(B)||(console.error(m,"'states' parameter in 'save()' method was passed a non-array value. Setting default value instead. Check your 'save()' method."),B=x),X(G)||(console.error(m,"'ignoreStates' parameter in 'save()' method was passed a non-array value. Setting default value instead. Check your 'save()' method."),G=b),0<G.length&&(G=G.filter(function($e){return ne($e)?$e:void console.error(m,"'ignoreStates' array contains a non-string value. Ignoring this value. Check your 'ignoreStates' array.")})),ne(fe)||(console.error(m,"'namespace' parameter in 'save()' method was passed a non-string value. Setting default value instead. Check your 'save()' method."),fe=g),ne(ye)||(console.error(m,"'namespaceSeparator' parameter in 'save()' method was passed a non-string value. Setting default value instead. Check your 'save()' method."),ye=_),H(q)||(console.error(m,"'debounce' parameter in 'save()' method was passed a non-integer value. Setting default value instead. Check your 'save()' method."),q=S),xe=0<G.length?D(G,J.getState()):J.getState();var He=new Y(Oe);return q?(O.get(B+fe)&&clearTimeout(O.get(B+fe)),O.set(B+fe,setTimeout(function(){he()},q))):he(),Le}}}}function W(){var z=0<arguments.length&&arguments[0]!==void 0?arguments[0]:{},N=z.states,B=N===void 0?x:N,Q=z.immutablejs,G=Q===void 0?C:Q,ae=z.namespace,fe=ae===void 0?g:ae,ce=z.namespaceSeparator,ye=ce===void 0?_:ce,F=z.preloadedState,q=F===void 0?{}:F,te=z.disableWarnings,ue=te===void 0?A:te,J=R(ue);X(B)||(console.error(m,"'states' parameter in 'load()' method was passed a non-array value. Setting default value instead. Check your 'load()' method."),B=x),ne(fe)||(console.error(m,"'namespace' parameter in 'load()' method was passed a non-string value. Setting default value instead. Check your 'load()' method."),fe=g),ne(ye)||(console.error(m,"'namespaceSeparator' parameter in 'load()' method was passed a non-string value. Setting default value instead. Check your 'load()' method."),ye=_),G===!0&&J("Support for Immutable.js data structures has been deprecated as of version 2.0.0. Please use version 1.4.0 if you require this functionality.");var se=new Y(J),de=q;if(B.length===0){var ve=se.getItem(fe);ve&&(de=ve)}else B.forEach(function(he){var xe=fe+ye+he,Oe=se.getItem(xe);Oe?de=t.default.recursive(de,V(he,Oe)):J("Invalid load '"+xe+"' provided. Check your 'states' in 'load()'. If this is your first time running this app you may see this message. To disable it in future use the 'disableWarnings' flag, see documentation.")});return de}function ee(){for(var z={},N=arguments.length,B=Array(N),Q=0;Q<N;Q++)B[Q]=arguments[Q];return B.forEach(function(G){for(var ae in I(G)||(console.error(m,"One or more loads provided to 'combineLoads()' is not a valid object. Ignoring the invalid load/s. Check your 'combineLoads()' method."),G={}),G)z[ae]=G[ae]}),z}function ie(){var z=0<arguments.length&&arguments[0]!==void 0?arguments[0]:{},N=z.namespace,B=N===void 0?g:N,Q=z.disableWarnings,G=Q===void 0?A:Q,ae=R(G);ne(B)||(console.error(m,"'namespace' parameter in 'clear()' method was passed a non-string value. Setting default value instead. Check your 'clear()' method."),B=g);for(var fe,ce=new Y(ae),ye=ce.length,F=0;F<ye;F++)fe=ce.key(F),fe&&fe.slice(0,B.length)===B&&ce.removeItem(fe)}function X(z){return Object.prototype.toString.call(z)==="[object Array]"}function ne(z){return typeof z=="string"}function H(z){return typeof z=="number"&&isFinite(z)&&Math.floor(z)===z}function I(z){return z!==null&&u(z)==="object"}function D(z,N){var B=Object.entries(N).reduce(function(Q,G){var ae=r(G,2),fe=ae[0];return ae[1],z.indexOf(fe)===-1&&(Q[fe]=N[fe]),Q},{});return B}}(MA)),MA}var eG=Z3e();const X3e=e=>UT({appUpdated:Wne,servers:f3e,selectedServer:e.selectedServerReducer,settings:N3e}),Q3e=e=>(e.settings&&e.settings.visits&&e.settings.visits.defaultInterval==="last180days"&&(e.settings.visits.defaultInterval="last180Days"),e),tG={states:["settings","servers"],namespace:"shlink",namespaceSeparator:".",debounce:300},J3e=Q3e(eG.load(tG)),e4e=e=>pB({devTools:!1,reducer:X3e(e),preloadedState:J3e,middleware:t=>t({immutableCheck:!1,serializableCheck:!1}).concat(eG.save(tG))}),t4e=!!(window.location.hostname==="localhost"||window.location.hostname==="[::1]"||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));function n4e(e){if("serviceWorker"in navigator){if(new URL(Iy.homepage,window.location.href).origin!==window.location.origin)return;window.addEventListener("load",()=>{const n=`${Iy.homepage}/service-worker.js`;t4e?(r4e(n,e),navigator.serviceWorker.ready.then(()=>{console.log("This web app is being served cache-first by a service worker. To learn more, visit https://cra.link/PWA")})):nG(n,e)})}}function nG(e,t){navigator.serviceWorker.register(e).then(n=>{n.onupdatefound=()=>{const r=n.installing;r!=null&&(r.onstatechange=()=>{r.state==="installed"&&(navigator.serviceWorker.controller?(console.log("New content is available and will be used when all tabs for this page are closed. See https://cra.link/PWA."),t&&t.onUpdate&&t.onUpdate(n)):(console.log("Content is cached for offline use."),t&&t.onSuccess&&t.onSuccess(n)))})}}).catch(n=>{console.error("Error during service worker registration:",n)})}function r4e(e,t){fetch(e,{headers:{"Service-Worker":"script"}}).then(n=>{const r=n.headers.get("content-type");n.status===404||r!=null&&r.indexOf("javascript")===-1?navigator.serviceWorker.ready.then(i=>{i.unregister().then(()=>{window.location.reload()})}):nG(e,t)}).catch(()=>{console.log("No internet connection found. App is running in offline mode.")})}const rG=e4e($4),{App:i4e,ScrollToTop:a4e,ErrorHandler:o4e,appUpdateAvailable:s4e}=$4;jW.createRoot(document.getElementById("root")).render(v.jsx(t9,{store:rG,children:v.jsx(p9,{basename:Iy.homepage,children:v.jsx(o4e,{children:v.jsx(a4e,{children:v.jsx(i4e,{})})})})}));n4e({onUpdate(){rG.dispatch(s4e())}});
|