var BW=Object.defineProperty;var UW=(e,t,n)=>t in e?BW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var Ql=(e,t,n)=>UW(e,typeof t!="symbol"?t+"":t,n);function zW(e,t){for(var n=0;nr[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function n(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=n(i);fetch(i.href,o)}})();var Ys=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function st(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function VW(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}var H$={exports:{}},T0={},G$={exports:{}},it={};/** * @license React * react.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 wp=Symbol.for("react.element"),WW=Symbol.for("react.portal"),HW=Symbol.for("react.fragment"),GW=Symbol.for("react.strict_mode"),qW=Symbol.for("react.profiler"),KW=Symbol.for("react.provider"),YW=Symbol.for("react.context"),ZW=Symbol.for("react.forward_ref"),XW=Symbol.for("react.suspense"),QW=Symbol.for("react.memo"),JW=Symbol.for("react.lazy"),Kj=Symbol.iterator;function eH(e){return e===null||typeof e!="object"?null:(e=Kj&&e[Kj]||e["@@iterator"],typeof e=="function"?e:null)}var q$={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},K$=Object.assign,Y$={};function Vc(e,t,n){this.props=e,this.context=t,this.refs=Y$,this.updater=n||q$}Vc.prototype.isReactComponent={};Vc.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Vc.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Z$(){}Z$.prototype=Vc.prototype;function sE(e,t,n){this.props=e,this.context=t,this.refs=Y$,this.updater=n||q$}var lE=sE.prototype=new Z$;lE.constructor=sE;K$(lE,Vc.prototype);lE.isPureReactComponent=!0;var Yj=Array.isArray,X$=Object.prototype.hasOwnProperty,uE={current:null},Q$={key:!0,ref:!0,__self:!0,__source:!0};function J$(e,t,n){var r,i={},o=null,a=null;if(t!=null)for(r in t.ref!==void 0&&(a=t.ref),t.key!==void 0&&(o=""+t.key),t)X$.call(t,r)&&!Q$.hasOwnProperty(r)&&(i[r]=t[r]);var s=arguments.length-2;if(s===1)i.children=n;else if(1>>1,ee=Z[H];if(0>>1;Hi(ie,B))aei(fe,ie)?(Z[H]=fe,Z[ae]=B,H=ae):(Z[H]=ie,Z[te]=B,H=te);else if(aei(fe,B))Z[H]=fe,Z[ae]=B,H=ae;else break e}}return z}function i(Z,z){var B=Z.sortIndex-z.sortIndex;return B!==0?B:Z.id-z.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}var l=[],u=[],f=1,d=null,h=3,v=!1,g=!1,y=!1,x=typeof setTimeout=="function"?setTimeout:null,_=typeof clearTimeout=="function"?clearTimeout:null,b=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function w(Z){for(var z=n(u);z!==null;){if(z.callback===null)r(u);else if(z.startTime<=Z)r(u),z.sortIndex=z.expirationTime,t(l,z);else break;z=n(u)}}function S(Z){if(y=!1,w(Z),!g)if(n(l)!==null)g=!0,Q(E);else{var z=n(u);z!==null&&ne(S,z.startTime-Z)}}function E(Z,z){g=!1,y&&(y=!1,_(A),A=-1),v=!0;var B=h;try{for(w(z),d=n(l);d!==null&&(!(d.expirationTime>z)||Z&&!I());){var H=d.callback;if(typeof H=="function"){d.callback=null,h=d.priorityLevel;var ee=H(d.expirationTime<=z);z=e.unstable_now(),typeof ee=="function"?d.callback=ee:d===n(l)&&r(l),w(z)}else r(l);d=n(l)}if(d!==null)var K=!0;else{var te=n(u);te!==null&&ne(S,te.startTime-z),K=!1}return K}finally{d=null,h=B,v=!1}}var P=!1,T=null,A=-1,D=5,k=-1;function I(){return!(e.unstable_now()-kZ||125H?(Z.sortIndex=B,t(u,Z),n(l)===null&&Z===n(u)&&(y?(_(A),A=-1):y=!0,ne(S,B-H))):(Z.sortIndex=ee,t(l,Z),g||v||(g=!0,Q(E))),Z},e.unstable_shouldYield=I,e.unstable_wrapCallback=function(Z){var z=h;return function(){var B=h;h=z;try{return Z.apply(this,arguments)}finally{h=B}}}})(iI);rI.exports=iI;var fH=rI.exports;/** * @license React * react-dom.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 dH=R,Ur=fH;function Oe(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Tx=Object.prototype.hasOwnProperty,hH=/^[: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]*$/,Xj={},Qj={};function pH(e){return Tx.call(Qj,e)?!0:Tx.call(Xj,e)?!1:hH.test(e)?Qj[e]=!0:(Xj[e]=!0,!1)}function mH(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function vH(e,t,n,r){if(t===null||typeof t>"u"||mH(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function hr(e,t,n,r,i,o,a){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var zn={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){zn[e]=new hr(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];zn[t]=new hr(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){zn[e]=new hr(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){zn[e]=new hr(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){zn[e]=new hr(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){zn[e]=new hr(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){zn[e]=new hr(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){zn[e]=new hr(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){zn[e]=new hr(e,5,!1,e.toLowerCase(),null,!1,!1)});var fE=/[\-:]([a-z])/g;function dE(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(fE,dE);zn[t]=new hr(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(fE,dE);zn[t]=new hr(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(fE,dE);zn[t]=new hr(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){zn[e]=new hr(e,1,!1,e.toLowerCase(),null,!1,!1)});zn.xlinkHref=new hr("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){zn[e]=new hr(e,1,!1,e.toLowerCase(),null,!0,!0)});function hE(e,t,n,r){var i=zn.hasOwnProperty(t)?zn[t]:null;(i!==null?i.type!==0:r||!(2s||i[a]!==o[s]){var l=` `+i[a].replace(" at new "," at ");return e.displayName&&l.includes("")&&(l=l.replace("",e.displayName)),l}while(1<=a&&0<=s);break}}}finally{B1=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?ld(e):""}function gH(e){switch(e.tag){case 5:return ld(e.type);case 16:return ld("Lazy");case 13:return ld("Suspense");case 19:return ld("SuspenseList");case 0:case 2:case 15:return e=U1(e.type,!1),e;case 11:return e=U1(e.type.render,!1),e;case 1:return e=U1(e.type,!0),e;default:return""}}function Nx(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case _u:return"Fragment";case bu:return"Portal";case jx:return"Profiler";case pE:return"StrictMode";case Ax:return"Suspense";case kx:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case sI:return(e.displayName||"Context")+".Consumer";case aI:return(e._context.displayName||"Context")+".Provider";case mE:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case vE:return t=e.displayName||null,t!==null?t:Nx(e.type)||"Memo";case Pa:t=e._payload,e=e._init;try{return Nx(e(t))}catch{}}return null}function yH(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Nx(t);case 8:return t===pE?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function es(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function uI(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function bH(e){var t=uI(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(a){r=""+a,o.call(this,a)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(a){r=""+a},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function km(e){e._valueTracker||(e._valueTracker=bH(e))}function cI(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=uI(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function ag(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Mx(e,t){var n=t.checked;return Ht({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function eA(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=es(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function fI(e,t){t=t.checked,t!=null&&hE(e,"checked",t,!1)}function Rx(e,t){fI(e,t);var n=es(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Lx(e,t.type,n):t.hasOwnProperty("defaultValue")&&Lx(e,t.type,es(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function tA(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Lx(e,t,n){(t!=="number"||ag(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var ud=Array.isArray;function Bu(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=Nm.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Jd(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var xd={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},_H=["Webkit","ms","Moz","O"];Object.keys(xd).forEach(function(e){_H.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),xd[t]=xd[e]})});function mI(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||xd.hasOwnProperty(e)&&xd[e]?(""+t).trim():t+"px"}function vI(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=mI(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var xH=Ht({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Dx(e,t){if(t){if(xH[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Oe(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Oe(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(Oe(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Oe(62))}}function Fx(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Bx=null;function gE(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Ux=null,Uu=null,zu=null;function iA(e){if(e=Ep(e)){if(typeof Ux!="function")throw Error(Oe(280));var t=e.stateNode;t&&(t=M0(t),Ux(e.stateNode,e.type,t))}}function gI(e){Uu?zu?zu.push(e):zu=[e]:Uu=e}function yI(){if(Uu){var e=Uu,t=zu;if(zu=Uu=null,iA(e),t)for(e=0;e>>=0,e===0?32:31-(NH(e)/MH|0)|0}var Mm=64,Rm=4194304;function cd(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function cg(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,o=e.pingedLanes,a=n&268435455;if(a!==0){var s=a&~i;s!==0?r=cd(s):(o&=a,o!==0&&(r=cd(o)))}else a=n&~i,a!==0?r=cd(a):o!==0&&(r=cd(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,o=t&-t,i>=o||i===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Op(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Ii(t),e[t]=n}function IH(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=Od),hA=" ",pA=!1;function DI(e,t){switch(e){case"keyup":return fG.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function FI(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var xu=!1;function hG(e,t){switch(e){case"compositionend":return FI(t);case"keypress":return t.which!==32?null:(pA=!0,hA);case"textInput":return e=t.data,e===hA&&pA?null:e;default:return null}}function pG(e,t){if(xu)return e==="compositionend"||!EE&&DI(e,t)?(e=$I(),Iv=wE=Ma=null,xu=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=yA(n)}}function VI(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?VI(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function WI(){for(var e=window,t=ag();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=ag(e.document)}return t}function PE(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function OG(e){var t=WI(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&VI(n.ownerDocument.documentElement,n)){if(r!==null&&PE(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,o=Math.min(r.start,i);r=r.end===void 0?o:Math.min(r.end,i),!e.extend&&o>r&&(i=r,r=o,o=i),i=bA(n,o);var a=bA(n,r);i&&a&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,wu=null,qx=null,Ed=null,Kx=!1;function _A(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Kx||wu==null||wu!==ag(r)||(r=wu,"selectionStart"in r&&PE(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Ed&&oh(Ed,r)||(Ed=r,r=hg(qx,"onSelect"),0Eu||(e.current=ew[Eu],ew[Eu]=null,Eu--)}function St(e,t){Eu++,ew[Eu]=e.current,e.current=t}var ts={},Yn=hs(ts),br=hs(!1),gl=ts;function Ju(e,t){var n=e.type.contextTypes;if(!n)return ts;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in n)i[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function _r(e){return e=e.childContextTypes,e!=null}function mg(){Nt(br),Nt(Yn)}function CA(e,t,n){if(Yn.current!==ts)throw Error(Oe(168));St(Yn,t),St(br,n)}function JI(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(Oe(108,yH(e)||"Unknown",i));return Ht({},n,r)}function vg(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||ts,gl=Yn.current,St(Yn,e),St(br,br.current),!0}function TA(e,t,n){var r=e.stateNode;if(!r)throw Error(Oe(169));n?(e=JI(e,t,gl),r.__reactInternalMemoizedMergedChildContext=e,Nt(br),Nt(Yn),St(Yn,e)):Nt(br),St(br,n)}var Io=null,R0=!1,t_=!1;function e6(e){Io===null?Io=[e]:Io.push(e)}function LG(e){R0=!0,e6(e)}function ps(){if(!t_&&Io!==null){t_=!0;var e=0,t=vt;try{var n=Io;for(vt=1;e>=a,i-=a,Do=1<<32-Ii(t)+i|n<A?(D=T,T=null):D=T.sibling;var k=h(_,T,w[A],S);if(k===null){T===null&&(T=D);break}e&&T&&k.alternate===null&&t(_,T),b=o(k,b,A),P===null?E=k:P.sibling=k,P=k,T=D}if(A===w.length)return n(_,T),Lt&&$s(_,A),E;if(T===null){for(;AA?(D=T,T=null):D=T.sibling;var I=h(_,T,k.value,S);if(I===null){T===null&&(T=D);break}e&&T&&I.alternate===null&&t(_,T),b=o(I,b,A),P===null?E=I:P.sibling=I,P=I,T=D}if(k.done)return n(_,T),Lt&&$s(_,A),E;if(T===null){for(;!k.done;A++,k=w.next())k=d(_,k.value,S),k!==null&&(b=o(k,b,A),P===null?E=k:P.sibling=k,P=k);return Lt&&$s(_,A),E}for(T=r(_,T);!k.done;A++,k=w.next())k=v(T,_,A,k.value,S),k!==null&&(e&&k.alternate!==null&&T.delete(k.key===null?A:k.key),b=o(k,b,A),P===null?E=k:P.sibling=k,P=k);return e&&T.forEach(function(F){return t(_,F)}),Lt&&$s(_,A),E}function x(_,b,w,S){if(typeof w=="object"&&w!==null&&w.type===_u&&w.key===null&&(w=w.props.children),typeof w=="object"&&w!==null){switch(w.$$typeof){case Am:e:{for(var E=w.key,P=b;P!==null;){if(P.key===E){if(E=w.type,E===_u){if(P.tag===7){n(_,P.sibling),b=i(P,w.props.children),b.return=_,_=b;break e}}else if(P.elementType===E||typeof E=="object"&&E!==null&&E.$$typeof===Pa&&kA(E)===P.type){n(_,P.sibling),b=i(P,w.props),b.ref=zf(_,P,w),b.return=_,_=b;break e}n(_,P);break}else t(_,P);P=P.sibling}w.type===_u?(b=ll(w.props.children,_.mode,S,w.key),b.return=_,_=b):(S=Hv(w.type,w.key,w.props,null,_.mode,S),S.ref=zf(_,b,w),S.return=_,_=S)}return a(_);case bu:e:{for(P=w.key;b!==null;){if(b.key===P)if(b.tag===4&&b.stateNode.containerInfo===w.containerInfo&&b.stateNode.implementation===w.implementation){n(_,b.sibling),b=i(b,w.children||[]),b.return=_,_=b;break e}else{n(_,b);break}else t(_,b);b=b.sibling}b=u_(w,_.mode,S),b.return=_,_=b}return a(_);case Pa:return P=w._init,x(_,b,P(w._payload),S)}if(ud(w))return g(_,b,w,S);if(If(w))return y(_,b,w,S);Um(_,w)}return typeof w=="string"&&w!==""||typeof w=="number"?(w=""+w,b!==null&&b.tag===6?(n(_,b.sibling),b=i(b,w),b.return=_,_=b):(n(_,b),b=l_(w,_.mode,S),b.return=_,_=b),a(_)):n(_,b)}return x}var tc=i6(!0),o6=i6(!1),bg=hs(null),_g=null,Tu=null,AE=null;function kE(){AE=Tu=_g=null}function NE(e){var t=bg.current;Nt(bg),e._currentValue=t}function rw(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Wu(e,t){_g=e,AE=Tu=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(gr=!0),e.firstContext=null)}function mi(e){var t=e._currentValue;if(AE!==e)if(e={context:e,memoizedValue:t,next:null},Tu===null){if(_g===null)throw Error(Oe(308));Tu=e,_g.dependencies={lanes:0,firstContext:e}}else Tu=Tu.next=e;return t}var Xs=null;function ME(e){Xs===null?Xs=[e]:Xs.push(e)}function a6(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,ME(t)):(n.next=i.next,i.next=n),t.interleaved=n,Yo(e,r)}function Yo(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Ca=!1;function RE(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function s6(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Vo(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Ha(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,ft&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,Yo(e,n)}return i=r.interleaved,i===null?(t.next=t,ME(r)):(t.next=i.next,i.next=t),r.interleaved=t,Yo(e,n)}function Fv(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,bE(e,n)}}function NA(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?i=o=a:o=o.next=a,n=n.next}while(n!==null);o===null?i=o=t:o=o.next=t}else i=o=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function xg(e,t,n,r){var i=e.updateQueue;Ca=!1;var o=i.firstBaseUpdate,a=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var l=s,u=l.next;l.next=null,a===null?o=u:a.next=u,a=l;var f=e.alternate;f!==null&&(f=f.updateQueue,s=f.lastBaseUpdate,s!==a&&(s===null?f.firstBaseUpdate=u:s.next=u,f.lastBaseUpdate=l))}if(o!==null){var d=i.baseState;a=0,f=u=l=null,s=o;do{var h=s.lane,v=s.eventTime;if((r&h)===h){f!==null&&(f=f.next={eventTime:v,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var g=e,y=s;switch(h=t,v=n,y.tag){case 1:if(g=y.payload,typeof g=="function"){d=g.call(v,d,h);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=y.payload,h=typeof g=="function"?g.call(v,d,h):g,h==null)break e;d=Ht({},d,h);break e;case 2:Ca=!0}}s.callback!==null&&s.lane!==0&&(e.flags|=64,h=i.effects,h===null?i.effects=[s]:h.push(s))}else v={eventTime:v,lane:h,tag:s.tag,payload:s.payload,callback:s.callback,next:null},f===null?(u=f=v,l=d):f=f.next=v,a|=h;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;h=s,s=h.next,h.next=null,i.lastBaseUpdate=h,i.shared.pending=null}}while(!0);if(f===null&&(l=d),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=f,t=i.shared.interleaved,t!==null){i=t;do a|=i.lane,i=i.next;while(i!==t)}else o===null&&(i.shared.lanes=0);_l|=a,e.lanes=a,e.memoizedState=d}}function MA(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=r_.transition;r_.transition={};try{e(!1),t()}finally{vt=n,r_.transition=r}}function S6(){return vi().memoizedState}function FG(e,t,n){var r=qa(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},E6(e))P6(t,n);else if(n=a6(e,t,n,r),n!==null){var i=lr();Di(n,e,r,i),C6(n,t,r)}}function BG(e,t,n){var r=qa(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(E6(e))P6(t,i);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var a=t.lastRenderedState,s=o(a,n);if(i.hasEagerState=!0,i.eagerState=s,Ui(s,a)){var l=t.interleaved;l===null?(i.next=i,ME(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}n=a6(e,t,i,r),n!==null&&(i=lr(),Di(n,e,r,i),C6(n,t,r))}}function E6(e){var t=e.alternate;return e===Vt||t!==null&&t===Vt}function P6(e,t){Pd=Og=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function C6(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,bE(e,n)}}var Sg={readContext:mi,useCallback:Vn,useContext:Vn,useEffect:Vn,useImperativeHandle:Vn,useInsertionEffect:Vn,useLayoutEffect:Vn,useMemo:Vn,useReducer:Vn,useRef:Vn,useState:Vn,useDebugValue:Vn,useDeferredValue:Vn,useTransition:Vn,useMutableSource:Vn,useSyncExternalStore:Vn,useId:Vn,unstable_isNewReconciler:!1},UG={readContext:mi,useCallback:function(e,t){return io().memoizedState=[e,t===void 0?null:t],e},useContext:mi,useEffect:LA,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Uv(4194308,4,b6.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Uv(4194308,4,e,t)},useInsertionEffect:function(e,t){return Uv(4,2,e,t)},useMemo:function(e,t){var n=io();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=io();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=FG.bind(null,Vt,e),[r.memoizedState,e]},useRef:function(e){var t=io();return e={current:e},t.memoizedState=e},useState:RA,useDebugValue:zE,useDeferredValue:function(e){return io().memoizedState=e},useTransition:function(){var e=RA(!1),t=e[0];return e=DG.bind(null,e[1]),io().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Vt,i=io();if(Lt){if(n===void 0)throw Error(Oe(407));n=n()}else{if(n=t(),Cn===null)throw Error(Oe(349));bl&30||f6(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,LA(h6.bind(null,r,o,e),[e]),r.flags|=2048,hh(9,d6.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=io(),t=Cn.identifierPrefix;if(Lt){var n=Fo,r=Do;n=(r&~(1<<32-Ii(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=fh++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=a.createElement(n,{is:r.is}):(e=a.createElement(n),n==="select"&&(a=e,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):e=a.createElementNS(e,n),e[lo]=t,e[lh]=r,I6(e,t,!1,!1),t.stateNode=e;e:{switch(a=Fx(n,r),n){case"dialog":Ct("cancel",e),Ct("close",e),i=r;break;case"iframe":case"object":case"embed":Ct("load",e),i=r;break;case"video":case"audio":for(i=0;iic&&(t.flags|=128,r=!0,Vf(o,!1),t.lanes=4194304)}else{if(!r)if(e=wg(a),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Vf(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!Lt)return Wn(t),null}else 2*tn()-o.renderingStartTime>ic&&n!==1073741824&&(t.flags|=128,r=!0,Vf(o,!1),t.lanes=4194304);o.isBackwards?(a.sibling=t.child,t.child=a):(n=o.last,n!==null?n.sibling=a:t.child=a,o.last=a)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=tn(),t.sibling=null,n=Ut.current,St(Ut,r?n&1|2:n&1),t):(Wn(t),null);case 22:case 23:return KE(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Rr&1073741824&&(Wn(t),t.subtreeFlags&6&&(t.flags|=8192)):Wn(t),null;case 24:return null;case 25:return null}throw Error(Oe(156,t.tag))}function YG(e,t){switch(TE(t),t.tag){case 1:return _r(t.type)&&mg(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return nc(),Nt(br),Nt(Yn),IE(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return $E(t),null;case 13:if(Nt(Ut),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(Oe(340));ec()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Nt(Ut),null;case 4:return nc(),null;case 10:return NE(t.type._context),null;case 22:case 23:return KE(),null;case 24:return null;default:return null}}var Vm=!1,Gn=!1,ZG=typeof WeakSet=="function"?WeakSet:Set,$e=null;function ju(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){qt(e,t,r)}else n.current=null}function dw(e,t,n){try{n()}catch(r){qt(e,t,r)}}var GA=!1;function XG(e,t){if(Yx=fg,e=WI(),PE(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var a=0,s=-1,l=-1,u=0,f=0,d=e,h=null;t:for(;;){for(var v;d!==n||i!==0&&d.nodeType!==3||(s=a+i),d!==o||r!==0&&d.nodeType!==3||(l=a+r),d.nodeType===3&&(a+=d.nodeValue.length),(v=d.firstChild)!==null;)h=d,d=v;for(;;){if(d===e)break t;if(h===n&&++u===i&&(s=a),h===o&&++f===r&&(l=a),(v=d.nextSibling)!==null)break;d=h,h=d.parentNode}d=v}n=s===-1||l===-1?null:{start:s,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Zx={focusedElem:e,selectionRange:n},fg=!1,$e=t;$e!==null;)if(t=$e,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,$e=e;else for(;$e!==null;){t=$e;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var y=g.memoizedProps,x=g.memoizedState,_=t.stateNode,b=_.getSnapshotBeforeUpdate(t.elementType===t.type?y:Ti(t.type,y),x);_.__reactInternalSnapshotBeforeUpdate=b}break;case 3:var w=t.stateNode.containerInfo;w.nodeType===1?w.textContent="":w.nodeType===9&&w.documentElement&&w.removeChild(w.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Oe(163))}}catch(S){qt(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,$e=e;break}$e=t.return}return g=GA,GA=!1,g}function Cd(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var o=i.destroy;i.destroy=void 0,o!==void 0&&dw(t,n,o)}i=i.next}while(i!==r)}}function I0(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function hw(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function B6(e){var t=e.alternate;t!==null&&(e.alternate=null,B6(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[lo],delete t[lh],delete t[Jx],delete t[MG],delete t[RG])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function U6(e){return e.tag===5||e.tag===3||e.tag===4}function qA(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||U6(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function pw(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=pg));else if(r!==4&&(e=e.child,e!==null))for(pw(e,t,n),e=e.sibling;e!==null;)pw(e,t,n),e=e.sibling}function mw(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(mw(e,t,n),e=e.sibling;e!==null;)mw(e,t,n),e=e.sibling}var Bn=null,ji=!1;function ga(e,t,n){for(n=n.child;n!==null;)z6(e,t,n),n=n.sibling}function z6(e,t,n){if(po&&typeof po.onCommitFiberUnmount=="function")try{po.onCommitFiberUnmount(j0,n)}catch{}switch(n.tag){case 5:Gn||ju(n,t);case 6:var r=Bn,i=ji;Bn=null,ga(e,t,n),Bn=r,ji=i,Bn!==null&&(ji?(e=Bn,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Bn.removeChild(n.stateNode));break;case 18:Bn!==null&&(ji?(e=Bn,n=n.stateNode,e.nodeType===8?e_(e.parentNode,n):e.nodeType===1&&e_(e,n),rh(e)):e_(Bn,n.stateNode));break;case 4:r=Bn,i=ji,Bn=n.stateNode.containerInfo,ji=!0,ga(e,t,n),Bn=r,ji=i;break;case 0:case 11:case 14:case 15:if(!Gn&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&dw(n,t,a),i=i.next}while(i!==r)}ga(e,t,n);break;case 1:if(!Gn&&(ju(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){qt(n,t,s)}ga(e,t,n);break;case 21:ga(e,t,n);break;case 22:n.mode&1?(Gn=(r=Gn)||n.memoizedState!==null,ga(e,t,n),Gn=r):ga(e,t,n);break;default:ga(e,t,n)}}function KA(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new ZG),t.forEach(function(r){var i=aq.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Pi(e,t){var n=t.deletions;if(n!==null)for(var r=0;ri&&(i=a),r&=~o}if(r=i,r=tn()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*JG(r/1960))-r,10e?16:e,Ra===null)var r=!1;else{if(e=Ra,Ra=null,Cg=0,ft&6)throw Error(Oe(331));var i=ft;for(ft|=4,$e=e.current;$e!==null;){var o=$e,a=o.child;if($e.flags&16){var s=o.deletions;if(s!==null){for(var l=0;ltn()-GE?sl(e,0):HE|=n),xr(e,t)}function Z6(e,t){t===0&&(e.mode&1?(t=Rm,Rm<<=1,!(Rm&130023424)&&(Rm=4194304)):t=1);var n=lr();e=Yo(e,t),e!==null&&(Op(e,t,n),xr(e,n))}function oq(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Z6(e,n)}function aq(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(Oe(314))}r!==null&&r.delete(t),Z6(e,n)}var X6;X6=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||br.current)gr=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return gr=!1,qG(e,t,n);gr=!!(e.flags&131072)}else gr=!1,Lt&&t.flags&1048576&&t6(t,yg,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;zv(e,t),e=t.pendingProps;var i=Ju(t,Yn.current);Wu(t,n),i=FE(null,t,r,e,i,n);var o=BE();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,_r(r)?(o=!0,vg(t)):o=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,RE(t),i.updater=$0,t.stateNode=i,i._reactInternals=t,ow(t,r,e,n),t=lw(null,t,r,!0,o,n)):(t.tag=0,Lt&&o&&CE(t),nr(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(zv(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=lq(r),e=Ti(r,e),i){case 0:t=sw(null,t,r,e,n);break e;case 1:t=VA(null,t,r,e,n);break e;case 11:t=UA(null,t,r,e,n);break e;case 14:t=zA(null,t,r,Ti(r.type,e),n);break e}throw Error(Oe(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ti(r,i),sw(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ti(r,i),VA(e,t,r,i,n);case 3:e:{if(R6(t),e===null)throw Error(Oe(387));r=t.pendingProps,o=t.memoizedState,i=o.element,s6(e,t),xg(t,r,null,n);var a=t.memoizedState;if(r=a.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){i=rc(Error(Oe(423)),t),t=WA(e,t,r,n,i);break e}else if(r!==i){i=rc(Error(Oe(424)),t),t=WA(e,t,r,n,i);break e}else for(Ir=Wa(t.stateNode.containerInfo.firstChild),Fr=t,Lt=!0,Ni=null,n=o6(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ec(),r===i){t=Zo(e,t,n);break e}nr(e,t,r,n)}t=t.child}return t;case 5:return l6(t),e===null&&nw(t),r=t.type,i=t.pendingProps,o=e!==null?e.memoizedProps:null,a=i.children,Xx(r,i)?a=null:o!==null&&Xx(r,o)&&(t.flags|=32),M6(e,t),nr(e,t,a,n),t.child;case 6:return e===null&&nw(t),null;case 13:return L6(e,t,n);case 4:return LE(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=tc(t,null,r,n):nr(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ti(r,i),UA(e,t,r,i,n);case 7:return nr(e,t,t.pendingProps,n),t.child;case 8:return nr(e,t,t.pendingProps.children,n),t.child;case 12:return nr(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,o=t.memoizedProps,a=i.value,St(bg,r._currentValue),r._currentValue=a,o!==null)if(Ui(o.value,a)){if(o.children===i.children&&!br.current){t=Zo(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var s=o.dependencies;if(s!==null){a=o.child;for(var l=s.firstContext;l!==null;){if(l.context===r){if(o.tag===1){l=Vo(-1,n&-n),l.tag=2;var u=o.updateQueue;if(u!==null){u=u.shared;var f=u.pending;f===null?l.next=l:(l.next=f.next,f.next=l),u.pending=l}}o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),rw(o.return,n,t),s.lanes|=n;break}l=l.next}}else if(o.tag===10)a=o.type===t.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(Oe(341));a.lanes|=n,s=a.alternate,s!==null&&(s.lanes|=n),rw(a,n,t),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===t){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}nr(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Wu(t,n),i=mi(i),r=r(i),t.flags|=1,nr(e,t,r,n),t.child;case 14:return r=t.type,i=Ti(r,t.pendingProps),i=Ti(r.type,i),zA(e,t,r,i,n);case 15:return k6(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:Ti(r,i),zv(e,t),t.tag=1,_r(r)?(e=!0,vg(t)):e=!1,Wu(t,n),T6(t,r,i),ow(t,r,i,n),lw(null,t,r,!0,e,n);case 19:return $6(e,t,n);case 22:return N6(e,t,n)}throw Error(Oe(156,t.tag))};function Q6(e,t){return EI(e,t)}function sq(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ci(e,t,n,r){return new sq(e,t,n,r)}function ZE(e){return e=e.prototype,!(!e||!e.isReactComponent)}function lq(e){if(typeof e=="function")return ZE(e)?1:0;if(e!=null){if(e=e.$$typeof,e===mE)return 11;if(e===vE)return 14}return 2}function Ka(e,t){var n=e.alternate;return n===null?(n=ci(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Hv(e,t,n,r,i,o){var a=2;if(r=e,typeof e=="function")ZE(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case _u:return ll(n.children,i,o,t);case pE:a=8,i|=8;break;case jx:return e=ci(12,n,t,i|2),e.elementType=jx,e.lanes=o,e;case Ax:return e=ci(13,n,t,i),e.elementType=Ax,e.lanes=o,e;case kx:return e=ci(19,n,t,i),e.elementType=kx,e.lanes=o,e;case lI:return F0(n,i,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case aI:a=10;break e;case sI:a=9;break e;case mE:a=11;break e;case vE:a=14;break e;case Pa:a=16,r=null;break e}throw Error(Oe(130,e==null?e:typeof e,""))}return t=ci(a,n,t,i),t.elementType=e,t.type=r,t.lanes=o,t}function ll(e,t,n,r){return e=ci(7,e,r,t),e.lanes=n,e}function F0(e,t,n,r){return e=ci(22,e,r,t),e.elementType=lI,e.lanes=n,e.stateNode={isHidden:!1},e}function l_(e,t,n){return e=ci(6,e,null,t),e.lanes=n,e}function u_(e,t,n){return t=ci(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function uq(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=V1(0),this.expirationTimes=V1(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=V1(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function XE(e,t,n,r,i,o,a,s,l){return e=new uq(e,t,n,s,l),t===1?(t=1,o===!0&&(t|=8)):t=0,o=ci(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},RE(o),e}function cq(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(nD)}catch(e){console.error(e)}}nD(),nI.exports=Hr;var W0=nI.exports;const Js=st(W0);var rD,nk=W0;rD=nk.createRoot,nk.hydrateRoot;var mq={};/** * @license React * use-sync-external-store-with-selector.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 Cp=R;function vq(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var gq=typeof Object.is=="function"?Object.is:vq,yq=Cp.useSyncExternalStore,bq=Cp.useRef,_q=Cp.useEffect,xq=Cp.useMemo,wq=Cp.useDebugValue;mq.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var o=bq(null);if(o.current===null){var a={hasValue:!1,value:null};o.current=a}else a=o.current;o=xq(function(){function l(v){if(!u){if(u=!0,f=v,v=r(v),i!==void 0&&a.hasValue){var g=a.value;if(i(g,v))return d=g}return d=v}if(g=d,gq(f,v))return g;var y=r(v);return i!==void 0&&i(g,y)?g:(f=v,d=y)}var u=!1,f,d,h=n===void 0?null:n;return[function(){return l(t())},h===null?void 0:function(){return l(h())}]},[t,n,r,i]);var s=yq(e,o[0],o[1]);return _q(function(){a.hasValue=!0,a.value=s},[s]),wq(s),s};var pt="default"in Cx?V:Cx,rk=Symbol.for("react-redux-context"),ik=typeof globalThis<"u"?globalThis:{};function Oq(){if(!pt.createContext)return{};const e=ik[rk]??(ik[rk]=new Map);let t=e.get(pt.createContext);return t||(t=pt.createContext(null),e.set(pt.createContext,t)),t}var iD=Oq(),Sq=()=>{throw new Error("uSES not initialized!")},Eq=Symbol.for("react.element"),Pq=Symbol.for("react.portal"),Cq=Symbol.for("react.fragment"),Tq=Symbol.for("react.strict_mode"),jq=Symbol.for("react.profiler"),Aq=Symbol.for("react.provider"),kq=Symbol.for("react.context"),Nq=Symbol.for("react.server_context"),oD=Symbol.for("react.forward_ref"),Mq=Symbol.for("react.suspense"),Rq=Symbol.for("react.suspense_list"),tP=Symbol.for("react.memo"),Lq=Symbol.for("react.lazy"),$q=oD,Iq=tP;function Dq(e){if(typeof e=="object"&&e!==null){const t=e.$$typeof;switch(t){case Eq:{const n=e.type;switch(n){case Cq:case jq:case Tq:case Mq:case Rq:return n;default:{const r=n&&n.$$typeof;switch(r){case Nq:case kq:case oD:case Lq:case tP:case Aq:return r;default:return t}}}}case Pq:return t}}}function Fq(e){return Dq(e)===tP}function Bq(e,t,n,r,{areStatesEqual:i,areOwnPropsEqual:o,areStatePropsEqual:a}){let s=!1,l,u,f,d,h;function v(b,w){return l=b,u=w,f=e(l,u),d=t(r,u),h=n(f,d,u),s=!0,h}function g(){return f=e(l,u),t.dependsOnOwnProps&&(d=t(r,u)),h=n(f,d,u),h}function y(){return e.dependsOnOwnProps&&(f=e(l,u)),t.dependsOnOwnProps&&(d=t(r,u)),h=n(f,d,u),h}function x(){const b=e(l,u),w=!a(b,f);return f=b,w&&(h=n(f,d,u)),h}function _(b,w){const S=!o(w,u),E=!i(b,l,w,u);return l=b,u=w,S&&E?g():S?y():E?x():h}return function(w,S){return s?_(w,S):v(w,S)}}function Uq(e,{initMapStateToProps:t,initMapDispatchToProps:n,initMergeProps:r,...i}){const o=t(e,i),a=n(e,i),s=r(e,i);return Bq(o,a,s,e,i)}function zq(e,t){const n={};for(const r in e){const i=e[r];typeof i=="function"&&(n[r]=(...o)=>t(i(...o)))}return n}function _w(e){return function(n){const r=e(n);function i(){return r}return i.dependsOnOwnProps=!1,i}}function ok(e){return e.dependsOnOwnProps?!!e.dependsOnOwnProps:e.length!==1}function aD(e,t){return function(r,{displayName:i}){const o=function(s,l){return o.dependsOnOwnProps?o.mapToProps(s,l):o.mapToProps(s,void 0)};return o.dependsOnOwnProps=!0,o.mapToProps=function(s,l){o.mapToProps=e,o.dependsOnOwnProps=ok(e);let u=o(s,l);return typeof u=="function"&&(o.mapToProps=u,o.dependsOnOwnProps=ok(u),u=o(s,l)),u},o}}function nP(e,t){return(n,r)=>{throw new Error(`Invalid value of type ${typeof e} for ${t} argument when connecting component ${r.wrappedComponentName}.`)}}function Vq(e){return e&&typeof e=="object"?_w(t=>zq(e,t)):e?typeof e=="function"?aD(e):nP(e,"mapDispatchToProps"):_w(t=>({dispatch:t}))}function Wq(e){return e?typeof e=="function"?aD(e):nP(e,"mapStateToProps"):_w(()=>({}))}function Hq(e,t,n){return{...n,...e,...t}}function Gq(e){return function(n,{displayName:r,areMergedPropsEqual:i}){let o=!1,a;return function(l,u,f){const d=e(l,u,f);return o?i(d,a)||(a=d):(o=!0,a=d),a}}}function qq(e){return e?typeof e=="function"?Gq(e):nP(e,"mergeProps"):()=>Hq}function Kq(e){e()}function Yq(){let e=null,t=null;return{clear(){e=null,t=null},notify(){Kq(()=>{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 ak={notify(){},get:()=>[]};function sD(e,t){let n,r=ak,i=0,o=!1;function a(y){f();const x=r.subscribe(y);let _=!1;return()=>{_||(_=!0,x(),d())}}function s(){r.notify()}function l(){g.onStateChange&&g.onStateChange()}function u(){return o}function f(){i++,n||(n=t?t.addNestedSub(l):e.subscribe(l),r=Yq())}function d(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=ak)}function h(){o||(o=!0,f())}function v(){o&&(o=!1,d())}const g={addNestedSub:a,notifyNestedSubs:s,handleChangeWrapper:l,isSubscribed:u,trySubscribe:h,tryUnsubscribe:v,getListeners:()=>r};return g}var Zq=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Xq=typeof navigator<"u"&&navigator.product==="ReactNative",Ag=Zq||Xq?pt.useLayoutEffect:pt.useEffect;function sk(e,t){return e===t?e!==0||t!==0||1/e===1/t:e!==e&&t!==t}function c_(e,t){if(sk(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{uD=e},sK=[null,null];function lK(e,t,n){Ag(()=>e(...t),n)}function uK(e,t,n,r,i,o){e.current=r,n.current=!1,i.current&&(i.current=null,o())}function cK(e,t,n,r,i,o,a,s,l,u,f){if(!e)return()=>{};let d=!1,h=null;const v=()=>{if(d||!s.current)return;const y=t.getState();let x,_;try{x=r(y,i.current)}catch(b){_=b,h=b}_||(h=null),x===o.current?a.current||u():(o.current=x,l.current=x,a.current=!0,f())};return n.onStateChange=v,n.trySubscribe(),v(),()=>{if(d=!0,n.tryUnsubscribe(),n.onStateChange=null,h)throw h}}function fK(e,t){return e===t}function dK(e,t,n,{pure:r,areStatesEqual:i=fK,areOwnPropsEqual:o=c_,areStatePropsEqual:a=c_,areMergedPropsEqual:s=c_,forwardRef:l=!1,context:u=iD}={}){const f=u,d=Wq(e),h=Vq(t),v=qq(n),g=!!e;return x=>{const _=x.displayName||x.name||"Component",b=`Connect(${_})`,w={shouldHandleStateChanges:g,displayName:b,wrappedComponentName:_,WrappedComponent:x,initMapStateToProps:d,initMapDispatchToProps:h,initMergeProps:v,areStatesEqual:i,areStatePropsEqual:a,areOwnPropsEqual:o,areMergedPropsEqual:s};function S(T){const[A,D,k]=pt.useMemo(()=>{const{reactReduxForwardedRef:Y,...oe}=T;return[T.context,Y,oe]},[T]),I=pt.useMemo(()=>{let Y=f;return A!=null&&A.Consumer,Y},[A,f]),F=pt.useContext(I),q=!!T.store&&!!T.store.getState&&!!T.store.dispatch,W=!!F&&!!F.store,X=q?T.store:F.store,Q=W?F.getServerState:X.getState,ne=pt.useMemo(()=>Uq(X.dispatch,w),[X]),[Z,z]=pt.useMemo(()=>{if(!g)return sK;const Y=sD(X,q?void 0:F.subscription),oe=Y.notifyNestedSubs.bind(Y);return[Y,oe]},[X,q,F]),B=pt.useMemo(()=>q?F:{...F,subscription:Z},[q,F,Z]),H=pt.useRef(void 0),ee=pt.useRef(k),K=pt.useRef(void 0),te=pt.useRef(!1),ie=pt.useRef(!1),ae=pt.useRef(void 0);Ag(()=>(ie.current=!0,()=>{ie.current=!1}),[]);const fe=pt.useMemo(()=>()=>K.current&&k===ee.current?K.current:ne(X.getState(),k),[X,k]),j=pt.useMemo(()=>oe=>Z?cK(g,X,Z,ne,ee,H,te,ie,K,z,oe):()=>{},[Z]);lK(uK,[ee,H,te,k,K,z]);let N;try{N=uD(j,fe,Q?()=>ne(Q(),k):fe)}catch(Y){throw ae.current&&(Y.message+=` The error may be correlated with this previous error: ${ae.current.stack} `),Y}Ag(()=>{ae.current=void 0,K.current=void 0,H.current=N});const U=pt.useMemo(()=>pt.createElement(x,{...N,ref:D}),[D,x,N]);return pt.useMemo(()=>g?pt.createElement(I.Provider,{value:B},U):U,[I,U,B])}const P=pt.memo(S);if(P.WrappedComponent=x,P.displayName=S.displayName=b,l){const A=pt.forwardRef(function(k,I){return pt.createElement(P,{...k,reactReduxForwardedRef:I})});return A.displayName=b,A.WrappedComponent=x,xw(A,x)}return xw(P,x)}}var cD=dK;function hK({store:e,context:t,children:n,serverState:r,stabilityCheck:i="once",identityFunctionCheck:o="once"}){const a=pt.useMemo(()=>{const u=sD(e);return{store:e,subscription:u,getServerState:r?()=>r:void 0,stabilityCheck:i,identityFunctionCheck:o}},[e,r,i,o]),s=pt.useMemo(()=>e.getState(),[e]);Ag(()=>{const{subscription:u}=a;return u.onStateChange=u.notifyNestedSubs,u.trySubscribe(),s!==e.getState()&&u.notifyNestedSubs(),()=>{u.tryUnsubscribe(),u.onStateChange=void 0}},[a,s]);const l=t||iD;return pt.createElement(l.Provider,{value:a},n)}var fD=hK;aK(R.useSyncExternalStore);/** * @remix-run/router v1.17.1 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function mh(){return mh=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function dD(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function mK(){return Math.random().toString(36).substr(2,8)}function dk(e,t){return{usr:e.state,key:e.key,idx:t}}function ww(e,t,n,r){return n===void 0&&(n=null),mh({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Gc(t):t,{state:n,key:t&&t.key||r||mK()})}function kg(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Gc(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function vK(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:o=!1}=r,a=i.history,s=La.Pop,l=null,u=f();u==null&&(u=0,a.replaceState(mh({},a.state,{idx:u}),""));function f(){return(a.state||{idx:null}).idx}function d(){s=La.Pop;let x=f(),_=x==null?null:x-u;u=x,l&&l({action:s,location:y.location,delta:_})}function h(x,_){s=La.Push;let b=ww(y.location,x,_);n&&n(b,x),u=f()+1;let w=dk(b,u),S=y.createHref(b);try{a.pushState(w,"",S)}catch(E){if(E instanceof DOMException&&E.name==="DataCloneError")throw E;i.location.assign(S)}o&&l&&l({action:s,location:y.location,delta:1})}function v(x,_){s=La.Replace;let b=ww(y.location,x,_);n&&n(b,x),u=f();let w=dk(b,u),S=y.createHref(b);a.replaceState(w,"",S),o&&l&&l({action:s,location:y.location,delta:0})}function g(x){let _=i.location.origin!=="null"?i.location.origin:i.location.href,b=typeof x=="string"?x:kg(x);return b=b.replace(/ $/,"%20"),Wt(_,"No window.location.(origin|href) available to create URL for href: "+b),new URL(b,_)}let y={get action(){return s},get location(){return e(i,a)},listen(x){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(fk,d),l=x,()=>{i.removeEventListener(fk,d),l=null}},createHref(x){return t(i,x)},createURL:g,encodeLocation(x){let _=g(x);return{pathname:_.pathname,search:_.search,hash:_.hash}},push:h,replace:v,go(x){return a.go(x)}};return y}var hk;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(hk||(hk={}));function gK(e,t,n){return n===void 0&&(n="/"),yK(e,t,n,!1)}function yK(e,t,n,r){let i=typeof t=="string"?Gc(t):t,o=oc(i.pathname||"/",n);if(o==null)return null;let a=hD(e);bK(a);let s=null;for(let l=0;s==null&&l{let l={relativePath:s===void 0?o.path||"":s,caseSensitive:o.caseSensitive===!0,childrenIndex:a,route:o};l.relativePath.startsWith("/")&&(Wt(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(r.length));let u=Ya([r,l.relativePath]),f=n.concat(l);o.children&&o.children.length>0&&(Wt(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),hD(o.children,t,f,u)),!(o.path==null&&!o.index)&&t.push({path:u,score:PK(u,o.index),routesMeta:f})};return e.forEach((o,a)=>{var s;if(o.path===""||!((s=o.path)!=null&&s.includes("?")))i(o,a);else for(let l of pD(o.path))i(o,a,l)}),t}function pD(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return i?[o,""]:[o];let a=pD(r.join("/")),s=[];return s.push(...a.map(l=>l===""?o:[o,l].join("/"))),i&&s.push(...a),s.map(l=>e.startsWith("/")&&l===""?"/":l)}function bK(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:CK(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const _K=/^:[\w-]+$/,xK=3,wK=2,OK=1,SK=10,EK=-2,pk=e=>e==="*";function PK(e,t){let n=e.split("/"),r=n.length;return n.some(pk)&&(r+=EK),t&&(r+=wK),n.filter(i=>!pk(i)).reduce((i,o)=>i+(_K.test(o)?xK:o===""?OK:SK),r)}function CK(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 TK(e,t,n){n===void 0&&(n=!1);let{routesMeta:r}=e,i={},o="/",a=[];for(let s=0;s{let{paramName:h,isOptional:v}=f;if(h==="*"){let y=s[d]||"";a=o.slice(0,o.length-y.length).replace(/(.)\/+$/,"$1")}const g=s[d];return v&&!g?u[h]=void 0:u[h]=(g||"").replace(/%2F/g,"/"),u},{}),pathname:o,pathnameBase:a,pattern:e}}function jK(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),dD(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,(a,s,l)=>(r.push({paramName:s,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function AK(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return dD(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function oc(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 kK(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Gc(e):e;return{pathname:n?n.startsWith("/")?n:NK(n,t):t,search:LK(r),hash:$K(i)}}function NK(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 f_(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 and the router will parse it for you.'}function MK(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function rP(e,t){let n=MK(e);return t?n.map((r,i)=>i===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function iP(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=Gc(e):(i=mh({},e),Wt(!i.pathname||!i.pathname.includes("?"),f_("?","pathname","search",i)),Wt(!i.pathname||!i.pathname.includes("#"),f_("#","pathname","hash",i)),Wt(!i.search||!i.search.includes("#"),f_("#","search","hash",i)));let o=e===""||i.pathname==="",a=o?"/":i.pathname,s;if(a==null)s=n;else{let d=t.length-1;if(!r&&a.startsWith("..")){let h=a.split("/");for(;h[0]==="..";)h.shift(),d-=1;i.pathname=h.join("/")}s=d>=0?t[d]:"/"}let l=kK(i,s),u=a&&a!=="/"&&a.endsWith("/"),f=(o||a===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(u||f)&&(l.pathname+="/"),l}const Ya=e=>e.join("/").replace(/\/\/+/g,"/"),RK=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),LK=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,$K=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function IK(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const mD=["post","put","patch","delete"];new Set(mD);const DK=["get",...mD];new Set(DK);/** * React Router v6.24.1 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function vh(){return vh=Object.assign?Object.assign.bind():function(e){for(var t=1;t{s.current=!0}),R.useCallback(function(u,f){if(f===void 0&&(f={}),!s.current)return;if(typeof u=="number"){r.go(u);return}let d=iP(u,JSON.parse(a),o,f.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:Ya([t,d.pathname])),(f.replace?r.replace:r.push)(d,f.state,f)},[t,r,a,o,e])}function qc(){let{matches:e}=R.useContext(la),t=e[e.length-1];return t?t.params:{}}function q0(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=R.useContext(sa),{matches:i}=R.useContext(la),{pathname:o}=pr(),a=JSON.stringify(rP(i,r.v7_relativeSplatPath));return R.useMemo(()=>iP(e,JSON.parse(a),o,n==="path"),[e,a,o,n])}function UK(e,t){return zK(e,t)}function zK(e,t,n,r){$l()||Wt(!1);let{navigator:i}=R.useContext(sa),{matches:o}=R.useContext(la),a=o[o.length-1],s=a?a.params:{};a&&a.pathname;let l=a?a.pathnameBase:"/";a&&a.route;let u=pr(),f;if(t){var d;let x=typeof t=="string"?Gc(t):t;l==="/"||(d=x.pathname)!=null&&d.startsWith(l)||Wt(!1),f=x}else f=u;let h=f.pathname||"/",v=h;if(l!=="/"){let x=l.replace(/^\//,"").split("/");v="/"+h.replace(/^\//,"").split("/").slice(x.length).join("/")}let g=gK(e,{pathname:v}),y=qK(g&&g.map(x=>Object.assign({},x,{params:Object.assign({},s,x.params),pathname:Ya([l,i.encodeLocation?i.encodeLocation(x.pathname).pathname:x.pathname]),pathnameBase:x.pathnameBase==="/"?l:Ya([l,i.encodeLocation?i.encodeLocation(x.pathnameBase).pathname:x.pathnameBase])})),o,n,r);return t&&y?R.createElement(G0.Provider,{value:{location:vh({pathname:"/",search:"",hash:"",state:null,key:"default"},f),navigationType:La.Pop}},y):y}function VK(){let e=XK(),t=IK(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return R.createElement(R.Fragment,null,R.createElement("h2",null,"Unexpected Application Error!"),R.createElement("h3",{style:{fontStyle:"italic"}},t),n?R.createElement("pre",{style:i},n):null,null)}const WK=R.createElement(VK,null);class HK extends R.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?R.createElement(la.Provider,{value:this.props.routeContext},R.createElement(gD.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function GK(e){let{routeContext:t,match:n,children:r}=e,i=R.useContext(H0);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),R.createElement(la.Provider,{value:t},r)}function qK(e,t,n,r){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var o;if((o=n)!=null&&o.errors)e=n.matches;else return null}let a=e,s=(i=n)==null?void 0:i.errors;if(s!=null){let f=a.findIndex(d=>d.route.id&&(s==null?void 0:s[d.route.id])!==void 0);f>=0||Wt(!1),a=a.slice(0,Math.min(a.length,f+1))}let l=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let f=0;f=0?a=a.slice(0,u+1):a=[a[0]];break}}}return a.reduceRight((f,d,h)=>{let v,g=!1,y=null,x=null;n&&(v=s&&d.route.id?s[d.route.id]:void 0,y=d.route.errorElement||WK,l&&(u<0&&h===0?(JK("route-fallback",!1),g=!0,x=null):u===h&&(g=!0,x=d.route.hydrateFallbackElement||null)));let _=t.concat(a.slice(0,h+1)),b=()=>{let w;return v?w=y:g?w=x:d.route.Component?w=R.createElement(d.route.Component,null):d.route.element?w=d.route.element:w=f,R.createElement(GK,{match:d,routeContext:{outlet:f,matches:_,isDataRoute:n!=null},children:w})};return n&&(d.route.ErrorBoundary||d.route.errorElement||h===0)?R.createElement(HK,{location:n.location,revalidation:n.revalidation,component:y,error:v,children:b(),routeContext:{outlet:null,matches:_,isDataRoute:!0}}):b()},null)}var bD=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(bD||{}),Mg=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Mg||{});function KK(e){let t=R.useContext(H0);return t||Wt(!1),t}function YK(e){let t=R.useContext(vD);return t||Wt(!1),t}function ZK(e){let t=R.useContext(la);return t||Wt(!1),t}function _D(e){let t=ZK(),n=t.matches[t.matches.length-1];return n.route.id||Wt(!1),n.route.id}function XK(){var e;let t=R.useContext(gD),n=YK(Mg.UseRouteError),r=_D(Mg.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function QK(){let{router:e}=KK(bD.UseNavigateStable),t=_D(Mg.UseNavigateStable),n=R.useRef(!1);return yD(()=>{n.current=!0}),R.useCallback(function(i,o){o===void 0&&(o={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,vh({fromRouteId:t},o)))},[e,t])}const mk={};function JK(e,t,n){!t&&!mk[e]&&(mk[e]=!0)}function oP(e){let{to:t,replace:n,state:r,relative:i}=e;$l()||Wt(!1);let{future:o,static:a}=R.useContext(sa),{matches:s}=R.useContext(la),{pathname:l}=pr(),u=Eo(),f=iP(t,rP(s,o.v7_relativeSplatPath),l,i==="path"),d=JSON.stringify(f);return R.useEffect(()=>u(JSON.parse(d),{replace:n,state:r,relative:i}),[u,d,i,n,r]),null}function lt(e){Wt(!1)}function eY(e){let{basename:t="/",children:n=null,location:r,navigationType:i=La.Pop,navigator:o,static:a=!1,future:s}=e;$l()&&Wt(!1);let l=t.replace(/^\/*/,"/"),u=R.useMemo(()=>({basename:l,navigator:o,static:a,future:vh({v7_relativeSplatPath:!1},s)}),[l,s,o,a]);typeof r=="string"&&(r=Gc(r));let{pathname:f="/",search:d="",hash:h="",state:v=null,key:g="default"}=r,y=R.useMemo(()=>{let x=oc(f,l);return x==null?null:{location:{pathname:x,search:d,hash:h,state:v,key:g},navigationType:i}},[l,f,d,h,v,g,i]);return y==null?null:R.createElement(sa.Provider,{value:u},R.createElement(G0.Provider,{children:n,value:y}))}function K0(e){let{children:t,location:n}=e;return UK(Ow(t),n)}new Promise(()=>{});function Ow(e,t){t===void 0&&(t=[]);let n=[];return R.Children.forEach(e,(r,i)=>{if(!R.isValidElement(r))return;let o=[...t,i];if(r.type===R.Fragment){n.push.apply(n,Ow(r.props.children,o));return}r.type!==lt&&Wt(!1),!r.props.index||!r.props.children||Wt(!1);let a={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(a.children=Ow(r.props.children,o)),n.push(a)}),n}/** * React Router DOM v6.24.1 * * Copyright (c) Remix Software Inc. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */function Rg(){return Rg=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[i]=e[i]);return n}function tY(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function nY(e,t){return e.button===0&&(!t||t==="_self")&&!tY(e)}const rY=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","unstable_viewTransition"],iY=["aria-current","caseSensitive","className","end","style","to","unstable_viewTransition","children"],oY="6";try{window.__reactRouterVersion=oY}catch{}const aY=R.createContext({isTransitioning:!1}),sY="startTransition",vk=Cx[sY];function wD(e){let{basename:t,children:n,future:r,window:i}=e,o=R.useRef();o.current==null&&(o.current=pK({window:i,v5Compat:!0}));let a=o.current,[s,l]=R.useState({action:a.action,location:a.location}),{v7_startTransition:u}=r||{},f=R.useCallback(d=>{u&&vk?vk(()=>l(d)):l(d)},[l,u]);return R.useLayoutEffect(()=>a.listen(f),[a,f]),R.createElement(eY,{basename:t,children:n,location:s.location,navigationType:s.action,navigator:a,future:r})}const lY=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",uY=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Pt=R.forwardRef(function(t,n){let{onClick:r,relative:i,reloadDocument:o,replace:a,state:s,target:l,to:u,preventScrollReset:f,unstable_viewTransition:d}=t,h=xD(t,rY),{basename:v}=R.useContext(sa),g,y=!1;if(typeof u=="string"&&uY.test(u)&&(g=u,lY))try{let w=new URL(window.location.href),S=u.startsWith("//")?new URL(w.protocol+u):new URL(u),E=oc(S.pathname,v);S.origin===w.origin&&E!=null?u=E+S.search+S.hash:y=!0}catch{}let x=FK(u,{relative:i}),_=fY(u,{replace:a,state:s,target:l,preventScrollReset:f,relative:i,unstable_viewTransition:d});function b(w){r&&r(w),w.defaultPrevented||_(w)}return R.createElement("a",Rg({},h,{href:g||x,onClick:y||o?r:b,ref:n,target:l}))}),OD=R.forwardRef(function(t,n){let{"aria-current":r="page",caseSensitive:i=!1,className:o="",end:a=!1,style:s,to:l,unstable_viewTransition:u,children:f}=t,d=xD(t,iY),h=q0(l,{relative:d.relative}),v=pr(),g=R.useContext(vD),{navigator:y,basename:x}=R.useContext(sa),_=g!=null&&dY(h)&&u===!0,b=y.encodeLocation?y.encodeLocation(h).pathname:h.pathname,w=v.pathname,S=g&&g.navigation&&g.navigation.location?g.navigation.location.pathname:null;i||(w=w.toLowerCase(),S=S?S.toLowerCase():null,b=b.toLowerCase()),S&&x&&(S=oc(S,x)||S);const E=b!=="/"&&b.endsWith("/")?b.length-1:b.length;let P=w===b||!a&&w.startsWith(b)&&w.charAt(E)==="/",T=S!=null&&(S===b||!a&&S.startsWith(b)&&S.charAt(b.length)==="/"),A={isActive:P,isPending:T,isTransitioning:_},D=P?r:void 0,k;typeof o=="function"?k=o(A):k=[o,P?"active":null,T?"pending":null,_?"transitioning":null].filter(Boolean).join(" ");let I=typeof s=="function"?s(A):s;return R.createElement(Pt,Rg({},d,{"aria-current":D,className:k,ref:n,style:I,to:l,unstable_viewTransition:u}),typeof f=="function"?f(A):f)});var Sw;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Sw||(Sw={}));var gk;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(gk||(gk={}));function cY(e){let t=R.useContext(H0);return t||Wt(!1),t}function fY(e,t){let{target:n,replace:r,state:i,preventScrollReset:o,relative:a,unstable_viewTransition:s}=t===void 0?{}:t,l=Eo(),u=pr(),f=q0(e,{relative:a});return R.useCallback(d=>{if(nY(d,n)){d.preventDefault();let h=r!==void 0?r:kg(u)===kg(f);l(e,{replace:h,state:i,preventScrollReset:o,relative:a,unstable_viewTransition:s})}},[u,l,f,r,i,n,e,o,a,s])}function dY(e,t){t===void 0&&(t={});let n=R.useContext(aY);n==null&&Wt(!1);let{basename:r}=cY(Sw.useViewTransitionState),i=q0(e,{relative:t.relative});if(!n.isTransitioning)return!1;let o=oc(n.currentLocation.pathname,r)||n.currentLocation.pathname,a=oc(n.nextLocation.pathname,r)||n.nextLocation.pathname;return Ng(i.pathname,a)!=null||Ng(i.pathname,o)!=null}const hY="shlink-web-client",pY="A React-based progressive web application for shlink",mY="/shlink-web-client/dependabot/npm_and_yarn/eslint-plugins-2ef52aae12",vY="https://github.com/shlinkio/shlink-web-client",gY="MIT",yY="module",bY={lint:"npm run lint:css && npm run lint:js","lint:css":"stylelint src/*.scss src/**/*.scss","lint:js":"eslint src test config/test","lint:fix":"npm run lint:css:fix && npm run lint:js:fix","lint:css:fix":"npm run lint:css -- --fix","lint:js:fix":"npm run lint:js -- --fix",types:"tsc",start:"vite serve --host=0.0.0.0",preview:"vite preview --host=0.0.0.0",build:"npm run types && vite build && node scripts/replace-version.mjs","build:dist":"npm run build && node scripts/create-dist-file.mjs",test:"vitest run --run","test:watch":"vitest --watch","test:ci":"npm run test -- --coverage","test:verbose":"npm run test -- --verbose"},_Y={"@fortawesome/fontawesome-free":"^6.5.2","@fortawesome/fontawesome-svg-core":"^6.5.2","@fortawesome/free-brands-svg-icons":"^6.5.2","@fortawesome/free-regular-svg-icons":"^6.5.2","@fortawesome/free-solid-svg-icons":"^6.5.2","@fortawesome/react-fontawesome":"^0.2.2","@json2csv/plainjs":"^7.0.6","@reduxjs/toolkit":"^2.2.6","@shlinkio/data-manipulation":"^1.0.3","@shlinkio/shlink-frontend-kit":"^0.5.1","@shlinkio/shlink-js-sdk":"^1.1.0","@shlinkio/shlink-web-component":"^0.7.0",bootstrap:"5.2.3",bottlejs:"^2.0.1",clsx:"^2.1.1","compare-versions":"^6.1.0",csvtojson:"^2.0.10","date-fns":"^3.6.0",react:"^18.3.1","react-dom":"^18.3.1","react-external-link":"^2.3.1","react-redux":"^9.1.2","react-router-dom":"^6.24.1",reactstrap:"^9.2.2","redux-localstorage-simple":"^2.5.1",uuid:"^10.0.0","workbox-core":"^7.1.0","workbox-expiration":"^7.1.0","workbox-precaching":"^7.1.0","workbox-routing":"^7.1.0","workbox-strategies":"^7.1.0"},xY={"@shlinkio/eslint-config-js-coding-standard":"~3.0.0","@shlinkio/stylelint-config-css-coding-standard":"~1.1.1","@stylistic/eslint-plugin":"^2.3.0","@testing-library/jest-dom":"^6.4.6","@testing-library/react":"^16.0.0","@testing-library/user-event":"^14.5.2","@total-typescript/shoehorn":"^0.1.2","@types/react":"^18.3.3","@types/react-dom":"^18.3.0","@types/uuid":"^10.0.0","@vitejs/plugin-react":"^4.3.1","@vitest/coverage-v8":"^1.6.0","adm-zip":"^0.5.14","axe-core":"^4.9.1",chalk:"^5.3.0",eslint:"^8.57.0","eslint-plugin-jsx-a11y":"^6.9.0","eslint-plugin-react":"^7.34.3","eslint-plugin-react-hooks":"^4.6.2","eslint-plugin-simple-import-sort":"^12.1.1",history:"^5.3.0",jsdom:"^24.1.0",sass:"^1.77.6",stylelint:"^15.11.0",typescript:"^5.5.3","typescript-eslint":"^7.16.0",vite:"^5.3.2","vite-plugin-pwa":"^0.20.0",vitest:"^1.2.2"},wY=[">0.2%","not dead","not ie <= 11","not op_mini all"],Lg={name:hY,description:pY,private:!1,homepage:mY,repository:vY,license:gY,type:yY,scripts:bY,dependencies:_Y,devDependencies:xY,browserslist:wY};var zi,_o=".",SD="function",ED="string",PD="__global__",aP="Provider",OY=0,sP=Array.prototype.slice,SY=function(t,n){var r=t[n];if(r===void 0&&zi.config.strict)throw new Error("Bottle was unable to resolve a service. `"+n+"` is undefined.");return r},Y0=function(t){var n;return this.nested[t]||(n=zi.pop(),this.nested[t]=n,this.factory(t,function(){return n.container})),this.nested[t]},CD=function(t){return t.split(_o).reduce(SY,this)},EY=function(t,n,r,i){var o={configurable:!0,enumerable:!0};return t.length?o.get=function(){var s=0,l=function(f){if(f)throw f;t[s]&&t[s++](r,l)};return l(),r}:(o.value=r,o.writable=!0),Object.defineProperty(i,n,o),i[n]},PY=function(t,n){var r,i;return typeof t===SD&&(n=t,t=PD),r=t.split(_o),i=r.shift(),r.length?Y0.call(this,i).middleware(r.join(_o),n):(this.middlewares[i]||(this.middlewares[i]=[]),this.middlewares[i].push(n)),this},CY=function(t,n){return n(t)},yk=function(t,n){return(t[n]||[]).concat(t.__global__||[])},TY=function(t,n){var r,i,o,a,s;return this.id,o=this.container,a=this.decorators,s=this.middlewares,r=t+aP,i=Object.create(null),i[r]={configurable:!0,enumerable:!0,get:function(){var u=new n;return delete o[r],o[r]=u,u}},i[t]={configurable:!0,enumerable:!0,get:function(){var u=o[r],f;return u&&(f=yk(a,t).reduce(CY,u.$get(o)),delete o[r],delete o[t]),f===void 0?f:EY(yk(s,t),t,f,o)}},Object.defineProperties(o,i),this},TD=function(t,n){var r,i;return r=t.split(_o),this.providerMap[t]&&r.length===1&&!this.container[t+aP]?console.error(t+" provider already instantiated."):(this.originalProviders[t]=n,this.providerMap[t]=!0,i=r.shift(),r.length?(Y0.call(this,i).provider(r.join(_o),n),this):TY.call(this,i,n))},lP=function(t,n){return TD.call(this,t,function(){this.$get=n})},jD=function(t,n,r){var i=arguments.length>3?sP.call(arguments,3):[],o=this;return lP.call(this,t,function(){var s=n,l=i.map(CD,o.container);return r?new(n.bind.apply(n,[null].concat(l))):s.apply(null,l)})},jY=function(t,n){return jD.apply(this,[t,n,!0].concat(sP.call(arguments,2)))},AY=function(t,n){return jD.apply(this,[t,n,!1].concat(sP.call(arguments,2)))},AD=function(t,n){Object.defineProperty(this,t,{configurable:!0,enumerable:!0,value:n,writable:!0})},kD=function(t,n){var r=t[n];return r||(r={},AD.call(t,n,r)),r},kY=function(t,n){var r;return r=t.split(_o),t=r.pop(),AD.call(r.reduce(kD,this.container),t,n),this},NY=function(t,n){Object.defineProperty(this,t,{configurable:!1,enumerable:!0,value:n,writable:!1})},MY=function(t,n){var r=t.split(_o);return t=r.pop(),NY.call(r.reduce(kD,this.container),t,n),this},ND=function(t,n){var r,i;return typeof t===SD&&(n=t,t=PD),r=t.split(_o),i=r.shift(),r.length?Y0.call(this,i).decorator(r.join(_o),n):(this.decorators[i]||(this.decorators[i]=[]),this.decorators[i].push(n)),this},RY=function(t){return this.deferred.push(t),this},LY=function(t){return(t||[]).map(CD,this.container)},$Y=function(t,n){return lP.call(this,t,function(i){return{instance:n.bind(n,i)}})},IY=function(t){return!/^\$(?:decorator|register|list)$|Provider$/.test(t)},uP=function(t){return Object.keys(t||this.container||{}).filter(IY)},$g={},DY=function(t){var n;return typeof t===ED?(n=$g[t],n||($g[t]=n=new zi,n.constant("BOTTLE_NAME",t)),n):new zi},FY=function(t){typeof t===ED?delete $g[t]:$g={}},MD=function(t){var n=t.$value===void 0?t:t.$value;return this[t.$type||"service"].apply(this,[t.$name,n].concat(t.$inject||[]))},bk=function(t){delete this.providerMap[t],delete this.container[t],delete this.container[t+aP]},BY=function(t){var n=this.originalProviders,r=Array.isArray(t);Object.keys(this.originalProviders).forEach(function(o){if(!(r&&t.indexOf(o)===-1)){var a=o.split(_o);a.length>1&&a.forEach(bk,Y0.call(this,a[0])),bk.call(this,o),this.provider(o,n[o])}},this)},UY=function(t){return this.deferred.forEach(function(r){r(t)}),this};zi=function e(t){if(!(this instanceof e))return e.pop(t);this.id=OY++,this.decorators={},this.middlewares={},this.nested={},this.providerMap={},this.originalProviders={},this.deferred=[],this.container={$decorator:ND.bind(this),$register:MD.bind(this),$list:uP.bind(this)}};zi.prototype={constant:MY,decorator:ND,defer:RY,digest:LY,factory:lP,instanceFactory:$Y,list:uP,middleware:PY,provider:TD,resetProviders:BY,register:MD,resolve:UY,service:jY,serviceFactory:AY,value:kY};zi.pop=DY;zi.clear=FY;zi.list=uP;zi.config={strict:!1};const RD=zi;var zY=Object.defineProperty,VY=(e,t,n)=>t in e?zY(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WY=(e,t,n)=>(VY(e,typeof t!="symbol"?t+"":t,n),n);const HY=(e,t)=>`${e}/rest/v${t}`,GY=e=>e.dir?`${e.field}-${e.dir}`:void 0,qY=({orderBy:e={},excludeMaxVisitsReached:t,excludePastValidUntil:n,...r})=>({...r,excludeMaxVisitsReached:t===!0?"true":void 0,excludePastValidUntil:n===!0?"true":void 0,orderBy:GY(e)}),KY=(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("/"),o=i.length?`/${i.join("/")}`:"";return`${n}://${t}${o}`},YY=(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()};class ZY{constructor(t,n){WY(this,"apiVersion"),this.httpClient=t,this.serverInfo=n,this.apiVersion=3}async listShortUrls(t={}){return this.performRequest({url:"/short-urls",query:qY(t)}).then(({shortUrls:n})=>n)}async createShortUrl(t){const n=Object.entries(t).reduce((r,[i,o])=>(o&&(r[i]=o),r),{});return this.performRequest({url:"/short-urls",method:"POST",body:n})}async getShortUrl(t,n){return this.performRequest({url:`/short-urls/${t}`,query:{domain:n}})}async deleteShortUrl(t,n){return this.performEmptyRequest({url:`/short-urls/${t}`,method:"DELETE",query:{domain:n}})}async updateShortUrl(t,n,r){return this.performRequest({url:`/short-urls/${t}`,method:"PATCH",query:{domain:n},body:r})}async getShortUrlRedirectRules(t,n){return this.performRequest({url:`/short-urls/${t}/redirect-rules`,method:"GET",query:{domain:n}})}async setShortUrlRedirectRules(t,n,r){return this.performRequest({url:`/short-urls/${t}/redirect-rules`,method:"POST",query:{domain:n},body:r})}async getVisitsOverview(){return this.performRequest({url:"/visits"}).then(({visits:t})=>t)}async getShortUrlVisits(t,n){return this.performVisitsRequest({url:`/short-urls/${t}/visits`,query:n})}async getTagVisits(t,n){return this.performVisitsRequest({url:`/tags/${t}/visits`,query:n})}async getDomainVisits(t,n){return this.performVisitsRequest({url:`/domains/${t}/visits`,query:n})}async getOrphanVisits(t){return this.performVisitsRequest({url:"/visits/orphan",query:t})}async getNonOrphanVisits(t){return this.performVisitsRequest({url:"/visits/non-orphan",query:t})}async performVisitsRequest(t){return this.performRequest(t).then(({visits:n})=>n)}async deleteShortUrlVisits(t,n){const r=n?{domain:n}:void 0;return this.performRequest({method:"DELETE",url:`/short-urls/${t}/visits`,query:r})}async deleteOrphanVisits(){return this.performRequest({method:"DELETE",url:"/visits/orphan"})}async listTags(){return this.performRequest({url:"/tags",query:{withStats:"true"}}).then(({tags:t})=>t)}async tagsStats(){return this.performRequest({url:"/tags/stats"}).then(({tags:t})=>t)}async deleteTags(t){return this.performEmptyRequest({url:"/tags",method:"DELETE",query:{tags:t}}).then(()=>({tags:t}))}async editTag(t,n){return this.performEmptyRequest({url:"/tags",method:"PUT",body:{oldName:t,newName:n}}).then(()=>({oldName:t,newName:n}))}async listDomains(){return this.performRequest({url:"/domains"}).then(({domains:t})=>t)}async editDomainRedirects(t){return this.performRequest({url:"/domains/redirects",method:"PATCH",body:t})}async health(t){return this.performRequest({url:"/health",domain:t})}async mercureInfo(){return this.performRequest({url:"/mercure-info"})}async performRequest(t){return this.httpClient.jsonRequest(...this.toFetchParams(t))}async performEmptyRequest(t){return this.httpClient.emptyRequest(...this.toFetchParams(t))}toFetchParams({url:t,method:n="GET",query:r={},body:i,domain:o}){const a=YY(r),s=a?`?${a}`:"",l=o?KY(this.serverInfo.baseUrl,o):this.serverInfo.baseUrl;return[`${HY(l,this.apiVersion)}${t}${s}`,{method:n,body:i&&JSON.stringify(i),headers:{"X-Api-Key":this.serverInfo.apiKey}}]}}const LD=e=>!!(e!=null&&e.url)&&!!(e!=null&&e.apiKey),Ad=e=>!!(e!=null&&e.id),cP=e=>!!(e!=null&&e.version),XY=e=>!!(e!=null&&e.serverNotFound),QY=e=>Ad(e)?e.id:"",JY=({name:e,url:t,apiKey:n})=>({name:e,url:t,apiKey:n}),_k={},eZ=e=>typeof e=="function",tZ=e=>{const{selectedServer:t}=e();if(!LD(t))throw new Error("There's no selected server or it is not found");return t},nZ=e=>t=>{const{url:n,apiKey:r}=eZ(t)?tZ(t):t,i=`${r}_${n}`,o=_k[i]??new ZY(e,{apiKey:r,baseUrl:n});return _k[i]=o,o},rZ=e=>{e.serviceFactory("buildShlinkApiClient",nZ,"HttpClient")};var $D={prefix:"fas",iconName:"trash-can",icon:[448,512,[61460,"trash-alt"],"f2ed","M135.2 17.7C140.6 6.8 151.7 0 163.8 0H284.2c12.1 0 23.2 6.8 28.6 17.7L320 32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32H32C14.3 96 0 81.7 0 64S14.3 32 32 32h96l7.2-14.3zM32 128H416V448c0 35.3-28.7 64-64 64H96c-35.3 0-64-28.7-64-64V128zm96 64c-8.8 0-16 7.2-16 16V432c0 8.8 7.2 16 16 16s16-7.2 16-16V208c0-8.8-7.2-16-16-16zm96 0c-8.8 0-16 7.2-16 16V432c0 8.8 7.2 16 16 16s16-7.2 16-16V208c0-8.8-7.2-16-16-16zm96 0c-8.8 0-16 7.2-16 16V432c0 8.8 7.2 16 16 16s16-7.2 16-16V208c0-8.8-7.2-16-16-16z"]},iZ={prefix:"fas",iconName:"calendar-days",icon:[448,512,["calendar-alt"],"f073","M128 0c17.7 0 32 14.3 32 32V64H288V32c0-17.7 14.3-32 32-32s32 14.3 32 32V64h48c26.5 0 48 21.5 48 48v48H0V112C0 85.5 21.5 64 48 64H96V32c0-17.7 14.3-32 32-32zM0 192H448V464c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V192zm64 80v32c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V272c0-8.8-7.2-16-16-16H80c-8.8 0-16 7.2-16 16zm128 0v32c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V272c0-8.8-7.2-16-16-16H208c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V272c0-8.8-7.2-16-16-16H336zM64 400v32c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V400c0-8.8-7.2-16-16-16H80c-8.8 0-16 7.2-16 16zm144-16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V400c0-8.8-7.2-16-16-16H208zm112 16v32c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V400c0-8.8-7.2-16-16-16H336c-8.8 0-16 7.2-16 16z"]},oZ=iZ,aZ={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 232H328c13.3 0 24 10.7 24 24s-10.7 24-24 24H184c-13.3 0-24-10.7-24-24s10.7-24 24-24z"]},fP=aZ,sZ={prefix:"fas",iconName:"file-csv",icon:[512,512,[],"f6dd","M0 64C0 28.7 28.7 0 64 0H224V128c0 17.7 14.3 32 32 32H384V304H176c-35.3 0-64 28.7-64 64V512H64c-35.3 0-64-28.7-64-64V64zm384 64H256V0L384 128zM200 352h16c22.1 0 40 17.9 40 40v8c0 8.8-7.2 16-16 16s-16-7.2-16-16v-8c0-4.4-3.6-8-8-8H200c-4.4 0-8 3.6-8 8v80c0 4.4 3.6 8 8 8h16c4.4 0 8-3.6 8-8v-8c0-8.8 7.2-16 16-16s16 7.2 16 16v8c0 22.1-17.9 40-40 40H200c-22.1 0-40-17.9-40-40V392c0-22.1 17.9-40 40-40zm133.1 0H368c8.8 0 16 7.2 16 16s-7.2 16-16 16H333.1c-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.1H304c-8.8 0-16-7.2-16-16s7.2-16 16-16h42.9c7.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 16v31.6c0 23 5.5 45.6 16 66c10.5-20.3 16-42.9 16-66V368c0-8.8 7.2-16 16-16s16 7.2 16 16v31.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.6V368c0-8.8 7.2-16 16-16z"]},lZ={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.1v32c0 8.8 7.2 16 16 16h32zM362.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"]},ID=lZ,DD={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"]},uZ={prefix:"fas",iconName:"bars",icon:[448,512,["navicon"],"f0c9","M0 96C0 78.3 14.3 64 32 64H416c17.7 0 32 14.3 32 32s-14.3 32-32 32H32C14.3 128 0 113.7 0 96zM0 256c0-17.7 14.3-32 32-32H416c17.7 0 32 14.3 32 32s-14.3 32-32 32H32c-17.7 0-32-14.3-32-32zM448 416c0 17.7-14.3 32-32 32H32c-17.7 0-32-14.3-32-32s14.3-32 32-32H416c17.7 0 32 14.3 32 32z"]},FD={prefix:"fas",iconName:"list",icon:[512,512,["list-squares"],"f03a","M40 48C26.7 48 16 58.7 16 72v48c0 13.3 10.7 24 24 24H88c13.3 0 24-10.7 24-24V72c0-13.3-10.7-24-24-24H40zM192 64c-17.7 0-32 14.3-32 32s14.3 32 32 32H480c17.7 0 32-14.3 32-32s-14.3-32-32-32H192zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32H480c17.7 0 32-14.3 32-32s-14.3-32-32-32H192zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32H480c17.7 0 32-14.3 32-32s-14.3-32-32-32H192zM16 232v48c0 13.3 10.7 24 24 24H88c13.3 0 24-10.7 24-24V232c0-13.3-10.7-24-24-24H40c-13.3 0-24 10.7-24 24zM40 368c-13.3 0-24 10.7-24 24v48c0 13.3 10.7 24 24 24H88c13.3 0 24-10.7 24-24V392c0-13.3-10.7-24-24-24H40z"]},cZ={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"]},fZ=cZ,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 160V416c0 53 43 96 96 96H352c53 0 96-43 96-96V320c0-17.7-14.3-32-32-32s-32 14.3-32 32v96c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V160c0-17.7 14.3-32 32-32h96c17.7 0 32-14.3 32-32s-14.3-32-32-32H96z"]},dP=dZ,hZ={prefix:"fas",iconName:"plug",icon:[384,512,[128268],"f1e6","M96 0C78.3 0 64 14.3 64 32v96h64V32c0-17.7-14.3-32-32-32zM288 0c-17.7 0-32 14.3-32 32v96h64V32c0-17.7-14.3-32-32-32zM32 160c-17.7 0-32 14.3-32 32s14.3 32 32 32v32c0 77.4 55 142 128 156.8V480c0 17.7 14.3 32 32 32s32-14.3 32-32V412.8C297 398 352 333.4 352 256V224c17.7 0 32-14.3 32-32s-14.3-32-32-32H32z"]},pZ={prefix:"fas",iconName:"globe",icon:[512,512,[127760],"f0ac","M352 256c0 22.2-1.2 43.6-3.3 64H163.3c-2.2-20.4-3.3-41.8-3.3-64s1.2-43.6 3.3-64H348.7c2.2 20.4 3.3 41.8 3.3 64zm28.8-64H503.9c5.3 20.5 8.1 41.9 8.1 64s-2.8 43.5-8.1 64H380.8c2.1-20.6 3.2-42 3.2-64s-1.1-43.4-3.2-64zm112.6-32H376.7c-10-63.9-29.8-117.4-55.3-151.6c78.3 20.7 142 77.5 171.9 151.6zm-149.1 0H167.7c6.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 0H18.6C48.6 85.9 112.2 29.1 190.6 8.4C165.1 42.6 145.3 96.1 135.3 160zM8.1 192H131.2c-2.1 20.6-3.2 42-3.2 64s1.1 43.4 3.2 64H8.1C2.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.6H344.3c-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 352H135.3zm358.1 0c-30 74.1-93.6 130.9-171.9 151.6c25.5-34.2 45.2-87.7 55.3-151.6H493.4z"]},mZ={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"]},xk={prefix:"fas",iconName:"server",icon:[512,512,[],"f233","M64 32C28.7 32 0 60.7 0 96v64c0 35.3 28.7 64 64 64H448c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64zm280 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 64v64c0 35.3 28.7 64 64 64H448c35.3 0 64-28.7 64-64V352c0-35.3-28.7-64-64-64H64zm280 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"]},vZ={prefix:"fas",iconName:"file-arrow-up",icon:[384,512,["file-upload"],"f574","M64 0C28.7 0 0 28.7 0 64V448c0 35.3 28.7 64 64 64H320c35.3 0 64-28.7 64-64V160H256c-17.7 0-32-14.3-32-32V0H64zM256 0V128H384L256 0zM216 408c0 13.3-10.7 24-24 24s-24-10.7-24-24V305.9l-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-31V408z"]},gZ=vZ,yZ={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 152V422.8c0 9.8-6 18.6-15.1 22.3L416 503V200.4zM137.6 138.3c2.4 14.1 7.2 28.3 12.8 41.5c2.9 6.8 6.1 13.7 9.6 20.6V451.8L32.9 502.7C17.1 509 0 497.4 0 480.4V209.6c0-9.8 6-18.6 15.1-22.3l122.6-49zM327.8 332c13.9-17.4 35.7-45.7 56.2-77V504.3L192 449.4V255c20.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"]},Ew=yZ,bZ={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.8H288c12.9 0 24.6-7.8 29.6-19.8s2.2-25.7-6.9-34.9l-128-128z"]},_Z={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.3H344c-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"]},xZ={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.7V64c0-17.7 14.3-32 32-32s32 14.3 32 32V365.7l32.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-32h32c17.7 0 32 14.3 32 32s-14.3 32-32 32H320zm0-128c-17.7 0-32-14.3-32-32s14.3-32 32-32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32H320zm0-128c-17.7 0-32-14.3-32-32s14.3-32 32-32H480c17.7 0 32 14.3 32 32s-14.3 32-32 32H320zm0-128c-17.7 0-32-14.3-32-32s14.3-32 32-32H544c17.7 0 32 14.3 32 32s-14.3 32-32 32H320z"]},wZ=xZ,hP={prefix:"fas",iconName:"chart-pie",icon:[576,512,["pie-chart"],"f200","M304 240V16.6c0-9 7-16.6 16-16.6C443.7 0 544 100.3 544 224c0 9-7.6 16-16.6 16H304zM32 272C32 150.7 122.1 50.3 239 34.3c9.2-1.3 17 6.1 17 15.4V288L412.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 288H558.4z"]},Z0={prefix:"fas",iconName:"chart-line",icon:[512,512,["line-chart"],"f201","M64 64c0-17.7-14.3-32-32-32S0 46.3 0 64V400c0 44.2 35.8 80 80 80H480c17.7 0 32-14.3 32-32s-14.3-32-32-32H80c-8.8 0-16-7.2-16-16V64zm406.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"]},BD={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.5V80C0 53.5 21.5 32 48 32H197.5c17 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"]},wk={prefix:"fas",iconName:"calendar-xmark",icon:[448,512,["calendar-times"],"f273","M128 0c17.7 0 32 14.3 32 32V64H288V32c0-17.7 14.3-32 32-32s32 14.3 32 32V64h48c26.5 0 48 21.5 48 48v48H0V112C0 85.5 21.5 64 48 64H96V32c0-17.7 14.3-32 32-32zM0 192H448V464c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V192zM305 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"]},OZ={prefix:"fas",iconName:"trash",icon:[448,512,[],"f1f8","M135.2 17.7L128 32H32C14.3 32 0 46.3 0 64S14.3 96 32 96H416c17.7 0 32-14.3 32-32s-14.3-32-32-32H320l-7.2-14.3C307.4 6.8 296.3 0 284.2 0H163.8c-12.1 0-23.2 6.8-28.6 17.7zM416 128H32L53.2 467c1.6 25.3 22.6 45 47.9 45H346.9c25.3 0 46.3-19.7 47.9-45L416 128z"]},SZ={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"]},EZ={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.6V32c0-17.7-14.3-32-32-32H352zM80 32C35.8 32 0 67.8 0 112V432c0 44.2 35.8 80 80 80H400c44.2 0 80-35.8 80-80V320c0-17.7-14.3-32-32-32s-32 14.3-32 32V432c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16V112c0-8.8 7.2-16 16-16H192c17.7 0 32-14.3 32-32s-14.3-32-32-32H80z"]},PZ=EZ,CZ={prefix:"fas",iconName:"tag",icon:[448,512,[127991],"f02b","M0 80V229.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.7H48C21.5 32 0 53.5 0 80zm112 32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z"]},TZ={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 336h24V272H216c-13.3 0-24-10.7-24-24s10.7-24 24-24h48c13.3 0 24 10.7 24 24v88h8c13.3 0 24 10.7 24 24s-10.7 24-24 24H216c-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"]},pP=TZ,jZ={prefix:"fas",iconName:"arrow-rotate-left",icon:[512,512,[8634,"arrow-left-rotate","arrow-rotate-back","arrow-rotate-backward","undo"],"f0e2","M125.7 160H176c17.7 0 32 14.3 32 32s-14.3 32-32 32H48c-17.7 0-32-14.3-32-32V64c0-17.7 14.3-32 32-32s32 14.3 32 32v51.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"]},AZ=jZ,kZ={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"]},NZ={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"]},MZ={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"]},RZ=MZ,LZ={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.1h-32l.7 160.2c0 2.7-.2 5.4-.5 8.1V472c0 22.1-17.9 40-40 40H456c-1.1 0-2.2 0-3.3-.1c-1.4 .1-2.8 .1-4.2 .1H416 392c-22.1 0-40-17.9-40-40V448 384c0-17.7-14.3-32-32-32H256c-17.7 0-32 14.3-32 32v64 24c0 22.1-17.9 40-40 40H160 128.1c-1.5 0-3-.1-4.5-.2c-1.2 .1-2.4 .2-3.6 .2H104c-22.1 0-40-17.9-40-40V360c0-.9 0-1.9 .1-2.8V287.6H32c-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"]},$Z=LZ,IZ={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.3V448c0 17.7 14.3 32 32 32s32-14.3 32-32V146.3l32.4 35.4c11.9 13 32.2 13.9 45.2 2s13.9-32.2 2-45.2l-88-96zM320 480h32c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32s14.3 32 32 32zm0-128h96c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32s14.3 32 32 32zm0-128H480c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32s14.3 32 32 32zm0-128H544c17.7 0 32-14.3 32-32s-14.3-32-32-32H320c-17.7 0-32 14.3-32 32s14.3 32 32 32z"]},DZ=IZ,FZ={prefix:"fas",iconName:"file-arrow-down",icon:[384,512,["file-download"],"f56d","M64 0C28.7 0 0 28.7 0 64V448c0 35.3 28.7 64 64 64H320c35.3 0 64-28.7 64-64V160H256c-17.7 0-32-14.3-32-32V0H64zM256 0V128H384L256 0zM216 232V334.1l31-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 31V232c0-13.3 10.7-24 24-24s24 10.7 24 24z"]},UD=FZ,BZ={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"]},UZ={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"]},zZ={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"]},VZ={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"]},WZ=VZ,HZ={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"]},GZ={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.2V448c0 17.7 14.3 32 32 32s32-14.3 32-32V141.2L329.4 246.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-160-160z"]},Tp={prefix:"fas",iconName:"plus",icon:[448,512,[10133,61543,"add"],"2b","M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32V224H48c-17.7 0-32 14.3-32 32s14.3 32 32 32H192V432c0 17.7 14.3 32 32 32s32-14.3 32-32V288H400c17.7 0 32-14.3 32-32s-14.3-32-32-32H256V80z"]},qZ={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"]},Pw=qZ,KZ={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"]},YZ={prefix:"fas",iconName:"rotate",icon:[512,512,[128260,"sync-alt"],"f2f1","M142.9 142.9c62.2-62.2 162.7-62.5 225.3-1L327 183c-6.9 6.9-8.9 17.2-5.2 26.2s12.5 14.8 22.2 14.8H463.5c0 0 0 0 0 0H472c13.3 0 24-10.7 24-24V72c0-9.7-5.8-18.5-14.8-22.2s-19.3-1.7-26.2 5.2L413.4 96.6c-87.6-86.5-228.7-86.2-315.8 1C73.2 122 55.6 150.7 44.8 181.4c-5.9 16.7 2.9 34.9 19.5 40.8s34.9-2.9 40.8-19.5c7.7-21.8 20.2-42.3 37.8-59.8zM16 312v7.6 .7V440c0 9.7 5.8 18.5 14.8 22.2s19.3 1.7 26.2-5.2l41.6-41.6c87.6 86.5 228.7 86.2 315.8-1c24.4-24.4 42.1-53.1 52.9-83.7c5.9-16.7-2.9-34.9-19.5-40.8s-34.9 2.9-40.8 19.5c-7.7 21.8-20.2 42.3-37.8 59.8c-62.2 62.2-162.7 62.5-225.3 1L185 329c6.9-6.9 8.9-17.2 5.2-26.2s-12.5-14.8-22.2-14.8H48.4h-.7H40c-13.3 0-24 10.7-24 24z"]},ZZ=YZ,Ok={prefix:"fas",iconName:"robot",icon:[640,512,[129302],"f544","M320 0c17.7 0 32 14.3 32 32V96H472c39.8 0 72 32.2 72 72V440c0 39.8-32.2 72-72 72H168c-39.8 0-72-32.2-72-72V168c0-39.8 32.2-72 72-72H288V32c0-17.7 14.3-32 32-32zM208 384c-8.8 0-16 7.2-16 16s7.2 16 16 16h32c8.8 0 16-7.2 16-16s-7.2-16-16-16H208zm96 0c-8.8 0-16 7.2-16 16s7.2 16 16 16h32c8.8 0 16-7.2 16-16s-7.2-16-16-16H304zm96 0c-8.8 0-16 7.2-16 16s7.2 16 16 16h32c8.8 0 16-7.2 16-16s-7.2-16-16-16H400zM264 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 224H64V416H48c-26.5 0-48-21.5-48-48V272c0-26.5 21.5-48 48-48zm544 0c26.5 0 48 21.5 48 48v96c0 26.5-21.5 48-48 48H576V224h16z"]},zD={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 8h-.7c-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"]},XZ=zD,QZ={prefix:"fas",iconName:"qrcode",icon:[448,512,[],"f029","M0 80C0 53.5 21.5 32 48 32h96c26.5 0 48 21.5 48 48v96c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V80zM64 96v64h64V96H64zM0 336c0-26.5 21.5-48 48-48h96c26.5 0 48 21.5 48 48v96c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V336zm64 16v64h64V352H64zM304 32h96c26.5 0 48 21.5 48 48v96c0 26.5-21.5 48-48 48H304c-26.5 0-48-21.5-48-48V80c0-26.5 21.5-48 48-48zm80 64H320v64h64V96zM256 304c0-8.8 7.2-16 16-16h64c8.8 0 16 7.2 16 16s7.2 16 16 16h32c8.8 0 16-7.2 16-16s7.2-16 16-16s16 7.2 16 16v96c0 8.8-7.2 16-16 16H368c-8.8 0-16-7.2-16-16s-7.2-16-16-16s-16 7.2-16 16v64c0 8.8-7.2 16-16 16H272c-8.8 0-16-7.2-16-16V304zM368 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"]},JZ={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"]},eX={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 162zM116.6 187.9L60.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.9zM220.9 270c-2.1 39.8 12.2 80.1 42.2 110c38.9 38.9 94.4 51 143.6 36.3L220.9 270z"]},tX={prefix:"fas",iconName:"desktop",icon:[576,512,[128421,61704,"desktop-alt"],"f390","M64 0C28.7 0 0 28.7 0 64V352c0 35.3 28.7 64 64 64H240l-10.7 32H160c-17.7 0-32 14.3-32 32s14.3 32 32 32H416c17.7 0 32-14.3 32-32s-14.3-32-32-32H346.7L336 416H512c35.3 0 64-28.7 64-64V64c0-35.3-28.7-64-64-64H64zM512 64V288H64V64H512z"]},gh={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"]},nX={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.3V384c0 35.3 28.7 64 64 64h64c17.7 0 32 14.3 32 32s-14.3 32-32 32H416c-70.7 0-128-57.3-128-128c0-35.3-28.7-64-64-64H109.3l41.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 256H224c23.3 0 45.2 6.2 64 17.1V109.3l-41.4 41.4z"]},rX={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 480H40c-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 24V296c0 13.3 10.7 24 24 24s24-10.7 24-24V184c0-13.3-10.7-24-24-24zm32 224a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z"]},iX=rX;function Sk(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 Le(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n-1;i--){var o=n[i],a=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(a)>-1&&(r=o)}return Mt.head.insertBefore(t,r),e}}var jX="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";function wh(){for(var e=12,t="";e-- >0;)t+=jX[Math.random()*62|0];return t}function Kc(e){for(var t=[],n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function _P(e){return e.classList?Kc(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(t){return t})}function e5(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function AX(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,'="').concat(e5(e[n]),'" ')},"").trim()}function X0(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,": ").concat(e[n].trim(),";")},"")}function xP(e){return e.size!==uo.size||e.x!==uo.x||e.y!==uo.y||e.rotate!==uo.rotate||e.flipX||e.flipY}function kX(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,i={transform:"translate(".concat(n/2," 256)")},o="translate(".concat(t.x*32,", ").concat(t.y*32,") "),a="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),s="rotate(".concat(t.rotate," 0 0)"),l={transform:"".concat(o," ").concat(a," ").concat(s)},u={transform:"translate(".concat(r/2*-1," -256)")};return{outer:i,inner:l,path:u}}function NX(e){var t=e.transform,n=e.width,r=n===void 0?Tw:n,i=e.height,o=i===void 0?Tw:i,a=e.startCentered,s=a===void 0?!1:a,l="";return s&&qD?l+="translate(".concat(t.x/ya-r/2,"em, ").concat(t.y/ya-o/2,"em) "):s?l+="translate(calc(-50% + ".concat(t.x/ya,"em), calc(-50% + ").concat(t.y/ya,"em)) "):l+="translate(".concat(t.x/ya,"em, ").concat(t.y/ya,"em) "),l+="scale(".concat(t.size/ya*(t.flipX?-1:1),", ").concat(t.size/ya*(t.flipY?-1:1),") "),l+="rotate(".concat(t.rotate,"deg) "),l}var MX=`:root, :host { --fa-font-solid: normal 900 1em/1 "Font Awesome 6 Solid"; --fa-font-regular: normal 400 1em/1 "Font Awesome 6 Regular"; --fa-font-light: normal 300 1em/1 "Font Awesome 6 Light"; --fa-font-thin: normal 100 1em/1 "Font Awesome 6 Thin"; --fa-font-duotone: normal 900 1em/1 "Font Awesome 6 Duotone"; --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-brands: normal 400 1em/1 "Font Awesome 6 Brands"; } 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 { -webkit-transform-origin: center center; transform-origin: center center; } .fa-layers-text { left: 50%; top: 50%; -webkit-transform: translate(-50%, -50%); transform: translate(-50%, -50%); -webkit-transform-origin: center center; 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); -webkit-transform: scale(var(--fa-counter-scale, 0.25)); transform: scale(var(--fa-counter-scale, 0.25)); -webkit-transform-origin: top right; transform-origin: top right; } .fa-layers-bottom-right { bottom: var(--fa-bottom, 0); right: var(--fa-right, 0); top: auto; -webkit-transform: scale(var(--fa-layers-scale, 0.25)); transform: scale(var(--fa-layers-scale, 0.25)); -webkit-transform-origin: bottom right; transform-origin: bottom right; } .fa-layers-bottom-left { bottom: var(--fa-bottom, 0); left: var(--fa-left, 0); right: auto; top: auto; -webkit-transform: scale(var(--fa-layers-scale, 0.25)); transform: scale(var(--fa-layers-scale, 0.25)); -webkit-transform-origin: bottom left; transform-origin: bottom left; } .fa-layers-top-right { top: var(--fa-top, 0); right: var(--fa-right, 0); -webkit-transform: scale(var(--fa-layers-scale, 0.25)); transform: scale(var(--fa-layers-scale, 0.25)); -webkit-transform-origin: top right; transform-origin: top right; } .fa-layers-top-left { left: var(--fa-left, 0); right: auto; top: var(--fa-top, 0); -webkit-transform: scale(var(--fa-layers-scale, 0.25)); transform: scale(var(--fa-layers-scale, 0.25)); -webkit-transform-origin: top left; 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(var(--fa-li-width, 2em) * -1); 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 { -webkit-animation-name: fa-beat; animation-name: fa-beat; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, ease-in-out); animation-timing-function: var(--fa-animation-timing, ease-in-out); } .fa-bounce { -webkit-animation-name: fa-bounce; animation-name: fa-bounce; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1)); animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1)); } .fa-fade { -webkit-animation-name: fa-fade; animation-name: fa-fade; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1)); animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1)); } .fa-beat-fade { -webkit-animation-name: fa-beat-fade; animation-name: fa-beat-fade; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1)); animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1)); } .fa-flip { -webkit-animation-name: fa-flip; animation-name: fa-flip; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, ease-in-out); animation-timing-function: var(--fa-animation-timing, ease-in-out); } .fa-shake { -webkit-animation-name: fa-shake; animation-name: fa-shake; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, linear); animation-timing-function: var(--fa-animation-timing, linear); } .fa-spin { -webkit-animation-name: fa-spin; animation-name: fa-spin; -webkit-animation-delay: var(--fa-animation-delay, 0s); animation-delay: var(--fa-animation-delay, 0s); -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 2s); animation-duration: var(--fa-animation-duration, 2s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, linear); animation-timing-function: var(--fa-animation-timing, linear); } .fa-spin-reverse { --fa-animation-direction: reverse; } .fa-pulse, .fa-spin-pulse { -webkit-animation-name: fa-spin; animation-name: fa-spin; -webkit-animation-direction: var(--fa-animation-direction, normal); animation-direction: var(--fa-animation-direction, normal); -webkit-animation-duration: var(--fa-animation-duration, 1s); animation-duration: var(--fa-animation-duration, 1s); -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite); animation-iteration-count: var(--fa-animation-iteration-count, infinite); -webkit-animation-timing-function: var(--fa-animation-timing, steps(8)); 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 { -webkit-animation-delay: -1ms; animation-delay: -1ms; -webkit-animation-duration: 1ms; animation-duration: 1ms; -webkit-animation-iteration-count: 1; animation-iteration-count: 1; -webkit-transition-delay: 0s; transition-delay: 0s; -webkit-transition-duration: 0s; transition-duration: 0s; } } @-webkit-keyframes fa-beat { 0%, 90% { -webkit-transform: scale(1); transform: scale(1); } 45% { -webkit-transform: scale(var(--fa-beat-scale, 1.25)); transform: scale(var(--fa-beat-scale, 1.25)); } } @keyframes fa-beat { 0%, 90% { -webkit-transform: scale(1); transform: scale(1); } 45% { -webkit-transform: scale(var(--fa-beat-scale, 1.25)); transform: scale(var(--fa-beat-scale, 1.25)); } } @-webkit-keyframes fa-bounce { 0% { -webkit-transform: scale(1, 1) translateY(0); transform: scale(1, 1) translateY(0); } 10% { -webkit-transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0); transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0); } 30% { -webkit-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)); 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% { -webkit-transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0); transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0); } 57% { -webkit-transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em)); transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em)); } 64% { -webkit-transform: scale(1, 1) translateY(0); transform: scale(1, 1) translateY(0); } 100% { -webkit-transform: scale(1, 1) translateY(0); transform: scale(1, 1) translateY(0); } } @keyframes fa-bounce { 0% { -webkit-transform: scale(1, 1) translateY(0); transform: scale(1, 1) translateY(0); } 10% { -webkit-transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0); transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0); } 30% { -webkit-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)); 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% { -webkit-transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0); transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0); } 57% { -webkit-transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em)); transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em)); } 64% { -webkit-transform: scale(1, 1) translateY(0); transform: scale(1, 1) translateY(0); } 100% { -webkit-transform: scale(1, 1) translateY(0); transform: scale(1, 1) translateY(0); } } @-webkit-keyframes fa-fade { 50% { opacity: var(--fa-fade-opacity, 0.4); } } @keyframes fa-fade { 50% { opacity: var(--fa-fade-opacity, 0.4); } } @-webkit-keyframes fa-beat-fade { 0%, 100% { opacity: var(--fa-beat-fade-opacity, 0.4); -webkit-transform: scale(1); transform: scale(1); } 50% { opacity: 1; -webkit-transform: scale(var(--fa-beat-fade-scale, 1.125)); transform: scale(var(--fa-beat-fade-scale, 1.125)); } } @keyframes fa-beat-fade { 0%, 100% { opacity: var(--fa-beat-fade-opacity, 0.4); -webkit-transform: scale(1); transform: scale(1); } 50% { opacity: 1; -webkit-transform: scale(var(--fa-beat-fade-scale, 1.125)); transform: scale(var(--fa-beat-fade-scale, 1.125)); } } @-webkit-keyframes fa-flip { 50% { -webkit-transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg)); transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg)); } } @keyframes fa-flip { 50% { -webkit-transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg)); transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg)); } } @-webkit-keyframes fa-shake { 0% { -webkit-transform: rotate(-15deg); transform: rotate(-15deg); } 4% { -webkit-transform: rotate(15deg); transform: rotate(15deg); } 8%, 24% { -webkit-transform: rotate(-18deg); transform: rotate(-18deg); } 12%, 28% { -webkit-transform: rotate(18deg); transform: rotate(18deg); } 16% { -webkit-transform: rotate(-22deg); transform: rotate(-22deg); } 20% { -webkit-transform: rotate(22deg); transform: rotate(22deg); } 32% { -webkit-transform: rotate(-12deg); transform: rotate(-12deg); } 36% { -webkit-transform: rotate(12deg); transform: rotate(12deg); } 40%, 100% { -webkit-transform: rotate(0deg); transform: rotate(0deg); } } @keyframes fa-shake { 0% { -webkit-transform: rotate(-15deg); transform: rotate(-15deg); } 4% { -webkit-transform: rotate(15deg); transform: rotate(15deg); } 8%, 24% { -webkit-transform: rotate(-18deg); transform: rotate(-18deg); } 12%, 28% { -webkit-transform: rotate(18deg); transform: rotate(18deg); } 16% { -webkit-transform: rotate(-22deg); transform: rotate(-22deg); } 20% { -webkit-transform: rotate(22deg); transform: rotate(22deg); } 32% { -webkit-transform: rotate(-12deg); transform: rotate(-12deg); } 36% { -webkit-transform: rotate(12deg); transform: rotate(12deg); } 40%, 100% { -webkit-transform: rotate(0deg); transform: rotate(0deg); } } @-webkit-keyframes fa-spin { 0% { -webkit-transform: rotate(0deg); transform: rotate(0deg); } 100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); } } @keyframes fa-spin { 0% { -webkit-transform: rotate(0deg); transform: rotate(0deg); } 100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); } } .fa-rotate-90 { -webkit-transform: rotate(90deg); transform: rotate(90deg); } .fa-rotate-180 { -webkit-transform: rotate(180deg); transform: rotate(180deg); } .fa-rotate-270 { -webkit-transform: rotate(270deg); transform: rotate(270deg); } .fa-flip-horizontal { -webkit-transform: scale(-1, 1); transform: scale(-1, 1); } .fa-flip-vertical { -webkit-transform: scale(1, -1); transform: scale(1, -1); } .fa-flip-both, .fa-flip-horizontal.fa-flip-vertical { -webkit-transform: scale(-1, -1); transform: scale(-1, -1); } .fa-rotate-by { -webkit-transform: rotate(var(--fa-rotate-angle, 0)); 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; } .fad.fa-inverse, .fa-duotone.fa-inverse { color: var(--fa-inverse, #fff); }`;function t5(){var e=KD,t=YD,n=Fe.cssPrefix,r=Fe.replacementClass,i=MX;if(n!==e||r!==t){var o=new RegExp("\\.".concat(e,"\\-"),"g"),a=new RegExp("\\--".concat(e,"\\-"),"g"),s=new RegExp("\\.".concat(t),"g");i=i.replace(o,".".concat(n,"-")).replace(a,"--".concat(n,"-")).replace(s,".".concat(r))}return i}var kk=!1;function d_(){Fe.autoAddCss&&!kk&&(TX(t5()),kk=!0)}var RX={mixout:function(){return{dom:{css:t5,insertCss:d_}}},hooks:function(){return{beforeDOMElementCreation:function(){d_()},beforeI2svg:function(){d_()}}}},Qo=ns||{};Qo[Xo]||(Qo[Xo]={});Qo[Xo].styles||(Qo[Xo].styles={});Qo[Xo].hooks||(Qo[Xo].hooks={});Qo[Xo].shims||(Qo[Xo].shims=[]);var Li=Qo[Xo],n5=[],LX=function e(){Mt.removeEventListener("DOMContentLoaded",e),Dg=1,n5.map(function(t){return t()})},Dg=!1;ua&&(Dg=(Mt.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(Mt.readyState),Dg||Mt.addEventListener("DOMContentLoaded",LX));function $X(e){ua&&(Dg?setTimeout(e,0):n5.push(e))}function kp(e){var t=e.tag,n=e.attributes,r=n===void 0?{}:n,i=e.children,o=i===void 0?[]:i;return typeof e=="string"?e5(e):"<".concat(t," ").concat(AX(r),">").concat(o.map(kp).join(""),"")}function Nk(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}var IX=function(t,n){return function(r,i,o,a){return t.call(n,r,i,o,a)}},h_=function(t,n,r,i){var o=Object.keys(t),a=o.length,s=i!==void 0?IX(n,i):n,l,u,f;for(r===void 0?(l=1,f=t[o[0]]):(l=0,f=r);l=55296&&i<=56319&&n=55296&&r<=56319&&n>t+1&&(i=e.charCodeAt(t+1),i>=56320&&i<=57343)?(r-55296)*1024+i-56320+65536:r}function Mk(e){return Object.keys(e).reduce(function(t,n){var r=e[n],i=!!r.icon;return i?t[r.iconName]=r.icon:t[n]=r,t},{})}function kw(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.skipHooks,i=r===void 0?!1:r,o=Mk(t);typeof Li.hooks.addPack=="function"&&!i?Li.hooks.addPack(e,Mk(t)):Li.styles[e]=Le(Le({},Li.styles[e]||{}),o),e==="fas"&&kw("fa",t)}var Qm,Jm,ev,ku=Li.styles,BX=Li.shims,UX=(Qm={},vn(Qm,At,Object.values(_h[At])),vn(Qm,Kt,Object.values(_h[Kt])),Qm),wP=null,r5={},i5={},o5={},a5={},s5={},zX=(Jm={},vn(Jm,At,Object.keys(yh[At])),vn(Jm,Kt,Object.keys(yh[Kt])),Jm);function VX(e){return~OX.indexOf(e)}function WX(e,t){var n=t.split("-"),r=n[0],i=n.slice(1).join("-");return r===e&&i!==""&&!VX(i)?i:null}var l5=function(){var t=function(o){return h_(ku,function(a,s,l){return a[l]=h_(s,o,{}),a},{})};r5=t(function(i,o,a){if(o[3]&&(i[o[3]]=a),o[2]){var s=o[2].filter(function(l){return typeof l=="number"});s.forEach(function(l){i[l.toString(16)]=a})}return i}),i5=t(function(i,o,a){if(i[a]=a,o[2]){var s=o[2].filter(function(l){return typeof l=="string"});s.forEach(function(l){i[l]=a})}return i}),s5=t(function(i,o,a){var s=o[2];return i[a]=a,s.forEach(function(l){i[l]=a}),i});var n="far"in ku||Fe.autoFetchSvg,r=h_(BX,function(i,o){var a=o[0],s=o[1],l=o[2];return s==="far"&&!n&&(s="fas"),typeof a=="string"&&(i.names[a]={prefix:s,iconName:l}),typeof a=="number"&&(i.unicodes[a.toString(16)]={prefix:s,iconName:l}),i},{names:{},unicodes:{}});o5=r.names,a5=r.unicodes,wP=Q0(Fe.styleDefault,{family:Fe.familyDefault})};CX(function(e){wP=Q0(e.styleDefault,{family:Fe.familyDefault})});l5();function OP(e,t){return(r5[e]||{})[t]}function HX(e,t){return(i5[e]||{})[t]}function tl(e,t){return(s5[e]||{})[t]}function u5(e){return o5[e]||{prefix:null,iconName:null}}function GX(e){var t=a5[e],n=OP("fas",e);return t||(n?{prefix:"fas",iconName:n}:null)||{prefix:null,iconName:null}}function rs(){return wP}var SP=function(){return{prefix:null,iconName:null,rest:[]}};function Q0(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.family,r=n===void 0?At:n,i=yh[r][e],o=bh[r][e]||bh[r][i],a=e in Li.styles?e:null;return o||a||null}var Rk=(ev={},vn(ev,At,Object.keys(_h[At])),vn(ev,Kt,Object.keys(_h[Kt])),ev);function J0(e){var t,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.skipLookups,i=r===void 0?!1:r,o=(t={},vn(t,At,"".concat(Fe.cssPrefix,"-").concat(At)),vn(t,Kt,"".concat(Fe.cssPrefix,"-").concat(Kt)),t),a=null,s=At;(e.includes(o[At])||e.some(function(u){return Rk[At].includes(u)}))&&(s=At),(e.includes(o[Kt])||e.some(function(u){return Rk[Kt].includes(u)}))&&(s=Kt);var l=e.reduce(function(u,f){var d=WX(Fe.cssPrefix,f);if(ku[f]?(f=UX[s].includes(f)?gX[s][f]:f,a=f,u.prefix=f):zX[s].indexOf(f)>-1?(a=f,u.prefix=Q0(f,{family:s})):d?u.iconName=d:f!==Fe.replacementClass&&f!==o[At]&&f!==o[Kt]&&u.rest.push(f),!i&&u.prefix&&u.iconName){var h=a==="fa"?u5(u.iconName):{},v=tl(u.prefix,u.iconName);h.prefix&&(a=null),u.iconName=h.iconName||v||u.iconName,u.prefix=h.prefix||u.prefix,u.prefix==="far"&&!ku.far&&ku.fas&&!Fe.autoFetchSvg&&(u.prefix="fas")}return u},SP());return(e.includes("fa-brands")||e.includes("fab"))&&(l.prefix="fab"),(e.includes("fa-duotone")||e.includes("fad"))&&(l.prefix="fad"),!l.prefix&&s===Kt&&(ku.fass||Fe.autoFetchSvg)&&(l.prefix="fass",l.iconName=tl(l.prefix,l.iconName)||l.iconName),(l.prefix==="fa"||a==="fa")&&(l.prefix=rs()||"fas"),l}var qX=function(){function e(){oX(this,e),this.definitions={}}return aX(e,[{key:"add",value:function(){for(var n=this,r=arguments.length,i=new Array(r),o=0;o0&&f.forEach(function(d){typeof d=="string"&&(n[s][d]=u)}),n[s][l]=u}),n}}]),e}(),Lk=[],Nu={},Gu={},KX=Object.keys(Gu);function YX(e,t){var n=t.mixoutsTo;return Lk=e,Nu={},Object.keys(Gu).forEach(function(r){KX.indexOf(r)===-1&&delete Gu[r]}),Lk.forEach(function(r){var i=r.mixout?r.mixout():{};if(Object.keys(i).forEach(function(a){typeof i[a]=="function"&&(n[a]=i[a]),Ig(i[a])==="object"&&Object.keys(i[a]).forEach(function(s){n[a]||(n[a]={}),n[a][s]=i[a][s]})}),r.hooks){var o=r.hooks();Object.keys(o).forEach(function(a){Nu[a]||(Nu[a]=[]),Nu[a].push(o[a])})}r.provides&&r.provides(Gu)}),n}function Nw(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i1?t-1:0),r=1;r0&&arguments[0]!==void 0?arguments[0]:{};return ua?(Ol("beforeI2svg",t),Jo("pseudoElements2svg",t),Jo("i2svg",t)):Promise.reject("Operation requires a DOM of some kind.")},watch:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot;Fe.autoReplaceSvg===!1&&(Fe.autoReplaceSvg=!0),Fe.observeMutations=!0,$X(function(){JX({autoReplaceSvgRoot:n}),Ol("watch",t)})}},QX={icon:function(t){if(t===null)return null;if(Ig(t)==="object"&&t.prefix&&t.iconName)return{prefix:t.prefix,iconName:tl(t.prefix,t.iconName)||t.iconName};if(Array.isArray(t)&&t.length===2){var n=t[1].indexOf("fa-")===0?t[1].slice(3):t[1],r=Q0(t[0]);return{prefix:r,iconName:tl(r,n)||n}}if(typeof t=="string"&&(t.indexOf("".concat(Fe.cssPrefix,"-"))>-1||t.match(yX))){var i=J0(t.split(" "),{skipLookups:!0});return{prefix:i.prefix||rs(),iconName:tl(i.prefix,i.iconName)||i.iconName}}if(typeof t=="string"){var o=rs();return{prefix:o,iconName:tl(o,t)||t}}}},qr={noAuto:ZX,config:Fe,dom:XX,parse:QX,library:c5,findIconDefinition:Mw,toHtml:kp},JX=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot,r=n===void 0?Mt:n;(Object.keys(Li.styles).length>0||Fe.autoFetchSvg)&&ua&&Fe.autoReplaceSvg&&qr.dom.i2svg({node:r})};function eb(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(r){return kp(r)})}}),Object.defineProperty(e,"node",{get:function(){if(ua){var r=Mt.createElement("div");return r.innerHTML=e.html,r.children}}}),e}function eQ(e){var t=e.children,n=e.main,r=e.mask,i=e.attributes,o=e.styles,a=e.transform;if(xP(a)&&n.found&&!r.found){var s=n.width,l=n.height,u={x:s/l/2,y:.5};i.style=X0(Le(Le({},o),{},{"transform-origin":"".concat(u.x+a.x/16,"em ").concat(u.y+a.y/16,"em")}))}return[{tag:"svg",attributes:i,children:t}]}function tQ(e){var t=e.prefix,n=e.iconName,r=e.children,i=e.attributes,o=e.symbol,a=o===!0?"".concat(t,"-").concat(Fe.cssPrefix,"-").concat(n):o;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:Le(Le({},i),{},{id:a}),children:r}]}]}function EP(e){var t=e.icons,n=t.main,r=t.mask,i=e.prefix,o=e.iconName,a=e.transform,s=e.symbol,l=e.title,u=e.maskId,f=e.titleId,d=e.extra,h=e.watchable,v=h===void 0?!1:h,g=r.found?r:n,y=g.width,x=g.height,_=i==="fak",b=[Fe.replacementClass,o?"".concat(Fe.cssPrefix,"-").concat(o):""].filter(function(D){return d.classes.indexOf(D)===-1}).filter(function(D){return D!==""||!!D}).concat(d.classes).join(" "),w={children:[],attributes:Le(Le({},d.attributes),{},{"data-prefix":i,"data-icon":o,class:b,role:d.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(y," ").concat(x)})},S=_&&!~d.classes.indexOf("fa-fw")?{width:"".concat(y/x*16*.0625,"em")}:{};v&&(w.attributes[wl]=""),l&&(w.children.push({tag:"title",attributes:{id:w.attributes["aria-labelledby"]||"title-".concat(f||wh())},children:[l]}),delete w.attributes.title);var E=Le(Le({},w),{},{prefix:i,iconName:o,main:n,mask:r,maskId:u,transform:a,symbol:s,styles:Le(Le({},S),d.styles)}),P=r.found&&n.found?Jo("generateAbstractMask",E)||{children:[],attributes:{}}:Jo("generateAbstractIcon",E)||{children:[],attributes:{}},T=P.children,A=P.attributes;return E.children=T,E.attributes=A,s?tQ(E):eQ(E)}function $k(e){var t=e.content,n=e.width,r=e.height,i=e.transform,o=e.title,a=e.extra,s=e.watchable,l=s===void 0?!1:s,u=Le(Le(Le({},a.attributes),o?{title:o}:{}),{},{class:a.classes.join(" ")});l&&(u[wl]="");var f=Le({},a.styles);xP(i)&&(f.transform=NX({transform:i,startCentered:!0,width:n,height:r}),f["-webkit-transform"]=f.transform);var d=X0(f);d.length>0&&(u.style=d);var h=[];return h.push({tag:"span",attributes:u,children:[t]}),o&&h.push({tag:"span",attributes:{class:"sr-only"},children:[o]}),h}function nQ(e){var t=e.content,n=e.title,r=e.extra,i=Le(Le(Le({},r.attributes),n?{title:n}:{}),{},{class:r.classes.join(" ")}),o=X0(r.styles);o.length>0&&(i.style=o);var a=[];return a.push({tag:"span",attributes:i,children:[t]}),n&&a.push({tag:"span",attributes:{class:"sr-only"},children:[n]}),a}var p_=Li.styles;function Rw(e){var t=e[0],n=e[1],r=e.slice(4),i=mP(r,1),o=i[0],a=null;return Array.isArray(o)?a={tag:"g",attributes:{class:"".concat(Fe.cssPrefix,"-").concat(el.GROUP)},children:[{tag:"path",attributes:{class:"".concat(Fe.cssPrefix,"-").concat(el.SECONDARY),fill:"currentColor",d:o[0]}},{tag:"path",attributes:{class:"".concat(Fe.cssPrefix,"-").concat(el.PRIMARY),fill:"currentColor",d:o[1]}}]}:a={tag:"path",attributes:{fill:"currentColor",d:o}},{found:!0,width:t,height:n,icon:a}}var rQ={found:!1,width:512,height:512};function iQ(e,t){!ZD&&!Fe.showMissingIcons&&e&&console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}function Lw(e,t){var n=t;return t==="fa"&&Fe.styleDefault!==null&&(t=rs()),new Promise(function(r,i){if(Jo("missingIconAbstract"),n==="fa"){var o=u5(e)||{};e=o.iconName||e,t=o.prefix||t}if(e&&t&&p_[t]&&p_[t][e]){var a=p_[t][e];return r(Rw(a))}iQ(e,t),r(Le(Le({},rQ),{},{icon:Fe.showMissingIcons&&e?Jo("missingIconAbstract")||{}:{}}))})}var Ik=function(){},$w=Fe.measurePerformance&&Gm&&Gm.mark&&Gm.measure?Gm:{mark:Ik,measure:Ik},dd='FA "6.5.2"',oQ=function(t){return $w.mark("".concat(dd," ").concat(t," begins")),function(){return f5(t)}},f5=function(t){$w.mark("".concat(dd," ").concat(t," ends")),$w.measure("".concat(dd," ").concat(t),"".concat(dd," ").concat(t," begins"),"".concat(dd," ").concat(t," ends"))},PP={begin:oQ,end:f5},Gv=function(){};function Dk(e){var t=e.getAttribute?e.getAttribute(wl):null;return typeof t=="string"}function aQ(e){var t=e.getAttribute?e.getAttribute(gP):null,n=e.getAttribute?e.getAttribute(yP):null;return t&&n}function sQ(e){return e&&e.classList&&e.classList.contains&&e.classList.contains(Fe.replacementClass)}function lQ(){if(Fe.autoReplaceSvg===!0)return qv.replace;var e=qv[Fe.autoReplaceSvg];return e||qv.replace}function uQ(e){return Mt.createElementNS("http://www.w3.org/2000/svg",e)}function cQ(e){return Mt.createElement(e)}function d5(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.ceFn,r=n===void 0?e.tag==="svg"?uQ:cQ:n;if(typeof e=="string")return Mt.createTextNode(e);var i=r(e.tag);Object.keys(e.attributes||[]).forEach(function(a){i.setAttribute(a,e.attributes[a])});var o=e.children||[];return o.forEach(function(a){i.appendChild(d5(a,{ceFn:r}))}),i}function fQ(e){var t=" ".concat(e.outerHTML," ");return t="".concat(t,"Font Awesome fontawesome.com "),t}var qv={replace:function(t){var n=t[0];if(n.parentNode)if(t[1].forEach(function(i){n.parentNode.insertBefore(d5(i),n)}),n.getAttribute(wl)===null&&Fe.keepOriginalSource){var r=Mt.createComment(fQ(n));n.parentNode.replaceChild(r,n)}else n.remove()},nest:function(t){var n=t[0],r=t[1];if(~_P(n).indexOf(Fe.replacementClass))return qv.replace(t);var i=new RegExp("".concat(Fe.cssPrefix,"-.*"));if(delete r[0].attributes.id,r[0].attributes.class){var o=r[0].attributes.class.split(" ").reduce(function(s,l){return l===Fe.replacementClass||l.match(i)?s.toSvg.push(l):s.toNode.push(l),s},{toNode:[],toSvg:[]});r[0].attributes.class=o.toSvg.join(" "),o.toNode.length===0?n.removeAttribute("class"):n.setAttribute("class",o.toNode.join(" "))}var a=r.map(function(s){return kp(s)}).join(` `);n.setAttribute(wl,""),n.innerHTML=a}};function Fk(e){e()}function h5(e,t){var n=typeof t=="function"?t:Gv;if(e.length===0)n();else{var r=Fk;Fe.mutateApproach===mX&&(r=ns.requestAnimationFrame||Fk),r(function(){var i=lQ(),o=PP.begin("mutate");e.map(i),o(),n()})}}var CP=!1;function p5(){CP=!0}function Iw(){CP=!1}var Fg=null;function Bk(e){if(jk&&Fe.observeMutations){var t=e.treeCallback,n=t===void 0?Gv:t,r=e.nodeCallback,i=r===void 0?Gv:r,o=e.pseudoElementsCallback,a=o===void 0?Gv:o,s=e.observeMutationsRoot,l=s===void 0?Mt:s;Fg=new jk(function(u){if(!CP){var f=rs();Kc(u).forEach(function(d){if(d.type==="childList"&&d.addedNodes.length>0&&!Dk(d.addedNodes[0])&&(Fe.searchPseudoElements&&a(d.target),n(d.target)),d.type==="attributes"&&d.target.parentNode&&Fe.searchPseudoElements&&a(d.target.parentNode),d.type==="attributes"&&Dk(d.target)&&~wX.indexOf(d.attributeName))if(d.attributeName==="class"&&aQ(d.target)){var h=J0(_P(d.target)),v=h.prefix,g=h.iconName;d.target.setAttribute(gP,v||f),g&&d.target.setAttribute(yP,g)}else sQ(d.target)&&i(d.target)})}}),ua&&Fg.observe(l,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function dQ(){Fg&&Fg.disconnect()}function hQ(e){var t=e.getAttribute("style"),n=[];return t&&(n=t.split(";").reduce(function(r,i){var o=i.split(":"),a=o[0],s=o.slice(1);return a&&s.length>0&&(r[a]=s.join(":").trim()),r},{})),n}function pQ(e){var t=e.getAttribute("data-prefix"),n=e.getAttribute("data-icon"),r=e.innerText!==void 0?e.innerText.trim():"",i=J0(_P(e));return i.prefix||(i.prefix=rs()),t&&n&&(i.prefix=t,i.iconName=n),i.iconName&&i.prefix||(i.prefix&&r.length>0&&(i.iconName=HX(i.prefix,e.innerText)||OP(i.prefix,Aw(e.innerText))),!i.iconName&&Fe.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function mQ(e){var t=Kc(e.attributes).reduce(function(i,o){return i.name!=="class"&&i.name!=="style"&&(i[o.name]=o.value),i},{}),n=e.getAttribute("title"),r=e.getAttribute("data-fa-title-id");return Fe.autoA11y&&(n?t["aria-labelledby"]="".concat(Fe.replacementClass,"-title-").concat(r||wh()):(t["aria-hidden"]="true",t.focusable="false")),t}function vQ(){return{iconName:null,title:null,titleId:null,prefix:null,transform:uo,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}}}function Uk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{styleParser:!0},n=pQ(e),r=n.iconName,i=n.prefix,o=n.rest,a=mQ(e),s=Nw("parseNodeAttributes",{},e),l=t.styleParser?hQ(e):[];return Le({iconName:r,title:e.getAttribute("title"),titleId:e.getAttribute("data-fa-title-id"),prefix:i,transform:uo,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:o,styles:l,attributes:a}},s)}var gQ=Li.styles;function m5(e){var t=Fe.autoReplaceSvg==="nest"?Uk(e,{styleParser:!1}):Uk(e);return~t.extra.classes.indexOf(XD)?Jo("generateLayersText",e,t):Jo("generateSvgReplacementMutation",e,t)}var is=new Set;bP.map(function(e){is.add("fa-".concat(e))});Object.keys(yh[At]).map(is.add.bind(is));Object.keys(yh[Kt]).map(is.add.bind(is));is=jp(is);function zk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(!ua)return Promise.resolve();var n=Mt.documentElement.classList,r=function(d){return n.add("".concat(Ak,"-").concat(d))},i=function(d){return n.remove("".concat(Ak,"-").concat(d))},o=Fe.autoFetchSvg?is:bP.map(function(f){return"fa-".concat(f)}).concat(Object.keys(gQ));o.includes("fa")||o.push("fa");var a=[".".concat(XD,":not([").concat(wl,"])")].concat(o.map(function(f){return".".concat(f,":not([").concat(wl,"])")})).join(", ");if(a.length===0)return Promise.resolve();var s=[];try{s=Kc(e.querySelectorAll(a))}catch{}if(s.length>0)r("pending"),i("complete");else return Promise.resolve();var l=PP.begin("onTree"),u=s.reduce(function(f,d){try{var h=m5(d);h&&f.push(h)}catch(v){ZD||v.name==="MissingIcon"&&console.error(v)}return f},[]);return new Promise(function(f,d){Promise.all(u).then(function(h){h5(h,function(){r("active"),r("complete"),i("pending"),typeof t=="function"&&t(),l(),f()})}).catch(function(h){l(),d(h)})})}function yQ(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;m5(e).then(function(n){n&&h5([n],t)})}function bQ(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=(t||{}).icon?t:Mw(t||{}),i=n.mask;return i&&(i=(i||{}).icon?i:Mw(i||{})),e(r,Le(Le({},n),{},{mask:i}))}}var _Q=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.transform,i=r===void 0?uo:r,o=n.symbol,a=o===void 0?!1:o,s=n.mask,l=s===void 0?null:s,u=n.maskId,f=u===void 0?null:u,d=n.title,h=d===void 0?null:d,v=n.titleId,g=v===void 0?null:v,y=n.classes,x=y===void 0?[]:y,_=n.attributes,b=_===void 0?{}:_,w=n.styles,S=w===void 0?{}:w;if(t){var E=t.prefix,P=t.iconName,T=t.icon;return eb(Le({type:"icon"},t),function(){return Ol("beforeDOMElementCreation",{iconDefinition:t,params:n}),Fe.autoA11y&&(h?b["aria-labelledby"]="".concat(Fe.replacementClass,"-title-").concat(g||wh()):(b["aria-hidden"]="true",b.focusable="false")),EP({icons:{main:Rw(T),mask:l?Rw(l.icon):{found:!1,width:null,height:null,icon:{}}},prefix:E,iconName:P,transform:Le(Le({},uo),i),symbol:a,title:h,maskId:f,titleId:g,extra:{attributes:b,styles:S,classes:x}})})}},xQ={mixout:function(){return{icon:bQ(_Q)}},hooks:function(){return{mutationObserverCallbacks:function(n){return n.treeCallback=zk,n.nodeCallback=yQ,n}}},provides:function(t){t.i2svg=function(n){var r=n.node,i=r===void 0?Mt:r,o=n.callback,a=o===void 0?function(){}:o;return zk(i,a)},t.generateSvgReplacementMutation=function(n,r){var i=r.iconName,o=r.title,a=r.titleId,s=r.prefix,l=r.transform,u=r.symbol,f=r.mask,d=r.maskId,h=r.extra;return new Promise(function(v,g){Promise.all([Lw(i,s),f.iconName?Lw(f.iconName,f.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(y){var x=mP(y,2),_=x[0],b=x[1];v([n,EP({icons:{main:_,mask:b},prefix:s,iconName:i,transform:l,symbol:u,maskId:d,title:o,titleId:a,extra:h,watchable:!0})])}).catch(g)})},t.generateAbstractIcon=function(n){var r=n.children,i=n.attributes,o=n.main,a=n.transform,s=n.styles,l=X0(s);l.length>0&&(i.style=l);var u;return xP(a)&&(u=Jo("generateAbstractTransformGrouping",{main:o,transform:a,containerWidth:o.width,iconWidth:o.width})),r.push(u||o.icon),{children:r,attributes:i}}}},wQ={mixout:function(){return{layer:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.classes,o=i===void 0?[]:i;return eb({type:"layer"},function(){Ol("beforeDOMElementCreation",{assembler:n,params:r});var a=[];return n(function(s){Array.isArray(s)?s.map(function(l){a=a.concat(l.abstract)}):a=a.concat(s.abstract)}),[{tag:"span",attributes:{class:["".concat(Fe.cssPrefix,"-layers")].concat(jp(o)).join(" ")},children:a}]})}}}},OQ={mixout:function(){return{counter:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.title,o=i===void 0?null:i,a=r.classes,s=a===void 0?[]:a,l=r.attributes,u=l===void 0?{}:l,f=r.styles,d=f===void 0?{}:f;return eb({type:"counter",content:n},function(){return Ol("beforeDOMElementCreation",{content:n,params:r}),nQ({content:n.toString(),title:o,extra:{attributes:u,styles:d,classes:["".concat(Fe.cssPrefix,"-layers-counter")].concat(jp(s))}})})}}}},SQ={mixout:function(){return{text:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.transform,o=i===void 0?uo:i,a=r.title,s=a===void 0?null:a,l=r.classes,u=l===void 0?[]:l,f=r.attributes,d=f===void 0?{}:f,h=r.styles,v=h===void 0?{}:h;return eb({type:"text",content:n},function(){return Ol("beforeDOMElementCreation",{content:n,params:r}),$k({content:n,transform:Le(Le({},uo),o),title:s,extra:{attributes:d,styles:v,classes:["".concat(Fe.cssPrefix,"-layers-text")].concat(jp(u))}})})}}},provides:function(t){t.generateLayersText=function(n,r){var i=r.title,o=r.transform,a=r.extra,s=null,l=null;if(qD){var u=parseInt(getComputedStyle(n).fontSize,10),f=n.getBoundingClientRect();s=f.width/u,l=f.height/u}return Fe.autoA11y&&!i&&(a.attributes["aria-hidden"]="true"),Promise.resolve([n,$k({content:n.innerHTML,width:s,height:l,transform:o,title:i,extra:a,watchable:!0})])}}},EQ=new RegExp('"',"ug"),Vk=[1105920,1112319];function PQ(e){var t=e.replace(EQ,""),n=FX(t,0),r=n>=Vk[0]&&n<=Vk[1],i=t.length===2?t[0]===t[1]:!1;return{value:Aw(i?t[0]:t),isSecondary:r||i}}function Wk(e,t){var n="".concat(pX).concat(t.replace(":","-"));return new Promise(function(r,i){if(e.getAttribute(n)!==null)return r();var o=Kc(e.children),a=o.filter(function(T){return T.getAttribute(jw)===t})[0],s=ns.getComputedStyle(e,t),l=s.getPropertyValue("font-family").match(bX),u=s.getPropertyValue("font-weight"),f=s.getPropertyValue("content");if(a&&!l)return e.removeChild(a),r();if(l&&f!=="none"&&f!==""){var d=s.getPropertyValue("content"),h=~["Sharp"].indexOf(l[2])?Kt:At,v=~["Solid","Regular","Light","Thin","Duotone","Brands","Kit"].indexOf(l[2])?bh[h][l[2].toLowerCase()]:_X[h][u],g=PQ(d),y=g.value,x=g.isSecondary,_=l[0].startsWith("FontAwesome"),b=OP(v,y),w=b;if(_){var S=GX(y);S.iconName&&S.prefix&&(b=S.iconName,v=S.prefix)}if(b&&!x&&(!a||a.getAttribute(gP)!==v||a.getAttribute(yP)!==w)){e.setAttribute(n,w),a&&e.removeChild(a);var E=vQ(),P=E.extra;P.attributes[jw]=t,Lw(b,v).then(function(T){var A=EP(Le(Le({},E),{},{icons:{main:T,mask:SP()},prefix:v,iconName:w,extra:P,watchable:!0})),D=Mt.createElementNS("http://www.w3.org/2000/svg","svg");t==="::before"?e.insertBefore(D,e.firstChild):e.appendChild(D),D.outerHTML=A.map(function(k){return kp(k)}).join(` `),e.removeAttribute(n),r()}).catch(i)}else r()}else r()})}function CQ(e){return Promise.all([Wk(e,"::before"),Wk(e,"::after")])}function TQ(e){return e.parentNode!==document.head&&!~vX.indexOf(e.tagName.toUpperCase())&&!e.getAttribute(jw)&&(!e.parentNode||e.parentNode.tagName!=="svg")}function Hk(e){if(ua)return new Promise(function(t,n){var r=Kc(e.querySelectorAll("*")).filter(TQ).map(CQ),i=PP.begin("searchPseudoElements");p5(),Promise.all(r).then(function(){i(),Iw(),t()}).catch(function(){i(),Iw(),n()})})}var jQ={hooks:function(){return{mutationObserverCallbacks:function(n){return n.pseudoElementsCallback=Hk,n}}},provides:function(t){t.pseudoElements2svg=function(n){var r=n.node,i=r===void 0?Mt:r;Fe.searchPseudoElements&&Hk(i)}}},Gk=!1,AQ={mixout:function(){return{dom:{unwatch:function(){p5(),Gk=!0}}}},hooks:function(){return{bootstrap:function(){Bk(Nw("mutationObserverCallbacks",{}))},noAuto:function(){dQ()},watch:function(n){var r=n.observeMutationsRoot;Gk?Iw():Bk(Nw("mutationObserverCallbacks",{observeMutationsRoot:r}))}}}},qk=function(t){var n={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return t.toLowerCase().split(" ").reduce(function(r,i){var o=i.toLowerCase().split("-"),a=o[0],s=o.slice(1).join("-");if(a&&s==="h")return r.flipX=!0,r;if(a&&s==="v")return r.flipY=!0,r;if(s=parseFloat(s),isNaN(s))return r;switch(a){case"grow":r.size=r.size+s;break;case"shrink":r.size=r.size-s;break;case"left":r.x=r.x-s;break;case"right":r.x=r.x+s;break;case"up":r.y=r.y-s;break;case"down":r.y=r.y+s;break;case"rotate":r.rotate=r.rotate+s;break}return r},n)},kQ={mixout:function(){return{parse:{transform:function(n){return qk(n)}}}},hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-transform");return i&&(n.transform=qk(i)),n}}},provides:function(t){t.generateAbstractTransformGrouping=function(n){var r=n.main,i=n.transform,o=n.containerWidth,a=n.iconWidth,s={transform:"translate(".concat(o/2," 256)")},l="translate(".concat(i.x*32,", ").concat(i.y*32,") "),u="scale(".concat(i.size/16*(i.flipX?-1:1),", ").concat(i.size/16*(i.flipY?-1:1),") "),f="rotate(".concat(i.rotate," 0 0)"),d={transform:"".concat(l," ").concat(u," ").concat(f)},h={transform:"translate(".concat(a/2*-1," -256)")},v={outer:s,inner:d,path:h};return{tag:"g",attributes:Le({},v.outer),children:[{tag:"g",attributes:Le({},v.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:Le(Le({},r.icon.attributes),v.path)}]}]}}}},m_={x:0,y:0,width:"100%",height:"100%"};function Kk(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}function NQ(e){return e.tag==="g"?e.children:[e]}var MQ={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-mask"),o=i?J0(i.split(" ").map(function(a){return a.trim()})):SP();return o.prefix||(o.prefix=rs()),n.mask=o,n.maskId=r.getAttribute("data-fa-mask-id"),n}}},provides:function(t){t.generateAbstractMask=function(n){var r=n.children,i=n.attributes,o=n.main,a=n.mask,s=n.maskId,l=n.transform,u=o.width,f=o.icon,d=a.width,h=a.icon,v=kX({transform:l,containerWidth:d,iconWidth:u}),g={tag:"rect",attributes:Le(Le({},m_),{},{fill:"white"})},y=f.children?{children:f.children.map(Kk)}:{},x={tag:"g",attributes:Le({},v.inner),children:[Kk(Le({tag:f.tag,attributes:Le(Le({},f.attributes),v.path)},y))]},_={tag:"g",attributes:Le({},v.outer),children:[x]},b="mask-".concat(s||wh()),w="clip-".concat(s||wh()),S={tag:"mask",attributes:Le(Le({},m_),{},{id:b,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[g,_]},E={tag:"defs",children:[{tag:"clipPath",attributes:{id:w},children:NQ(h)},S]};return r.push(E,{tag:"rect",attributes:Le({fill:"currentColor","clip-path":"url(#".concat(w,")"),mask:"url(#".concat(b,")")},m_)}),{children:r,attributes:i}}}},RQ={provides:function(t){var n=!1;ns.matchMedia&&(n=ns.matchMedia("(prefers-reduced-motion: reduce)").matches),t.missingIconAbstract=function(){var r=[],i={fill:"currentColor"},o={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};r.push({tag:"path",attributes:Le(Le({},i),{},{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"})});var a=Le(Le({},o),{},{attributeName:"opacity"}),s={tag:"circle",attributes:Le(Le({},i),{},{cx:"256",cy:"364",r:"28"}),children:[]};return n||s.children.push({tag:"animate",attributes:Le(Le({},o),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:Le(Le({},a),{},{values:"1;0;1;1;0;1;"})}),r.push(s),r.push({tag:"path",attributes:Le(Le({},i),{},{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:n?[]:[{tag:"animate",attributes:Le(Le({},a),{},{values:"1;0;0;0;0;1;"})}]}),n||r.push({tag:"path",attributes:Le(Le({},i),{},{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:Le(Le({},a),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:r}}}},LQ={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-symbol"),o=i===null?!1:i===""?!0:i;return n.symbol=o,n}}}},$Q=[RX,xQ,wQ,OQ,SQ,jQ,AQ,kQ,MQ,RQ,LQ];YX($Q,{mixoutsTo:qr});qr.noAuto;qr.config;qr.library;qr.dom;var Dw=qr.parse;qr.findIconDefinition;qr.toHtml;var IQ=qr.icon;qr.layer;qr.text;qr.counter;var v5={exports:{}},DQ="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",FQ=DQ,BQ=FQ;function g5(){}function y5(){}y5.resetWarningCache=g5;var UQ=function(){function e(r,i,o,a,s,l){if(l!==BQ){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:y5,resetWarningCache:g5};return n.PropTypes=n,n};v5.exports=UQ();var zQ=v5.exports;const $=st(zQ);function Yk(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 ao(e){for(var t=1;t=0)&&(n[i]=e[i]);return n}function WQ(e,t){if(e==null)return{};var n=VQ(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Fw(e){return HQ(e)||GQ(e)||qQ(e)||KQ()}function HQ(e){if(Array.isArray(e))return Bw(e)}function GQ(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function qQ(e,t){if(e){if(typeof e=="string")return Bw(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 Bw(e,t)}}function Bw(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n2&&arguments[2]!==void 0?arguments[2]:{};if(typeof t=="string")return t;var r=(t.children||[]).map(function(l){return _5(e,l)}),i=Object.keys(t.attributes||{}).reduce(function(l,u){var f=t.attributes[u];switch(u){case"class":l.attrs.className=f,delete t.attributes.class;break;case"style":l.attrs.style=JQ(f);break;default:u.indexOf("aria-")===0||u.indexOf("data-")===0?l.attrs[u.toLowerCase()]=f:l.attrs[b5(u)]=f}return l},{attrs:{}}),o=n.style,a=o===void 0?{}:o,s=WQ(n,XQ);return i.attrs.style=ao(ao({},i.attrs.style),a),e.apply(void 0,[t.tag,ao(ao({},i.attrs),s)].concat(Fw(r)))}var x5=!1;try{x5=!0}catch{}function eJ(){if(!x5&&console&&typeof console.error=="function"){var e;(e=console).error.apply(e,arguments)}}function Zk(e){if(e&&Bg(e)==="object"&&e.prefix&&e.iconName&&e.icon)return e;if(Dw.icon)return Dw.icon(e);if(e===null)return null;if(e&&Bg(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 v_(e,t){return Array.isArray(t)&&t.length>0||!Array.isArray(t)&&t?Mu({},e,t):{}}var Xk={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},je=V.forwardRef(function(e,t){var n=ao(ao({},Xk),e),r=n.icon,i=n.mask,o=n.symbol,a=n.className,s=n.title,l=n.titleId,u=n.maskId,f=Zk(r),d=v_("classes",[].concat(Fw(YQ(n)),Fw((a||"").split(" ")))),h=v_("transform",typeof n.transform=="string"?Dw.transform(n.transform):n.transform),v=v_("mask",Zk(i)),g=IQ(f,ao(ao(ao(ao({},d),h),v),{},{symbol:o,title:s,titleId:l,maskId:u}));if(!g)return eJ("Could not find icon",f),null;var y=g.abstract,x={ref:t};return Object.keys(n).forEach(function(_){Xk.hasOwnProperty(_)||(x[_]=n[_])}),tJ(y[0],x)});je.displayName="FontAwesomeIcon";je.propTypes={beat:$.bool,border:$.bool,beatFade:$.bool,bounce:$.bool,className:$.string,fade:$.bool,flash:$.bool,mask:$.oneOfType([$.object,$.array,$.string]),maskId:$.string,fixedWidth:$.bool,inverse:$.bool,flip:$.oneOf([!0,!1,"horizontal","vertical","both"]),icon:$.oneOfType([$.object,$.array,$.string]),listItem:$.bool,pull:$.oneOf(["right","left"]),pulse:$.bool,rotation:$.oneOf([0,90,180,270]),shake:$.bool,size:$.oneOf(["2xs","xs","sm","lg","xl","2xl","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"]),spin:$.bool,spinPulse:$.bool,spinReverse:$.bool,symbol:$.oneOfType([$.bool,$.string]),title:$.string,titleId:$.string,transform:$.oneOfType([$.string,$.object]),swapOpacity:$.bool};var tJ=_5.bind(null,V.createElement);function w5(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;t0?"".concat(e,"px"):null}function iJ(){return document.body.clientWidth0&&arguments[0]!==void 0?arguments[0]:"",t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:sJ;return t?e.split(" ").map(function(n){return t[n]||n}).join(" "):e}function ms(e,t){var n={};return Object.keys(e).forEach(function(r){t.indexOf(r)===-1&&(n[r]=e[r])}),n}function E5(e,t){for(var n=Array.isArray(t)?t:[t],r=n.length,i,o={};r>0;)r-=1,i=n[r],o[i]=e[i];return o}var Qk={};function Uw(e){Qk[e]||(typeof console<"u"&&console.error(e),Qk[e]=!0)}function P5(e,t){return function(r,i,o){r[i]!==null&&typeof r[i]<"u"&&Uw('"'.concat(i,'" property of "').concat(o,`" has been deprecated. `).concat(t));for(var a=arguments.length,s=new Array(a>3?a-3:0),l=3;l"u"?"undefined":sc(window))==="object"&&window.Element||function(){};function TP(e,t,n){if(!(e[t]instanceof lJ))return new Error("Invalid prop `"+t+"` supplied to `"+n+"`. Expected prop to be an instance of Element. Validation failed.")}var lc=$.oneOfType([$.string,$.func,TP,$.shape({current:$.any})]),at=$.oneOfType([$.func,$.string,$.shape({$$typeof:$.symbol,render:$.func}),$.arrayOf($.oneOfType([$.func,$.string,$.shape({$$typeof:$.symbol,render:$.func})]))]),Ug={Fade:150,Collapse:350,Modal:300,Carousel:600,Offcanvas:300},zg=["in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","onEnter","onEntering","onEntered","onExit","onExiting","onExited"],tv={ENTERING:"entering",ENTERED:"entered",EXITING:"exiting",EXITED:"exited"},mt={esc:27,space:32,enter:13,tab:9,up:38,down:40,home:36,end:35,n:78,p:80},uJ=["auto-start","auto","auto-end","top-start","top","top-end","right-start","right","right-end","bottom-end","bottom","bottom-start","left-end","left","left-start"],jP=!!(typeof window<"u"&&window.document&&window.document.createElement);function cJ(e){return e&&sc(e)==="object"?"current"in e:!1}function C5(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}function zw(e){var t=sc(e);return e!=null&&(t==="object"||t==="function")}function Jk(e){var t=sc(e),n=NaN;if(t==="number")return e;if(t==="symbol"||t==="object"&&C5(e)==="[object Symbol]")return n;if(zw(e)){var r=typeof e.valueOf=="function"?e.valueOf():e;e=zw(r)?"".concat(r):r}if(t!=="string")return e===0?e:+e;e=e.replace(/^\s+|\s+$/g,"");var i=/^0b[01]+$/i.test(e);return i||/^0o[0-7]+$/i.test(e)?parseInt(e.slice(2),i?2:8):/^[-+]0x[0-9a-f]+$/i.test(e)?n:+e}function fJ(e){if(!zw(e))return!1;var t=C5(e);return t==="[object Function]"||t==="[object AsyncFunction]"||t==="[object GeneratorFunction]"||t==="[object Proxy]"}function dJ(e){if(cJ(e))return e.current;if(fJ(e))return e();if(typeof e=="string"&&jP){var t=document.querySelectorAll(e);if(t.length||(t=document.querySelectorAll("#".concat(e))),!t.length)throw new Error("The target '".concat(e,"' could not be identified in the dom, tip: check spelling"));return t}return e}function e3(e){return e===null?!1:Array.isArray(e)||jP&&typeof e.length=="number"}function Oh(e,t){var n=dJ(e);return t?e3(n)?n:n===null?[]:[n]:e3(n)?n[0]:n}var hJ=["a[href]","area[href]","input:not([disabled]):not([type=hidden])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","object","embed","[tabindex]:not(.modal):not(.offcanvas)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],pJ=["className","cssModule","noGutters","tag","widths"];function Vw(){return Vw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function vJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var gJ=["xs","sm","md","lg","xl","xxl"],eu=$.oneOfType([$.number,$.string]),yJ={tag:at,noGutters:P5($.bool,"Please use Bootstrap 5 gutter utility classes. https://getbootstrap.com/docs/5.0/layout/gutters/"),className:$.string,cssModule:$.object,xs:eu,sm:eu,md:eu,lg:eu,xl:eu,xxl:eu,widths:$.array};function rr(e){var t=e.className,n=e.cssModule,r=e.noGutters,i=e.tag,o=i===void 0?"div":i,a=e.widths,s=a===void 0?gJ:a,l=mJ(e,pJ),u=[];s.forEach(function(d,h){var v=e[d];if(delete l[d],!!v){var g=!h;u.push(g?"row-cols-".concat(v):"row-cols-".concat(d,"-").concat(v))}});var f=Ue(Ge(t,r?"gx-0":null,"row",u),n);return V.createElement(o,Vw({},l,{className:f}))}rr.propTypes=yJ;var bJ=["expand","className","cssModule","light","dark","fixed","sticky","color","container","tag","children"];function Ww(){return Ww=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function xJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var wJ={children:$.node,className:$.string,color:$.string,container:$.oneOfType([$.bool,$.string]),cssModule:$.object,dark:$.bool,expand:$.oneOfType([$.bool,$.string]),fixed:$.string,light:$.bool,role:$.string,sticky:$.string,tag:at},OJ=function(t){return t===!1?!1:t===!0||t==="xs"?"navbar-expand":"navbar-expand-".concat(t)};function T5(e){var t,n=e.expand,r=n===void 0?!1:n,i=e.className,o=e.cssModule,a=e.light,s=e.dark,l=e.fixed,u=e.sticky,f=e.color,d=e.container,h=d===void 0?"fluid":d,v=e.tag,g=v===void 0?"nav":v,y=e.children,x=_J(e,bJ),_=Ue(Ge(i,"navbar",OJ(r),(t={"navbar-light":a,"navbar-dark":s},g_(t,"bg-".concat(f),f),g_(t,"fixed-".concat(l),l),g_(t,"sticky-".concat(u),u),t)),o),b=h&&h===!0?"container":"container-".concat(h);return V.createElement(g,Ww({},x,{className:_}),h?V.createElement("div",{className:b},y):y)}T5.propTypes=wJ;var SJ=["className","cssModule","tag"];function Hw(){return Hw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function PJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var CJ={className:$.string,cssModule:$.object,tag:at};function j5(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"a":r,o=EJ(e,SJ),a=Ue(Ge(t,"navbar-brand"),n);return V.createElement(i,Hw({},o,{className:a}))}j5.propTypes=CJ;var TJ=["className","cssModule","children","tag"];function Gw(){return Gw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function NJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var MJ={className:$.string,cssModule:$.object,tag:at,type:$.string,children:$.node};function A5(e){var t=e.className,n=e.cssModule,r=e.children,i=e.tag,o=i===void 0?"button":i,a=kJ(e,TJ),s=Ue(Ge(t,"navbar-toggler"),n);return V.createElement(o,Gw({"aria-label":"Toggle navigation"},jJ({type:"button"},a),{className:s}),r||V.createElement("span",{className:Ue("navbar-toggler-icon",n)}))}A5.propTypes=MJ;var RJ=["className","cssModule","tabs","pills","vertical","horizontal","justified","fill","navbar","card","tag"];function qw(){return qw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function $J(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var IJ={card:$.bool,className:$.string,cssModule:$.object,fill:$.bool,horizontal:$.oneOf(["center","end"]),justified:$.bool,navbar:$.bool,pills:$.bool,tabs:$.bool,tag:at,vertical:$.oneOfType([$.bool,$.string])},DJ=function(t){return t===!1?!1:t===!0||t==="xs"?"flex-column":"flex-".concat(t,"-column")};function AP(e){var t=e.className,n=e.cssModule,r=e.tabs,i=e.pills,o=e.vertical,a=o===void 0?!1:o,s=e.horizontal,l=e.justified,u=e.fill,f=e.navbar,d=e.card,h=e.tag,v=h===void 0?"ul":h,g=LJ(e,RJ),y=Ue(Ge(t,f?"navbar-nav":"nav",s?"justify-content-".concat(s):!1,DJ(a),{"nav-tabs":r,"card-header-tabs":d&&r,"nav-pills":i,"card-header-pills":d&&i,"nav-justified":l,"nav-fill":u}),n);return V.createElement(v,qw({},g,{className:y}))}AP.propTypes=IJ;var FJ=["className","cssModule","active","tag"];function Kw(){return Kw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function UJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var zJ={active:$.bool,className:$.string,cssModule:$.object,tag:at};function kP(e){var t=e.className,n=e.cssModule,r=e.active,i=e.tag,o=i===void 0?"li":i,a=BJ(e,FJ),s=Ue(Ge(t,"nav-item",r?"active":!1),n);return V.createElement(o,Kw({},a,{className:s}))}kP.propTypes=zJ;function Yw(e){"@babel/helpers - typeof";return Yw=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},Yw(e)}var VJ=["className","cssModule","active","tag","innerRef"];function Zw(){return Zw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function HJ(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function GJ(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n3(e,t){for(var n=0;n"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 Vg(e){return Vg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Vg(e)}var QJ={active:$.bool,className:$.string,cssModule:$.object,disabled:$.bool,href:$.any,innerRef:$.oneOfType([$.object,$.func,$.string]),onClick:$.func,tag:at},N5=function(e){KJ(n,e);var t=YJ(n);function n(r){var i;return GJ(this,n),i=t.call(this,r),i.onClick=i.onClick.bind(k5(i)),i}return qJ(n,[{key:"onClick",value:function(i){if(this.props.disabled){i.preventDefault();return}this.props.href==="#"&&i.preventDefault(),this.props.onClick&&this.props.onClick(i)}},{key:"render",value:function(){var i=this.props,o=i.className,a=i.cssModule,s=i.active,l=i.tag,u=l===void 0?"a":l,f=i.innerRef,d=WJ(i,VJ),h=Ue(Ge(o,"nav-link",{disabled:d.disabled,active:s}),a);return V.createElement(u,Zw({},d,{ref:f,onClick:this.onClick,className:h}))}}]),n}(V.Component);N5.propTypes=QJ;const M5=N5;var JJ=["className","cssModule","variant","innerRef"];function Qw(){return Qw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function ree(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var iee={active:$.bool,"aria-label":$.string,onClick:$.func,variant:$.oneOf(["white"]),className:$.string,cssModule:$.object,innerRef:$.oneOfType([$.object,$.string,$.func])};function R5(e){var t=e.className;e.cssModule;var n=e.variant,r=e.innerRef,i=nee(e,JJ),o=Ue(Ge(t,"btn-close",n&&"btn-close-".concat(n)));return V.createElement("button",Qw({ref:r,type:"button",className:o},eee({"aria-label":"close"},i)))}R5.propTypes=iee;var oee=["active","aria-label","block","className","close","cssModule","color","outline","size","tag","innerRef"];function Jw(){return Jw=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function see(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var lee={active:$.bool,"aria-label":$.string,block:$.bool,children:$.node,className:$.string,cssModule:$.object,close:$.bool,color:$.string,disabled:$.bool,innerRef:$.oneOfType([$.object,$.func,$.string]),onClick:$.func,outline:$.bool,size:$.string,tag:at};function Ye(e){var t=R.useCallback(function(b){if(e.disabled){b.preventDefault();return}if(e.onClick)return e.onClick(b)},[e.onClick,e.disabled]),n=e.active,r=e["aria-label"],i=e.block,o=e.className,a=e.close,s=e.cssModule,l=e.color,u=l===void 0?"secondary":l,f=e.outline,d=e.size,h=e.tag,v=h===void 0?"button":h,g=e.innerRef,y=aee(e,oee);if(a)return V.createElement(R5,y);var x="btn".concat(f?"-outline":"","-").concat(u),_=Ue(Ge(o,"btn",x,d?"btn-".concat(d):!1,i?"d-block w-100":!1,{active:n,disabled:e.disabled}),s);return y.href&&v==="button"&&(v="a"),V.createElement(v,Jw({type:v==="button"&&y.onClick?"button":void 0},y,{className:_,ref:g,onClick:t,"aria-label":r}))}Ye.propTypes=lee;var L5=R.createContext(),$5=R.createContext();function i3(e){var t=e.children,n=R.useState(null),r=n[0],i=n[1],o=R.useRef(!1);R.useEffect(function(){return function(){o.current=!0}},[]);var a=R.useCallback(function(s){o.current||i(s)},[]);return R.createElement(L5.Provider,{value:r},R.createElement($5.Provider,{value:a},t))}var I5=function(t){return Array.isArray(t)?t[0]:t},D5=function(t){if(typeof t=="function"){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i"u")return!1;var t=zr(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function xee(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},i=t.attributes[n]||{},o=t.elements[n];!hi(o)||!xo(o)||(Object.assign(o.style,r),Object.keys(i).forEach(function(a){var s=i[a];s===!1?o.removeAttribute(a):o.setAttribute(a,s===!0?"":s)}))})}function wee(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var i=t.elements[r],o=t.attributes[r]||{},a=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),s=a.reduce(function(l,u){return l[u]="",l},{});!hi(i)||!xo(i)||(Object.assign(i.style,s),Object.keys(o).forEach(function(l){i.removeAttribute(l)}))})}}const Oee={name:"applyStyles",enabled:!0,phase:"write",fn:xee,effect:wee,requires:["computeStyles"]};function vo(e){return e.split("-")[0]}var ul=Math.max,Wg=Math.min,cc=Math.round;function t2(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function U5(){return!/^((?!chrome|android).)*safari/i.test(t2())}function fc(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),i=1,o=1;t&&hi(e)&&(i=e.offsetWidth>0&&cc(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&cc(r.height)/e.offsetHeight||1);var a=Sl(e)?zr(e):window,s=a.visualViewport,l=!U5()&&n,u=(r.left+(l&&s?s.offsetLeft:0))/i,f=(r.top+(l&&s?s.offsetTop:0))/o,d=r.width/i,h=r.height/o;return{width:d,height:h,top:f,right:u+d,bottom:f+h,left:u,x:u,y:f}}function RP(e){var t=fc(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function z5(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&MP(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function ea(e){return zr(e).getComputedStyle(e)}function See(e){return["table","td","th"].indexOf(xo(e))>=0}function vs(e){return((Sl(e)?e.ownerDocument:e.document)||window.document).documentElement}function tb(e){return xo(e)==="html"?e:e.assignedSlot||e.parentNode||(MP(e)?e.host:null)||vs(e)}function l3(e){return!hi(e)||ea(e).position==="fixed"?null:e.offsetParent}function Eee(e){var t=/firefox/i.test(t2()),n=/Trident/i.test(t2());if(n&&hi(e)){var r=ea(e);if(r.position==="fixed")return null}var i=tb(e);for(MP(i)&&(i=i.host);hi(i)&&["html","body"].indexOf(xo(i))<0;){var o=ea(i);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return i;i=i.parentNode}return null}function Mp(e){for(var t=zr(e),n=l3(e);n&&See(n)&&ea(n).position==="static";)n=l3(n);return n&&(xo(n)==="html"||xo(n)==="body"&&ea(n).position==="static")?t:n||Eee(e)||t}function LP(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Md(e,t,n){return ul(e,Wg(t,n))}function Pee(e,t,n){var r=Md(e,t,n);return r>n?n:r}function V5(){return{top:0,right:0,bottom:0,left:0}}function W5(e){return Object.assign({},V5(),e)}function H5(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Cee=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,W5(typeof t!="number"?t:H5(t,Np))};function Tee(e){var t,n=e.state,r=e.name,i=e.options,o=n.elements.arrow,a=n.modifiersData.popperOffsets,s=vo(n.placement),l=LP(s),u=[Or,yi].indexOf(s)>=0,f=u?"height":"width";if(!(!o||!a)){var d=Cee(i.padding,n),h=RP(o),v=l==="y"?wr:Or,g=l==="y"?gi:yi,y=n.rects.reference[f]+n.rects.reference[l]-a[l]-n.rects.popper[f],x=a[l]-n.rects.reference[l],_=Mp(o),b=_?l==="y"?_.clientHeight||0:_.clientWidth||0:0,w=y/2-x/2,S=d[v],E=b-h[f]-d[g],P=b/2-h[f]/2+w,T=Md(S,P,E),A=l;n.modifiersData[r]=(t={},t[A]=T,t.centerOffset=T-P,t)}}function jee(e){var t=e.state,n=e.options,r=n.element,i=r===void 0?"[data-popper-arrow]":r;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||z5(t.elements.popper,i)&&(t.elements.arrow=i))}const Aee={name:"arrow",enabled:!0,phase:"main",fn:Tee,effect:jee,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function dc(e){return e.split("-")[1]}var kee={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Nee(e,t){var n=e.x,r=e.y,i=t.devicePixelRatio||1;return{x:cc(n*i)/i||0,y:cc(r*i)/i||0}}function u3(e){var t,n=e.popper,r=e.popperRect,i=e.placement,o=e.variation,a=e.offsets,s=e.position,l=e.gpuAcceleration,u=e.adaptive,f=e.roundOffsets,d=e.isFixed,h=a.x,v=h===void 0?0:h,g=a.y,y=g===void 0?0:g,x=typeof f=="function"?f({x:v,y}):{x:v,y};v=x.x,y=x.y;var _=a.hasOwnProperty("x"),b=a.hasOwnProperty("y"),w=Or,S=wr,E=window;if(u){var P=Mp(n),T="clientHeight",A="clientWidth";if(P===zr(n)&&(P=vs(n),ea(P).position!=="static"&&s==="absolute"&&(T="scrollHeight",A="scrollWidth")),P=P,i===wr||(i===Or||i===yi)&&o===Sh){S=gi;var D=d&&P===E&&E.visualViewport?E.visualViewport.height:P[T];y-=D-r.height,y*=l?1:-1}if(i===Or||(i===wr||i===gi)&&o===Sh){w=yi;var k=d&&P===E&&E.visualViewport?E.visualViewport.width:P[A];v-=k-r.width,v*=l?1:-1}}var I=Object.assign({position:s},u&&kee),F=f===!0?Nee({x:v,y},zr(n)):{x:v,y};if(v=F.x,y=F.y,l){var q;return Object.assign({},I,(q={},q[S]=b?"0":"",q[w]=_?"0":"",q.transform=(E.devicePixelRatio||1)<=1?"translate("+v+"px, "+y+"px)":"translate3d("+v+"px, "+y+"px, 0)",q))}return Object.assign({},I,(t={},t[S]=b?y+"px":"",t[w]=_?v+"px":"",t.transform="",t))}function Mee(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=r===void 0?!0:r,o=n.adaptive,a=o===void 0?!0:o,s=n.roundOffsets,l=s===void 0?!0:s,u={placement:vo(t.placement),variation:dc(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,u3(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,u3(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Ree={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Mee,data:{}};var nv={passive:!0};function Lee(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,o=i===void 0?!0:i,a=r.resize,s=a===void 0?!0:a,l=zr(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&u.forEach(function(f){f.addEventListener("scroll",n.update,nv)}),s&&l.addEventListener("resize",n.update,nv),function(){o&&u.forEach(function(f){f.removeEventListener("scroll",n.update,nv)}),s&&l.removeEventListener("resize",n.update,nv)}}const $ee={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Lee,data:{}};var Iee={left:"right",right:"left",bottom:"top",top:"bottom"};function Kv(e){return e.replace(/left|right|bottom|top/g,function(t){return Iee[t]})}var Dee={start:"end",end:"start"};function c3(e){return e.replace(/start|end/g,function(t){return Dee[t]})}function $P(e){var t=zr(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function IP(e){return fc(vs(e)).left+$P(e).scrollLeft}function Fee(e,t){var n=zr(e),r=vs(e),i=n.visualViewport,o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;var u=U5();(u||!u&&t==="fixed")&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s+IP(e),y:l}}function Bee(e){var t,n=vs(e),r=$P(e),i=(t=e.ownerDocument)==null?void 0:t.body,o=ul(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=ul(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-r.scrollLeft+IP(e),l=-r.scrollTop;return ea(i||n).direction==="rtl"&&(s+=ul(n.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:s,y:l}}function DP(e){var t=ea(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function G5(e){return["html","body","#document"].indexOf(xo(e))>=0?e.ownerDocument.body:hi(e)&&DP(e)?e:G5(tb(e))}function Rd(e,t){var n;t===void 0&&(t=[]);var r=G5(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=zr(r),a=i?[o].concat(o.visualViewport||[],DP(r)?r:[]):r,s=t.concat(a);return i?s:s.concat(Rd(tb(a)))}function n2(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Uee(e,t){var n=fc(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function f3(e,t,n){return t===F5?n2(Fee(e,n)):Sl(t)?Uee(t,n):n2(Bee(vs(e)))}function zee(e){var t=Rd(tb(e)),n=["absolute","fixed"].indexOf(ea(e).position)>=0,r=n&&hi(e)?Mp(e):e;return Sl(r)?t.filter(function(i){return Sl(i)&&z5(i,r)&&xo(i)!=="body"}):[]}function Vee(e,t,n,r){var i=t==="clippingParents"?zee(e):[].concat(t),o=[].concat(i,[n]),a=o[0],s=o.reduce(function(l,u){var f=f3(e,u,r);return l.top=ul(f.top,l.top),l.right=Wg(f.right,l.right),l.bottom=Wg(f.bottom,l.bottom),l.left=ul(f.left,l.left),l},f3(e,a,r));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function q5(e){var t=e.reference,n=e.element,r=e.placement,i=r?vo(r):null,o=r?dc(r):null,a=t.x+t.width/2-n.width/2,s=t.y+t.height/2-n.height/2,l;switch(i){case wr:l={x:a,y:t.y-n.height};break;case gi:l={x:a,y:t.y+t.height};break;case yi:l={x:t.x+t.width,y:s};break;case Or:l={x:t.x-n.width,y:s};break;default:l={x:t.x,y:t.y}}var u=i?LP(i):null;if(u!=null){var f=u==="y"?"height":"width";switch(o){case uc:l[u]=l[u]-(t[f]/2-n[f]/2);break;case Sh:l[u]=l[u]+(t[f]/2-n[f]/2);break}}return l}function Eh(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=r===void 0?e.placement:r,o=n.strategy,a=o===void 0?e.strategy:o,s=n.boundary,l=s===void 0?uee:s,u=n.rootBoundary,f=u===void 0?F5:u,d=n.elementContext,h=d===void 0?Hf:d,v=n.altBoundary,g=v===void 0?!1:v,y=n.padding,x=y===void 0?0:y,_=W5(typeof x!="number"?x:H5(x,Np)),b=h===Hf?cee:Hf,w=e.rects.popper,S=e.elements[g?b:h],E=Vee(Sl(S)?S:S.contextElement||vs(e.elements.popper),l,f,a),P=fc(e.elements.reference),T=q5({reference:P,element:w,strategy:"absolute",placement:i}),A=n2(Object.assign({},w,T)),D=h===Hf?A:P,k={top:E.top-D.top+_.top,bottom:D.bottom-E.bottom+_.bottom,left:E.left-D.left+_.left,right:D.right-E.right+_.right},I=e.modifiersData.offset;if(h===Hf&&I){var F=I[i];Object.keys(k).forEach(function(q){var W=[yi,gi].indexOf(q)>=0?1:-1,X=[wr,gi].indexOf(q)>=0?"y":"x";k[q]+=F[X]*W})}return k}function Wee(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=n.boundary,o=n.rootBoundary,a=n.padding,s=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?B5:l,f=dc(r),d=f?s?s3:s3.filter(function(g){return dc(g)===f}):Np,h=d.filter(function(g){return u.indexOf(g)>=0});h.length===0&&(h=d);var v=h.reduce(function(g,y){return g[y]=Eh(e,{placement:y,boundary:i,rootBoundary:o,padding:a})[vo(y)],g},{});return Object.keys(v).sort(function(g,y){return v[g]-v[y]})}function Hee(e){if(vo(e)===NP)return[];var t=Kv(e);return[c3(e),t,c3(t)]}function Gee(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,o=i===void 0?!0:i,a=n.altAxis,s=a===void 0?!0:a,l=n.fallbackPlacements,u=n.padding,f=n.boundary,d=n.rootBoundary,h=n.altBoundary,v=n.flipVariations,g=v===void 0?!0:v,y=n.allowedAutoPlacements,x=t.options.placement,_=vo(x),b=_===x,w=l||(b||!g?[Kv(x)]:Hee(x)),S=[x].concat(w).reduce(function(te,ie){return te.concat(vo(ie)===NP?Wee(t,{placement:ie,boundary:f,rootBoundary:d,padding:u,flipVariations:g,allowedAutoPlacements:y}):ie)},[]),E=t.rects.reference,P=t.rects.popper,T=new Map,A=!0,D=S[0],k=0;k=0,X=W?"width":"height",Q=Eh(t,{placement:I,boundary:f,rootBoundary:d,altBoundary:h,padding:u}),ne=W?q?yi:Or:q?gi:wr;E[X]>P[X]&&(ne=Kv(ne));var Z=Kv(ne),z=[];if(o&&z.push(Q[F]<=0),s&&z.push(Q[ne]<=0,Q[Z]<=0),z.every(function(te){return te})){D=I,A=!1;break}T.set(I,z)}if(A)for(var B=g?3:1,H=function(ie){var ae=S.find(function(fe){var j=T.get(fe);if(j)return j.slice(0,ie).every(function(N){return N})});if(ae)return D=ae,"break"},ee=B;ee>0;ee--){var K=H(ee);if(K==="break")break}t.placement!==D&&(t.modifiersData[r]._skip=!0,t.placement=D,t.reset=!0)}}const qee={name:"flip",enabled:!0,phase:"main",fn:Gee,requiresIfExists:["offset"],data:{_skip:!1}};function d3(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function h3(e){return[wr,yi,gi,Or].some(function(t){return e[t]>=0})}function Kee(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Eh(t,{elementContext:"reference"}),s=Eh(t,{altBoundary:!0}),l=d3(a,r),u=d3(s,i,o),f=h3(l),d=h3(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:f,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":f,"data-popper-escaped":d})}const Yee={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Kee};function Zee(e,t,n){var r=vo(e),i=[Or,wr].indexOf(r)>=0?-1:1,o=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,a=o[0],s=o[1];return a=a||0,s=(s||0)*i,[Or,yi].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function Xee(e){var t=e.state,n=e.options,r=e.name,i=n.offset,o=i===void 0?[0,0]:i,a=B5.reduce(function(f,d){return f[d]=Zee(d,t.rects,o),f},{}),s=a[t.placement],l=s.x,u=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=a}const Qee={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Xee};function Jee(e){var t=e.state,n=e.name;t.modifiersData[n]=q5({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const ete={name:"popperOffsets",enabled:!0,phase:"read",fn:Jee,data:{}};function tte(e){return e==="x"?"y":"x"}function nte(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,o=i===void 0?!0:i,a=n.altAxis,s=a===void 0?!1:a,l=n.boundary,u=n.rootBoundary,f=n.altBoundary,d=n.padding,h=n.tether,v=h===void 0?!0:h,g=n.tetherOffset,y=g===void 0?0:g,x=Eh(t,{boundary:l,rootBoundary:u,padding:d,altBoundary:f}),_=vo(t.placement),b=dc(t.placement),w=!b,S=LP(_),E=tte(S),P=t.modifiersData.popperOffsets,T=t.rects.reference,A=t.rects.popper,D=typeof y=="function"?y(Object.assign({},t.rects,{placement:t.placement})):y,k=typeof D=="number"?{mainAxis:D,altAxis:D}:Object.assign({mainAxis:0,altAxis:0},D),I=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,F={x:0,y:0};if(P){if(o){var q,W=S==="y"?wr:Or,X=S==="y"?gi:yi,Q=S==="y"?"height":"width",ne=P[S],Z=ne+x[W],z=ne-x[X],B=v?-A[Q]/2:0,H=b===uc?T[Q]:A[Q],ee=b===uc?-A[Q]:-T[Q],K=t.elements.arrow,te=v&&K?RP(K):{width:0,height:0},ie=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:V5(),ae=ie[W],fe=ie[X],j=Md(0,T[Q],te[Q]),N=w?T[Q]/2-B-j-ae-k.mainAxis:H-j-ae-k.mainAxis,U=w?-T[Q]/2+B+j+fe+k.mainAxis:ee+j+fe+k.mainAxis,J=t.elements.arrow&&Mp(t.elements.arrow),Y=J?S==="y"?J.clientTop||0:J.clientLeft||0:0,oe=(q=I==null?void 0:I[S])!=null?q:0,he=ne+N-oe-Y,Se=ne+U-oe,se=Md(v?Wg(Z,he):Z,ne,v?ul(z,Se):z);P[S]=se,F[S]=se-ne}if(s){var pe,me=S==="x"?wr:Or,xe=S==="x"?gi:yi,Te=P[E],Ce=E==="y"?"height":"width",Ae=Te+x[me],le=Te-x[xe],ce=[wr,Or].indexOf(_)!==-1,ye=(pe=I==null?void 0:I[E])!=null?pe:0,ge=ce?Ae:Te-T[Ce]-A[Ce]-ye+k.altAxis,we=ce?Te+T[Ce]+A[Ce]-ye-k.altAxis:le,ke=v&&ce?Pee(ge,Te,we):Md(v?ge:Ae,Te,v?we:le);P[E]=ke,F[E]=ke-Te}t.modifiersData[r]=F}}const rte={name:"preventOverflow",enabled:!0,phase:"main",fn:nte,requiresIfExists:["offset"]};function ite(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function ote(e){return e===zr(e)||!hi(e)?$P(e):ite(e)}function ate(e){var t=e.getBoundingClientRect(),n=cc(t.width)/e.offsetWidth||1,r=cc(t.height)/e.offsetHeight||1;return n!==1||r!==1}function ste(e,t,n){n===void 0&&(n=!1);var r=hi(t),i=hi(t)&&ate(t),o=vs(t),a=fc(e,i,n),s={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((xo(t)!=="body"||DP(o))&&(s=ote(t)),hi(t)?(l=fc(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=IP(o))),{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function lte(e){var t=new Map,n=new Set,r=[];e.forEach(function(o){t.set(o.name,o)});function i(o){n.add(o.name);var a=[].concat(o.requires||[],o.requiresIfExists||[]);a.forEach(function(s){if(!n.has(s)){var l=t.get(s);l&&i(l)}}),r.push(o)}return e.forEach(function(o){n.has(o.name)||i(o)}),r}function ute(e){var t=lte(e);return _ee.reduce(function(n,r){return n.concat(t.filter(function(i){return i.phase===r}))},[])}function cte(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function fte(e){var t=e.reduce(function(n,r){var i=n[r.name];return n[r.name]=i?Object.assign({},i,r,{options:Object.assign({},i.options,r.options),data:Object.assign({},i.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var p3={placement:"bottom",modifiers:[],strategy:"absolute"};function m3(){for(var e=arguments.length,t=new Array(e),n=0;n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Nte(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function Mte(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function v3(e,t){for(var n=0;n"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 Hg(e){return Hg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Hg(e)}var Fte={a11y:$.bool,disabled:$.bool,direction:$.oneOf(["up","down","start","end","left","right"]),group:$.bool,isOpen:$.bool,nav:$.bool,active:$.bool,size:$.string,tag:at,toggle:$.func,children:$.node,className:$.string,cssModule:$.object,dropup:$.bool,inNavbar:$.bool,setActiveFromChild:$.bool,menuRole:$.oneOf(["listbox","menu"])},Bte={a11y:!0,isOpen:!1,direction:"down",nav:!1,active:!1,inNavbar:!1,setActiveFromChild:!1},Ute=[mt.space,mt.enter,mt.up,mt.down,mt.end,mt.home],nb=function(e){Lte(n,e);var t=$te(n);function n(r){var i;return Mte(this,n),i=t.call(this,r),i.addEvents=i.addEvents.bind(xa(i)),i.handleDocumentClick=i.handleDocumentClick.bind(xa(i)),i.handleKeyDown=i.handleKeyDown.bind(xa(i)),i.removeEvents=i.removeEvents.bind(xa(i)),i.toggle=i.toggle.bind(xa(i)),i.handleMenuRef=i.handleMenuRef.bind(xa(i)),i.handleToggleRef=i.handleToggleRef.bind(xa(i)),i.containerRef=V.createRef(),i.menuRef=V.createRef(),i.toggleRef=V.createRef(),i}return Rte(n,[{key:"componentDidMount",value:function(){this.handleProps()}},{key:"componentDidUpdate",value:function(i){this.props.isOpen!==i.isOpen&&this.handleProps()}},{key:"componentWillUnmount",value:function(){this.removeEvents()}},{key:"handleMenuRef",value:function(i){this.menuRef.current=i}},{key:"handleToggleRef",value:function(i){this.toggleRef.current=i}},{key:"handleDocumentClick",value:function(i){if(!(i&&(i.which===3||i.type==="keyup"&&i.which!==mt.tab))){var o=this.getContainer(),a=this.getMenu(),s=this.getToggle();if(s){var l=s.contains(i.target),u=a&&a.contains(i.target)&&a!==i.target,f=!1;o&&(f=o.classList.contains("input-group")&&o.classList.contains("dropdown")&&i.target.tagName==="INPUT"),!((l&&!f||u)&&(i.type!=="keyup"||i.which===mt.tab))&&this.toggle(i)}}}},{key:"handleKeyDown",value:function(i){var o=this,a=i.target.getAttribute("role")==="menuitem"||i.target.getAttribute("role")==="option",s=this.getMenuCtrl()===i.target,l=mt.tab===i.which;if(!(/input|textarea/i.test(i.target.tagName)||l&&!this.props.a11y||l&&!(a||s))&&((Ute.indexOf(i.which)!==-1||i.which>=48&&i.which<=90)&&i.preventDefault(),!this.props.disabled)){if(s)if([mt.space,mt.enter,mt.up,mt.down].indexOf(i.which)>-1)this.props.isOpen||this.toggle(i),setTimeout(function(){var b;return(b=o.getMenuItems()[0])===null||b===void 0?void 0:b.focus()});else if(this.props.isOpen&&l){var u;i.preventDefault(),(u=this.getMenuItems()[0])===null||u===void 0||u.focus()}else this.props.isOpen&&i.which===mt.esc&&this.toggle(i);if(this.props.isOpen&&a){if([mt.tab,mt.esc].indexOf(i.which)>-1)this.toggle(i),this.getMenuCtrl().focus();else if([mt.space,mt.enter].indexOf(i.which)>-1)i.target.click(),this.getMenuCtrl().focus();else if([mt.down,mt.up].indexOf(i.which)>-1||[mt.n,mt.p].indexOf(i.which)>-1&&i.ctrlKey){var f=this.getMenuItems(),d=f.indexOf(i.target);mt.up===i.which||mt.p===i.which&&i.ctrlKey?d=d!==0?d-1:f.length-1:(mt.down===i.which||mt.n===i.which&&i.ctrlKey)&&(d=d===f.length-1?0:d+1),f[d].focus()}else if(mt.end===i.which){var h=this.getMenuItems();h[h.length-1].focus()}else if(mt.home===i.which){var v=this.getMenuItems();v[0].focus()}else if(i.which>=48&&i.which<=90)for(var g=this.getMenuItems(),y=String.fromCharCode(i.which).toLowerCase(),x=0;x=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Wte(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function Hte(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g3(e,t){for(var n=0;n"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 Gg(e){return Gg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Gg(e)}var Xte={children:$.node,active:$.bool,disabled:$.bool,divider:$.bool,tag:at,header:$.bool,onClick:$.func,className:$.string,cssModule:$.object,toggle:$.bool,text:$.bool},FP=function(e){qte(n,e);var t=Kte(n);function n(r){var i;return Hte(this,n),i=t.call(this,r),i.onClick=i.onClick.bind(u2(i)),i.getTabIndex=i.getTabIndex.bind(u2(i)),i}return Gte(n,[{key:"onClick",value:function(i){var o,a=this.props,s=a.disabled,l=a.header,u=a.divider,f=a.text;if(s||l||u||f){i.preventDefault();return}this.props.onClick&&this.props.onClick(i),(!((o=this.props.toggle)!==null&&o!==void 0)||o)&&this.context.toggle(i)}},{key:"getRole",value:function(){return this.context.menuRole==="listbox"?"option":"menuitem"}},{key:"getTabIndex",value:function(){var i=this.props,o=i.disabled,a=i.header,s=i.divider,l=i.text;return o||a||s||l?"-1":"0"}},{key:"render",value:function(){var i=this.getTabIndex(),o=i>-1?this.getRole():void 0,a=ms(this.props,["toggle"]),s=a.className,l=a.cssModule,u=a.divider,f=a.tag,d=f===void 0?"button":f,h=a.header,v=a.active,g=a.text,y=Vte(a,zte),x=Ue(Ge(s,{disabled:y.disabled,"dropdown-item":!u&&!h&&!g,active:v,"dropdown-header":h,"dropdown-divider":u,"dropdown-item-text":g}),l);return d==="button"&&(h?d="h6":u?d="div":y.href?d="a":g&&(d="span")),V.createElement(d,s2({type:d==="button"&&(y.onClick||this.props.toggle)?"button":void 0},y,{tabIndex:i,role:o,className:x,onClick:this.onClick}))}}]),n}(V.Component);FP.propTypes=Xte;FP.contextType=Ph;const Ne=FP;function c2(e){"@babel/helpers - typeof";return c2=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},c2(e)}var Qte=["className","cssModule","dark","end","right","tag","flip","modifiers","persist","strategy","container","updateOnSelect"];function qg(){return qg=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function ane(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function sne(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function b3(e,t){for(var n=0;n"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 Kg(e){return Kg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Kg(e)}var pne={tag:at,children:$.node.isRequired,dark:$.bool,end:$.bool,flip:$.bool,modifiers:$.array,className:$.string,cssModule:$.object,style:$.object,persist:$.bool,strategy:$.string,container:lc,updateOnSelect:$.bool,right:P5($.bool,'Please use "end" instead.')},mne={up:"top",left:"left",right:"right",start:"left",end:"right",down:"bottom"},BP=function(e){une(n,e);var t=cne(n);function n(){return sne(this,n),t.apply(this,arguments)}return lne(n,[{key:"getRole",value:function(){return this.context.menuRole==="listbox"?"listbox":"menu"}},{key:"render",value:function(){var i=this,o=this.props,a=o.className,s=o.cssModule,l=o.dark,u=o.end,f=o.right,d=o.tag,h=d===void 0?"div":d,v=o.flip,g=v===void 0?!0:v,y=o.modifiers,x=y===void 0?[]:y,_=o.persist,b=o.strategy,w=o.container,S=o.updateOnSelect,E=one(o,Qte),P=Ue(Ge(a,"dropdown-menu",{"dropdown-menu-dark":l,"dropdown-menu-end":u||f,show:this.context.isOpen}),s),T=h;if(_||this.context.isOpen&&!this.context.inNavbar){var A=mne[this.context.direction]||"bottom",D=u||f?"end":"start",k="".concat(A,"-").concat(D),I=[].concat(ene(x),[{name:"flip",enabled:!!g}]),F={};_&&(F.display="block",F.visibility=this.context.isOpen?"visible":"hidden");var q=V.createElement(K5,{placement:k,modifiers:I,strategy:b},function(X){var Q=X.ref,ne=X.style,Z=X.placement,z=X.update,B=y_(y_(y_({},i.props.style),F),ne),H=function(K){Q(K);var te=i.context.onMenuRef;te&&te(K)};return V.createElement(T,qg({tabIndex:"-1",role:i.getRole(),ref:H},E,{style:B,"aria-hidden":!i.context.isOpen,className:P,"data-popper-placement":Z,onClick:function(){return S&&z()}}))});return w?Js.createPortal(q,Oh(w)):q}var W=this.context.onMenuRef;return V.createElement(T,qg({tabIndex:"-1",role:this.getRole()},E,{ref:W,"aria-hidden":!this.context.isOpen,className:P,"data-popper-placement":E.placement,"data-bs-popper":"static"}))}}]),n}(V.Component);BP.propTypes=pne;BP.contextType=Ph;const Yc=BP;function h2(e){"@babel/helpers - typeof";return h2=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},h2(e)}var vne=["className","color","cssModule","caret","split","nav","tag","innerRef"];function p2(){return p2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function bne(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function _ne(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _3(e,t){for(var n=0;n"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 Yg(e){return Yg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Yg(e)}var Pne={caret:$.bool,color:$.string,children:$.node,className:$.string,cssModule:$.object,disabled:$.bool,onClick:$.func,"aria-haspopup":$.bool,split:$.bool,tag:at,nav:$.bool,innerRef:$.oneOfType([$.object,$.string,$.func])},Cne={color:"secondary","aria-haspopup":!0},rb=function(e){wne(n,e);var t=One(n);function n(r){var i;return _ne(this,n),i=t.call(this,r),i.onClick=i.onClick.bind(Z5(i)),i}return xne(n,[{key:"onClick",value:function(i){if(this.props.disabled||this.context.disabled){i.preventDefault();return}this.props.nav&&!this.props.tag&&i.preventDefault(),this.props.onClick&&this.props.onClick(i),this.context.toggle(i)}},{key:"getRole",value:function(){return this.context.menuRole||this.props["aria-haspopup"]}},{key:"render",value:function(){var i=this,o=this.props,a=o.className,s=o.color,l=o.cssModule,u=o.caret,f=o.split,d=o.nav,h=o.tag,v=o.innerRef,g=yne(o,vne),y=g["aria-label"]||"Toggle Dropdown",x=Ue(Ge(a,{"dropdown-toggle":u||f,"dropdown-toggle-split":f,"nav-link":d}),l),_=typeof g.children<"u"?g.children:V.createElement("span",{className:"visually-hidden"},y),b;d&&!h?(b="a",g.href="#"):h?b=h:(b=Ye,g.color=s,g.cssModule=l);var w=function(E){var P=E.ref,T=function(D){P(D);var k=i.context.onToggleRef;k&&k(D)};return V.createElement(b,p2({},g,gne({},typeof b=="string"?"ref":"innerRef",T),{className:x,onClick:i.onClick,"aria-expanded":i.context.isOpen,"aria-haspopup":i.getRole(),children:_}))};return this.context.inNavbar?V.createElement(V.Fragment,null,w({ref:this.context.onToggleRef})):V.createElement(jte,{innerRef:v},w)}}]),n}(V.Component);rb.propTypes=Pne;rb.defaultProps=Cne;rb.contextType=Ph;const Zc=rb;function Tne(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function v2(e,t){return v2=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},v2(e,t)}function jne(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,v2(e,t)}const x3={disabled:!1},X5=V.createContext(null);var Ane=function(t){return t.scrollTop},hd="unmounted",Ds="exited",Fs="entering",pu="entered",g2="exiting",Cr=function(e){jne(t,e);function t(r,i){var o;o=e.call(this,r,i)||this;var a=i,s=a&&!a.isMounting?r.enter:r.appear,l;return o.appearStatus=null,r.in?s?(l=Ds,o.appearStatus=Fs):l=pu:r.unmountOnExit||r.mountOnEnter?l=hd:l=Ds,o.state={status:l},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var a=i.in;return a&&o.status===hd?{status:Ds}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(i){var o=null;if(i!==this.props){var a=this.state.status;this.props.in?a!==Fs&&a!==pu&&(o=Fs):(a===Fs||a===pu)&&(o=g2)}this.updateStatus(!1,o)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var i=this.props.timeout,o,a,s;return o=a=s=i,i!=null&&typeof i!="number"&&(o=i.exit,a=i.enter,s=i.appear!==void 0?i.appear:a),{exit:o,enter:a,appear:s}},n.updateStatus=function(i,o){if(i===void 0&&(i=!1),o!==null)if(this.cancelNextCallback(),o===Fs){if(this.props.unmountOnExit||this.props.mountOnEnter){var a=this.props.nodeRef?this.props.nodeRef.current:Js.findDOMNode(this);a&&Ane(a)}this.performEnter(i)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Ds&&this.setState({status:hd})},n.performEnter=function(i){var o=this,a=this.props.enter,s=this.context?this.context.isMounting:i,l=this.props.nodeRef?[s]:[Js.findDOMNode(this),s],u=l[0],f=l[1],d=this.getTimeouts(),h=s?d.appear:d.enter;if(!i&&!a||x3.disabled){this.safeSetState({status:pu},function(){o.props.onEntered(u)});return}this.props.onEnter(u,f),this.safeSetState({status:Fs},function(){o.props.onEntering(u,f),o.onTransitionEnd(h,function(){o.safeSetState({status:pu},function(){o.props.onEntered(u,f)})})})},n.performExit=function(){var i=this,o=this.props.exit,a=this.getTimeouts(),s=this.props.nodeRef?void 0:Js.findDOMNode(this);if(!o||x3.disabled){this.safeSetState({status:Ds},function(){i.props.onExited(s)});return}this.props.onExit(s),this.safeSetState({status:g2},function(){i.props.onExiting(s),i.onTransitionEnd(a.exit,function(){i.safeSetState({status:Ds},function(){i.props.onExited(s)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(i,o){o=this.setNextCallback(o),this.setState(i,o)},n.setNextCallback=function(i){var o=this,a=!0;return this.nextCallback=function(s){a&&(a=!1,o.nextCallback=null,i(s))},this.nextCallback.cancel=function(){a=!1},this.nextCallback},n.onTransitionEnd=function(i,o){this.setNextCallback(o);var a=this.props.nodeRef?this.props.nodeRef.current:Js.findDOMNode(this),s=i==null&&!this.props.addEndListener;if(!a||s){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[a,this.nextCallback],u=l[0],f=l[1];this.props.addEndListener(u,f)}i!=null&&setTimeout(this.nextCallback,i)},n.render=function(){var i=this.state.status;if(i===hd)return null;var o=this.props,a=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var s=Tne(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return V.createElement(X5.Provider,{value:null},typeof a=="function"?a(i,s):V.cloneElement(V.Children.only(a),s))},t}(V.Component);Cr.contextType=X5;Cr.propTypes={};function tu(){}Cr.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:tu,onEntering:tu,onEntered:tu,onExit:tu,onExiting:tu,onExited:tu};Cr.UNMOUNTED=hd;Cr.EXITED=Ds;Cr.ENTERING=Fs;Cr.ENTERED=pu;Cr.EXITING=g2;var kne=["tag","baseClass","baseClassActive","className","cssModule","children","innerRef"];function Zg(){return Zg=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Mne(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function w3(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 Ch(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Dne(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function Fne(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function O3(e,t){for(var n=0;n"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 Qg(e){return Qg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qg(e)}function S3(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 hc(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Qne(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Jne={body:$.bool,className:$.string,color:$.string,cssModule:$.object,innerRef:$.oneOfType([$.object,$.string,$.func]),inverse:$.bool,outline:$.bool,tag:at};function Pr(e){var t=e.className,n=e.cssModule,r=e.color,i=e.body,o=e.inverse,a=e.outline,s=e.tag,l=s===void 0?"div":s,u=e.innerRef,f=Xne(e,Zne),d=Ue(Ge(t,"card",o?"text-white":!1,i?"card-body":!1,r?"".concat(a?"border":"bg","-").concat(r):!1),n);return V.createElement(l,_2({},f,{className:d,ref:u}))}Pr.propTypes=Jne;var ere=["className","cssModule","innerRef","tag"];function x2(){return x2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function nre(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var rre={className:$.string,cssModule:$.object,innerRef:$.oneOfType([$.object,$.string,$.func]),tag:at};function pc(e){var t=e.className,n=e.cssModule,r=e.innerRef,i=e.tag,o=i===void 0?"div":i,a=tre(e,ere),s=Ue(Ge(t,"card-body"),n);return V.createElement(o,x2({},a,{className:s,ref:r}))}pc.propTypes=rre;var ire=["className","cssModule","tag"];function w2(){return w2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function are(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var sre={className:$.string,cssModule:$.object,tag:at};function e8(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"div":r,o=ore(e,ire),a=Ue(Ge(t,"card-footer"),n);return V.createElement(i,w2({},o,{className:a}))}e8.propTypes=sre;var lre=["className","cssModule","tag"];function O2(){return O2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function cre(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var fre={className:$.string,cssModule:$.object,tag:at};function mc(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"div":r,o=ure(e,lre),a=Ue(Ge(t,"card-header"),n);return V.createElement(i,O2({},o,{className:a}))}mc.propTypes=fre;var dre=["className","cssModule","tag"];function S2(){return S2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function pre(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var mre={className:$.string,cssModule:$.object,tag:at};function t8(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"p":r,o=hre(e,dre),a=Ue(Ge(t,"card-text"),n);return V.createElement(i,S2({},o,{className:a}))}t8.propTypes=mre;var vre=["className","cssModule","tag"];function E2(){return E2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function yre(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var bre={className:$.string,cssModule:$.object,tag:at};function n8(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"div":r,o=gre(e,vre),a=Ue(Ge(t,"card-title"),n);return V.createElement(i,E2({},o,{className:a}))}n8.propTypes=bre;function P2(e){"@babel/helpers - typeof";return P2=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},P2(e)}var _re=["cssModule","children","isOpen","flip","target","offset","fallbackPlacements","placementPrefix","arrowClassName","hideArrow","popperClassName","tag","container","modifiers","strategy","boundariesElement","onClosed","fade","transition","placement"];function C2(){return C2=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Pre(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function Cre(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function P3(e,t){for(var n=0;n"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 Jg(e){return Jg=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Jg(e)}function C3(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 Zv(e){for(var t=1;t"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 ey(e){return ey=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ey(e)}var VP={children:$.oneOfType([$.node,$.func]),placement:$.oneOf(uJ),target:lc.isRequired,container:lc,isOpen:$.bool,disabled:$.bool,hideArrow:$.bool,boundariesElement:$.oneOfType([$.string,TP]),className:$.string,innerClassName:$.string,arrowClassName:$.string,popperClassName:$.string,cssModule:$.object,toggle:$.func,autohide:$.bool,placementPrefix:$.string,delay:$.oneOfType([$.shape({show:$.number,hide:$.number}),$.number]),modifiers:$.array,strategy:$.string,offset:$.arrayOf($.number),innerRef:$.oneOfType([$.func,$.string,$.object]),trigger:$.string,fade:$.bool,flip:$.bool},r8={show:0,hide:50},Wre={isOpen:!1,hideArrow:!1,autohide:!1,delay:r8,toggle:function(){},trigger:"click",fade:!0};function i8(e,t){return t&&(e===t||t.contains(e))}function j3(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return t&&t.length&&t.filter(function(n){return i8(e,n)})[0]}var WP=function(e){Bre(n,e);var t=Ure(n);function n(r){var i;return Dre(this,n),i=t.call(this,r),i._targets=[],i.currentTargetElement=null,i.addTargetEvents=i.addTargetEvents.bind(kr(i)),i.handleDocumentClick=i.handleDocumentClick.bind(kr(i)),i.removeTargetEvents=i.removeTargetEvents.bind(kr(i)),i.toggle=i.toggle.bind(kr(i)),i.showWithDelay=i.showWithDelay.bind(kr(i)),i.hideWithDelay=i.hideWithDelay.bind(kr(i)),i.onMouseOverTooltipContent=i.onMouseOverTooltipContent.bind(kr(i)),i.onMouseLeaveTooltipContent=i.onMouseLeaveTooltipContent.bind(kr(i)),i.show=i.show.bind(kr(i)),i.hide=i.hide.bind(kr(i)),i.onEscKeyDown=i.onEscKeyDown.bind(kr(i)),i.getRef=i.getRef.bind(kr(i)),i.state={isOpen:r.isOpen},i._isMounted=!1,i}return Fre(n,[{key:"componentDidMount",value:function(){this._isMounted=!0,this.updateTarget()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,this.removeTargetEvents(),this._targets=null,this.clearShowTimeout(),this.clearHideTimeout()}},{key:"handleDocumentClick",value:function(i){var o=this.props.trigger.split(" ");o.indexOf("legacy")>-1&&(this.props.isOpen||j3(i.target,this._targets))?(this._hideTimeout&&this.clearHideTimeout(),this.props.isOpen&&!i8(i.target,this._popover)?this.hideWithDelay(i):this.props.isOpen||this.showWithDelay(i)):o.indexOf("click")>-1&&j3(i.target,this._targets)&&(this._hideTimeout&&this.clearHideTimeout(),this.props.isOpen?this.hideWithDelay(i):this.showWithDelay(i))}},{key:"onMouseOverTooltipContent",value:function(){this.props.trigger.indexOf("hover")>-1&&!this.props.autohide&&(this._hideTimeout&&this.clearHideTimeout(),this.state.isOpen&&!this.props.isOpen&&this.toggle())}},{key:"onMouseLeaveTooltipContent",value:function(i){this.props.trigger.indexOf("hover")>-1&&!this.props.autohide&&(this._showTimeout&&this.clearShowTimeout(),i.persist(),this._hideTimeout=setTimeout(this.hide.bind(this,i),this.getDelay("hide")))}},{key:"onEscKeyDown",value:function(i){i.key==="Escape"&&this.hide(i)}},{key:"getRef",value:function(i){var o=this.props.innerRef;o&&(typeof o=="function"?o(i):Th(o)==="object"&&(o.current=i)),this._popover=i}},{key:"getDelay",value:function(i){var o=this.props.delay;return Th(o)==="object"?isNaN(o[i])?r8[i]:o[i]:o}},{key:"getCurrentTarget",value:function(i){if(!i)return null;var o=this._targets.indexOf(i);return o>=0?this._targets[o]:this.getCurrentTarget(i.parentElement)}},{key:"show",value:function(i){if(!this.props.isOpen){if(this.clearShowTimeout(),this.currentTargetElement=i?i.currentTarget||this.getCurrentTarget(i.target):null,i&&i.composedPath&&typeof i.composedPath=="function"){var o=i.composedPath();this.currentTargetElement=o&&o[0]||this.currentTargetElement}this.toggle(i)}}},{key:"showWithDelay",value:function(i){this._hideTimeout&&this.clearHideTimeout(),this._showTimeout=setTimeout(this.show.bind(this,i),this.getDelay("show"))}},{key:"hide",value:function(i){this.props.isOpen&&(this.clearHideTimeout(),this.currentTargetElement=null,this.toggle(i))}},{key:"hideWithDelay",value:function(i){this._showTimeout&&this.clearShowTimeout(),this._hideTimeout=setTimeout(this.hide.bind(this,i),this.getDelay("hide"))}},{key:"clearShowTimeout",value:function(){clearTimeout(this._showTimeout),this._showTimeout=void 0}},{key:"clearHideTimeout",value:function(){clearTimeout(this._hideTimeout),this._hideTimeout=void 0}},{key:"addEventOnTargets",value:function(i,o,a){this._targets.forEach(function(s){s.addEventListener(i,o,a)})}},{key:"removeEventOnTargets",value:function(i,o,a){this._targets.forEach(function(s){s.removeEventListener(i,o,a)})}},{key:"addTargetEvents",value:function(){if(this.props.trigger){var i=this.props.trigger.split(" ");i.indexOf("manual")===-1&&((i.indexOf("click")>-1||i.indexOf("legacy")>-1)&&document.addEventListener("click",this.handleDocumentClick,!0),this._targets&&this._targets.length&&(i.indexOf("hover")>-1&&(this.addEventOnTargets("mouseover",this.showWithDelay,!0),this.addEventOnTargets("mouseout",this.hideWithDelay,!0)),i.indexOf("focus")>-1&&(this.addEventOnTargets("focusin",this.show,!0),this.addEventOnTargets("focusout",this.hide,!0)),this.addEventOnTargets("keydown",this.onEscKeyDown,!0)))}}},{key:"removeTargetEvents",value:function(){this._targets&&(this.removeEventOnTargets("mouseover",this.showWithDelay,!0),this.removeEventOnTargets("mouseout",this.hideWithDelay,!0),this.removeEventOnTargets("keydown",this.onEscKeyDown,!0),this.removeEventOnTargets("focusin",this.show,!0),this.removeEventOnTargets("focusout",this.hide,!0)),document.removeEventListener("click",this.handleDocumentClick,!0)}},{key:"updateTarget",value:function(){var i=Oh(this.props.target,!0);i!==this._targets&&(this.removeTargetEvents(),this._targets=i?Array.from(i):[],this.currentTargetElement=this.currentTargetElement||this._targets[0],this.addTargetEvents())}},{key:"toggle",value:function(i){return this.props.disabled||!this._isMounted?i&&i.preventDefault():this.props.toggle(i)}},{key:"render",value:function(){var i=this;this.props.isOpen&&this.updateTarget();var o=this.currentTargetElement||this._targets[0];if(!o)return null;var a=this.props,s=a.className,l=a.cssModule,u=a.innerClassName,f=a.isOpen,d=a.hideArrow,h=a.boundariesElement,v=a.placement,g=a.placementPrefix,y=a.arrowClassName,x=a.popperClassName,_=a.container,b=a.modifiers,w=a.strategy,S=a.offset,E=a.fade,P=a.flip,T=a.children,A=ms(this.props,Object.keys(VP)),D=Ue(x,l),k=Ue(u,l);return V.createElement(Ire,{className:s,target:o,isOpen:f,hideArrow:d,boundariesElement:h,placement:v,placementPrefix:g,arrowClassName:y,popperClassName:D,container:_,modifiers:b,strategy:w,offset:S,cssModule:l,fade:E,flip:P},function(I){var F=I.update;return V.createElement("div",A2({},A,{ref:i.getRef,className:k,role:"tooltip",onMouseOver:i.onMouseOverTooltipContent,onMouseLeave:i.onMouseLeaveTooltipContent,onKeyDown:i.onEscKeyDown}),typeof T=="function"?T({update:F}):T)})}}],[{key:"getDerivedStateFromProps",value:function(i,o){return i.isOpen&&!o.isOpen?{isOpen:i.isOpen}:null}}]),n}(V.Component);WP.propTypes=VP;WP.defaultProps=Wre;const Hre=WP;var Gre=["children","className","barClassName","cssModule","value","min","max","animated","striped","color","bar","multi","tag","style","barStyle","barAriaValueText","barAriaLabelledBy"];function ty(){return ty=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Yre(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Zre={animated:$.bool,bar:$.bool,barAriaLabelledBy:$.string,barAriaValueText:$.string,barClassName:$.string,barStyle:$.object,children:$.node,className:$.string,cssModule:$.object,color:$.string,max:$.oneOfType([$.string,$.number]),min:$.oneOfType([$.string,$.number]),multi:$.bool,striped:$.bool,style:$.object,tag:at,value:$.oneOfType([$.string,$.number])};function o8(e){var t=e.children,n=e.className,r=e.barClassName,i=e.cssModule,o=e.value,a=o===void 0?0:o,s=e.min,l=s===void 0?0:s,u=e.max,f=u===void 0?100:u,d=e.animated,h=e.striped,v=e.color,g=e.bar,y=e.multi,x=e.tag,_=x===void 0?"div":x,b=e.style,w=b===void 0?{}:b,S=e.barStyle,E=S===void 0?{}:S,P=e.barAriaValueText,T=e.barAriaLabelledBy,A=Kre(e,Gre),D=Jk(a)/Jk(f)*100,k=Ue(Ge(n,"progress"),i),I=Ue(Ge("progress-bar",g&&n||r,d?"progress-bar-animated":null,v?"bg-".concat(v):null,h||d?"progress-bar-striped":null),i),F={className:I,style:b_(b_(b_({},g?w:{}),E),{},{width:"".concat(D,"%")}),role:"progressbar","aria-valuenow":a,"aria-valuemin":l,"aria-valuemax":f,"aria-valuetext":P,"aria-labelledby":T,children:t};return g?V.createElement(_,ty({},A,F)):V.createElement(_,ty({},A,{style:w,className:k}),y?t:V.createElement("div",F))}o8.propTypes=Zre;function N2(e){"@babel/helpers - typeof";return N2=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},N2(e)}function Xre(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function k3(e,t){for(var n=0;n"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 ny(e){return ny=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ny(e)}var iie={children:$.node.isRequired,node:$.any},a8=function(e){Jre(n,e);var t=eie(n);function n(){return Xre(this,n),t.apply(this,arguments)}return Qre(n,[{key:"componentWillUnmount",value:function(){this.defaultNode&&document.body.removeChild(this.defaultNode),this.defaultNode=null}},{key:"render",value:function(){return jP?(!this.props.node&&!this.defaultNode&&(this.defaultNode=document.createElement("div"),document.body.appendChild(this.defaultNode)),Js.createPortal(this.props.children,this.props.node||this.defaultNode)):null}}]),n}(V.Component);a8.propTypes=iie;const oie=a8;function R2(e){"@babel/helpers - typeof";return R2=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},R2(e)}function N3(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 ru(e){for(var t=1;t"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 ry(e){return ry=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ry(e)}function iy(){}var R3=$.shape(ir.propTypes),s8={autoFocus:$.bool,backdrop:$.oneOfType([$.bool,$.oneOf(["static"])]),backdropClassName:$.string,backdropTransition:R3,centered:$.bool,children:$.node,contentClassName:$.string,className:$.string,container:lc,cssModule:$.object,external:$.node,fade:$.bool,fullscreen:$.oneOfType([$.bool,$.oneOf(["sm","md","lg","xl"])]),innerRef:$.oneOfType([$.object,$.string,$.func]),isOpen:$.bool,keyboard:$.bool,labelledBy:$.string,modalClassName:$.string,modalTransition:R3,onClosed:$.func,onEnter:$.func,onExit:$.func,onOpened:$.func,returnFocusAfterClose:$.bool,role:$.string,scrollable:$.bool,size:$.string,toggle:$.func,trapFocus:$.bool,unmountOnClose:$.bool,wrapClassName:$.string,zIndex:$.oneOfType([$.number,$.string])},die=Object.keys(s8),hie={isOpen:!1,autoFocus:!0,centered:!1,scrollable:!1,role:"dialog",backdrop:!0,keyboard:!0,zIndex:1050,fade:!0,onOpened:iy,onClosed:iy,modalTransition:{timeout:Ug.Modal},backdropTransition:{mountOnEnter:!0,timeout:Ug.Fade},unmountOnClose:!0,returnFocusAfterClose:!0,container:"body",trapFocus:!1},Lp=function(e){lie(n,e);var t=uie(n);function n(r){var i;return aie(this,n),i=t.call(this,r),i._element=null,i._originalBodyPadding=null,i.getFocusableChildren=i.getFocusableChildren.bind(ni(i)),i.handleBackdropClick=i.handleBackdropClick.bind(ni(i)),i.handleBackdropMouseDown=i.handleBackdropMouseDown.bind(ni(i)),i.handleEscape=i.handleEscape.bind(ni(i)),i.handleStaticBackdropAnimation=i.handleStaticBackdropAnimation.bind(ni(i)),i.handleTab=i.handleTab.bind(ni(i)),i.onOpened=i.onOpened.bind(ni(i)),i.onClosed=i.onClosed.bind(ni(i)),i.manageFocusAfterClose=i.manageFocusAfterClose.bind(ni(i)),i.clearBackdropAnimationTimeout=i.clearBackdropAnimationTimeout.bind(ni(i)),i.trapFocus=i.trapFocus.bind(ni(i)),i.state={isOpen:!1,showStaticBackdropAnimation:!1},i}return sie(n,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isOpen,a=i.autoFocus,s=i.onEnter;o&&(this.init(),this.setState({isOpen:!0}),a&&this.setFocus()),s&&s(),document.addEventListener("focus",this.trapFocus,!0),this._isMounted=!0}},{key:"componentDidUpdate",value:function(i,o){if(this.props.isOpen&&!i.isOpen){this.init(),this.setState({isOpen:!0});return}this.props.autoFocus&&this.state.isOpen&&!o.isOpen&&this.setFocus(),this._element&&i.zIndex!==this.props.zIndex&&(this._element.style.zIndex=this.props.zIndex)}},{key:"componentWillUnmount",value:function(){this.clearBackdropAnimationTimeout(),this.props.onExit&&this.props.onExit(),this._element&&(this.destroy(),(this.props.isOpen||this.state.isOpen)&&this.close()),document.removeEventListener("focus",this.trapFocus,!0),this._isMounted=!1}},{key:"handleBackdropClick",value:function(i){if(i.target===this._mouseDownElement){i.stopPropagation();var o=this._dialog?this._dialog.parentNode:null;if(o&&i.target===o&&this.props.backdrop==="static"&&this.handleStaticBackdropAnimation(),!this.props.isOpen||this.props.backdrop!==!0)return;o&&i.target===o&&this.props.toggle&&this.props.toggle(i)}}},{key:"handleTab",value:function(i){if(i.which===9&&!(this.modalIndex0&&(i.preventDefault(),i.stopPropagation(),o[0].focus())}}},{key:"init",value:function(){try{this._triggeringElement=document.activeElement}catch{this._triggeringElement=null}this._element||(this._element=document.createElement("div"),this._element.setAttribute("tabindex","-1"),this._element.style.position="relative",this._element.style.zIndex=this.props.zIndex,this._mountContainer=Oh(this.props.container),this._mountContainer.appendChild(this._element)),this._originalBodyPadding=oJ(),n.openCount<1&&(n.originalBodyOverflow=window.getComputedStyle(document.body).overflow),aJ(),n.openCount===0&&(document.body.className=Ge(document.body.className,Ue("modal-open",this.props.cssModule)),document.body.style.overflow="hidden"),this.modalIndex=n.openCount,n.openCount+=1}},{key:"destroy",value:function(){this._element&&(this._mountContainer.removeChild(this._element),this._element=null),this.manageFocusAfterClose()}},{key:"manageFocusAfterClose",value:function(){if(this._triggeringElement){var i=this.props.returnFocusAfterClose;this._triggeringElement.focus&&i&&this._triggeringElement.focus(),this._triggeringElement=null}}},{key:"close",value:function(){if(n.openCount<=1){var i=Ue("modal-open",this.props.cssModule),o=new RegExp("(^| )".concat(i,"( |$)"));document.body.className=document.body.className.replace(o," ").trim(),document.body.style.overflow=n.originalBodyOverflow}this.manageFocusAfterClose(),n.openCount=Math.max(0,n.openCount-1),S5(this._originalBodyPadding)}},{key:"clearBackdropAnimationTimeout",value:function(){this._backdropAnimationTimeout&&(clearTimeout(this._backdropAnimationTimeout),this._backdropAnimationTimeout=void 0)}},{key:"renderModalDialog",value:function(){var i,o=this,a=ms(this.props,die),s="modal-dialog";return V.createElement("div",Ld({},a,{className:Ue(Ge(s,this.props.className,(i={},mu(i,"modal-".concat(this.props.size),this.props.size),mu(i,"".concat(s,"-centered"),this.props.centered),mu(i,"".concat(s,"-scrollable"),this.props.scrollable),mu(i,"modal-fullscreen",this.props.fullscreen===!0),mu(i,"modal-fullscreen-".concat(this.props.fullscreen,"-down"),typeof this.props.fullscreen=="string"),i)),this.props.cssModule),role:"document",ref:function(u){o._dialog=u}}),V.createElement("div",{className:Ue(Ge("modal-content",this.props.contentClassName),this.props.cssModule)},this.props.children))}},{key:"render",value:function(){var i=this.props.unmountOnClose;if(this._element&&(this.state.isOpen||!i)){var o=!!this._element&&!this.state.isOpen&&!i;this._element.style.display=o?"none":"block";var a=this.props,s=a.wrapClassName,l=a.modalClassName,u=a.backdropClassName,f=a.cssModule,d=a.isOpen,h=a.backdrop,v=a.role,g=a.labelledBy,y=a.external,x=a.innerRef,_={onClick:this.handleBackdropClick,onMouseDown:this.handleBackdropMouseDown,onKeyUp:this.handleEscape,onKeyDown:this.handleTab,style:{display:"block"},"aria-labelledby":g,"aria-modal":!0,role:v,tabIndex:"-1"},b=this.props.fade,w=ru(ru(ru({},ir.defaultProps),this.props.modalTransition),{},{baseClass:b?this.props.modalTransition.baseClass:"",timeout:b?this.props.modalTransition.timeout:0}),S=ru(ru(ru({},ir.defaultProps),this.props.backdropTransition),{},{baseClass:b?this.props.backdropTransition.baseClass:"",timeout:b?this.props.backdropTransition.timeout:0}),E=h&&(b?V.createElement(ir,Ld({},S,{in:d&&!!h,cssModule:f,className:Ue(Ge("modal-backdrop",u),f)})):V.createElement("div",{className:Ue(Ge("modal-backdrop","show",u),f)}));return V.createElement(oie,{node:this._element},V.createElement("div",{className:Ue(s)},V.createElement(ir,Ld({},_,w,{in:d,onEntered:this.onOpened,onExited:this.onClosed,cssModule:f,className:Ue(Ge("modal",l,this.state.showStaticBackdropAnimation&&"modal-static"),f),innerRef:x}),y,this.renderModalDialog()),E))}return null}}]),n}(V.Component);Lp.propTypes=s8;Lp.defaultProps=hie;Lp.openCount=0;Lp.originalBodyOverflow=null;const Po=Lp;var pie=["className","cssModule","children","toggle","tag","wrapTag","closeAriaLabel","close"];function $2(){return $2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function vie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var gie={children:$.node,className:$.string,close:$.object,closeAriaLabel:$.string,cssModule:$.object,tag:at,toggle:$.func,wrapTag:at};function Co(e){var t,n=e.className,r=e.cssModule,i=e.children,o=e.toggle,a=e.tag,s=a===void 0?"h5":a,l=e.wrapTag,u=l===void 0?"div":l,f=e.closeAriaLabel,d=f===void 0?"Close":f,h=e.close,v=mie(e,pie),g=Ue(Ge(n,"modal-header"),r);return!h&&o&&(t=V.createElement("button",{type:"button",onClick:o,className:Ue("btn-close",r),"aria-label":d})),V.createElement(u,$2({},v,{className:g}),V.createElement(s,{className:Ue("modal-title",r)},i),h||t)}Co.propTypes=gie;var yie=["className","cssModule","tag"];function I2(){return I2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function _ie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var xie={className:$.string,cssModule:$.object,tag:at};function Wi(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"div":r,o=bie(e,yie),a=Ue(Ge(t,"modal-body"),n);return V.createElement(i,I2({},o,{className:a}))}Wi.propTypes=xie;var wie=["className","cssModule","tag"];function D2(){return D2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Sie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Eie={className:$.string,cssModule:$.object,tag:at};function gs(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"div":r,o=Oie(e,wie),a=Ue(Ge(t,"modal-footer"),n);return V.createElement(i,D2({},o,{className:a}))}gs.propTypes=Eie;function F2(){return F2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function jie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Aie={className:$.string,cssModule:$.object,flush:$.bool,horizontal:$.oneOfType([$.bool,$.string]),numbered:$.bool,tag:at},kie=function(t){return t===!1?!1:t===!0||t==="xs"?"list-group-horizontal":"list-group-horizontal-".concat(t)};function l8(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"ul":r,o=e.flush,a=e.horizontal,s=a===void 0?!1:a,l=e.numbered,u=l===void 0?!1:l,f=Tie(e,Cie),d=Ue(Ge(t,"list-group",o?"list-group-flush":kie(s),{"list-group-numbered":u}),n);return V.createElement(i,B2({},f,{className:d}))}l8.propTypes=Aie;var Nie=["className","cssModule","row","disabled","check","inline","floating","noMargin","tag","switch"];function U2(){return U2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Rie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Lie={children:$.node,row:$.bool,check:$.bool,switch:$.bool,inline:$.bool,floating:$.bool,noMargin:$.bool,disabled:$.bool,tag:at,className:$.string,cssModule:$.object};function co(e){var t=e.className,n=e.cssModule,r=e.row,i=e.disabled,o=e.check,a=e.inline,s=e.floating,l=e.noMargin,u=e.tag,f=u===void 0?"div":u,d=e.switch,h=Mie(e,Nie),v=o||d,g=Ue(Ge(t,r?"row":!1,v?"form-check":!1,d?"form-switch":!1,v||l?!1:"mb-3",v&&a?"form-check-inline":!1,v&&i?"disabled":!1,s&&"form-floating"),n);return f==="fieldset"&&(h.disabled=i),V.createElement(f,U2({},h,{className:g}))}co.propTypes=Lie;function z2(e){"@babel/helpers - typeof";return z2=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},z2(e)}var $ie=["className","cssModule","type","bsSize","valid","invalid","tag","addon","plaintext","innerRef"];function V2(){return V2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Die(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function Fie(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function L3(e,t){for(var n=0;n"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 oy(e){return oy=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},oy(e)}var Hie={children:$.node,type:$.string,size:$.oneOfType([$.number,$.string]),bsSize:$.string,valid:$.bool,invalid:$.bool,tag:at,innerRef:$.oneOfType([$.object,$.func,$.string]),plaintext:$.bool,addon:$.bool,className:$.string,cssModule:$.object},u8=function(e){Uie(n,e);var t=zie(n);function n(r){var i;return Fie(this,n),i=t.call(this,r),i.getRef=i.getRef.bind(H2(i)),i.focus=i.focus.bind(H2(i)),i}return Bie(n,[{key:"getRef",value:function(i){this.props.innerRef&&this.props.innerRef(i),this.ref=i}},{key:"focus",value:function(){this.ref&&this.ref.focus()}},{key:"render",value:function(){var i=this.props,o=i.className,a=i.cssModule,s=i.type,l=s===void 0?"text":s,u=i.bsSize,f=i.valid,d=i.invalid,h=i.tag,v=i.addon,g=i.plaintext,y=i.innerRef,x=Iie(i,$ie),_=["switch","radio","checkbox"].indexOf(l)>-1,b=/\D/g,w=l==="textarea",S=l==="select",E=l==="range",P=h||(S||w?l:"input"),T="form-control";g?(T="".concat(T,"-plaintext"),P=h||"input"):E?T="form-range":S?T="form-select":_&&(v?T=null:T="form-check-input"),x.size&&b.test(x.size)&&(Uw(`Please use the prop "bsSize" instead of the "size" to bootstrap's input sizing.`),u=x.size,delete x.size);var A=Ue(Ge(o,d&&"is-invalid",f&&"is-valid",u?S?"form-select-".concat(u):"form-control-".concat(u):!1,T),a);return(P==="input"||h&&typeof h=="function")&&(x.type=l==="switch"?"checkbox":l),x.children&&!(g||l==="select"||typeof P!="string"||P==="select")&&(Uw('Input with a type of "'.concat(l,'" cannot have children. Please use "value"/"defaultValue" instead.')),delete x.children),V.createElement(P,V2({},x,{ref:y,className:A,"aria-invalid":d}))}}]),n}(V.Component);u8.propTypes=Hie;const qn=u8;var Gie=["className","cssModule","tag","type","size"];function ay(){return ay=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Kie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Yie={className:$.string,cssModule:$.object,size:$.string,tag:at,type:$.string};function ib(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"div":r;e.type;var o=e.size,a=qie(e,Gie),s=Ue(Ge(t,"input-group",o?"input-group-".concat(o):null),n);return e.type==="dropdown"?V.createElement(Rp,ay({},a,{className:s})):V.createElement(Y5.Provider,{value:{insideInputGroup:!0}},V.createElement(i,ay({},a,{className:s})))}ib.propTypes=Yie;var Zie=["className","listClassName","cssModule","size","tag","listTag","aria-label"];function G2(){return G2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Jie(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var eoe={children:$.node,className:$.string,listClassName:$.string,cssModule:$.object,size:$.string,tag:at,listTag:at,"aria-label":$.string};function HP(e){var t=e.className,n=e.listClassName,r=e.cssModule,i=e.size,o=e.tag,a=o===void 0?"nav":o,s=e.listTag,l=s===void 0?"ul":s,u=e["aria-label"],f=u===void 0?"pagination":u,d=Qie(e,Zie),h=Ue(Ge(t),r),v=Ue(Ge(n,"pagination",Xie({},"pagination-".concat(i),!!i)),r);return V.createElement(a,{className:h,"aria-label":f},V.createElement(l,G2({},d,{className:v})))}HP.propTypes=eoe;var toe=["active","className","cssModule","disabled","tag"];function q2(){return q2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function roe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var ioe={active:$.bool,children:$.node,className:$.string,cssModule:$.object,disabled:$.bool,tag:at};function cl(e){var t=e.active,n=e.className,r=e.cssModule,i=e.disabled,o=e.tag,a=o===void 0?"li":o,s=noe(e,toe),l=Ue(Ge(n,"page-item",{active:t,disabled:i}),r);return V.createElement(a,q2({},s,{className:l}))}cl.propTypes=ioe;var ooe=["className","cssModule","next","previous","first","last","tag"];function K2(){return K2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function soe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var loe={"aria-label":$.string,children:$.node,className:$.string,cssModule:$.object,next:$.bool,previous:$.bool,first:$.bool,last:$.bool,tag:at};function fl(e){var t=e.className,n=e.cssModule,r=e.next,i=e.previous,o=e.first,a=e.last,s=e.tag,l=s===void 0?"a":s,u=aoe(e,ooe),f=Ue(Ge(t,"page-link"),n),d;i?d="Previous":r?d="Next":o?d="First":a&&(d="Last");var h=e["aria-label"]||d,v;i?v="‹":r?v="›":o?v="«":a&&(v="»");var g=e.children;return g&&Array.isArray(g)&&g.length===0&&(g=null),!u.href&&l==="a"&&(l="button"),(i||r||o||a)&&(g=[V.createElement("span",{"aria-hidden":"true",key:"caret"},g||v),V.createElement("span",{className:"visually-hidden",key:"ariaLabel"},h)]),V.createElement(l,K2({},u,{className:f,"aria-label":h}),g)}fl.propTypes=loe;var uoe=["className","closeClassName","closeAriaLabel","cssModule","tag","color","isOpen","toggle","children","transition","fade","innerRef"];function Y2(){return Y2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function doe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var hoe={children:$.node,className:$.string,closeClassName:$.string,closeAriaLabel:$.string,color:$.string,cssModule:$.object,fade:$.bool,innerRef:$.oneOfType([$.object,$.string,$.func]),isOpen:$.bool,tag:at,toggle:$.func,transition:$.shape(ir.propTypes)};function c8(e){var t=e.className,n=e.closeClassName,r=e.closeAriaLabel,i=r===void 0?"Close":r,o=e.cssModule,a=e.tag,s=a===void 0?"div":a,l=e.color,u=l===void 0?"success":l,f=e.isOpen,d=f===void 0?!0:f,h=e.toggle,v=e.children,g=e.transition,y=g===void 0?Gf(Gf({},ir.defaultProps),{},{unmountOnExit:!0}):g,x=e.fade,_=x===void 0?!0:x,b=e.innerRef,w=foe(e,uoe),S=Ue(Ge(t,"alert","alert-".concat(u),{"alert-dismissible":h}),o),E=Ue(Ge("btn-close",n),o),P=Gf(Gf(Gf({},ir.defaultProps),y),{},{baseClass:_?y.baseClass:"",timeout:_?y.timeout:0});return V.createElement(ir,Y2({},w,P,{tag:s,className:S,in:d,role:"alert",innerRef:b}),h?V.createElement("button",{type:"button",className:E,"aria-label":i,onClick:h}):null,v)}c8.propTypes=hoe;var poe=["className","cssModule","tag","active","disabled","action","color"];function Z2(){return Z2=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function voe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var goe={action:$.bool,active:$.bool,className:$.string,cssModule:$.object,color:$.string,disabled:$.bool,tag:at},yoe=function(t){t.preventDefault()};function f8(e){var t=e.className,n=e.cssModule,r=e.tag,i=r===void 0?"li":r,o=e.active,a=e.disabled,s=e.action,l=e.color,u=moe(e,poe),f=Ue(Ge(t,o?"active":!1,a?"disabled":!1,s?"list-group-item-action":!1,l?"list-group-item-".concat(l):!1,"list-group-item"),n);return a&&(u.onClick=yoe),V.createElement(i,Z2({},u,{className:f}))}f8.propTypes=goe;function X2(e){"@babel/helpers - typeof";return X2=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},X2(e)}function I3(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 boe(e){for(var t=1;t"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 sy(e){return sy=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},sy(e)}var Coe=["defaultOpen"],Ip=function(e){Ooe(n,e);var t=Soe(n);function n(r){var i;return xoe(this,n),i=t.call(this,r),i.state={isOpen:r.defaultOpen||!1},i.toggle=i.toggle.bind(d8(i)),i}return woe(n,[{key:"toggle",value:function(i){var o=this;this.setState(function(a){return{isOpen:!a.isOpen}},function(){o.props.onToggle&&o.props.onToggle(i,o.state.isOpen)})}},{key:"render",value:function(){return V.createElement(Rp,Q2({isOpen:this.state.isOpen,toggle:this.toggle},ms(this.props,Coe)))}}]),n}(R.Component);Ip.propTypes=boe({defaultOpen:$.bool,onToggle:$.func},Rp.propTypes);function eO(e){"@babel/helpers - typeof";return eO=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},eO(e)}function F3(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 Toe(e){for(var t=1;t"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 ly(e){return ly=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ly(e)}var $oe=["defaultOpen"],Tr=function(e){Noe(n,e);var t=Moe(n);function n(r){var i;return Aoe(this,n),i=t.call(this,r),i.state={isOpen:r.defaultOpen||!1},i.toggle=i.toggle.bind(h8(i)),i}return koe(n,[{key:"toggle",value:function(){this.setState(function(i){return{isOpen:!i.isOpen}})}},{key:"render",value:function(){return V.createElement($p,tO({isOpen:this.state.isOpen,toggle:this.toggle},ms(this.props,$oe)))}}]),n}(R.Component);Tr.propTypes=Toe({defaultOpen:$.bool},$p.propTypes);let rv;const Ioe=new Uint8Array(16);function Doe(){if(!rv&&(rv=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!rv))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return rv(Ioe)}const $n=[];for(let e=0;e<256;++e)$n.push((e+256).toString(16).slice(1));function Foe(e,t=0){return $n[e[t+0]]+$n[e[t+1]]+$n[e[t+2]]+$n[e[t+3]]+"-"+$n[e[t+4]]+$n[e[t+5]]+"-"+$n[e[t+6]]+$n[e[t+7]]+"-"+$n[e[t+8]]+$n[e[t+9]]+"-"+$n[e[t+10]]+$n[e[t+11]]+$n[e[t+12]]+$n[e[t+13]]+$n[e[t+14]]+$n[e[t+15]]}const Boe=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),U3={randomUUID:Boe};function Uoe(e,t,n){if(U3.randomUUID&&!t&&!e)return U3.randomUUID();e=e||{};const r=e.random||(e.rng||Doe)();if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){n=n||0;for(let i=0;i<16;++i)t[n+i]=r[i];return t}return Foe(r)}var zoe=Error,Voe=EvalError,Woe=RangeError,Hoe=ReferenceError,p8=SyntaxError,Dp=TypeError,Goe=URIError,qoe=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},n=Symbol("test"),r=Object(n);if(typeof n=="string"||Object.prototype.toString.call(n)!=="[object Symbol]"||Object.prototype.toString.call(r)!=="[object Symbol]")return!1;var i=42;t[n]=i;for(n in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var o=Object.getOwnPropertySymbols(t);if(o.length!==1||o[0]!==n||!Object.prototype.propertyIsEnumerable.call(t,n))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var a=Object.getOwnPropertyDescriptor(t,n);if(a.value!==i||a.enumerable!==!0)return!1}return!0},z3=typeof Symbol<"u"&&Symbol,Koe=qoe,Yoe=function(){return typeof z3!="function"||typeof Symbol!="function"||typeof z3("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Koe()},__={__proto__:null,foo:{}},Zoe=Object,Xoe=function(){return{__proto__:__}.foo===__.foo&&!(__ instanceof Zoe)},Qoe="Function.prototype.bind called on incompatible ",Joe=Object.prototype.toString,eae=Math.max,tae="[object Function]",V3=function(t,n){for(var r=[],i=0;i"u"||!On?ot:On(Uint8Array),hl={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?ot:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?ot:ArrayBuffer,"%ArrayIteratorPrototype%":iu&&On?On([][Symbol.iterator]()):ot,"%AsyncFromSyncIteratorPrototype%":ot,"%AsyncFunction%":vu,"%AsyncGenerator%":vu,"%AsyncGeneratorFunction%":vu,"%AsyncIteratorPrototype%":vu,"%Atomics%":typeof Atomics>"u"?ot:Atomics,"%BigInt%":typeof BigInt>"u"?ot:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?ot:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?ot:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?ot:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":cae,"%eval%":eval,"%EvalError%":fae,"%Float32Array%":typeof Float32Array>"u"?ot:Float32Array,"%Float64Array%":typeof Float64Array>"u"?ot:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?ot:FinalizationRegistry,"%Function%":m8,"%GeneratorFunction%":vu,"%Int8Array%":typeof Int8Array>"u"?ot:Int8Array,"%Int16Array%":typeof Int16Array>"u"?ot:Int16Array,"%Int32Array%":typeof Int32Array>"u"?ot:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":iu&&On?On(On([][Symbol.iterator]())):ot,"%JSON%":typeof JSON=="object"?JSON:ot,"%Map%":typeof Map>"u"?ot:Map,"%MapIteratorPrototype%":typeof Map>"u"||!iu||!On?ot:On(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?ot:Promise,"%Proxy%":typeof Proxy>"u"?ot:Proxy,"%RangeError%":dae,"%ReferenceError%":hae,"%Reflect%":typeof Reflect>"u"?ot:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?ot:Set,"%SetIteratorPrototype%":typeof Set>"u"||!iu||!On?ot:On(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?ot:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":iu&&On?On(""[Symbol.iterator]()):ot,"%Symbol%":iu?Symbol:ot,"%SyntaxError%":vc,"%ThrowTypeError%":mae,"%TypedArray%":gae,"%TypeError%":qu,"%Uint8Array%":typeof Uint8Array>"u"?ot:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?ot:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?ot:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?ot:Uint32Array,"%URIError%":pae,"%WeakMap%":typeof WeakMap>"u"?ot:WeakMap,"%WeakRef%":typeof WeakRef>"u"?ot:WeakRef,"%WeakSet%":typeof WeakSet>"u"?ot:WeakSet};if(On)try{null.error}catch(e){var yae=On(On(e));hl["%Error.prototype%"]=yae}var bae=function e(t){var n;if(t==="%AsyncFunction%")n=x_("async function () {}");else if(t==="%GeneratorFunction%")n=x_("function* () {}");else if(t==="%AsyncGeneratorFunction%")n=x_("async function* () {}");else if(t==="%AsyncGenerator%"){var r=e("%AsyncGeneratorFunction%");r&&(n=r.prototype)}else if(t==="%AsyncIteratorPrototype%"){var i=e("%AsyncGenerator%");i&&On&&(n=On(i.prototype))}return hl[t]=n,n},W3={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Fp=GP,uy=uae,_ae=Fp.call(Function.call,Array.prototype.concat),xae=Fp.call(Function.apply,Array.prototype.splice),H3=Fp.call(Function.call,String.prototype.replace),cy=Fp.call(Function.call,String.prototype.slice),wae=Fp.call(Function.call,RegExp.prototype.exec),Oae=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Sae=/\\(\\)?/g,Eae=function(t){var n=cy(t,0,1),r=cy(t,-1);if(n==="%"&&r!=="%")throw new vc("invalid intrinsic syntax, expected closing `%`");if(r==="%"&&n!=="%")throw new vc("invalid intrinsic syntax, expected opening `%`");var i=[];return H3(t,Oae,function(o,a,s,l){i[i.length]=s?H3(l,Sae,"$1"):a||o}),i},Pae=function(t,n){var r=t,i;if(uy(W3,r)&&(i=W3[r],r="%"+i[0]+"%"),uy(hl,r)){var o=hl[r];if(o===vu&&(o=bae(r)),typeof o>"u"&&!n)throw new qu("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:i,name:r,value:o}}throw new vc("intrinsic "+t+" does not exist!")},Xc=function(t,n){if(typeof t!="string"||t.length===0)throw new qu("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof n!="boolean")throw new qu('"allowMissing" argument must be a boolean');if(wae(/^%?[^%]*%?$/,t)===null)throw new vc("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=Eae(t),i=r.length>0?r[0]:"",o=Pae("%"+i+"%",n),a=o.name,s=o.value,l=!1,u=o.alias;u&&(i=u[0],xae(r,_ae([0,1],u)));for(var f=1,d=!0;f=r.length){var y=dl(s,h);d=!!y,d&&"get"in y&&!("originalValue"in y.get)?s=y.get:s=s[h]}else d=uy(s,h),s=s[h];d&&!l&&(hl[a]=s)}}return s},v8={exports:{}},O_,G3;function qP(){if(G3)return O_;G3=1;var e=Xc,t=e("%Object.defineProperty%",!0)||!1;if(t)try{t({},"a",{value:1})}catch{t=!1}return O_=t,O_}var Cae=Xc,Xv=Cae("%Object.getOwnPropertyDescriptor%",!0);if(Xv)try{Xv([],"length")}catch{Xv=null}var g8=Xv,q3=qP(),Tae=p8,ou=Dp,K3=g8,jae=function(t,n,r){if(!t||typeof t!="object"&&typeof t!="function")throw new ou("`obj` must be an object or a function`");if(typeof n!="string"&&typeof n!="symbol")throw new ou("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new ou("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new ou("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new ou("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new ou("`loose`, if provided, must be a boolean");var i=arguments.length>3?arguments[3]:null,o=arguments.length>4?arguments[4]:null,a=arguments.length>5?arguments[5]:null,s=arguments.length>6?arguments[6]:!1,l=!!K3&&K3(t,n);if(q3)q3(t,n,{configurable:a===null&&l?l.configurable:!a,enumerable:i===null&&l?l.enumerable:!i,value:r,writable:o===null&&l?l.writable:!o});else if(s||!i&&!o&&!a)t[n]=r;else throw new Tae("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},rO=qP(),y8=function(){return!!rO};y8.hasArrayLengthDefineBug=function(){if(!rO)return null;try{return rO([],"length",{value:1}).length!==1}catch{return!0}};var Aae=y8,kae=Xc,Y3=jae,Nae=Aae(),Z3=g8,X3=Dp,Mae=kae("%Math.floor%"),Rae=function(t,n){if(typeof t!="function")throw new X3("`fn` is not a function");if(typeof n!="number"||n<0||n>4294967295||Mae(n)!==n)throw new X3("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],i=!0,o=!0;if("length"in t&&Z3){var a=Z3(t,"length");a&&!a.configurable&&(i=!1),a&&!a.writable&&(o=!1)}return(i||o||!r)&&(Nae?Y3(t,"length",n,!0,!0):Y3(t,"length",n)),t};(function(e){var t=GP,n=Xc,r=Rae,i=Dp,o=n("%Function.prototype.apply%"),a=n("%Function.prototype.call%"),s=n("%Reflect.apply%",!0)||t.call(a,o),l=qP(),u=n("%Math.max%");e.exports=function(h){if(typeof h!="function")throw new i("a function is required");var v=s(t,a,arguments);return r(v,1+u(0,h.length-(arguments.length-1)),!0)};var f=function(){return s(t,o,arguments)};l?l(e.exports,"apply",{value:f}):e.exports.apply=f})(v8);var Lae=v8.exports,b8=Xc,_8=Lae,$ae=_8(b8("String.prototype.indexOf")),Iae=function(t,n){var r=b8(t,!!n);return typeof r=="function"&&$ae(t,".prototype.")>-1?_8(r):r};const Dae={},Fae=Object.freeze(Object.defineProperty({__proto__:null,default:Dae},Symbol.toStringTag,{value:"Module"})),Bae=VW(Fae);var KP=typeof Map=="function"&&Map.prototype,S_=Object.getOwnPropertyDescriptor&&KP?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,fy=KP&&S_&&typeof S_.get=="function"?S_.get:null,Q3=KP&&Map.prototype.forEach,YP=typeof Set=="function"&&Set.prototype,E_=Object.getOwnPropertyDescriptor&&YP?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,dy=YP&&E_&&typeof E_.get=="function"?E_.get:null,J3=YP&&Set.prototype.forEach,Uae=typeof WeakMap=="function"&&WeakMap.prototype,$d=Uae?WeakMap.prototype.has:null,zae=typeof WeakSet=="function"&&WeakSet.prototype,Id=zae?WeakSet.prototype.has:null,Vae=typeof WeakRef=="function"&&WeakRef.prototype,eN=Vae?WeakRef.prototype.deref:null,Wae=Boolean.prototype.valueOf,Hae=Object.prototype.toString,Gae=Function.prototype.toString,qae=String.prototype.match,ZP=String.prototype.slice,$a=String.prototype.replace,Kae=String.prototype.toUpperCase,tN=String.prototype.toLowerCase,x8=RegExp.prototype.test,nN=Array.prototype.concat,so=Array.prototype.join,Yae=Array.prototype.slice,rN=Math.floor,iO=typeof BigInt=="function"?BigInt.prototype.valueOf:null,P_=Object.getOwnPropertySymbols,oO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,gc=typeof Symbol=="function"&&typeof Symbol.iterator=="object",Zn=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===gc||!0)?Symbol.toStringTag:null,w8=Object.prototype.propertyIsEnumerable,iN=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function oN(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||x8.call(/e/,t))return t;var n=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var r=e<0?-rN(-e):rN(e);if(r!==e){var i=String(r),o=ZP.call(t,i.length+1);return $a.call(i,n,"$&_")+"."+$a.call($a.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return $a.call(t,n,"$&_")}var aO=Bae,aN=aO.custom,sN=S8(aN)?aN:null,Zae=function e(t,n,r,i){var o=n||{};if(Ta(o,"quoteStyle")&&o.quoteStyle!=="single"&&o.quoteStyle!=="double")throw new TypeError('option "quoteStyle" must be "single" or "double"');if(Ta(o,"maxStringLength")&&(typeof o.maxStringLength=="number"?o.maxStringLength<0&&o.maxStringLength!==1/0:o.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var a=Ta(o,"customInspect")?o.customInspect:!0;if(typeof a!="boolean"&&a!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(Ta(o,"indent")&&o.indent!==null&&o.indent!==" "&&!(parseInt(o.indent,10)===o.indent&&o.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(Ta(o,"numericSeparator")&&typeof o.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var s=o.numericSeparator;if(typeof t>"u")return"undefined";if(t===null)return"null";if(typeof t=="boolean")return t?"true":"false";if(typeof t=="string")return P8(t,o);if(typeof t=="number"){if(t===0)return 1/0/t>0?"0":"-0";var l=String(t);return s?oN(t,l):l}if(typeof t=="bigint"){var u=String(t)+"n";return s?oN(t,u):u}var f=typeof o.depth>"u"?5:o.depth;if(typeof r>"u"&&(r=0),r>=f&&f>0&&typeof t=="object")return sO(t)?"[Array]":"[Object]";var d=pse(o,r);if(typeof i>"u")i=[];else if(E8(i,t)>=0)return"[Circular]";function h(q,W,X){if(W&&(i=Yae.call(i),i.push(W)),X){var Q={depth:o.depth};return Ta(o,"quoteStyle")&&(Q.quoteStyle=o.quoteStyle),e(q,Q,r+1,i)}return e(q,o,r+1,i)}if(typeof t=="function"&&!lN(t)){var v=ose(t),g=iv(t,h);return"[Function"+(v?": "+v:" (anonymous)")+"]"+(g.length>0?" { "+so.call(g,", ")+" }":"")}if(S8(t)){var y=gc?$a.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):oO.call(t);return typeof t=="object"&&!gc?qf(y):y}if(fse(t)){for(var x="<"+tN.call(String(t.nodeName)),_=t.attributes||[],b=0;b<_.length;b++)x+=" "+_[b].name+"="+O8(Xae(_[b].value),"double",o);return x+=">",t.childNodes&&t.childNodes.length&&(x+="..."),x+="",x}if(sO(t)){if(t.length===0)return"[]";var w=iv(t,h);return d&&!hse(w)?"["+lO(w,d)+"]":"[ "+so.call(w,", ")+" ]"}if(Jae(t)){var S=iv(t,h);return!("cause"in Error.prototype)&&"cause"in t&&!w8.call(t,"cause")?"{ ["+String(t)+"] "+so.call(nN.call("[cause]: "+h(t.cause),S),", ")+" }":S.length===0?"["+String(t)+"]":"{ ["+String(t)+"] "+so.call(S,", ")+" }"}if(typeof t=="object"&&a){if(sN&&typeof t[sN]=="function"&&aO)return aO(t,{depth:f-r});if(a!=="symbol"&&typeof t.inspect=="function")return t.inspect()}if(ase(t)){var E=[];return Q3&&Q3.call(t,function(q,W){E.push(h(W,t,!0)+" => "+h(q,t))}),uN("Map",fy.call(t),E,d)}if(use(t)){var P=[];return J3&&J3.call(t,function(q){P.push(h(q,t))}),uN("Set",dy.call(t),P,d)}if(sse(t))return C_("WeakMap");if(cse(t))return C_("WeakSet");if(lse(t))return C_("WeakRef");if(tse(t))return qf(h(Number(t)));if(rse(t))return qf(h(iO.call(t)));if(nse(t))return qf(Wae.call(t));if(ese(t))return qf(h(String(t)));if(typeof window<"u"&&t===window)return"{ [object Window] }";if(t===Ys)return"{ [object globalThis] }";if(!Qae(t)&&!lN(t)){var T=iv(t,h),A=iN?iN(t)===Object.prototype:t instanceof Object||t.constructor===Object,D=t instanceof Object?"":"null prototype",k=!A&&Zn&&Object(t)===t&&Zn in t?ZP.call(ys(t),8,-1):D?"Object":"",I=A||typeof t.constructor!="function"?"":t.constructor.name?t.constructor.name+" ":"",F=I+(k||D?"["+so.call(nN.call([],k||[],D||[]),": ")+"] ":"");return T.length===0?F+"{}":d?F+"{"+lO(T,d)+"}":F+"{ "+so.call(T,", ")+" }"}return String(t)};function O8(e,t,n){var r=(n.quoteStyle||t)==="double"?'"':"'";return r+e+r}function Xae(e){return $a.call(String(e),/"/g,""")}function sO(e){return ys(e)==="[object Array]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function Qae(e){return ys(e)==="[object Date]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function lN(e){return ys(e)==="[object RegExp]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function Jae(e){return ys(e)==="[object Error]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function ese(e){return ys(e)==="[object String]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function tse(e){return ys(e)==="[object Number]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function nse(e){return ys(e)==="[object Boolean]"&&(!Zn||!(typeof e=="object"&&Zn in e))}function S8(e){if(gc)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!oO)return!1;try{return oO.call(e),!0}catch{}return!1}function rse(e){if(!e||typeof e!="object"||!iO)return!1;try{return iO.call(e),!0}catch{}return!1}var ise=Object.prototype.hasOwnProperty||function(e){return e in this};function Ta(e,t){return ise.call(e,t)}function ys(e){return Hae.call(e)}function ose(e){if(e.name)return e.name;var t=qae.call(Gae.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}function E8(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;nt.maxStringLength){var n=e.length-t.maxStringLength,r="... "+n+" more character"+(n>1?"s":"");return P8(ZP.call(e,0,t.maxStringLength),t)+r}var i=$a.call($a.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,dse);return O8(i,"single",t)}function dse(e){var t=e.charCodeAt(0),n={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return n?"\\"+n:"\\x"+(t<16?"0":"")+Kae.call(t.toString(16))}function qf(e){return"Object("+e+")"}function C_(e){return e+" { ? }"}function uN(e,t,n,r){var i=r?lO(n,r):so.call(n,", ");return e+" ("+t+") {"+i+"}"}function hse(e){for(var t=0;t=0)return!1;return!0}function pse(e,t){var n;if(e.indent===" ")n=" ";else if(typeof e.indent=="number"&&e.indent>0)n=so.call(Array(e.indent+1)," ");else return null;return{base:n,prev:so.call(Array(t+1),n)}}function lO(e,t){if(e.length===0)return"";var n=` `+t.prev+t.base;return n+so.call(e,","+n)+` `+t.prev}function iv(e,t){var n=sO(e),r=[];if(n){r.length=e.length;for(var i=0;i1;){var n=t.pop(),r=n.obj[n.prop];if(Gs(r)){for(var i=[],o=0;o=A_?a.slice(l,l+A_):a,f=[],d=0;d=48&&h<=57||h>=65&&h<=90||h>=97&&h<=122||o===jse.RFC1738&&(h===40||h===41)){f[f.length]=u.charAt(d);continue}if(h<128){f[f.length]=no[h];continue}if(h<2048){f[f.length]=no[192|h>>6]+no[128|h&63];continue}if(h<55296||h>=57344){f[f.length]=no[224|h>>12]+no[128|h>>6&63]+no[128|h&63];continue}d+=1,h=65536+((h&1023)<<10|u.charCodeAt(d)&1023),f[f.length]=no[240|h>>18]+no[128|h>>12&63]+no[128|h>>6&63]+no[128|h&63]}s+=f.join("")}return s},Lse=function(t){for(var n=[{obj:{o:t},prop:"o"}],r=[],i=0;i"u"&&(E=0)}if(typeof f=="function"?w=f(n,w):w instanceof Date?w=v(w):r==="comma"&&oo(w)&&(w=Qv.maybeMap(w,function(B){return B instanceof Date?v(B):B})),w===null){if(a)return u&&!x?u(n,fn.encoder,_,"key",g):n;w=""}if(Vse(w)||Qv.isBuffer(w)){if(u){var A=x?n:u(n,fn.encoder,_,"key",g);return[y(A)+"="+y(u(w,fn.encoder,_,"value",g))]}return[y(n)+"="+y(String(w))]}var D=[];if(typeof w>"u")return D;var k;if(r==="comma"&&oo(w))x&&u&&(w=Qv.maybeMap(w,u)),k=[{value:w.length>0?w.join(",")||null:void 0}];else if(oo(f))k=f;else{var I=Object.keys(w);k=d?I.sort(d):I}var F=l?n.replace(/\./g,"%2E"):n,q=i&&oo(w)&&w.length===1?F+"[]":F;if(o&&oo(w)&&w.length===0)return q+"[]";for(var W=0;W"u"?t.encodeDotInKeys===!0?!0:fn.allowDots:!!t.allowDots;return{addQueryPrefix:typeof t.addQueryPrefix=="boolean"?t.addQueryPrefix:fn.addQueryPrefix,allowDots:s,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:fn.allowEmptyArrays,arrayFormat:a,charset:n,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:fn.charsetSentinel,commaRoundTrip:t.commaRoundTrip,delimiter:typeof t.delimiter>"u"?fn.delimiter:t.delimiter,encode:typeof t.encode=="boolean"?t.encode:fn.encode,encodeDotInKeys:typeof t.encodeDotInKeys=="boolean"?t.encodeDotInKeys:fn.encodeDotInKeys,encoder:typeof t.encoder=="function"?t.encoder:fn.encoder,encodeValuesOnly:typeof t.encodeValuesOnly=="boolean"?t.encodeValuesOnly:fn.encodeValuesOnly,filter:o,format:r,formatter:i,serializeDate:typeof t.serializeDate=="function"?t.serializeDate:fn.serializeDate,skipNulls:typeof t.skipNulls=="boolean"?t.skipNulls:fn.skipNulls,sort:typeof t.sort=="function"?t.sort:null,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:fn.strictNullHandling}},Gse=function(e,t){var n=e,r=Hse(t),i,o;typeof r.filter=="function"?(o=r.filter,n=o("",n)):oo(r.filter)&&(o=r.filter,i=o);var a=[];if(typeof n!="object"||n===null)return"";var s=k8[r.arrayFormat],l=s==="comma"&&r.commaRoundTrip;i||(i=Object.keys(n)),r.sort&&i.sort(r.sort);for(var u=A8(),f=0;f0?v+h:""},yc=j8,uO=Object.prototype.hasOwnProperty,qse=Array.isArray,en={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:yc.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},Kse=function(e){return e.replace(/&#(\d+);/g,function(t,n){return String.fromCharCode(parseInt(n,10))})},M8=function(e,t){return e&&typeof e=="string"&&t.comma&&e.indexOf(",")>-1?e.split(","):e},Yse="utf8=%26%2310003%3B",Zse="utf8=%E2%9C%93",Xse=function(t,n){var r={__proto__:null},i=n.ignoreQueryPrefix?t.replace(/^\?/,""):t,o=n.parameterLimit===1/0?void 0:n.parameterLimit,a=i.split(n.delimiter,o),s=-1,l,u=n.charset;if(n.charsetSentinel)for(l=0;l-1&&(g=qse(g)?[g]:g);var y=uO.call(r,v);y&&n.duplicates==="combine"?r[v]=yc.combine(r[v],g):(!y||n.duplicates==="last")&&(r[v]=g)}return r},Qse=function(e,t,n,r){for(var i=r?t:M8(t,n),o=e.length-1;o>=0;--o){var a,s=e[o];if(s==="[]"&&n.parseArrays)a=n.allowEmptyArrays&&i===""?[]:[].concat(i);else{a=n.plainObjects?Object.create(null):{};var l=s.charAt(0)==="["&&s.charAt(s.length-1)==="]"?s.slice(1,-1):s,u=n.decodeDotInKeys?l.replace(/%2E/g,"."):l,f=parseInt(u,10);!n.parseArrays&&u===""?a={0:i}:!isNaN(f)&&s!==u&&String(f)===u&&f>=0&&n.parseArrays&&f<=n.arrayLimit?(a=[],a[f]=i):u!=="__proto__"&&(a[u]=i)}i=a}return i},Jse=function(t,n,r,i){if(t){var o=r.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,a=/(\[[^[\]]*])/,s=/(\[[^[\]]*])/g,l=r.depth>0&&a.exec(o),u=l?o.slice(0,l.index):o,f=[];if(u){if(!r.plainObjects&&uO.call(Object.prototype,u)&&!r.allowPrototypes)return;f.push(u)}for(var d=0;r.depth>0&&(l=s.exec(o))!==null&&d"u"?en.charset:t.charset,r=typeof t.duplicates>"u"?en.duplicates:t.duplicates;if(r!=="combine"&&r!=="first"&&r!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var i=typeof t.allowDots>"u"?t.decodeDotInKeys===!0?!0:en.allowDots:!!t.allowDots;return{allowDots:i,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:en.allowEmptyArrays,allowPrototypes:typeof t.allowPrototypes=="boolean"?t.allowPrototypes:en.allowPrototypes,allowSparse:typeof t.allowSparse=="boolean"?t.allowSparse:en.allowSparse,arrayLimit:typeof t.arrayLimit=="number"?t.arrayLimit:en.arrayLimit,charset:n,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:en.charsetSentinel,comma:typeof t.comma=="boolean"?t.comma:en.comma,decodeDotInKeys:typeof t.decodeDotInKeys=="boolean"?t.decodeDotInKeys:en.decodeDotInKeys,decoder:typeof t.decoder=="function"?t.decoder:en.decoder,delimiter:typeof t.delimiter=="string"||yc.isRegExp(t.delimiter)?t.delimiter:en.delimiter,depth:typeof t.depth=="number"||t.depth===!1?+t.depth:en.depth,duplicates:r,ignoreQueryPrefix:t.ignoreQueryPrefix===!0,interpretNumericEntities:typeof t.interpretNumericEntities=="boolean"?t.interpretNumericEntities:en.interpretNumericEntities,parameterLimit:typeof t.parameterLimit=="number"?t.parameterLimit:en.parameterLimit,parseArrays:t.parseArrays!==!1,plainObjects:typeof t.plainObjects=="boolean"?t.plainObjects:en.plainObjects,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:en.strictNullHandling}},tle=function(e,t){var n=ele(t);if(e===""||e===null||typeof e>"u")return n.plainObjects?Object.create(null):{};for(var r=typeof e=="string"?Xse(e,n):e,i=n.plainObjects?Object.create(null):{},o=Object.keys(r),a=0;a({error:"border-danger",default:""})[e],sle=e=>({error:"text-danger",default:"text-muted"})[e],ta=({className:e,children:t,loading:n=!1,type:r="default",fullWidth:i=!1})=>{const o=Pe({"col-md-12":i,"col-md-10 offset-md-1":!i});return m.jsx(rr,{className:Pe("g-0",e),children:m.jsx("div",{className:o,children:m.jsx(Pr,{className:ale(r),body:!0,children:m.jsxs("h3",{className:Pe("text-center mb-0",sle(r)),children:[n&&m.jsx(je,{icon:DD,spin:!0}),n&&m.jsx("span",{className:"ms-2",children:t??"Loading..."}),!n&&t]})})})})},Ot=({title:e,children:t,bodyClassName:n,...r})=>m.jsxs(Pr,{...r,children:[e&&m.jsx(mc,{role:"heading","aria-level":4,children:e}),m.jsx(pc,{className:n,children:t})]}),ur=({children:e,type:t,className:n,small:r=!1})=>m.jsx(rr,{className:n,children:m.jsx("div",{className:Pe({"col-md-10 offset-md-1":!r,"col-12":r}),children:m.jsx(Ot,{role:"document",className:Pe("text-center",{"bg-main":t==="success","bg-danger":t==="error","bg-warning":t==="warning","text-white":t!=="warning"}),bodyClassName:Pe({"p-2":r}),children:e})})}),JP=e=>R8.parse(e,{ignoreQueryPrefix:!0}),ob=e=>R8.stringify(e,{arrayFormat:"brackets"}),Zt=(e=!1)=>{const[t,n]=R.useState(e),r=R.useCallback(()=>n(a=>!a),[]),i=R.useCallback(()=>n(!0),[]),o=R.useCallback(()=>n(!1),[]);return[t,r,i,o]},L8=(e=!1,t=2e3,n=window.setTimeout,r=window.clearTimeout)=>{const[i,o]=R.useState(e),a=R.useRef(e),s=R.useRef(),l=R.useCallback(()=>{o(!a.current),s.current&&r(s.current),s.current=n(()=>o(a.current),t)},[r,t,n]);return[i,l]},eC=()=>{const{current:e}=R.useRef(`dom-${Uoe()}`);return e},ca=()=>R.useRef(null),Bp=()=>{const{search:e}=pr();return R.useMemo(()=>JP(e),[e])},$8=({checked:e=!1,onChange:t,className:n,children:r,type:i,inline:o=!1})=>{const a=eC(),s=f=>t==null?void 0:t(f.target.checked,f),l={"form-switch":i==="switch","form-checkbox":i==="checkbox"},u=o?{display:"inline-block"}:{};return m.jsxs("span",{className:Pe("form-check",l,n),style:u,children:[m.jsx("input",{type:"checkbox",className:"form-check-input",id:a,checked:e,onChange:s}),m.jsx("label",{className:"form-check-label",htmlFor:a,children:r})]})},I8=e=>m.jsx($8,{type:"checkbox",...e}),El=e=>m.jsx($8,{type:"switch",...e}),Jc=({children:e,label:t,className:n="",labelClassName:r="",noMargin:i=!1,id:o})=>m.jsxs("div",{className:`${n} ${i?"":"mb-3"}`,children:[m.jsx("label",{className:`form-label ${r}`,htmlFor:o,children:t}),e]}),Jv=({children:e,value:t,onChange:n,type:r,required:i,placeholder:o,className:a,labelClassName:s})=>{const l=eC();return m.jsx(Jc,{label:m.jsxs(m.Fragment,{children:[e,":"]}),className:a,labelClassName:s,id:l,children:m.jsx("input",{id:l,className:"form-control",type:r??"text",value:t,required:i??!0,placeholder:o,onChange:u=>n(u.target.value)})})},lle=500;let eg;const fN=()=>{eg&&clearTimeout(eg),eg=null},Up=({onChange:e,className:t,large:n=!0,noBorder:r=!1,initialValue:i="",setTimeout_:o=setTimeout})=>{const[a,s]=R.useState(i),l=(u,f=lle)=>{s(u),fN(),eg=o(()=>{e(u),fN()},f)};return m.jsxs("div",{className:Pe("search-field",t),children:[m.jsx("input",{type:"text",className:Pe("form-control search-field__input",{"form-control-lg":n,"search-field__input--no-border":r}),placeholder:"Search...",value:a,onChange:u=>l(u.target.value)}),m.jsx(je,{icon:WZ,className:"search-field__icon"}),m.jsx("button",{"aria-label":"Clear search",type:"button",className:"close search-field__close btn-close",hidden:a==="",id:"search-field__close",onClick:()=>l("",0)})]})},fa=({text:e,disabled:t=!1,className:n,children:r,dropdownClassName:i,noCaret:o,end:a=!1,minWidth:s,inline:l,size:u,...f})=>{const[d,h]=Zt(),v=Pe("dropdown-btn__toggle",n,{"btn-block":!l,"dropdown-btn__toggle--with-caret":!o}),g={minWidth:s&&`${s}px`};return m.jsxs(Rp,{isOpen:d,toggle:h,disabled:t,className:i,children:[m.jsx(Zc,{size:u,caret:!o,className:v,color:"primary",...f,children:e}),m.jsx(Yc,{className:"w-100",end:a,style:g,children:r})]})},ab=({children:e,minWidth:t,label:n="Options"})=>m.jsx(fa,{text:m.jsx(je,{className:"px-1",icon:RZ}),"aria-label":n,size:"sm",minWidth:t,end:!0,noCaret:!0,inline:!0,children:e}),Fd=({children:e,...t})=>m.jsx(kP,{children:m.jsx(M5,{className:"nav-pills__nav-link",tag:OD,...t,children:e})}),D8=({children:e,fill:t=!1,className:n=""})=>m.jsx(Pr,{className:`nav-pills__nav p-0 overflow-hidden ${n}`,body:!0,children:m.jsx(AP,{pills:!0,fill:t,children:R.Children.map(e,r=>{if(!R.isValidElement(r)||r.type!==Fd)throw new Error("Only NavPillItem children are allowed inside NavPills.");return r})})}),sb=(e,t,n)=>e!==t?"ASC":n?{ASC:"DESC",DESC:void 0}[n]:"ASC",F8=(e,{field:t,dir:n})=>!t||!n?e:e.sort((r,i)=>{const o=n==="ASC"?1:-1,a=n==="ASC"?-1:1;return r[t]>i[t]?o:a}),ule=e=>e.dir?`${e.field}-${e.dir}`:void 0,cle=e=>{const[t,n]=e.split("-");return{field:t,dir:n}};function zp({items:e,order:t,onChange:n,isButton:r=!0,right:i=!1,prefixed:o=!0}){const a=s=>()=>{const l=sb(s,t.field,t.dir);n(l?s:void 0,l)};return m.jsxs(Ip,{children:[m.jsxs(Zc,{caret:!0,color:r?"primary":"link",className:Pe({"dropdown-btn__toggle btn-block pe-4 overflow-hidden":r,"btn-sm p-0":!r}),children:[!r&&m.jsx(m.Fragment,{children:"Order by"}),r&&!t.field&&m.jsx("i",{children:"Order by..."}),r&&t.field&&m.jsxs(m.Fragment,{children:[o&&"Order by: ",e[t.field]," - ",m.jsx("small",{children:t.dir??"DESC"})]})]}),m.jsxs(Yc,{end:i,className:Pe("w-100",{"ordering-dropdown__menu--link":!r}),children:[Object.entries(e).map(([s,l])=>m.jsxs(Ne,{active:t.field===s,onClick:a(s),children:[l,t.field===s&&m.jsx(je,{icon:t.dir==="ASC"?DZ:wZ,className:"ordering-dropdown__sort-icon"})]},s)),m.jsx(Ne,{divider:!0}),m.jsx(Ne,{disabled:!t.field,onClick:()=>n(),children:m.jsx("i",{children:"Clear selection"})})]})]})}const jh="#4696e5",fle="rgba(70, 150, 229, 0.4)",cO="#f77f28",dle="rgba(247, 127, 40, 0.4)",hle="white",ple="#161b22",mle=e=>{var t;return(t=document.querySelector("html"))==null?void 0:t.setAttribute("data-theme",e)},tC=()=>{var e;return((e=document.querySelector("html"))==null?void 0:e.getAttribute("data-theme"))==="dark"},nC=(e=window.matchMedia.bind(window))=>e("(prefers-color-scheme: dark)").matches?"dark":"light",vle=R.forwardRef(({isOpen:e,toggle:t,forceUpdate:n},r)=>{const[i,,o]=Zt(),a=R.useCallback(()=>{o(),n()},[n,o]);return m.jsxs(c8,{className:"app-update-banner",isOpen:e,toggle:t,tag:Ot,color:"secondary",innerRef:r,children:[m.jsx("h4",{className:"mb-4",children:"This app has just been updated!"}),m.jsxs("p",{className:"mb-0",children:["Restart it to enjoy the new features.",m.jsxs(Ye,{role:"button",disabled:i,className:"ms-2",color:"secondary",size:"sm",onClick:a,children:[!i&&m.jsxs(m.Fragment,{children:["Restart now ",m.jsx(je,{icon:ZZ,className:"ms-1"})]}),i&&m.jsx(m.Fragment,{children:"Restarting..."})]})]})]})}),B8=({to:e="/",children:t="Home"})=>m.jsx("div",{className:"home",children:m.jsxs(Ot,{className:"p-4",children:[m.jsx("h2",{children:"Oops! We could not find requested route."}),m.jsx("p",{children:"Use your browser's back button to navigate to the page you have previously come from, or just press this button."}),m.jsx("br",{}),m.jsx(Pt,{to:e,className:"btn btn-outline-primary btn-lg",children:t})]})});function Hi(e){return R.useRef(e).current}function Gi(e,t){return(n,r=globalThis.console)=>(t.forEach(i=>{const o=n[i];e[i]=o}),e)}const gle=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"})})},U8=({fetchServers:e,servers:t,settings:n,appUpdated:r,resetAppUpdate:i})=>{var x;const{MainHeader:o,Home:a,ShlinkWebComponentContainer:s,CreateServer:l,EditServer:u,Settings:f,ManageServers:d,ShlinkVersionsContainer:h}=Hi(U8),v=pr(),g=R.useRef(t),y=v.pathname==="/";return R.useEffect(()=>{Object.keys(g.current).length===0&&e()},[e]),R.useEffect(()=>{var _;mle(((_=n.ui)==null?void 0:_.theme)??nC())},[(x=n.ui)==null?void 0:x.theme]),m.jsxs("div",{className:"container-fluid app-container",children:[m.jsx(o,{}),m.jsxs("div",{className:"app",children:[m.jsx("div",{className:Pe("shlink-wrapper",{"d-flex d-md-block align-items-center":y}),children:m.jsxs(K0,{children:[m.jsx(lt,{index:!0,element:m.jsx(a,{})}),m.jsx(lt,{path:"/settings/*",element:m.jsx(f,{})}),m.jsx(lt,{path:"/manage-servers",element:m.jsx(d,{})}),m.jsx(lt,{path:"/server/create",element:m.jsx(l,{})}),m.jsx(lt,{path:"/server/:serverId/edit",element:m.jsx(u,{})}),m.jsx(lt,{path:"/server/:serverId/*",element:m.jsx(s,{})}),m.jsx(lt,{path:"*",element:m.jsx(B8,{})})]})}),m.jsx("div",{className:"shlink-footer",children:m.jsx(h,{})})]}),m.jsx(vle,{isOpen:r,toggle:i,forceUpdate:gle})]})},yle=Gi(U8,["MainHeader","Home","ShlinkWebComponentContainer","CreateServer","EditServer","Settings","ManageServers","ShlinkVersionsContainer"]);function Dn(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 ble=typeof Symbol=="function"&&Symbol.observable||"@@observable",dN=ble,N_=()=>Math.random().toString(36).substring(7).split("").join("."),_le={INIT:`@@redux/INIT${N_()}`,REPLACE:`@@redux/REPLACE${N_()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${N_()}`},hy=_le;function rC(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 z8(e,t,n){if(typeof e!="function")throw new Error(Dn(2));if(typeof t=="function"&&typeof n=="function"||typeof n=="function"&&typeof arguments[3]=="function")throw new Error(Dn(0));if(typeof t=="function"&&typeof n>"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(Dn(1));return n(z8)(e,t)}let r=e,i=t,o=new Map,a=o,s=0,l=!1;function u(){a===o&&(a=new Map,o.forEach((x,_)=>{a.set(_,x)}))}function f(){if(l)throw new Error(Dn(3));return i}function d(x){if(typeof x!="function")throw new Error(Dn(4));if(l)throw new Error(Dn(5));let _=!0;u();const b=s++;return a.set(b,x),function(){if(_){if(l)throw new Error(Dn(6));_=!1,u(),a.delete(b),o=null}}}function h(x){if(!rC(x))throw new Error(Dn(7));if(typeof x.type>"u")throw new Error(Dn(8));if(typeof x.type!="string")throw new Error(Dn(17));if(l)throw new Error(Dn(9));try{l=!0,i=r(i,x)}finally{l=!1}return(o=a).forEach(b=>{b()}),x}function v(x){if(typeof x!="function")throw new Error(Dn(10));r=x,h({type:hy.REPLACE})}function g(){const x=d;return{subscribe(_){if(typeof _!="object"||_===null)throw new Error(Dn(11));function b(){const S=_;S.next&&S.next(f())}return b(),{unsubscribe:x(b)}},[dN](){return this}}}return h({type:hy.INIT}),{dispatch:h,subscribe:d,getState:f,replaceReducer:v,[dN]:g}}function xle(e){Object.keys(e).forEach(t=>{const n=e[t];if(typeof n(void 0,{type:hy.INIT})>"u")throw new Error(Dn(12));if(typeof n(void 0,{type:hy.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Dn(13))})}function iC(e){const t=Object.keys(e),n={};for(let o=0;o"u")throw s&&s.type,new Error(Dn(14));u[d]=g,l=l||g!==v}return l=l||r.length!==Object.keys(a).length,l?u:a}}function py(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,n)=>(...r)=>t(n(...r)))}function wle(...e){return t=>(n,r)=>{const i=t(n,r);let o=()=>{throw new Error(Dn(15))};const a={getState:i.getState,dispatch:(l,...u)=>o(l,...u)},s=e.map(l=>l(a));return o=py(...s)(i.dispatch),{...i,dispatch:o}}}function Ole(e){return rC(e)&&"type"in e&&typeof e.type=="string"}var V8=Symbol.for("immer-nothing"),hN=Symbol.for("immer-draftable"),Vr=Symbol.for("immer-state");function Mi(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var bc=Object.getPrototypeOf;function os(e){return!!e&&!!e[Vr]}function na(e){var t;return e?W8(e)||Array.isArray(e)||!!e[hN]||!!((t=e.constructor)!=null&&t[hN])||ub(e)||cb(e):!1}var Sle=Object.prototype.constructor.toString();function W8(e){if(!e||typeof e!="object")return!1;const t=bc(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)===Sle}function Ah(e,t){lb(e)===0?Object.entries(e).forEach(([n,r])=>{t(n,r,e)}):e.forEach((n,r)=>t(r,n,e))}function lb(e){const t=e[Vr];return t?t.type_:Array.isArray(e)?1:ub(e)?2:cb(e)?3:0}function fO(e,t){return lb(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function H8(e,t,n){const r=lb(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function Ele(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function ub(e){return e instanceof Map}function cb(e){return e instanceof Set}function Bs(e){return e.copy_||e.base_}function dO(e,t){if(ub(e))return new Map(e);if(cb(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);if(!t&&W8(e))return bc(e)?{...e}:Object.assign(Object.create(null),e);const n=Object.getOwnPropertyDescriptors(e);delete n[Vr];let r=Reflect.ownKeys(n);for(let i=0;i1&&(e.set=e.add=e.clear=e.delete=Ple),Object.freeze(e),t&&Ah(e,(n,r)=>oC(r,!0))),e}function Ple(){Mi(2)}function fb(e){return Object.isFrozen(e)}var Cle={};function Pl(e){const t=Cle[e];return t||Mi(0,e),t}var kh;function G8(){return kh}function Tle(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function pN(e,t){t&&(Pl("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function hO(e){pO(e),e.drafts_.forEach(jle),e.drafts_=null}function pO(e){e===kh&&(kh=e.parent_)}function mN(e){return kh=Tle(kh,e)}function jle(e){const t=e[Vr];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function vN(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[Vr].modified_&&(hO(t),Mi(4)),na(e)&&(e=my(t,e),t.parent_||vy(t,e)),t.patches_&&Pl("Patches").generateReplacementPatches_(n[Vr].base_,e,t.patches_,t.inversePatches_)):e=my(t,n,[]),hO(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==V8?e:void 0}function my(e,t,n){if(fb(t))return t;const r=t[Vr];if(!r)return Ah(t,(i,o)=>gN(e,r,t,i,o,n)),t;if(r.scope_!==e)return t;if(!r.modified_)return vy(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const i=r.copy_;let o=i,a=!1;r.type_===3&&(o=new Set(i),i.clear(),a=!0),Ah(o,(s,l)=>gN(e,r,i,s,l,n,a)),vy(e,i,!1),n&&e.patches_&&Pl("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function gN(e,t,n,r,i,o,a){if(os(i)){const s=o&&t&&t.type_!==3&&!fO(t.assigned_,r)?o.concat(r):void 0,l=my(e,i,s);if(H8(n,r,l),os(l))e.canAutoFreeze_=!1;else return}else a&&n.add(i);if(na(i)&&!fb(i)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;my(e,i),(!t||!t.scope_.parent_)&&vy(e,i)}}function vy(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&oC(t,n)}function Ale(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:G8(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=r,o=aC;n&&(i=[r],o=Nh);const{revoke:a,proxy:s}=Proxy.revocable(i,o);return r.draft_=s,r.revoke_=a,s}var aC={get(e,t){if(t===Vr)return e;const n=Bs(e);if(!fO(n,t))return kle(e,n,t);const r=n[t];return e.finalized_||!na(r)?r:r===M_(e.base_,t)?(R_(e),e.copy_[t]=vO(r,e)):r},has(e,t){return t in Bs(e)},ownKeys(e){return Reflect.ownKeys(Bs(e))},set(e,t,n){const r=q8(Bs(e),t);if(r!=null&&r.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=M_(Bs(e),t),o=i==null?void 0:i[Vr];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(Ele(n,i)&&(n!==void 0||fO(e.base_,t)))return!0;R_(e),mO(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 M_(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,R_(e),mO(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=Bs(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){Mi(11)},getPrototypeOf(e){return bc(e.base_)},setPrototypeOf(){Mi(12)}},Nh={};Ah(aC,(e,t)=>{Nh[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});Nh.deleteProperty=function(e,t){return Nh.set.call(this,e,t,void 0)};Nh.set=function(e,t,n){return aC.set.call(this,e[0],t,n,e[0])};function M_(e,t){const n=e[Vr];return(n?Bs(n):e)[t]}function kle(e,t,n){var i;const r=q8(t,n);return r?"value"in r?r.value:(i=r.get)==null?void 0:i.call(e.draft_):void 0}function q8(e,t){if(!(t in e))return;let n=bc(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=bc(n)}}function mO(e){e.modified_||(e.modified_=!0,e.parent_&&mO(e.parent_))}function R_(e){e.copy_||(e.copy_=dO(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Nle=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const o=n;n=t;const a=this;return function(l=o,...u){return a.produce(l,f=>n.call(this,f,...u))}}typeof n!="function"&&Mi(6),r!==void 0&&typeof r!="function"&&Mi(7);let i;if(na(t)){const o=mN(this),a=vO(t,void 0);let s=!0;try{i=n(a),s=!1}finally{s?hO(o):pO(o)}return pN(o,r),vN(i,o)}else if(!t||typeof t!="object"){if(i=n(t),i===void 0&&(i=t),i===V8&&(i=void 0),this.autoFreeze_&&oC(i,!0),r){const o=[],a=[];Pl("Patches").generateReplacementPatches_(t,i,o,a),r(o,a)}return i}else Mi(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(a,...s)=>this.produceWithPatches(a,l=>t(l,...s));let r,i;return[this.produce(t,n,(a,s)=>{r=a,i=s}),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){na(e)||Mi(8),os(e)&&(e=K8(e));const t=mN(this),n=vO(e,void 0);return n[Vr].isManual_=!0,pO(t),n}finishDraft(e,t){const n=e&&e[Vr];(!n||!n.isManual_)&&Mi(9);const{scope_:r}=n;return pN(r,t),vN(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=Pl("Patches").applyPatches_;return os(e)?r(e,t):this.produce(e,i=>r(i,t))}};function vO(e,t){const n=ub(e)?Pl("MapSet").proxyMap_(e,t):cb(e)?Pl("MapSet").proxySet_(e,t):Ale(e,t);return(t?t.scope_:G8()).drafts_.push(n),n}function K8(e){return os(e)||Mi(10,e),Y8(e)}function Y8(e){if(!na(e)||fb(e))return e;const t=e[Vr];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=dO(e,t.scope_.immer_.useStrictShallowCopy_)}else n=dO(e,!0);return Ah(n,(r,i)=>{H8(n,r,Y8(i))}),t&&(t.finalized_=!1),n}var Wr=new Nle,Z8=Wr.produce;Wr.produceWithPatches.bind(Wr);Wr.setAutoFreeze.bind(Wr);Wr.setUseStrictShallowCopy.bind(Wr);Wr.applyPatches.bind(Wr);Wr.createDraft.bind(Wr);Wr.finishDraft.bind(Wr);function Mle(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function Rle(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function Lle(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(n=>typeof n=="function")){const n=e.map(r=>typeof r=="function"?`function ${r.name||"unnamed"}()`:typeof r).join(", ");throw new TypeError(`${t}[${n}]`)}}var yN=e=>Array.isArray(e)?e:[e];function $le(e){const t=Array.isArray(e[0])?e[0]:e;return Lle(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function Ile(e,t){const n=[],{length:r}=e;for(let i=0;i{n=sv(),a.resetResultsCount()},a.resultsCount=()=>o,a.resetResultsCount=()=>{o=0},a}function X8(e,...t){const n=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,r=(...i)=>{let o=0,a=0,s,l={},u=i.pop();typeof u=="object"&&(l=u,u=i.pop()),Mle(u,`createSelector expects an output function after the inputs, but received: [${typeof u}]`);const f={...n,...l},{memoize:d,memoizeOptions:h=[],argsMemoize:v=sC,argsMemoizeOptions:g=[],devModeChecks:y={}}=f,x=yN(h),_=yN(g),b=$le(i),w=d(function(){return o++,u.apply(null,arguments)},...x),S=v(function(){a++;const P=Ile(b,arguments);return s=w.apply(null,P),s},..._);return Object.assign(S,{resultFunc:u,memoizedResultFunc:w,dependencies:b,dependencyRecomputations:()=>a,resetDependencyRecomputations:()=>{a=0},lastResult:()=>s,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:d,argsMemoize:v})};return Object.assign(r,{withTypes:()=>r}),r}var Ule=X8(sC),zle=Object.assign((e,t=Ule)=>{Rle(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const n=Object.keys(e),r=n.map(o=>e[o]);return t(r,(...o)=>o.reduce((a,s,l)=>(a[n[l]]=s,a),{}))},{withTypes:()=>zle});function Q8(e){return({dispatch:n,getState:r})=>i=>o=>typeof o=="function"?o(n,r,e):i(o)}var Vle=Q8(),Wle=Q8,Hle=(...e)=>{const t=X8(...e),n=Object.assign((...r)=>{const i=t(...r),o=(a,...s)=>i(os(a)?K8(a):a,...s);return Object.assign(o,i),o},{withTypes:()=>n});return n};Hle(sC);var Gle=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?py:py.apply(null,arguments)},qle=e=>e&&typeof e.match=="function";function mn(e,t){function n(...r){if(t){let i=t(...r);if(!i)throw new Error(Sr(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=>Ole(r)&&r.type===e,n}var J8=class md extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,md.prototype)}static get[Symbol.species](){return md}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new md(...t[0].concat(this)):new md(...t.concat(this))}};function _N(e){return na(e)?Z8(e,()=>{}):e}function xN(e,t,n){if(e.has(t)){let i=e.get(t);return n.update&&(i=n.update(i,t,e),e.set(t,i)),i}if(!n.insert)throw new Error(Sr(10));const r=n.insert(t,e);return e.set(t,r),r}function Kle(e){return typeof e=="boolean"}var Yle=()=>function(t){const{thunk:n=!0,immutableCheck:r=!0,serializableCheck:i=!0,actionCreatorCheck:o=!0}=t??{};let a=new J8;return n&&(Kle(n)?a.push(Vle):a.push(Wle(n.extraArgument))),a},Zle="RTK_autoBatch",eF=e=>t=>{setTimeout(t,e)},Xle=typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:eF(10),Qle=(e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let i=!0,o=!1,a=!1;const s=new Set,l=e.type==="tick"?queueMicrotask:e.type==="raf"?Xle:e.type==="callback"?e.queueNotification:eF(e.timeout),u=()=>{a=!1,o&&(o=!1,s.forEach(f=>f()))};return Object.assign({},r,{subscribe(f){const d=()=>i&&f(),h=r.subscribe(d);return s.add(f),()=>{h(),s.delete(f)}},dispatch(f){var d;try{return i=!((d=f==null?void 0:f.meta)!=null&&d[Zle]),o=!i,o&&(a||(a=!0,l(u))),r.dispatch(f)}finally{i=!0}}})},Jle=e=>function(n){const{autoBatch:r=!0}=n??{};let i=new J8(e);return r&&i.push(Qle(typeof r=="object"?r:void 0)),i},eue=!0;function tF(e){const t=Yle(),{reducer:n=void 0,middleware:r,devTools:i=!0,preloadedState:o=void 0,enhancers:a=void 0}=e||{};let s;if(typeof n=="function")s=n;else if(rC(n))s=iC(n);else throw new Error(Sr(1));let l;typeof r=="function"?l=r(t):l=t();let u=py;i&&(u=Gle({trace:!eue,...typeof i=="object"&&i}));const f=wle(...l),d=Jle(f);let h=typeof a=="function"?a(d):d();const v=u(...h);return z8(s,o,v)}function nF(e){const t={},n=[];let r;const i={addCase(o,a){const s=typeof o=="string"?o:o.type;if(!s)throw new Error(Sr(28));if(s in t)throw new Error(Sr(29));return t[s]=a,i},addMatcher(o,a){return n.push({matcher:o,reducer:a}),i},addDefaultCase(o){return r=o,i}};return e(i),[t,n,r]}function tue(e){return typeof e=="function"}function nue(e,t){let[n,r,i]=nF(t),o;if(tue(e))o=()=>_N(e());else{const s=_N(e);o=()=>s}function a(s=o(),l){let u=[n[l.type],...r.filter(({matcher:f})=>f(l)).map(({reducer:f})=>f)];return u.filter(f=>!!f).length===0&&(u=[i]),u.reduce((f,d)=>{if(d)if(os(f)){const v=d(f,l);return v===void 0?f:v}else{if(na(f))return Z8(f,h=>d(h,l));{const h=d(f,l);if(h===void 0){if(f===null)return f;throw new Error(Sr(9))}return h}}return f},s)}return a.getInitialState=o,a}var rue="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",rF=(e=21)=>{let t="",n=e;for(;n--;)t+=rue[Math.random()*64|0];return t},iue=(e,t)=>qle(e)?e.match(t):e(t);function oue(...e){return t=>e.some(n=>iue(n,t))}var aue=["name","message","stack","code"],L_=class{constructor(e,t){Ql(this,"_type");this.payload=e,this.meta=t}},wN=class{constructor(e,t){Ql(this,"_type");this.payload=e,this.meta=t}},sue=e=>{if(typeof e=="object"&&e!==null){const t={};for(const n of aue)typeof e[n]=="string"&&(t[n]=e[n]);return t}return{message:String(e)}},iF=(()=>{function e(t,n,r){const i=mn(t+"/fulfilled",(l,u,f,d)=>({payload:l,meta:{...d||{},arg:f,requestId:u,requestStatus:"fulfilled"}})),o=mn(t+"/pending",(l,u,f)=>({payload:void 0,meta:{...f||{},arg:u,requestId:l,requestStatus:"pending"}})),a=mn(t+"/rejected",(l,u,f,d,h)=>({payload:d,error:(r&&r.serializeError||sue)(l||"Rejected"),meta:{...h||{},arg:f,requestId:u,rejectedWithValue:!!d,requestStatus:"rejected",aborted:(l==null?void 0:l.name)==="AbortError",condition:(l==null?void 0:l.name)==="ConditionError"}}));function s(l){return(u,f,d)=>{const h=r!=null&&r.idGenerator?r.idGenerator(l):rF(),v=new AbortController;let g,y;function x(b){y=b,v.abort()}const _=async function(){var S,E;let b;try{let P=(S=r==null?void 0:r.condition)==null?void 0:S.call(r,l,{getState:f,extra:d});if(uue(P)&&(P=await P),P===!1||v.signal.aborted)throw{name:"ConditionError",message:"Aborted due to condition callback returning false."};const T=new Promise((A,D)=>{g=()=>{D({name:"AbortError",message:y||"Aborted"})},v.signal.addEventListener("abort",g)});u(o(h,l,(E=r==null?void 0:r.getPendingMeta)==null?void 0:E.call(r,{requestId:h,arg:l},{getState:f,extra:d}))),b=await Promise.race([T,Promise.resolve(n(l,{dispatch:u,getState:f,extra:d,requestId:h,signal:v.signal,abort:x,rejectWithValue:(A,D)=>new L_(A,D),fulfillWithValue:(A,D)=>new wN(A,D)})).then(A=>{if(A instanceof L_)throw A;return A instanceof wN?i(A.payload,h,l,A.meta):i(A,h,l)})])}catch(P){b=P instanceof L_?a(null,h,l,P.payload,P.meta):a(P,h,l)}finally{g&&v.signal.removeEventListener("abort",g)}return r&&!r.dispatchConditionRejection&&a.match(b)&&b.meta.condition||u(b),b}();return Object.assign(_,{abort:x,requestId:h,arg:l,unwrap(){return _.then(lue)}})}}return Object.assign(s,{pending:o,rejected:a,fulfilled:i,settled:oue(a,i),typePrefix:t})}return e.withTypes=()=>e,e})();function lue(e){if(e.meta&&e.meta.rejectedWithValue)throw e.payload;if(e.error)throw e.error;return e.payload}function uue(e){return e!==null&&typeof e=="object"&&typeof e.then=="function"}var cue=Symbol.for("rtk-slice-createasyncthunk");function fue(e,t){return`${e}/${t}`}function due({creators:e}={}){var n;const t=(n=e==null?void 0:e.asyncThunk)==null?void 0:n[cue];return function(i){const{name:o,reducerPath:a=o}=i;if(!o)throw new Error(Sr(11));typeof process<"u";const s=(typeof i.reducers=="function"?i.reducers(pue()):i.reducers)||{},l=Object.keys(s),u={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},f={addCase(w,S){const E=typeof w=="string"?w:w.type;if(!E)throw new Error(Sr(12));if(E in u.sliceCaseReducersByType)throw new Error(Sr(13));return u.sliceCaseReducersByType[E]=S,f},addMatcher(w,S){return u.sliceMatchers.push({matcher:w,reducer:S}),f},exposeAction(w,S){return u.actionCreators[w]=S,f},exposeCaseReducer(w,S){return u.sliceCaseReducersByName[w]=S,f}};l.forEach(w=>{const S=s[w],E={reducerName:w,type:fue(o,w),createNotation:typeof i.reducers=="function"};vue(S)?yue(E,S,f,t):mue(E,S,f)});function d(){const[w={},S=[],E=void 0]=typeof i.extraReducers=="function"?nF(i.extraReducers):[i.extraReducers],P={...w,...u.sliceCaseReducersByType};return nue(i.initialState,T=>{for(let A in P)T.addCase(A,P[A]);for(let A of u.sliceMatchers)T.addMatcher(A.matcher,A.reducer);for(let A of S)T.addMatcher(A.matcher,A.reducer);E&&T.addDefaultCase(E)})}const h=w=>w,v=new Map;let g;function y(w,S){return g||(g=d()),g(w,S)}function x(){return g||(g=d()),g.getInitialState()}function _(w,S=!1){function E(T){let A=T[w];return typeof A>"u"&&S&&(A=x()),A}function P(T=h){const A=xN(v,S,{insert:()=>new WeakMap});return xN(A,T,{insert:()=>{const D={};for(const[k,I]of Object.entries(i.selectors??{}))D[k]=hue(I,T,x,S);return D}})}return{reducerPath:w,getSelectors:P,get selectors(){return P(E)},selectSlice:E}}const b={name:o,reducer:y,actions:u.actionCreators,caseReducers:u.sliceCaseReducersByName,getInitialState:x,..._(a),injectInto(w,{reducerPath:S,...E}={}){const P=S??a;return w.inject({reducerPath:P,reducer:y},E),{...b,..._(P,!0)}}};return b}}function hue(e,t,n,r){function i(o,...a){let s=t(o);return typeof s>"u"&&r&&(s=n()),e(s,...a)}return i.unwrapped=e,i}var nn=due();function pue(){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 mue({type:e,reducerName:t,createNotation:n},r,i){let o,a;if("reducer"in r){if(n&&!gue(r))throw new Error(Sr(17));o=r.reducer,a=r.prepare}else o=r;i.addCase(e,o).exposeCaseReducer(t,o).exposeAction(t,a?mn(e,a):mn(e))}function vue(e){return e._reducerDefinitionType==="asyncThunk"}function gue(e){return e._reducerDefinitionType==="reducerWithPrepare"}function yue({type:e,reducerName:t},n,r,i){if(!i)throw new Error(Sr(18));const{payloadCreator:o,fulfilled:a,pending:s,rejected:l,settled:u,options:f}=n,d=i(e,o,f);r.exposeAction(t,d),a&&r.addCase(d.fulfilled,a),s&&r.addCase(d.pending,s),l&&r.addCase(d.rejected,l),u&&r.addMatcher(d.settled,u),r.exposeCaseReducer(t,{fulfilled:a||lv,pending:s||lv,rejected:l||lv,settled:u||lv})}function lv(){}var bue=(e,t)=>{if(typeof e!="function")throw new Error(Sr(32))},lC="listenerMiddleware",_ue=e=>{let{type:t,actionCreator:n,matcher:r,predicate:i,effect:o}=e;if(t)i=mn(t).match;else if(n)t=n.type,i=n.match;else if(r)i=r;else if(!i)throw new Error(Sr(21));return bue(o),{predicate:i,type:t,effect:o}},xue=Object.assign(e=>{const{type:t,predicate:n,effect:r}=_ue(e);return{id:rF(),effect:r,type:t,predicate:n,pending:new Set,unsubscribe:()=>{throw new Error(Sr(22))}}},{withTypes:()=>xue}),wue=Object.assign(mn(`${lC}/add`),{withTypes:()=>wue});mn(`${lC}/removeAll`);var Oue=Object.assign(mn(`${lC}/remove`),{withTypes:()=>Oue});function Sr(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:Sue,reducer:Eue}=nn({name:"shlink/appUpdates",initialState:!1,reducers:{appUpdateAvailable:()=>!0,resetAppUpdate:()=>!1}}),{appUpdateAvailable:Pue,resetAppUpdate:Cue}=Sue,Tue=Eue,jue=(e,t)=>{e.factory("App",yle),e.decorator("App",t(["servers","settings","appUpdated"],["fetchServers","resetAppUpdate"])),e.serviceFactory("appUpdateAvailable",()=>Pue),e.serviceFactory("resetAppUpdate",()=>Cue)},ON={"Content-Type":"application/json"},SN=e=>e!=null&&e.body?e?{...e,headers:{...e.headers??{},...ON}}:{headers:ON}:e;let Aue=class{constructor(t=window.fetch.bind(window)){this.fetch=t}async jsonRequest(t,n){return this.fetch(t,SN(n)).then(async r=>{const i=await r.json();if(!r.ok)throw i;return i})}async emptyRequest(t,n){return this.fetch(t,SN(n)).then(async r=>{if(!r.ok)throw await r.json()})}};var uC=(e=>(e.INVALID_ARGUMENT="https://shlink.io/api/error/invalid-data",e.INVALID_SHORT_URL_DELETION="https://shlink.io/api/error/invalid-short-url-deletion",e.DOMAIN_NOT_FOUND="https://shlink.io/api/error/domain-not-found",e.FORBIDDEN_OPERATION="https://shlink.io/api/error/forbidden-tag-operation",e.INVALID_SLUG="https://shlink.io/api/error/non-unique-slug",e.INVALID_SHORTCODE="https://shlink.io/api/error/short-url-not-found",e.TAG_CONFLICT="https://shlink.io/api/error/tag-conflict",e.TAG_NOT_FOUND="https://shlink.io/api/error/tag-not-found",e.MERCURE_NOT_CONFIGURED="https://shlink.io/api/error/mercure-not-configured",e.INVALID_AUTHORIZATION="https://shlink.io/api/error/missing-authentication",e.INVALID_API_KEY="https://shlink.io/api/error/invalid-api-key",e.NOT_FOUND="https://shlink.io/api/error/not-found",e.INVALID_URL="https://shlink.io/api/error/invalid-url",e))(uC||{});const oF=(e,t)=>e.reduce((n,r)=>{const i=t(r);return n[i]=(n[i]||0)+1,n},{}),kue=(e,t)=>e.reduce((n,r)=>{const i=t(r);return(n[i]=n[i]||[]).push(r),n},{}),$_=e=>Object.prototype.toString.call(e)==="[object Object]",aF=(e,t)=>{const n={};return(...r)=>{const i=e(...r);if(n[i])return n[i];const o=t(...r);return n[i]=o,o}},db=(e,t)=>{const n={...e};return!$_(e)||!$_(t)||Object.keys(t).forEach(r=>{$_(t[r])?n[r]=r in e&&e[r]!==void 0?db(e[r],t[r]):{...t[r]}:n[r]=t[r]}),n},cC=(e,t)=>Array.from({length:t-e},(n,r)=>e+r),Nue=(e,t)=>[...e].sort((n,r)=>{const i=t(n),o=t(r);return i===o?0:i{const n=[];for(let r=0;rObject.fromEntries(e.map((n,r)=>[n,t[r]]));function Ke(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}function Vi(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function fC(e,t){const n=Ke(e);return isNaN(t)?Vi(e,NaN):(t&&n.setDate(n.getDate()+t),n)}function Mue(e,t){const n=Ke(e);if(isNaN(t))return Vi(e,NaN);if(!t)return n;const r=n.getDate(),i=Vi(e,n.getTime());i.setMonth(n.getMonth()+t+1,0);const o=i.getDate();return r>=o?i:(n.setFullYear(i.getFullYear(),i.getMonth(),r),n)}function Rue(e,t){const{years:n=0,months:r=0,weeks:i=0,days:o=0,hours:a=0,minutes:s=0,seconds:l=0}=t,u=Ke(e),f=r||n?Mue(u,r+n*12):u,d=o||i?fC(f,o+i*7):f,h=s+a*60,g=(l+h*60)*1e3;return Vi(e,d.getTime()+g)}const sF=6048e5,Lue=864e5,lF=6e4,dC=36e5,uv=43200,PN=1440;let $ue={};function ef(){return $ue}function Mh(e,t){var s,l,u,f;const n=ef(),r=(t==null?void 0:t.weekStartsOn)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((f=(u=n.locale)==null?void 0:u.options)==null?void 0:f.weekStartsOn)??0,i=Ke(e),o=i.getDay(),a=(o=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function Cl(e){const t=Ke(e);return t.setHours(0,0,0,0),t}function gy(e){const t=Ke(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function cF(e,t){const n=Cl(e),r=Cl(t),i=+n-gy(n),o=+r-gy(r);return Math.round((i-o)/Lue)}function Iue(e){const t=uF(e),n=Vi(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),Rh(n)}function fF(e){let t;return e.forEach(function(n){const r=Ke(n);(t===void 0||t{const r=Ke(n);(!t||t>r||isNaN(+r))&&(t=r)}),t||new Date(NaN)}function tg(e,t){const n=Ke(e),r=Ke(t),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function Fue(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Bue(e){if(!Fue(e)&&typeof e!="number")return!1;const t=Ke(e);return!isNaN(Number(t))}function Uue(e,t){const n=Ke(e),r=Ke(t),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return i*12+o}function Vp(e,t){const n=Ke(e),r=Ke(t),i=CN(n,r),o=Math.abs(cF(n,r));n.setDate(n.getDate()-i*o);const a=+(CN(n,r)===-i),s=i*(o-a);return s===0?0:s}function CN(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 hC(e){return t=>{const r=(e?Math[e]:Math.trunc)(t);return r===0?0:r}}function dF(e,t){return+Ke(e)-+Ke(t)}function zue(e,t,n){const r=dF(e,t)/dC;return hC(n==null?void 0:n.roundingMethod)(r)}function _c(e){const t=Ke(e);return t.setHours(23,59,59,999),t}function Vue(e){const t=Ke(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function Wue(e){const t=Ke(e);return+_c(t)==+Vue(t)}function yy(e,t){const n=Ke(e),r=Ke(t),i=tg(n,r),o=Math.abs(Uue(n,r));let a;if(o<1)a=0;else{n.getMonth()===1&&n.getDate()>27&&n.setDate(30),n.setMonth(n.getMonth()-i*o);let s=tg(n,r)===-i;Wue(Ke(e))&&o===1&&tg(e,r)===1&&(s=!1),a=i*(o-Number(s))}return a===0?0:a}function Hue(e,t,n){const r=dF(e,t)/1e3;return hC(n==null?void 0:n.roundingMethod)(r)}function Gue(e,t,n){const r=Vp(e,t)/7;return hC(n==null?void 0:n.roundingMethod)(r)}function que(e){const t=Ke(e),n=Vi(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}function Kue(e,t){var s,l,u,f;const n=ef(),r=(t==null?void 0:t.weekStartsOn)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((f=(u=n.locale)==null?void 0:u.options)==null?void 0:f.weekStartsOn)??0,i=Ke(e),o=i.getDay(),a=(o{let r;const i=Zue[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 I_(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const Que={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Jue={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},ece={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},tce={date:I_({formats:Que,defaultWidth:"full"}),time:I_({formats:Jue,defaultWidth:"full"}),dateTime:I_({formats:ece,defaultWidth:"full"})},nce={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},rce=(e,t,n,r)=>nce[e];function Kf(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,s=n!=null&&n.width?String(n.width):a;i=e.formattingValues[s]||e.formattingValues[a]}else{const a=e.defaultWidth,s=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[s]||e.values[a]}const o=e.argumentCallback?e.argumentCallback(t):t;return i[o]}}const ice={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},oce={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},ace={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"]},sce={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"]},lce={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"}},uce={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"}},cce=(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"},fce={ordinalNumber:cce,era:Kf({values:ice,defaultWidth:"wide"}),quarter:Kf({values:oce,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Kf({values:ace,defaultWidth:"wide"}),day:Kf({values:sce,defaultWidth:"wide"}),dayPeriod:Kf({values:lce,defaultWidth:"wide",formattingValues:uce,defaultFormattingWidth:"wide"})};function Yf(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;const a=o[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(s)?hce(s,d=>d.test(a)):dce(s,d=>d.test(a));let u;u=e.valueCallback?e.valueCallback(l):l,u=n.valueCallback?n.valueCallback(u):u;const f=t.slice(a.length);return{value:u,rest:f}}}function dce(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function hce(e,t){for(let n=0;n{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],o=t.match(e.parsePattern);if(!o)return null;let a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;const s=t.slice(i.length);return{value:a,rest:s}}}const mce=/^(\d+)(th|st|nd|rd)?/i,vce=/\d+/i,gce={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},yce={any:[/^b/i,/^(a|c)/i]},bce={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},_ce={any:[/1/i,/2/i,/3/i,/4/i]},xce={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},wce={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]},Oce={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},Sce={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]},Ece={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},Pce={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}},Cce={ordinalNumber:pce({matchPattern:mce,parsePattern:vce,valueCallback:e=>parseInt(e,10)}),era:Yf({matchPatterns:gce,defaultMatchWidth:"wide",parsePatterns:yce,defaultParseWidth:"any"}),quarter:Yf({matchPatterns:bce,defaultMatchWidth:"wide",parsePatterns:_ce,defaultParseWidth:"any",valueCallback:e=>e+1}),month:Yf({matchPatterns:xce,defaultMatchWidth:"wide",parsePatterns:wce,defaultParseWidth:"any"}),day:Yf({matchPatterns:Oce,defaultMatchWidth:"wide",parsePatterns:Sce,defaultParseWidth:"any"}),dayPeriod:Yf({matchPatterns:Ece,defaultMatchWidth:"any",parsePatterns:Pce,defaultParseWidth:"any"})},hF={code:"en-US",formatDistance:Xue,formatLong:tce,formatRelative:rce,localize:fce,match:Cce,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Tce(e){const t=Ke(e);return cF(t,que(t))+1}function jce(e){const t=Ke(e),n=+Rh(t)-+Iue(t);return Math.round(n/sF)+1}function pF(e,t){var f,d,h,v;const n=Ke(e),r=n.getFullYear(),i=ef(),o=(t==null?void 0:t.firstWeekContainsDate)??((d=(f=t==null?void 0:t.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??i.firstWeekContainsDate??((v=(h=i.locale)==null?void 0:h.options)==null?void 0:v.firstWeekContainsDate)??1,a=Vi(e,0);a.setFullYear(r+1,0,o),a.setHours(0,0,0,0);const s=Mh(a,t),l=Vi(e,0);l.setFullYear(r,0,o),l.setHours(0,0,0,0);const u=Mh(l,t);return n.getTime()>=s.getTime()?r+1:n.getTime()>=u.getTime()?r:r-1}function Ace(e,t){var s,l,u,f;const n=ef(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(s=t==null?void 0:t.locale)==null?void 0:s.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((f=(u=n.locale)==null?void 0:u.options)==null?void 0:f.firstWeekContainsDate)??1,i=pF(e,t),o=Vi(e,0);return o.setFullYear(i,0,r),o.setHours(0,0,0,0),Mh(o,t)}function kce(e,t){const n=Ke(e),r=+Mh(n,t)-+Ace(n,t);return Math.round(r/sF)+1}function rt(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const _a={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return rt(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):rt(n+1,2)},d(e,t){return rt(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 rt(e.getHours()%12||12,t.length)},H(e,t){return rt(e.getHours(),t.length)},m(e,t){return rt(e.getMinutes(),t.length)},s(e,t){return rt(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),i=Math.trunc(r*Math.pow(10,n-3));return rt(i,t.length)}},au={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},TN={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 _a.y(e,t)},Y:function(e,t,n,r){const i=pF(e,r),o=i>0?i:1-i;if(t==="YY"){const a=o%100;return rt(a,2)}return t==="Yo"?n.ordinalNumber(o,{unit:"year"}):rt(o,t.length)},R:function(e,t){const n=uF(e);return rt(n,t.length)},u:function(e,t){const n=e.getFullYear();return rt(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 rt(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 rt(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 _a.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 rt(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=kce(e,r);return t==="wo"?n.ordinalNumber(i,{unit:"week"}):rt(i,t.length)},I:function(e,t,n){const r=jce(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):rt(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):_a.d(e,t)},D:function(e,t,n){const r=Tce(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):rt(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const i=e.getDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return rt(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const i=e.getDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return rt(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),i=r===0?7:r;switch(t){case"i":return String(i);case"ii":return rt(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=au.noon:r===0?i=au.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=au.evening:r>=12?i=au.afternoon:r>=4?i=au.morning:i=au.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 _a.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):_a.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):rt(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):rt(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):_a.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):_a.s(e,t)},S:function(e,t){return _a.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return AN(r);case"XXXX":case"XX":return Us(r);case"XXXXX":case"XXX":default:return Us(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return AN(r);case"xxxx":case"xx":return Us(r);case"xxxxx":case"xxx":default:return Us(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+jN(r,":");case"OOOO":default:return"GMT"+Us(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+jN(r,":");case"zzzz":default:return"GMT"+Us(r,":")}},t:function(e,t,n){const r=Math.trunc(e.getTime()/1e3);return rt(r,t.length)},T:function(e,t,n){const r=e.getTime();return rt(r,t.length)}};function jN(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Math.trunc(r/60),o=r%60;return o===0?n+String(i):n+String(i)+t+rt(o,2)}function AN(e,t){return e%60===0?(e>0?"-":"+")+rt(Math.abs(e)/60,2):Us(e,t)}function Us(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=rt(Math.trunc(r/60),2),o=rt(r%60,2);return n+i+t+o}const kN=(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"})}},mF=(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"})}},Nce=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return kN(e,t);let o;switch(r){case"P":o=t.dateTime({width:"short"});break;case"PP":o=t.dateTime({width:"medium"});break;case"PPP":o=t.dateTime({width:"long"});break;case"PPPP":default:o=t.dateTime({width:"full"});break}return o.replace("{{date}}",kN(r,t)).replace("{{time}}",mF(i,t))},Mce={p:mF,P:Nce},Rce=/^D+$/,Lce=/^Y+$/,$ce=["D","DD","YY","YYYY"];function Ice(e){return Rce.test(e)}function Dce(e){return Lce.test(e)}function Fce(e,t,n){const r=Bce(e,t,n);if(console.warn(r),$ce.includes(e))throw new RangeError(r)}function Bce(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 Uce=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,zce=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Vce=/^'([^]*?)'?$/,Wce=/''/g,Hce=/[a-zA-Z]/;function by(e,t,n){var f,d,h,v,g,y,x,_;const r=ef(),i=(n==null?void 0:n.locale)??r.locale??hF,o=(n==null?void 0:n.firstWeekContainsDate)??((d=(f=n==null?void 0:n.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((v=(h=r.locale)==null?void 0:h.options)==null?void 0:v.firstWeekContainsDate)??1,a=(n==null?void 0:n.weekStartsOn)??((y=(g=n==null?void 0:n.locale)==null?void 0:g.options)==null?void 0:y.weekStartsOn)??r.weekStartsOn??((_=(x=r.locale)==null?void 0:x.options)==null?void 0:_.weekStartsOn)??0,s=Ke(e);if(!Bue(s))throw new RangeError("Invalid time value");let l=t.match(zce).map(b=>{const w=b[0];if(w==="p"||w==="P"){const S=Mce[w];return S(b,i.formatLong)}return b}).join("").match(Uce).map(b=>{if(b==="''")return{isToken:!1,value:"'"};const w=b[0];if(w==="'")return{isToken:!1,value:Gce(b)};if(TN[w])return{isToken:!0,value:b};if(w.match(Hce))throw new RangeError("Format string contains an unescaped latin alphabet character `"+w+"`");return{isToken:!1,value:b}});i.localize.preprocessor&&(l=i.localize.preprocessor(s,l));const u={firstWeekContainsDate:o,weekStartsOn:a,locale:i};return l.map(b=>{if(!b.isToken)return b.value;const w=b.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&Dce(w)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&Ice(w))&&Fce(w,t,String(e));const S=TN[w[0]];return S(s,w,i.localize,u)}).join("")}function Gce(e){const t=e.match(Vce);return t?t[1].replace(Wce,"'"):e}function qce(e,t,n){const r=ef(),i=(n==null?void 0:n.locale)??r.locale??hF,o=2520,a=tg(e,t);if(isNaN(a))throw new RangeError("Invalid time value");const s=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:a});let l,u;a>0?(l=Ke(t),u=Ke(e)):(l=Ke(e),u=Ke(t));const f=Hue(u,l),d=(gy(u)-gy(l))/1e3,h=Math.round((f-d)/60);let v;if(h<2)return n!=null&&n.includeSeconds?f<5?i.formatDistance("lessThanXSeconds",5,s):f<10?i.formatDistance("lessThanXSeconds",10,s):f<20?i.formatDistance("lessThanXSeconds",20,s):f<40?i.formatDistance("halfAMinute",0,s):f<60?i.formatDistance("lessThanXMinutes",1,s):i.formatDistance("xMinutes",1,s):h===0?i.formatDistance("lessThanXMinutes",1,s):i.formatDistance("xMinutes",h,s);if(h<45)return i.formatDistance("xMinutes",h,s);if(h<90)return i.formatDistance("aboutXHours",1,s);if(hr.getTime()}function _y(e,t){const n=Ke(e),r=Ke(t);return+n<+r}function gO(e,t){const n=Ke(e),r=Ke(t);return+n==+r}function Xce(e,t){const n=+Ke(e),[r,i]=[+Ke(t.start),+Ke(t.end)].sort((o,a)=>o-a);return n>=r&&n<=i}function xy(e,t){return fC(e,-t)}function as(e,t){const n=(t==null?void 0:t.additionalDigits)??2,r=tfe(e);let i;if(r.date){const l=nfe(r.date,n);i=rfe(l.restDateString,l.year)}if(!i||isNaN(i.getTime()))return new Date(NaN);const o=i.getTime();let a=0,s;if(r.time&&(a=ife(r.time),isNaN(a)))return new Date(NaN);if(r.timezone){if(s=ofe(r.timezone),isNaN(s))return new Date(NaN)}else{const l=new Date(o+a),u=new Date(0);return u.setFullYear(l.getUTCFullYear(),l.getUTCMonth(),l.getUTCDate()),u.setHours(l.getUTCHours(),l.getUTCMinutes(),l.getUTCSeconds(),l.getUTCMilliseconds()),u}return new Date(o+a+s)}const cv={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Qce=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,Jce=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,efe=/^([+-])(\d{2})(?::?(\d{2}))?$/;function tfe(e){const t={},n=e.split(cv.dateTimeDelimiter);let r;if(n.length>2)return t;if(/:/.test(n[0])?r=n[0]:(t.date=n[0],r=n[1],cv.timeZoneDelimiter.test(t.date)&&(t.date=e.split(cv.timeZoneDelimiter)[0],r=e.substr(t.date.length,e.length))),r){const i=cv.timezone.exec(r);i?(t.time=r.replace(i[1],""),t.timezone=i[1]):t.time=r}return t}function nfe(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,o=r[2]?parseInt(r[2]):null;return{year:o===null?i:o*100,restDateString:e.slice((r[1]||r[2]).length)}}function rfe(e,t){if(t===null)return new Date(NaN);const n=e.match(Qce);if(!n)return new Date(NaN);const r=!!n[4],i=Zf(n[1]),o=Zf(n[2])-1,a=Zf(n[3]),s=Zf(n[4]),l=Zf(n[5])-1;if(r)return cfe(t,s,l)?afe(t,s,l):new Date(NaN);{const u=new Date(0);return!lfe(t,o,a)||!ufe(t,i)?new Date(NaN):(u.setUTCFullYear(t,o,Math.max(i,a)),u)}}function Zf(e){return e?parseInt(e):1}function ife(e){const t=e.match(Jce);if(!t)return NaN;const n=D_(t[1]),r=D_(t[2]),i=D_(t[3]);return ffe(n,r,i)?n*dC+r*lF+i*1e3:NaN}function D_(e){return e&&parseFloat(e.replace(",","."))||0}function ofe(e){if(e==="Z")return 0;const t=e.match(efe);if(!t)return 0;const n=t[1]==="+"?-1:1,r=parseInt(t[2]),i=t[3]&&parseInt(t[3])||0;return dfe(r,i)?n*(r*dC+i*lF):NaN}function afe(e,t,n){const r=new Date(0);r.setUTCFullYear(e,0,4);const i=r.getUTCDay()||7,o=(t-1)*7+n+1-i;return r.setUTCDate(r.getUTCDate()+o),r}const sfe=[31,null,31,30,31,30,31,31,30,31,30,31];function vF(e){return e%400===0||e%4===0&&e%100!==0}function lfe(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(sfe[t]||(vF(e)?29:28))}function ufe(e,t){return t>=1&&t<=(vF(e)?366:365)}function cfe(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function ffe(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function dfe(e,t){return t>=0&&t<=59}const Er=({href:e,children:t,rel:n,...r})=>m.jsx("a",{target:"_blank",rel:`noopener noreferrer${n?` ${n}`:""}`,href:e,...r,children:t??e}),hfe="Left",pfe="Right",mfe="Up",vfe="Down",Lu={delta:10,preventScrollOnSwipe:!1,rotationAngle:0,trackMouse:!1,trackTouch:!0,swipeDuration:1/0,touchEventOptions:{passive:!0}},yO={first:!0,initial:[0,0],start:0,swiping:!1,xy:[0,0]},NN="mousemove",MN="mouseup",gfe="touchend",yfe="touchmove",bfe="touchstart";function _fe(e,t,n,r){return e>t?n>0?pfe:hfe:r>0?vfe:mfe}function RN(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 xfe(e,t){const n=f=>{const d="touches"in f;d&&f.touches.length>1||e((h,v)=>{v.trackMouse&&!d&&(document.addEventListener(NN,r),document.addEventListener(MN,a));const{clientX:g,clientY:y}=d?f.touches[0]:f,x=RN([g,y],v.rotationAngle);return v.onTouchStartOrOnMouseDown&&v.onTouchStartOrOnMouseDown({event:f}),Object.assign(Object.assign(Object.assign({},h),yO),{initial:x.slice(),xy:x,start:f.timeStamp||0})})},r=f=>{e((d,h)=>{const v="touches"in f;if(v&&f.touches.length>1)return d;if(f.timeStamp-d.start>h.swipeDuration)return d.swiping?Object.assign(Object.assign({},d),{swiping:!1}):d;const{clientX:g,clientY:y}=v?f.touches[0]:f,[x,_]=RN([g,y],h.rotationAngle),b=x-d.xy[0],w=_-d.xy[1],S=Math.abs(b),E=Math.abs(w),P=(f.timeStamp||0)-d.start,T=Math.sqrt(S*S+E*E)/(P||1),A=[b/(P||1),w/(P||1)],D=_fe(S,E,b,w),k=typeof h.delta=="number"?h.delta:h.delta[D.toLowerCase()]||Lu.delta;if(S{e((d,h)=>{let v;if(d.swiping&&d.eventData){if(f.timeStamp-d.start{document.removeEventListener(NN,r),document.removeEventListener(MN,a)},a=f=>{o(),i(f)},s=(f,d)=>{let h=()=>{};if(f&&f.addEventListener){const v=Object.assign(Object.assign({},Lu.touchEventOptions),d.touchEventOptions),g=[[bfe,n,v],[yfe,r,Object.assign(Object.assign({},v),d.preventScrollOnSwipe?{passive:!1}:{})],[gfe,i,v]];g.forEach(([y,x,_])=>f.addEventListener(y,x,_)),h=()=>g.forEach(([y,x])=>f.removeEventListener(y,x))}return h},u={ref:f=>{f!==null&&e((d,h)=>{if(d.el===f)return d;const v={};return d.el&&d.el!==f&&d.cleanUpTouch&&(d.cleanUpTouch(),v.cleanUpTouch=void 0),h.trackTouch&&f&&(v.cleanUpTouch=s(f,h)),Object.assign(Object.assign(Object.assign({},d),{el:f}),v)})}};return t.trackMouse&&(u.onMouseDown=n),[u,s]}function wfe(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 Ofe(e){const{trackMouse:t}=e,n=R.useRef(Object.assign({},yO)),r=R.useRef(Object.assign({},Lu)),i=R.useRef(Object.assign({},r.current));i.current=Object.assign({},r.current),r.current=Object.assign(Object.assign({},Lu),e);let o;for(o in Lu)r.current[o]===void 0&&(r.current[o]=Lu[o]);const[a,s]=R.useMemo(()=>xfe(l=>n.current=l(n.current,r.current),{trackMouse:t}),[t]);return n.current=wfe(n.current,r.current,i.current,s),a}var bO={exports:{}};/** @license * eventsource.js * Available under MIT License (MIT) * https://github.com/Yaffle/EventSource/ */(function(e,t){(function(n){var r=n.setTimeout,i=n.clearTimeout,o=n.XMLHttpRequest,a=n.XDomainRequest,s=n.ActiveXObject,l=n.EventSource,u=n.document,f=n.Promise,d=n.fetch,h=n.Response,v=n.TextDecoder,g=n.TextEncoder,y=n.AbortController;if(typeof window<"u"&&typeof u<"u"&&!("readyState"in u)&&u.body==null&&(u.readyState="loading",window.addEventListener("load",function(se){u.readyState="complete"},!1)),o==null&&s!=null&&(o=function(){return new s("Microsoft.XMLHTTP")}),Object.create==null&&(Object.create=function(se){function pe(){}return pe.prototype=se,new pe}),Date.now||(Date.now=function(){return new Date().getTime()}),y==null){var x=d;d=function(se,pe){var me=pe.signal;return x(se,{headers:pe.headers,credentials:pe.credentials,cache:pe.cache}).then(function(xe){var Te=xe.body.getReader();return me._reader=Te,me._aborted&&me._reader.cancel(),{status:xe.status,statusText:xe.statusText,headers:xe.headers,body:{getReader:function(){return Te}}}})},y=function(){this.signal={_reader:null,_aborted:!1},this.abort=function(){this.signal._reader!=null&&this.signal._reader.cancel(),this.signal._aborted=!0}}}function _(){this.bitsNeeded=0,this.codePoint=0}_.prototype.decode=function(se){function pe(ye,ge,we){if(we===1)return ye>=128>>ge&&ye<=2048>>ge&&ye<=57344>>ge&&ye<=65536>>ge&&ye<>6>15?3:ge>31?2:1;if(ye===6*2)return ge>15?3:2;if(ye===6*3)return 3;throw new Error}for(var xe=65533,Te="",Ce=this.bitsNeeded,Ae=this.codePoint,le=0;le191||!pe(Ae<<6|ce&63,Ce-6,me(Ce,Ae)))&&(Ce=0,Ae=xe,Te+=String.fromCharCode(Ae)),Ce===0?(ce>=0&&ce<=127?(Ce=0,Ae=ce):ce>=192&&ce<=223?(Ce=6*1,Ae=ce&31):ce>=224&&ce<=239?(Ce=6*2,Ae=ce&15):ce>=240&&ce<=247?(Ce=6*3,Ae=ce&7):(Ce=0,Ae=xe),Ce!==0&&!pe(Ae,Ce,me(Ce,Ae))&&(Ce=0,Ae=xe)):(Ce-=6,Ae=Ae<<6|ce&63),Ce===0&&(Ae<=65535?Te+=String.fromCharCode(Ae):(Te+=String.fromCharCode(55296+(Ae-65535-1>>10)),Te+=String.fromCharCode(56320+(Ae-65535-1&1023))))}return this.bitsNeeded=Ce,this.codePoint=Ae,Te};var b=function(){try{return new v().decode(new g().encode("test"),{stream:!0})==="test"}catch(se){console.debug("TextDecoder does not support streaming option. Using polyfill instead: "+se)}return!1};(v==null||g==null||!b())&&(v=_);var w=function(){};function S(se){this.withCredentials=!1,this.readyState=0,this.status=0,this.statusText="",this.responseText="",this.onprogress=w,this.onload=w,this.onerror=w,this.onreadystatechange=w,this._contentType="",this._xhr=se,this._sendTimeout=0,this._abort=w}S.prototype.open=function(se,pe){this._abort(!0);var me=this,xe=this._xhr,Te=1,Ce=0;this._abort=function(we){me._sendTimeout!==0&&(i(me._sendTimeout),me._sendTimeout=0),(Te===1||Te===2||Te===3)&&(Te=4,xe.onload=w,xe.onerror=w,xe.onabort=w,xe.onprogress=w,xe.onreadystatechange=w,xe.abort(),Ce!==0&&(i(Ce),Ce=0),we||(me.readyState=4,me.onabort(null),me.onreadystatechange())),Te=0};var Ae=function(){if(Te===1){var we=0,ke="",Me=void 0;if("contentType"in xe)we=200,ke="OK",Me=xe.contentType;else try{we=xe.status,ke=xe.statusText,Me=xe.getResponseHeader("Content-Type")}catch{we=0,ke="",Me=void 0}we!==0&&(Te=2,me.readyState=2,me.status=we,me.statusText=ke,me._contentType=Me,me.onreadystatechange())}},le=function(){if(Ae(),Te===2||Te===3){Te=3;var we="";try{we=xe.responseText}catch{}me.readyState=3,me.responseText=we,me.onprogress()}},ce=function(we,ke){if((ke==null||ke.preventDefault==null)&&(ke={preventDefault:w}),le(),Te===1||Te===2||Te===3){if(Te=4,Ce!==0&&(i(Ce),Ce=0),me.readyState=4,we==="load")me.onload(ke);else if(we==="error")me.onerror(ke);else if(we==="abort")me.onabort(ke);else throw new TypeError;me.onreadystatechange()}},ye=function(we){xe!=null&&(xe.readyState===4?(!("onload"in xe)||!("onerror"in xe)||!("onabort"in xe))&&ce(xe.responseText===""?"error":"load",we):xe.readyState===3?"onprogress"in xe||le():xe.readyState===2&&Ae())},ge=function(){Ce=r(function(){ge()},500),xe.readyState===3&&le()};"onload"in xe&&(xe.onload=function(we){ce("load",we)}),"onerror"in xe&&(xe.onerror=function(we){ce("error",we)}),"onabort"in xe&&(xe.onabort=function(we){ce("abort",we)}),"onprogress"in xe&&(xe.onprogress=le),"onreadystatechange"in xe&&(xe.onreadystatechange=function(we){ye(we)}),("contentType"in xe||!("ontimeout"in o.prototype))&&(pe+=(pe.indexOf("?")===-1?"?":"&")+"padding=true"),xe.open(se,pe,!0),"readyState"in xe&&(Ce=r(function(){ge()},0))},S.prototype.abort=function(){this._abort(!1)},S.prototype.getResponseHeader=function(se){return this._contentType},S.prototype.setRequestHeader=function(se,pe){var me=this._xhr;"setRequestHeader"in me&&me.setRequestHeader(se,pe)},S.prototype.getAllResponseHeaders=function(){return this._xhr.getAllResponseHeaders!=null&&this._xhr.getAllResponseHeaders()||""},S.prototype.send=function(){if((!("ontimeout"in o.prototype)||!("sendAsBinary"in o.prototype)&&!("mozAnon"in o.prototype))&&u!=null&&u.readyState!=null&&u.readyState!=="complete"){var se=this;se._sendTimeout=r(function(){se._sendTimeout=0,se.send()},4);return}var pe=this._xhr;"withCredentials"in pe&&(pe.withCredentials=this.withCredentials);try{pe.send(void 0)}catch(me){throw me}};function E(se){return se.replace(/[A-Z]/g,function(pe){return String.fromCharCode(pe.charCodeAt(0)+32)})}function P(se){for(var pe=Object.create(null),me=se.split(`\r `),xe=0;xe"u"?typeof window<"u"?window:typeof self<"u"?self:Ys:globalThis)})(bO,bO.exports);var Sfe=bO.exports;const pl=({children:e})=>m.jsx("small",{className:"form-text text-muted d-block",children:e}),Efe=({toggleRealTimeUpdates:e,setRealTimeUpdatesInterval:t})=>{const{enabled:n,interval:r}=jr("realTimeUpdates",{enabled:!0}),i=R.useId();return m.jsxs(Ot,{title:"Real-time updates",className:"h-100",children:[m.jsx(co,{children:m.jsxs(El,{checked:n,onChange:e,children:["Enable or disable real-time updates.",m.jsxs(pl,{children:["Real-time updates are currently being ",m.jsx("b",{children:n?"processed":"ignored"}),"."]})]})}),m.jsxs(Jc,{noMargin:!0,label:"Real-time updates frequency (in minutes):",labelClassName:Pe("form-label",{"text-muted":!n}),id:i,children:[m.jsx(qn,{type:"number",min:0,placeholder:"Immediate",disabled:!n,value:`${r??""}`,id:i,onChange:({target:o})=>t(Number(o.value))}),n&&m.jsx(pl,{children:r?m.jsxs("span",{children:["Updates will be reflected in the UI every ",m.jsx("b",{children:r})," minute",r>1&&"s","."]}):"Updates will be reflected in the UI as soon as they happen."})]})]})},F_=e=>e==="includes"?"Suggest tags including input":"Suggest tags starting with input",Pfe=e=>e==="includes"?m.jsxs(m.Fragment,{children:["The list of suggested tags will contain those ",m.jsx("b",{children:"including"})," provided input."]}):m.jsxs(m.Fragment,{children:["The list of suggested tags will contain those ",m.jsx("b",{children:"starting with"})," provided input."]}),Cfe=({updateShortUrlCreationSettings:e})=>{const t=jr("shortUrlCreation",{validateUrls:!1}),n=r=>()=>e({...t??{validateUrls:!1},tagFilteringMode:r});return m.jsxs(Ot,{title:"Short URLs form",className:"h-100",children:[m.jsx(co,{children:m.jsxs(El,{checked:t.validateUrls??!1,onChange:r=>e({...t,validateUrls:r}),children:["Request validation on long URLs when creating new short URLs."," ",m.jsxs("b",{children:["This option is ignored by Shlink ",">=","4.0.0"]}),m.jsxs(pl,{children:["The initial state of the ",m.jsx("b",{children:"Validate URL"})," checkbox will be ",m.jsx("b",{children:t.validateUrls?"checked":"unchecked"}),"."]})]})}),m.jsx(co,{children:m.jsxs(El,{checked:t.forwardQuery??!0,onChange:r=>e({...t,forwardQuery:r}),children:["Make all new short URLs forward their query params to the long URL.",m.jsxs(pl,{children:["The initial state of the ",m.jsx("b",{children:"Forward query params on redirect"})," checkbox will be ",m.jsx("b",{children:t.forwardQuery??!0?"checked":"unchecked"}),"."]})]})}),m.jsxs(Jc,{noMargin:!0,label:"Tag suggestions search mode:",children:[m.jsxs(fa,{text:F_(t.tagFilteringMode),children:[m.jsx(Ne,{active:!t.tagFilteringMode||t.tagFilteringMode==="startsWith",onClick:n("startsWith"),children:F_("startsWith")}),m.jsx(Ne,{active:t.tagFilteringMode==="includes",onClick:n("includes"),children:F_("includes")})]}),m.jsx(pl,{children:Pfe(t.tagFilteringMode)})]})]})},Tfe={dateCreated:"Created at",shortCode:"Short URL",longUrl:"Long URL",title:"Title",visits:"Visits"},jfe=({updateShortUrlsListSettings:e,defaultOrdering:t})=>{const n=jr("shortUrlsList");return m.jsx(Ot,{title:"Short URLs list",className:"h-100",children:m.jsx(Jc,{noMargin:!0,label:"Default ordering for short URLs list:",children:m.jsx(zp,{items:Tfe,order:(n==null?void 0:n.defaultOrdering)??t,onChange:(r,i)=>e({defaultOrdering:{field:r,dir:i}})})})})},Afe={tag:"Tag",shortUrls:"Short URLs",visits:"Visits"},kfe=({updateTagsSettings:e})=>{const t=jr("tags",{});return m.jsx(Ot,{title:"Tags",className:"h-100",children:m.jsx(Jc,{noMargin:!0,label:"Default ordering for tags list:",children:m.jsx(zp,{items:Afe,order:t.defaultOrdering??{},onChange:(n,r)=>e({...t,defaultOrdering:{field:n,dir:r}})})})})},Nfe=({updateUiSettings:e,_matchMedia:t})=>{const n=jr("ui"),r=R.useMemo(()=>(n==null?void 0:n.theme)??nC(t),[n==null?void 0:n.theme,t]);return m.jsxs(Ot,{title:"User interface",className:"h-100",children:[m.jsx(je,{icon:r==="dark"?JZ:BZ,className:"float-end mt-1"}),m.jsx(El,{checked:r==="dark",onChange:i=>{e({...n,theme:i?"dark":"light"})},children:"Use dark theme."})]})},gF={today:"Today",yesterday:"Yesterday",last7Days:"Last 7 days",last30Days:"Last 30 days",last90Days:"Last 90 days",last180Days:"Last 180 days",last365Days:"Last 365 days"},Mfe=(e,t)=>!e||e==="all"?t:gF[e],Rfe=({onChange:e,active:t,allText:n})=>m.jsxs(fa,{text:Mfe(t,n),children:[m.jsx(Ne,{active:t==="all",onClick:()=>e("all"),children:n}),m.jsx(Ne,{divider:!0}),Object.entries(gF).map(([r,i])=>m.jsx(Ne,{active:t===r,onClick:()=>e(r),children:i},r))]}),LN=e=>(e==null?void 0:e.defaultInterval)??"last30Days",Lfe=({updateVisitsSettings:e})=>{const t=jr("visits"),n=R.useCallback(({defaultInterval:r,...i})=>e({defaultInterval:r??LN(t),...i}),[e,t]);return m.jsxs(Ot,{title:"Visits",className:"h-100",children:[m.jsx(co,{children:m.jsxs(El,{checked:!!(t!=null&&t.excludeBots),onChange:r=>n({excludeBots:r}),children:["Exclude bots wherever possible (this option‘s effect might depend on Shlink server‘s version).",m.jsxs(pl,{children:["The visits coming from potential bots will be ",m.jsx("b",{children:t!=null&&t.excludeBots?"excluded":"included"}),"."]})]})}),m.jsx(co,{children:m.jsxs(El,{checked:!!(t!=null&&t.loadPrevInterval),onChange:r=>n({loadPrevInterval:r}),children:["Compare visits with previous period.",m.jsxs(pl,{children:["When loading visits, previous period ",m.jsx("b",{children:t!=null&&t.loadPrevInterval?"will":"won't"})," be loaded by default."]})]})}),m.jsx(Jc,{noMargin:!0,label:"Default interval to load on visits sections:",children:m.jsx(Rfe,{allText:"All visits",active:LN(t),onChange:r=>n({defaultInterval:r})})})]})},B_=({items:e})=>m.jsx(m.Fragment,{children:e.map((t,n)=>m.jsx("div",{className:"mb-3",children:t},n))}),$fe=({settings:e,updateSettings:t,defaultShortUrlsListOrdering:n})=>{const r=R.useCallback(s=>t(db(e,s)),[e,t]),i=R.useCallback(s=>r({realTimeUpdates:{enabled:s}}),[r]),o=R.useCallback(s=>r({realTimeUpdates:{interval:s}}),[r]),a=R.useCallback((s,l)=>r({[s]:l}),[r]);return m.jsxs(_F,{value:e,children:[m.jsxs(D8,{className:"mb-3",children:[m.jsx(Fd,{to:"general",children:"General"}),m.jsx(Fd,{to:"short-urls",children:"Short URLs"}),m.jsx(Fd,{to:"other-items",children:"Other items"})]}),m.jsxs(K0,{children:[m.jsx(lt,{path:"general",element:m.jsx(B_,{items:[m.jsx(Nfe,{updateUiSettings:s=>a("ui",s)}),m.jsx(Efe,{toggleRealTimeUpdates:i,setRealTimeUpdatesInterval:o})]})}),m.jsx(lt,{path:"short-urls",element:m.jsx(B_,{items:[m.jsx(Cfe,{updateShortUrlCreationSettings:s=>a("shortUrlCreation",s)}),m.jsx(jfe,{defaultOrdering:n,updateShortUrlsListSettings:s=>a("shortUrlsList",s)})]})}),m.jsx(lt,{path:"other-items",element:m.jsx(B_,{items:[m.jsx(kfe,{updateTagsSettings:s=>a("tags",s)}),m.jsx(Lfe,{updateVisitsSettings:s=>a("visits",s)})]})}),m.jsx(lt,{path:"*",element:m.jsx(oP,{replace:!0,to:"general"})})]})]})},yF={realTimeUpdates:{enabled:!0},shortUrlCreation:{validateUrls:!1},visits:{defaultInterval:"last30Days"},shortUrlsList:{defaultOrdering:{field:"dateCreated",dir:"DESC"}}},bF=R.createContext(yF),{Provider:_F}=bF,pC=()=>R.useContext(bF)??yF;function jr(e,t){return pC()[e]??t}var Ife={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 135.1c-4.2-4.5-10.1-7.1-16.3-7.1C266 128 256 138 256 150.3V208H160c-17.7 0-32 14.3-32 32v32c0 17.7 14.3 32 32 32h96v57.7c0 12.3 10 22.3 22.3 22.3c6.2 0 12.1-2.6 16.3-7.1l99.9-107.1c3.5-3.8 5.5-8.7 5.5-13.8s-2-10.1-5.5-13.8L294.6 135.1z"]},Dfe=Ife,Ffe={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"]},xF={prefix:"far",iconName:"clone",icon:[512,512,[],"f24d","M64 464H288c8.8 0 16-7.2 16-16V384h48v64c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64V224c0-35.3 28.7-64 64-64h64v48H64c-8.8 0-16 7.2-16 16V448c0 8.8 7.2 16 16 16zM224 304H448c8.8 0 16-7.2 16-16V64c0-8.8-7.2-16-16-16H224c-8.8 0-16 7.2-16 16V288c0 8.8 7.2 16 16 16zm-64-16V64c0-35.3 28.7-64 64-64H448c35.3 0 64 28.7 64 64V288c0 35.3-28.7 64-64 64H224c-35.3 0-64-28.7-64-64z"]};const Bfe=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,$N=e=>{if(typeof e!="string")throw new TypeError("Invalid argument expected string");const t=e.match(Bfe);if(!t)throw new Error(`Invalid argument not valid semver ('${e}' received)`);return t.shift(),t},IN=e=>e==="*"||e==="x"||e==="X",DN=e=>{const t=parseInt(e,10);return isNaN(t)?e:t},Ufe=(e,t)=>typeof e!=typeof t?[String(e),String(t)]:[e,t],zfe=(e,t)=>{if(IN(e)||IN(t))return 0;const[n,r]=Ufe(DN(e),DN(t));return n>r?1:n{for(let n=0;n{const n=$N(e),r=$N(t),i=n.pop(),o=r.pop(),a=FN(n,r);return a!==0?a:i&&o?FN(i.split("."),o.split(".")):i||o?i?-1:1:0},_O=(e,t,n)=>{Wfe(n);const r=Vfe(e,t);return wF[n].includes(r)},wF={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},BN=Object.keys(wF),Wfe=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(BN.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${BN.join("|")}`)};var Hfe={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"]},Gfe={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"]};const zs={Enter:"Enter",Escape:"Escape",Tab:"Tab",Backspace:"Backspace",UpArrow:"ArrowUp",UpArrowCompat:"Up",DownArrow:"ArrowDown",DownArrowCompat:"Down",PageDown:"PageDown",PageUp:"PageUp"},mC=Symbol("Create new tag"),OF=Symbol("No options"),gu=()=>{},Tn=V.createContext(void 0);function UN(e,t){return e===t?[]:e.filter(n=>!t.includes(n))}function qfe(e){return e.selectionStart===0&&e.selectionEnd===0}function Kfe(e){const t=e.value.length;return e.selectionStart===t&&e.selectionEnd===t}function hb(e){return`${e}-label`}function Yfe(e){return`${e}-combobox`}function Zfe(e){return`${e}-input`}function SF(e){return`${e}-listbox`}function EF(e,t){return`${e}-option-${rde(t)}`}function Xfe(e,t){if((e==null?void 0:e.value)===mC&&e.disabled===!1)return{value:t,label:t}}function Qfe(e){const t=Xfe(e.activeOption,e.value)||e.activeOption||sde(e.value,e.options);return t&&!t.disabled?t:void 0}function Jfe(e,t,n){const r=t-1;return e>r?n:en===e.value)}const ide=/[-\\^$*+?.()|[\]{}]/g;function PF(e){return e.replace(ide,"\\$&")}function CF(e){return new RegExp(PF(e),"i")}function ode(e){return new RegExp(`^${PF(e)}$`,"i")}function ade(e,t){if(e){const n=CF(e);return t.filter(r=>n.test(r.label))}else return[].concat(t)}function sde(e,t){const n=ode(e);return t.find(r=>n.test(r.label))||null}const lde={autoComplete:"off",autoCorrect:"off","data-form-type":"other",spellCheck:!1};function ude({allowBackspace:e,ariaDescribedBy:t,ariaErrorMessage:n,delimiterKeys:r}){const{id:i,comboBoxRef:o,inputRef:a,isDisabled:s,isInvalid:l,managerRef:u}=R.useContext(Tn),f=R.useMemo(()=>{const g=k=>{const I=k.currentTarget.value;u.current.updateInputValue(I),document.activeElement===a.current&&u.current.listBoxExpand(I)},y=()=>{u.current.listBoxExpand()},x=k=>{var I;((I=o.current)==null?void 0:I.contains(k.relatedTarget))===!1&&u.current.listBoxCollapse()},_=()=>{u.current.listBoxExpand()},b=k=>{const{activeIndex:I,isExpanded:F}=u.current.state;F?(k.preventDefault(),u.current.updateActiveIndex(I+1)):(Kfe(k.currentTarget)||k.altKey)&&(k.preventDefault(),u.current.listBoxExpand())},w=k=>{const{activeIndex:I,isExpanded:F}=u.current.state;F?(k.preventDefault(),u.current.updateActiveIndex(I-1)):qfe(k.currentTarget)&&(k.preventDefault(),u.current.listBoxExpand())},S=k=>{const{isExpanded:I,options:F}=u.current.state;I&&(k.preventDefault(),u.current.updateActiveIndex(F.length-1))},E=k=>{u.current.state.isExpanded&&(k.preventDefault(),u.current.updateActiveIndex(0))},P=()=>{u.current.state.isExpanded?u.current.listBoxCollapse():u.current.updateInputValue("")},T=()=>{if(e){const{value:k,selected:I}=u.current.state,F=I[I.length-1];k===""&&F&&u.current.selectTag(F)}},A=k=>{u.current.state.isExpanded&&(k.preventDefault(),u.current.selectTag())};return{onBlur:x,onChange:g,onClick:_,onFocus:y,onKeyDown:k=>{if(k.key===zs.UpArrow)return w(k);if(k.key===zs.DownArrow)return b(k);if(k.key===zs.PageUp)return E(k);if(k.key===zs.PageDown)return S(k);if(k.key===zs.Escape)return P();if(k.key===zs.Backspace)return T();if(r.includes(k.key))return A(k)}}},[e,o,r,a,u]),{activeOption:d,isExpanded:h,value:v}=u.current.state;return{...lde,"aria-autocomplete":"list","aria-activedescendant":d?EF(i,d):void 0,"aria-controls":SF(i),"aria-describedby":t||void 0,"aria-disabled":s,"aria-errormessage":l&&n||void 0,"aria-invalid":l,"aria-labelledby":hb(i),"aria-expanded":h,id:Zfe(i),onBlur:s?gu:f.onBlur,onChange:s?gu:f.onChange,onClick:s?gu:f.onClick,onFocus:s?gu:f.onFocus,onKeyDown:s?gu:f.onKeyDown,ref:a,role:"combobox",type:"text",value:v}}const cde={position:"absolute",width:0,height:0,visibility:"hidden",overflow:"scroll",whiteSpace:"pre"},fde=["font-family","font-size","font-style","font-weight","letter-spacing","text-transform"];function dde({allowResize:e=!0,text:t}){const n=R.useRef(null),{inputRef:r}=R.useContext(Tn),[i,o]=R.useState(null);return R.useLayoutEffect(()=>{if(e&&r.current&&n.current&&window.getComputedStyle){const a=window.getComputedStyle(r.current);fde.forEach(s=>{const l=a.getPropertyValue(s);n.current.style.setProperty(s,l)})}},[e,r,n]),R.useLayoutEffect(()=>{var a;if(e){const s=Math.ceil(((a=n.current)==null?void 0:a.scrollWidth)??0)+2;i!==s&&o(s)}},[e,t,i]),{width:i,sizerProps:{ref:n,style:cde}}}function hde(){const{id:e,inputRef:t,listBoxRef:n,managerRef:r}=R.useContext(Tn),i=r.current.state.activeIndex===-1,o=R.useCallback(a=>{var s;a.target!==t.current&&((s=t.current)==null||s.focus({preventScroll:!0}))},[t]);return R.useEffect(()=>{var a;i&&((a=n.current)==null||a.scrollTo({top:0}))},[n,i]),{"aria-labelledby":hb(e),id:SF(e),onFocus:o,ref:n,role:"listbox",tabIndex:-1}}function pde({activateFirstOption:e,allowNew:t,collapseOnSelect:n,newOptionText:r,noOptionsText:i,onAdd:o,onDelete:a,onCollapse:s,onExpand:l,onInput:u,onShouldCollapse:f,onShouldExpand:d,onValidate:h,selected:v,suggestions:g,suggestionsTransform:y}){const x=R.useRef(),[_,b]=R.useState(null),[w,S]=R.useState(!1),[E,P]=R.useState(""),T=R.useMemo(()=>{const W=y(E,g);return E&&(t&&W.push({disabled:h?!h(E):!1,label:r,value:mC}),W.length===0&&W.push({disabled:!0,label:i,value:OF})),W},[t,r,i,h,g,y,E]),A=_?wO(_,T):-1,D=e?Math.max(A,0):A,k=T[D],I={activeIndex:D,activeOption:k,isExpanded:w,options:T,selected:v,value:E},F={tagsAdded:x.current?UN(v,x.current.state.selected):[],tagsDeleted:x.current?UN(x.current.state.selected,v):[]},q={listBoxCollapse(W){w&&(!f||f(W??I.value))&&(S(!1),b(null),s==null||s())},listBoxExpand(W){w||(!d||d(W??I.value))&&(S(!0),b(T[D]),l==null||l())},updateActiveIndex(W){const X=Jfe(W,T.length,e?0:-1);b(T[X])},updateInputValue(W){E!==W&&(P(W),u==null||u(W))},selectTag(W){if(W??(W=Qfe(I)),W){const X=wO(W,I.selected);X>-1?a(X):o(W),n&&this.listBoxCollapse(),this.updateInputValue("")}}};return x.current={...q,flags:F,state:I},x}function mde(e){const{id:t,inputRef:n,listBoxRef:r,managerRef:i}=R.useContext(Tn),o=R.useRef(null),a=i.current.state.options[e],s=e===i.current.state.activeIndex,l=a.disabled??!1,u=wO(a,i.current.state.selected)>-1,f=R.useCallback(()=>{var h;i.current.selectTag(),(h=n.current)==null||h.focus()},[n,i]),d=R.useCallback(()=>{e!==i.current.state.activeIndex&&i.current.updateActiveIndex(e)},[e,i]);return yde(o,r,s),{option:{...a,active:s,disabled:l,index:e,selected:u},optionProps:{"aria-disabled":l,"aria-posinset":e+1,"aria-selected":l?void 0:u,"aria-setsize":i.current.state.options.length,id:EF(t,a),onClick:f,onMouseDown:d,ref:o,role:"option",tabIndex:-1}}}function vde({inputRef:e,managerRef:t}){return R.useRef({input:{blur(){var r;(r=e.current)==null||r.blur()},focus(){var r;(r=e.current)==null||r.focus()},get value(){return t.current.state.value},set value(r){typeof r!="string"&&(r=String(r)),t.current.updateInputValue(r)}},listBox:{collapse(){t.current.listBoxCollapse()},expand(){t.current.listBoxExpand()},get activeOption(){return t.current.state.activeOption},get isExpanded(){return t.current.state.isExpanded}},select(r){t.current.selectTag(r)}}).current}function gde({onBlur:e,onFocus:t}){const[n,r]=R.useState(!1),{id:i,inputRef:o,rootRef:a}=R.useContext(Tn),s=R.useMemo(()=>({"aria-describedby":hb(i),id:i,onFocus(){r(!0),t==null||t()},onBlur(){var l;(l=a.current)!=null&&l.contains(document.activeElement)||(r(!1),e==null||e())},onClick(){var l;document.activeElement===a.current&&((l=o.current)==null||l.focus())},ref:a,tabIndex:-1}),[o,i,e,t,a]);return{isActive:n,rootProps:s}}function yde(e,t,n){R.useEffect(()=>{var r,i,o,a;if(n){const s=(r=e.current)==null?void 0:r.offsetHeight,l=(i=e.current)==null?void 0:i.offsetTop,u=(o=t.current)==null?void 0:o.offsetHeight,f=(a=t.current)==null?void 0:a.scrollTop;lf+u&&t.current.scrollTo(0,l+s-u)}},[n,t,e])}function bde(e,t){const{isDisabled:n,managerRef:r}=R.useContext(Tn),i=r.current.state.selected[e],o=R.useCallback(()=>r.current.selectTag(i),[r,i]);return{tag:i,tagProps:{"aria-disabled":n,title:wy(t,i.label),onClick:n?gu:o}}}function _de(){var e;const{rootRef:t,managerRef:n}=R.useContext(Tn),r=R.useRef(),i=n.current.flags.tagsDeleted[0],o=(e=r.current)==null?void 0:e.contains(document.activeElement);return R.useLayoutEffect(()=>{var a,s;if(i){const l=(a=r.current)==null?void 0:a.contains(document.activeElement);o&&!l&&((s=t.current)==null||s.focus({preventScroll:!0}))}},[o,r,t,i]),{listRef:r}}const xde={position:"absolute",width:1,height:1,left:-9999,overflow:"hidden",clip:"rect(0 0 0 0)"};function wde({ariaAddedText:e,ariaDeletedText:t}){const{managerRef:n}=R.useContext(Tn),r=R.useRef([]);return n.current.flags.tagsAdded.forEach(i=>{r.current.push(wy(e,i.label))}),n.current.flags.tagsDeleted.forEach(i=>{r.current.push(wy(t,i.label))}),V.createElement("div",{"aria-live":"polite","aria-relevant":"additions",role:"status",style:xde},r.current.join(` `))}function Ode({children:e}){const{classNames:t,comboBoxRef:n,id:r}=R.useContext(Tn);return V.createElement("div",{className:t.comboBox,id:Yfe(r),ref:n},e)}const Sde=({classNames:e,text:t})=>V.createElement("mark",{className:e.highlight},t);function Ede({option:e,query:t,render:n=Sde}){const{classNames:r}=R.useContext(Tn);if(e.value===mC||e.value===OF)return V.createElement(V.Fragment,null,wy(e.label,t));if(t){const i=tde(e.label,t);if(i){const o=n({text:i[1],classNames:r});return V.createElement(V.Fragment,null,i[0],o,i[2])}}return V.createElement(V.Fragment,null,e.label)}const Pde=V.memo(Ede),Cde=({classNames:e,inputWidth:t,...n})=>V.createElement("input",{className:e.input,style:{width:t},...n});function Tde({allowBackspace:e=!0,allowResize:t=!0,ariaDescribedBy:n,ariaErrorMessage:r,delimiterKeys:i,placeholderText:o,render:a=Cde}){const{classNames:s}=R.useContext(Tn),{value:l,...u}=ude({allowBackspace:e,ariaDescribedBy:n,ariaErrorMessage:r,delimiterKeys:i}),f=l.lengthV.createElement("div",{className:t.label,id:n},e);function Ade({children:e,render:t=jde}){const{classNames:n,id:r}=R.useContext(Tn);return t({children:e,classNames:n,id:hb(r)})}const kde=({children:e,classNames:t,...n})=>V.createElement("div",{className:t.listBox,...n},e);function Nde({children:e,render:t=kde}){const{classNames:n,managerRef:r}=R.useContext(Tn),i=hde();return!r.current.state.isExpanded||V.Children.count(e)===0?null:t({children:e,classNames:n,...i})}const Mde=({children:e,classNames:t,option:n,...r})=>{const i=[t.option];return n.active&&i.push(t.optionIsActive),V.createElement("div",{className:i.join(" "),...r},e)};function Rde({children:e,index:t,render:n=Mde}){const{classNames:r}=R.useContext(Tn),{option:i,optionProps:o}=mde(t);return n({classNames:r,children:e,option:i,...o})}const Lde=({children:e,classNames:t,isActive:n,isDisabled:r,isInvalid:i,...o})=>{const a=[t.root];return n&&a.push(t.rootIsActive),r&&a.push(t.rootIsDisabled),i&&a.push(t.rootIsInvalid),V.createElement("div",{className:a.join(" "),...o},e)};function $de({children:e,onBlur:t,onFocus:n,render:r=Lde}){const{classNames:i,isDisabled:o,isInvalid:a}=R.useContext(Tn),{isActive:s,rootProps:l}=gde({onBlur:t,onFocus:n});return r({children:e,classNames:i,isActive:s,isDisabled:o,isInvalid:a,...l})}const Ide=({classNames:e,tag:t,...n})=>V.createElement("button",{type:"button",className:e.tag,...n},V.createElement("span",{className:e.tagName},t.label));function Dde({render:e=Ide,index:t,title:n}){const{classNames:r}=R.useContext(Tn),{tag:i,tagProps:o}=bde(t,n);return e({classNames:r,tag:i,...o})}function Fde({children:e,label:t}){const{classNames:n}=R.useContext(Tn),{listRef:r}=_de();return V.createElement("ul",{className:n.tagList,"aria-label":t,ref:r,role:"list"},e.map(i=>V.createElement("li",{className:n.tagListItem,key:i.key,role:"listitem"},i)))}const Bde={root:"react-tags",rootIsActive:"is-active",rootIsDisabled:"is-disabled",rootIsInvalid:"is-invalid",label:"react-tags__label",tagList:"react-tags__list",tagListItem:"react-tags__list-item",tag:"react-tags__tag",tagName:"react-tags__tag-name",comboBox:"react-tags__combobox",input:"react-tags__combobox-input",listBox:"react-tags__listbox",option:"react-tags__listbox-option",optionIsActive:"is-active",highlight:"react-tags__listbox-option-highlight"},Ude=[zs.Enter];function zde({activateFirstOption:e=!1,allowBackspace:t=!0,allowNew:n=!1,allowResize:r=!0,ariaAddedText:i="Added tag %value%",ariaDescribedBy:o,ariaErrorMessage:a,ariaDeletedText:s="Removed tag %value%",classNames:l=Bde,collapseOnSelect:u=!1,deleteButtonText:f="Remove %value% from the list",delimiterKeys:d=Ude,id:h="react-tags",isDisabled:v=!1,isInvalid:g=!1,labelText:y="Select tags",newOptionText:x="Add %value%",noOptionsText:_="No options found for %value%",onAdd:b,onBlur:w,onCollapse:S,onDelete:E,onExpand:P,onFocus:T,onInput:A,onShouldCollapse:D,onShouldExpand:k,onValidate:I,placeholderText:F="Add a tag",renderHighlight:q,renderInput:W,renderLabel:X,renderListBox:Q,renderOption:ne,renderRoot:Z,renderTag:z,selected:B=[],suggestions:H=[],suggestionsTransform:ee=ade,tagListLabelText:K="Selected tags"},te){const ie=R.useRef(null),ae=R.useRef(null),fe=R.useRef(null),j=R.useRef(null),N=pde({activateFirstOption:e,allowNew:n,collapseOnSelect:u,newOptionText:x,noOptionsText:_,onAdd:b,onDelete:E,onCollapse:S,onExpand:P,onInput:A,onShouldCollapse:D,onShouldExpand:k,onValidate:I,selected:B,suggestions:H,suggestionsTransform:ee}),U=vde({inputRef:ae,managerRef:N});return te&&(typeof te=="function"?te(U):te.current=U),V.createElement(Tn.Provider,{value:{classNames:l,comboBoxRef:ie,id:h,inputRef:ae,isDisabled:v,isInvalid:g,listBoxRef:fe,managerRef:N,rootRef:j}},V.createElement($de,{onBlur:w,onFocus:T,render:Z},V.createElement(Ade,{render:X},y),V.createElement(Fde,{label:K},N.current.state.selected.map((J,Y)=>V.createElement(Dde,{key:xO(J),index:Y,render:z,title:f}))),V.createElement(Ode,null,V.createElement(Tde,{allowBackspace:t,allowResize:r,ariaDescribedBy:o,ariaErrorMessage:a,delimiterKeys:d,placeholderText:F,render:W}),V.createElement(Nde,{render:Q},N.current.state.options.map((J,Y)=>V.createElement(Rde,{key:xO(J),index:Y,render:ne},V.createElement(Pde,{option:J,query:N.current.state.value,render:q}))))),V.createElement(wde,{ariaAddedText:i,ariaDeletedText:s})))}const Vde=V.forwardRef(zde);function U_(e){return e==null?"":`${e}`}function Wde(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 vC(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 Hde(e={stringFormatter:vC()}){return t=>e.stringFormatter(t.toString().slice(7,-1))}function Gde(e={stringFormatter:vC()}){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 qde=RegExp(`[^.[\\]]+|\\[(?:([^"'][^[]*)|(["'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))`,"g");function Kde(e){var t,n,r;const i=[];let o;for(;o=qde.exec(e);)i.push((r=(t=o[3])!==null&&t!==void 0?t:(n=o[1])===null||n===void 0?void 0:n.trim())!==null&&r!==void 0?r:o[0]);return i}function zN(e,t,n){if(t in e){const o=e[t];return o===void 0?n:o}const r=Array.isArray(t)?t:Kde(t);let i=e;for(const o of r)if(i=i==null?void 0:i[o],i===void 0)return n;return i}function TF(e,t){try{return Array.isArray(t)?e.push(...t):e.push(t),e}catch{return e.concat(t)}}function OO(e,t){let n=!0;return e.reduce((r,i)=>(i==null&&(i=""),n?(n=!1,`${i}`):`${r}${t}${i}`),"")}var VN;(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"})(VN||(VN={}));class Yde{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||vC(),i=Gde({stringFormatter:r}),o={header:r,undefined:U_,boolean:U_,number:Wde(),bigint:U_,string:r,symbol:Hde({stringFormatter:r}),function:i,object:i};return n.formatters=Object.assign(Object.assign({},o),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=>zN(i,r,n)};if(typeof r=="object"){const i="default"in r?r.default:n;if(typeof r.value=="string"){const o=r.value;return{label:r.label||r.value,value:a=>zN(a,o,i)}}if(typeof r.value=="function"){const o=r.label||r.value.name||"",a={label:o,default:i},s=r.value;return{label:o,value(l){const u=s(l,a);return u===void 0?i:u}}}}throw new Error("Invalid field info option. "+JSON.stringify(r))})}getHeader(){return OO(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(TF,[]),[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 OO(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 jF extends Yde{constructor(t){super(t)}parse(t){const n=this.preprocessData(t);this.opts.fields=this.opts.fields||this.preprocessFieldsInfo(n.reduce((a,s)=>(Object.keys(s).forEach(l=>{a.includes(l)||a.push(l)}),a),[]),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(TF,[])}processData(t){return OO(t.map(n=>this.processRow(n)).filter(n=>n),this.opts.eol)}}var xn;(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"})(xn||(xn={}));xn.QUOTATION_MARK+"",xn.QUOTATION_MARK,xn.REVERSE_SOLIDUS+"",xn.REVERSE_SOLIDUS,xn.SOLIDUS+"",xn.SOLIDUS,xn.LATIN_SMALL_LETTER_B+"",xn.BACKSPACE,xn.LATIN_SMALL_LETTER_F+"",xn.FORM_FEED,xn.LATIN_SMALL_LETTER_N+"",xn.NEWLINE,xn.LATIN_SMALL_LETTER_R+"",xn.CARRIAGE_RETURN,xn.LATIN_SMALL_LETTER_T+"",xn.TAB;var WN;(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"})(WN||(WN={}));var HN;(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"})(HN||(HN={}));var GN;(function(e){e[e.OBJECT=0]="OBJECT",e[e.ARRAY=1]="ARRAY"})(GN||(GN={}));var qN;(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"})(qN||(qN={}));var Zde=Array.isArray,Ar=Zde,Xde=typeof Ys=="object"&&Ys&&Ys.Object===Object&&Ys,AF=Xde,Qde=AF,Jde=typeof self=="object"&&self&&self.Object===Object&&self,ehe=Qde||Jde||Function("return this")(),To=ehe,the=To,nhe=the.Symbol,Wp=nhe,KN=Wp,kF=Object.prototype,rhe=kF.hasOwnProperty,ihe=kF.toString,Xf=KN?KN.toStringTag:void 0;function ohe(e){var t=rhe.call(e,Xf),n=e[Xf];try{e[Xf]=void 0;var r=!0}catch{}var i=ihe.call(e);return r&&(t?e[Xf]=n:delete e[Xf]),i}var ahe=ohe,she=Object.prototype,lhe=she.toString;function uhe(e){return lhe.call(e)}var che=uhe,YN=Wp,fhe=ahe,dhe=che,hhe="[object Null]",phe="[object Undefined]",ZN=YN?YN.toStringTag:void 0;function mhe(e){return e==null?e===void 0?phe:hhe:ZN&&ZN in Object(e)?fhe(e):dhe(e)}var da=mhe;function vhe(e){return e!=null&&typeof e=="object"}var ha=vhe,ghe=da,yhe=ha,bhe="[object Symbol]";function _he(e){return typeof e=="symbol"||yhe(e)&&ghe(e)==bhe}var tf=_he,xhe=Ar,whe=tf,Ohe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,She=/^\w*$/;function Ehe(e,t){if(xhe(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||whe(e)?!0:She.test(e)||!Ohe.test(e)||t!=null&&e in Object(t)}var gC=Ehe;function Phe(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var bs=Phe;const nf=st(bs);var Che=da,The=bs,jhe="[object AsyncFunction]",Ahe="[object Function]",khe="[object GeneratorFunction]",Nhe="[object Proxy]";function Mhe(e){if(!The(e))return!1;var t=Che(e);return t==Ahe||t==khe||t==jhe||t==Nhe}var yC=Mhe;const We=st(yC);var Rhe=To,Lhe=Rhe["__core-js_shared__"],$he=Lhe,z_=$he,XN=function(){var e=/[^.]+$/.exec(z_&&z_.keys&&z_.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Ihe(e){return!!XN&&XN in e}var Dhe=Ihe,Fhe=Function.prototype,Bhe=Fhe.toString;function Uhe(e){if(e!=null){try{return Bhe.call(e)}catch{}try{return e+""}catch{}}return""}var NF=Uhe,zhe=yC,Vhe=Dhe,Whe=bs,Hhe=NF,Ghe=/[\\^$.*+?()[\]{}|]/g,qhe=/^\[object .+?Constructor\]$/,Khe=Function.prototype,Yhe=Object.prototype,Zhe=Khe.toString,Xhe=Yhe.hasOwnProperty,Qhe=RegExp("^"+Zhe.call(Xhe).replace(Ghe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Jhe(e){if(!Whe(e)||Vhe(e))return!1;var t=zhe(e)?Qhe:qhe;return t.test(Hhe(e))}var epe=Jhe;function tpe(e,t){return e==null?void 0:e[t]}var npe=tpe,rpe=epe,ipe=npe;function ope(e,t){var n=ipe(e,t);return rpe(n)?n:void 0}var Il=ope,ape=Il,spe=ape(Object,"create"),pb=spe,QN=pb;function lpe(){this.__data__=QN?QN(null):{},this.size=0}var upe=lpe;function cpe(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var fpe=cpe,dpe=pb,hpe="__lodash_hash_undefined__",ppe=Object.prototype,mpe=ppe.hasOwnProperty;function vpe(e){var t=this.__data__;if(dpe){var n=t[e];return n===hpe?void 0:n}return mpe.call(t,e)?t[e]:void 0}var gpe=vpe,ype=pb,bpe=Object.prototype,_pe=bpe.hasOwnProperty;function xpe(e){var t=this.__data__;return ype?t[e]!==void 0:_pe.call(t,e)}var wpe=xpe,Ope=pb,Spe="__lodash_hash_undefined__";function Epe(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Ope&&t===void 0?Spe:t,this}var Ppe=Epe,Cpe=upe,Tpe=fpe,jpe=gpe,Ape=wpe,kpe=Ppe;function rf(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1}var Kpe=qpe,Ype=mb;function Zpe(e,t){var n=this.__data__,r=Ype(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var Xpe=Zpe,Qpe=Rpe,Jpe=zpe,eme=Hpe,tme=Kpe,nme=Xpe;function of(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t0?1:-1},nl=function(t){return Hp(t)&&t.indexOf("%")===t.length-1},Ee=function(t){return Pve(t)&&!sf(t)},pn=function(t){return Ee(t)||Hp(t)},Ave=0,_s=function(t){var n=++Ave;return"".concat(t||"").concat(n)},ar=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(!Ee(t)&&!Hp(t))return r;var o;if(nl(t)){var a=t.indexOf("%");o=n*parseFloat(t.slice(0,a))/100}else o=+t;return sf(o)&&(o=r),i&&o>n&&(o=n),o},Na=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},kve=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Dve(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function PO(e){"@babel/helpers - typeof";return PO=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},PO(e)}var oM={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"},Wo=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},aM=null,W_=null,jC=function e(t){if(t===aM&&Array.isArray(W_))return W_;var n=[];return R.Children.forEach(t,function(r){ze(r)||(SO.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),W_=n,aM=t,n};function cr(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(i){return Wo(i)}):r=[Wo(t)],jC(e).forEach(function(i){var o=Br(i,"type.displayName")||Br(i,"type.name");r.indexOf(o)!==-1&&n.push(i)}),n}function Lr(e,t){var n=cr(e,t);return n&&n[0]}var sM=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,i=n.height;return!(!Ee(r)||r<=0||!Ee(i)||i<=0)},Fve=["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"],Bve=function(t){return t&&t.type&&Hp(t.type)&&Fve.indexOf(t.type)>=0},zF=function(t){return t&&PO(t)==="object"&&"cx"in t&&"cy"in t&&"r"in t},Uve=function(t,n,r,i){var o,a=(o=V_==null?void 0:V_[i])!==null&&o!==void 0?o:[];return!We(t)&&(i&&a.includes(n)||Rve.includes(n))||r&&TC.includes(n)},De=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(R.isValidElement(t)&&(i=t.props),!nf(i))return null;var o={};return Object.keys(i).forEach(function(a){var s;Uve((s=i)===null||s===void 0?void 0:s[a],a,n,r)&&(o[a]=i[a])}),o},CO=function e(t,n){if(t===n)return!0;var r=R.Children.count(t);if(r!==R.Children.count(n))return!1;if(r===0)return!0;if(r===1)return lM(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Gve(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function jO(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,o=e.className,a=e.style,s=e.title,l=e.desc,u=Hve(e,Wve),f=i||{width:n,height:r,x:0,y:0},d=Pe("recharts-surface",o);return V.createElement("svg",TO({},De(u,!0,"svg"),{className:d,width:n,height:r,style:a,viewBox:"".concat(f.x," ").concat(f.y," ").concat(f.width," ").concat(f.height)}),V.createElement("title",null,s),V.createElement("desc",null,l),t)}var qve=["children","className"];function AO(){return AO=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Yve(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Qe=V.forwardRef(function(e,t){var n=e.children,r=e.className,i=Kve(e,qve),o=Pe("recharts-layer",r);return V.createElement("g",AO({className:o},De(i,!0),{ref:t}),n)}),Fi=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;oi?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=Array(i);++r=r?e:Qve(e,t,n)}var ege=Jve,tge="\\ud800-\\udfff",nge="\\u0300-\\u036f",rge="\\ufe20-\\ufe2f",ige="\\u20d0-\\u20ff",oge=nge+rge+ige,age="\\ufe0e\\ufe0f",sge="\\u200d",lge=RegExp("["+sge+tge+oge+age+"]");function uge(e){return lge.test(e)}var VF=uge;function cge(e){return e.split("")}var fge=cge,WF="\\ud800-\\udfff",dge="\\u0300-\\u036f",hge="\\ufe20-\\ufe2f",pge="\\u20d0-\\u20ff",mge=dge+hge+pge,vge="\\ufe0e\\ufe0f",gge="["+WF+"]",kO="["+mge+"]",NO="\\ud83c[\\udffb-\\udfff]",yge="(?:"+kO+"|"+NO+")",HF="[^"+WF+"]",GF="(?:\\ud83c[\\udde6-\\uddff]){2}",qF="[\\ud800-\\udbff][\\udc00-\\udfff]",bge="\\u200d",KF=yge+"?",YF="["+vge+"]?",_ge="(?:"+bge+"(?:"+[HF,GF,qF].join("|")+")"+YF+KF+")*",xge=YF+KF+_ge,wge="(?:"+[HF+kO+"?",kO,GF,qF,gge].join("|")+")",Oge=RegExp(NO+"(?="+NO+")|"+wge+xge,"g");function Sge(e){return e.match(Oge)||[]}var Ege=Sge,Pge=fge,Cge=VF,Tge=Ege;function jge(e){return Cge(e)?Tge(e):Pge(e)}var Age=jge,kge=ege,Nge=VF,Mge=Age,Rge=$F;function Lge(e){return function(t){t=Rge(t);var n=Nge(t)?Mge(t):void 0,r=n?n[0]:t.charAt(0),i=n?kge(n,1).join(""):t.slice(1);return r[e]()+i}}var $ge=Lge,Ige=$ge,Dge=Ige("toUpperCase"),Fge=Dge;const jb=st(Fge);function wt(e){return function(){return e}}const ZF=Math.cos,Ey=Math.sin,qi=Math.sqrt,Py=Math.PI,Ab=2*Py,MO=Math.PI,RO=2*MO,Vs=1e-6,Bge=RO-Vs;function XF(e){this._+=e[0];for(let t=1,n=e.length;t=0))throw new Error(`invalid digits: ${e}`);if(t>15)return XF;const n=10**t;return function(r){this._+=r[0];for(let i=1,o=r.length;iVs)if(!(Math.abs(d*l-u*f)>Vs)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let v=r-a,g=i-s,y=l*l+u*u,x=v*v+g*g,_=Math.sqrt(y),b=Math.sqrt(h),w=o*Math.tan((MO-Math.acos((y+h-x)/(2*_*b)))/2),S=w/b,E=w/_;Math.abs(S-1)>Vs&&this._append`L${t+S*f},${n+S*d}`,this._append`A${o},${o},0,0,${+(d*v>f*g)},${this._x1=t+E*l},${this._y1=n+E*u}`}}arc(t,n,r,i,o,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let s=r*Math.cos(i),l=r*Math.sin(i),u=t+s,f=n+l,d=1^a,h=a?i-o:o-i;this._x1===null?this._append`M${u},${f}`:(Math.abs(this._x1-u)>Vs||Math.abs(this._y1-f)>Vs)&&this._append`L${u},${f}`,r&&(h<0&&(h=h%RO+RO),h>Bge?this._append`A${r},${r},0,1,${d},${t-s},${n-l}A${r},${r},0,1,${d},${this._x1=u},${this._y1=f}`:h>Vs&&this._append`A${r},${r},0,${+(h>=MO)},${d},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function AC(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 zge(t)}function kC(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function QF(e){this._context=e}QF.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 kb(e){return new QF(e)}function JF(e){return e[0]}function e7(e){return e[1]}function t7(e,t){var n=wt(!0),r=null,i=kb,o=null,a=AC(s);e=typeof e=="function"?e:e===void 0?JF:wt(e),t=typeof t=="function"?t:t===void 0?e7:wt(t);function s(l){var u,f=(l=kC(l)).length,d,h=!1,v;for(r==null&&(o=i(v=a())),u=0;u<=f;++u)!(u=v;--g)s.point(w[g],S[g]);s.lineEnd(),s.areaEnd()}_&&(w[h]=+e(x,h,d),S[h]=+t(x,h,d),s.point(r?+r(x,h,d):w[h],n?+n(x,h,d):S[h]))}if(b)return s=null,b+""||null}function f(){return t7().defined(i).curve(a).context(o)}return u.x=function(d){return arguments.length?(e=typeof d=="function"?d:wt(+d),r=null,u):e},u.x0=function(d){return arguments.length?(e=typeof d=="function"?d:wt(+d),u):e},u.x1=function(d){return arguments.length?(r=d==null?null:typeof d=="function"?d:wt(+d),u):r},u.y=function(d){return arguments.length?(t=typeof d=="function"?d:wt(+d),n=null,u):t},u.y0=function(d){return arguments.length?(t=typeof d=="function"?d:wt(+d),u):t},u.y1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:wt(+d),u):n},u.lineX0=u.lineY0=function(){return f().x(e).y(t)},u.lineY1=function(){return f().x(e).y(n)},u.lineX1=function(){return f().x(r).y(t)},u.defined=function(d){return arguments.length?(i=typeof d=="function"?d:wt(!!d),u):i},u.curve=function(d){return arguments.length?(a=d,o!=null&&(s=a(o)),u):a},u.context=function(d){return arguments.length?(d==null?o=s=null:s=a(o=d),u):o},u}class n7{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 Vge(e){return new n7(e,!0)}function Wge(e){return new n7(e,!1)}const NC={draw(e,t){const n=qi(t/Py);e.moveTo(n,0),e.arc(0,0,n,0,Ab)}},Hge={draw(e,t){const n=qi(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()}},r7=qi(1/3),Gge=r7*2,qge={draw(e,t){const n=qi(t/Gge),r=n*r7;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},Kge={draw(e,t){const n=qi(t),r=-n/2;e.rect(r,r,n,n)}},Yge=.8908130915292852,i7=Ey(Py/10)/Ey(7*Py/10),Zge=Ey(Ab/10)*i7,Xge=-ZF(Ab/10)*i7,Qge={draw(e,t){const n=qi(t*Yge),r=Zge*n,i=Xge*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const a=Ab*o/5,s=ZF(a),l=Ey(a);e.lineTo(l*n,-s*n),e.lineTo(s*r-l*i,l*r+s*i)}e.closePath()}},H_=qi(3),Jge={draw(e,t){const n=-qi(t/(H_*3));e.moveTo(0,n*2),e.lineTo(-H_*n,-n),e.lineTo(H_*n,-n),e.closePath()}},Jr=-.5,ei=qi(3)/2,LO=1/qi(12),eye=(LO/2+1)*3,tye={draw(e,t){const n=qi(t/eye),r=n/2,i=n*LO,o=r,a=n*LO+n,s=-o,l=a;e.moveTo(r,i),e.lineTo(o,a),e.lineTo(s,l),e.lineTo(Jr*r-ei*i,ei*r+Jr*i),e.lineTo(Jr*o-ei*a,ei*o+Jr*a),e.lineTo(Jr*s-ei*l,ei*s+Jr*l),e.lineTo(Jr*r+ei*i,Jr*i-ei*r),e.lineTo(Jr*o+ei*a,Jr*a-ei*o),e.lineTo(Jr*s+ei*l,Jr*l-ei*s),e.closePath()}};function nye(e,t){let n=null,r=AC(i);e=typeof e=="function"?e:wt(e||NC),t=typeof t=="function"?t:wt(t===void 0?64:+t);function i(){let o;if(n||(n=o=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:wt(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:wt(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function Cy(){}function Ty(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 o7(e){this._context=e}o7.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:Ty(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:Ty(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rye(e){return new o7(e)}function a7(e){this._context=e}a7.prototype={areaStart:Cy,areaEnd:Cy,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:Ty(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function iye(e){return new a7(e)}function s7(e){this._context=e}s7.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:Ty(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function oye(e){return new s7(e)}function l7(e){this._context=e}l7.prototype={areaStart:Cy,areaEnd:Cy,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 aye(e){return new l7(e)}function cM(e){return e<0?-1:1}function fM(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),a=(n-e._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(cM(o)+cM(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function dM(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function G_(e,t,n){var r=e._x0,i=e._y0,o=e._x1,a=e._y1,s=(o-r)/3;e._context.bezierCurveTo(r+s,i+s*t,o-s,a-s*n,o,a)}function jy(e){this._context=e}jy.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:G_(this,this._t0,dM(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,G_(this,dM(this,n=fM(this,e,t)),n);break;default:G_(this,this._t0,n=fM(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function u7(e){this._context=new c7(e)}(u7.prototype=Object.create(jy.prototype)).point=function(e,t){jy.prototype.point.call(this,t,e)};function c7(e){this._context=e}c7.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,o){this._context.bezierCurveTo(t,e,r,n,o,i)}};function sye(e){return new jy(e)}function lye(e){return new u7(e)}function f7(e){this._context=e}f7.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=hM(e),i=hM(t),o=0,a=1;a=0;--t)i[t]=(a[t]-i[t+1])/o[t];for(o[n-1]=(e[n]+i[n-1])/2,t=0;t=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 cye(e){return new Nb(e,.5)}function fye(e){return new Nb(e,0)}function dye(e){return new Nb(e,1)}function xc(e,t){if((a=e.length)>1)for(var n=1,r,i,o=e[t[0]],a,s=o.length;n=0;)n[t]=t;return n}function hye(e,t){return e[t]}function pye(e){const t=[];return t.key=e,t}function mye(){var e=wt([]),t=$O,n=xc,r=hye;function i(o){var a=Array.from(e.apply(this,arguments),pye),s,l=a.length,u=-1,f;for(const d of o)for(s=0,++u;s0){for(var n,r,i=0,o=e[0].length,a;i0){for(var n=0,r=e[t[0]],i,o=r.length;n0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,a;r=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Sye(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var d7={symbolCircle:NC,symbolCross:Hge,symbolDiamond:qge,symbolSquare:Kge,symbolStar:Qge,symbolTriangle:Jge,symbolWye:tye},Eye=Math.PI/180,Pye=function(t){var n="symbol".concat(jb(t));return d7[n]||NC},Cye=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*Eye;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}},Tye=function(t,n){d7["symbol".concat(jb(t))]=n},Mb=function(t){var n=t.type,r=n===void 0?"circle":n,i=t.size,o=i===void 0?64:i,a=t.sizeType,s=a===void 0?"area":a,l=Oye(t,bye),u=mM(mM({},l),{},{type:r,size:o,sizeType:s}),f=function(){var x=Pye(r),_=nye().type(x).size(Cye(o,s,r));return _()},d=u.className,h=u.cx,v=u.cy,g=De(u,!0);return h===+h&&v===+v&&o===+o?V.createElement("path",IO({},g,{className:Pe("recharts-symbols",d),transform:"translate(".concat(h,", ").concat(v,")"),d:f()})):null};Mb.registerSymbol=Tye;function wc(e){"@babel/helpers - typeof";return wc=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},wc(e)}function DO(){return DO=Object.assign?Object.assign.bind():function(e){for(var t=1;t`);var b=v.inactive?u:v.color;return V.createElement("li",DO({className:x,style:d,key:"legend-item-".concat(g)},ss(r.props,v,g)),V.createElement(jO,{width:a,height:a,viewBox:f,style:h},r.renderIcon(v)),V.createElement("span",{className:"recharts-legend-item-text",style:{color:b}},y?y(_,v,g):_))})}},{key:"render",value:function(){var r=this.props,i=r.payload,o=r.layout,a=r.align;if(!i||!i.length)return null;var s={padding:0,margin:0,textAlign:o==="horizontal"?a:"left"};return V.createElement("ul",{className:"recharts-default-legend",style:s},this.renderItems())}}]),t}(R.PureComponent);$h(MC,"displayName","Legend");$h(MC,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var Iye=vb;function Dye(){this.__data__=new Iye,this.size=0}var Fye=Dye;function Bye(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}var Uye=Bye;function zye(e){return this.__data__.get(e)}var Vye=zye;function Wye(e){return this.__data__.has(e)}var Hye=Wye,Gye=vb,qye=_C,Kye=xC,Yye=200;function Zye(e,t){var n=this.__data__;if(n instanceof Gye){var r=n.__data__;if(!qye||r.lengths))return!1;var u=o.get(e),f=o.get(t);if(u&&f)return u==t&&f==e;var d=-1,h=!0,v=n&y0e?new p0e:void 0;for(o.set(e,t),o.set(t,e);++d-1&&e%1==0&&e-1&&e%1==0&&e<=wbe}var IC=Obe,Sbe=da,Ebe=IC,Pbe=ha,Cbe="[object Arguments]",Tbe="[object Array]",jbe="[object Boolean]",Abe="[object Date]",kbe="[object Error]",Nbe="[object Function]",Mbe="[object Map]",Rbe="[object Number]",Lbe="[object Object]",$be="[object RegExp]",Ibe="[object Set]",Dbe="[object String]",Fbe="[object WeakMap]",Bbe="[object ArrayBuffer]",Ube="[object DataView]",zbe="[object Float32Array]",Vbe="[object Float64Array]",Wbe="[object Int8Array]",Hbe="[object Int16Array]",Gbe="[object Int32Array]",qbe="[object Uint8Array]",Kbe="[object Uint8ClampedArray]",Ybe="[object Uint16Array]",Zbe="[object Uint32Array]",Tt={};Tt[zbe]=Tt[Vbe]=Tt[Wbe]=Tt[Hbe]=Tt[Gbe]=Tt[qbe]=Tt[Kbe]=Tt[Ybe]=Tt[Zbe]=!0;Tt[Cbe]=Tt[Tbe]=Tt[Bbe]=Tt[jbe]=Tt[Ube]=Tt[Abe]=Tt[kbe]=Tt[Nbe]=Tt[Mbe]=Tt[Rbe]=Tt[Lbe]=Tt[$be]=Tt[Ibe]=Tt[Dbe]=Tt[Fbe]=!1;function Xbe(e){return Pbe(e)&&Ebe(e.length)&&!!Tt[Sbe(e)]}var Qbe=Xbe;function Jbe(e){return function(t){return e(t)}}var O7=Jbe,My={exports:{}};My.exports;(function(e,t){var n=AF,r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,a=o&&n.process,s=function(){try{var l=i&&i.require&&i.require("util").types;return l||a&&a.binding&&a.binding("util")}catch{}}();e.exports=s})(My,My.exports);var e1e=My.exports,t1e=Qbe,n1e=O7,OM=e1e,SM=OM&&OM.isTypedArray,r1e=SM?n1e(SM):t1e,S7=r1e,i1e=sbe,o1e=LC,a1e=Ar,s1e=w7,l1e=$C,u1e=S7,c1e=Object.prototype,f1e=c1e.hasOwnProperty;function d1e(e,t){var n=a1e(e),r=!n&&o1e(e),i=!n&&!r&&s1e(e),o=!n&&!r&&!i&&u1e(e),a=n||r||i||o,s=a?i1e(e.length,String):[],l=s.length;for(var u in e)(t||f1e.call(e,u))&&!(a&&(u=="length"||i&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||l1e(u,l)))&&s.push(u);return s}var h1e=d1e,p1e=Object.prototype;function m1e(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||p1e;return e===n}var v1e=m1e;function g1e(e,t){return function(n){return e(t(n))}}var E7=g1e,y1e=E7,b1e=y1e(Object.keys,Object),_1e=b1e,x1e=v1e,w1e=_1e,O1e=Object.prototype,S1e=O1e.hasOwnProperty;function E1e(e){if(!x1e(e))return w1e(e);var t=[];for(var n in Object(e))S1e.call(e,n)&&n!="constructor"&&t.push(n);return t}var P1e=E1e,C1e=yC,T1e=IC;function j1e(e){return e!=null&&T1e(e.length)&&!C1e(e)}var Gp=j1e,A1e=h1e,k1e=P1e,N1e=Gp;function M1e(e){return N1e(e)?A1e(e):k1e(e)}var Rb=M1e,R1e=Y0e,L1e=obe,$1e=Rb;function I1e(e){return R1e(e,$1e,L1e)}var D1e=I1e,EM=D1e,F1e=1,B1e=Object.prototype,U1e=B1e.hasOwnProperty;function z1e(e,t,n,r,i,o){var a=n&F1e,s=EM(e),l=s.length,u=EM(t),f=u.length;if(l!=f&&!a)return!1;for(var d=l;d--;){var h=s[d];if(!(a?h in t:U1e.call(t,h)))return!1}var v=o.get(e),g=o.get(t);if(v&&g)return v==t&&g==e;var y=!0;o.set(e,t),o.set(t,e);for(var x=a;++d-1}var Bxe=Fxe;function Uxe(e,t,n){for(var r=-1,i=e==null?0:e.length;++r=nwe){var u=t?null:ewe(e);if(u)return twe(u);a=!1,i=Jxe,l=new Zxe}else l=t?[]:s;e:for(;++r=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function gwe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function ywe(e){return e.value}function bwe(e,t){if(V.isValidElement(e))return V.cloneElement(e,t);if(typeof e=="function")return V.createElement(e,t);t.ref;var n=vwe(t,uwe);return V.createElement(MC,n)}var UM=1,Ih=function(e){pwe(t,e);function t(){var n;cwe(this,t);for(var r=arguments.length,i=new Array(r),o=0;oUM||Math.abs(i.height-this.lastBoundingBox.height)>UM)&&(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?ks({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var i=this.props,o=i.layout,a=i.align,s=i.verticalAlign,l=i.margin,u=i.chartWidth,f=i.chartHeight,d,h;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(a==="center"&&o==="vertical"){var v=this.getBBoxSnapshot();d={left:((u||0)-v.width)/2}}else d=a==="right"?{right:l&&l.right||0}:{left:l&&l.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(s==="middle"){var g=this.getBBoxSnapshot();h={top:((f||0)-g.height)/2}}else h=s==="bottom"?{bottom:l&&l.bottom||0}:{top:l&&l.top||0};return ks(ks({},d),h)}},{key:"render",value:function(){var r=this,i=this.props,o=i.content,a=i.width,s=i.height,l=i.wrapperStyle,u=i.payloadUniqBy,f=i.payload,d=ks(ks({position:"absolute",width:a||"auto",height:s||"auto"},this.getDefaultPosition(l)),l);return V.createElement("div",{className:"recharts-legend-wrapper",style:d,ref:function(v){r.wrapperNode=v}},bwe(o,ks(ks({},this.props),{},{payload:N7(f,u,ywe)})))}}],[{key:"getWithHeight",value:function(r,i){var o=r.props.layout;return o==="vertical"&&Ee(r.props.height)?{height:r.props.height}:o==="horizontal"?{width:r.props.width||i}:null}}]),t}(R.PureComponent);Lb(Ih,"displayName","Legend");Lb(Ih,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var zM=Wp,_we=LC,xwe=Ar,VM=zM?zM.isConcatSpreadable:void 0;function wwe(e){return xwe(e)||_we(e)||!!(VM&&e&&e[VM])}var Owe=wwe,Swe=_7,Ewe=Owe;function $7(e,t,n,r,i){var o=-1,a=e.length;for(n||(n=Ewe),i||(i=[]);++o0&&n(s)?t>1?$7(s,t-1,n,r,i):Swe(i,s):r||(i[i.length]=s)}return i}var I7=$7;function Pwe(e){return function(t,n,r){for(var i=-1,o=Object(t),a=r(t),s=a.length;s--;){var l=a[e?s:++i];if(n(o[l],l,o)===!1)break}return t}}var Cwe=Pwe,Twe=Cwe,jwe=Twe(),Awe=jwe,kwe=Awe,Nwe=Rb;function Mwe(e,t){return e&&kwe(e,t,Nwe)}var D7=Mwe,Rwe=Gp;function Lwe(e,t){return function(n,r){if(n==null)return n;if(!Rwe(n))return e(n,r);for(var i=n.length,o=t?i:-1,a=Object(n);(t?o--:++ot||o&&a&&l&&!s&&!u||r&&a&&l||!n&&l||!i)return 1;if(!r&&!o&&!u&&e=s)return l;var u=n[r];return l*(u=="desc"?-1:1)}}return e.index-t.index}var Ywe=Kwe,Z_=OC,Zwe=SC,Xwe=jo,Qwe=F7,Jwe=Wwe,e2e=O7,t2e=Ywe,n2e=cf,r2e=Ar;function i2e(e,t,n){t.length?t=Z_(t,function(o){return r2e(o)?function(a){return Zwe(a,o.length===1?o[0]:o)}:o}):t=[n2e];var r=-1;t=Z_(t,e2e(Xwe));var i=Qwe(e,function(o,a,s){var l=Z_(t,function(u){return u(o)});return{criteria:l,index:++r,value:o}});return Jwe(i,function(o,a){return t2e(o,a,n)})}var o2e=i2e;function a2e(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var s2e=a2e,l2e=s2e,HM=Math.max;function u2e(e,t,n){return t=HM(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=HM(r.length-t,0),a=Array(o);++i0){if(++t>=b2e)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var O2e=w2e,S2e=y2e,E2e=O2e,P2e=E2e(S2e),C2e=P2e,T2e=cf,j2e=c2e,A2e=C2e;function k2e(e,t){return A2e(j2e(e,t,T2e),e+"")}var N2e=k2e,M2e=bC,R2e=Gp,L2e=$C,$2e=bs;function I2e(e,t,n){if(!$2e(n))return!1;var r=typeof t;return(r=="number"?R2e(n)&&L2e(t,n.length):r=="string"&&t in n)?M2e(n[t],e):!1}var $b=I2e,D2e=I7,F2e=o2e,B2e=N2e,qM=$b,U2e=B2e(function(e,t){if(e==null)return[];var n=t.length;return n>1&&qM(e,t[0],t[1])?t=[]:n>2&&qM(t[0],t[1],t[2])&&(t=[t[0]]),F2e(e,D2e(t,1),[])}),z2e=U2e;const BC=st(z2e);function Dh(e){"@babel/helpers - typeof";return Dh=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},Dh(e)}function GO(){return GO=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=t.x),"".concat(Qf,"-left"),Ee(n)&&t&&Ee(t.x)&&n=t.y),"".concat(Qf,"-top"),Ee(r)&&t&&Ee(t.y)&&ry?Math.max(f,l[r]):Math.max(d,l[r])}function rOe(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 iOe(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,o=e.reverseDirection,a=e.tooltipBox,s=e.useTranslate3d,l=e.viewBox,u,f,d;return a.height>0&&a.width>0&&n?(f=ZM({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:a.width,viewBox:l,viewBoxDimension:l.width}),d=ZM({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:a.height,viewBox:l,viewBoxDimension:l.height}),u=rOe({translateX:f,translateY:d,useTranslate3d:s})):u=tOe,{cssProperties:u,cssClasses:nOe({translateX:f,translateY:d,coordinate:n})}}function Sc(e){"@babel/helpers - typeof";return Sc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Sc(e)}function XM(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 QM(e){for(var t=1;teR||Math.abs(r.height-this.state.lastBoundingBox.height)>eR)&&this.setState({lastBoundingBox:{width:r.width,height:r.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var r,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var r=this,i=this.props,o=i.active,a=i.allowEscapeViewBox,s=i.animationDuration,l=i.animationEasing,u=i.children,f=i.coordinate,d=i.hasPayload,h=i.isAnimationActive,v=i.offset,g=i.position,y=i.reverseDirection,x=i.useTranslate3d,_=i.viewBox,b=i.wrapperStyle,w=iOe({allowEscapeViewBox:a,coordinate:f,offsetTopLeft:v,position:g,reverseDirection:y,tooltipBox:this.state.lastBoundingBox,useTranslate3d:x,viewBox:_}),S=w.cssClasses,E=w.cssProperties,P=QM(QM({transition:h&&o?"transform ".concat(s,"ms ").concat(l):void 0},E),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&d?"visible":"hidden",position:"absolute",top:0,left:0},b);return V.createElement("div",{tabIndex:-1,className:S,style:P,ref:function(A){r.wrapperNode=A}},u)}}]),t}(R.PureComponent),dOe=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},pi={isSsr:dOe(),get:function(t){return pi[t]},set:function(t,n){if(typeof t=="string")pi[t]=n;else{var r=Object.keys(t);r&&r.length&&r.forEach(function(i){pi[i]=t[i]})}}};function Ec(e){"@babel/helpers - typeof";return Ec=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ec(e)}function tR(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 nR(e){for(var t=1;t0;return V.createElement(fOe,{allowEscapeViewBox:a,animationDuration:s,animationEasing:l,isAnimationActive:h,active:o,coordinate:f,hasPayload:P,offset:v,position:x,reverseDirection:_,useTranslate3d:b,viewBox:w,wrapperStyle:S},xOe(u,nR(nR({},this.props),{},{payload:E})))}}]),t}(R.PureComponent);UC(ii,"displayName","Tooltip");UC(ii,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!pi.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 wOe=To,OOe=function(){return wOe.Date.now()},SOe=OOe,EOe=/\s/;function POe(e){for(var t=e.length;t--&&EOe.test(e.charAt(t)););return t}var COe=POe,TOe=COe,jOe=/^\s+/;function AOe(e){return e&&e.slice(0,TOe(e)+1).replace(jOe,"")}var kOe=AOe,NOe=kOe,iR=bs,MOe=tf,oR=NaN,ROe=/^[-+]0x[0-9a-f]+$/i,LOe=/^0b[01]+$/i,$Oe=/^0o[0-7]+$/i,IOe=parseInt;function DOe(e){if(typeof e=="number")return e;if(MOe(e))return oR;if(iR(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=iR(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=NOe(e);var n=LOe.test(e);return n||$Oe.test(e)?IOe(e.slice(2),n?2:8):ROe.test(e)?oR:+e}var H7=DOe,FOe=bs,Q_=SOe,aR=H7,BOe="Expected a function",UOe=Math.max,zOe=Math.min;function VOe(e,t,n){var r,i,o,a,s,l,u=0,f=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(BOe);t=aR(t)||0,FOe(n)&&(f=!!n.leading,d="maxWait"in n,o=d?UOe(aR(n.maxWait)||0,t):o,h="trailing"in n?!!n.trailing:h);function v(P){var T=r,A=i;return r=i=void 0,u=P,a=e.apply(A,T),a}function g(P){return u=P,s=setTimeout(_,t),f?v(P):a}function y(P){var T=P-l,A=P-u,D=t-T;return d?zOe(D,o-A):D}function x(P){var T=P-l,A=P-u;return l===void 0||T>=t||T<0||d&&A>=o}function _(){var P=Q_();if(x(P))return b(P);s=setTimeout(_,y(P))}function b(P){return s=void 0,h&&r?v(P):(r=i=void 0,a)}function w(){s!==void 0&&clearTimeout(s),u=0,r=l=i=s=void 0}function S(){return s===void 0?a:b(Q_())}function E(){var P=Q_(),T=x(P);if(r=arguments,i=this,l=P,T){if(s===void 0)return g(l);if(d)return clearTimeout(s),s=setTimeout(_,t),v(l)}return s===void 0&&(s=setTimeout(_,t)),a}return E.cancel=w,E.flush=S,E}var WOe=VOe,HOe=WOe,GOe=bs,qOe="Expected a function";function KOe(e,t,n){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(qOe);return GOe(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),HOe(e,t,{leading:r,maxWait:t,trailing:i})}var YOe=KOe;const G7=st(YOe);function Bh(e){"@babel/helpers - typeof";return Bh=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},Bh(e)}function sR(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 pv(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&(q=G7(q,y,{trailing:!0,leading:!1}));var W=new ResizeObserver(q),X=E.current.getBoundingClientRect(),Q=X.width,ne=X.height;return I(Q,ne),W.observe(E.current),function(){W.disconnect()}},[I,y]);var F=R.useMemo(function(){var q=D.containerWidth,W=D.containerHeight;if(q<0||W<0)return null;Fi(nl(a)||nl(l),`The width(%s) and height(%s) are both fixed numbers, maybe you don't need to use a ResponsiveContainer.`,a,l),Fi(!n||n>0,"The aspect(%s) must be greater than zero.",n);var X=nl(a)?q:a,Q=nl(l)?W:l;n&&n>0&&(X?Q=X/n:Q&&(X=Q*n),h&&Q>h&&(Q=h)),Fi(X>0||Q>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.`,X,Q,a,l,f,d,n);var ne=!Array.isArray(v)&&SO.isElement(v)&&Wo(v.type).endsWith("Chart");return V.Children.map(v,function(Z){return SO.isElement(Z)?R.cloneElement(Z,pv({width:X,height:Q},ne?{style:pv({height:"100%",width:"100%",maxHeight:Q,maxWidth:X},Z.props.style)}:{})):Z})},[n,v,l,h,d,f,D,a]);return V.createElement("div",{id:x?"".concat(x):void 0,className:Pe("recharts-responsive-container",_),style:pv(pv({},S),{},{width:a,height:l,minWidth:f,minHeight:d,maxHeight:h}),ref:E},F)}),Za=function(t){return null};Za.displayName="Cell";function Uh(e){"@babel/helpers - typeof";return Uh=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},Uh(e)}function uR(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 XO(e){for(var t=1;t1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||pi.isSsr)return{width:0,height:0};var r=uSe(n),i=JSON.stringify({text:t,copyStyle:r});if(su.widthCache[i])return su.widthCache[i];try{var o=document.getElementById(cR);o||(o=document.createElement("span"),o.setAttribute("id",cR),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var a=XO(XO({},lSe),r);Object.assign(o.style,a),o.textContent="".concat(t);var s=o.getBoundingClientRect(),l={width:s.width,height:s.height};return su.widthCache[i]=l,++su.cacheCount>sSe&&(su.cacheCount=0,su.widthCache={}),l}catch{return{width:0,height:0}}},cSe=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function zh(e){"@babel/helpers - typeof";return zh=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},zh(e)}function Iy(e,t){return pSe(e)||hSe(e,t)||dSe(e,t)||fSe()}function fSe(){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 dSe(e,t){if(e){if(typeof e=="string")return fR(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 fR(e,t)}}function fR(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function TSe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function gR(e,t){return NSe(e)||kSe(e,t)||ASe(e,t)||jSe()}function jSe(){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 ASe(e,t){if(e){if(typeof e=="string")return yR(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 yR(e,t)}}function yR(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&arguments[0]!==void 0?arguments[0]:[];return X.reduce(function(Q,ne){var Z=ne.word,z=ne.width,B=Q[Q.length-1];if(B&&(i==null||o||B.width+z+rne.width?Q:ne})};if(!f)return v;for(var y="…",x=function(X){var Q=d.slice(0,X),ne=Z7({breakAll:u,style:l,children:Q+y}).wordsWithComputedWidth,Z=h(ne),z=Z.length>a||g(Z).width>Number(i);return[z,Z]},_=0,b=d.length-1,w=0,S;_<=b&&w<=d.length-1;){var E=Math.floor((_+b)/2),P=E-1,T=x(P),A=gR(T,2),D=A[0],k=A[1],I=x(E),F=gR(I,1),q=F[0];if(!D&&!q&&(_=E+1),D&&q&&(b=E-1),!D&&q){S=k;break}w++}return S||v},bR=function(t){var n=ze(t)?[]:t.toString().split(Y7);return[{words:n}]},RSe=function(t){var n=t.width,r=t.scaleToFit,i=t.children,o=t.style,a=t.breakAll,s=t.maxLines;if((n||r)&&!pi.isSsr){var l,u,f=Z7({breakAll:a,children:i,style:o});if(f){var d=f.wordsWithComputedWidth,h=f.spaceWidth;l=d,u=h}else return bR(i);return MSe({breakAll:a,children:i,maxLines:s,style:o},l,u,n,r)}return bR(i)},_R="#808080",Tl=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,a=t.lineHeight,s=a===void 0?"1em":a,l=t.capHeight,u=l===void 0?"0.71em":l,f=t.scaleToFit,d=f===void 0?!1:f,h=t.textAnchor,v=h===void 0?"start":h,g=t.verticalAnchor,y=g===void 0?"end":g,x=t.fill,_=x===void 0?_R:x,b=vR(t,PSe),w=R.useMemo(function(){return RSe({breakAll:b.breakAll,children:b.children,maxLines:b.maxLines,scaleToFit:d,style:b.style,width:b.width})},[b.breakAll,b.children,b.maxLines,d,b.style,b.width]),S=b.dx,E=b.dy,P=b.angle,T=b.className,A=b.breakAll,D=vR(b,CSe);if(!pn(r)||!pn(o))return null;var k=r+(Ee(S)?S:0),I=o+(Ee(E)?E:0),F;switch(y){case"start":F=J_("calc(".concat(u,")"));break;case"middle":F=J_("calc(".concat((w.length-1)/2," * -").concat(s," + (").concat(u," / 2))"));break;default:F=J_("calc(".concat(w.length-1," * -").concat(s,")"));break}var q=[];if(d){var W=w[0].width,X=b.width;q.push("scale(".concat((Ee(X)?X/W:1)/W,")"))}return P&&q.push("rotate(".concat(P,", ").concat(k,", ").concat(I,")")),q.length&&(D.transform=q.join(" ")),V.createElement("text",QO({},De(D,!0),{x:k,y:I,className:Pe("recharts-text",T),textAnchor:v,fill:_.includes("url")?_R:_}),w.map(function(Q,ne){var Z=Q.words.join(A?"":" ");return V.createElement("tspan",{x:k,dy:ne===0?F:s,key:Z},Z)}))};function Xa(e,t){return e==null||t==null?NaN:et?1:e>=t?0:NaN}function LSe(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function VC(e){let t,n,r;e.length!==2?(t=Xa,n=(s,l)=>Xa(e(s),l),r=(s,l)=>e(s)-l):(t=e===Xa||e===LSe?e:$Se,n=e,r=e);function i(s,l,u=0,f=s.length){if(u>>1;n(s[d],l)<0?u=d+1:f=d}while(u>>1;n(s[d],l)<=0?u=d+1:f=d}while(uu&&r(s[d-1],l)>-r(s[d],l)?d-1:d}return{left:i,center:a,right:o}}function $Se(){return 0}function X7(e){return e===null?NaN:+e}function*ISe(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}const DSe=VC(Xa),qp=DSe.right;VC(X7).center;class xR extends Map{constructor(t,n=USe){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(wR(this,t))}has(t){return super.has(wR(this,t))}set(t,n){return super.set(FSe(this,t),n)}delete(t){return super.delete(BSe(this,t))}}function wR({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function FSe({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function BSe({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function USe(e){return e!==null&&typeof e=="object"?e.valueOf():e}function zSe(e=Xa){if(e===Xa)return Q7;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 Q7(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(et?1:0)}const VSe=Math.sqrt(50),WSe=Math.sqrt(10),HSe=Math.sqrt(2);function Dy(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=VSe?10:o>=WSe?5:o>=HSe?2:1;let s,l,u;return i<0?(u=Math.pow(10,-i)/a,s=Math.round(e*u),l=Math.round(t*u),s/ut&&--l,u=-u):(u=Math.pow(10,i)*a,s=Math.round(e/u),l=Math.round(t/u),s*ut&&--l),l0))return[];if(e===t)return[e];const r=t=i))return[];const s=o-i+1,l=new Array(s);if(r)if(a<0)for(let u=0;u=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n=i)&&(n=i)}return n}function SR(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function J7(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?Q7:zSe(i);r>n;){if(r-n>600){const l=r-n+1,u=t-n+1,f=Math.log(l),d=.5*Math.exp(2*f/3),h=.5*Math.sqrt(f*d*(l-d)/l)*(u-l/2<0?-1:1),v=Math.max(n,Math.floor(t-u*d/l+h)),g=Math.min(r,Math.floor(t+(l-u)*d/l+h));J7(e,t,v,g,i)}const o=e[t];let a=n,s=r;for(Jf(e,n,t),i(e[r],o)>0&&Jf(e,n,r);a0;)--s}i(e[n],o)===0?Jf(e,n,s):(++s,Jf(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function Jf(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function GSe(e,t,n){if(e=Float64Array.from(ISe(e,n)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return SR(e);if(t>=1)return OR(e);var r,i=(r-1)*t,o=Math.floor(i),a=OR(J7(e,o).subarray(0,o+1)),s=SR(e.subarray(o+1));return a+(s-a)*(i-o)}}function qSe(e,t,n=X7){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,o=Math.floor(i),a=+n(e[o],o,e),s=+n(e[o+1],o+1,e);return a+(s-a)*(i-o)}}function KSe(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?vv(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?vv(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=ZSe.exec(e))?new yr(t[1],t[2],t[3],1):(t=XSe.exec(e))?new yr(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=QSe.exec(e))?vv(t[1],t[2],t[3],t[4]):(t=JSe.exec(e))?vv(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=eEe.exec(e))?kR(t[1],t[2]/100,t[3]/100,1):(t=tEe.exec(e))?kR(t[1],t[2]/100,t[3]/100,t[4]):ER.hasOwnProperty(e)?TR(ER[e]):e==="transparent"?new yr(NaN,NaN,NaN,0):null}function TR(e){return new yr(e>>16&255,e>>8&255,e&255,1)}function vv(e,t,n,r){return r<=0&&(e=t=n=NaN),new yr(e,t,n,r)}function iEe(e){return e instanceof Kp||(e=Gh(e)),e?(e=e.rgb(),new yr(e.r,e.g,e.b,e.opacity)):new yr}function rS(e,t,n,r){return arguments.length===1?iEe(e):new yr(e,t,n,r??1)}function yr(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}HC(yr,rS,tB(Kp,{brighter(e){return e=e==null?Fy:Math.pow(Fy,e),new yr(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Wh:Math.pow(Wh,e),new yr(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new yr(ml(this.r),ml(this.g),ml(this.b),By(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:jR,formatHex:jR,formatHex8:oEe,formatRgb:AR,toString:AR}));function jR(){return`#${rl(this.r)}${rl(this.g)}${rl(this.b)}`}function oEe(){return`#${rl(this.r)}${rl(this.g)}${rl(this.b)}${rl((isNaN(this.opacity)?1:this.opacity)*255)}`}function AR(){const e=By(this.opacity);return`${e===1?"rgb(":"rgba("}${ml(this.r)}, ${ml(this.g)}, ${ml(this.b)}${e===1?")":`, ${e})`}`}function By(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function ml(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function rl(e){return e=ml(e),(e<16?"0":"")+e.toString(16)}function kR(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Ri(e,t,n,r)}function nB(e){if(e instanceof Ri)return new Ri(e.h,e.s,e.l,e.opacity);if(e instanceof Kp||(e=Gh(e)),!e)return new Ri;if(e instanceof Ri)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,l=(o+i)/2;return s?(t===o?a=(n-r)/s+(n0&&l<1?0:a,new Ri(a,s,l,e.opacity)}function aEe(e,t,n,r){return arguments.length===1?nB(e):new Ri(e,t,n,r??1)}function Ri(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}HC(Ri,aEe,tB(Kp,{brighter(e){return e=e==null?Fy:Math.pow(Fy,e),new Ri(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Wh:Math.pow(Wh,e),new Ri(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 yr(ex(e>=240?e-240:e+120,i,r),ex(e,i,r),ex(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Ri(NR(this.h),gv(this.s),gv(this.l),By(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=By(this.opacity);return`${e===1?"hsl(":"hsla("}${NR(this.h)}, ${gv(this.s)*100}%, ${gv(this.l)*100}%${e===1?")":`, ${e})`}`}}));function NR(e){return e=(e||0)%360,e<0?e+360:e}function gv(e){return Math.max(0,Math.min(1,e||0))}function ex(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 GC=e=>()=>e;function sEe(e,t){return function(n){return e+n*t}}function lEe(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 uEe(e){return(e=+e)==1?rB:function(t,n){return n-t?lEe(t,n,e):GC(isNaN(t)?n:t)}}function rB(e,t){var n=t-e;return n?sEe(e,n):GC(isNaN(e)?t:e)}const MR=function e(t){var n=uEe(t);function r(i,o){var a=n((i=rS(i)).r,(o=rS(o)).r),s=n(i.g,o.g),l=n(i.b,o.b),u=rB(i.opacity,o.opacity);return function(f){return i.r=a(f),i.g=s(f),i.b=l(f),i.opacity=u(f),i+""}}return r.gamma=e,r}(1);function cEe(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;in&&(o=t.slice(n,o),s[a]?s[a]+=o:s[++a]=o),(r=r[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,l.push({i:a,x:Uy(r,i)})),n=tx.lastIndex;return nt&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function xEe(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i2?wEe:xEe,l=u=null,d}function d(h){return h==null||isNaN(h=+h)?o:(l||(l=s(e.map(r),t,n)))(r(a(h)))}return d.invert=function(h){return a(i((u||(u=s(t,e.map(r),Uy)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,zy),f()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),f()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),n=qC,f()},d.clamp=function(h){return arguments.length?(a=h?!0:sr,f()):a!==sr},d.interpolate=function(h){return arguments.length?(n=h,f()):n},d.unknown=function(h){return arguments.length?(o=h,d):o},function(h,v){return r=h,i=v,f()}}function KC(){return Ib()(sr,sr)}function OEe(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Vy(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 Pc(e){return e=Vy(Math.abs(e)),e?e[1]:NaN}function SEe(e,t){return function(n,r){for(var i=n.length,o=[],a=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),o.push(n.substring(i-=s,i+s)),!((l+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(t)}}function EEe(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var PEe=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function qh(e){if(!(t=PEe.exec(e)))throw new Error("invalid format: "+e);var t;return new YC({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]})}qh.prototype=YC.prototype;function YC(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+""}YC.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 CEe(e){e:for(var t=e.length,n=1,r=-1,i;n0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var iB;function TEe(e,t){var n=Vy(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(iB=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Vy(e,Math.max(0,t+o-1))[0]}function LR(e,t){var n=Vy(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 $R={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:OEe,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)=>LR(e*100,t),r:LR,s:TEe,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function IR(e){return e}var DR=Array.prototype.map,FR=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function jEe(e){var t=e.grouping===void 0||e.thousands===void 0?IR:SEe(DR.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?IR:EEe(DR.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function u(d){d=qh(d);var h=d.fill,v=d.align,g=d.sign,y=d.symbol,x=d.zero,_=d.width,b=d.comma,w=d.precision,S=d.trim,E=d.type;E==="n"?(b=!0,E="g"):$R[E]||(w===void 0&&(w=12),S=!0,E="g"),(x||h==="0"&&v==="=")&&(x=!0,h="0",v="=");var P=y==="$"?n:y==="#"&&/[boxX]/.test(E)?"0"+E.toLowerCase():"",T=y==="$"?r:/[%p]/.test(E)?a:"",A=$R[E],D=/[defgprs%]/.test(E);w=w===void 0?6:/[gprs]/.test(E)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w));function k(I){var F=P,q=T,W,X,Q;if(E==="c")q=A(I)+q,I="";else{I=+I;var ne=I<0||1/I<0;if(I=isNaN(I)?l:A(Math.abs(I),w),S&&(I=CEe(I)),ne&&+I==0&&g!=="+"&&(ne=!1),F=(ne?g==="("?g:s:g==="-"||g==="("?"":g)+F,q=(E==="s"?FR[8+iB/3]:"")+q+(ne&&g==="("?")":""),D){for(W=-1,X=I.length;++WQ||Q>57){q=(Q===46?i+I.slice(W+1):I.slice(W))+q,I=I.slice(0,W);break}}}b&&!x&&(I=t(I,1/0));var Z=F.length+I.length+q.length,z=Z<_?new Array(_-Z+1).join(h):"";switch(b&&x&&(I=t(z+I,z.length?_-q.length:1/0),z=""),v){case"<":I=F+I+q+z;break;case"=":I=F+z+I+q;break;case"^":I=z.slice(0,Z=z.length>>1)+F+I+q+z.slice(Z);break;default:I=z+F+I+q;break}return o(I)}return k.toString=function(){return d+""},k}function f(d,h){var v=u((d=qh(d),d.type="f",d)),g=Math.max(-8,Math.min(8,Math.floor(Pc(h)/3)))*3,y=Math.pow(10,-g),x=FR[8+g/3];return function(_){return v(y*_)+x}}return{format:u,formatPrefix:f}}var yv,ZC,oB;AEe({thousands:",",grouping:[3],currency:["$",""]});function AEe(e){return yv=jEe(e),ZC=yv.format,oB=yv.formatPrefix,yv}function kEe(e){return Math.max(0,-Pc(Math.abs(e)))}function NEe(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Pc(t)/3)))*3-Pc(Math.abs(e)))}function MEe(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Pc(t)-Pc(e))+1}function aB(e,t,n,r){var i=tS(e,t,n),o;switch(r=qh(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=NEe(i,a))&&(r.precision=o),oB(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=MEe(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=kEe(i))&&(r.precision=o-(r.type==="%")*2);break}}return ZC(r)}function xs(e){var t=e.domain;return e.ticks=function(n){var r=t();return JO(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return aB(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,a=r[i],s=r[o],l,u,f=10;for(s0;){if(u=eS(a,s,n),u===l)return r[i]=a,r[o]=s,t(r);if(u>0)a=Math.floor(a/u)*u,s=Math.ceil(s/u)*u;else if(u<0)a=Math.ceil(a*u)/u,s=Math.floor(s*u)/u;else break;l=u}return e},e}function Wy(){var e=KC();return e.copy=function(){return Yp(e,Wy())},xi.apply(e,arguments),xs(e)}function sB(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,zy),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return sB(e).unknown(t)},e=arguments.length?Array.from(e,zy):[0,1],xs(n)}function lB(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],a;return oMath.pow(e,t)}function DEe(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 zR(e){return(t,n)=>-e(-t,n)}function XC(e){const t=e(BR,UR),n=t.domain;let r=10,i,o;function a(){return i=DEe(r),o=IEe(r),n()[0]<0?(i=zR(i),o=zR(o),e(REe,LEe)):e(BR,UR),t}return t.base=function(s){return arguments.length?(r=+s,a()):r},t.domain=function(s){return arguments.length?(n(s),a()):n()},t.ticks=s=>{const l=n();let u=l[0],f=l[l.length-1];const d=f0){for(;h<=v;++h)for(g=1;gf)break;_.push(y)}}else for(;h<=v;++h)for(g=r-1;g>=1;--g)if(y=h>0?g/o(-h):g*o(h),!(yf)break;_.push(y)}_.length*2{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=qh(l)).precision==null&&(l.trim=!0),l=ZC(l)),s===1/0)return l;const u=Math.max(1,r*s/t.ticks().length);return f=>{let d=f/o(Math.round(i(f)));return d*rn(lB(n(),{floor:s=>o(Math.floor(i(s))),ceil:s=>o(Math.ceil(i(s)))})),t}function uB(){const e=XC(Ib()).domain([1,10]);return e.copy=()=>Yp(e,uB()).base(e.base()),xi.apply(e,arguments),e}function VR(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function WR(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function QC(e){var t=1,n=e(VR(t),WR(t));return n.constant=function(r){return arguments.length?e(VR(t=+r),WR(t)):t},xs(n)}function cB(){var e=QC(Ib());return e.copy=function(){return Yp(e,cB()).constant(e.constant())},xi.apply(e,arguments)}function HR(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function FEe(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function BEe(e){return e<0?-e*e:e*e}function JC(e){var t=e(sr,sr),n=1;function r(){return n===1?e(sr,sr):n===.5?e(FEe,BEe):e(HR(n),HR(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},xs(t)}function eT(){var e=JC(Ib());return e.copy=function(){return Yp(e,eT()).exponent(e.exponent())},xi.apply(e,arguments),e}function UEe(){return eT.apply(null,arguments).exponent(.5)}function GR(e){return Math.sign(e)*e*e}function zEe(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function fB(){var e=KC(),t=[0,1],n=!1,r;function i(o){var a=zEe(e(o));return isNaN(a)?r:n?Math.round(a):a}return i.invert=function(o){return e.invert(GR(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,zy)).map(GR)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return fB(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},xi.apply(i,arguments),xs(i)}function dB(){var e=[],t=[],n=[],r;function i(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a0?n[s-1]:e[0],s=n?[r[n-1],t]:[r[u-1],r[u]]},a.unknown=function(l){return arguments.length&&(o=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return hB().domain([e,t]).range(i).unknown(o)},xi.apply(xs(a),arguments)}function pB(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[qp(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var a=t.indexOf(o);return[e[a-1],e[a]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return pB().domain(e).range(t).unknown(n)},xi.apply(i,arguments)}const nx=new Date,rx=new Date;function yn(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const a=i(o),s=i.ceil(o);return o-a(t(o=new Date(+o),a==null?1:Math.floor(a)),o),i.range=(o,a,s)=>{const l=[];if(o=i.ceil(o),s=s==null?1:Math.floor(s),!(o0))return l;let u;do l.push(u=new Date(+o)),t(o,s),e(o);while(uyn(a=>{if(a>=a)for(;e(a),!o(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!o(a););else for(;--s>=0;)for(;t(a,1),!o(a););}),n&&(i.count=(o,a)=>(nx.setTime(+o),rx.setTime(+a),e(nx),e(rx),Math.floor(n(nx,rx))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?a=>r(a)%o===0:a=>i.count(0,a)%o===0):i)),i}const Hy=yn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Hy.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?yn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Hy);Hy.range;const Bo=1e3,fi=Bo*60,Uo=fi*60,ra=Uo*24,tT=ra*7,qR=ra*30,ix=ra*365,il=yn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Bo)},(e,t)=>(t-e)/Bo,e=>e.getUTCSeconds());il.range;const nT=yn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Bo)},(e,t)=>{e.setTime(+e+t*fi)},(e,t)=>(t-e)/fi,e=>e.getMinutes());nT.range;const rT=yn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*fi)},(e,t)=>(t-e)/fi,e=>e.getUTCMinutes());rT.range;const iT=yn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Bo-e.getMinutes()*fi)},(e,t)=>{e.setTime(+e+t*Uo)},(e,t)=>(t-e)/Uo,e=>e.getHours());iT.range;const oT=yn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Uo)},(e,t)=>(t-e)/Uo,e=>e.getUTCHours());oT.range;const Zp=yn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*fi)/ra,e=>e.getDate()-1);Zp.range;const Db=yn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ra,e=>e.getUTCDate()-1);Db.range;const mB=yn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ra,e=>Math.floor(e/ra));mB.range;function Dl(e){return yn(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())*fi)/tT)}const Fb=Dl(0),Gy=Dl(1),VEe=Dl(2),WEe=Dl(3),Cc=Dl(4),HEe=Dl(5),GEe=Dl(6);Fb.range;Gy.range;VEe.range;WEe.range;Cc.range;HEe.range;GEe.range;function Fl(e){return yn(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)/tT)}const Bb=Fl(0),qy=Fl(1),qEe=Fl(2),KEe=Fl(3),Tc=Fl(4),YEe=Fl(5),ZEe=Fl(6);Bb.range;qy.range;qEe.range;KEe.range;Tc.range;YEe.range;ZEe.range;const aT=yn(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());aT.range;const sT=yn(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());sT.range;const ia=yn(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());ia.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:yn(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)});ia.range;const oa=yn(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());oa.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:yn(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)});oa.range;function vB(e,t,n,r,i,o){const a=[[il,1,Bo],[il,5,5*Bo],[il,15,15*Bo],[il,30,30*Bo],[o,1,fi],[o,5,5*fi],[o,15,15*fi],[o,30,30*fi],[i,1,Uo],[i,3,3*Uo],[i,6,6*Uo],[i,12,12*Uo],[r,1,ra],[r,2,2*ra],[n,1,tT],[t,1,qR],[t,3,3*qR],[e,1,ix]];function s(u,f,d){const h=fx).right(a,h);if(v===a.length)return e.every(tS(u/ix,f/ix,d));if(v===0)return Hy.every(Math.max(tS(u,f,d),1));const[g,y]=a[h/a[v-1][2]53)return null;"w"in Y||(Y.w=1),"Z"in Y?(he=ax(ed(Y.y,0,1)),Se=he.getUTCDay(),he=Se>4||Se===0?qy.ceil(he):qy(he),he=Db.offset(he,(Y.V-1)*7),Y.y=he.getUTCFullYear(),Y.m=he.getUTCMonth(),Y.d=he.getUTCDate()+(Y.w+6)%7):(he=ox(ed(Y.y,0,1)),Se=he.getDay(),he=Se>4||Se===0?Gy.ceil(he):Gy(he),he=Zp.offset(he,(Y.V-1)*7),Y.y=he.getFullYear(),Y.m=he.getMonth(),Y.d=he.getDate()+(Y.w+6)%7)}else("W"in Y||"U"in Y)&&("w"in Y||(Y.w="u"in Y?Y.u%7:"W"in Y?1:0),Se="Z"in Y?ax(ed(Y.y,0,1)).getUTCDay():ox(ed(Y.y,0,1)).getDay(),Y.m=0,Y.d="W"in Y?(Y.w+6)%7+Y.W*7-(Se+5)%7:Y.w+Y.U*7-(Se+6)%7);return"Z"in Y?(Y.H+=Y.Z/100|0,Y.M+=Y.Z%100,ax(Y)):ox(Y)}}function A(N,U,J,Y){for(var oe=0,he=U.length,Se=J.length,se,pe;oe=Se)return-1;if(se=U.charCodeAt(oe++),se===37){if(se=U.charAt(oe++),pe=E[se in KR?U.charAt(oe++):se],!pe||(Y=pe(N,J,Y))<0)return-1}else if(se!=J.charCodeAt(Y++))return-1}return Y}function D(N,U,J){var Y=u.exec(U.slice(J));return Y?(N.p=f.get(Y[0].toLowerCase()),J+Y[0].length):-1}function k(N,U,J){var Y=v.exec(U.slice(J));return Y?(N.w=g.get(Y[0].toLowerCase()),J+Y[0].length):-1}function I(N,U,J){var Y=d.exec(U.slice(J));return Y?(N.w=h.get(Y[0].toLowerCase()),J+Y[0].length):-1}function F(N,U,J){var Y=_.exec(U.slice(J));return Y?(N.m=b.get(Y[0].toLowerCase()),J+Y[0].length):-1}function q(N,U,J){var Y=y.exec(U.slice(J));return Y?(N.m=x.get(Y[0].toLowerCase()),J+Y[0].length):-1}function W(N,U,J){return A(N,t,U,J)}function X(N,U,J){return A(N,n,U,J)}function Q(N,U,J){return A(N,r,U,J)}function ne(N){return a[N.getDay()]}function Z(N){return o[N.getDay()]}function z(N){return l[N.getMonth()]}function B(N){return s[N.getMonth()]}function H(N){return i[+(N.getHours()>=12)]}function ee(N){return 1+~~(N.getMonth()/3)}function K(N){return a[N.getUTCDay()]}function te(N){return o[N.getUTCDay()]}function ie(N){return l[N.getUTCMonth()]}function ae(N){return s[N.getUTCMonth()]}function fe(N){return i[+(N.getUTCHours()>=12)]}function j(N){return 1+~~(N.getUTCMonth()/3)}return{format:function(N){var U=P(N+="",w);return U.toString=function(){return N},U},parse:function(N){var U=T(N+="",!1);return U.toString=function(){return N},U},utcFormat:function(N){var U=P(N+="",S);return U.toString=function(){return N},U},utcParse:function(N){var U=T(N+="",!0);return U.toString=function(){return N},U}}}var KR={"-":"",_:" ",0:"0"},An=/^\s*\d+/,nPe=/^%/,rPe=/[\\^$*+?|[\]().{}]/g;function ht(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o[t.toLowerCase(),n]))}function oPe(e,t,n){var r=An.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function aPe(e,t,n){var r=An.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function sPe(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function lPe(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function uPe(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function YR(e,t,n){var r=An.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function ZR(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function cPe(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 fPe(e,t,n){var r=An.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function dPe(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function XR(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function hPe(e,t,n){var r=An.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function QR(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function pPe(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function mPe(e,t,n){var r=An.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function vPe(e,t,n){var r=An.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function gPe(e,t,n){var r=An.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function yPe(e,t,n){var r=nPe.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function bPe(e,t,n){var r=An.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function _Pe(e,t,n){var r=An.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function JR(e,t){return ht(e.getDate(),t,2)}function xPe(e,t){return ht(e.getHours(),t,2)}function wPe(e,t){return ht(e.getHours()%12||12,t,2)}function OPe(e,t){return ht(1+Zp.count(ia(e),e),t,3)}function gB(e,t){return ht(e.getMilliseconds(),t,3)}function SPe(e,t){return gB(e,t)+"000"}function EPe(e,t){return ht(e.getMonth()+1,t,2)}function PPe(e,t){return ht(e.getMinutes(),t,2)}function CPe(e,t){return ht(e.getSeconds(),t,2)}function TPe(e){var t=e.getDay();return t===0?7:t}function jPe(e,t){return ht(Fb.count(ia(e)-1,e),t,2)}function yB(e){var t=e.getDay();return t>=4||t===0?Cc(e):Cc.ceil(e)}function APe(e,t){return e=yB(e),ht(Cc.count(ia(e),e)+(ia(e).getDay()===4),t,2)}function kPe(e){return e.getDay()}function NPe(e,t){return ht(Gy.count(ia(e)-1,e),t,2)}function MPe(e,t){return ht(e.getFullYear()%100,t,2)}function RPe(e,t){return e=yB(e),ht(e.getFullYear()%100,t,2)}function LPe(e,t){return ht(e.getFullYear()%1e4,t,4)}function $Pe(e,t){var n=e.getDay();return e=n>=4||n===0?Cc(e):Cc.ceil(e),ht(e.getFullYear()%1e4,t,4)}function IPe(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ht(t/60|0,"0",2)+ht(t%60,"0",2)}function eL(e,t){return ht(e.getUTCDate(),t,2)}function DPe(e,t){return ht(e.getUTCHours(),t,2)}function FPe(e,t){return ht(e.getUTCHours()%12||12,t,2)}function BPe(e,t){return ht(1+Db.count(oa(e),e),t,3)}function bB(e,t){return ht(e.getUTCMilliseconds(),t,3)}function UPe(e,t){return bB(e,t)+"000"}function zPe(e,t){return ht(e.getUTCMonth()+1,t,2)}function VPe(e,t){return ht(e.getUTCMinutes(),t,2)}function WPe(e,t){return ht(e.getUTCSeconds(),t,2)}function HPe(e){var t=e.getUTCDay();return t===0?7:t}function GPe(e,t){return ht(Bb.count(oa(e)-1,e),t,2)}function _B(e){var t=e.getUTCDay();return t>=4||t===0?Tc(e):Tc.ceil(e)}function qPe(e,t){return e=_B(e),ht(Tc.count(oa(e),e)+(oa(e).getUTCDay()===4),t,2)}function KPe(e){return e.getUTCDay()}function YPe(e,t){return ht(qy.count(oa(e)-1,e),t,2)}function ZPe(e,t){return ht(e.getUTCFullYear()%100,t,2)}function XPe(e,t){return e=_B(e),ht(e.getUTCFullYear()%100,t,2)}function QPe(e,t){return ht(e.getUTCFullYear()%1e4,t,4)}function JPe(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Tc(e):Tc.ceil(e),ht(e.getUTCFullYear()%1e4,t,4)}function eCe(){return"+0000"}function tL(){return"%"}function nL(e){return+e}function rL(e){return Math.floor(+e/1e3)}var lu,xB,wB;tCe({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 tCe(e){return lu=tPe(e),xB=lu.format,lu.parse,wB=lu.utcFormat,lu.utcParse,lu}function nCe(e){return new Date(e)}function rCe(e){return e instanceof Date?+e:+new Date(+e)}function lT(e,t,n,r,i,o,a,s,l,u){var f=KC(),d=f.invert,h=f.domain,v=u(".%L"),g=u(":%S"),y=u("%I:%M"),x=u("%I %p"),_=u("%a %d"),b=u("%b %d"),w=u("%B"),S=u("%Y");function E(P){return(l(P)t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>GSe(e,o/r))},n.copy=function(){return PB(t).domain(e)},pa.apply(n,arguments)}function zb(){var e=0,t=.5,n=1,r=1,i,o,a,s,l,u=sr,f,d=!1,h;function v(y){return isNaN(y=+y)?h:(y=.5+((y=+f(y))-o)*(r*yt}var AB=cCe,fCe=Vb,dCe=AB,hCe=cf;function pCe(e){return e&&e.length?fCe(e,hCe,dCe):void 0}var mCe=pCe;const Ia=st(mCe);function vCe(e,t){return ee.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=re.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1};Ie.decimalPlaces=Ie.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*jt;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};Ie.dividedBy=Ie.div=function(e){return Ho(this,new this.constructor(e))};Ie.dividedToIntegerBy=Ie.idiv=function(e){var t=this,n=t.constructor;return _t(Ho(t,new n(e),0,1),n.precision)};Ie.equals=Ie.eq=function(e){return!this.cmp(e)};Ie.exponent=function(){return ln(this)};Ie.greaterThan=Ie.gt=function(e){return this.cmp(e)>0};Ie.greaterThanOrEqualTo=Ie.gte=function(e){return this.cmp(e)>=0};Ie.isInteger=Ie.isint=function(){return this.e>this.d.length-2};Ie.isNegative=Ie.isneg=function(){return this.s<0};Ie.isPositive=Ie.ispos=function(){return this.s>0};Ie.isZero=function(){return this.s===0};Ie.lessThan=Ie.lt=function(e){return this.cmp(e)<0};Ie.lessThanOrEqualTo=Ie.lte=function(e){return this.cmp(e)<1};Ie.logarithm=Ie.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq($r))throw Error(bi+"NaN");if(n.s<1)throw Error(bi+(n.s?"NaN":"-Infinity"));return n.eq($r)?new r(0):($t=!1,t=Ho(Kh(n,o),Kh(e,o),o),$t=!0,_t(t,i))};Ie.minus=Ie.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?LB(t,e):MB(t,(e.s=-e.s,e))};Ie.modulo=Ie.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(bi+"NaN");return n.s?($t=!1,t=Ho(n,e,0,1).times(e),$t=!0,n.minus(t)):_t(new r(n),i)};Ie.naturalExponential=Ie.exp=function(){return RB(this)};Ie.naturalLogarithm=Ie.ln=function(){return Kh(this)};Ie.negated=Ie.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};Ie.plus=Ie.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?MB(t,e):LB(t,(e.s=-e.s,e))};Ie.precision=Ie.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(vl+e);if(t=ln(i)+1,r=i.d.length-1,n=r*jt+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};Ie.squareRoot=Ie.sqrt=function(){var e,t,n,r,i,o,a,s=this,l=s.constructor;if(s.s<1){if(!s.s)return new l(0);throw Error(bi+"NaN")}for(e=ln(s),$t=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=fo(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=hf((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 l(t)):r=new l(i.toString()),n=l.precision,i=a=n+3;;)if(o=r,r=o.plus(Ho(s,o,a+2)).times(.5),fo(o.d).slice(0,a)===(t=fo(r.d)).slice(0,a)){if(t=t.slice(a-3,a+1),i==a&&t=="4999"){if(_t(o,n+1,0),o.times(o).eq(s)){r=o;break}}else if(t!="9999")break;a+=4}return $t=!0,_t(r,n)};Ie.times=Ie.mul=function(e){var t,n,r,i,o,a,s,l,u,f=this,d=f.constructor,h=f.d,v=(e=new d(e)).d;if(!f.s||!e.s)return new d(0);for(e.s*=f.s,n=f.e+e.e,l=h.length,u=v.length,l=0;){for(t=0,i=l+r;i>r;)s=o[i]+v[r]*h[i-r-1]+t,o[i--]=s%Sn|0,t=s/Sn|0;o[i]=(o[i]+t)%Sn|0}for(;!o[--a];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,$t?_t(e,d.precision):e};Ie.toDecimalPlaces=Ie.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(wo(e,0,df),t===void 0?t=r.rounding:wo(t,0,8),_t(n,e+ln(n)+1,t))};Ie.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=jl(r,!0):(wo(e,0,df),t===void 0?t=i.rounding:wo(t,0,8),r=_t(new i(r),e+1,t),n=jl(r,!0,e+1)),n};Ie.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?jl(i):(wo(e,0,df),t===void 0?t=o.rounding:wo(t,0,8),r=_t(new o(i),e+ln(i)+1,t),n=jl(r.abs(),!1,e+ln(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};Ie.toInteger=Ie.toint=function(){var e=this,t=e.constructor;return _t(new t(e),ln(e)+1,t.rounding)};Ie.toNumber=function(){return+this};Ie.toPower=Ie.pow=function(e){var t,n,r,i,o,a,s=this,l=s.constructor,u=12,f=+(e=new l(e));if(!e.s)return new l($r);if(s=new l(s),!s.s){if(e.s<1)throw Error(bi+"Infinity");return s}if(s.eq($r))return s;if(r=l.precision,e.eq($r))return _t(s,r);if(t=e.e,n=e.d.length-1,a=t>=n,o=s.s,a){if((n=f<0?-f:f)<=NB){for(i=new l($r),t=Math.ceil(r/jt+4),$t=!1;n%2&&(i=i.times(s),aL(i.d,t)),n=hf(n/2),n!==0;)s=s.times(s),aL(s.d,t);return $t=!0,e.s<0?new l($r).div(i):_t(i,r)}}else if(o<0)throw Error(bi+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,$t=!1,i=e.times(Kh(s,r+u)),$t=!0,i=RB(i),i.s=o,i};Ie.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=ln(i),r=jl(i,n<=o.toExpNeg||n>=o.toExpPos)):(wo(e,1,df),t===void 0?t=o.rounding:wo(t,0,8),i=_t(new o(i),e,t),n=ln(i),r=jl(i,e<=n||n<=o.toExpNeg,e)),r};Ie.toSignificantDigits=Ie.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(wo(e,1,df),t===void 0?t=r.rounding:wo(t,0,8)),_t(new r(n),e,t)};Ie.toString=Ie.valueOf=Ie.val=Ie.toJSON=Ie[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=ln(e),n=e.constructor;return jl(e,t<=n.toExpNeg||t>=n.toExpPos)};function MB(e,t){var n,r,i,o,a,s,l,u,f=e.constructor,d=f.precision;if(!e.s||!t.s)return t.s||(t=new f(e)),$t?_t(t,d):t;if(l=e.d,u=t.d,a=e.e,i=t.e,l=l.slice(),o=a-i,o){for(o<0?(r=l,o=-o,s=u.length):(r=u,i=a,s=l.length),a=Math.ceil(d/jt),s=a>s?a+1:s+1,o>s&&(o=s,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(s=l.length,o=u.length,s-o<0&&(o=s,r=u,u=l,l=r),n=0;o;)n=(l[--o]=l[o]+u[o]+n)/Sn|0,l[o]%=Sn;for(n&&(l.unshift(n),++i),s=l.length;l[--s]==0;)l.pop();return t.d=l,t.e=i,$t?_t(t,d):t}function wo(e,t,n){if(e!==~~e||en)throw Error(vl+e)}function fo(e){var t,n,r,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;ta?1:-1;else for(s=l=0;si[s]?1:-1;break}return l}function n(r,i,o){for(var a=0;o--;)r[o]-=a,a=r[o]1;)r.shift()}return function(r,i,o,a){var s,l,u,f,d,h,v,g,y,x,_,b,w,S,E,P,T,A,D=r.constructor,k=r.s==i.s?1:-1,I=r.d,F=i.d;if(!r.s)return new D(r);if(!i.s)throw Error(bi+"Division by zero");for(l=r.e-i.e,T=F.length,E=I.length,v=new D(k),g=v.d=[],u=0;F[u]==(I[u]||0);)++u;if(F[u]>(I[u]||0)&&--l,o==null?b=o=D.precision:a?b=o+(ln(r)-ln(i))+1:b=o,b<0)return new D(0);if(b=b/jt+2|0,u=0,T==1)for(f=0,F=F[0],b++;(u1&&(F=e(F,f),I=e(I,f),T=F.length,E=I.length),S=T,y=I.slice(0,T),x=y.length;x=Sn/2&&++P;do f=0,s=t(F,y,T,x),s<0?(_=y[0],T!=x&&(_=_*Sn+(y[1]||0)),f=_/P|0,f>1?(f>=Sn&&(f=Sn-1),d=e(F,f),h=d.length,x=y.length,s=t(d,y,h,x),s==1&&(f--,n(d,T16)throw Error(fT+ln(e));if(!e.s)return new f($r);for(t==null?($t=!1,s=d):s=t,a=new f(.03125);e.abs().gte(.1);)e=e.times(a),u+=5;for(r=Math.log(Hs(2,u))/Math.LN10*2+5|0,s+=r,n=i=o=new f($r),f.precision=s;;){if(i=_t(i.times(e),s),n=n.times(++l),a=o.plus(Ho(i,n,s)),fo(a.d).slice(0,s)===fo(o.d).slice(0,s)){for(;u--;)o=_t(o.times(o),s);return f.precision=d,t==null?($t=!0,_t(o,d)):o}o=a}}function ln(e){for(var t=e.e*jt,n=e.d[0];n>=10;n/=10)t++;return t}function sx(e,t,n){if(t>e.LN10.sd())throw $t=!0,n&&(e.precision=n),Error(bi+"LN10 precision limit exceeded");return _t(new e(e.LN10),t)}function ja(e){for(var t="";e--;)t+="0";return t}function Kh(e,t){var n,r,i,o,a,s,l,u,f,d=1,h=10,v=e,g=v.d,y=v.constructor,x=y.precision;if(v.s<1)throw Error(bi+(v.s?"NaN":"-Infinity"));if(v.eq($r))return new y(0);if(t==null?($t=!1,u=x):u=t,v.eq(10))return t==null&&($t=!0),sx(y,u);if(u+=h,y.precision=u,n=fo(g),r=n.charAt(0),o=ln(v),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)v=v.times(e),n=fo(v.d),r=n.charAt(0),d++;o=ln(v),r>1?(v=new y("0."+n),o++):v=new y(r+"."+n.slice(1))}else return l=sx(y,u+2,x).times(o+""),v=Kh(new y(r+"."+n.slice(1)),u-h).plus(l),y.precision=x,t==null?($t=!0,_t(v,x)):v;for(s=a=v=Ho(v.minus($r),v.plus($r),u),f=_t(v.times(v),u),i=3;;){if(a=_t(a.times(f),u),l=s.plus(Ho(a,new y(i),u)),fo(l.d).slice(0,u)===fo(s.d).slice(0,u))return s=s.times(2),o!==0&&(s=s.plus(sx(y,u+2,x).times(o+""))),s=Ho(s,new y(d),u),y.precision=x,t==null?($t=!0,_t(s,x)):s;s=l,i+=2}}function oL(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=hf(n/jt),e.d=[],r=(n+1)%jt,n<0&&(r+=jt),rKy||e.e<-Ky))throw Error(fT+n)}else e.s=0,e.e=0,e.d=[0];return e}function _t(e,t,n){var r,i,o,a,s,l,u,f,d=e.d;for(a=1,o=d[0];o>=10;o/=10)a++;if(r=t-a,r<0)r+=jt,i=t,u=d[f=0];else{if(f=Math.ceil((r+1)/jt),o=d.length,f>=o)return e;for(u=o=d[f],a=1;o>=10;o/=10)a++;r%=jt,i=r-jt+a}if(n!==void 0&&(o=Hs(10,a-i-1),s=u/o%10|0,l=t<0||d[f+1]!==void 0||u%o,l=n<4?(s||l)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||l||n==6&&(r>0?i>0?u/Hs(10,a-i):0:d[f-1])%10&1||n==(e.s<0?8:7))),t<1||!d[0])return l?(o=ln(e),d.length=1,t=t-o-1,d[0]=Hs(10,(jt-t%jt)%jt),e.e=hf(-t/jt)||0):(d.length=1,d[0]=e.e=e.s=0),e;if(r==0?(d.length=f,o=1,f--):(d.length=f+1,o=Hs(10,jt-r),d[f]=i>0?(u/Hs(10,a-i)%Hs(10,i)|0)*o:0),l)for(;;)if(f==0){(d[0]+=o)==Sn&&(d[0]=1,++e.e);break}else{if(d[f]+=o,d[f]!=Sn)break;d[f--]=0,o=1}for(r=d.length;d[--r]===0;)d.pop();if($t&&(e.e>Ky||e.e<-Ky))throw Error(fT+ln(e));return e}function LB(e,t){var n,r,i,o,a,s,l,u,f,d,h=e.constructor,v=h.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new h(e),$t?_t(t,v):t;if(l=e.d,d=t.d,r=t.e,u=e.e,l=l.slice(),a=u-r,a){for(f=a<0,f?(n=l,a=-a,s=d.length):(n=d,r=u,s=l.length),i=Math.max(Math.ceil(v/jt),s)+2,a>i&&(a=i,n.length=1),n.reverse(),i=a;i--;)n.push(0);n.reverse()}else{for(i=l.length,s=d.length,f=i0;--i)l[s++]=0;for(i=d.length;i>a;){if(l[--i]0?o=o.charAt(0)+"."+o.slice(1)+ja(r):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+ja(-i-1)+o,n&&(r=n-a)>0&&(o+=ja(r))):i>=a?(o+=ja(i+1-a),n&&(r=n-i-1)>0&&(o=o+"."+ja(r))):((r=i+1)0&&(i+1===a&&(o+="."),o+=ja(r))),e.s<0?"-"+o:o}function aL(e,t){if(e.length>t)return e.length=t,!0}function $B(e){var t,n,r;function i(o){var a=this;if(!(a instanceof i))return new i(o);if(a.constructor=i,o instanceof i){a.s=o.s,a.e=o.e,a.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(vl+o);if(o>0)a.s=1;else if(o<0)o=-o,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(o===~~o&&o<1e7){a.e=0,a.d=[o];return}return oL(a,o.toString())}else if(typeof o!="string")throw Error(vl+o);if(o.charCodeAt(0)===45?(o=o.slice(1),a.s=-1):a.s=1,ICe.test(o))oL(a,o);else throw Error(vl+o)}if(i.prototype=Ie,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=$B,i.config=i.set=DCe,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(vl+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(vl+n+": "+r);return this}var dT=$B($Ce);$r=new dT(1);const yt=dT;function FCe(e){return VCe(e)||zCe(e)||UCe(e)||BCe()}function BCe(){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 UCe(e,t){if(e){if(typeof e=="string")return aS(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 aS(e,t)}}function zCe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function VCe(e){if(Array.isArray(e))return aS(e)}function aS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=t?n.apply(void 0,i):e(t-a,sL(function(){for(var s=arguments.length,l=new Array(s),u=0;ue.length)&&(t=e.length);for(var n=0,r=new Array(t);n"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,o=void 0;try{for(var a=e[Symbol.iterator](),s;!(r=(s=a.next()).done)&&(n.push(s.value),!(t&&n.length===t));r=!0);}catch(l){i=!0,o=l}finally{try{!r&&a.return!=null&&a.return()}finally{if(i)throw o}}return n}}function iTe(e){if(Array.isArray(e))return e}function UB(e){var t=Yh(e,2),n=t[0],r=t[1],i=n,o=r;return n>r&&(i=r,o=n),[i,o]}function zB(e,t,n){if(e.lte(0))return new yt(0);var r=Gb.getDigitCount(e.toNumber()),i=new yt(10).pow(r),o=e.div(i),a=r!==1?.05:.1,s=new yt(Math.ceil(o.div(a).toNumber())).add(n).mul(a),l=s.mul(i);return t?l:new yt(Math.ceil(l))}function oTe(e,t,n){var r=1,i=new yt(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new yt(10).pow(Gb.getDigitCount(e)-1),i=new yt(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new yt(Math.floor(e)))}else e===0?i=new yt(Math.floor((t-1)/2)):n||(i=new yt(Math.floor(e)));var a=Math.floor((t-1)/2),s=qCe(GCe(function(l){return i.add(new yt(l-a).mul(r)).toNumber()}),sS);return s(0,t)}function VB(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new yt(0),tickMin:new yt(0),tickMax:new yt(0)};var o=zB(new yt(t).sub(e).div(n-1),r,i),a;e<=0&&t>=0?a=new yt(0):(a=new yt(e).add(t).div(2),a=a.sub(new yt(a).mod(o)));var s=Math.ceil(a.sub(e).div(o).toNumber()),l=Math.ceil(new yt(t).sub(a).div(o).toNumber()),u=s+l+1;return u>n?VB(e,t,n,r,i+1):(u0?l+(n-u):l,s=t>0?s:s+(n-u)),{step:o,tickMin:a.sub(new yt(s).mul(o)),tickMax:a.add(new yt(l).mul(o))})}function aTe(e){var t=Yh(e,2),n=t[0],r=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=Math.max(i,2),s=UB([n,r]),l=Yh(s,2),u=l[0],f=l[1];if(u===-1/0||f===1/0){var d=f===1/0?[u].concat(uS(sS(0,i-1).map(function(){return 1/0}))):[].concat(uS(sS(0,i-1).map(function(){return-1/0})),[f]);return n>r?lS(d):d}if(u===f)return oTe(u,i,o);var h=VB(u,f,a,o),v=h.step,g=h.tickMin,y=h.tickMax,x=Gb.rangeStep(g,y.add(new yt(.1).mul(v)),v);return n>r?lS(x):x}function sTe(e,t){var n=Yh(e,2),r=n[0],i=n[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=UB([r,i]),s=Yh(a,2),l=s[0],u=s[1];if(l===-1/0||u===1/0)return[r,i];if(l===u)return[l];var f=Math.max(t,2),d=zB(new yt(u).sub(l).div(f-1),o,0),h=[].concat(uS(Gb.rangeStep(new yt(l),new yt(u).sub(new yt(.99).mul(d)),d)),[u]);return r>i?lS(h):h}var lTe=FB(aTe),uTe=FB(sTe),cTe="Invariant failed";function Al(e,t){if(!e)throw new Error(cTe)}var fTe=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function Yy(){return Yy=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function yTe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function pf(e){var t=e.offset,n=e.layout,r=e.width,i=e.dataKey,o=e.data,a=e.dataPointFormatter,s=e.xAxis,l=e.yAxis,u=gTe(e,fTe),f=De(u,!1);e.direction==="x"&&s.type!=="number"&&Al(!1);var d=o.map(function(h){var v=a(h,i),g=v.x,y=v.y,x=v.value,_=v.errorVal;if(!_)return null;var b=[],w,S;if(Array.isArray(_)){var E=dTe(_,2);w=E[0],S=E[1]}else w=S=_;if(n==="vertical"){var P=s.scale,T=y+t,A=T+r,D=T-r,k=P(x-w),I=P(x+S);b.push({x1:I,y1:A,x2:I,y2:D}),b.push({x1:k,y1:T,x2:I,y2:T}),b.push({x1:k,y1:A,x2:k,y2:D})}else if(n==="horizontal"){var F=l.scale,q=g+t,W=q-r,X=q+r,Q=F(x-w),ne=F(x+S);b.push({x1:W,y1:ne,x2:X,y2:ne}),b.push({x1:q,y1:Q,x2:q,y2:ne}),b.push({x1:W,y1:Q,x2:X,y2:Q})}return V.createElement(Qe,Yy({className:"recharts-errorBar",key:"bar-".concat(b.map(function(Z){return"".concat(Z.x1,"-").concat(Z.x2,"-").concat(Z.y1,"-").concat(Z.y2)}))},f),b.map(function(Z){return V.createElement("line",Yy({},Z,{key:"line-".concat(Z.x1,"-").concat(Z.x2,"-").concat(Z.y1,"-").concat(Z.y2)}))}))});return V.createElement(Qe,{className:"recharts-errorBars"},d)}pf.defaultProps={stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"};pf.displayName="ErrorBar";function Zh(e){"@babel/helpers - typeof";return Zh=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},Zh(e)}function uL(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 lx(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,a=-1,s=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(s<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var l=o.range,u=0;u0?i[u-1].coordinate:i[s-1].coordinate,d=i[u].coordinate,h=u>=s-1?i[0].coordinate:i[u+1].coordinate,v=void 0;if(or(d-f)!==or(h-d)){var g=[];if(or(h-d)===or(l[1]-l[0])){v=h;var y=d+l[1]-l[0];g[0]=Math.min(y,(y+f)/2),g[1]=Math.max(y,(y+f)/2)}else{v=f;var x=h+l[1]-l[0];g[0]=Math.min(d,(x+d)/2),g[1]=Math.max(d,(x+d)/2)}var _=[Math.min(d,(v+d)/2),Math.max(d,(v+d)/2)];if(t>_[0]&&t<=_[1]||t>=g[0]&&t<=g[1]){a=i[u].index;break}}else{var b=Math.min(f,h),w=Math.max(f,h);if(t>(b+d)/2&&t<=(w+d)/2){a=i[u].index;break}}}else for(var S=0;S0&&S(r[S].coordinate+r[S-1].coordinate)/2&&t<=(r[S].coordinate+r[S+1].coordinate)/2||S===s-1&&t>(r[S].coordinate+r[S-1].coordinate)/2){a=r[S].index;break}return a},hT=function(t){var n=t,r=n.type.displayName,i=t.props,o=i.stroke,a=i.fill,s;switch(r){case"Line":s=o;break;case"Area":case"Radar":s=o&&o!=="none"?o:a;break;default:s=a;break}return s},jTe=function(t){var n=t.barSize,r=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var a={},s=Object.keys(o),l=0,u=s.length;l=0});if(_&&_.length){var b=_[0].props.barSize,w=_[0].props[x];a[w]||(a[w]=[]);var S=ze(b)?n:b;a[w].push({item:_[0],stackList:_.slice(1),barSize:ze(S)?void 0:ar(S,r,0)})}}return a},ATe=function(t){var n=t.barGap,r=t.barCategoryGap,i=t.bandSize,o=t.sizeList,a=o===void 0?[]:o,s=t.maxBarSize,l=a.length;if(l<1)return null;var u=ar(n,i,0,!0),f,d=[];if(a[0].barSize===+a[0].barSize){var h=!1,v=i/l,g=a.reduce(function(S,E){return S+E.barSize||0},0);g+=(l-1)*u,g>=i&&(g-=(l-1)*u,u=0),g>=i&&v>0&&(h=!0,v*=.9,g=l*v);var y=(i-g)/2>>0,x={offset:y-u,size:0};f=a.reduce(function(S,E){var P={item:E.item,position:{offset:x.offset+x.size+u,size:h?v:E.barSize}},T=[].concat(fL(S),[P]);return x=T[T.length-1].position,E.stackList&&E.stackList.length&&E.stackList.forEach(function(A){T.push({item:A,position:x})}),T},d)}else{var _=ar(r,i,0,!0);i-2*_-(l-1)*u<=0&&(u=0);var b=(i-2*_-(l-1)*u)/l;b>1&&(b>>=0);var w=s===+s?Math.min(b,s):b;f=a.reduce(function(S,E,P){var T=[].concat(fL(S),[{item:E.item,position:{offset:_+(b+u)*P+(b-w)/2,size:w}}]);return E.stackList&&E.stackList.length&&E.stackList.forEach(function(A){T.push({item:A,position:T[T.length-1].position})}),T},d)}return f},kTe=function(t,n,r,i){var o=r.children,a=r.width,s=r.margin,l=a-(s.left||0)-(s.right||0),u=WB({children:o,legendWidth:l});if(u){var f=i||{},d=f.width,h=f.height,v=u.align,g=u.verticalAlign,y=u.layout;if((y==="vertical"||y==="horizontal"&&g==="middle")&&v!=="center"&&Ee(t[v]))return si(si({},t),{},Xu({},v,t[v]+(d||0)));if((y==="horizontal"||y==="vertical"&&v==="center")&&g!=="middle"&&Ee(t[g]))return si(si({},t),{},Xu({},g,t[g]+(h||0)))}return t},NTe=function(t,n,r){return ze(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},HB=function(t,n,r,i,o){var a=n.props.children,s=cr(a,pf).filter(function(u){return NTe(i,o,u.props.direction)});if(s&&s.length){var l=s.map(function(u){return u.props.dataKey});return t.reduce(function(u,f){var d=kt(f,r);if(ze(d))return u;var h=Array.isArray(d)?[Wb(d),Ia(d)]:[d,d],v=l.reduce(function(g,y){var x=kt(f,y,0),_=h[0]-Math.abs(Array.isArray(x)?x[0]:x),b=h[1]+Math.abs(Array.isArray(x)?x[1]:x);return[Math.min(_,g[0]),Math.max(b,g[1])]},[1/0,-1/0]);return[Math.min(v[0],u[0]),Math.max(v[1],u[1])]},[1/0,-1/0])}return null},MTe=function(t,n,r,i,o){var a=n.map(function(s){return HB(t,s,r,o,i)}).filter(function(s){return!ze(s)});return a&&a.length?a.reduce(function(s,l){return[Math.min(s[0],l[0]),Math.max(s[1],l[1])]},[1/0,-1/0]):null},GB=function(t,n,r,i,o){var a=n.map(function(l){var u=l.props.dataKey;return r==="number"&&u&&HB(t,l,u,i)||zd(t,u,r,o)});if(r==="number")return a.reduce(function(l,u){return[Math.min(l[0],u[0]),Math.max(l[1],u[1])]},[1/0,-1/0]);var s={};return a.reduce(function(l,u){for(var f=0,d=u.length;f=2?or(s[0]-s[1])*2*u:u,n&&(t.ticks||t.niceTicks)){var f=(t.ticks||t.niceTicks).map(function(d){var h=o?o.indexOf(d):d;return{coordinate:i(h)+u,value:d,offset:u}});return f.filter(function(d){return!sf(d.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(d,h){return{coordinate:i(d)+u,value:d,index:h,offset:u}}):i.ticks&&!r?i.ticks(t.tickCount).map(function(d){return{coordinate:i(d)+u,value:d,offset:u}}):i.domain().map(function(d,h){return{coordinate:i(d)+u,value:o?o[d]:d,index:h,offset:u}})},ux=new WeakMap,bv=function(t,n){if(typeof n!="function")return t;ux.has(t)||ux.set(t,new WeakMap);var r=ux.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},YB=function(t,n,r){var i=t.scale,o=t.type,a=t.layout,s=t.axisType;if(i==="auto")return a==="radial"&&s==="radiusAxis"?{scale:Vh(),realScaleType:"band"}:a==="radial"&&s==="angleAxis"?{scale:Wy(),realScaleType:"linear"}:o==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:Ud(),realScaleType:"point"}:o==="category"?{scale:Vh(),realScaleType:"band"}:{scale:Wy(),realScaleType:"linear"};if(Hp(i)){var l="scale".concat(jb(i));return{scale:(iL[l]||Ud)(),realScaleType:iL[l]?l:"point"}}return We(i)?{scale:i}:{scale:Ud(),realScaleType:"point"}},dL=1e-4,ZB=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,i=t.range(),o=Math.min(i[0],i[1])-dL,a=Math.max(i[0],i[1])+dL,s=t(n[0]),l=t(n[r-1]);(sa||la)&&t.domain([n[0],n[r-1]])}},RTe=function(t,n){if(!t)return null;for(var r=0,i=t.length;ri)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]=0?(t[s][r][0]=o,t[s][r][1]=o+l,o=t[s][r][1]):(t[s][r][0]=a,t[s][r][1]=a+l,a=t[s][r][1])}},ITe=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r=0?(t[a][r][0]=o,t[a][r][1]=o+s,o=t[a][r][1]):(t[a][r][0]=0,t[a][r][1]=0)}},DTe={sign:$Te,expand:vye,none:xc,silhouette:gye,wiggle:yye,positive:ITe},FTe=function(t,n,r){var i=n.map(function(s){return s.props.dataKey}),o=DTe[r],a=mye().keys(i).value(function(s,l){return+kt(s,l,0)}).order($O).offset(o);return a(t)},BTe=function(t,n,r,i,o,a){if(!t)return null;var s=a?n.reverse():n,l={},u=s.reduce(function(d,h){var v=h.props,g=v.stackId,y=v.hide;if(y)return d;var x=h.props[r],_=d[x]||{hasStack:!1,stackGroups:{}};if(pn(g)){var b=_.stackGroups[g]||{numericAxisId:r,cateAxisId:i,items:[]};b.items.push(h),_.hasStack=!0,_.stackGroups[g]=b}else _.stackGroups[_s("_stackId_")]={numericAxisId:r,cateAxisId:i,items:[h]};return si(si({},d),{},Xu({},x,_))},l),f={};return Object.keys(u).reduce(function(d,h){var v=u[h];if(v.hasStack){var g={};v.stackGroups=Object.keys(v.stackGroups).reduce(function(y,x){var _=v.stackGroups[x];return si(si({},y),{},Xu({},x,{numericAxisId:r,cateAxisId:i,items:_.items,stackedData:FTe(t,_.items,o)}))},g)}return si(si({},d),{},Xu({},h,v))},f)},XB=function(t,n){var r=n.realScaleType,i=n.type,o=n.tickCount,a=n.originalDomain,s=n.allowDecimals,l=r||n.scale;if(l!=="auto"&&l!=="linear")return null;if(o&&i==="number"&&a&&(a[0]==="auto"||a[1]==="auto")){var u=t.domain();if(!u.length)return null;var f=lTe(u,o,s);return t.domain([Wb(f),Ia(f)]),{niceTicks:f}}if(o&&i==="number"){var d=t.domain(),h=uTe(d,o,s);return{niceTicks:h}}return null};function jc(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,o=e.index,a=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!ze(i[t.dataKey])){var s=Oy(n,"value",i[t.dataKey]);if(s)return s.coordinate+r/2}return n[o]?n[o].coordinate+r/2:null}var l=kt(i,ze(a)?t.dataKey:a);return ze(l)?null:t.scale(l)}var hL=function(t){var n=t.axis,r=t.ticks,i=t.offset,o=t.bandSize,a=t.entry,s=t.index;if(n.type==="category")return r[s]?r[s].coordinate+i:null;var l=kt(a,n.dataKey,n.domain[s]);return ze(l)?null:n.scale(l)-o/2+i},UTe=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var i=Math.min(r[0],r[1]),o=Math.max(r[0],r[1]);return i<=0&&o>=0?0:o<0?o:i}return r[0]},zTe=function(t,n){var r=t.props.stackId;if(pn(r)){var i=n[r];if(i){var o=i.items.indexOf(t);return o>=0?i.stackedData[o]:null}}return null},VTe=function(t){return t.reduce(function(n,r){return[Wb(r.concat([n[0]]).filter(Ee)),Ia(r.concat([n[1]]).filter(Ee))]},[1/0,-1/0])},QB=function(t,n,r){return Object.keys(t).reduce(function(i,o){var a=t[o],s=a.stackedData,l=s.reduce(function(u,f){var d=VTe(f.slice(n,r+1));return[Math.min(u[0],d[0]),Math.max(u[1],d[1])]},[1/0,-1/0]);return[Math.min(l[0],i[0]),Math.max(l[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},pL=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,mL=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,dS=function(t,n,r){if(We(t))return t(n,r);if(!Array.isArray(t))return n;var i=[];if(Ee(t[0]))i[0]=r?t[0]:Math.min(t[0],n[0]);else if(pL.test(t[0])){var o=+pL.exec(t[0])[1];i[0]=n[0]-o}else We(t[0])?i[0]=t[0](n[0]):i[0]=n[0];if(Ee(t[1]))i[1]=r?t[1]:Math.max(t[1],n[1]);else if(mL.test(t[1])){var a=+mL.exec(t[1])[1];i[1]=n[1]+a}else We(t[1])?i[1]=t[1](n[1]):i[1]=n[1];return i},Zy=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!r||i>0)return i}if(t&&n&&n.length>=2){for(var o=BC(n,function(d){return d.coordinate}),a=1/0,s=1,l=o.length;se.length)&&(t=e.length);for(var n=0,r=new Array(t);n2&&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},QTe=function(t,n,r,i,o){var a=t.width,s=t.height,l=t.startAngle,u=t.endAngle,f=ar(t.cx,a,a/2),d=ar(t.cy,s,s/2),h=tU(a,s,r),v=ar(t.innerRadius,h,0),g=ar(t.outerRadius,h,h*.8),y=Object.keys(n);return y.reduce(function(x,_){var b=n[_],w=b.domain,S=b.reversed,E;if(ze(b.range))i==="angleAxis"?E=[l,u]:i==="radiusAxis"&&(E=[v,g]),S&&(E=[E[1],E[0]]);else{E=b.range;var P=E,T=GTe(P,2);l=T[0],u=T[1]}var A=YB(b,o),D=A.realScaleType,k=A.scale;k.domain(w).range(E),ZB(k);var I=XB(k,$o($o({},b),{},{realScaleType:D})),F=$o($o($o({},b),I),{},{range:E,radius:g,realScaleType:D,scale:k,cx:f,cy:d,innerRadius:v,outerRadius:g,startAngle:l,endAngle:u});return $o($o({},x),{},eU({},_,F))},{})},JTe=function(t,n){var r=t.x,i=t.y,o=n.x,a=n.y;return Math.sqrt(Math.pow(r-o,2)+Math.pow(i-a,2))},eje=function(t,n){var r=t.x,i=t.y,o=n.cx,a=n.cy,s=JTe({x:r,y:i},{x:o,y:a});if(s<=0)return{radius:s};var l=(r-o)/s,u=Math.acos(l);return i>a&&(u=2*Math.PI-u),{radius:s,angle:XTe(u),angleInRadian:u}},tje=function(t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),o=Math.floor(r/360),a=Math.min(i,o);return{startAngle:n-a*360,endAngle:r-a*360}},nje=function(t,n){var r=n.startAngle,i=n.endAngle,o=Math.floor(r/360),a=Math.floor(i/360),s=Math.min(o,a);return t+s*360},bL=function(t,n){var r=t.x,i=t.y,o=eje({x:r,y:i},n),a=o.radius,s=o.angle,l=n.innerRadius,u=n.outerRadius;if(au)return!1;if(a===0)return!0;var f=tje(n),d=f.startAngle,h=f.endAngle,v=s,g;if(d<=h){for(;v>h;)v-=360;for(;v=d&&v<=h}else{for(;v>d;)v-=360;for(;v=h&&v<=d}return g?$o($o({},n),{},{radius:a,angle:nje(v,n)}):null},nU=function(t){return!R.isValidElement(t)&&!We(t)&&typeof t!="boolean"?t.className:""};function Jh(e){"@babel/helpers - typeof";return Jh=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},Jh(e)}var rje=["offset"];function ije(e){return lje(e)||sje(e)||aje(e)||oje()}function oje(){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 aje(e,t){if(e){if(typeof e=="string")return hS(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 hS(e,t)}}function sje(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function lje(e){if(Array.isArray(e))return hS(e)}function hS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function cje(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function _L(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 cn(e){for(var t=1;t=0?1:-1,w,S;i==="insideStart"?(w=v+b*a,S=y):i==="insideEnd"?(w=g-b*a,S=!y):i==="end"&&(w=g+b*a,S=y),S=_<=0?S:!S;var E=Et(u,f,x,w),P=Et(u,f,x,w+(S?1:-1)*359),T="M".concat(E.x,",").concat(E.y,` A`).concat(x,",").concat(x,",0,1,").concat(S?0:1,`, `).concat(P.x,",").concat(P.y),A=ze(t.id)?_s("recharts-radial-line-"):t.id;return V.createElement("text",ep({},r,{dominantBaseline:"central",className:Pe("recharts-radial-bar-label",s)}),V.createElement("defs",null,V.createElement("path",{id:A,d:T})),V.createElement("textPath",{xlinkHref:"#".concat(A)},n))},gje=function(t){var n=t.viewBox,r=t.offset,i=t.position,o=n,a=o.cx,s=o.cy,l=o.innerRadius,u=o.outerRadius,f=o.startAngle,d=o.endAngle,h=(f+d)/2;if(i==="outside"){var v=Et(a,s,u+r,h),g=v.x,y=v.y;return{x:g,y,textAnchor:g>=a?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:a,y:s,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:a,y:s,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:a,y:s,textAnchor:"middle",verticalAnchor:"end"};var x=(l+u)/2,_=Et(a,s,x,h),b=_.x,w=_.y;return{x:b,y:w,textAnchor:"middle",verticalAnchor:"middle"}},yje=function(t){var n=t.viewBox,r=t.parentViewBox,i=t.offset,o=t.position,a=n,s=a.x,l=a.y,u=a.width,f=a.height,d=f>=0?1:-1,h=d*i,v=d>0?"end":"start",g=d>0?"start":"end",y=u>=0?1:-1,x=y*i,_=y>0?"end":"start",b=y>0?"start":"end";if(o==="top"){var w={x:s+u/2,y:l-d*i,textAnchor:"middle",verticalAnchor:v};return cn(cn({},w),r?{height:Math.max(l-r.y,0),width:u}:{})}if(o==="bottom"){var S={x:s+u/2,y:l+f+h,textAnchor:"middle",verticalAnchor:g};return cn(cn({},S),r?{height:Math.max(r.y+r.height-(l+f),0),width:u}:{})}if(o==="left"){var E={x:s-x,y:l+f/2,textAnchor:_,verticalAnchor:"middle"};return cn(cn({},E),r?{width:Math.max(E.x-r.x,0),height:f}:{})}if(o==="right"){var P={x:s+u+x,y:l+f/2,textAnchor:b,verticalAnchor:"middle"};return cn(cn({},P),r?{width:Math.max(r.x+r.width-P.x,0),height:f}:{})}var T=r?{width:u,height:f}:{};return o==="insideLeft"?cn({x:s+x,y:l+f/2,textAnchor:b,verticalAnchor:"middle"},T):o==="insideRight"?cn({x:s+u-x,y:l+f/2,textAnchor:_,verticalAnchor:"middle"},T):o==="insideTop"?cn({x:s+u/2,y:l+h,textAnchor:"middle",verticalAnchor:g},T):o==="insideBottom"?cn({x:s+u/2,y:l+f-h,textAnchor:"middle",verticalAnchor:v},T):o==="insideTopLeft"?cn({x:s+x,y:l+h,textAnchor:b,verticalAnchor:g},T):o==="insideTopRight"?cn({x:s+u-x,y:l+h,textAnchor:_,verticalAnchor:g},T):o==="insideBottomLeft"?cn({x:s+x,y:l+f-h,textAnchor:b,verticalAnchor:v},T):o==="insideBottomRight"?cn({x:s+u-x,y:l+f-h,textAnchor:_,verticalAnchor:v},T):nf(o)&&(Ee(o.x)||nl(o.x))&&(Ee(o.y)||nl(o.y))?cn({x:s+ar(o.x,u),y:l+ar(o.y,f),textAnchor:"end",verticalAnchor:"end"},T):cn({x:s+u/2,y:l+f/2,textAnchor:"middle",verticalAnchor:"middle"},T)},bje=function(t){return"cx"in t&&Ee(t.cx)};function Pn(e){var t=e.offset,n=t===void 0?5:t,r=uje(e,rje),i=cn({offset:n},r),o=i.viewBox,a=i.position,s=i.value,l=i.children,u=i.content,f=i.className,d=f===void 0?"":f,h=i.textBreakAll;if(!o||ze(s)&&ze(l)&&!R.isValidElement(u)&&!We(u))return null;if(R.isValidElement(u))return R.cloneElement(u,i);var v;if(We(u)){if(v=R.createElement(u,i),R.isValidElement(v))return v}else v=pje(i);var g=bje(o),y=De(i,!0);if(g&&(a==="insideStart"||a==="insideEnd"||a==="end"))return vje(i,v,y);var x=g?gje(i):yje(i);return V.createElement(Tl,ep({className:Pe("recharts-label",d)},y,x,{breakAll:h}),v)}Pn.displayName="Label";var rU=function(t){var n=t.cx,r=t.cy,i=t.angle,o=t.startAngle,a=t.endAngle,s=t.r,l=t.radius,u=t.innerRadius,f=t.outerRadius,d=t.x,h=t.y,v=t.top,g=t.left,y=t.width,x=t.height,_=t.clockWise,b=t.labelViewBox;if(b)return b;if(Ee(y)&&Ee(x)){if(Ee(d)&&Ee(h))return{x:d,y:h,width:y,height:x};if(Ee(v)&&Ee(g))return{x:v,y:g,width:y,height:x}}return Ee(d)&&Ee(h)?{x:d,y:h,width:0,height:0}:Ee(n)&&Ee(r)?{cx:n,cy:r,startAngle:o||i||0,endAngle:a||i||0,innerRadius:u||0,outerRadius:f||l||s||0,clockWise:_}:t.viewBox?t.viewBox:{}},_je=function(t,n){return t?t===!0?V.createElement(Pn,{key:"label-implicit",viewBox:n}):pn(t)?V.createElement(Pn,{key:"label-implicit",viewBox:n,value:t}):R.isValidElement(t)?t.type===Pn?R.cloneElement(t,{key:"label-implicit",viewBox:n}):V.createElement(Pn,{key:"label-implicit",content:t,viewBox:n}):We(t)?V.createElement(Pn,{key:"label-implicit",content:t,viewBox:n}):nf(t)?V.createElement(Pn,ep({viewBox:n},t,{key:"label-implicit"})):null:null},xje=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&r&&!t.label)return null;var i=t.children,o=rU(t),a=cr(i,Pn).map(function(l,u){return R.cloneElement(l,{viewBox:n||o,key:"label-".concat(u)})});if(!r)return a;var s=_je(t.label,n||o);return[s].concat(ije(a))};Pn.parseViewBox=rU;Pn.renderCallByParent=xje;function wje(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var Oje=wje;const Sje=st(Oje);function tp(e){"@babel/helpers - typeof";return tp=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},tp(e)}var Eje=["valueAccessor"],Pje=["data","dataKey","clockWise","id","textBreakAll"];function Cje(e){return kje(e)||Aje(e)||jje(e)||Tje()}function Tje(){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 jje(e,t){if(e){if(typeof e=="string")return pS(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 pS(e,t)}}function Aje(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function kje(e){if(Array.isArray(e))return pS(e)}function pS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Lje(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var $je=function(t){return Array.isArray(t.value)?Sje(t.value):t.value};function Bi(e){var t=e.valueAccessor,n=t===void 0?$je:t,r=OL(e,Eje),i=r.data,o=r.dataKey,a=r.clockWise,s=r.id,l=r.textBreakAll,u=OL(r,Pje);return!i||!i.length?null:V.createElement(Qe,{className:"recharts-label-list"},i.map(function(f,d){var h=ze(o)?n(f,d):kt(f&&f.payload,o),v=ze(s)?{}:{id:"".concat(s,"-").concat(d)};return V.createElement(Pn,Qy({},De(f,!0),u,v,{parentViewBox:f.parentViewBox,value:h,textBreakAll:l,viewBox:Pn.parseViewBox(ze(a)?f:wL(wL({},f),{},{clockWise:a})),key:"label-".concat(d),index:d}))}))}Bi.displayName="LabelList";function Ije(e,t){return e?e===!0?V.createElement(Bi,{key:"labelList-implicit",data:t}):V.isValidElement(e)||We(e)?V.createElement(Bi,{key:"labelList-implicit",data:t,content:e}):nf(e)?V.createElement(Bi,Qy({data:t},e,{key:"labelList-implicit"})):null:null}function Dje(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=cr(r,Bi).map(function(a,s){return R.cloneElement(a,{data:t,key:"labelList-".concat(s)})});if(!n)return i;var o=Ije(e.label,t);return[o].concat(Cje(i))}Bi.renderCallByParent=Dje;function np(e){"@babel/helpers - typeof";return np=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},np(e)}function mS(){return mS=Object.assign?Object.assign.bind():function(e){for(var t=1;t180),",").concat(+(a>u),`, `).concat(d.x,",").concat(d.y,` `);if(i>0){var v=Et(n,r,i,a),g=Et(n,r,i,u);h+="L ".concat(g.x,",").concat(g.y,` A `).concat(i,",").concat(i,`,0, `).concat(+(Math.abs(l)>180),",").concat(+(a<=u),`, `).concat(v.x,",").concat(v.y," Z")}else h+="L ".concat(n,",").concat(r," Z");return h},Vje=function(t){var n=t.cx,r=t.cy,i=t.innerRadius,o=t.outerRadius,a=t.cornerRadius,s=t.forceCornerRadius,l=t.cornerIsExternal,u=t.startAngle,f=t.endAngle,d=or(f-u),h=_v({cx:n,cy:r,radius:o,angle:u,sign:d,cornerRadius:a,cornerIsExternal:l}),v=h.circleTangency,g=h.lineTangency,y=h.theta,x=_v({cx:n,cy:r,radius:o,angle:f,sign:-d,cornerRadius:a,cornerIsExternal:l}),_=x.circleTangency,b=x.lineTangency,w=x.theta,S=l?Math.abs(u-f):Math.abs(u-f)-y-w;if(S<0)return s?"M ".concat(g.x,",").concat(g.y,` a`).concat(a,",").concat(a,",0,0,1,").concat(a*2,`,0 a`).concat(a,",").concat(a,",0,0,1,").concat(-a*2,`,0 `):iU({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:u,endAngle:f});var E="M ".concat(g.x,",").concat(g.y,` A`).concat(a,",").concat(a,",0,0,").concat(+(d<0),",").concat(v.x,",").concat(v.y,` A`).concat(o,",").concat(o,",0,").concat(+(S>180),",").concat(+(d<0),",").concat(_.x,",").concat(_.y,` A`).concat(a,",").concat(a,",0,0,").concat(+(d<0),",").concat(b.x,",").concat(b.y,` `);if(i>0){var P=_v({cx:n,cy:r,radius:i,angle:u,sign:d,isExternal:!0,cornerRadius:a,cornerIsExternal:l}),T=P.circleTangency,A=P.lineTangency,D=P.theta,k=_v({cx:n,cy:r,radius:i,angle:f,sign:-d,isExternal:!0,cornerRadius:a,cornerIsExternal:l}),I=k.circleTangency,F=k.lineTangency,q=k.theta,W=l?Math.abs(u-f):Math.abs(u-f)-D-q;if(W<0&&a===0)return"".concat(E,"L").concat(n,",").concat(r,"Z");E+="L".concat(F.x,",").concat(F.y,` A`).concat(a,",").concat(a,",0,0,").concat(+(d<0),",").concat(I.x,",").concat(I.y,` A`).concat(i,",").concat(i,",0,").concat(+(W>180),",").concat(+(d>0),",").concat(T.x,",").concat(T.y,` A`).concat(a,",").concat(a,",0,0,").concat(+(d<0),",").concat(A.x,",").concat(A.y,"Z")}else E+="L".concat(n,",").concat(r,"Z");return E},Wje={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},oU=function(t){var n=EL(EL({},Wje),t),r=n.cx,i=n.cy,o=n.innerRadius,a=n.outerRadius,s=n.cornerRadius,l=n.forceCornerRadius,u=n.cornerIsExternal,f=n.startAngle,d=n.endAngle,h=n.className;if(a0&&Math.abs(f-d)<360?x=Vje({cx:r,cy:i,innerRadius:o,outerRadius:a,cornerRadius:Math.min(y,g/2),forceCornerRadius:l,cornerIsExternal:u,startAngle:f,endAngle:d}):x=iU({cx:r,cy:i,innerRadius:o,outerRadius:a,startAngle:f,endAngle:d}),V.createElement("path",mS({},De(n,!0),{className:v,d:x,role:"img"}))};function rp(e){"@babel/helpers - typeof";return rp=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},rp(e)}function vS(){return vS=Object.assign?Object.assign.bind():function(e){for(var t=1;t0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function eAe(e,t){return mf(e.getTime(),t.getTime())}function ML(e,t,n){if(e.size!==t.size)return!1;for(var r={},i=e.entries(),o=0,a,s;(a=i.next())&&!a.done;){for(var l=t.entries(),u=!1,f=0;(s=l.next())&&!s.done;){var d=a.value,h=d[0],v=d[1],g=s.value,y=g[0],x=g[1];!u&&!r[f]&&(u=n.equals(h,y,o,f,e,t,n)&&n.equals(v,x,h,y,e,t,n))&&(r[f]=!0),f++}if(!u)return!1;o++}return!0}function tAe(e,t,n){var r=NL(e),i=r.length;if(NL(t).length!==i)return!1;for(var o;i-- >0;)if(o=r[i],o===sU&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof||!aU(t,o)||!n.equals(e[o],t[o],o,o,e,t,n))return!1;return!0}function od(e,t,n){var r=AL(e),i=r.length;if(AL(t).length!==i)return!1;for(var o,a,s;i-- >0;)if(o=r[i],o===sU&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof||!aU(t,o)||!n.equals(e[o],t[o],o,o,e,t,n)||(a=kL(e,o),s=kL(t,o),(a||s)&&(!a||!s||a.configurable!==s.configurable||a.enumerable!==s.enumerable||a.writable!==s.writable)))return!1;return!0}function nAe(e,t){return mf(e.valueOf(),t.valueOf())}function rAe(e,t){return e.source===t.source&&e.flags===t.flags}function RL(e,t,n){if(e.size!==t.size)return!1;for(var r={},i=e.values(),o,a;(o=i.next())&&!o.done;){for(var s=t.values(),l=!1,u=0;(a=s.next())&&!a.done;)!l&&!r[u]&&(l=n.equals(o.value,a.value,o.value,a.value,e,t,n))&&(r[u]=!0),u++;if(!l)return!1}return!0}function iAe(e,t){var n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}var oAe="[object Arguments]",aAe="[object Boolean]",sAe="[object Date]",lAe="[object Map]",uAe="[object Number]",cAe="[object Object]",fAe="[object RegExp]",dAe="[object Set]",hAe="[object String]",pAe=Array.isArray,LL=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,$L=Object.assign,mAe=Object.prototype.toString.call.bind(Object.prototype.toString);function vAe(e){var t=e.areArraysEqual,n=e.areDatesEqual,r=e.areMapsEqual,i=e.areObjectsEqual,o=e.arePrimitiveWrappersEqual,a=e.areRegExpsEqual,s=e.areSetsEqual,l=e.areTypedArraysEqual;return function(f,d,h){if(f===d)return!0;if(f==null||d==null||typeof f!="object"||typeof d!="object")return f!==f&&d!==d;var v=f.constructor;if(v!==d.constructor)return!1;if(v===Object)return i(f,d,h);if(pAe(f))return t(f,d,h);if(LL!=null&&LL(f))return l(f,d,h);if(v===Date)return n(f,d,h);if(v===RegExp)return a(f,d,h);if(v===Map)return r(f,d,h);if(v===Set)return s(f,d,h);var g=mAe(f);return g===sAe?n(f,d,h):g===fAe?a(f,d,h):g===lAe?r(f,d,h):g===dAe?s(f,d,h):g===cAe?typeof f.then!="function"&&typeof d.then!="function"&&i(f,d,h):g===oAe?i(f,d,h):g===aAe||g===uAe||g===hAe?o(f,d,h):!1}}function gAe(e){var t=e.circular,n=e.createCustomConfig,r=e.strict,i={areArraysEqual:r?od:Jje,areDatesEqual:eAe,areMapsEqual:r?jL(ML,od):ML,areObjectsEqual:r?od:tAe,arePrimitiveWrappersEqual:nAe,areRegExpsEqual:rAe,areSetsEqual:r?jL(RL,od):RL,areTypedArraysEqual:r?od:iAe};if(n&&(i=$L({},i,n(i))),t){var o=wv(i.areArraysEqual),a=wv(i.areMapsEqual),s=wv(i.areObjectsEqual),l=wv(i.areSetsEqual);i=$L({},i,{areArraysEqual:o,areMapsEqual:a,areObjectsEqual:s,areSetsEqual:l})}return i}function yAe(e){return function(t,n,r,i,o,a,s){return e(t,n,s)}}function bAe(e){var t=e.circular,n=e.comparator,r=e.createState,i=e.equals,o=e.strict;if(r)return function(l,u){var f=r(),d=f.cache,h=d===void 0?t?new WeakMap:void 0:d,v=f.meta;return n(l,u,{cache:h,equals:i,meta:v,strict:o})};if(t)return function(l,u){return n(l,u,{cache:new WeakMap,equals:i,meta:void 0,strict:o})};var a={cache:void 0,equals:i,meta:void 0,strict:o};return function(l,u){return n(l,u,a)}}var _Ae=Os();Os({strict:!0});Os({circular:!0});Os({circular:!0,strict:!0});Os({createInternalComparator:function(){return mf}});Os({strict:!0,createInternalComparator:function(){return mf}});Os({circular:!0,createInternalComparator:function(){return mf}});Os({circular:!0,createInternalComparator:function(){return mf},strict:!0});function Os(e){e===void 0&&(e={});var t=e.circular,n=t===void 0?!1:t,r=e.createInternalComparator,i=e.createState,o=e.strict,a=o===void 0?!1:o,s=gAe(e),l=vAe(s),u=r?r(l):yAe(l);return bAe({circular:n,comparator:l,createState:i,equals:u,strict:a})}function xAe(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function IL(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function i(o){n<0&&(n=o),o-n>t?(e(o),n=-1):xAe(i)};requestAnimationFrame(r)}function gS(e){"@babel/helpers - typeof";return gS=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},gS(e)}function wAe(e){return PAe(e)||EAe(e)||SAe(e)||OAe()}function OAe(){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 SAe(e,t){if(e){if(typeof e=="string")return DL(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 DL(e,t)}}function DL(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n1?1:_<0?0:_},y=function(_){for(var b=_>1?1:_,w=b,S=0;S<8;++S){var E=d(w)-b,P=v(w);if(Math.abs(E-b)0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,i=t.damping,o=i===void 0?8:i,a=t.dt,s=a===void 0?17:a,l=function(f,d,h){var v=-(f-d)*r,g=h*o,y=h+(v-g)*s/1e3,x=h*s/1e3+f;return Math.abs(x-d)e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function rke(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function cx(e){return ske(e)||ake(e)||oke(e)||ike()}function ike(){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 oke(e,t){if(e){if(typeof e=="string")return wS(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 wS(e,t)}}function ake(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function ske(e){if(Array.isArray(e))return wS(e)}function wS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n"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 t0(e){return t0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},t0(e)}var _i=function(e){fke(n,e);var t=dke(n);function n(r,i){var o;lke(this,n),o=t.call(this,r,i);var a=o.props,s=a.isActive,l=a.attributeName,u=a.from,f=a.to,d=a.steps,h=a.children,v=a.duration;if(o.handleStyleChange=o.handleStyleChange.bind(ES(o)),o.changeStyle=o.changeStyle.bind(ES(o)),!s||v<=0)return o.state={style:{}},typeof h=="function"&&(o.state={style:f}),SS(o);if(d&&d.length)o.state={style:d[0].style};else if(u){if(typeof h=="function")return o.state={style:u},SS(o);o.state={style:l?vd({},l,u):u}}else o.state={style:{}};return o}return uke(n,[{key:"componentDidMount",value:function(){var i=this.props,o=i.isActive,a=i.canBegin;this.mounted=!0,!(!o||!a)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var o=this.props,a=o.isActive,s=o.canBegin,l=o.attributeName,u=o.shouldReAnimate,f=o.to,d=o.from,h=this.state.style;if(s){if(!a){var v={style:l?vd({},l,f):f};this.state&&h&&(l&&h[l]!==f||!l&&h!==f)&&this.setState(v);return}if(!(_Ae(i.to,f)&&i.canBegin&&i.isActive)){var g=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var y=g||u?d:i.to;if(this.state&&h){var x={style:l?vd({},l,y):y};(l&&h[l]!==y||!l&&h!==y)&&this.setState(x)}this.runAnimation(Ci(Ci({},this.props),{},{from:y,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var i=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),i&&i()}},{key:"handleStyleChange",value:function(i){this.changeStyle(i)}},{key:"changeStyle",value:function(i){this.mounted&&this.setState({style:i})}},{key:"runJSAnimation",value:function(i){var o=this,a=i.from,s=i.to,l=i.duration,u=i.easing,f=i.begin,d=i.onAnimationEnd,h=i.onAnimationStart,v=eke(a,s,VAe(u),l,this.changeStyle),g=function(){o.stopJSAnimation=v()};this.manager.start([h,f,g,l,d])}},{key:"runStepAnimation",value:function(i){var o=this,a=i.steps,s=i.begin,l=i.onAnimationStart,u=a[0],f=u.style,d=u.duration,h=d===void 0?0:d,v=function(y,x,_){if(_===0)return y;var b=x.duration,w=x.easing,S=w===void 0?"ease":w,E=x.style,P=x.properties,T=x.onAnimationEnd,A=_>0?a[_-1]:x,D=P||Object.keys(E);if(typeof S=="function"||S==="spring")return[].concat(cx(y),[o.runJSAnimation.bind(o,{from:A.style,to:E,duration:b,easing:S}),b]);var k=UL(D,b,S),I=Ci(Ci(Ci({},A.style),E),{},{transition:k});return[].concat(cx(y),[I,b,T]).filter(kAe)};return this.manager.start([l].concat(cx(a.reduce(v,[f,Math.max(h,s)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=CAe());var o=i.begin,a=i.duration,s=i.attributeName,l=i.to,u=i.easing,f=i.onAnimationStart,d=i.onAnimationEnd,h=i.steps,v=i.children,g=this.manager;if(this.unSubscribe=g.subscribe(this.handleStyleChange),typeof u=="function"||typeof v=="function"||u==="spring"){this.runJSAnimation(i);return}if(h.length>1){this.runStepAnimation(i);return}var y=s?vd({},s,l):l,x=UL(Object.keys(y),a,u);g.start([f,o,Ci(Ci({},y),{},{transition:x}),a,d])}},{key:"render",value:function(){var i=this.props,o=i.children;i.begin;var a=i.duration;i.attributeName,i.easing;var s=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var l=nke(i,tke),u=R.Children.count(o),f=this.state.style;if(typeof o=="function")return o(f);if(!s||u===0||a<=0)return o;var d=function(v){var g=v.props,y=g.style,x=y===void 0?{}:y,_=g.className,b=R.cloneElement(v,Ci(Ci({},l),{},{style:Ci(Ci({},x),f),className:_}));return b};return u===1?d(R.Children.only(o)):V.createElement("div",null,R.Children.map(o,function(h){return d(h)}))}}]),n}(R.PureComponent);_i.displayName="Animate";_i.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};_i.propTypes={from:$.oneOfType([$.object,$.string]),to:$.oneOfType([$.object,$.string]),attributeName:$.string,duration:$.number,begin:$.number,easing:$.oneOfType([$.string,$.func]),steps:$.arrayOf($.shape({duration:$.number.isRequired,style:$.object.isRequired,easing:$.oneOfType([$.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),$.func]),properties:$.arrayOf("string"),onAnimationEnd:$.func})),children:$.oneOfType([$.node,$.func]),isActive:$.bool,canBegin:$.bool,onAnimationEnd:$.func,shouldReAnimate:$.bool,onAnimationStart:$.func,onAnimationReStart:$.func};$.object,$.object,$.object,$.element;$.object,$.object,$.object,$.oneOfType([$.array,$.element]),$.any;function ap(e){"@babel/helpers - typeof";return ap=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},ap(e)}function n0(){return n0=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0?1:-1,l=r>=0?1:-1,u=i>=0&&r>=0||i<0&&r<0?1:0,f;if(a>0&&o instanceof Array){for(var d=[0,0,0,0],h=0,v=4;ha?a:o[h];f="M".concat(t,",").concat(n+s*d[0]),d[0]>0&&(f+="A ".concat(d[0],",").concat(d[0],",0,0,").concat(u,",").concat(t+l*d[0],",").concat(n)),f+="L ".concat(t+r-l*d[1],",").concat(n),d[1]>0&&(f+="A ".concat(d[1],",").concat(d[1],",0,0,").concat(u,`, `).concat(t+r,",").concat(n+s*d[1])),f+="L ".concat(t+r,",").concat(n+i-s*d[2]),d[2]>0&&(f+="A ".concat(d[2],",").concat(d[2],",0,0,").concat(u,`, `).concat(t+r-l*d[2],",").concat(n+i)),f+="L ".concat(t+l*d[3],",").concat(n+i),d[3]>0&&(f+="A ".concat(d[3],",").concat(d[3],",0,0,").concat(u,`, `).concat(t,",").concat(n+i-s*d[3])),f+="Z"}else if(a>0&&o===+o&&o>0){var g=Math.min(a,o);f="M ".concat(t,",").concat(n+s*g,` A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t+l*g,",").concat(n,` L `).concat(t+r-l*g,",").concat(n,` A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t+r,",").concat(n+s*g,` L `).concat(t+r,",").concat(n+i-s*g,` A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t+r-l*g,",").concat(n+i,` L `).concat(t+l*g,",").concat(n+i,` A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t,",").concat(n+i-s*g," Z")}else f="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(i," h ").concat(-r," Z");return f},wke=function(t,n){if(!t||!n)return!1;var r=t.x,i=t.y,o=n.x,a=n.y,s=n.width,l=n.height;if(Math.abs(s)>0&&Math.abs(l)>0){var u=Math.min(o,o+s),f=Math.max(o,o+s),d=Math.min(a,a+l),h=Math.max(a,a+l);return r>=u&&r<=f&&i>=d&&i<=h}return!1},Oke={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},pT=function(t){var n=ZL(ZL({},Oke),t),r=R.useRef(),i=R.useState(-1),o=pke(i,2),a=o[0],s=o[1];R.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var S=r.current.getTotalLength();S&&s(S)}catch{}},[]);var l=n.x,u=n.y,f=n.width,d=n.height,h=n.radius,v=n.className,g=n.animationEasing,y=n.animationDuration,x=n.animationBegin,_=n.isAnimationActive,b=n.isUpdateAnimationActive;if(l!==+l||u!==+u||f!==+f||d!==+d||f===0||d===0)return null;var w=Pe("recharts-rectangle",v);return b?V.createElement(_i,{canBegin:a>0,from:{width:f,height:d,x:l,y:u},to:{width:f,height:d,x:l,y:u},duration:y,animationEasing:g,isActive:b},function(S){var E=S.width,P=S.height,T=S.x,A=S.y;return V.createElement(_i,{canBegin:a>0,from:"0px ".concat(a===-1?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:x,duration:y,isActive:_,easing:g},V.createElement("path",n0({},De(n,!0),{className:w,d:XL(T,A,E,P,h),ref:r})))}):V.createElement("path",n0({},De(n,!0),{className:w,d:XL(l,u,f,d,h)}))},Ske=["points","className","baseLinePoints","connectNulls"];function Iu(){return Iu=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Pke(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function QL(e){return Ake(e)||jke(e)||Tke(e)||Cke()}function Cke(){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 Tke(e,t){if(e){if(typeof e=="string")return PS(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 PS(e,t)}}function jke(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Ake(e){if(Array.isArray(e))return PS(e)}function PS(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&arguments[0]!==void 0?arguments[0]:[],n=[[]];return t.forEach(function(r){JL(r)?n[n.length-1].push(r):n[n.length-1].length>0&&n.push([])}),JL(t[0])&&n[n.length-1].push(t[0]),n[n.length-1].length<=0&&(n=n.slice(0,-1)),n},Wd=function(t,n){var r=kke(t);n&&(r=[r.reduce(function(o,a){return[].concat(QL(o),QL(a))},[])]);var i=r.map(function(o){return o.reduce(function(a,s,l){return"".concat(a).concat(l===0?"M":"L").concat(s.x,",").concat(s.y)},"")}).join("");return r.length===1?"".concat(i,"Z"):i},Nke=function(t,n,r){var i=Wd(t,r);return"".concat(i.slice(-1)==="Z"?i.slice(0,-1):i,"L").concat(Wd(n.reverse(),r).slice(1))},Mke=function(t){var n=t.points,r=t.className,i=t.baseLinePoints,o=t.connectNulls,a=Eke(t,Ske);if(!n||!n.length)return null;var s=Pe("recharts-polygon",r);if(i&&i.length){var l=a.stroke&&a.stroke!=="none",u=Nke(n,i,o);return V.createElement("g",{className:s},V.createElement("path",Iu({},De(a,!0),{fill:u.slice(-1)==="Z"?a.fill:"none",stroke:"none",d:u})),l?V.createElement("path",Iu({},De(a,!0),{fill:"none",d:Wd(n,o)})):null,l?V.createElement("path",Iu({},De(a,!0),{fill:"none",d:Wd(i,o)})):null)}var f=Wd(n,o);return V.createElement("path",Iu({},De(a,!0),{fill:f.slice(-1)==="Z"?a.fill:"none",className:s,d:f}))};function CS(){return CS=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Bke(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var Uke=function(t,n,r,i,o,a){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(a,",").concat(n,"h").concat(r)},zke=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,a=t.top,s=a===void 0?0:a,l=t.left,u=l===void 0?0:l,f=t.width,d=f===void 0?0:f,h=t.height,v=h===void 0?0:h,g=t.className,y=Fke(t,Rke),x=Lke({x:r,y:o,top:s,left:u,width:d,height:v},y);return!Ee(r)||!Ee(o)||!Ee(d)||!Ee(v)||!Ee(s)||!Ee(u)?null:V.createElement("path",TS({},De(x,!0),{className:Pe("recharts-cross",g),d:Uke(r,o,d,v,s,u)}))},Vke=Vb,Wke=AB,Hke=jo;function Gke(e,t){return e&&e.length?Vke(e,Hke(t),Wke):void 0}var qke=Gke;const Kke=st(qke);var Yke=Vb,Zke=jo,Xke=kB;function Qke(e,t){return e&&e.length?Yke(e,Zke(t),Xke):void 0}var Jke=Qke;const e3e=st(Jke);var t3e=["cx","cy","angle","ticks","axisLine"],n3e=["ticks","tick","angle","tickFormatter","stroke"];function kc(e){"@babel/helpers - typeof";return kc=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},kc(e)}function Hd(){return Hd=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function r3e(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function i3e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r4(e,t){for(var n=0;na4?a=i==="outer"?"start":"end":o<-a4?a=i==="outer"?"end":"start":a="middle",a}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.cx,o=r.cy,a=r.radius,s=r.axisLine,l=r.axisLineType,u=Ms(Ms({},De(this.props,!1)),{},{fill:"none"},De(s,!1));if(l==="circle")return V.createElement(Xp,qs({className:"recharts-polar-angle-axis-line"},u,{cx:i,cy:o,r:a}));var f=this.props.ticks,d=f.map(function(h){return Et(i,o,a,h.coordinate)});return V.createElement(Mke,qs({className:"recharts-polar-angle-axis-line"},u,{points:d}))}},{key:"renderTicks",value:function(){var r=this,i=this.props,o=i.ticks,a=i.tick,s=i.tickLine,l=i.tickFormatter,u=i.stroke,f=De(this.props,!1),d=De(a,!1),h=Ms(Ms({},f),{},{fill:"none"},De(s,!1)),v=o.map(function(g,y){var x=r.getTickLineCoord(g),_=r.getTickTextAnchor(g),b=Ms(Ms(Ms({textAnchor:_},f),{},{stroke:"none",fill:u},d),{},{index:y,payload:g,x:x.x2,y:x.y2});return V.createElement(Qe,qs({className:Pe("recharts-polar-angle-axis-tick",nU(a)),key:"tick-".concat(g.coordinate)},ss(r.props,g,y)),s&&V.createElement("line",qs({className:"recharts-polar-angle-axis-tick-line"},h,x)),a&&t.renderTickItem(a,b,l?l(g.value,y):g.value))});return V.createElement(Qe,{className:"recharts-polar-angle-axis-ticks"},v)}},{key:"render",value:function(){var r=this.props,i=r.ticks,o=r.radius,a=r.axisLine;return o<=0||!i||!i.length?null:V.createElement(Qe,{className:Pe("recharts-polar-angle-axis",this.props.className)},a&&this.renderAxisLine(),this.renderTicks())}}],[{key:"renderTickItem",value:function(r,i,o){var a;return V.isValidElement(r)?a=V.cloneElement(r,i):We(r)?a=r(i):a=V.createElement(Tl,qs({},i,{className:"recharts-polar-angle-axis-tick-value"}),o),a}}]),t}(R.PureComponent);Yb(Zb,"displayName","PolarAngleAxis");Yb(Zb,"axisType","angleAxis");Yb(Zb,"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 b3e=E7,_3e=b3e(Object.getPrototypeOf,Object),x3e=_3e,w3e=da,O3e=x3e,S3e=ha,E3e="[object Object]",P3e=Function.prototype,C3e=Object.prototype,yU=P3e.toString,T3e=C3e.hasOwnProperty,j3e=yU.call(Object);function A3e(e){if(!S3e(e)||w3e(e)!=E3e)return!1;var t=O3e(e);if(t===null)return!0;var n=T3e.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&yU.call(n)==j3e}var k3e=A3e;const N3e=st(k3e);var M3e=da,R3e=ha,L3e="[object Boolean]";function $3e(e){return e===!0||e===!1||R3e(e)&&M3e(e)==L3e}var I3e=$3e;const D3e=st(I3e);function lp(e){"@babel/helpers - typeof";return lp=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},lp(e)}function o0(){return o0=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n0,from:{upperWidth:0,lowerWidth:0,height:h,x:l,y:u},to:{upperWidth:f,lowerWidth:d,height:h,x:l,y:u},duration:y,animationEasing:g,isActive:_},function(w){var S=w.upperWidth,E=w.lowerWidth,P=w.height,T=w.x,A=w.y;return V.createElement(_i,{canBegin:a>0,from:"0px ".concat(a===-1?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:x,duration:y,easing:g},V.createElement("path",o0({},De(n,!0),{className:b,d:c4(T,A,S,E,P),ref:r})))}):V.createElement("g",null,V.createElement("path",o0({},De(n,!0),{className:b,d:c4(l,u,f,d,h)})))},Y3e=["option","shapeType","propTransformer","activeClassName","isActive"];function up(e){"@babel/helpers - typeof";return up=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},up(e)}function Z3e(e,t){if(e==null)return{};var n=X3e(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function X3e(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function f4(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 a0(e){for(var t=1;t0?Br(w,"paddingAngle",0):0;if(E){var T=zt(E.endAngle-E.startAngle,w.endAngle-w.startAngle),A=Rt(Rt({},w),{},{startAngle:b+P,endAngle:b+T(y)+P});x.push(A),b=A.endAngle}else{var D=w.endAngle,k=w.startAngle,I=zt(0,D-k),F=I(y),q=Rt(Rt({},w),{},{startAngle:b+P,endAngle:b+F+P});x.push(q),b=q.endAngle}}),V.createElement(Qe,null,r.renderSectorsStatically(x))})}},{key:"attachKeyboardHandlers",value:function(r){var i=this;r.onkeydown=function(o){if(!o.altKey)switch(o.key){case"ArrowLeft":{var a=++i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[a].focus(),i.setState({sectorToFocus:a});break}case"ArrowRight":{var s=--i.state.sectorToFocus<0?i.sectorRefs.length-1:i.state.sectorToFocus%i.sectorRefs.length;i.sectorRefs[s].focus(),i.setState({sectorToFocus:s});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,o=r.isAnimationActive,a=this.state.prevSectors;return o&&i&&i.length&&(!a||!ls(a,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,o=i.hide,a=i.sectors,s=i.className,l=i.label,u=i.cx,f=i.cy,d=i.innerRadius,h=i.outerRadius,v=i.isAnimationActive,g=this.state.isAnimationFinished;if(o||!a||!a.length||!Ee(u)||!Ee(f)||!Ee(d)||!Ee(h))return null;var y=Pe("recharts-pie",s);return V.createElement(Qe,{tabIndex:this.props.rootTabIndex,className:y,ref:function(_){r.pieRef=_}},this.renderSectors(),l&&this.renderLabels(a),Pn.renderCallByParent(this.props,null,!1),(!v||g)&&Bi.renderCallByParent(this.props,a,!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=360?b:b-1)*l,S=x-b*v-w,E=r.reduce(function(A,D){var k=kt(D,_,0);return A+(Ee(k)?k:0)},0),P;if(E>0){var T;P=r.map(function(A,D){var k=kt(A,_,0),I=kt(A,f,D),F=(Ee(k)?k:0)/E,q;D?q=T.endAngle+or(y)*l*(k!==0?1:0):q=a;var W=q+or(y)*((k!==0?v:0)+F*S),X=(q+W)/2,Q=(g.innerRadius+g.outerRadius)/2,ne=[{name:I,value:k,payload:A,dataKey:_,type:h}],Z=Et(g.cx,g.cy,Q,X);return T=Rt(Rt(Rt({percent:F,cornerRadius:o,name:I,tooltipPayload:ne,midAngle:X,middleRadius:Q,tooltipPosition:Z},A),g),{},{value:kt(A,_),startAngle:q,endAngle:W,payload:A,paddingAngle:or(y)*l}),T})}return Rt(Rt({},g),{},{sectors:P,data:r})});var gNe=Math.ceil,yNe=Math.max;function bNe(e,t,n,r){for(var i=-1,o=yNe(gNe((t-e)/(n||1)),0),a=Array(o);o--;)a[r?o:++i]=e,e+=n;return a}var _Ne=bNe,xNe=H7,m4=1/0,wNe=17976931348623157e292;function ONe(e){if(!e)return e===0?e:0;if(e=xNe(e),e===m4||e===-m4){var t=e<0?-1:1;return t*wNe}return e===e?e:0}var xU=ONe,SNe=_Ne,ENe=$b,fx=xU;function PNe(e){return function(t,n,r){return r&&typeof r!="number"&&ENe(t,n,r)&&(n=r=void 0),t=fx(t),n===void 0?(n=t,t=0):n=fx(n),r=r===void 0?t0&&r.handleDrag(i.changedTouches[0])}),Mr(ro(r),"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=r.props,o=i.endIndex,a=i.onDragEnd,s=i.startIndex;a==null||a({endIndex:o,startIndex:s})}),r.detachDragEndListener()}),Mr(ro(r),"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),Mr(ro(r),"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),Mr(ro(r),"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),Mr(ro(r),"handleSlideDragStart",function(i){var o=_4(i)?i.changedTouches[0]:i;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(ro(r),"startX"),endX:r.handleTravellerDragStart.bind(ro(r),"endX")},r.state={},r}return $Ne(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var i=r.startX,o=r.endX,a=this.state.scaleValues,s=this.props,l=s.gap,u=s.data,f=u.length-1,d=Math.min(i,o),h=Math.max(i,o),v=t.getIndexInRange(a,d),g=t.getIndexInRange(a,h);return{startIndex:v-v%l,endIndex:g===f?f:g-g%l}}},{key:"getTextOfTick",value:function(r){var i=this.props,o=i.data,a=i.tickFormatter,s=i.dataKey,l=kt(o[r],s,r);return We(a)?a(l,r):l}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(r){var i=this.state,o=i.slideMoveStartX,a=i.startX,s=i.endX,l=this.props,u=l.x,f=l.width,d=l.travellerWidth,h=l.startIndex,v=l.endIndex,g=l.onChange,y=r.pageX-o;y>0?y=Math.min(y,u+f-d-s,u+f-d-a):y<0&&(y=Math.max(y,u-a,u-s));var x=this.getIndex({startX:a+y,endX:s+y});(x.startIndex!==h||x.endIndex!==v)&&g&&g(x),this.setState({startX:a+y,endX:s+y,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,i){var o=_4(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var i=this.state,o=i.brushMoveStartX,a=i.movingTravellerId,s=i.endX,l=i.startX,u=this.state[a],f=this.props,d=f.x,h=f.width,v=f.travellerWidth,g=f.onChange,y=f.gap,x=f.data,_={startX:this.state.startX,endX:this.state.endX},b=r.pageX-o;b>0?b=Math.min(b,d+h-v-u):b<0&&(b=Math.max(b,d-u)),_[a]=u+b;var w=this.getIndex(_),S=w.startIndex,E=w.endIndex,P=function(){var A=x.length-1;return a==="startX"&&(s>l?S%y===0:E%y===0)||sl?E%y===0:S%y===0)||s>l&&E===A};this.setState(Mr(Mr({},a,u+b),"brushMoveStartX",r.pageX),function(){g&&P()&&g(w)})}},{key:"handleTravellerMoveKeyboard",value:function(r,i){var o=this,a=this.state,s=a.scaleValues,l=a.startX,u=a.endX,f=this.state[i],d=s.indexOf(f);if(d!==-1){var h=d+r;if(!(h===-1||h>=s.length)){var v=s[h];i==="startX"&&v>=u||i==="endX"&&v<=l||this.setState(Mr({},i,v),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,i=r.x,o=r.y,a=r.width,s=r.height,l=r.fill,u=r.stroke;return V.createElement("rect",{stroke:u,fill:l,x:i,y:o,width:a,height:s})}},{key:"renderPanorama",value:function(){var r=this.props,i=r.x,o=r.y,a=r.width,s=r.height,l=r.data,u=r.children,f=r.padding,d=R.Children.only(u);return d?V.cloneElement(d,{x:i,y:o,width:a,height:s,margin:f,compact:!0,data:l}):null}},{key:"renderTravellerLayer",value:function(r,i){var o,a,s=this,l=this.props,u=l.y,f=l.travellerWidth,d=l.height,h=l.traveller,v=l.ariaLabel,g=l.data,y=l.startIndex,x=l.endIndex,_=Math.max(r,this.props.x),b=dx(dx({},De(this.props,!1)),{},{x:_,y:u,width:f,height:d}),w=v||"Min value: ".concat((o=g[y])===null||o===void 0?void 0:o.name,", Max value: ").concat((a=g[x])===null||a===void 0?void 0:a.name);return V.createElement(Qe,{tabIndex:0,role:"slider","aria-label":w,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(E){["ArrowLeft","ArrowRight"].includes(E.key)&&(E.preventDefault(),E.stopPropagation(),s.handleTravellerMoveKeyboard(E.key==="ArrowRight"?1:-1,i))},onFocus:function(){s.setState({isTravellerFocused:!0})},onBlur:function(){s.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(h,b))}},{key:"renderSlide",value:function(r,i){var o=this.props,a=o.y,s=o.height,l=o.stroke,u=o.travellerWidth,f=Math.min(r,i)+u,d=Math.max(Math.abs(i-r)-u,0);return V.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:l,fillOpacity:.2,x:f,y:a,width:d,height:s})}},{key:"renderText",value:function(){var r=this.props,i=r.startIndex,o=r.endIndex,a=r.y,s=r.height,l=r.travellerWidth,u=r.stroke,f=this.state,d=f.startX,h=f.endX,v=5,g={pointerEvents:"none",fill:u};return V.createElement(Qe,{className:"recharts-brush-texts"},V.createElement(Tl,c0({textAnchor:"end",verticalAnchor:"middle",x:Math.min(d,h)-v,y:a+s/2},g),this.getTextOfTick(i)),V.createElement(Tl,c0({textAnchor:"start",verticalAnchor:"middle",x:Math.max(d,h)+l+v,y:a+s/2},g),this.getTextOfTick(o)))}},{key:"render",value:function(){var r=this.props,i=r.data,o=r.className,a=r.children,s=r.x,l=r.y,u=r.width,f=r.height,d=r.alwaysShowText,h=this.state,v=h.startX,g=h.endX,y=h.isTextActive,x=h.isSlideMoving,_=h.isTravellerMoving,b=h.isTravellerFocused;if(!i||!i.length||!Ee(s)||!Ee(l)||!Ee(u)||!Ee(f)||u<=0||f<=0)return null;var w=Pe("recharts-brush",o),S=V.Children.count(a)===1,E=RNe("userSelect","none");return V.createElement(Qe,{className:w,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:E},this.renderBackground(),S&&this.renderPanorama(),this.renderSlide(v,g),this.renderTravellerLayer(v,"startX"),this.renderTravellerLayer(g,"endX"),(y||x||_||b||d)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var i=r.x,o=r.y,a=r.width,s=r.height,l=r.stroke,u=Math.floor(o+s/2)-1;return V.createElement(V.Fragment,null,V.createElement("rect",{x:i,y:o,width:a,height:s,fill:l,stroke:"none"}),V.createElement("line",{x1:i+1,y1:u,x2:i+a-1,y2:u,fill:"none",stroke:"#fff"}),V.createElement("line",{x1:i+1,y1:u+2,x2:i+a-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,i){var o;return V.isValidElement(r)?o=V.cloneElement(r,i):We(r)?o=r(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(r,i){var o=r.data,a=r.width,s=r.x,l=r.travellerWidth,u=r.updateId,f=r.startIndex,d=r.endIndex;if(o!==i.prevData||u!==i.prevUpdateId)return dx({prevData:o,prevTravellerWidth:l,prevUpdateId:u,prevX:s,prevWidth:a},o&&o.length?UNe({data:o,width:a,x:s,travellerWidth:l,startIndex:f,endIndex:d}):{scale:null,scaleValues:null});if(i.scale&&(a!==i.prevWidth||s!==i.prevX||l!==i.prevTravellerWidth)){i.scale.range([s,s+a-l]);var h=i.scale.domain().map(function(v){return i.scale(v)});return{prevData:o,prevTravellerWidth:l,prevUpdateId:u,prevX:s,prevWidth:a,startX:i.scale(r.startIndex),endX:i.scale(r.endIndex),scaleValues:h}}return null}},{key:"getIndexInRange",value:function(r,i){for(var o=r.length,a=0,s=o-1;s-a>1;){var l=Math.floor((a+s)/2);r[l]>i?s=l:a=l}return i>=r[s]?s:a}}]),t}(R.PureComponent);Mr(Lc,"displayName","Brush");Mr(Lc,"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 zNe=FC;function VNe(e,t){var n;return zNe(e,function(r,i,o){return n=t(r,i,o),!n}),!!n}var WNe=VNe,HNe=g7,GNe=jo,qNe=WNe,KNe=Ar,YNe=$b;function ZNe(e,t,n){var r=KNe(e)?HNe:qNe;return n&&YNe(e,t,n)&&(t=void 0),r(e,GNe(t))}var XNe=ZNe;const QNe=st(XNe);var yo=function(t,n){var r=t.alwaysShow,i=t.ifOverflow;return r&&(i="extendDomain"),i===n},x4=B7;function JNe(e,t,n){t=="__proto__"&&x4?x4(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var eMe=JNe,tMe=eMe,nMe=D7,rMe=jo;function iMe(e,t){var n={};return t=rMe(t),nMe(e,function(r,i,o){tMe(n,i,t(r,i,o))}),n}var oMe=iMe;const aMe=st(oMe);function sMe(e,t){for(var n=-1,r=e==null?0:e.length;++n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function SMe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function EMe(e,t){var n=e.x,r=e.y,i=OMe(e,bMe),o="".concat(n),a=parseInt(o,10),s="".concat(r),l=parseInt(s,10),u="".concat(t.height||i.height),f=parseInt(u,10),d="".concat(t.width||i.width),h=parseInt(d,10);return ad(ad(ad(ad(ad({},t),i),a?{x:a}:{}),l?{y:l}:{}),{},{height:f,width:h,name:t.name,radius:t.radius})}function O4(e){return V.createElement(s0,MS({shapeType:"rectangle",propTransformer:EMe,activeClassName:"recharts-active-bar"},e))}var PMe=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,i){if(typeof t=="number")return t;var o=typeof r=="number";return o?t(r,i):(o||Al(!1),n)}},CMe=["value","background"],PU;function $c(e){"@babel/helpers - typeof";return $c=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},$c(e)}function TMe(e,t){if(e==null)return{};var n=jMe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function jMe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function d0(){return d0=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&Math.abs(W)0&&Math.abs(q)0&&(q=Math.min((te||0)-(W[ie-1]||0),q))}),Number.isFinite(q)){var X=q/F,Q=y.layout==="vertical"?r.height:r.width;if(y.padding==="gap"&&(T=X*Q/2),y.padding==="no-gap"){var ne=ar(t.barCategoryGap,X*Q),Z=X*Q/2;T=Z-ne-(Z-ne)/Q*ne}}}i==="xAxis"?A=[r.left+(w.left||0)+(T||0),r.left+r.width-(w.right||0)-(T||0)]:i==="yAxis"?A=l==="horizontal"?[r.top+r.height-(w.bottom||0),r.top+(w.top||0)]:[r.top+(w.top||0)+(T||0),r.top+r.height-(w.bottom||0)-(T||0)]:A=y.range,E&&(A=[A[1],A[0]]);var z=YB(y,o,h),B=z.scale,H=z.realScaleType;B.domain(_).range(A),ZB(B);var ee=XB(B,Ai(Ai({},y),{},{realScaleType:H}));i==="xAxis"?(I=x==="top"&&!S||x==="bottom"&&S,D=r.left,k=d[P]-I*y.height):i==="yAxis"&&(I=x==="left"&&!S||x==="right"&&S,D=d[P]-I*y.width,k=r.top);var K=Ai(Ai(Ai({},y),ee),{},{realScaleType:H,x:D,y:k,scale:B,width:i==="xAxis"?r.width:y.width,height:i==="yAxis"?r.height:y.height});return K.bandSize=Zy(K,ee),!y.hide&&i==="xAxis"?d[P]+=(I?-1:1)*K.height:y.hide||(d[P]+=(I?-1:1)*K.width),Ai(Ai({},v),{},Jb({},g,K))},{})},kU=function(t,n){var r=t.x,i=t.y,o=n.x,a=n.y;return{x:Math.min(r,o),y:Math.min(i,a),width:Math.abs(o-r),height:Math.abs(a-i)}},FMe=function(t){var n=t.x1,r=t.y1,i=t.x2,o=t.y2;return kU({x:n,y:r},{x:i,y:o})},NU=function(){function e(t){$Me(this,e),this.scale=t}return IMe(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.bandAware,o=r.position;if(n!==void 0){if(o)switch(o){case"start":return this.scale(n);case"middle":{var a=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+a}case"end":{var s=this.bandwidth?this.bandwidth():0;return this.scale(n)+s}default:return this.scale(n)}if(i){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+l}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),i=r[0],o=r[r.length-1];return i<=o?n>=i&&n<=o:n>=o&&n<=i}}],[{key:"create",value:function(n){return new e(n)}}]),e}();Jb(NU,"EPS",1e-4);var mT=function(t){var n=Object.keys(t).reduce(function(r,i){return Ai(Ai({},r),{},Jb({},i,NU.create(t[i])))},{});return Ai(Ai({},n),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=o.bandAware,s=o.position;return aMe(i,function(l,u){return n[u].apply(l,{bandAware:a,position:s})})},isInRange:function(i){return EU(i,function(o,a){return n[a].isInRange(o)})}})};function BMe(e){return(e%180+180)%180}var UMe=function(t){var n=t.width,r=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=BMe(i),a=o*Math.PI/180,s=Math.atan(r/n),l=a>s&&a-1?i[o?t[a]:a]:void 0}}var GMe=HMe,qMe=xU;function KMe(e){var t=qMe(e),n=t%1;return t===t?n?t-n:t:0}var YMe=KMe,ZMe=k7,XMe=jo,QMe=YMe,JMe=Math.max;function eRe(e,t,n){var r=e==null?0:e.length;if(!r)return-1;var i=n==null?0:QMe(n);return i<0&&(i=JMe(r+i,0)),ZMe(e,XMe(t),i)}var tRe=eRe,nRe=GMe,rRe=tRe,iRe=nRe(rRe),oRe=iRe;const aRe=st(oRe);var sRe=Nme(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("")}),vT=R.createContext(void 0),gT=R.createContext(void 0),MU=R.createContext(void 0),RU=R.createContext({}),LU=R.createContext(void 0),$U=R.createContext(0),IU=R.createContext(0),T4=function(t){var n=t.state,r=n.xAxisMap,i=n.yAxisMap,o=n.offset,a=t.clipPathId,s=t.children,l=t.width,u=t.height,f=sRe(o);return V.createElement(vT.Provider,{value:r},V.createElement(gT.Provider,{value:i},V.createElement(RU.Provider,{value:o},V.createElement(MU.Provider,{value:f},V.createElement(LU.Provider,{value:a},V.createElement($U.Provider,{value:u},V.createElement(IU.Provider,{value:l},s)))))))},lRe=function(){return R.useContext(LU)},DU=function(t){var n=R.useContext(vT);n==null&&Al(!1);var r=n[t];return r==null&&Al(!1),r},uRe=function(){var t=R.useContext(vT);return Na(t)},cRe=function(){var t=R.useContext(gT),n=aRe(t,function(r){return EU(r.domain,Number.isFinite)});return n||Na(t)},FU=function(t){var n=R.useContext(gT);n==null&&Al(!1);var r=n[t];return r==null&&Al(!1),r},fRe=function(){var t=R.useContext(MU);return t},dRe=function(){return R.useContext(RU)},yT=function(){return R.useContext(IU)},bT=function(){return R.useContext($U)};function pp(e){"@babel/helpers - typeof";return pp=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},pp(e)}function j4(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 A4(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);ne*i)return!1;var o=n();return e*(t-e*o/2-r)>=0&&e*(t+e*o/2-i)<=0}function MRe(e,t){return BU(e,t+1)}function RRe(e,t,n,r,i){for(var o=(r||[]).slice(),a=t.start,s=t.end,l=0,u=1,f=a,d=function(){var g=r==null?void 0:r[l];if(g===void 0)return{v:BU(r,u)};var y=l,x,_=function(){return x===void 0&&(x=n(g,y)),x},b=g.coordinate,w=l===0||p0(e,b,_,f,s);w||(l=0,f=a,u+=1),w&&(f=b+e*(_()/2+i),l+=u)},h;u<=o.length;)if(h=d(),h)return h.v;return[]}function gp(e){"@babel/helpers - typeof";return gp=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},gp(e)}function $4(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 Hn(e){for(var t=1;t0?v.coordinate-x*e:v.coordinate})}else o[h]=v=Hn(Hn({},v),{},{tickCoord:v.coordinate});var _=p0(e,v.tickCoord,y,s,l);_&&(l=v.tickCoord-e*(y()/2+i),o[h]=Hn(Hn({},v),{},{isShow:!0}))},f=a-1;f>=0;f--)u(f);return o}function FRe(e,t,n,r,i,o){var a=(r||[]).slice(),s=a.length,l=t.start,u=t.end;if(o){var f=r[s-1],d=n(f,s-1),h=e*(f.coordinate+e*d/2-u);a[s-1]=f=Hn(Hn({},f),{},{tickCoord:h>0?f.coordinate-h*e:f.coordinate});var v=p0(e,f.tickCoord,function(){return d},l,u);v&&(u=f.tickCoord-e*(d/2+i),a[s-1]=Hn(Hn({},f),{},{isShow:!0}))}for(var g=o?s-1:s,y=function(b){var w=a[b],S,E=function(){return S===void 0&&(S=n(w,b)),S};if(b===0){var P=e*(w.coordinate-e*E()/2-l);a[b]=w=Hn(Hn({},w),{},{tickCoord:P<0?w.coordinate-P*e:w.coordinate})}else a[b]=w=Hn(Hn({},w),{},{tickCoord:w.coordinate});var T=p0(e,w.tickCoord,E,l,u);T&&(l=w.tickCoord+e*(E()/2+i),a[b]=Hn(Hn({},w),{},{isShow:!0}))},x=0;x=2?or(i[1].coordinate-i[0].coordinate):1,_=NRe(o,x,v);return l==="equidistantPreserveStart"?RRe(x,_,y,i,a):(l==="preserveStart"||l==="preserveStartEnd"?h=FRe(x,_,y,i,a,l==="preserveStartEnd"):h=DRe(x,_,y,i,a),h.filter(function(b){return b.isShow}))}var BRe=["viewBox"],URe=["viewBox"],zRe=["ticks"];function Ic(e){"@babel/helpers - typeof";return Ic=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ic(e)}function Fu(){return Fu=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function VRe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function WRe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function D4(e,t){for(var n=0;n0?l(this.props):l(v)),a<=0||s<=0||!g||!g.length?null:V.createElement(Qe,{className:Pe("recharts-cartesian-axis",u),ref:function(x){r.layerReference=x}},o&&this.renderAxisLine(),this.renderTicks(g,this.state.fontSize,this.state.letterSpacing),Pn.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,i,o){var a;return V.isValidElement(r)?a=V.cloneElement(r,i):We(r)?a=r(i):a=V.createElement(Tl,Fu({},i,{className:"recharts-cartesian-axis-tick-value"}),o),a}}]),t}(R.Component);wT(vf,"displayName","CartesianAxis");wT(vf,"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 XRe=["x1","y1","x2","y2","key"],QRe=["offset"];function kl(e){"@babel/helpers - typeof";return kl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kl(e)}function F4(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 Kn(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function nLe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}var rLe=function(t){var n=t.fill;if(!n||n==="none")return null;var r=t.fillOpacity,i=t.x,o=t.y,a=t.width,s=t.height;return V.createElement("rect",{x:i,y:o,width:a,height:s,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function VU(e,t){var n;if(V.isValidElement(e))n=V.cloneElement(e,t);else if(We(e))n=e(t);else{var r=t.x1,i=t.y1,o=t.x2,a=t.y2,s=t.key,l=B4(t,XRe),u=De(l,!1);u.offset;var f=B4(u,QRe);n=V.createElement("line",ol({},f,{x1:r,y1:i,x2:o,y2:a,fill:"none",key:s}))}return n}function iLe(e){var t=e.x,n=e.width,r=e.horizontal,i=r===void 0?!0:r,o=e.horizontalPoints;if(!i||!o||!o.length)return null;var a=o.map(function(s,l){var u=Kn(Kn({},e),{},{x1:t,y1:s,x2:t+n,y2:s,key:"line-".concat(l),index:l});return VU(i,u)});return V.createElement("g",{className:"recharts-cartesian-grid-horizontal"},a)}function oLe(e){var t=e.y,n=e.height,r=e.vertical,i=r===void 0?!0:r,o=e.verticalPoints;if(!i||!o||!o.length)return null;var a=o.map(function(s,l){var u=Kn(Kn({},e),{},{x1:s,y1:t,x2:s,y2:t+n,key:"line-".concat(l),index:l});return VU(i,u)});return V.createElement("g",{className:"recharts-cartesian-grid-vertical"},a)}function aLe(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,i=e.y,o=e.width,a=e.height,s=e.horizontalPoints,l=e.horizontal,u=l===void 0?!0:l;if(!u||!t||!t.length)return null;var f=s.map(function(h){return Math.round(h+i-i)}).sort(function(h,v){return h-v});i!==f[0]&&f.unshift(0);var d=f.map(function(h,v){var g=!f[v+1],y=g?i+a-h:f[v+1]-h;if(y<=0)return null;var x=v%t.length;return V.createElement("rect",{key:"react-".concat(v),y:h,x:r,height:y,width:o,stroke:"none",fill:t[x],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return V.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},d)}function sLe(e){var t=e.vertical,n=t===void 0?!0:t,r=e.verticalFill,i=e.fillOpacity,o=e.x,a=e.y,s=e.width,l=e.height,u=e.verticalPoints;if(!n||!r||!r.length)return null;var f=u.map(function(h){return Math.round(h+o-o)}).sort(function(h,v){return h-v});o!==f[0]&&f.unshift(0);var d=f.map(function(h,v){var g=!f[v+1],y=g?o+s-h:f[v+1]-h;if(y<=0)return null;var x=v%r.length;return V.createElement("rect",{key:"react-".concat(v),x:h,y:a,width:y,height:l,stroke:"none",fill:r[x],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return V.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},d)}var lLe=function(t,n){var r=t.xAxis,i=t.width,o=t.height,a=t.offset;return KB(xT(Kn(Kn(Kn({},vf.defaultProps),r),{},{ticks:zo(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),a.left,a.left+a.width,n)},uLe=function(t,n){var r=t.yAxis,i=t.width,o=t.height,a=t.offset;return KB(xT(Kn(Kn(Kn({},vf.defaultProps),r),{},{ticks:zo(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),a.top,a.top+a.height,n)},uu={horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function OT(e){var t,n,r,i,o,a,s=yT(),l=bT(),u=dRe(),f=Kn(Kn({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:uu.stroke,fill:(n=e.fill)!==null&&n!==void 0?n:uu.fill,horizontal:(r=e.horizontal)!==null&&r!==void 0?r:uu.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:uu.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:uu.vertical,verticalFill:(a=e.verticalFill)!==null&&a!==void 0?a:uu.verticalFill,x:Ee(e.x)?e.x:u.left,y:Ee(e.y)?e.y:u.top,width:Ee(e.width)?e.width:u.width,height:Ee(e.height)?e.height:u.height}),d=f.x,h=f.y,v=f.width,g=f.height,y=f.syncWithTicks,x=f.horizontalValues,_=f.verticalValues,b=uRe(),w=cRe();if(!Ee(v)||v<=0||!Ee(g)||g<=0||!Ee(d)||d!==+d||!Ee(h)||h!==+h)return null;var S=f.verticalCoordinatesGenerator||lLe,E=f.horizontalCoordinatesGenerator||uLe,P=f.horizontalPoints,T=f.verticalPoints;if((!P||!P.length)&&We(E)){var A=x&&x.length,D=E({yAxis:w?Kn(Kn({},w),{},{ticks:A?x:w.ticks}):void 0,width:s,height:l,offset:u},A?!0:y);Fi(Array.isArray(D),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(kl(D),"]")),Array.isArray(D)&&(P=D)}if((!T||!T.length)&&We(S)){var k=_&&_.length,I=S({xAxis:b?Kn(Kn({},b),{},{ticks:k?_:b.ticks}):void 0,width:s,height:l,offset:u},k?!0:y);Fi(Array.isArray(I),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(kl(I),"]")),Array.isArray(I)&&(T=I)}return V.createElement("g",{className:"recharts-cartesian-grid"},V.createElement(rLe,{fill:f.fill,fillOpacity:f.fillOpacity,x:f.x,y:f.y,width:f.width,height:f.height}),V.createElement(iLe,ol({},f,{offset:u,horizontalPoints:P,xAxis:b,yAxis:w})),V.createElement(oLe,ol({},f,{offset:u,verticalPoints:T,xAxis:b,yAxis:w})),V.createElement(aLe,ol({},f,{horizontalPoints:P})),V.createElement(sLe,ol({},f,{verticalPoints:T})))}OT.displayName="CartesianGrid";var cLe=["type","layout","connectNulls","ref"];function Dc(e){"@babel/helpers - typeof";return Dc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Dc(e)}function fLe(e,t){if(e==null)return{};var n=dLe(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function dLe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function Gd(){return Gd=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);nd){v=[].concat(cu(l.slice(0,g)),[d-y]);break}var x=v.length%2===0?[0,h]:[h];return[].concat(cu(t.repeat(l,f)),cu(v),x).map(function(_){return"".concat(_,"px")}).join(", ")}),ki(wa(n),"id",_s("recharts-line-")),ki(wa(n),"pathRef",function(a){n.mainCurve=a}),ki(wa(n),"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),ki(wa(n),"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return yLe(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();this.setState({totalLength:r})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();r!==this.state.totalLength&&this.setState({totalLength:r})}}},{key:"getTotalLength",value:function(){var r=this.mainCurve;try{return r&&r.getTotalLength&&r.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,a=o.points,s=o.xAxis,l=o.yAxis,u=o.layout,f=o.children,d=cr(f,pf);if(!d)return null;var h=function(y,x){return{x:y.x,y:y.y,value:y.value,errorVal:kt(y.payload,x)}},v={clipPath:r?"url(#clipPath-".concat(i,")"):null};return V.createElement(Qe,v,d.map(function(g){return V.cloneElement(g,{key:"bar-".concat(g.props.dataKey),data:a,xAxis:s,yAxis:l,layout:u,dataPointFormatter:h})}))}},{key:"renderDots",value:function(r,i,o){var a=this.props.isAnimationActive;if(a&&!this.state.isAnimationFinished)return null;var s=this.props,l=s.dot,u=s.points,f=s.dataKey,d=De(this.props,!1),h=De(l,!0),v=u.map(function(y,x){var _=Nr(Nr(Nr({key:"dot-".concat(x),r:3},d),h),{},{value:y.value,dataKey:f,cx:y.x,cy:y.y,index:x,payload:y.payload});return t.renderDotItem(l,_)}),g={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return V.createElement(Qe,Gd({className:"recharts-line-dots",key:"dots"},g),v)}},{key:"renderCurveStatically",value:function(r,i,o,a){var s=this.props,l=s.type,u=s.layout,f=s.connectNulls;s.ref;var d=fLe(s,cLe),h=Nr(Nr(Nr({},De(d,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:r},a),{},{type:l,layout:u,connectNulls:f});return V.createElement(Qa,Gd({},h,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(r,i){var o=this,a=this.props,s=a.points,l=a.strokeDasharray,u=a.isAnimationActive,f=a.animationBegin,d=a.animationDuration,h=a.animationEasing,v=a.animationId,g=a.animateNewValues,y=a.width,x=a.height,_=this.state,b=_.prevPoints,w=_.totalLength;return V.createElement(_i,{begin:f,duration:d,isActive:u,easing:h,from:{t:0},to:{t:1},key:"line-".concat(v),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(S){var E=S.t;if(b){var P=b.length/s.length,T=s.map(function(F,q){var W=Math.floor(q*P);if(b[W]){var X=b[W],Q=zt(X.x,F.x),ne=zt(X.y,F.y);return Nr(Nr({},F),{},{x:Q(E),y:ne(E)})}if(g){var Z=zt(y*2,F.x),z=zt(x/2,F.y);return Nr(Nr({},F),{},{x:Z(E),y:z(E)})}return Nr(Nr({},F),{},{x:F.x,y:F.y})});return o.renderCurveStatically(T,r,i)}var A=zt(0,w),D=A(E),k;if(l){var I="".concat(l).split(/[,\s]+/gim).map(function(F){return parseFloat(F)});k=o.getStrokeDasharray(D,w,I)}else k=o.generateSimpleStrokeDasharray(w,D);return o.renderCurveStatically(s,r,i,{strokeDasharray:k})})}},{key:"renderCurve",value:function(r,i){var o=this.props,a=o.points,s=o.isAnimationActive,l=this.state,u=l.prevPoints,f=l.totalLength;return s&&a&&a.length&&(!u&&f>0||!ls(u,a))?this.renderCurveWithAnimation(r,i):this.renderCurveStatically(a,r,i)}},{key:"render",value:function(){var r,i=this.props,o=i.hide,a=i.dot,s=i.points,l=i.className,u=i.xAxis,f=i.yAxis,d=i.top,h=i.left,v=i.width,g=i.height,y=i.isAnimationActive,x=i.id;if(o||!s||!s.length)return null;var _=this.state.isAnimationFinished,b=s.length===1,w=Pe("recharts-line",l),S=u&&u.allowDataOverflow,E=f&&f.allowDataOverflow,P=S||E,T=ze(x)?this.id:x,A=(r=De(a,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},D=A.r,k=D===void 0?3:D,I=A.strokeWidth,F=I===void 0?2:I,q=zF(a)?a:{},W=q.clipDot,X=W===void 0?!0:W,Q=k*2+F;return V.createElement(Qe,{className:w},S||E?V.createElement("defs",null,V.createElement("clipPath",{id:"clipPath-".concat(T)},V.createElement("rect",{x:S?h:h-v/2,y:E?d:d-g/2,width:S?v:v*2,height:E?g:g*2})),!X&&V.createElement("clipPath",{id:"clipPath-dots-".concat(T)},V.createElement("rect",{x:h-Q/2,y:d-Q/2,width:v+Q,height:g+Q}))):null,!b&&this.renderCurve(P,T),this.renderErrorBar(P,T),(b||a)&&this.renderDots(P,X,T),(!y||_)&&Bi.renderCallByParent(this.props,s))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,prevPoints:i.curPoints}:r.points!==i.curPoints?{curPoints:r.points}:null}},{key:"repeat",value:function(r,i){for(var o=r.length%2!==0?[].concat(cu(r),[0]):r,a=[],s=0;s=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function ELe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function al(){return al=Object.assign?Object.assign.bind():function(e){for(var t=1;t0||!ls(f,a)||!ls(d,s))?this.renderAreaWithAnimation(r,i):this.renderAreaStatically(a,s,r,i)}},{key:"render",value:function(){var r,i=this.props,o=i.hide,a=i.dot,s=i.points,l=i.className,u=i.top,f=i.left,d=i.xAxis,h=i.yAxis,v=i.width,g=i.height,y=i.isAnimationActive,x=i.id;if(o||!s||!s.length)return null;var _=this.state.isAnimationFinished,b=s.length===1,w=Pe("recharts-area",l),S=d&&d.allowDataOverflow,E=h&&h.allowDataOverflow,P=S||E,T=ze(x)?this.id:x,A=(r=De(a,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},D=A.r,k=D===void 0?3:D,I=A.strokeWidth,F=I===void 0?2:I,q=zF(a)?a:{},W=q.clipDot,X=W===void 0?!0:W,Q=k*2+F;return V.createElement(Qe,{className:w},S||E?V.createElement("defs",null,V.createElement("clipPath",{id:"clipPath-".concat(T)},V.createElement("rect",{x:S?f:f-v/2,y:E?u:u-g/2,width:S?v:v*2,height:E?g:g*2})),!X&&V.createElement("clipPath",{id:"clipPath-dots-".concat(T)},V.createElement("rect",{x:f-Q/2,y:u-Q/2,width:v+Q,height:g+Q}))):null,b?null:this.renderArea(P,T),(a||b)&&this.renderDots(P,X,T),(!y||_)&&Bi.renderCallByParent(this.props,s))}}],[{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}}]),t}(R.PureComponent);GU=Bl;ho(Bl,"displayName","Area");ho(Bl,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!pi.isSsr,animationBegin:0,animationDuration:1500,animationEasing:"ease"});ho(Bl,"getBaseValue",function(e,t,n,r){var i=e.layout,o=e.baseValue,a=t.props.baseValue,s=a??o;if(Ee(s)&&typeof s=="number")return s;var l=i==="horizontal"?r:n,u=l.scale.domain();if(l.type==="number"){var f=Math.max(u[0],u[1]),d=Math.min(u[0],u[1]);return s==="dataMin"?d:s==="dataMax"||f<0?f:Math.max(Math.min(u[0],u[1]),0)}return s==="dataMin"?u[0]:s==="dataMax"?u[1]:u[0]});ho(Bl,"getComposedData",function(e){var t=e.props,n=e.item,r=e.xAxis,i=e.yAxis,o=e.xAxisTicks,a=e.yAxisTicks,s=e.bandSize,l=e.dataKey,u=e.stackedData,f=e.dataStartIndex,d=e.displayedData,h=e.offset,v=t.layout,g=u&&u.length,y=GU.getBaseValue(t,n,r,i),x=v==="horizontal",_=!1,b=d.map(function(S,E){var P;g?P=u[f+E]:(P=kt(S,l),Array.isArray(P)?_=!0:P=[y,P]);var T=P[1]==null||g&&kt(S,l)==null;return x?{x:jc({axis:r,ticks:o,bandSize:s,entry:S,index:E}),y:T?null:i.scale(P[1]),value:P,payload:S}:{x:T?null:r.scale(P[1]),y:jc({axis:i,ticks:a,bandSize:s,entry:S,index:E}),value:P,payload:S}}),w;return g||_?w=b.map(function(S){var E=Array.isArray(S.value)?S.value[0]:null;return x?{x:S.x,y:E!=null&&S.y!=null?i.scale(E):null}:{x:E!=null?r.scale(E):null,y:S.y}}):w=x?i.scale(y):r.scale(y),Oa({points:b,baseLine:w,layout:v,isRange:_},h)});ho(Bl,"renderDotItem",function(e,t){var n;if(V.isValidElement(e))n=V.cloneElement(e,t);else if(We(e))n=e(t);else{var r=Pe("recharts-area-dot",typeof e!="boolean"?e.className:"");n=V.createElement(Xp,al({},t,{className:r}))}return n});var e1=function(){return null};e1.displayName="ZAxis";e1.defaultProps={zAxisId:0,range:[64,64],scale:"auto",type:"number"};var NLe=["option","isActive"];function qd(){return qd=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function RLe(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function LLe(e){var t=e.option,n=e.isActive,r=MLe(e,NLe);return typeof t=="string"?V.createElement(s0,qd({option:V.createElement(Mb,qd({type:t},r)),isActive:n,shapeType:"symbols"},r)):V.createElement(s0,qd({option:t,isActive:n,shapeType:"symbols"},r))}function Bc(e){"@babel/helpers - typeof";return Bc=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},Bc(e)}function Kd(){return Kd=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function c4e(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o=0)&&(n[i]=e[i]);return n}function f4e(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Q4(e,t){for(var n=0;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n0?a:t&&t.length&&Ee(i)&&Ee(o)?t.slice(i,o+1):[]};function i9(e){return e==="number"?[0,"auto"]:void 0}var YS=function(t,n,r,i){var o=t.graphicalItems,a=t.tooltipAxis,s=n1(n,t);return r<0||!o||!o.length||r>=s.length?null:o.reduce(function(l,u){var f,d=(f=u.props.data)!==null&&f!==void 0?f:n;d&&t.dataStartIndex+t.dataEndIndex!==0&&(d=d.slice(t.dataStartIndex,t.dataEndIndex+1));var h;if(a.dataKey&&!a.allowDuplicatedCategory){var v=d===void 0?s:d;h=Oy(v,a.dataKey,i)}else h=d&&d[r]||s[r];return h?[].concat(zc(l),[JB(u,h)]):l},[])},e$=function(t,n,r,i){var o=i||{x:t.chartX,y:t.chartY},a=w4e(o,r),s=t.orderedTooltipTicks,l=t.tooltipAxis,u=t.tooltipTicks,f=TTe(a,s,u,l);if(f>=0&&u){var d=u[f]&&u[f].value,h=YS(t,n,f,d),v=O4e(r,s,f,o);return{activeTooltipIndex:f,activeLabel:d,activePayload:h,activeCoordinate:v}}return null},S4e=function(t,n){var r=n.axes,i=n.graphicalItems,o=n.axisType,a=n.axisIdKey,s=n.stackGroups,l=n.dataStartIndex,u=n.dataEndIndex,f=t.layout,d=t.children,h=t.stackOffset,v=qB(f,o);return r.reduce(function(g,y){var x,_=y.props,b=_.type,w=_.dataKey,S=_.allowDataOverflow,E=_.allowDuplicatedCategory,P=_.scale,T=_.ticks,A=_.includeHidden,D=y.props[a];if(g[D])return g;var k=n1(t.data,{graphicalItems:i.filter(function(ee){return ee.props[a]===D}),dataStartIndex:l,dataEndIndex:u}),I=k.length,F,q,W;QLe(y.props.domain,S,b)&&(F=dS(y.props.domain,null,S),v&&(b==="number"||P!=="auto")&&(W=zd(k,w,"category")));var X=i9(b);if(!F||F.length===0){var Q,ne=(Q=y.props.domain)!==null&&Q!==void 0?Q:X;if(w){if(F=zd(k,w,b),b==="category"&&v){var Z=kve(F);E&&Z?(q=F,F=u0(0,I)):E||(F=vL(ne,F,y).reduce(function(ee,K){return ee.indexOf(K)>=0?ee:[].concat(zc(ee),[K])},[]))}else if(b==="category")E?F=F.filter(function(ee){return ee!==""&&!ze(ee)}):F=vL(ne,F,y).reduce(function(ee,K){return ee.indexOf(K)>=0||K===""||ze(K)?ee:[].concat(zc(ee),[K])},[]);else if(b==="number"){var z=MTe(k,i.filter(function(ee){return ee.props[a]===D&&(A||!ee.props.hide)}),w,o,f);z&&(F=z)}v&&(b==="number"||P!=="auto")&&(W=zd(k,w,"category"))}else v?F=u0(0,I):s&&s[D]&&s[D].hasStack&&b==="number"?F=h==="expand"?[0,1]:QB(s[D].stackGroups,l,u):F=GB(k,i.filter(function(ee){return ee.props[a]===D&&(A||!ee.props.hide)}),b,f,!0);if(b==="number")F=GS(d,F,D,o,T),ne&&(F=dS(ne,F,S));else if(b==="category"&&ne){var B=ne,H=F.every(function(ee){return B.indexOf(ee)>=0});H&&(F=B)}}return ve(ve({},g),{},He({},D,ve(ve({},y.props),{},{axisType:o,domain:F,categoricalDomain:W,duplicateDomain:q,originalDomain:(x=y.props.domain)!==null&&x!==void 0?x:X,isCategorical:v,layout:f})))},{})},E4e=function(t,n){var r=n.graphicalItems,i=n.Axis,o=n.axisType,a=n.axisIdKey,s=n.stackGroups,l=n.dataStartIndex,u=n.dataEndIndex,f=t.layout,d=t.children,h=n1(t.data,{graphicalItems:r,dataStartIndex:l,dataEndIndex:u}),v=h.length,g=qB(f,o),y=-1;return r.reduce(function(x,_){var b=_.props[a],w=i9("number");if(!x[b]){y++;var S;return g?S=u0(0,v):s&&s[b]&&s[b].hasStack?(S=QB(s[b].stackGroups,l,u),S=GS(d,S,b,o)):(S=dS(w,GB(h,r.filter(function(E){return E.props[a]===b&&!E.props.hide}),"number",f),i.defaultProps.allowDataOverflow),S=GS(d,S,b,o)),ve(ve({},x),{},He({},b,ve(ve({axisType:o},i.defaultProps),{},{hide:!0,orientation:Br(_4e,"".concat(o,".").concat(y%2),null),domain:S,originalDomain:w,isCategorical:g,layout:f})))}return x},{})},P4e=function(t,n){var r=n.axisType,i=r===void 0?"xAxis":r,o=n.AxisComp,a=n.graphicalItems,s=n.stackGroups,l=n.dataStartIndex,u=n.dataEndIndex,f=t.children,d="".concat(i,"Id"),h=cr(f,o),v={};return h&&h.length?v=S4e(t,{axes:h,graphicalItems:a,axisType:i,axisIdKey:d,stackGroups:s,dataStartIndex:l,dataEndIndex:u}):a&&a.length&&(v=E4e(t,{Axis:o,graphicalItems:a,axisType:i,axisIdKey:d,stackGroups:s,dataStartIndex:l,dataEndIndex:u})),v},C4e=function(t){var n=Na(t),r=zo(n,!1,!0);return{tooltipTicks:r,orderedTooltipTicks:BC(r,function(i){return i.coordinate}),tooltipAxis:n,tooltipAxisBandSize:Zy(n,r)}},t$=function(t){var n=t.children,r=t.defaultShowTooltip,i=Lr(n,Lc),o=0,a=0;return t.data&&t.data.length!==0&&(a=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(o=i.props.startIndex),i.props.endIndex>=0&&(a=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:a,activeTooltipIndex:-1,isTooltipActive:!!r}},T4e=function(t){return!t||!t.length?!1:t.some(function(n){var r=Wo(n&&n.type);return r&&r.indexOf("Bar")>=0})},n$=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"}},j4e=function(t,n){var r=t.props,i=t.graphicalItems,o=t.xAxisMap,a=o===void 0?{}:o,s=t.yAxisMap,l=s===void 0?{}:s,u=r.width,f=r.height,d=r.children,h=r.margin||{},v=Lr(d,Lc),g=Lr(d,Ih),y=Object.keys(l).reduce(function(E,P){var T=l[P],A=T.orientation;return!T.mirror&&!T.hide?ve(ve({},E),{},He({},A,E[A]+T.width)):E},{left:h.left||0,right:h.right||0}),x=Object.keys(a).reduce(function(E,P){var T=a[P],A=T.orientation;return!T.mirror&&!T.hide?ve(ve({},E),{},He({},A,Br(E,"".concat(A))+T.height)):E},{top:h.top||0,bottom:h.bottom||0}),_=ve(ve({},x),y),b=_.bottom;v&&(_.bottom+=v.props.height||Lc.defaultProps.height),g&&n&&(_=kTe(_,i,r,n));var w=u-_.left-_.right,S=f-_.top-_.bottom;return ve(ve({brushBottom:b},_),{},{width:Math.max(w,0),height:Math.max(S,0)})},A4e=function(t,n){if(n==="xAxis")return t[n].width;if(n==="yAxis")return t[n].height},ST=function(t){var n,r=t.chartName,i=t.GraphicalChild,o=t.defaultTooltipEventType,a=o===void 0?"axis":o,s=t.validateTooltipEventTypes,l=s===void 0?["axis"]:s,u=t.axisComponents,f=t.legendContent,d=t.formatAxisMap,h=t.defaultProps,v=function(x,_){var b=_.graphicalItems,w=_.stackGroups,S=_.offset,E=_.updateId,P=_.dataStartIndex,T=_.dataEndIndex,A=x.barSize,D=x.layout,k=x.barGap,I=x.barCategoryGap,F=x.maxBarSize,q=n$(D),W=q.numericAxisName,X=q.cateAxisName,Q=T4e(b),ne=[];return b.forEach(function(Z,z){var B=n1(x.data,{graphicalItems:[Z],dataStartIndex:P,dataEndIndex:T}),H=Z.props,ee=H.dataKey,K=H.maxBarSize,te=Z.props["".concat(W,"Id")],ie=Z.props["".concat(X,"Id")],ae={},fe=u.reduce(function(Te,Ce){var Ae=_["".concat(Ce.axisType,"Map")],le=Z.props["".concat(Ce.axisType,"Id")];Ae&&Ae[le]||Ce.axisType==="zAxis"||Al(!1);var ce=Ae[le];return ve(ve({},Te),{},He(He({},Ce.axisType,ce),"".concat(Ce.axisType,"Ticks"),zo(ce)))},ae),j=fe[X],N=fe["".concat(X,"Ticks")],U=w&&w[te]&&w[te].hasStack&&zTe(Z,w[te].stackGroups),J=Wo(Z.type).indexOf("Bar")>=0,Y=Zy(j,N),oe=[],he=Q&&jTe({barSize:A,stackGroups:w,totalSize:A4e(fe,X)});if(J){var Se,se,pe=ze(K)?F:K,me=(Se=(se=Zy(j,N,!0))!==null&&se!==void 0?se:pe)!==null&&Se!==void 0?Se:0;oe=ATe({barGap:k,barCategoryGap:I,bandSize:me!==Y?me:Y,sizeList:he[ie],maxBarSize:pe}),me!==Y&&(oe=oe.map(function(Te){return ve(ve({},Te),{},{position:ve(ve({},Te.position),{},{offset:Te.position.offset-me/2})})}))}var xe=Z&&Z.type&&Z.type.getComposedData;xe&&ne.push({props:ve(ve({},xe(ve(ve({},fe),{},{displayedData:B,props:x,dataKey:ee,item:Z,bandSize:Y,barPosition:oe,offset:S,stackedData:U,layout:D,dataStartIndex:P,dataEndIndex:T}))),{},He(He(He({key:Z.key||"item-".concat(z)},W,fe[W]),X,fe[X]),"animationId",E)),childIndex:Vve(Z,x.children),item:Z})}),ne},g=function(x,_){var b=x.props,w=x.dataStartIndex,S=x.dataEndIndex,E=x.updateId;if(!sM({props:b}))return null;var P=b.children,T=b.layout,A=b.stackOffset,D=b.data,k=b.reverseStackOrder,I=n$(T),F=I.numericAxisName,q=I.cateAxisName,W=cr(P,i),X=BTe(D,W,"".concat(F,"Id"),"".concat(q,"Id"),A,k),Q=u.reduce(function(H,ee){var K="".concat(ee.axisType,"Map");return ve(ve({},H),{},He({},K,P4e(b,ve(ve({},ee),{},{graphicalItems:W,stackGroups:ee.axisType===F&&X,dataStartIndex:w,dataEndIndex:S}))))},{}),ne=j4e(ve(ve({},Q),{},{props:b,graphicalItems:W}),_==null?void 0:_.legendBBox);Object.keys(Q).forEach(function(H){Q[H]=d(b,Q[H],ne,H.replace("Map",""),r)});var Z=Q["".concat(q,"Map")],z=C4e(Z),B=v(b,ve(ve({},Q),{},{dataStartIndex:w,dataEndIndex:S,updateId:E,graphicalItems:W,stackGroups:X,offset:ne}));return ve(ve({formattedGraphicalItems:B,graphicalItems:W,offset:ne,stackGroups:X},z),Q)};return n=function(y){m4e(x,y);function x(_){var b,w,S;return f4e(this,x),S=h4e(this,x,[_]),He(ct(S),"eventEmitterSymbol",Symbol("rechartsEventEmitter")),He(ct(S),"accessibilityManager",new XLe),He(ct(S),"handleLegendBBoxUpdate",function(E){if(E){var P=S.state,T=P.dataStartIndex,A=P.dataEndIndex,D=P.updateId;S.setState(ve({legendBBox:E},g({props:S.props,dataStartIndex:T,dataEndIndex:A,updateId:D},ve(ve({},S.state),{},{legendBBox:E}))))}}),He(ct(S),"handleReceiveSyncEvent",function(E,P,T){if(S.props.syncId===E){if(T===S.eventEmitterSymbol&&typeof S.props.syncMethod!="function")return;S.applySyncEvent(P)}}),He(ct(S),"handleBrushChange",function(E){var P=E.startIndex,T=E.endIndex;if(P!==S.state.dataStartIndex||T!==S.state.dataEndIndex){var A=S.state.updateId;S.setState(function(){return ve({dataStartIndex:P,dataEndIndex:T},g({props:S.props,dataStartIndex:P,dataEndIndex:T,updateId:A},S.state))}),S.triggerSyncEvent({dataStartIndex:P,dataEndIndex:T})}}),He(ct(S),"handleMouseEnter",function(E){var P=S.getMouseInfo(E);if(P){var T=ve(ve({},P),{},{isTooltipActive:!0});S.setState(T),S.triggerSyncEvent(T);var A=S.props.onMouseEnter;We(A)&&A(T,E)}}),He(ct(S),"triggeredAfterMouseMove",function(E){var P=S.getMouseInfo(E),T=P?ve(ve({},P),{},{isTooltipActive:!0}):{isTooltipActive:!1};S.setState(T),S.triggerSyncEvent(T);var A=S.props.onMouseMove;We(A)&&A(T,E)}),He(ct(S),"handleItemMouseEnter",function(E){S.setState(function(){return{isTooltipActive:!0,activeItem:E,activePayload:E.tooltipPayload,activeCoordinate:E.tooltipPosition||{x:E.cx,y:E.cy}}})}),He(ct(S),"handleItemMouseLeave",function(){S.setState(function(){return{isTooltipActive:!1}})}),He(ct(S),"handleMouseMove",function(E){E.persist(),S.throttleTriggeredAfterMouseMove(E)}),He(ct(S),"handleMouseLeave",function(E){S.throttleTriggeredAfterMouseMove.cancel();var P={isTooltipActive:!1};S.setState(P),S.triggerSyncEvent(P);var T=S.props.onMouseLeave;We(T)&&T(P,E)}),He(ct(S),"handleOuterEvent",function(E){var P=zve(E),T=Br(S.props,"".concat(P));if(P&&We(T)){var A,D;/.*touch.*/i.test(P)?D=S.getMouseInfo(E.changedTouches[0]):D=S.getMouseInfo(E),T((A=D)!==null&&A!==void 0?A:{},E)}}),He(ct(S),"handleClick",function(E){var P=S.getMouseInfo(E);if(P){var T=ve(ve({},P),{},{isTooltipActive:!0});S.setState(T),S.triggerSyncEvent(T);var A=S.props.onClick;We(A)&&A(T,E)}}),He(ct(S),"handleMouseDown",function(E){var P=S.props.onMouseDown;if(We(P)){var T=S.getMouseInfo(E);P(T,E)}}),He(ct(S),"handleMouseUp",function(E){var P=S.props.onMouseUp;if(We(P)){var T=S.getMouseInfo(E);P(T,E)}}),He(ct(S),"handleTouchMove",function(E){E.changedTouches!=null&&E.changedTouches.length>0&&S.throttleTriggeredAfterMouseMove(E.changedTouches[0])}),He(ct(S),"handleTouchStart",function(E){E.changedTouches!=null&&E.changedTouches.length>0&&S.handleMouseDown(E.changedTouches[0])}),He(ct(S),"handleTouchEnd",function(E){E.changedTouches!=null&&E.changedTouches.length>0&&S.handleMouseUp(E.changedTouches[0])}),He(ct(S),"triggerSyncEvent",function(E){S.props.syncId!==void 0&&px.emit(mx,S.props.syncId,E,S.eventEmitterSymbol)}),He(ct(S),"applySyncEvent",function(E){var P=S.props,T=P.layout,A=P.syncMethod,D=S.state.updateId,k=E.dataStartIndex,I=E.dataEndIndex;if(E.dataStartIndex!==void 0||E.dataEndIndex!==void 0)S.setState(ve({dataStartIndex:k,dataEndIndex:I},g({props:S.props,dataStartIndex:k,dataEndIndex:I,updateId:D},S.state)));else if(E.activeTooltipIndex!==void 0){var F=E.chartX,q=E.chartY,W=E.activeTooltipIndex,X=S.state,Q=X.offset,ne=X.tooltipTicks;if(!Q)return;if(typeof A=="function")W=A(ne,E);else if(A==="value"){W=-1;for(var Z=0;Z=0){var U,J;if(F.dataKey&&!F.allowDuplicatedCategory){var Y=typeof F.dataKey=="function"?N:"payload.".concat(F.dataKey.toString());U=Oy(Z,Y,W),J=z&&B&&Oy(B,Y,W)}else U=Z==null?void 0:Z[q],J=z&&B&&B[q];if(ie||te){var oe=E.props.activeIndex!==void 0?E.props.activeIndex:q;return[R.cloneElement(E,ve(ve(ve({},A.props),fe),{},{activeIndex:oe})),null,null]}if(!ze(U))return[j].concat(zc(S.renderActivePoints({item:A,activePoint:U,basePoint:J,childIndex:q,isRange:z})))}else{var he,Se=(he=S.getItemByXY(S.state.activeCoordinate))!==null&&he!==void 0?he:{graphicalItem:j},se=Se.graphicalItem,pe=se.item,me=pe===void 0?E:pe,xe=se.childIndex,Te=ve(ve(ve({},A.props),fe),{},{activeIndex:xe});return[R.cloneElement(me,Te),null,null]}return z?[j,null,null]:[j,null]}),He(ct(S),"renderCustomized",function(E,P,T){return R.cloneElement(E,ve(ve({key:"recharts-customized-".concat(T)},S.props),S.state))}),He(ct(S),"renderMap",{CartesianGrid:{handler:Sv,once:!0},ReferenceArea:{handler:S.renderReferenceElement},ReferenceLine:{handler:Sv},ReferenceDot:{handler:S.renderReferenceElement},XAxis:{handler:Sv},YAxis:{handler:Sv},Brush:{handler:S.renderBrush,once:!0},Bar:{handler:S.renderGraphicChild},Line:{handler:S.renderGraphicChild},Area:{handler:S.renderGraphicChild},Radar:{handler:S.renderGraphicChild},RadialBar:{handler:S.renderGraphicChild},Scatter:{handler:S.renderGraphicChild},Pie:{handler:S.renderGraphicChild},Funnel:{handler:S.renderGraphicChild},Tooltip:{handler:S.renderCursor,once:!0},PolarGrid:{handler:S.renderPolarGrid,once:!0},PolarAngleAxis:{handler:S.renderPolarAxis},PolarRadiusAxis:{handler:S.renderPolarAxis},Customized:{handler:S.renderCustomized}}),S.clipPathId="".concat((b=_.id)!==null&&b!==void 0?b:_s("recharts"),"-clip"),S.throttleTriggeredAfterMouseMove=G7(S.triggeredAfterMouseMove,(w=_.throttleDelay)!==null&&w!==void 0?w:1e3/60),S.state={},S}return d4e(x,[{key:"componentDidMount",value:function(){var b,w;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(b=this.props.margin.left)!==null&&b!==void 0?b:0,top:(w=this.props.margin.top)!==null&&w!==void 0?w:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var b=this.props,w=b.children,S=b.data,E=b.height,P=b.layout,T=Lr(w,ii);if(T){var A=T.props.defaultIndex;if(!(typeof A!="number"||A<0||A>this.state.tooltipTicks.length)){var D=this.state.tooltipTicks[A]&&this.state.tooltipTicks[A].value,k=YS(this.state,S,A,D),I=this.state.tooltipTicks[A].coordinate,F=(this.state.offset.top+E)/2,q=P==="horizontal",W=q?{x:I,y:F}:{y:I,x:F},X=this.state.formattedGraphicalItems.find(function(ne){var Z=ne.item;return Z.type.name==="Scatter"});X&&(W=ve(ve({},W),X.props.points[A].tooltipPosition),k=X.props.points[A].tooltipPayload);var Q={activeTooltipIndex:A,isTooltipActive:!0,activeLabel:D,activePayload:k,activeCoordinate:W};this.setState(Q),this.renderCursor(T),this.accessibilityManager.setIndex(A)}}}},{key:"getSnapshotBeforeUpdate",value:function(b,w){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==w.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==b.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==b.margin){var S,E;this.accessibilityManager.setDetails({offset:{left:(S=this.props.margin.left)!==null&&S!==void 0?S:0,top:(E=this.props.margin.top)!==null&&E!==void 0?E:0}})}return null}},{key:"componentDidUpdate",value:function(b){CO([Lr(b.children,ii)],[Lr(this.props.children,ii)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var b=Lr(this.props.children,ii);if(b&&typeof b.props.shared=="boolean"){var w=b.props.shared?"axis":"item";return l.indexOf(w)>=0?w:a}return a}},{key:"getMouseInfo",value:function(b){if(!this.container)return null;var w=this.container,S=w.getBoundingClientRect(),E=cSe(S),P={chartX:Math.round(b.pageX-E.left),chartY:Math.round(b.pageY-E.top)},T=S.width/w.offsetWidth||1,A=this.inRange(P.chartX,P.chartY,T);if(!A)return null;var D=this.state,k=D.xAxisMap,I=D.yAxisMap,F=this.getTooltipEventType();if(F!=="axis"&&k&&I){var q=Na(k).scale,W=Na(I).scale,X=q&&q.invert?q.invert(P.chartX):null,Q=W&&W.invert?W.invert(P.chartY):null;return ve(ve({},P),{},{xValue:X,yValue:Q})}var ne=e$(this.state,this.props.data,this.props.layout,A);return ne?ve(ve({},P),ne):null}},{key:"inRange",value:function(b,w){var S=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,E=this.props.layout,P=b/S,T=w/S;if(E==="horizontal"||E==="vertical"){var A=this.state.offset,D=P>=A.left&&P<=A.left+A.width&&T>=A.top&&T<=A.top+A.height;return D?{x:P,y:T}:null}var k=this.state,I=k.angleAxisMap,F=k.radiusAxisMap;if(I&&F){var q=Na(I);return bL({x:P,y:T},q)}return null}},{key:"parseEventsOfWrapper",value:function(){var b=this.props.children,w=this.getTooltipEventType(),S=Lr(b,ii),E={};S&&w==="axis"&&(S.props.trigger==="click"?E={onClick:this.handleClick}:E={onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd});var P=Sy(this.props,this.handleOuterEvent);return ve(ve({},P),E)}},{key:"addListener",value:function(){px.on(mx,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){px.removeListener(mx,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(b,w,S){for(var E=this.state.formattedGraphicalItems,P=0,T=E.length;P");return e}function I4e(e){function t(n,r){const{instance:i,context:o}=e(n).current;return R.useImperativeHandle(r,()=>i),n.children==null?null:V.createElement(s9,{value:o},n.children)}return R.forwardRef(t)}function D4e(e){function t(n,r){const[i,o]=R.useState(!1),{instance:a}=e(n,o).current;R.useImperativeHandle(r,()=>a),R.useEffect(function(){i&&a.update()},[a,i,n.children]);const s=a._contentNode;return s?W0.createPortal(n.children,s):null}return R.forwardRef(t)}function F4e(e){function t(n,r){const{instance:i}=e(n).current;return R.useImperativeHandle(r,()=>i),null}return R.forwardRef(t)}function u9(e,t){const n=R.useRef();R.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 ET(e,t){const n=e.pane??t.pane;return n?{...e,pane:n}:e}function B4e(e,t){return function(r,i){const o=l9(),a=e(ET(r,o),o);return o9(o.map,r.attribution),u9(a.current,r.eventHandlers),t(a.current,o,r,i),a}}var ZS={exports:{}};/* @preserve * Leaflet 1.9.4, a JS library for interactive maps. https://leafletjs.com * (c) 2010-2023 Vladimir Agafonkin, (c) 2010-2011 CloudMade */(function(e,t){(function(n,r){r(t)})(Ys,function(n){var r="1.9.4";function i(c){var p,O,C,M;for(O=1,C=arguments.length;O"u"||!L||!L.Mixin)){c=w(c)?c:[c];for(var p=0;p0?Math.floor(c):Math.ceil(c)};Z.prototype={clone:function(){return new Z(this.x,this.y)},add:function(c){return this.clone()._add(B(c))},_add:function(c){return this.x+=c.x,this.y+=c.y,this},subtract:function(c){return this.clone()._subtract(B(c))},_subtract:function(c){return this.x-=c.x,this.y-=c.y,this},divideBy:function(c){return this.clone()._divideBy(c)},_divideBy:function(c){return this.x/=c,this.y/=c,this},multiplyBy:function(c){return this.clone()._multiplyBy(c)},_multiplyBy:function(c){return this.x*=c,this.y*=c,this},scaleBy:function(c){return new Z(this.x*c.x,this.y*c.y)},unscaleBy:function(c){return new Z(this.x/c.x,this.y/c.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(c){c=B(c);var p=c.x-this.x,O=c.y-this.y;return Math.sqrt(p*p+O*O)},equals:function(c){return c=B(c),c.x===this.x&&c.y===this.y},contains:function(c){return c=B(c),Math.abs(c.x)<=Math.abs(this.x)&&Math.abs(c.y)<=Math.abs(this.y)},toString:function(){return"Point("+h(this.x)+", "+h(this.y)+")"}};function B(c,p,O){return c instanceof Z?c:w(c)?new Z(c[0],c[1]):c==null?c:typeof c=="object"&&"x"in c&&"y"in c?new Z(c.x,c.y):new Z(c,p,O)}function H(c,p){if(c)for(var O=p?[c,p]:c,C=0,M=O.length;C=this.min.x&&O.x<=this.max.x&&p.y>=this.min.y&&O.y<=this.max.y},intersects:function(c){c=ee(c);var p=this.min,O=this.max,C=c.min,M=c.max,G=M.x>=p.x&&C.x<=O.x,re=M.y>=p.y&&C.y<=O.y;return G&&re},overlaps:function(c){c=ee(c);var p=this.min,O=this.max,C=c.min,M=c.max,G=M.x>p.x&&C.xp.y&&C.y=p.lat&&M.lat<=O.lat&&C.lng>=p.lng&&M.lng<=O.lng},intersects:function(c){c=te(c);var p=this._southWest,O=this._northEast,C=c.getSouthWest(),M=c.getNorthEast(),G=M.lat>=p.lat&&C.lat<=O.lat,re=M.lng>=p.lng&&C.lng<=O.lng;return G&&re},overlaps:function(c){c=te(c);var p=this._southWest,O=this._northEast,C=c.getSouthWest(),M=c.getNorthEast(),G=M.lat>p.lat&&C.latp.lng&&C.lng1,Xt=function(){var c=!1;try{var p=Object.defineProperty({},"passive",{get:function(){c=!0}});window.addEventListener("testPassiveEventSupport",d,p),window.removeEventListener("testPassiveEventSupport",d,p)}catch{}return c}(),Qn=function(){return!!document.createElement("canvas").getContext}(),Nn=!!(document.createElementNS&&Se("svg").createSVGRect),Mn=!!Nn&&function(){var c=document.createElement("div");return c.innerHTML="",(c.firstChild&&c.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"}(),un=!Nn&&function(){try{var c=document.createElement("div");c.innerHTML='';var p=c.firstChild;return p.style.behavior="url(#default#VML)",p&&typeof p.adj=="object"}catch{return!1}}(),wi=navigator.platform.indexOf("Mac")===0,Oi=navigator.platform.indexOf("Linux")===0;function Rn(c){return navigator.userAgent.toLowerCase().indexOf(c)>=0}var Be={ie:me,ielt9:xe,edge:Te,webkit:Ce,android:Ae,android23:le,androidStock:ye,opera:ge,chrome:we,gecko:ke,safari:Me,phantom:et,opera12:nt,win:Ze,ie3d:Gt,webkit3d:Ft,gecko3d:bn,any3d:Xn,mobile:Zi,mobileWebkit:kn,mobileWebkit3d:Of,msPointer:Xi,pointer:lm,touch:cm,touchNative:um,mobileOpera:Sf,mobileGecko:Es,retina:rn,passiveEvents:Xt,canvas:Qn,svg:Nn,vml:un,inlineSvg:Mn,mac:wi,linux:Oi},JT=Be.msPointer?"MSPointerDown":"pointerdown",ej=Be.msPointer?"MSPointerMove":"pointermove",tj=Be.msPointer?"MSPointerUp":"pointerup",nj=Be.msPointer?"MSPointerCancel":"pointercancel",d1={touchstart:JT,touchmove:ej,touchend:tj,touchcancel:nj},rj={touchstart:BV,touchmove:fm,touchend:fm,touchcancel:fm},Vl={},ij=!1;function LV(c,p,O){return p==="touchstart"&&FV(),rj[p]?(O=rj[p].bind(this,O),c.addEventListener(d1[p],O,!1),O):(console.warn("wrong event specified:",p),d)}function $V(c,p,O){if(!d1[p]){console.warn("wrong event specified:",p);return}c.removeEventListener(d1[p],O,!1)}function IV(c){Vl[c.pointerId]=c}function DV(c){Vl[c.pointerId]&&(Vl[c.pointerId]=c)}function oj(c){delete Vl[c.pointerId]}function FV(){ij||(document.addEventListener(JT,IV,!0),document.addEventListener(ej,DV,!0),document.addEventListener(tj,oj,!0),document.addEventListener(nj,oj,!0),ij=!0)}function fm(c,p){if(p.pointerType!==(p.MSPOINTER_TYPE_MOUSE||"mouse")){p.touches=[];for(var O in Vl)p.touches.push(Vl[O]);p.changedTouches=[p],c(p)}}function BV(c,p){p.MSPOINTER_TYPE_TOUCH&&p.pointerType===p.MSPOINTER_TYPE_TOUCH&&Ln(p),fm(c,p)}function UV(c){var p={},O,C;for(C in c)O=c[C],p[C]=O&&O.bind?O.bind(c):O;return c=p,p.type="dblclick",p.detail=2,p.isTrusted=!1,p._simulated=!0,p}var zV=200;function VV(c,p){c.addEventListener("dblclick",p);var O=0,C;function M(G){if(G.detail!==1){C=G.detail;return}if(!(G.pointerType==="mouse"||G.sourceCapabilities&&!G.sourceCapabilities.firesTouchEvents)){var re=cj(G);if(!(re.some(function(de){return de instanceof HTMLLabelElement&&de.attributes.for})&&!re.some(function(de){return de instanceof HTMLInputElement||de instanceof HTMLSelectElement}))){var ue=Date.now();ue-O<=zV?(C++,C===2&&p(UV(G))):C=1,O=ue}}}return c.addEventListener("click",M),{dblclick:p,simDblclick:M}}function WV(c,p){c.removeEventListener("dblclick",p.dblclick),c.removeEventListener("click",p.simDblclick)}var h1=pm(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),Ef=pm(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),aj=Ef==="webkitTransition"||Ef==="OTransition"?Ef+"End":"transitionend";function sj(c){return typeof c=="string"?document.getElementById(c):c}function Pf(c,p){var O=c.style[p]||c.currentStyle&&c.currentStyle[p];if((!O||O==="auto")&&document.defaultView){var C=document.defaultView.getComputedStyle(c,null);O=C?C[p]:null}return O==="auto"?null:O}function dt(c,p,O){var C=document.createElement(c);return C.className=p||"",O&&O.appendChild(C),C}function Bt(c){var p=c.parentNode;p&&p.removeChild(c)}function dm(c){for(;c.firstChild;)c.removeChild(c.firstChild)}function Wl(c){var p=c.parentNode;p&&p.lastChild!==c&&p.appendChild(c)}function Hl(c){var p=c.parentNode;p&&p.firstChild!==c&&p.insertBefore(c,p.firstChild)}function p1(c,p){if(c.classList!==void 0)return c.classList.contains(p);var O=hm(c);return O.length>0&&new RegExp("(^|\\s)"+p+"(\\s|$)").test(O)}function Je(c,p){if(c.classList!==void 0)for(var O=g(p),C=0,M=O.length;C0?2*window.devicePixelRatio:1;function dj(c){return Be.edge?c.wheelDeltaY/2:c.deltaY&&c.deltaMode===0?-c.deltaY/qV:c.deltaY&&c.deltaMode===1?-c.deltaY*20:c.deltaY&&c.deltaMode===2?-c.deltaY*60:c.deltaX||c.deltaZ?0:c.wheelDelta?(c.wheelDeltaY||c.wheelDelta)/2:c.detail&&Math.abs(c.detail)<32765?-c.detail*20:c.detail?c.detail/-32765*60:0}function P1(c,p){var O=p.relatedTarget;if(!O)return!0;try{for(;O&&O!==c;)O=O.parentNode}catch{return!1}return O!==c}var KV={__proto__:null,on:Xe,off:xt,stopPropagation:Ts,disableScrollPropagation:E1,disableClickPropagation:Af,preventDefault:Ln,stop:js,getPropagationPath:cj,getMousePosition:fj,getWheelDelta:dj,isExternalTarget:P1,addListener:Xe,removeListener:xt},hj=ne.extend({run:function(c,p,O,C){this.stop(),this._el=c,this._inProgress=!0,this._duration=O||.25,this._easeOutPower=1/Math.max(C||.5,.2),this._startPos=Cs(c),this._offset=p.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=I(this._animate,this),this._step()},_step:function(c){var p=+new Date-this._startTime,O=this._duration*1e3;pthis.options.maxZoom)?this.setZoom(c):this},panInsideBounds:function(c,p){this._enforcingBounds=!0;var O=this.getCenter(),C=this._limitCenter(O,this._zoom,te(c));return O.equals(C)||this.panTo(C,p),this._enforcingBounds=!1,this},panInside:function(c,p){p=p||{};var O=B(p.paddingTopLeft||p.padding||[0,0]),C=B(p.paddingBottomRight||p.padding||[0,0]),M=this.project(this.getCenter()),G=this.project(c),re=this.getPixelBounds(),ue=ee([re.min.add(O),re.max.subtract(C)]),de=ue.getSize();if(!ue.contains(G)){this._enforcingBounds=!0;var _e=G.subtract(ue.getCenter()),Re=ue.extend(G).getSize().subtract(de);M.x+=_e.x<0?-Re.x:Re.x,M.y+=_e.y<0?-Re.y:Re.y,this.panTo(this.unproject(M),p),this._enforcingBounds=!1}return this},invalidateSize:function(c){if(!this._loaded)return this;c=i({animate:!1,pan:!0},c===!0?{animate:!0}:c);var p=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var O=this.getSize(),C=p.divideBy(2).round(),M=O.divideBy(2).round(),G=C.subtract(M);return!G.x&&!G.y?this:(c.animate&&c.pan?this.panBy(G):(c.pan&&this._rawPanBy(G),this.fire("move"),c.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(a(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:p,newSize:O}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(c){if(c=this._locateOptions=i({timeout:1e4,watch:!1},c),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var p=a(this._handleGeolocationResponse,this),O=a(this._handleGeolocationError,this);return c.watch?this._locationWatchId=navigator.geolocation.watchPosition(p,O,c):navigator.geolocation.getCurrentPosition(p,O,c),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(c){if(this._container._leaflet_id){var p=c.code,O=c.message||(p===1?"permission denied":p===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:p,message:"Geolocation error: "+O+"."})}},_handleGeolocationResponse:function(c){if(this._container._leaflet_id){var p=c.coords.latitude,O=c.coords.longitude,C=new ie(p,O),M=C.toBounds(c.coords.accuracy*2),G=this._locateOptions;if(G.setView){var re=this.getBoundsZoom(M);this.setView(C,G.maxZoom?Math.min(re,G.maxZoom):re)}var ue={latlng:C,bounds:M,timestamp:c.timestamp};for(var de in c.coords)typeof c.coords[de]=="number"&&(ue[de]=c.coords[de]);this.fire("locationfound",ue)}},addHandler:function(c,p){if(!p)return this;var O=this[c]=new p(this);return this._handlers.push(O),this.options[c]&&O.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(),Bt(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(F(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var c;for(c in this._layers)this._layers[c].remove();for(c in this._panes)Bt(this._panes[c]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(c,p){var O="leaflet-pane"+(c?" leaflet-"+c.replace("Pane","")+"-pane":""),C=dt("div",O,p||this._mapPane);return c&&(this._panes[c]=C),C},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var c=this.getPixelBounds(),p=this.unproject(c.getBottomLeft()),O=this.unproject(c.getTopRight());return new K(p,O)},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(c,p,O){c=te(c),O=B(O||[0,0]);var C=this.getZoom()||0,M=this.getMinZoom(),G=this.getMaxZoom(),re=c.getNorthWest(),ue=c.getSouthEast(),de=this.getSize().subtract(O),_e=ee(this.project(ue,C),this.project(re,C)).getSize(),Re=Be.any3d?this.options.zoomSnap:1,Ve=de.x/_e.x,tt=de.y/_e.y,Jn=p?Math.max(Ve,tt):Math.min(Ve,tt);return C=this.getScaleZoom(Jn,C),Re&&(C=Math.round(C/(Re/100))*(Re/100),C=p?Math.ceil(C/Re)*Re:Math.floor(C/Re)*Re),Math.max(M,Math.min(G,C))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new Z(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(c,p){var O=this._getTopLeftPoint(c,p);return new H(O,O.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(c){return this.options.crs.getProjectedBounds(c===void 0?this.getZoom():c)},getPane:function(c){return typeof c=="string"?this._panes[c]:c},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(c,p){var O=this.options.crs;return p=p===void 0?this._zoom:p,O.scale(c)/O.scale(p)},getScaleZoom:function(c,p){var O=this.options.crs;p=p===void 0?this._zoom:p;var C=O.zoom(c*O.scale(p));return isNaN(C)?1/0:C},project:function(c,p){return p=p===void 0?this._zoom:p,this.options.crs.latLngToPoint(ae(c),p)},unproject:function(c,p){return p=p===void 0?this._zoom:p,this.options.crs.pointToLatLng(B(c),p)},layerPointToLatLng:function(c){var p=B(c).add(this.getPixelOrigin());return this.unproject(p)},latLngToLayerPoint:function(c){var p=this.project(ae(c))._round();return p._subtract(this.getPixelOrigin())},wrapLatLng:function(c){return this.options.crs.wrapLatLng(ae(c))},wrapLatLngBounds:function(c){return this.options.crs.wrapLatLngBounds(te(c))},distance:function(c,p){return this.options.crs.distance(ae(c),ae(p))},containerPointToLayerPoint:function(c){return B(c).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(c){return B(c).add(this._getMapPanePos())},containerPointToLatLng:function(c){var p=this.containerPointToLayerPoint(B(c));return this.layerPointToLatLng(p)},latLngToContainerPoint:function(c){return this.layerPointToContainerPoint(this.latLngToLayerPoint(ae(c)))},mouseEventToContainerPoint:function(c){return fj(c,this._container)},mouseEventToLayerPoint:function(c){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(c))},mouseEventToLatLng:function(c){return this.layerPointToLatLng(this.mouseEventToLayerPoint(c))},_initContainer:function(c){var p=this._container=sj(c);if(p){if(p._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");Xe(p,"scroll",this._onScroll,this),this._containerId=l(p)},_initLayout:function(){var c=this._container;this._fadeAnimated=this.options.fadeAnimation&&Be.any3d,Je(c,"leaflet-container"+(Be.touch?" leaflet-touch":"")+(Be.retina?" leaflet-retina":"")+(Be.ielt9?" leaflet-oldie":"")+(Be.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var p=Pf(c,"position");p!=="absolute"&&p!=="relative"&&p!=="fixed"&&p!=="sticky"&&(c.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var c=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),on(this._mapPane,new Z(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(Je(c.markerPane,"leaflet-zoom-hide"),Je(c.shadowPane,"leaflet-zoom-hide"))},_resetView:function(c,p,O){on(this._mapPane,new Z(0,0));var C=!this._loaded;this._loaded=!0,p=this._limitZoom(p),this.fire("viewprereset");var M=this._zoom!==p;this._moveStart(M,O)._move(c,p)._moveEnd(M),this.fire("viewreset"),C&&this.fire("load")},_moveStart:function(c,p){return c&&this.fire("zoomstart"),p||this.fire("movestart"),this},_move:function(c,p,O,C){p===void 0&&(p=this._zoom);var M=this._zoom!==p;return this._zoom=p,this._lastCenter=c,this._pixelOrigin=this._getNewPixelOrigin(c),C?O&&O.pinch&&this.fire("zoom",O):((M||O&&O.pinch)&&this.fire("zoom",O),this.fire("move",O)),this},_moveEnd:function(c){return c&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return F(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(c){on(this._mapPane,this._getMapPanePos().subtract(c))},_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(c){this._targets={},this._targets[l(this._container)]=this;var p=c?xt:Xe;p(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&p(window,"resize",this._onResize,this),Be.any3d&&this.options.transform3DLimit&&(c?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){F(this._resizeRequest),this._resizeRequest=I(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var c=this._getMapPanePos();Math.max(Math.abs(c.x),Math.abs(c.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(c,p){for(var O=[],C,M=p==="mouseout"||p==="mouseover",G=c.target||c.srcElement,re=!1;G;){if(C=this._targets[l(G)],C&&(p==="click"||p==="preclick")&&this._draggableMoved(C)){re=!0;break}if(C&&C.listens(p,!0)&&(M&&!P1(G,c)||(O.push(C),M))||G===this._container)break;G=G.parentNode}return!O.length&&!re&&!M&&this.listens(p,!0)&&(O=[this]),O},_isClickDisabled:function(c){for(;c&&c!==this._container;){if(c._leaflet_disable_click)return!0;c=c.parentNode}},_handleDOMEvent:function(c){var p=c.target||c.srcElement;if(!(!this._loaded||p._leaflet_disable_events||c.type==="click"&&this._isClickDisabled(p))){var O=c.type;O==="mousedown"&&_1(p),this._fireDOMEvent(c,O)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(c,p,O){if(c.type==="click"){var C=i({},c);C.type="preclick",this._fireDOMEvent(C,C.type,O)}var M=this._findEventTargets(c,p);if(O){for(var G=[],re=0;re0?Math.round(c-p)/2:Math.max(0,Math.ceil(c))-Math.max(0,Math.floor(p))},_limitZoom:function(c){var p=this.getMinZoom(),O=this.getMaxZoom(),C=Be.any3d?this.options.zoomSnap:1;return C&&(c=Math.round(c/C)*C),Math.max(p,Math.min(O,c))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){Qt(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(c,p){var O=this._getCenterOffset(c)._trunc();return(p&&p.animate)!==!0&&!this.getSize().contains(O)?!1:(this.panBy(O,p),!0)},_createAnimProxy:function(){var c=this._proxy=dt("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(c),this.on("zoomanim",function(p){var O=h1,C=this._proxy.style[O];Ps(this._proxy,this.project(p.center,p.zoom),this.getZoomScale(p.zoom,1)),C===this._proxy.style[O]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){Bt(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var c=this.getCenter(),p=this.getZoom();Ps(this._proxy,this.project(c,p),this.getZoomScale(p,1))},_catchTransitionEnd:function(c){this._animatingZoom&&c.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(c,p,O){if(this._animatingZoom)return!0;if(O=O||{},!this._zoomAnimated||O.animate===!1||this._nothingToAnimate()||Math.abs(p-this._zoom)>this.options.zoomAnimationThreshold)return!1;var C=this.getZoomScale(p),M=this._getCenterOffset(c)._divideBy(1-1/C);return O.animate!==!0&&!this.getSize().contains(M)?!1:(I(function(){this._moveStart(!0,O.noMoveStart||!1)._animateZoom(c,p,!0)},this),!0)},_animateZoom:function(c,p,O,C){this._mapPane&&(O&&(this._animatingZoom=!0,this._animateToCenter=c,this._animateToZoom=p,Je(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:c,zoom:p,noUpdate:C}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(a(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&Qt(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 YV(c,p){return new ut(c,p)}var Si=W.extend({options:{position:"topright"},initialize:function(c){y(this,c)},getPosition:function(){return this.options.position},setPosition:function(c){var p=this._map;return p&&p.removeControl(this),this.options.position=c,p&&p.addControl(this),this},getContainer:function(){return this._container},addTo:function(c){this.remove(),this._map=c;var p=this._container=this.onAdd(c),O=this.getPosition(),C=c._controlCorners[O];return Je(p,"leaflet-control"),O.indexOf("bottom")!==-1?C.insertBefore(p,C.firstChild):C.appendChild(p),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(Bt(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(c){this._map&&c&&c.screenX>0&&c.screenY>0&&this._map.getContainer().focus()}}),kf=function(c){return new Si(c)};ut.include({addControl:function(c){return c.addTo(this),this},removeControl:function(c){return c.remove(),this},_initControlPos:function(){var c=this._controlCorners={},p="leaflet-",O=this._controlContainer=dt("div",p+"control-container",this._container);function C(M,G){var re=p+M+" "+p+G;c[M+G]=dt("div",re,O)}C("top","left"),C("top","right"),C("bottom","left"),C("bottom","right")},_clearControlPos:function(){for(var c in this._controlCorners)Bt(this._controlCorners[c]);Bt(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var pj=Si.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(c,p,O,C){return O1,this._baseLayersList.style.display=c?"":"none"),this._separator.style.display=p&&c?"":"none",this},_onLayerChange:function(c){this._handlingClick||this._update();var p=this._getLayer(l(c.target)),O=p.overlay?c.type==="add"?"overlayadd":"overlayremove":c.type==="add"?"baselayerchange":null;O&&this._map.fire(O,p)},_createRadioElement:function(c,p){var O='",C=document.createElement("div");return C.innerHTML=O,C.firstChild},_addItem:function(c){var p=document.createElement("label"),O=this._map.hasLayer(c.layer),C;c.overlay?(C=document.createElement("input"),C.type="checkbox",C.className="leaflet-control-layers-selector",C.defaultChecked=O):C=this._createRadioElement("leaflet-base-layers_"+l(this),O),this._layerControlInputs.push(C),C.layerId=l(c.layer),Xe(C,"click",this._onInputClick,this);var M=document.createElement("span");M.innerHTML=" "+c.name;var G=document.createElement("span");p.appendChild(G),G.appendChild(C),G.appendChild(M);var re=c.overlay?this._overlaysList:this._baseLayersList;return re.appendChild(p),this._checkDisabledLayers(),p},_onInputClick:function(){if(!this._preventClick){var c=this._layerControlInputs,p,O,C=[],M=[];this._handlingClick=!0;for(var G=c.length-1;G>=0;G--)p=c[G],O=this._getLayer(p.layerId).layer,p.checked?C.push(O):p.checked||M.push(O);for(G=0;G=0;M--)p=c[M],O=this._getLayer(p.layerId).layer,p.disabled=O.options.minZoom!==void 0&&CO.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var c=this._section;this._preventClick=!0,Xe(c,"click",Ln),this.expand();var p=this;setTimeout(function(){xt(c,"click",Ln),p._preventClick=!1})}}),ZV=function(c,p,O){return new pj(c,p,O)},C1=Si.extend({options:{position:"topleft",zoomInText:'',zoomInTitle:"Zoom in",zoomOutText:'',zoomOutTitle:"Zoom out"},onAdd:function(c){var p="leaflet-control-zoom",O=dt("div",p+" leaflet-bar"),C=this.options;return this._zoomInButton=this._createButton(C.zoomInText,C.zoomInTitle,p+"-in",O,this._zoomIn),this._zoomOutButton=this._createButton(C.zoomOutText,C.zoomOutTitle,p+"-out",O,this._zoomOut),this._updateDisabled(),c.on("zoomend zoomlevelschange",this._updateDisabled,this),O},onRemove:function(c){c.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(c){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(c.shiftKey?3:1))},_createButton:function(c,p,O,C,M){var G=dt("a",O,C);return G.innerHTML=c,G.href="#",G.title=p,G.setAttribute("role","button"),G.setAttribute("aria-label",p),Af(G),Xe(G,"click",js),Xe(G,"click",M,this),Xe(G,"click",this._refocusOnMap,this),G},_updateDisabled:function(){var c=this._map,p="leaflet-disabled";Qt(this._zoomInButton,p),Qt(this._zoomOutButton,p),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||c._zoom===c.getMinZoom())&&(Je(this._zoomOutButton,p),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||c._zoom===c.getMaxZoom())&&(Je(this._zoomInButton,p),this._zoomInButton.setAttribute("aria-disabled","true"))}});ut.mergeOptions({zoomControl:!0}),ut.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new C1,this.addControl(this.zoomControl))});var XV=function(c){return new C1(c)},mj=Si.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(c){var p="leaflet-control-scale",O=dt("div",p),C=this.options;return this._addScales(C,p+"-line",O),c.on(C.updateWhenIdle?"moveend":"move",this._update,this),c.whenReady(this._update,this),O},onRemove:function(c){c.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(c,p,O){c.metric&&(this._mScale=dt("div",p,O)),c.imperial&&(this._iScale=dt("div",p,O))},_update:function(){var c=this._map,p=c.getSize().y/2,O=c.distance(c.containerPointToLatLng([0,p]),c.containerPointToLatLng([this.options.maxWidth,p]));this._updateScales(O)},_updateScales:function(c){this.options.metric&&c&&this._updateMetric(c),this.options.imperial&&c&&this._updateImperial(c)},_updateMetric:function(c){var p=this._getRoundNum(c),O=p<1e3?p+" m":p/1e3+" km";this._updateScale(this._mScale,O,p/c)},_updateImperial:function(c){var p=c*3.2808399,O,C,M;p>5280?(O=p/5280,C=this._getRoundNum(O),this._updateScale(this._iScale,C+" mi",C/O)):(M=this._getRoundNum(p),this._updateScale(this._iScale,M+" ft",M/p))},_updateScale:function(c,p,O){c.style.width=Math.round(this.options.maxWidth*O)+"px",c.innerHTML=p},_getRoundNum:function(c){var p=Math.pow(10,(Math.floor(c)+"").length-1),O=c/p;return O=O>=10?10:O>=5?5:O>=3?3:O>=2?2:1,p*O}}),QV=function(c){return new mj(c)},JV='',T1=Si.extend({options:{position:"bottomright",prefix:''+(Be.inlineSvg?JV+" ":"")+"Leaflet"},initialize:function(c){y(this,c),this._attributions={}},onAdd:function(c){c.attributionControl=this,this._container=dt("div","leaflet-control-attribution"),Af(this._container);for(var p in c._layers)c._layers[p].getAttribution&&this.addAttribution(c._layers[p].getAttribution());return this._update(),c.on("layeradd",this._addAttribution,this),this._container},onRemove:function(c){c.off("layeradd",this._addAttribution,this)},_addAttribution:function(c){c.layer.getAttribution&&(this.addAttribution(c.layer.getAttribution()),c.layer.once("remove",function(){this.removeAttribution(c.layer.getAttribution())},this))},setPrefix:function(c){return this.options.prefix=c,this._update(),this},addAttribution:function(c){return c?(this._attributions[c]||(this._attributions[c]=0),this._attributions[c]++,this._update(),this):this},removeAttribution:function(c){return c?(this._attributions[c]&&(this._attributions[c]--,this._update()),this):this},_update:function(){if(this._map){var c=[];for(var p in this._attributions)this._attributions[p]&&c.push(p);var O=[];this.options.prefix&&O.push(this.options.prefix),c.length&&O.push(c.join(", ")),this._container.innerHTML=O.join(' ')}}});ut.mergeOptions({attributionControl:!0}),ut.addInitHook(function(){this.options.attributionControl&&new T1().addTo(this)});var eW=function(c){return new T1(c)};Si.Layers=pj,Si.Zoom=C1,Si.Scale=mj,Si.Attribution=T1,kf.layers=ZV,kf.zoom=XV,kf.scale=QV,kf.attribution=eW;var Ji=W.extend({initialize:function(c){this._map=c},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}});Ji.addTo=function(c,p){return c.addHandler(p,this),this};var tW={Events:Q},vj=Be.touch?"touchstart mousedown":"mousedown",ma=ne.extend({options:{clickTolerance:3},initialize:function(c,p,O,C){y(this,C),this._element=c,this._dragStartTarget=p||c,this._preventOutline=O},enable:function(){this._enabled||(Xe(this._dragStartTarget,vj,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(ma._dragging===this&&this.finishDrag(!0),xt(this._dragStartTarget,vj,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(c){if(this._enabled&&(this._moved=!1,!p1(this._element,"leaflet-zoom-anim"))){if(c.touches&&c.touches.length!==1){ma._dragging===this&&this.finishDrag();return}if(!(ma._dragging||c.shiftKey||c.which!==1&&c.button!==1&&!c.touches)&&(ma._dragging=this,this._preventOutline&&_1(this._element),g1(),Cf(),!this._moving)){this.fire("down");var p=c.touches?c.touches[0]:c,O=lj(this._element);this._startPoint=new Z(p.clientX,p.clientY),this._startPos=Cs(this._element),this._parentScale=x1(O);var C=c.type==="mousedown";Xe(document,C?"mousemove":"touchmove",this._onMove,this),Xe(document,C?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(c){if(this._enabled){if(c.touches&&c.touches.length>1){this._moved=!0;return}var p=c.touches&&c.touches.length===1?c.touches[0]:c,O=new Z(p.clientX,p.clientY)._subtract(this._startPoint);!O.x&&!O.y||Math.abs(O.x)+Math.abs(O.y)G&&(re=ue,G=de);G>O&&(p[re]=1,A1(c,p,O,C,re),A1(c,p,O,re,M))}function oW(c,p){for(var O=[c[0]],C=1,M=0,G=c.length;Cp&&(O.push(c[C]),M=C);return Mp.max.x&&(O|=2),c.yp.max.y&&(O|=8),O}function aW(c,p){var O=p.x-c.x,C=p.y-c.y;return O*O+C*C}function Nf(c,p,O,C){var M=p.x,G=p.y,re=O.x-M,ue=O.y-G,de=re*re+ue*ue,_e;return de>0&&(_e=((c.x-M)*re+(c.y-G)*ue)/de,_e>1?(M=O.x,G=O.y):_e>0&&(M+=re*_e,G+=ue*_e)),re=c.x-M,ue=c.y-G,C?re*re+ue*ue:new Z(M,G)}function Xr(c){return!w(c[0])||typeof c[0][0]!="object"&&typeof c[0][0]<"u"}function Oj(c){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),Xr(c)}function Sj(c,p){var O,C,M,G,re,ue,de,_e;if(!c||c.length===0)throw new Error("latlngs not passed");Xr(c)||(console.warn("latlngs are not flat! Only the first ring will be used"),c=c[0]);var Re=ae([0,0]),Ve=te(c),tt=Ve.getNorthWest().distanceTo(Ve.getSouthWest())*Ve.getNorthEast().distanceTo(Ve.getNorthWest());tt<1700&&(Re=j1(c));var Jn=c.length,_n=[];for(O=0;OC){de=(G-C)/M,_e=[ue.x-de*(ue.x-re.x),ue.y-de*(ue.y-re.y)];break}var mr=p.unproject(B(_e));return ae([mr.lat+Re.lat,mr.lng+Re.lng])}var sW={__proto__:null,simplify:bj,pointToSegmentDistance:_j,closestPointOnSegment:rW,clipSegment:wj,_getEdgeIntersection:gm,_getBitCode:As,_sqClosestPointOnSegment:Nf,isFlat:Xr,_flat:Oj,polylineCenter:Sj},k1={project:function(c){return new Z(c.lng,c.lat)},unproject:function(c){return new ie(c.y,c.x)},bounds:new H([-180,-90],[180,90])},N1={R:6378137,R_MINOR:6356752314245179e-9,bounds:new H([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(c){var p=Math.PI/180,O=this.R,C=c.lat*p,M=this.R_MINOR/O,G=Math.sqrt(1-M*M),re=G*Math.sin(C),ue=Math.tan(Math.PI/4-C/2)/Math.pow((1-re)/(1+re),G/2);return C=-O*Math.log(Math.max(ue,1e-10)),new Z(c.lng*p*O,C)},unproject:function(c){for(var p=180/Math.PI,O=this.R,C=this.R_MINOR/O,M=Math.sqrt(1-C*C),G=Math.exp(-c.y/O),re=Math.PI/2-2*Math.atan(G),ue=0,de=.1,_e;ue<15&&Math.abs(de)>1e-7;ue++)_e=M*Math.sin(re),_e=Math.pow((1-_e)/(1+_e),M/2),de=Math.PI/2-2*Math.atan(G*_e)-re,re+=de;return new ie(re*p,c.x*p/O)}},lW={__proto__:null,LonLat:k1,Mercator:N1,SphericalMercator:U},uW=i({},j,{code:"EPSG:3395",projection:N1,transformation:function(){var c=.5/(Math.PI*N1.R);return Y(c,.5,-c,.5)}()}),Ej=i({},j,{code:"EPSG:4326",projection:k1,transformation:Y(1/180,1,-1/180,.5)}),cW=i({},fe,{projection:k1,transformation:Y(1,0,-1,0),scale:function(c){return Math.pow(2,c)},zoom:function(c){return Math.log(c)/Math.LN2},distance:function(c,p){var O=p.lng-c.lng,C=p.lat-c.lat;return Math.sqrt(O*O+C*C)},infinite:!0});fe.Earth=j,fe.EPSG3395=uW,fe.EPSG3857=oe,fe.EPSG900913=he,fe.EPSG4326=Ej,fe.Simple=cW;var Ei=ne.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(c){return c.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(c){return c&&c.removeLayer(this),this},getPane:function(c){return this._map.getPane(c?this.options[c]||c:this.options.pane)},addInteractiveTarget:function(c){return this._map._targets[l(c)]=this,this},removeInteractiveTarget:function(c){return delete this._map._targets[l(c)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(c){var p=c.target;if(p.hasLayer(this)){if(this._map=p,this._zoomAnimated=p._zoomAnimated,this.getEvents){var O=this.getEvents();p.on(O,this),this.once("remove",function(){p.off(O,this)},this)}this.onAdd(p),this.fire("add"),p.fire("layeradd",{layer:this})}}});ut.include({addLayer:function(c){if(!c._layerAdd)throw new Error("The provided object is not a Layer.");var p=l(c);return this._layers[p]?this:(this._layers[p]=c,c._mapToAdd=this,c.beforeAdd&&c.beforeAdd(this),this.whenReady(c._layerAdd,c),this)},removeLayer:function(c){var p=l(c);return this._layers[p]?(this._loaded&&c.onRemove(this),delete this._layers[p],this._loaded&&(this.fire("layerremove",{layer:c}),c.fire("remove")),c._map=c._mapToAdd=null,this):this},hasLayer:function(c){return l(c)in this._layers},eachLayer:function(c,p){for(var O in this._layers)c.call(p,this._layers[O]);return this},_addLayers:function(c){c=c?w(c)?c:[c]:[];for(var p=0,O=c.length;pthis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()=2&&p[0]instanceof ie&&p[0].equals(p[O-1])&&p.pop(),p},_setLatLngs:function(c){ko.prototype._setLatLngs.call(this,c),Xr(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return Xr(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var c=this._renderer._bounds,p=this.options.weight,O=new Z(p,p);if(c=new H(c.min.subtract(O),c.max.add(O)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(c))){if(this.options.noClip){this._parts=this._rings;return}for(var C=0,M=this._rings.length,G;Cc.y!=M.y>c.y&&c.x<(M.x-C.x)*(c.y-C.y)/(M.y-C.y)+C.x&&(p=!p);return p||ko.prototype._containsPoint.call(this,c,!0)}});function yW(c,p){return new Kl(c,p)}var No=Ao.extend({initialize:function(c,p){y(this,p),this._layers={},c&&this.addData(c)},addData:function(c){var p=w(c)?c:c.features,O,C,M;if(p){for(O=0,C=p.length;O0&&M.push(M[0].slice()),M}function Yl(c,p){return c.feature?i({},c.feature,{geometry:p}):Om(p)}function Om(c){return c.type==="Feature"||c.type==="FeatureCollection"?c:{type:"Feature",properties:{},geometry:c}}var $1={toGeoJSON:function(c){return Yl(this,{type:"Point",coordinates:L1(this.getLatLng(),c)})}};ym.include($1),M1.include($1),bm.include($1),ko.include({toGeoJSON:function(c){var p=!Xr(this._latlngs),O=wm(this._latlngs,p?1:0,!1,c);return Yl(this,{type:(p?"Multi":"")+"LineString",coordinates:O})}}),Kl.include({toGeoJSON:function(c){var p=!Xr(this._latlngs),O=p&&!Xr(this._latlngs[0]),C=wm(this._latlngs,O?2:p?1:0,!0,c);return p||(C=[C]),Yl(this,{type:(O?"Multi":"")+"Polygon",coordinates:C})}}),Gl.include({toMultiPoint:function(c){var p=[];return this.eachLayer(function(O){p.push(O.toGeoJSON(c).geometry.coordinates)}),Yl(this,{type:"MultiPoint",coordinates:p})},toGeoJSON:function(c){var p=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(p==="MultiPoint")return this.toMultiPoint(c);var O=p==="GeometryCollection",C=[];return this.eachLayer(function(M){if(M.toGeoJSON){var G=M.toGeoJSON(c);if(O)C.push(G.geometry);else{var re=Om(G);re.type==="FeatureCollection"?C.push.apply(C,re.features):C.push(re)}}}),O?Yl(this,{geometries:C,type:"GeometryCollection"}):{type:"FeatureCollection",features:C}}});function Tj(c,p){return new No(c,p)}var bW=Tj,Sm=Ei.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(c,p,O){this._url=c,this._bounds=te(p),y(this,O)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(Je(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){Bt(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(c){return this.options.opacity=c,this._image&&this._updateOpacity(),this},setStyle:function(c){return c.opacity&&this.setOpacity(c.opacity),this},bringToFront:function(){return this._map&&Wl(this._image),this},bringToBack:function(){return this._map&&Hl(this._image),this},setUrl:function(c){return this._url=c,this._image&&(this._image.src=c),this},setBounds:function(c){return this._bounds=te(c),this._map&&this._reset(),this},getEvents:function(){var c={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(c.zoomanim=this._animateZoom),c},setZIndex:function(c){return this.options.zIndex=c,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var c=this._url.tagName==="IMG",p=this._image=c?this._url:dt("img");if(Je(p,"leaflet-image-layer"),this._zoomAnimated&&Je(p,"leaflet-zoom-animated"),this.options.className&&Je(p,this.options.className),p.onselectstart=d,p.onmousemove=d,p.onload=a(this.fire,this,"load"),p.onerror=a(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(p.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),c){this._url=p.src;return}p.src=this._url,p.alt=this.options.alt},_animateZoom:function(c){var p=this._map.getZoomScale(c.zoom),O=this._map._latLngBoundsToNewLayerBounds(this._bounds,c.zoom,c.center).min;Ps(this._image,O,p)},_reset:function(){var c=this._image,p=new H(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),O=p.getSize();on(c,p.min),c.style.width=O.x+"px",c.style.height=O.y+"px"},_updateOpacity:function(){Zr(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 c=this.options.errorOverlayUrl;c&&this._url!==c&&(this._url=c,this._image.src=c)},getCenter:function(){return this._bounds.getCenter()}}),_W=function(c,p,O){return new Sm(c,p,O)},jj=Sm.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var c=this._url.tagName==="VIDEO",p=this._image=c?this._url:dt("video");if(Je(p,"leaflet-image-layer"),this._zoomAnimated&&Je(p,"leaflet-zoom-animated"),this.options.className&&Je(p,this.options.className),p.onselectstart=d,p.onmousemove=d,p.onloadeddata=a(this.fire,this,"load"),c){for(var O=p.getElementsByTagName("source"),C=[],M=0;M0?C:[p.src];return}w(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(p.style,"objectFit")&&(p.style.objectFit="fill"),p.autoplay=!!this.options.autoplay,p.loop=!!this.options.loop,p.muted=!!this.options.muted,p.playsInline=!!this.options.playsInline;for(var G=0;GM?(p.height=M+"px",Je(c,G)):Qt(c,G),this._containerWidth=this._container.offsetWidth},_animateZoom:function(c){var p=this._map._latLngToNewLayerPoint(this._latlng,c.zoom,c.center),O=this._getAnchor();on(this._container,p.add(O))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var c=this._map,p=parseInt(Pf(this._container,"marginBottom"),10)||0,O=this._container.offsetHeight+p,C=this._containerWidth,M=new Z(this._containerLeft,-O-this._containerBottom);M._add(Cs(this._container));var G=c.layerPointToContainerPoint(M),re=B(this.options.autoPanPadding),ue=B(this.options.autoPanPaddingTopLeft||re),de=B(this.options.autoPanPaddingBottomRight||re),_e=c.getSize(),Re=0,Ve=0;G.x+C+de.x>_e.x&&(Re=G.x+C-_e.x+de.x),G.x-Re-ue.x<0&&(Re=G.x-ue.x),G.y+O+de.y>_e.y&&(Ve=G.y+O-_e.y+de.y),G.y-Ve-ue.y<0&&(Ve=G.y-ue.y),(Re||Ve)&&(this.options.keepInView&&(this._autopanning=!0),c.fire("autopanstart").panBy([Re,Ve]))}},_getAnchor:function(){return B(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),OW=function(c,p){return new Em(c,p)};ut.mergeOptions({closePopupOnClick:!0}),ut.include({openPopup:function(c,p,O){return this._initOverlay(Em,c,p,O).openOn(this),this},closePopup:function(c){return c=arguments.length?c:this._popup,c&&c.close(),this}}),Ei.include({bindPopup:function(c,p){return this._popup=this._initOverlay(Em,this._popup,c,p),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(c){return this._popup&&(this instanceof Ao||(this._popup._source=this),this._popup._prepareOpen(c||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(c){return this._popup&&this._popup.setContent(c),this},getPopup:function(){return this._popup},_openPopup:function(c){if(!(!this._popup||!this._map)){js(c);var p=c.layer||c.target;if(this._popup._source===p&&!(p instanceof va)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(c.latlng);return}this._popup._source=p,this.openPopup(c.latlng)}},_movePopup:function(c){this._popup.setLatLng(c.latlng)},_onKeyPress:function(c){c.originalEvent.keyCode===13&&this._openPopup(c)}});var Pm=eo.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(c){eo.prototype.onAdd.call(this,c),this.setOpacity(this.options.opacity),c.fire("tooltipopen",{tooltip:this}),this._source&&(this.addEventParent(this._source),this._source.fire("tooltipopen",{tooltip:this},!0))},onRemove:function(c){eo.prototype.onRemove.call(this,c),c.fire("tooltipclose",{tooltip:this}),this._source&&(this.removeEventParent(this._source),this._source.fire("tooltipclose",{tooltip:this},!0))},getEvents:function(){var c=eo.prototype.getEvents.call(this);return this.options.permanent||(c.preclick=this.close),c},_initLayout:function(){var c="leaflet-tooltip",p=c+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=dt("div",p),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+l(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(c){var p,O,C=this._map,M=this._container,G=C.latLngToContainerPoint(C.getCenter()),re=C.layerPointToContainerPoint(c),ue=this.options.direction,de=M.offsetWidth,_e=M.offsetHeight,Re=B(this.options.offset),Ve=this._getAnchor();ue==="top"?(p=de/2,O=_e):ue==="bottom"?(p=de/2,O=0):ue==="center"?(p=de/2,O=_e/2):ue==="right"?(p=0,O=_e/2):ue==="left"?(p=de,O=_e/2):re.xthis.options.maxZoom||OC?this._retainParent(M,G,re,C):!1)},_retainChildren:function(c,p,O,C){for(var M=2*c;M<2*c+2;M++)for(var G=2*p;G<2*p+2;G++){var re=new Z(M,G);re.z=O+1;var ue=this._tileCoordsToKey(re),de=this._tiles[ue];if(de&&de.active){de.retain=!0;continue}else de&&de.loaded&&(de.retain=!0);O+1this.options.maxZoom||this.options.minZoom!==void 0&&M1){this._setView(c,O);return}for(var Ve=M.min.y;Ve<=M.max.y;Ve++)for(var tt=M.min.x;tt<=M.max.x;tt++){var Jn=new Z(tt,Ve);if(Jn.z=this._tileZoom,!!this._isValidTile(Jn)){var _n=this._tiles[this._tileCoordsToKey(Jn)];_n?_n.current=!0:re.push(Jn)}}if(re.sort(function(mr,Xl){return mr.distanceTo(G)-Xl.distanceTo(G)}),re.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var Qr=document.createDocumentFragment();for(tt=0;ttO.max.x)||!p.wrapLat&&(c.yO.max.y))return!1}if(!this.options.bounds)return!0;var C=this._tileCoordsToBounds(c);return te(this.options.bounds).overlaps(C)},_keyToBounds:function(c){return this._tileCoordsToBounds(this._keyToTileCoords(c))},_tileCoordsToNwSe:function(c){var p=this._map,O=this.getTileSize(),C=c.scaleBy(O),M=C.add(O),G=p.unproject(C,c.z),re=p.unproject(M,c.z);return[G,re]},_tileCoordsToBounds:function(c){var p=this._tileCoordsToNwSe(c),O=new K(p[0],p[1]);return this.options.noWrap||(O=this._map.wrapLatLngBounds(O)),O},_tileCoordsToKey:function(c){return c.x+":"+c.y+":"+c.z},_keyToTileCoords:function(c){var p=c.split(":"),O=new Z(+p[0],+p[1]);return O.z=+p[2],O},_removeTile:function(c){var p=this._tiles[c];p&&(Bt(p.el),delete this._tiles[c],this.fire("tileunload",{tile:p.el,coords:this._keyToTileCoords(c)}))},_initTile:function(c){Je(c,"leaflet-tile");var p=this.getTileSize();c.style.width=p.x+"px",c.style.height=p.y+"px",c.onselectstart=d,c.onmousemove=d,Be.ielt9&&this.options.opacity<1&&Zr(c,this.options.opacity)},_addTile:function(c,p){var O=this._getTilePos(c),C=this._tileCoordsToKey(c),M=this.createTile(this._wrapCoords(c),a(this._tileReady,this,c));this._initTile(M),this.createTile.length<2&&I(a(this._tileReady,this,c,null,M)),on(M,O),this._tiles[C]={el:M,coords:c,current:!0},p.appendChild(M),this.fire("tileloadstart",{tile:M,coords:c})},_tileReady:function(c,p,O){p&&this.fire("tileerror",{error:p,tile:O,coords:c});var C=this._tileCoordsToKey(c);O=this._tiles[C],O&&(O.loaded=+new Date,this._map._fadeAnimated?(Zr(O.el,0),F(this._fadeFrame),this._fadeFrame=I(this._updateOpacity,this)):(O.active=!0,this._pruneTiles()),p||(Je(O.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:O.el,coords:c})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),Be.ielt9||!this._map._fadeAnimated?I(this._pruneTiles,this):setTimeout(a(this._pruneTiles,this),250)))},_getTilePos:function(c){return c.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(c){var p=new Z(this._wrapX?f(c.x,this._wrapX):c.x,this._wrapY?f(c.y,this._wrapY):c.y);return p.z=c.z,p},_pxBoundsToTileRange:function(c){var p=this.getTileSize();return new H(c.min.unscaleBy(p).floor(),c.max.unscaleBy(p).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var c in this._tiles)if(!this._tiles[c].loaded)return!1;return!0}});function PW(c){return new Rf(c)}var Zl=Rf.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1,referrerPolicy:!1},initialize:function(c,p){this._url=c,p=y(this,p),p.detectRetina&&Be.retina&&p.maxZoom>0?(p.tileSize=Math.floor(p.tileSize/2),p.zoomReverse?(p.zoomOffset--,p.minZoom=Math.min(p.maxZoom,p.minZoom+1)):(p.zoomOffset++,p.maxZoom=Math.max(p.minZoom,p.maxZoom-1)),p.minZoom=Math.max(0,p.minZoom)):p.zoomReverse?p.minZoom=Math.min(p.maxZoom,p.minZoom):p.maxZoom=Math.max(p.minZoom,p.maxZoom),typeof p.subdomains=="string"&&(p.subdomains=p.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(c,p){return this._url===c&&p===void 0&&(p=!0),this._url=c,p||this.redraw(),this},createTile:function(c,p){var O=document.createElement("img");return Xe(O,"load",a(this._tileOnLoad,this,p,O)),Xe(O,"error",a(this._tileOnError,this,p,O)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(O.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(O.referrerPolicy=this.options.referrerPolicy),O.alt="",O.src=this.getTileUrl(c),O},getTileUrl:function(c){var p={r:Be.retina?"@2x":"",s:this._getSubdomain(c),x:c.x,y:c.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var O=this._globalTileRange.max.y-c.y;this.options.tms&&(p.y=O),p["-y"]=O}return b(this._url,i(p,this.options))},_tileOnLoad:function(c,p){Be.ielt9?setTimeout(a(c,this,null,p),0):c(null,p)},_tileOnError:function(c,p,O){var C=this.options.errorTileUrl;C&&p.getAttribute("src")!==C&&(p.src=C),c(O,p)},_onTileRemove:function(c){c.tile.onload=null},_getZoomForUrl:function(){var c=this._tileZoom,p=this.options.maxZoom,O=this.options.zoomReverse,C=this.options.zoomOffset;return O&&(c=p-c),c+C},_getSubdomain:function(c){var p=Math.abs(c.x+c.y)%this.options.subdomains.length;return this.options.subdomains[p]},_abortLoading:function(){var c,p;for(c in this._tiles)if(this._tiles[c].coords.z!==this._tileZoom&&(p=this._tiles[c].el,p.onload=d,p.onerror=d,!p.complete)){p.src=E;var O=this._tiles[c].coords;Bt(p),delete this._tiles[c],this.fire("tileabort",{tile:p,coords:O})}},_removeTile:function(c){var p=this._tiles[c];if(p)return p.el.setAttribute("src",E),Rf.prototype._removeTile.call(this,c)},_tileReady:function(c,p,O){if(!(!this._map||O&&O.getAttribute("src")===E))return Rf.prototype._tileReady.call(this,c,p,O)}});function Nj(c,p){return new Zl(c,p)}var Mj=Zl.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(c,p){this._url=c;var O=i({},this.defaultWmsParams);for(var C in p)C in this.options||(O[C]=p[C]);p=y(this,p);var M=p.detectRetina&&Be.retina?2:1,G=this.getTileSize();O.width=G.x*M,O.height=G.y*M,this.wmsParams=O},onAdd:function(c){this._crs=this.options.crs||c.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var p=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[p]=this._crs.code,Zl.prototype.onAdd.call(this,c)},getTileUrl:function(c){var p=this._tileCoordsToNwSe(c),O=this._crs,C=ee(O.project(p[0]),O.project(p[1])),M=C.min,G=C.max,re=(this._wmsVersion>=1.3&&this._crs===Ej?[M.y,M.x,G.y,G.x]:[M.x,M.y,G.x,G.y]).join(","),ue=Zl.prototype.getTileUrl.call(this,c);return ue+x(this.wmsParams,ue,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+re},setParams:function(c,p){return i(this.wmsParams,c),p||this.redraw(),this}});function CW(c,p){return new Mj(c,p)}Zl.WMS=Mj,Nj.wms=CW;var Mo=Ei.extend({options:{padding:.1},initialize:function(c){y(this,c),l(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),Je(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 c={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(c.zoomanim=this._onAnimZoom),c},_onAnimZoom:function(c){this._updateTransform(c.center,c.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(c,p){var O=this._map.getZoomScale(p,this._zoom),C=this._map.getSize().multiplyBy(.5+this.options.padding),M=this._map.project(this._center,p),G=C.multiplyBy(-O).add(M).subtract(this._map._getNewPixelOrigin(c,p));Be.any3d?Ps(this._container,G,O):on(this._container,G)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var c in this._layers)this._layers[c]._reset()},_onZoomEnd:function(){for(var c in this._layers)this._layers[c]._project()},_updatePaths:function(){for(var c in this._layers)this._layers[c]._update()},_update:function(){var c=this.options.padding,p=this._map.getSize(),O=this._map.containerPointToLayerPoint(p.multiplyBy(-c)).round();this._bounds=new H(O,O.add(p.multiplyBy(1+c*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),Rj=Mo.extend({options:{tolerance:0},getEvents:function(){var c=Mo.prototype.getEvents.call(this);return c.viewprereset=this._onViewPreReset,c},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Mo.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var c=this._container=document.createElement("canvas");Xe(c,"mousemove",this._onMouseMove,this),Xe(c,"click dblclick mousedown mouseup contextmenu",this._onClick,this),Xe(c,"mouseout",this._handleMouseOut,this),c._leaflet_disable_events=!0,this._ctx=c.getContext("2d")},_destroyContainer:function(){F(this._redrawRequest),delete this._ctx,Bt(this._container),xt(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var c;this._redrawBounds=null;for(var p in this._layers)c=this._layers[p],c._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Mo.prototype._update.call(this);var c=this._bounds,p=this._container,O=c.getSize(),C=Be.retina?2:1;on(p,c.min),p.width=C*O.x,p.height=C*O.y,p.style.width=O.x+"px",p.style.height=O.y+"px",Be.retina&&this._ctx.scale(2,2),this._ctx.translate(-c.min.x,-c.min.y),this.fire("update")}},_reset:function(){Mo.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(c){this._updateDashArray(c),this._layers[l(c)]=c;var p=c._order={layer:c,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=p),this._drawLast=p,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(c){this._requestRedraw(c)},_removePath:function(c){var p=c._order,O=p.next,C=p.prev;O?O.prev=C:this._drawLast=C,C?C.next=O:this._drawFirst=O,delete c._order,delete this._layers[l(c)],this._requestRedraw(c)},_updatePath:function(c){this._extendRedrawBounds(c),c._project(),c._update(),this._requestRedraw(c)},_updateStyle:function(c){this._updateDashArray(c),this._requestRedraw(c)},_updateDashArray:function(c){if(typeof c.options.dashArray=="string"){var p=c.options.dashArray.split(/[, ]+/),O=[],C,M;for(M=0;M')}}catch{}return function(c){return document.createElement("<"+c+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),TW={_initContainer:function(){this._container=dt("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Mo.prototype._update.call(this),this.fire("update"))},_initPath:function(c){var p=c._container=Lf("shape");Je(p,"leaflet-vml-shape "+(this.options.className||"")),p.coordsize="1 1",c._path=Lf("path"),p.appendChild(c._path),this._updateStyle(c),this._layers[l(c)]=c},_addPath:function(c){var p=c._container;this._container.appendChild(p),c.options.interactive&&c.addInteractiveTarget(p)},_removePath:function(c){var p=c._container;Bt(p),c.removeInteractiveTarget(p),delete this._layers[l(c)]},_updateStyle:function(c){var p=c._stroke,O=c._fill,C=c.options,M=c._container;M.stroked=!!C.stroke,M.filled=!!C.fill,C.stroke?(p||(p=c._stroke=Lf("stroke")),M.appendChild(p),p.weight=C.weight+"px",p.color=C.color,p.opacity=C.opacity,C.dashArray?p.dashStyle=w(C.dashArray)?C.dashArray.join(" "):C.dashArray.replace(/( *, *)/g," "):p.dashStyle="",p.endcap=C.lineCap.replace("butt","flat"),p.joinstyle=C.lineJoin):p&&(M.removeChild(p),c._stroke=null),C.fill?(O||(O=c._fill=Lf("fill")),M.appendChild(O),O.color=C.fillColor||C.color,O.opacity=C.fillOpacity):O&&(M.removeChild(O),c._fill=null)},_updateCircle:function(c){var p=c._point.round(),O=Math.round(c._radius),C=Math.round(c._radiusY||O);this._setPath(c,c._empty()?"M0 0":"AL "+p.x+","+p.y+" "+O+","+C+" 0,"+65535*360)},_setPath:function(c,p){c._path.v=p},_bringToFront:function(c){Wl(c._container)},_bringToBack:function(c){Hl(c._container)}},Cm=Be.vml?Lf:Se,$f=Mo.extend({_initContainer:function(){this._container=Cm("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=Cm("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){Bt(this._container),xt(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Mo.prototype._update.call(this);var c=this._bounds,p=c.getSize(),O=this._container;(!this._svgSize||!this._svgSize.equals(p))&&(this._svgSize=p,O.setAttribute("width",p.x),O.setAttribute("height",p.y)),on(O,c.min),O.setAttribute("viewBox",[c.min.x,c.min.y,p.x,p.y].join(" ")),this.fire("update")}},_initPath:function(c){var p=c._path=Cm("path");c.options.className&&Je(p,c.options.className),c.options.interactive&&Je(p,"leaflet-interactive"),this._updateStyle(c),this._layers[l(c)]=c},_addPath:function(c){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(c._path),c.addInteractiveTarget(c._path)},_removePath:function(c){Bt(c._path),c.removeInteractiveTarget(c._path),delete this._layers[l(c)]},_updatePath:function(c){c._project(),c._update()},_updateStyle:function(c){var p=c._path,O=c.options;p&&(O.stroke?(p.setAttribute("stroke",O.color),p.setAttribute("stroke-opacity",O.opacity),p.setAttribute("stroke-width",O.weight),p.setAttribute("stroke-linecap",O.lineCap),p.setAttribute("stroke-linejoin",O.lineJoin),O.dashArray?p.setAttribute("stroke-dasharray",O.dashArray):p.removeAttribute("stroke-dasharray"),O.dashOffset?p.setAttribute("stroke-dashoffset",O.dashOffset):p.removeAttribute("stroke-dashoffset")):p.setAttribute("stroke","none"),O.fill?(p.setAttribute("fill",O.fillColor||O.color),p.setAttribute("fill-opacity",O.fillOpacity),p.setAttribute("fill-rule",O.fillRule||"evenodd")):p.setAttribute("fill","none"))},_updatePoly:function(c,p){this._setPath(c,se(c._parts,p))},_updateCircle:function(c){var p=c._point,O=Math.max(Math.round(c._radius),1),C=Math.max(Math.round(c._radiusY),1)||O,M="a"+O+","+C+" 0 1,0 ",G=c._empty()?"M0 0":"M"+(p.x-O)+","+p.y+M+O*2+",0 "+M+-O*2+",0 ";this._setPath(c,G)},_setPath:function(c,p){c._path.setAttribute("d",p)},_bringToFront:function(c){Wl(c._path)},_bringToBack:function(c){Hl(c._path)}});Be.vml&&$f.include(TW);function $j(c){return Be.svg||Be.vml?new $f(c):null}ut.include({getRenderer:function(c){var p=c.options.renderer||this._getPaneRenderer(c.options.pane)||this.options.renderer||this._renderer;return p||(p=this._renderer=this._createRenderer()),this.hasLayer(p)||this.addLayer(p),p},_getPaneRenderer:function(c){if(c==="overlayPane"||c===void 0)return!1;var p=this._paneRenderers[c];return p===void 0&&(p=this._createRenderer({pane:c}),this._paneRenderers[c]=p),p},_createRenderer:function(c){return this.options.preferCanvas&&Lj(c)||$j(c)}});var Ij=Kl.extend({initialize:function(c,p){Kl.prototype.initialize.call(this,this._boundsToLatLngs(c),p)},setBounds:function(c){return this.setLatLngs(this._boundsToLatLngs(c))},_boundsToLatLngs:function(c){return c=te(c),[c.getSouthWest(),c.getNorthWest(),c.getNorthEast(),c.getSouthEast()]}});function jW(c,p){return new Ij(c,p)}$f.create=Cm,$f.pointsToPath=se,No.geometryToLayer=_m,No.coordsToLatLng=R1,No.coordsToLatLngs=xm,No.latLngToCoords=L1,No.latLngsToCoords=wm,No.getFeature=Yl,No.asFeature=Om,ut.mergeOptions({boxZoom:!0});var Dj=Ji.extend({initialize:function(c){this._map=c,this._container=c._container,this._pane=c._panes.overlayPane,this._resetStateTimeout=0,c.on("unload",this._destroy,this)},addHooks:function(){Xe(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){xt(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){Bt(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(c){if(!c.shiftKey||c.which!==1&&c.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),Cf(),g1(),this._startPoint=this._map.mouseEventToContainerPoint(c),Xe(document,{contextmenu:js,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(c){this._moved||(this._moved=!0,this._box=dt("div","leaflet-zoom-box",this._container),Je(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(c);var p=new H(this._point,this._startPoint),O=p.getSize();on(this._box,p.min),this._box.style.width=O.x+"px",this._box.style.height=O.y+"px"},_finish:function(){this._moved&&(Bt(this._box),Qt(this._container,"leaflet-crosshair")),Tf(),y1(),xt(document,{contextmenu:js,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(c){if(!(c.which!==1&&c.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(a(this._resetState,this),0);var p=new K(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(p).fire("boxzoomend",{boxZoomBounds:p})}},_onKeyDown:function(c){c.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});ut.addInitHook("addHandler","boxZoom",Dj),ut.mergeOptions({doubleClickZoom:!0});var Fj=Ji.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(c){var p=this._map,O=p.getZoom(),C=p.options.zoomDelta,M=c.originalEvent.shiftKey?O-C:O+C;p.options.doubleClickZoom==="center"?p.setZoom(M):p.setZoomAround(c.containerPoint,M)}});ut.addInitHook("addHandler","doubleClickZoom",Fj),ut.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var Bj=Ji.extend({addHooks:function(){if(!this._draggable){var c=this._map;this._draggable=new ma(c._mapPane,c._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),c.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),c.on("zoomend",this._onZoomEnd,this),c.whenReady(this._onZoomEnd,this))}Je(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){Qt(this._map._container,"leaflet-grab"),Qt(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 c=this._map;if(c._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var p=te(this._map.options.maxBounds);this._offsetLimit=ee(this._map.latLngToContainerPoint(p.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(p.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;c.fire("movestart").fire("dragstart"),c.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(c){if(this._map.options.inertia){var p=this._lastTime=+new Date,O=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(O),this._times.push(p),this._prunePositions(p)}this._map.fire("move",c).fire("drag",c)},_prunePositions:function(c){for(;this._positions.length>1&&c-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var c=this._map.getSize().divideBy(2),p=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=p.subtract(c).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(c,p){return c-(c-p)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var c=this._draggable._newPos.subtract(this._draggable._startPos),p=this._offsetLimit;c.xp.max.x&&(c.x=this._viscousLimit(c.x,p.max.x)),c.y>p.max.y&&(c.y=this._viscousLimit(c.y,p.max.y)),this._draggable._newPos=this._draggable._startPos.add(c)}},_onPreDragWrap:function(){var c=this._worldWidth,p=Math.round(c/2),O=this._initialWorldOffset,C=this._draggable._newPos.x,M=(C-p+O)%c+p-O,G=(C+p+O)%c-p-O,re=Math.abs(M+O)0?G:-G))-p;this._delta=0,this._startTime=null,re&&(c.options.scrollWheelZoom==="center"?c.setZoom(p+re):c.setZoomAround(this._lastMousePos,p+re))}});ut.addInitHook("addHandler","scrollWheelZoom",zj);var AW=600;ut.mergeOptions({tapHold:Be.touchNative&&Be.safari&&Be.mobile,tapTolerance:15});var Vj=Ji.extend({addHooks:function(){Xe(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){xt(this._map._container,"touchstart",this._onDown,this)},_onDown:function(c){if(clearTimeout(this._holdTimeout),c.touches.length===1){var p=c.touches[0];this._startPos=this._newPos=new Z(p.clientX,p.clientY),this._holdTimeout=setTimeout(a(function(){this._cancel(),this._isTapValid()&&(Xe(document,"touchend",Ln),Xe(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",p))},this),AW),Xe(document,"touchend touchcancel contextmenu",this._cancel,this),Xe(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function c(){xt(document,"touchend",Ln),xt(document,"touchend touchcancel",c)},_cancel:function(){clearTimeout(this._holdTimeout),xt(document,"touchend touchcancel contextmenu",this._cancel,this),xt(document,"touchmove",this._onMove,this)},_onMove:function(c){var p=c.touches[0];this._newPos=new Z(p.clientX,p.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(c,p){var O=new MouseEvent(c,{bubbles:!0,cancelable:!0,view:window,screenX:p.screenX,screenY:p.screenY,clientX:p.clientX,clientY:p.clientY});O._simulated=!0,p.target.dispatchEvent(O)}});ut.addInitHook("addHandler","tapHold",Vj),ut.mergeOptions({touchZoom:Be.touch,bounceAtZoomLimits:!0});var Wj=Ji.extend({addHooks:function(){Je(this._map._container,"leaflet-touch-zoom"),Xe(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){Qt(this._map._container,"leaflet-touch-zoom"),xt(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(c){var p=this._map;if(!(!c.touches||c.touches.length!==2||p._animatingZoom||this._zooming)){var O=p.mouseEventToContainerPoint(c.touches[0]),C=p.mouseEventToContainerPoint(c.touches[1]);this._centerPoint=p.getSize()._divideBy(2),this._startLatLng=p.containerPointToLatLng(this._centerPoint),p.options.touchZoom!=="center"&&(this._pinchStartLatLng=p.containerPointToLatLng(O.add(C)._divideBy(2))),this._startDist=O.distanceTo(C),this._startZoom=p.getZoom(),this._moved=!1,this._zooming=!0,p._stop(),Xe(document,"touchmove",this._onTouchMove,this),Xe(document,"touchend touchcancel",this._onTouchEnd,this),Ln(c)}},_onTouchMove:function(c){if(!(!c.touches||c.touches.length!==2||!this._zooming)){var p=this._map,O=p.mouseEventToContainerPoint(c.touches[0]),C=p.mouseEventToContainerPoint(c.touches[1]),M=O.distanceTo(C)/this._startDist;if(this._zoom=p.getScaleZoom(M,this._startZoom),!p.options.bounceAtZoomLimits&&(this._zoomp.getMaxZoom()&&M>1)&&(this._zoom=p._limitZoom(this._zoom)),p.options.touchZoom==="center"){if(this._center=this._startLatLng,M===1)return}else{var G=O._add(C)._divideBy(2)._subtract(this._centerPoint);if(M===1&&G.x===0&&G.y===0)return;this._center=p.unproject(p.project(this._pinchStartLatLng,this._zoom).subtract(G),this._zoom)}this._moved||(p._moveStart(!0,!1),this._moved=!0),F(this._animRequest);var re=a(p._move,p,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=I(re,this,!0),Ln(c)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,F(this._animRequest),xt(document,"touchmove",this._onTouchMove,this),xt(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))}});ut.addInitHook("addHandler","touchZoom",Wj),ut.BoxZoom=Dj,ut.DoubleClickZoom=Fj,ut.Drag=Bj,ut.Keyboard=Uj,ut.ScrollWheelZoom=zj,ut.TapHold=Vj,ut.TouchZoom=Wj,n.Bounds=H,n.Browser=Be,n.CRS=fe,n.Canvas=Rj,n.Circle=M1,n.CircleMarker=bm,n.Class=W,n.Control=Si,n.DivIcon=kj,n.DivOverlay=eo,n.DomEvent=KV,n.DomUtil=GV,n.Draggable=ma,n.Evented=ne,n.FeatureGroup=Ao,n.GeoJSON=No,n.GridLayer=Rf,n.Handler=Ji,n.Icon=ql,n.ImageOverlay=Sm,n.LatLng=ie,n.LatLngBounds=K,n.Layer=Ei,n.LayerGroup=Gl,n.LineUtil=sW,n.Map=ut,n.Marker=ym,n.Mixin=tW,n.Path=va,n.Point=Z,n.PolyUtil=nW,n.Polygon=Kl,n.Polyline=ko,n.Popup=Em,n.PosAnimation=hj,n.Projection=lW,n.Rectangle=Ij,n.Renderer=Mo,n.SVG=$f,n.SVGOverlay=Aj,n.TileLayer=Zl,n.Tooltip=Pm,n.Transformation=J,n.Util=q,n.VideoOverlay=jj,n.bind=a,n.bounds=ee,n.canvas=Lj,n.circle=vW,n.circleMarker=mW,n.control=kf,n.divIcon=EW,n.extend=i,n.featureGroup=dW,n.geoJSON=Tj,n.geoJson=bW,n.gridLayer=PW,n.icon=hW,n.imageOverlay=_W,n.latLng=ae,n.latLngBounds=te,n.layerGroup=fW,n.map=YV,n.marker=pW,n.point=B,n.polygon=yW,n.polyline=gW,n.popup=OW,n.rectangle=jW,n.setOptions=y,n.stamp=l,n.svg=$j,n.svgOverlay=wW,n.tileLayer=Nj,n.tooltip=SW,n.transformation=Y,n.version=r,n.videoOverlay=xW;var kW=window.L;n.noConflict=function(){return window.L=kW,this},window.L=n})})(ZS,ZS.exports);var em=ZS.exports;const r$=st(em);function PT(e,t,n){return Object.freeze({instance:e,context:t,container:n})}function CT(e,t){return t==null?function(r,i){const o=R.useRef();return o.current||(o.current=e(r,i)),o}:function(r,i){const o=R.useRef();o.current||(o.current=e(r,i));const a=R.useRef(r),{instance:s}=o.current;return R.useEffect(function(){a.current!==r&&(t(s,r,a.current),a.current=r)},[s,r,i]),o}}function U4e(e,t){R.useEffect(function(){return(t.layerContainer??t.map).addLayer(e.instance),function(){var o;(o=t.layerContainer)==null||o.removeLayer(e.instance),t.map.removeLayer(e.instance)}},[t,e])}function c9(e){return function(n){const r=l9(),i=e(ET(n,r),r);return o9(r.map,n.attribution),u9(i.current,n.eventHandlers),U4e(i.current,r),i}}function z4e(e,t){const n=CT(e,t),r=c9(n);return I4e(r)}function V4e(e,t){const n=CT(e),r=B4e(n,t);return D4e(r)}function W4e(e,t){const n=CT(e,t),r=c9(n);return F4e(r)}function H4e(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 XS(){return XS=Object.assign||function(e){for(var t=1;t(v==null?void 0:v.map)??null,[v]);const y=R.useCallback(_=>{if(_!==null&&v===null){const b=new em.Map(_,f);n!=null&&u!=null?b.setView(n,u):e!=null&&b.fitBounds(e,t),l!=null&&b.whenReady(l),g(L4e(b))}},[]);R.useEffect(()=>()=>{v==null||v.map.remove()},[v]);const x=v?V.createElement(s9,{value:v},r):a??null;return V.createElement("div",XS({},h,{ref:y}),x)}const q4e=R.forwardRef(G4e),K4e=z4e(function({position:t,...n},r){const i=new em.Marker(t,n);return PT(i,$4e(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())}),Y4e=V4e(function(t,n){const r=new em.Popup(t,n.overlayContainer);return PT(r,n)},function(t,n,{position:r},i){R.useEffect(function(){const{instance:a}=t;function s(u){u.popup===a&&(a.update(),i(!0))}function l(u){u.popup===a&&i(!1)}return n.map.on({popupopen:s,popupclose:l}),n.overlayContainer==null?(r!=null&&a.setLatLng(r),a.openOn(n.map)):n.overlayContainer.bindPopup(a),function(){var f;n.map.off({popupopen:s,popupclose:l}),(f=n.overlayContainer)==null||f.unbindPopup(),n.map.removeLayer(a)}},[t,n,i,r])}),Z4e=W4e(function({url:t,...n},r){const i=new em.TileLayer(t,ET(n,r));return PT(i,r)},function(t,n,r){H4e(t,n,r);const{url:i}=n;i!=null&&i!==r.url&&t.setUrl(i)}),X4e={"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"},f9={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"},Jt={tablet:"tablet",mobile:"mobile",desktop:"desktop",tv:"tv"},tr={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"},Sa={EdgeHTML:"EdgeHTML",Blink:"Blink",Trident:"Trident",Presto:"Presto",Gecko:"Gecko",WebKit:"WebKit"};class be{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=be.getVersionPrecision(t),o=be.getVersionPrecision(n);let a=Math.max(i,o),s=0;const l=be.map([t,n],u=>{const f=a-be.getVersionPrecision(u),d=u+new Array(f+1).join(".0");return be.map(d.split("."),h=>new Array(20-h.length).join("0")+h).reverse()});for(r&&(s=a-Math.min(i,o)),a-=1;a>=s;){if(l[0][a]>l[1][a])return 1;if(l[0][a]===l[1][a]){if(a===s)return 0;a-=1}else if(l[0][a]{r[l]=a[l]})}return t}static getBrowserAlias(t){return X4e[t]}static getBrowserTypeByAlias(t){return f9[t]||""}}const bt=/version\/(\d+(\.?_?\d+)+)/i,Q4e=[{test:[/googlebot/i],describe(e){const t={name:"Googlebot"},n=be.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/opera/i],describe(e){const t={name:"Opera"},n=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/opr\/|opios/i],describe(e){const t={name:"Opera"},n=be.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/SamsungBrowser/i],describe(e){const t={name:"Samsung Internet for Android"},n=be.getFirstMatch(bt,e)||be.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=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/MZBrowser/i],describe(e){const t={name:"MZ Browser"},n=be.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/focus/i],describe(e){const t={name:"Focus"},n=be.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/swing/i],describe(e){const t={name:"Swing"},n=be.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/coast/i],describe(e){const t={name:"Opera Coast"},n=be.getFirstMatch(bt,e)||be.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=be.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/yabrowser/i],describe(e){const t={name:"Yandex Browser"},n=be.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/ucbrowser/i],describe(e){const t={name:"UC Browser"},n=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/Maxthon|mxios/i],describe(e){const t={name:"Maxthon"},n=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/epiphany/i],describe(e){const t={name:"Epiphany"},n=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/puffin/i],describe(e){const t={name:"Puffin"},n=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/sleipnir/i],describe(e){const t={name:"Sleipnir"},n=be.getFirstMatch(bt,e)||be.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=be.getFirstMatch(bt,e)||be.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/micromessenger/i],describe(e){const t={name:"WeChat"},n=be.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,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=be.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/msie|trident/i],describe(e){const t={name:"Internet Explorer"},n=be.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/\sedg\//i],describe(e){const t={name:"Microsoft Edge"},n=be.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=be.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/vivaldi/i],describe(e){const t={name:"Vivaldi"},n=be.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/seamonkey/i],describe(e){const t={name:"SeaMonkey"},n=be.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/sailfish/i],describe(e){const t={name:"Sailfish"},n=be.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=be.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/phantom/i],describe(e){const t={name:"PhantomJS"},n=be.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/slimerjs/i],describe(e){const t={name:"SlimerJS"},n=be.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=be.getFirstMatch(bt,e)||be.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=be.getFirstMatch(bt,e)||be.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=be.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/tizen/i],describe(e){const t={name:"Tizen"},n=be.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/qupzilla/i],describe(e){const t={name:"QupZilla"},n=be.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/firefox|iceweasel|fxios/i],describe(e){const t={name:"Firefox"},n=be.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=be.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/MiuiBrowser/i],describe(e){const t={name:"Miui"},n=be.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/chromium/i],describe(e){const t={name:"Chromium"},n=be.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,e)||be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/chrome|crios|crmo/i],describe(e){const t={name:"Chrome"},n=be.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=be.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=be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/playstation 4/i],describe(e){const t={name:"PlayStation 4"},n=be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/safari|applewebkit/i],describe(e){const t={name:"Safari"},n=be.getFirstMatch(bt,e);return n&&(t.version=n),t}},{test:[/.*/i],describe(e){const t=/^(.*)\/(.*) /,n=/^(.*)\/(.*)[ \t]\((.*)/,i=e.search("\\(")!==-1?n:t;return{name:be.getFirstMatch(i,e),version:be.getSecondMatch(i,e)}}}],J4e=[{test:[/Roku\/DVP/],describe(e){const t=be.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,e);return{name:tr.Roku,version:t}}},{test:[/windows phone/i],describe(e){const t=be.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,e);return{name:tr.WindowsPhone,version:t}}},{test:[/windows /i],describe(e){const t=be.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,e),n=be.getWindowsVersionName(t);return{name:tr.Windows,version:t,versionName:n}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe(e){const t={name:tr.iOS},n=be.getSecondMatch(/(Version\/)(\d[\d.]+)/,e);return n&&(t.version=n),t}},{test:[/macintosh/i],describe(e){const t=be.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,e).replace(/[_\s]/g,"."),n=be.getMacOSVersionName(t),r={name:tr.MacOS,version:t};return n&&(r.versionName=n),r}},{test:[/(ipod|iphone|ipad)/i],describe(e){const t=be.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,e).replace(/[_\s]/g,".");return{name:tr.iOS,version:t}}},{test(e){const t=!e.test(/like android/i),n=e.test(/android/i);return t&&n},describe(e){const t=be.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,e),n=be.getAndroidVersionName(t),r={name:tr.Android,version:t};return n&&(r.versionName=n),r}},{test:[/(web|hpw)[o0]s/i],describe(e){const t=be.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,e),n={name:tr.WebOS};return t&&t.length&&(n.version=t),n}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe(e){const t=be.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,e)||be.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,e)||be.getFirstMatch(/\bbb(\d+)/i,e);return{name:tr.BlackBerry,version:t}}},{test:[/bada/i],describe(e){const t=be.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,e);return{name:tr.Bada,version:t}}},{test:[/tizen/i],describe(e){const t=be.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,e);return{name:tr.Tizen,version:t}}},{test:[/linux/i],describe(){return{name:tr.Linux}}},{test:[/CrOS/],describe(){return{name:tr.ChromeOS}}},{test:[/PlayStation 4/],describe(e){const t=be.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,e);return{name:tr.PlayStation4,version:t}}}],e$e=[{test:[/googlebot/i],describe(){return{type:"bot",vendor:"Google"}}},{test:[/huawei/i],describe(e){const t=be.getFirstMatch(/(can-l01)/i,e)&&"Nova",n={type:Jt.mobile,vendor:"Huawei"};return t&&(n.model=t),n}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe(){return{type:Jt.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe(){return{type:Jt.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe(){return{type:Jt.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe(){return{type:Jt.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe(){return{type:Jt.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe(){return{type:Jt.tablet}}},{test(e){const t=e.test(/ipod|iphone/i),n=e.test(/like (ipod|iphone)/i);return t&&!n},describe(e){const t=be.getFirstMatch(/(ipod|iphone)/i,e);return{type:Jt.mobile,vendor:"Apple",model:t}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe(){return{type:Jt.mobile,vendor:"Nexus"}}},{test:[/[^-]mobi/i],describe(){return{type:Jt.mobile}}},{test(e){return e.getBrowserName(!0)==="blackberry"},describe(){return{type:Jt.mobile,vendor:"BlackBerry"}}},{test(e){return e.getBrowserName(!0)==="bada"},describe(){return{type:Jt.mobile}}},{test(e){return e.getBrowserName()==="windows phone"},describe(){return{type:Jt.mobile,vendor:"Microsoft"}}},{test(e){const t=Number(String(e.getOSVersion()).split(".")[0]);return e.getOSName(!0)==="android"&&t>=3},describe(){return{type:Jt.tablet}}},{test(e){return e.getOSName(!0)==="android"},describe(){return{type:Jt.mobile}}},{test(e){return e.getOSName(!0)==="macos"},describe(){return{type:Jt.desktop,vendor:"Apple"}}},{test(e){return e.getOSName(!0)==="windows"},describe(){return{type:Jt.desktop}}},{test(e){return e.getOSName(!0)==="linux"},describe(){return{type:Jt.desktop}}},{test(e){return e.getOSName(!0)==="playstation 4"},describe(){return{type:Jt.tv}}},{test(e){return e.getOSName(!0)==="roku"},describe(){return{type:Jt.tv}}}],t$e=[{test(e){return e.getBrowserName(!0)==="microsoft edge"},describe(e){if(/\sedg\//i.test(e))return{name:Sa.Blink};const n=be.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,e);return{name:Sa.EdgeHTML,version:n}}},{test:[/trident/i],describe(e){const t={name:Sa.Trident},n=be.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test(e){return e.test(/presto/i)},describe(e){const t={name:Sa.Presto},n=be.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:Sa.Gecko},n=be.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}},{test:[/(apple)?webkit\/537\.36/i],describe(){return{name:Sa.Blink}}},{test:[/(apple)?webkit/i],describe(e){const t={name:Sa.WebKit},n=be.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,e);return n&&(t.version=n),t}}];class i${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=be.find(Q4e,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=be.find(J4e,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=be.find(e$e,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=be.find(t$e,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 be.assign({},this.parsedResult)}satisfies(t){const n={};let r=0;const i={};let o=0;if(Object.keys(t).forEach(s=>{const l=t[s];typeof l=="string"?(i[s]=l,o+=1):typeof l=="object"&&(n[s]=l,r+=1)}),r>0){const s=Object.keys(n),l=be.find(s,f=>this.isOS(f));if(l){const f=this.satisfies(n[l]);if(f!==void 0)return f}const u=be.find(s,f=>this.isPlatform(f));if(u){const f=this.satisfies(n[u]);if(f!==void 0)return f}}if(o>0){const s=Object.keys(i),l=be.find(s,u=>this.isBrowser(u,!0));if(l!==void 0)return this.compareVersion(i[l])}}isBrowser(t,n=!1){const r=this.getBrowserName().toLowerCase();let i=t.toLowerCase();const o=be.getBrowserTypeByAlias(i);return n&&o&&(i=o.toLowerCase()),i===r}compareVersion(t){let n=[0],r=t,i=!1;const o=this.getBrowserVersion();if(typeof o=="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(be.compareVersions(o,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 n$e{static getParser(t,n=!1){if(typeof t!="string")throw new Error("UserAgent should be a string");return new i$(t,n)}static parse(t){return new i$(t).getResult()}static get BROWSER_MAP(){return f9}static get ENGINE_MAP(){return Sa}static get OS_MAP(){return tr}static get PLATFORMS_MAP(){return Jt}}var r$e=Object.defineProperty,i$e=(e,t,n)=>t in e?r$e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ja=(e,t,n)=>(i$e(e,typeof t!="symbol"?t+"":t,n),n);const o$e=({listDomains:e,value:t,domainsList:n,onChange:r})=>{const[i,,o,a]=Zt(),{domains:s}=n,l=!t,u=R.useCallback(()=>{r(""),a()},[r,a]),f=R.useCallback(()=>{r(""),o()},[r,o]);return R.useEffect(()=>{e()},[e]),i?m.jsxs(ib,{children:[m.jsx(qn,{value:t??"",placeholder:"Domain",onChange:d=>r(d.target.value)}),m.jsx(Ye,{id:"backToDropdown",outline:!0,type:"button",className:"domains-dropdown__back-btn","aria-label":"Back to domains list",onClick:u,children:m.jsx(je,{icon:AZ})}),m.jsx(Tr,{target:"backToDropdown",placement:"left",trigger:"hover",children:"Existing domains"})]}):m.jsxs(fa,{text:l?"Domain":`Domain: ${t}`,className:l?"domains-dropdown__toggle-btn":"domains-dropdown__toggle-btn--active",children:[s.map(({domain:d,isDefault:h})=>m.jsxs(Ne,{active:(t===d||h)&&l,onClick:()=>r(d),children:[d,h&&m.jsx("span",{className:"float-end text-muted",children:"default"})]},d)),m.jsx(Ne,{divider:!0}),m.jsx(Ne,{onClick:f,children:m.jsx("i",{children:"New domain"})})]})},a$e=e=>(e==null?void 0:e.type)===uC.INVALID_ARGUMENT,s$e=e=>(e==null?void 0:e.type)===uC.INVALID_SHORT_URL_DELETION,l$e=e=>!!e&&typeof e=="object"&&["type","detail","title","status"].every(t=>t in e),Yr=e=>l$e(e)?e:void 0,So=({errorData:e,fallbackMessage:t})=>m.jsxs(m.Fragment,{children:[(e==null?void 0:e.detail)??t,a$e(e)&&m.jsxs("p",{className:"mb-0",children:["Invalid elements: [",e.invalidElements.join(", "),"]"]})]}),Nl=({style:e,className:t,...n})=>m.jsx("button",{type:"button",className:Pe("border-0",t),style:{backgroundColor:"inherit",fontWeight:"inherit",color:"inherit",...e},...n}),d9=R.createContext(""),u$e=d9.Provider,Ss=()=>R.useContext(d9),h9=R.createContext(void 0),{Provider:TT}=h9,r1=()=>R.useContext(h9),c$e=5,jT=()=>{const[e,t]=R.useState([]),n=R.useMemo(()=>e.length>=c$e,[e.length]),r=R.useCallback(s=>!n&&t(l=>[...l,s]),[n]),i=R.useCallback(s=>!n&&e.every(l=>l.name!==s),[e,n]),o=R.useCallback(s=>t(l=>l.filter(u=>u!==s)),[]),a=R.useCallback(()=>t([]),[]);return{itemsToCompare:e,addItemToCompare:r,removeItemToCompare:o,clearItemsToCompare:a,canAddItemWithName:i}},AT=({className:e,type:t})=>{const n=Ss(),r=r1(),i=R.useMemo(()=>r?encodeURIComponent(r.itemsToCompare.map(l=>l.query).join(",")):"",[r]);if(!r||r.itemsToCompare.length===0)return null;const{itemsToCompare:o,clearItemsToCompare:a,removeItemToCompare:s}=r;return m.jsx("div",{className:Pe("top-sticky",e),children:m.jsxs(Ot,{bodyClassName:"d-md-flex gap-3 align-items-center",children:[m.jsx("ul",{className:"d-flex flex-wrap gap-1 flex-grow-1 p-0 m-0",children:o.map((l,u)=>{var f;return m.jsxs("li",{className:Pe("badge pe-1",{"bg-secondary":!((f=l.style)!=null&&f.backgroundColor)}),style:l.style,children:[l.name,m.jsx(Nl,{"aria-label":`Remove ${l.name}`,className:"fw-bold fs-6",onClick:()=>s(l),children:"×"})]},`${l.name}_${u}`)})}),m.jsxs("div",{className:"d-flex mt-3 mt-md-0",children:[m.jsxs(Ye,{outline:!0,color:"primary",className:"flex-grow-1 indivisible",disabled:o.length<2,tag:Pt,to:`${n}/${t}/compare-visits?${t}=${i}`,children:[m.jsx(je,{icon:Z0,fixedWidth:!0,className:"me-1"}),"Compare (",o.length,"/5) »"]}),m.jsx(Ye,{"aria-label":"Close compare",outline:!0,color:"secondary",className:"ms-2 fw-bold",onClick:a,children:"×"})]})]})})},Zd=(e,t,n)=>n==null?e.shortCode===t&&!e.domain:e.shortCode===t&&e.domain===n,f$e=(e,t)=>!e.domain&&t===o1?!0:e.domain===t,d$e=(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}},p9=e=>e.replaceAll("/","__"),kT=e=>e.replaceAll("__","/"),NT=({domain:e,shortCode:t})=>`${e??o1}__${p9(t)}`,m9=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===o1?null:t,shortCode:kT(n)}},h$e="yyyy-MM-dd",v9="yyyy-MM-dd HH:mm",us=()=>new Date,MT=e=>typeof e!="string",RT=(e,t)=>!e||!MT(e)?e:t?by(e,t):Kce(e),cs=e=>RT(e,void 0),Ba=e=>RT(e,h$e),_p=e=>RT(e,v9),Dr=e=>MT(e)?e:as(e),tm=(e,t,n)=>{const r=Dr(e),i=t&&Dr(t),o=n&&Dr(n);if(i&&o)try{return Xce(r,{start:i,end:o})}catch{return!1}return i?gO(r,i)||Zce(r,i):o?gO(r,o)||_y(r,o):!0},Rs=(e,t)=>gO(e,t)||_y(e,t),i1="all",g9={today:"Today",yesterday:"Yesterday",last7Days:"Last 7 days",last30Days:"Last 30 days",last90Days:"Last 90 days",last180Days:"Last 180 days",last365Days:"Last 365 days",[i1]:void 0},y9=Object.keys(g9),p$e=e=>!e||!e.startDate&&!e.endDate,_0=e=>typeof e=="string"&&y9.includes(e),m$e=y9.filter(e=>e!==i1),o$=e=>e?Dr(e):null,b9=(e,t)=>({startDate:o$(e),endDate:o$(t)}),v$e=e=>{if(!(!e||p$e(e)))return e.startDate&&!e.endDate?`Since ${Ba(e.startDate)}`:!e.startDate&&e.endDate?`Until ${Ba(e.endDate)}`:`${Ba(e.startDate)} - ${Ba(e.endDate)}`},_9=e=>{if(!(!e||e===i1))return _0(e)?g9[e]:v$e(e)},li=e=>Cl(xy(us(),e)),fu=e=>({startDate:e,endDate:_c(us())}),x9=e=>{var t;return((t=[[()=>e==="today",()=>fu(Cl(us()))],[()=>e==="yesterday",()=>({startDate:li(1),endDate:_c(xy(us(),1))})],[()=>e==="last7Days",()=>fu(li(7))],[()=>e==="last30Days",()=>fu(li(30))],[()=>e==="last90Days",()=>fu(li(90))],[()=>e==="last180Days",()=>fu(li(180))],[()=>e==="last365Days",()=>fu(li(365))]].find(([n])=>n()))==null?void 0:t[1]())??{}},g$e=e=>{var t;const n=Dr(e);return((t=[[()=>Rs(Cl(us()),n),"today"],[()=>Rs(li(1),n),"yesterday"],[()=>Rs(li(7),n),"last7Days"],[()=>Rs(li(30),n),"last30Days"],[()=>Rs(li(90),n),"last90Days"],[()=>Rs(li(180),n),"last180Days"],[()=>Rs(li(365),n),"last365Days"]].find(([r])=>r()))==null?void 0:t[1])??i1},w9=e=>_0(e)?x9(e):e,O9=e=>!!(e&&e.startDate),y$e=({startDate:e,endDate:t})=>{const n=Vp(_c(t??new Date),Cl(e))+1,r=xy(Cl(e),n),i=xy(_c(e),1);return{startDate:r,endDate:i}},b$e=e=>{if(O9(e))return Vp(e.endDate??new Date,e.startDate)},LT=e=>e.type!==void 0,_$e=e=>e.type!==void 0,x$e=e=>{const t=kue(e,n=>LT(n.visit)?"orphanVisits":"nonOrphanVisits");return{orphanVisits:[],nonOrphanVisits:[],...t}},S9=(e,{shortCode:t,domain:n},{endDate:r,startDate:i}={})=>e.filter(({shortUrl:o,visit:a})=>o&&Zd(o,t,n)&&tm(a.date,i,r)),E9=(e,t,{endDate:n,startDate:r}={})=>e.filter(({shortUrl:i,visit:o})=>i&&f$e(i,t)&&tm(o.date,r,n)),P9=(e,t,{endDate:n,startDate:r}={})=>e.filter(({shortUrl:i,visit:o})=>(i==null?void 0:i.tags.includes(t))&&tm(o.date,r,n)),Ev=(e,t)=>oF(e,n=>n[t]),w$e=e=>{const t=((e==null?void 0:e.startDate)&&cs(e==null?void 0:e.startDate))??void 0,n=((e==null?void 0:e.endDate)&&cs(e==null?void 0:e.endDate))??void 0;return{startDate:t,endDate:n}},QS=({filter:e,dateRange:t})=>{const{startDate:n,endDate:r}=w$e(t),i=(e==null?void 0:e.excludeBots)||void 0;return{startDate:n,endDate:r,excludeBots:i}},O$e=e=>O9(e.dateRange),S$e=({dateRange:e,...t})=>({...t,dateRange:y$e(e)}),gn=(e,t)=>iF(e,t,{serializeError:n=>n}),a$=5e3,E$e=2,P$e=4,C$e=({currentPage:e,pagesCount:t})=>e>=t,T$e=(e,t)=>t*100/e,C9=({visitsLoader:e,shouldCancel:t,progressChanged:n,batchSize:r})=>{const i=async(a,s)=>Promise.all(s.map(async l=>e({...a,page:l,itemsPerPage:a$}).then(({data:u})=>u))).then(l=>l.flat()),o=async(a,s,l=0)=>{if(t())return[];const u=await i(a,s[l]);return n(T$e(s.length,l+1)),l{const{pagination:s,data:l}=await e({...a,page:1,itemsPerPage:a$});if(C$e(s))return l;const u=cC(E$e,s.pagesCount+1),f=Ku(u,r);return s.pagesCount-1>r&&n(0),l.concat(await o(a,f))}},nm=(e,t)=>async n=>e?t({page:1,itemsPerPage:1,excludeBots:n}).then(({data:r})=>r[0]):Promise.resolve(void 0),rm=({typePrefix:e,createLoaders:t,shouldCancel:n})=>{const r=mn(`${e}/progressChanged`),i=mn(`${e}/fallbackToInterval`),o=gn(e,async(a,{getState:s,dispatch:l})=>{var u;const{params:f,options:d}=a,{visitsLoader:h,lastVisitLoader:v}=t(a),g=b$e(f.dateRange),y=QS(f),x=d.loadPrevInterval&&O$e(f)?QS(S$e(f)):void 0,_=P$e/(x?2:1),b=x?{main:0,prev:0}:{main:0},w=(A,D)=>{b[A]=D;const k=Object.values(b),I=k.reduce((F,q)=>F+q,0);l(r(I/k.length))},S=C9({visitsLoader:h,shouldCancel:()=>n(s),progressChanged:A=>w("main",A),batchSize:_}),[E,P,T]=await Promise.all([S(y),v((u=f.filter)==null?void 0:u.excludeBots),x?S(x).then(A=>A.map(D=>{if(g===void 0)return D;const{date:k,...I}=D,F=fC(Dr(k),g);return{...I,date:cs(F)}})):Promise.resolve(void 0)]);return!E.length&&P&&l(i(g$e(P.date))),{...a,visits:E,prevVisits:T}});return Object.assign(o,{progressChanged:r,fallbackToInterval:i})},_f=mn("shlink/visitCreation/createNewVisits",e=>({payload:{createdVisits:e}})),im=({name:e,asyncThunkCreator:t,initialState:n,filterCreatedVisits:r,extraReducers:i})=>{const{pending:o,rejected:a,fulfilled:s,progressChanged:l,fallbackToInterval:u}=t,{reducer:f,actions:d}=nn({name:e,initialState:n,reducers:{cancelGetVisits:v=>({...v,cancelLoad:!0})},extraReducers:v=>{v.addCase(o,()=>({...n,loading:!0})),v.addCase(a,(g,{error:y})=>({...n,errorData:Yr(y)??null})),v.addCase(s,(g,{payload:y})=>({...g,...y,loading:!1,progress:null,errorData:null})),v.addCase(l,(g,{payload:y})=>({...g,progress:y})),v.addCase(u,(g,{payload:y})=>({...g,fallbackInterval:y})),v.addCase(_f,(g,{payload:y})=>{const{visits:x}=g,_=r(g,y.createdVisits).map(({visit:b})=>b);return _.length?{...g,visits:[..._,...x]}:g}),i==null||i(v)}}),{cancelGetVisits:h}=d;return{reducer:f,cancelGetVisits:h}},T9="shlink/domainVisits",o1="DEFAULT",j$e={visits:[],domain:"",loading:!1,cancelLoad:!1,errorData:null,progress:null},A$e=e=>rm({typePrefix:`${T9}/getDomainVisits`,createLoaders:({domain:t,options:n})=>{const r=e(),{doIntervalFallback:i=!1}=n,o=s=>r.getDomainVisits(t,s),a=nm(i,s=>r.getDomainVisits(t,s));return{visitsLoader:o,lastVisitLoader:a}},shouldCancel:t=>t().domainVisits.cancelLoad}),k$e=e=>im({name:T9,initialState:j$e,asyncThunkCreator:e,filterCreatedVisits:({domain:t,params:n},r)=>E9(r,t,n==null?void 0:n.dateRange)}),rg=({className:e="",placement:t,children:n})=>{const r=ca();return m.jsxs(m.Fragment,{children:[m.jsx("span",{className:e,ref:r,children:m.jsx(je,{icon:pP})}),m.jsx(Tr,{target:r,placement:t,children:n})]})},j9=e=>t=>{t.preventDefault(),e()},$T=(e,t,n=1)=>cC(n,e+1).map(t),N$e=e=>Array.isArray(e)&&e.length===0||typeof e=="string"&&e===""||typeof e=="object"&&Object.keys(e).length===0,Ks=e=>e!=null&&!N$e(e),gx=e=>e||null,JS=e=>e?"true":"false",yx=e=>e===void 0?void 0:JS(e),bx=({isLast:e,...t})=>m.jsx(Jv,{...t,required:!1,type:"url",placeholder:"No redirect",className:e?"mb-0":""}),M$e=({isOpen:e,toggle:t,domain:n,editDomainRedirects:r})=>{var i,o,a;const[s,l]=R.useState(((i=n.redirects)==null?void 0:i.baseUrlRedirect)??""),[u,f]=R.useState(((o=n.redirects)==null?void 0:o.regular404Redirect)??""),[d,h]=R.useState(((a=n.redirects)==null?void 0:a.invalidShortUrlRedirect)??""),v=j9(async()=>r({domain:n.domain,redirects:{baseUrlRedirect:gx(s),regular404Redirect:gx(u),invalidShortUrlRedirect:gx(d)}}).then(t));return m.jsx(Po,{isOpen:e,toggle:t,centered:!0,children:m.jsxs("form",{name:"domainRedirectsModal",onSubmit:v,children:[m.jsxs(Co,{toggle:t,children:["Edit redirects for ",m.jsx("b",{children:n.domain})]}),m.jsxs(Wi,{children:[m.jsxs(bx,{value:s,onChange:l,children:[m.jsxs(rg,{className:"me-2",placement:"bottom",children:["Visitors accessing the base url, as in ",m.jsxs("b",{children:["https://",n.domain,"/"]}),", will be redirected to this URL."]}),"Base URL"]}),m.jsxs(bx,{value:u,onChange:f,children:[m.jsxs(rg,{className:"me-2",placement:"bottom",children:["Visitors accessing a url not matching a short URL pattern, as in ",m.jsxs("b",{children:["https://",n.domain,"/???/[...]"]}),", will be redirected to this URL."]}),"Regular 404"]}),m.jsxs(bx,{value:d,isLast:!0,onChange:h,children:[m.jsx(rg,{className:"me-2",placement:"bottom",children:"Visitors accessing a url matching a short URL pattern, but not matching an existing short code, will be redirected to this URL."}),"Invalid short URL"]})]}),m.jsxs(gs,{children:[m.jsx(Ye,{color:"link",type:"button",onClick:t,children:"Cancel"}),m.jsx(Ye,{color:"primary",children:"Save"})]})]})})},R$e=({domain:e,editDomainRedirects:t})=>{const[n,r]=Zt(),i=Ss(),o=r1();return m.jsxs(ab,{children:[m.jsxs(Ne,{tag:Pt,to:`${i}/domain/${e.domain}${e.isDefault?`_${o1}`:""}/visits`,children:[m.jsx(je,{icon:hP,fixedWidth:!0})," Visit stats"]}),m.jsxs(Ne,{disabled:!o||!o.canAddItemWithName(e.domain),onClick:()=>o==null?void 0:o.addItemToCompare({name:e.domain,query:e.domain}),children:[m.jsx(je,{icon:Z0,fixedWidth:!0})," Compare visits"]}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsxs(Ne,{onClick:r,children:[m.jsx(je,{fixedWidth:!0,icon:dP})," Edit redirects"]}),m.jsx(M$e,{domain:e,isOpen:n,toggle:r,editDomainRedirects:t})]})},L$e=(e,t)=>{const n=r=>i=>{i.event.composedPath().some(({classList:o})=>o==null?void 0:o.contains("visits-table"))||document.querySelector(".modal")||r()};return Ofe({delta:40,onSwipedLeft:n(t),onSwipedRight:n(e)})},$$e=(e,t)=>{const[n,r]=R.useState(t),i=R.useCallback(o=>{const{location:a,history:s}=window,l=JP(a.search);l[e]=o,s.pushState(null,"",`${a.pathname}?${ob(l)}`),r(o)},[e]);return[n,i]},IT=e=>{const t=Bp();return R.useMemo(()=>{var n;return((n=t[e])==null?void 0:n.split(",").filter(Boolean))??[]},[e,t])},I$e=()=>{const e=Eo();return R.useCallback(()=>e(-1),[e])},DT=(e,t)=>{const n=R.useCallback(()=>t(`(max-width: ${e}px)`).matches,[t,e]),[r,i]=R.useState(n());return R.useEffect(()=>{const o=()=>i(n());return window.addEventListener("resize",o),()=>window.removeEventListener("resize",o)},[n]),r},D$e=({status:e,matchMedia:t=window.matchMedia})=>{const n=ca(),r=DT(991,t);return e==="validating"?m.jsx(je,{fixedWidth:!0,icon:DD,spin:!0}):m.jsxs(m.Fragment,{children:[m.jsx("span",{ref:n,children:e==="valid"?m.jsx(je,{fixedWidth:!0,icon:gh,className:"text-muted"}):m.jsx(je,{fixedWidth:!0,icon:Pw,className:"text-danger"})}),m.jsx(Tr,{target:n,placement:r?"right":"left",autohide:e==="valid",children:e==="valid"?"Congratulations! This domain is properly configured.":m.jsxs("span",{children:["Oops! There is some missing configuration, and short URLs shared with this domain will not work.",m.jsx("br",{}),"Check the ",m.jsx(Er,{href:"https://slnk.to/multi-domain-docs",children:"documentation"})," in order to find out what is missing."]})})]})},_x=({fallback:e})=>m.jsxs("span",{className:"text-muted",children:[!e&&m.jsx("small",{children:"No redirect"}),e&&m.jsxs(m.Fragment,{children:[e," ",m.jsx("small",{children:"(as fallback)"})]})]}),F$e=()=>m.jsxs(m.Fragment,{children:[m.jsx(je,{fixedWidth:!0,icon:fZ,className:"text-primary",id:"defaultDomainIcon"}),m.jsx(Tr,{target:"defaultDomainIcon",placement:"right",children:"Default domain"})]}),B$e=({domain:e,editDomainRedirects:t,checkDomainHealth:n,defaultRedirects:r})=>{const{domain:i,isDefault:o,redirects:a,status:s}=e;return R.useEffect(()=>{n(e.domain)},[n,e.domain]),m.jsxs("tr",{className:"responsive-table__row",children:[m.jsx("td",{className:"responsive-table__cell","data-th":"Is default domain",children:o&&m.jsx(F$e,{})}),m.jsx("th",{className:"responsive-table__cell","data-th":"Domain",children:i}),m.jsx("td",{className:"responsive-table__cell","data-th":"Base path redirect",children:(a==null?void 0:a.baseUrlRedirect)??m.jsx(_x,{fallback:r==null?void 0:r.baseUrlRedirect})}),m.jsx("td",{className:"responsive-table__cell","data-th":"Regular 404 redirect",children:(a==null?void 0:a.regular404Redirect)??m.jsx(_x,{fallback:r==null?void 0:r.regular404Redirect})}),m.jsx("td",{className:"responsive-table__cell","data-th":"Invalid short URL redirect",children:(a==null?void 0:a.invalidShortUrlRedirect)??m.jsx(_x,{fallback:r==null?void 0:r.invalidShortUrlRedirect})}),m.jsx("td",{className:"responsive-table__cell text-lg-center","data-th":"Status",children:m.jsx(D$e,{status:s})}),m.jsx("td",{className:"responsive-table__cell text-end",children:m.jsx(R$e,{domain:e,editDomainRedirects:t})})]})},s$=[{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}],U$e=({listDomains:e,domainsList:t,filterDomains:n,editDomainRedirects:r,checkDomainHealth:i})=>{var o;const{filteredDomains:a,defaultRedirects:s,loading:l,error:u,errorData:f}=t,d=s??((o=a.find(({isDefault:v})=>v))==null?void 0:o.redirects),h=jT();return R.useEffect(()=>{e()},[e]),l?m.jsx(ta,{loading:!0}):m.jsxs(TT,{value:h,children:[m.jsx(Up,{className:"mb-3",onChange:n}),m.jsx(AT,{type:"domains",className:"mb-3"}),u?m.jsx(ur,{type:"error",children:m.jsx(So,{errorData:f,fallbackMessage:"Error loading domains :("})}):m.jsx(Ot,{children:m.jsxs("table",{className:"table table-hover responsive-table mb-0",children:[m.jsx("thead",{className:"responsive-table__header",children:m.jsx("tr",{children:s$.map((v,g)=>m.jsx("th",{children:m.jsx("span",{className:v.isHidden?"sr-only":void 0,children:v.value})},g))})}),m.jsxs("tbody",{children:[a.length<1&&m.jsx("tr",{children:m.jsx("td",{colSpan:s$.length,className:"text-center",children:"No results found"})}),a.map(v=>m.jsx(B$e,{domain:v,editDomainRedirects:r,checkDomainHealth:i,defaultRedirects:d},v.domain))]})]})})]})},z$e="shlink/domainRedirects/EDIT_DOMAIN_REDIRECTS",V$e=e=>gn(z$e,async({domain:t,redirects:n})=>{const r=await e().editDomainRedirects({domain:t,...n});return{domain:t,redirects:r}}),Pv="shlink/domainsList",Cv={domains:[],filteredDomains:[],loading:!1,error:!1},l$=({domain:e,redirects:t})=>n=>n.domain!==e?n:{...n,redirects:t},u$=(e,t)=>n=>n.domain!==e?n:{...n,status:t},W$e=(e,t)=>{const n=gn(`${Pv}/listDomains`,async()=>{const{data:a,defaultRedirects:s}=await e().listDomains();return{domains:a.map(l=>({...l,status:"validating"})),defaultRedirects:s}}),r=gn(`${Pv}/checkDomainHealth`,async a=>{try{const{status:s}=await e().health(a);return{domain:a,status:s==="pass"?"valid":"invalid"}}catch{return{domain:a,status:"invalid"}}}),i=mn(`${Pv}/filterDomains`),{reducer:o}=nn({name:Pv,initialState:Cv,reducers:{},extraReducers:a=>{a.addCase(n.pending,()=>({...Cv,loading:!0})),a.addCase(n.rejected,(s,{error:l})=>({...Cv,error:!0,errorData:Yr(l)})),a.addCase(n.fulfilled,(s,{payload:l})=>({...Cv,...l,filteredDomains:l.domains})),a.addCase(r.fulfilled,({domains:s,filteredDomains:l,...u},{payload:f})=>({...u,domains:s.map(u$(f.domain,f.status)),filteredDomains:l.map(u$(f.domain,f.status))})),a.addCase(i,(s,{payload:l})=>({...s,filteredDomains:s.domains.filter(({domain:u})=>u.toLowerCase().match(l.toLowerCase()))})),a.addCase(t.fulfilled,(s,{payload:l})=>({...s,domains:s.domains.map(l$(l)),filteredDomains:s.filteredDomains.map(l$(l))}))}});return{reducer:o,listDomains:n,checkDomainHealth:r,filterDomains:i}},H$e=(e,t)=>{e.serviceFactory("DomainSelector",()=>o$e),e.decorator("DomainSelector",t(["domainsList"],["listDomains"])),e.serviceFactory("ManageDomains",()=>U$e),e.decorator("ManageDomains",t(["domainsList"],["listDomains","filterDomains","editDomainRedirects","checkDomainHealth"])),e.serviceFactory("domainsListReducerCreator",W$e,"apiClientFactory","editDomainRedirects"),e.serviceFactory("domainsListReducer",n=>n.reducer,"domainsListReducerCreator"),e.serviceFactory("listDomains",n=>n.listDomains,"domainsListReducerCreator"),e.serviceFactory("filterDomains",n=>n.filterDomains,"domainsListReducerCreator"),e.serviceFactory("editDomainRedirects",V$e,"apiClientFactory"),e.serviceFactory("checkDomainHealth",n=>n.checkDomainHealth,"domainsListReducerCreator")},c$="shlink/mercure",G$e={loading:!0,error:!1},q$e=e=>{const t=gn(`${c$}/loadMercureInfo`,r=>{if(r&&r.realTimeUpdates&&!r.realTimeUpdates.enabled)throw new Error("Real time updates not enabled");return e().mercureInfo()}),{reducer:n}=nn({name:c$,initialState:G$e,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:o})=>({...o,loading:!1,error:!1}))}});return{loadMercureInfo:t,reducer:n}},K$e=e=>{e.serviceFactory("mercureInfoReducerCreator",q$e,"apiClientFactory"),e.serviceFactory("mercureInfoReducer",t=>t.reducer,"mercureInfoReducerCreator"),e.serviceFactory("loadMercureInfo",t=>t.loadMercureInfo,"mercureInfoReducerCreator")};function It(e){return R.useRef(e).current}function Dt(e,t){return(n,r=globalThis.console)=>(t.forEach(i=>{const o=n[i];e[i]=o}),e)}const Y$e=(e,t,n,r)=>{const{mercureHubUrl:i,token:o,loading:a,error:s}=e;if(a||s||!i)return;const l=({data:d})=>n(JSON.parse(d)),u=({status:d})=>d===401&&r(),f=t.map(d=>{const h=new URL(i);h.searchParams.append("topic",d);const v=new Sfe.EventSourcePolyfill(h,{headers:{Authorization:`Bearer ${o}`}});return v.onmessage=l,v.onerror=u,v});return()=>f.forEach(d=>d.close())};function Ki(e,t){const n=new Set;return r=>{const{createNewVisits:i,loadMercureInfo:o,mercureInfo:a}=r,s=qc();return R.useEffect(()=>{const{interval:l}=a,u=v=>l?n.add(v):i([v]),f=t(s),d=Y$e(a,f,u,o);if(!l)return d;const h=setInterval(()=>{i([...n]),n.clear()},l*1e3*60);return()=>{clearInterval(h),d==null||d()}},[i,o,a,s]),m.jsx(e,{...r})}}class fr{}Ja(fr,"visits","https://shlink.io/new-visit"),Ja(fr,"orphanVisits","https://shlink.io/new-orphan-visit"),Ja(fr,"shortUrlVisits",e=>`https://shlink.io/new-visit/${e}`);const FT="shlink/shortUrlDeletion",f$={shortCode:"",loading:!1,deleted:!1,error:!1},Z$e=e=>gn(`${FT}/deleteShortUrl`,async({shortCode:t,domain:n})=>(await e().deleteShortUrl(t,n),{shortCode:t,domain:n})),A9=mn(`${FT}/shortUrlDeleted`),X$e=e=>{const{actions:t,reducer:n}=nn({name:FT,initialState:f$,reducers:{resetDeleteShortUrl:()=>f$},extraReducers:i=>{i.addCase(e.pending,o=>({...o,loading:!0,error:!1,deleted:!1})),i.addCase(e.rejected,(o,{error:a})=>({...o,errorData:Yr(a),loading:!1,error:!0,deleted:!1})),i.addCase(e.fulfilled,(o,{payload:a})=>({...o,shortCode:a.shortCode,loading:!1,error:!1,deleted:!0}))}}),{resetDeleteShortUrl:r}=t;return{reducer:n,resetDeleteShortUrl:r}},k9="shlink/shortUrlsList",N9=5,Q$e={loading:!0,error:!1},J$e=e=>gn(`${k9}/listShortUrls`,t=>e().listShortUrls(t??{})),eIe=(e,t,n)=>nn({name:k9,initialState:Q$e,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:o})=>({loading:!1,error:!1,shortUrls:o})),r.addCase(n.fulfilled,(i,{payload:o})=>{i.shortUrls&&(i.shortUrls.data=[o,...i.shortUrls.data.slice(0,N9-1)],i.shortUrls.pagination.totalItems+=1)}),r.addCase(t.fulfilled,(i,{payload:o})=>{i.shortUrls&&(i.shortUrls.data=i.shortUrls.data.map(a=>{const{shortCode:s,domain:l}=o;return Zd(a,s,l)?o:a}))}),r.addCase(A9,(i,{payload:o})=>{i.shortUrls&&(i.shortUrls.data=i.shortUrls.data.filter(a=>!Zd(a,o.shortCode,o.domain)),i.shortUrls.pagination.totalItems-=1)}),r.addCase(_f,(i,{payload:o})=>{i.shortUrls&&(i.shortUrls.data=i.shortUrls.data.map(a=>{var s;return((s=o.createdVisits.findLast(({shortUrl:l})=>l&&Zd(a,l.shortCode,l.domain)))==null?void 0:s.shortUrl)??a}))})}}),d$=10,{ceil:tIe}=Math,nIe=new Intl.NumberFormat("en-US"),Yt=e=>nIe.format(Number(e)),rIe=e=>tIe(e/d$)*d$,eE=({children:e,title:t,link:n,tooltip:r})=>{const i=ca();return m.jsxs(m.Fragment,{children:[m.jsxs(Pr,{innerRef:i,className:"highlight-card",body:!0,tag:Pt,to:n,children:[m.jsx(je,{size:"3x",className:"highlight-card__link-icon",icon:Dfe}),m.jsx(n8,{className:"lh-sm fw-semibold text-uppercase fs-5 highlight-card__title",children:t}),m.jsx(t8,{className:"fs-2 fw-semibold lh-sm",children:e})]}),r&&m.jsx(Tr,{target:i,placement:"bottom",children:r})]})},h$=({loading:e,excludeBots:t,visitsSummary:n,...r})=>m.jsx(eE,{tooltip:n.bots!==void 0?m.jsxs(m.Fragment,{children:[t?"Plus":"Including"," ",m.jsx("strong",{children:Yt(n.bots)})," potential bot visits"]}):void 0,...r,children:e?"Loading...":Yt(t&&n.nonBots?n.nonBots:n.total)}),M9=Ki(({shortUrlsList:e,listShortUrls:t,tagsList:n,loadVisitsOverview:r,visitsOverview:i})=>{const{ShortUrlsTable:o,CreateShortUrl:a}=It(M9),{loading:s,shortUrls:l}=e,{loading:u}=n,{loading:f,nonOrphanVisits:d,orphanVisits:h}=i,v=Ss(),g=Eo(),y=jr("visits");return R.useEffect(()=>{t({itemsPerPage:N9,orderBy:{field:"dateCreated",dir:"DESC"}}),r()},[t,r]),m.jsxs(m.Fragment,{children:[m.jsxs(rr,{children:[m.jsx("div",{className:"col-lg-6 col-xl-3 mb-3",children:m.jsx(h$,{title:"Visits",link:`${v}/non-orphan-visits`,excludeBots:(y==null?void 0:y.excludeBots)??!1,loading:f,visitsSummary:d})}),m.jsx("div",{className:"col-lg-6 col-xl-3 mb-3",children:m.jsx(h$,{title:"Orphan visits",link:`${v}/orphan-visits`,excludeBots:(y==null?void 0:y.excludeBots)??!1,loading:f,visitsSummary:h})}),m.jsx("div",{className:"col-lg-6 col-xl-3 mb-3",children:m.jsx(eE,{title:"Short URLs",link:`${v}/list-short-urls/1`,children:s?"Loading...":Yt((l==null?void 0:l.pagination.totalItems)??0)})}),m.jsx("div",{className:"col-lg-6 col-xl-3 mb-3",children:m.jsx(eE,{title:"Tags",link:`${v}/manage-tags`,children:u?"Loading...":Yt(n.tags.length)})})]}),m.jsxs(Pr,{className:"mb-3",children:[m.jsxs(mc,{children:[m.jsx("span",{className:"d-sm-none",children:"Create a short URL"}),m.jsx("h5",{className:"d-none d-sm-inline",children:"Create a short URL"}),m.jsx(Pt,{className:"float-end",to:`${v}/create-short-url`,children:"Advanced options »"})]}),m.jsx(pc,{children:m.jsx(a,{basicMode:!0})})]}),m.jsxs(Pr,{children:[m.jsxs(mc,{children:[m.jsx("span",{className:"d-sm-none",children:"Recently created URLs"}),m.jsx("h5",{className:"d-none d-sm-inline",children:"Recently created URLs"}),m.jsx(Pt,{className:"float-end",to:`${v}/list-short-urls/1`,children:"See all »"})]}),m.jsx(pc,{children:m.jsx(o,{shortUrlsList:e,className:"mb-0",onTagClick:x=>g(`${v}/list-short-urls/1?tags=${encodeURIComponent(x)}`)})})]})]})},()=>[fr.visits,fr.orphanVisits]),iIe=Dt(M9,["ShortUrlsTable","CreateShortUrl"]);function oIe(e,t){e.factory("Overview",iIe),e.decorator("Overview",t(["shortUrlsList","tagsList","mercureInfo","visitsOverview"],["listShortUrls","createNewVisits","loadMercureInfo","loadVisitsOverview"]))}const R9="shlink/setShortUrlRedirectRules",p$={saving:!1,saved:!1,error:!1},aIe=e=>gn(`${R9}/setShortUrlRedirectRules`,({shortUrl:t,data:n})=>{const{shortCode:r,domain:i}=t;return e().setShortUrlRedirectRules(r,i,n)}),sIe=e=>{const{reducer:t,actions:n}=nn({name:R9,initialState:p$,reducers:{resetSetRules:()=>p$},extraReducers:i=>{i.addCase(e.pending,()=>({saving:!0,saved:!1,error:!1})),i.addCase(e.rejected,(o,{error:a})=>({saving:!1,saved:!1,error:!0,errorData:Yr(a)})),i.addCase(e.fulfilled,()=>({saving:!1,error:!1,saved:!0}))}}),{resetSetRules:r}=n;return{reducer:t,resetSetRules:r}},L9="shlink/getShortUrlRedirectRules",lIe={loading:!0,error:!1},uIe=e=>gn(`${L9}/getShortUrlRedirectRules`,({shortCode:t,domain:n})=>e().getShortUrlRedirectRules(t,n)),cIe=e=>nn({name:L9,initialState:lIe,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 fIe(e,t){var n=!1;return function(...r){n||(e.call(null,...r),n=!0,setTimeout(function(){n=!1},t))}}function $9(e){return e.split(" ").filter(t=>t)}var I9=typeof window<"u";function Ml(e,t,n=!1){if(!t)return;const r=$9(t);if(r.length&&!r.includes("longTouch"))for(const i of e){if(!om(i)||!bo.has(i)){i.classList.add(...r);continue}const o=[],a=bo.get(i);if(a){for(const s of r)i.classList.contains(s)?i.classList.contains(s)&&n===!1&&o.push(s):i.classList.add(s);a.privateClasses=o,bo.set(i,a)}}}function x0(e,t){if(!t)return;const n=$9(t);if(n.length)for(const r of e){if(!om(r)){r.classList.remove(...n);continue}const i=bo.get(r);if(i)for(const o of n)i.privateClasses.includes(o)||r.classList.remove(o)}}function D9(e){let t=e.parentNode;for(;t!==null&&t.nodeType===1&&t instanceof HTMLElement;){const n=window.getComputedStyle(t).getPropertyValue("overflow");if(n==="scroll"||n==="auto")return t;t=t.parentNode}return document.documentElement}function dIe(e){if(!(e.e instanceof TouchEvent))return;const t=e.e.touches[0].clientX,n=e.e.touches[0].clientY;let r=document.elementFromPoint(t,n);if(!om(r))return;let i,o=!0;for(;r&&o;){if(bo.has(r)||$i.has(r)){o=!1,i=$i.has(r);break}r=r.parentNode}if(i){const a=$i.get(r);return a?{parent:{el:r,data:a}}:void 0}else{const a=bo.get(r);if(!a)return;const s=$i.get(r.parentNode);return s?{node:{el:r,data:a},parent:{el:r.parentNode,data:s}}:void 0}}function om(e){return e instanceof HTMLElement&&e.parentNode instanceof HTMLElement}function F9(e,t){const n=new AbortController;for(const r in t){const i=t[r];e.addEventListener(r,i,{signal:n.signal,passive:!1})}return n}function B9(e,t,n=!1){const r=window.getComputedStyle(e),i=["position","z-index","top","left","x","pointer-events","y","transform-origin","filter","-webkit-text-fill-color"];for(const o of Array.from(r))n===!1&&o&&i.includes(o)||t.style.setProperty(o,r.getPropertyValue(o),r.getPropertyPriority(o));for(const o of Array.from(e.children)){if(!om(o))continue;const a=t.children[Array.from(e.children).indexOf(o)];B9(o,a,n)}}function Ul(e){return e instanceof DragEvent?{x:e.clientX,y:e.clientY}:{x:e.touches[0].clientX,y:e.touches[0].clientY}}Array();var m$={up:[0,-1],down:[0,1],left:[-1,0],right:[1,0]},bo=new WeakMap,$i=new WeakMap,qe=void 0;function hIe(){qe=void 0}function U9(e){return qe={ascendingDirection:!1,incomingDirection:void 0,enterCount:0,targetIndex:0,affectedNodes:[],lastValue:void 0,activeNode:void 0,lastTargetValue:void 0,remapJustFinished:!1,preventEnter:!1,clonedDraggedEls:[],swappedNodeValue:!1,originalZIndex:void 0,...e},qe}function pIe(e,t){return qe={...e,...t},qe}function z9(e){const{x:t,y:n}=Ul(e.e);return{coordinates:{x:t,y:n},draggedNode:{el:e.targetData.node.el,data:e.targetData.node.data},draggedNodes:[{el:e.targetData.node.el,data:e.targetData.node.data}],initialIndex:e.targetData.node.data.index,initialParent:{el:e.targetData.parent.el,data:e.targetData.parent.data},lastParent:{el:e.targetData.parent.el,data:e.targetData.parent.data},scrollParent:D9(e.targetData.node.el)}}function mIe(e,t){const n=V9(e),r=[...tE(t.targetData.parent.el,t.targetData.parent.data).filter(i=>!n.includes(i))];r.splice(t.targetData.node.data.index,0,...n),e.lastTargetValue=t.targetData.node.data.value,nE(t.targetData.parent.el,t.targetData.parent.data,[...r])}function tE(e,t){return[...t.getValues(e)]}function nE(e,t,n){t.setValues(n,e)}function V9(e){return[...e.draggedNodes.map(t=>t.data.value)]}function vIe({parent:e,getValues:t,setValues:n,config:r={}}){var i,o;if(!I9)return;document.addEventListener("dragover",s=>{if(s.preventDefault(),qe){qe.remapJustFinished=!1,qe.lastTargetValue=void 0;const{x:l,y:u}=Ul(s);qe.coordinates.y=u,qe.coordinates.x=l,a1()}}),W9(e);const a={getValues:t,setValues:n,config:{handleDragstart:_Ie,handleDragoverNode:GIe,handleDragoverParent:qIe,handleEnd:AIe,handleTouchstart:NIe,handleTouchmove:$Ie,handleTouchOverNode:EIe,handleTouchOverParent:KIe,performSort:mIe,performTransfer:QIe,root:document,setupNode:PIe,setupNodeRemap:q9,reapplyDragClasses:CIe,tearDownNode:jIe,tearDownNodeRemap:TIe,remapFinished:bIe,scrollBehavior:{x:.8,y:.8},threshold:{horizontal:0,vertical:0},...r},enabledNodes:[],abortControllers:{}};gIe(e,a),(i=r.plugins)==null||i.forEach(s=>{var l,u;(u=(l=s(e))==null?void 0:l.tearDown)==null||u.call(l)}),(o=r.plugins)==null||o.forEach(s=>{var l,u;(u=(l=s(e))==null?void 0:l.setup)==null||u.call(l)}),H9(e,!0)}function W9(e){const t=$i.get(e);t&&t.abortControllers.mainParent&&t.abortControllers.mainParent.abort()}function gIe(e,t){new MutationObserver(yIe).observe(e,{childList:!0}),$i.set(e,t),t.abortControllers.mainParent=F9(e,{dragover:JIe(fIe(t.config.handleDragoverParent,10)),touchOverParent:t.config.handleTouchOverParent})}function yIe(e){const t=e[0].target;t instanceof HTMLElement&&H9(t)}function H9(e,t){const n=$i.get(e);if(!n)return;const r=[],i=n.config;for(let s=0;sh.data.value).includes(f.value)){const h=qe.draggedNodes.find(v=>v.data.value===f.value);h&&(h.el=l)}a.push({el:l,data:f});const d={node:l,parent:e,parentData:n,nodeData:f};(t||!u)&&i.setupNode(d),q9(d)}$i.set(e,{...n,enabledNodes:a}),i.remapFinished(n)}function bIe(){qe&&(qe.preventEnter=!1,qe.swappedNodeValue=void 0,qe.remapJustFinished=!0)}function _Ie(e){e.e instanceof DragEvent&&SIe({e:e.e,targetData:e.targetData})}function xIe(e,t,n){Ml([e],t),setTimeout(()=>{x0([e],t),Ml([e],n)})}function wIe(e){const t=U9(z9(e));return e.e.stopPropagation(),e.e.dataTransfer&&(e.e.dataTransfer.dropEffect="move",e.e.dataTransfer.effectAllowed="move",e.e.dataTransfer.setDragImage(e.targetData.node.el,e.e.offsetX,e.e.offsetY)),t}function G9(e){if(!(e.e instanceof DragEvent)&&!(e.e instanceof TouchEvent))return!1;const t=e.targetData.parent.data.config;if(!t.dragHandle)return!0;const n=e.targetData.node.el.querySelectorAll(t.dragHandle);if(!n)return!1;const r=Ul(e.e),i=t.root.elementFromPoint(r.x,r.y);if(!i)return!1;for(const o of Array.from(n))if(i===o||o.contains(i))return!0;return!1}function OIe(e){if(!G9(e))return;const t=MIe(e);RIe(e,t),LIe(e,t)}function SIe(e){if(!G9(e)){e.e.preventDefault();return}const t=e.targetData.parent.data.config,n=wIe(e),r=e.targetData.node.el.style.zIndex;n.originalZIndex=r,e.targetData.node.el.style.zIndex="9999",xIe(n.draggedNode.el,t.draggingClass,t.dropZoneClass)}function EIe(e){qe&&(e.detail.targetData.parent.el===qe.lastParent.el?Z9(e.detail,qe):s1(e.detail,qe))}function PIe(e){var t;const n=e.parentData.config;e.node.draggable=!0,e.nodeData.abortControllers.mainNode=F9(e.node,{dragstart:du(n.handleDragstart),dragover:du(n.handleDragoverNode),dragend:du(n.handleEnd),touchstart:du(n.handleTouchstart),touchmove:du(n.handleTouchmove),touchend:du(n.handleEnd),touchOverNode:n.handleTouchOverNode}),n.reapplyDragClasses(e.node,e.parentData),(t=e.parentData.config.plugins)==null||t.forEach(r=>{var i,o;(o=(i=r(e.parent))==null?void 0:i.setupNode)==null||o.call(i,e)})}function q9(e){var t;bo.set(e.node,e.nodeData),(t=e.parentData.config.plugins)==null||t.forEach(n=>{var r,i;(i=(r=n(e.parent))==null?void 0:r.setupNodeRemap)==null||i.call(r,e)})}function CIe(e,t){if(!qe)return;const n="touchedNode"in qe?t.config.touchDropZoneClass:t.config.dropZoneClass;qe.draggedNode.el===e&&Ml([e],n,!0)}function TIe(e){var t;(t=e.parentData.config.plugins)==null||t.forEach(n=>{var r,i;(i=(r=n(e.parent))==null?void 0:r.tearDownNodeRemap)==null||i.call(r,e)})}function jIe(e){var t,n,r,i,o;(t=e.parentData.config.plugins)==null||t.forEach(a=>{var s,l;(l=(s=a(e.parent))==null?void 0:s.tearDownNode)==null||l.call(s,e)}),e.node.draggable=!1,(r=(n=e.nodeData)==null?void 0:n.abortControllers)!=null&&r.mainNode&&((o=(i=e.nodeData)==null?void 0:i.abortControllers)==null||o.mainNode.abort())}function AIe(e){qe&&(kIe(e,qe),hIe())}function kIe(e,t){var n,r,i,o;document.removeEventListener("contextmenu",K9),"longTouchTimeout"in t&&t.longTouchTimeout&&clearTimeout(t.longTouchTimeout);const a=(n=$i.get(t.initialParent.el))==null?void 0:n.config,s="touchedNode"in t?a==null?void 0:a.touchDropZoneClass:a==null?void 0:a.dropZoneClass;t.originalZIndex!==void 0&&(t.draggedNode.el.style.zIndex=t.originalZIndex),Ml(t.draggedNodes.map(l=>l.el),s,!0),x0(t.draggedNodes.map(l=>l.el),s),a!=null&&a.longTouchClass&&x0(t.draggedNodes.map(l=>l.el),(i=(r=t.initialParent.data)==null?void 0:r.config)==null?void 0:i.longTouchClass),"touchedNode"in t&&((o=t.touchedNode)==null||o.remove())}function NIe(e){e.e instanceof TouchEvent&&OIe({e:e.e,targetData:e.targetData})}function MIe(e){e.e.stopPropagation();const t=e.targetData.node.el.cloneNode(!0),n=e.targetData.node.el.getBoundingClientRect();return pIe(U9(z9(e)),{coordinates:{x:e.e.touches[0].clientX,y:e.e.touches[0].clientY},scrollParent:D9(e.targetData.node.el),touchStartLeft:e.e.touches[0].clientX-n.left,touchStartTop:e.e.touches[0].clientY-n.top,touchedNode:t,touchMoving:!1})}function K9(e){e.preventDefault()}function RIe(e,t){t.touchedNodeDisplay=t.touchedNode.style.display;const n=e.targetData.node.el.getBoundingClientRect();t.touchedNode.style.cssText=` width: ${n.width}px; position: fixed; pointer-events: none; top: -9999px; z-index: 999999; display: none; `,document.body.append(t.touchedNode),B9(e.targetData.node.el,t.touchedNode),t.touchedNode.style.display="none",document.addEventListener("contextmenu",K9)}function LIe(e,t){const n=e.targetData.parent.data.config;n.longTouch&&(t.longTouchTimeout=setTimeout(()=>{t&&(t.longTouch=!0,n.longTouchClass&&e.e.cancelable&&Ml(t.draggedNodes.map(r=>r.el),n.longTouchClass),e.e.preventDefault())},n.longTouchTimeout||200))}function $Ie(e){!qe||!("touchedNode"in qe)||HIe(e,qe)}function IIe(e,t){t.longTouchClass&&x0(e.draggedNodes.map(n=>n.el),t==null?void 0:t.longTouchClass),t.touchDraggingClass&&Ml([e.touchedNode],t.touchDraggingClass),t.touchDropZoneClass&&Ml(e.draggedNodes.map(n=>n.el),t.touchDropZoneClass)}function DIe(e){if(!e||!e.scrollParent)return;const{x:t,y:n,width:r,height:i}=e.scrollParent.getBoundingClientRect(),{x:o,y:a,scrollOutside:s}=e.lastParent.data.config.scrollBehavior;return{state:e,xThresh:o,yThresh:a,scrollOutside:s,scrollParent:e.scrollParent,x:t,y:n,width:r,height:i}}function FIe(e){const t=DIe(qe);if(t)switch(e){case"down":return VIe(t.state,t);case"up":return zIe(t.state,t);case"right":return BIe(t.state,t);case"left":return UIe(t.state,t)}}function BIe(e,t){const n=t.scrollParent.clientWidth+t.x-e.coordinates.x;if(!(!t.scrollOutside&&n<0)&&n<(1-t.xThresh)*t.scrollParent.clientWidth&&!(t.scrollParent.scrollLeft+t.scrollParent.clientWidth>=t.scrollParent.scrollWidth))return e}function UIe(e,t){const n=t.scrollParent.clientWidth+t.x-e.coordinates.x;if(!(!t.scrollOutside&&n>t.scrollParent.clientWidth)&&n>t.xThresh*t.scrollParent.clientWidth&&t.scrollParent.scrollLeft!==0)return e}function zIe(e,t){const n=t.scrollParent.clientHeight+t.y-e.coordinates.y;if(!(!t.scrollOutside&&n>t.scrollParent.clientHeight)&&n>t.yThresh*t.scrollParent.clientHeight&&t.scrollParent.scrollTop!==0)return e}function VIe(e,t){const n=t.scrollParent.clientHeight+t.y-e.coordinates.y;if(!(!t.scrollOutside&&n<0)&&n<(1-t.yThresh)*t.scrollParent.clientHeight&&!(t.scrollParent.scrollTop+t.scrollParent.clientHeight>=t.scrollParent.scrollHeight))return e}function WIe(e,t){t.touchMoving=!0,t.touchedNode.style.display=t.touchedNodeDisplay||"";const{x:n,y:r}=Ul(e.e);t.coordinates.y=r,t.coordinates.x=n;const i=t.touchStartLeft??0,o=t.touchStartTop??0;t.touchedNode.style.left=`${n-i}px`,t.touchedNode.style.top=`${r-o}px`,IIe(t,e.targetData.parent.data.config)}function HIe(e,t){if(e.targetData.parent.data.config.longTouch&&!t.longTouch){clearTimeout(t.longTouchTimeout);return}e.e.cancelable&&e.e.preventDefault(),WIe(e,t),a1();const n=dIe(e);if(!n)return;const r={e:e.e,targetData:n};"node"in n?n.node.el.dispatchEvent(new CustomEvent("touchOverNode",{detail:r})):n.parent.el.dispatchEvent(new CustomEvent("touchOverParent",{detail:r}))}function a1(){for(const e of Object.keys(m$)){const[t,n]=m$[e];Y9(e,t,n)}}function Y9(e,t,n){const r=FIe(e);r&&(r.scrollParent.scrollBy(t,n),setTimeout(()=>{Y9(e,t,n)},"touchedNode"in r?10:100))}function GIe(e){if(!qe)return;const{x:t,y:n}=Ul(e.e);qe.coordinates.y=n,qe.coordinates.x=t,a1(),ZIe(e,qe)}function qIe(e){if(!qe)return;const{x:t,y:n}=Ul(e.e);qe.coordinates.y=n,qe.coordinates.x=t,a1(),s1(e,qe)}function KIe(e){qe&&s1(e.detail,qe)}function YIe(e,t){if(e.targetData.parent.el===t.lastParent.el)return!1;const n=e.targetData.parent.data.config;if(n.dropZone===!1)return!1;const r=t.initialParent.data.config;return n.accepts?n.accepts(e.targetData.parent,t.initialParent,t.lastParent,t):!(!n.group||n.group!==r.group)}function ZIe(e,t){var n;e.e.preventDefault(),e.e.stopPropagation(),e.targetData.parent.el===((n=t.lastParent)==null?void 0:n.el)?Z9(e,t):s1(e,t)}function XIe(e,t,n,r){var i;if(t.remapJustFinished)return t.remapJustFinished=!1,t.lastTargetValue=e.targetData.node.data.value,!1;if(t.lastTargetValue===e.targetData.node.data.value||t.draggedNodes.map(h=>h.el).includes(e.targetData.node.el)||t.preventEnter||t.swappedNodeValue===e.targetData.node.data.value||e.targetData.parent.el!==((i=t.lastParent)==null?void 0:i.el)||e.targetData.parent.data.config.sortable===!1)return!1;const o=e.targetData.node.el.getBoundingClientRect(),a=t.draggedNode.el.getBoundingClientRect(),s=o.y-a.y,l=o.x-a.x;let u;const f=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(h=>f[0]<=h.data.index&&h.data.index<=f[1]&&h.el!==t.draggedNode.el),Math.abs(s)>Math.abs(l)?u=s>0?"above":"below":u=l>0?"left":"right";const d=t.lastParent.data.config.threshold;switch(u){case"left":if(n>o.x+o.width*d.horizontal)return t.incomingDirection="left",!0;break;case"right":if(no.y+o.height*d.vertical)return t.incomingDirection="above",!0;break;case"below":if(r{const r=t(n.currentTarget);if(r)return e({e:n,targetData:r})}}function QIe(e,t){const n=V9(e),r=tE(e.lastParent.el,e.lastParent.data).filter(s=>!n.includes(s)),i=tE(t.targetData.parent.el,t.targetData.parent.data),o=e.initialParent.el===t.targetData.parent.el&&t.targetData.parent.data.config.sortable===!1;let a;"node"in t.targetData?(o?a=e.initialIndex:t.targetData.parent.data.config.sortable===!1?a=t.targetData.parent.data.enabledNodes.length:a=t.targetData.node.data.index,i.splice(a,0,...n)):(a=o?e.initialIndex:t.targetData.parent.data.enabledNodes.length,i.splice(a,0,...n)),nE(e.lastParent.el,e.lastParent.data,r),nE(t.targetData.parent.el,t.targetData.parent.data,i)}function s1(e,t){YIe(e,t)&&(e.targetData.parent.data.config.performTransfer(t,e),t.lastParent=e.targetData.parent)}function JIe(e){function t(n){const r=$i.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})}}function e6e(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 t6e(e,t){const n=e6e(e);n&&t(n)}var w0=new WeakMap;function n6e(e){const t=w0.get(e);return t?t[0]:(console.warn("No values found for parent element"),[])}function r6e(e,t){const n=w0.get(t);n&&n[1](e),w0.set(t,[e,n[1]])}function i6e(e,t){return n=>{w0.set(n,t),vIe({parent:n,getValues:n6e,setValues:r6e,config:e})}}function v$(e){I9&&(Array.isArray(e)||(e=[e]),e.forEach(t=>{const{parent:n,state:r,...i}=t;t6e(n,i6e(i,r))}))}function o6e(e,t={}){const n=R.useRef(null),[r,i]=R.useState(e);function o(a={}){v$({parent:n,state:[r,i],...a})}return R.useEffect(()=>{v$({parent:n,state:[r,i],...t})},[r]),R.useEffect(()=>()=>{n.current&&W9(n.current)},[]),[n,r,i,o]}const l1=()=>{const e=Eo(),t=Ss(),n=Bp(),r=R.useMemo(()=>{const{orderBy:o,tags:a,excludeBots:s,excludeMaxVisitsReached:l,excludePastValidUntil:u,...f}=n,d=o?cle(o):void 0,h=(a==null?void 0:a.split(","))??[];return{...f,orderBy:d,tags:h,excludeBots:s!==void 0?s==="true":void 0,excludeMaxVisitsReached:l!==void 0?l==="true":void 0,excludePastValidUntil:u!==void 0?u==="true":void 0}},[n]),i=R.useCallback(o=>{const a={...r,...o},{orderBy:s,tags:l,excludeBots:u,excludeMaxVisitsReached:f,excludePastValidUntil:d,...h}=a,v={...h,orderBy:s&&ule(s),tags:l.length>0?l.join(","):void 0,excludeBots:yx(u),excludeMaxVisitsReached:yx(f),excludePastValidUntil:yx(d)},g=ob(v),y=g?`?${g}`:"";e(`${t}/list-short-urls/1${y}`)},[r,e,t]);return[r,i]},BT=()=>{const{domain:e}=Bp(),{shortCode:t=""}=qc();return R.useMemo(()=>({shortCode:kT(t),domain:e}),[e,t])},u1=()=>{const e=I$e();return m.jsx(Ye,{color:"link",size:"lg",className:"p-0 me-3",onClick:e,"aria-label":"Go back",children:m.jsx(je,{icon:SZ})})},a6e={android:"Android",ios:"iOS",desktop:"Desktop"},s6e=({deviceType:e,onDeviceTypeChange:t})=>{const n=R.useId();return m.jsxs("div",{children:[m.jsx("label",{htmlFor:n,children:"Device type:"}),m.jsxs("select",{id:n,className:"form-select",value:e,onChange:r=>t(r.target.value),required:!0,children:[!e&&m.jsx("option",{value:"",children:"- Select type -"}),Object.entries(a6e).map(([r,i])=>m.jsx("option",{value:r,children:i},r))]})]})},l6e=({language:e,onLanguageChange:t})=>{const n=R.useId();return m.jsxs("div",{children:[m.jsx("label",{htmlFor:n,children:"Language:"}),m.jsx(qn,{id:n,value:e??"",onChange:r=>t(r.target.value),placeholder:"en-US / en",required:!0})]})},u6e=({name:e,value:t,onNameChange:n,onValueChange:r})=>{const i=R.useId(),o=R.useId();return m.jsxs(m.Fragment,{children:[m.jsxs("div",{children:[m.jsx("label",{htmlFor:i,children:"Param name:"}),m.jsx(qn,{id:i,value:e??"",onChange:a=>n(a.target.value),placeholder:"hello",required:!0})]}),m.jsxs("div",{children:[m.jsx("label",{htmlFor:o,children:"Param value:"}),m.jsx(qn,{id:o,value:t??"",onChange:a=>r(a.target.value),placeholder:"world",required:!0})]})]})},c6e={device:"Device type",language:"Language","query-param":"Query param"},f6e=({condition:e,onConditionChange:t,onDelete:n})=>{const r=R.useId(),i=R.useCallback(s=>t({type:s,matchValue:"",matchKey:null}),[t]),o=R.useCallback(s=>t({...e,matchValue:s}),[e,t]),a=R.useCallback(s=>t({...e,matchKey:s}),[e,t]);return m.jsxs("div",{className:"redirect-rule-modal__condition rounded p-3 h-100 d-flex flex-column gap-2",children:[m.jsxs("div",{children:[m.jsx("label",{htmlFor:r,children:"Type:"}),m.jsxs("div",{className:"d-flex gap-2",children:[m.jsx("select",{id:r,className:"form-select flex-grow-1",value:e.type,onChange:s=>i(s.target.value),children:Object.entries(c6e).map(([s,l])=>m.jsx("option",{value:s,children:l},s))}),m.jsx(Ye,{outline:!0,color:"danger",type:"button","aria-label":"Delete condition",onClick:n,children:m.jsx(je,{icon:$D})})]})]}),e.type==="device"&&m.jsx(s6e,{deviceType:e.matchValue,onDeviceTypeChange:o}),e.type==="language"&&m.jsx(l6e,{language:e.matchValue,onLanguageChange:o}),e.type==="query-param"&&m.jsx(u6e,{value:e.matchValue,name:e.matchKey??"",onNameChange:a,onValueChange:o})]})},X9=({isOpen:e,toggle:t,onSave:n,initialData:r})=>{const[i,o]=R.useState(r??{longUrl:"",conditions:[]}),a=R.useCallback(v=>{v.preventDefault(),v.stopPropagation(),i&&n(i),t()},[n,i,t]),s=R.useCallback(()=>o(({longUrl:v,conditions:g})=>({longUrl:v,conditions:[...g,{type:"device",matchValue:"",matchKey:null}]})),[]),l=R.useCallback((v,g)=>o(({longUrl:y,conditions:x})=>{const _=[...x];return _[v]=g,{longUrl:y,conditions:_}}),[]),u=R.useCallback(v=>o(({longUrl:g,conditions:y})=>{const x=[...y];return x.splice(v,1),{longUrl:g,conditions:x}}),[]),f=ca(),d=R.useCallback(()=>{var v;return(v=f==null?void 0:f.current)==null?void 0:v.focus()},[f]),h=R.useCallback(()=>o(r??{longUrl:"",conditions:[]}),[r]);return m.jsx(Po,{size:"xl",isOpen:e,toggle:t,centered:!0,onOpened:d,onClosed:h,children:m.jsxs("form",{onSubmit:a,children:[m.jsx(Co,{toggle:t,className:"sticky-top redirect-rule-modal__header",children:"Redirect rule"}),m.jsxs(Wi,{children:[m.jsx("label",{htmlFor:"longUrl",className:"fw-bold",children:"Long URL:"}),m.jsx(qn,{id:"longUrl",type:"url",placeholder:"https://www.example.com",value:i.longUrl,onChange:v=>o(g=>({...g,longUrl:v.target.value})),required:!0,innerRef:f}),m.jsx("hr",{}),m.jsxs("div",{className:"d-flex justify-content-between",children:[m.jsx("b",{children:"Conditions:"}),m.jsx(Ye,{outline:!0,size:"sm",type:"button","aria-label":"Add condition",onClick:s,children:m.jsx(je,{icon:Tp})})]}),i.conditions.length===0&&m.jsx("div",{className:"text-center",children:m.jsx("i",{children:"Add conditions..."})}),i.conditions.length>0&&m.jsx(rr,{children:i.conditions.map((v,g)=>m.jsx("div",{className:"col-lg-6 col-xl-4 mt-3",children:m.jsx(f6e,{condition:v,onConditionChange:y=>l(g,y),onDelete:()=>u(g)})},`${g}_${v.type}`))})]}),m.jsxs(gs,{className:"sticky-bottom redirect-rule-modal__footer",children:[m.jsx(Ye,{type:"button",color:"link",onClick:t,children:"Cancel"}),m.jsx(Ye,{color:"primary",disabled:i.conditions.length===0,children:"Confirm"})]})]})})},d6e=({priority:e,isLast:t,redirectRule:n,onDelete:r,onMoveUp:i,onMoveDown:o,onUpdate:a})=>{const[s,l]=Zt();return m.jsxs(Ot,{children:[m.jsxs("div",{className:"d-flex align-content-center gap-3",children:[m.jsx("div",{className:"d-flex flex-column my-auto drag-n-drop-handler d-none d-md-block",style:{cursor:"grab"},children:m.jsx(je,{icon:kZ})}),m.jsxs("div",{className:"d-flex flex-column my-auto",children:[m.jsx(Ye,{outline:!0,color:"secondary",size:"sm","aria-label":`Move rule with priority ${e} up`,disabled:e===1,onClick:i,className:"rounded-0 rounded-top",style:{marginBottom:"-1px"},children:m.jsx(je,{icon:GZ})}),m.jsx(Ye,{outline:!0,color:"secondary",size:"sm","aria-label":`Move rule with priority ${e} down`,disabled:t,onClick:o,className:"rounded-0 rounded-bottom",children:m.jsx(je,{icon:UZ})})]}),m.jsxs("div",{className:"flex-grow-1",children:[m.jsxs("div",{className:"mb-2",children:[m.jsx("b",{children:"Long URL:"})," ",m.jsx(Er,{href:n.longUrl,"data-testid":"rule-long-url"})]}),m.jsxs("div",{className:"d-flex flex-column flex-lg-row gap-2",children:[m.jsx("b",{children:"Conditions:"}),n.conditions.map((u,f)=>m.jsxs("div",{className:"badge bg-secondary",children:[u.type==="device"&&m.jsxs(m.Fragment,{children:["Device is ",u.matchValue]}),u.type==="language"&&m.jsxs(m.Fragment,{children:[u.matchValue," language is accepted"]}),u.type==="query-param"&&m.jsxs(m.Fragment,{children:["Query string contains ",u.matchKey,"=",u.matchValue]})]},`${u.type}_${f}`))]})]}),m.jsxs("div",{className:"d-flex flex-column flex-sm-row gap-1 my-auto",children:[m.jsx(Ye,{outline:!0,color:"secondary",size:"sm","aria-label":`Edit rule with priority ${e}`,onClick:l,children:m.jsx(je,{icon:ID})}),m.jsx(Ye,{outline:!0,color:"danger",size:"sm","aria-label":`Delete rule with priority ${e}`,onClick:r,children:m.jsx(je,{icon:$D})})]})]}),m.jsx(X9,{onSave:a,isOpen:s,toggle:l,initialData:n})]})},h6e=({shortUrlRedirectRules:e,getShortUrlRedirectRules:t,getShortUrlsDetails:n,shortUrlsDetails:r,setShortUrlRedirectRules:i,shortUrlRedirectRulesSaving:o,resetSetRules:a})=>{const s=BT(),{shortUrls:l}=r,u=s&&(l==null?void 0:l.get(s)),[f,d,h]=o6e([],{dragHandle:".drag-n-drop-handler",dropZoneClass:"opacity-25"}),{saving:v,saved:g,errorData:y}=o,[x,_]=Zt(),b=R.useCallback(D=>h((k=[])=>[...k,D]),[h]),w=R.useCallback(D=>h((k=[])=>{const I=[...k];return I.splice(D,1),I}),[h]),S=R.useCallback((D,k)=>h((I=[])=>{const F=[...I];return F[D]=k,F}),[h]),E=R.useCallback((D,k)=>h((I=[])=>{if(!I[k])return I;const F=[...I],q=F[k];return F[k]=F[D],F[D]=q,F}),[h]),P=R.useCallback(D=>E(D,D-1),[E]),T=R.useCallback(D=>E(D,D+1),[E]),A=R.useCallback(D=>{D.preventDefault(),d&&i({shortUrl:s,data:{redirectRules:d}})},[s,d,i]);return R.useEffect(()=>(t(s),n([s]),a),[t,n,s,a]),R.useEffect(()=>{e.redirectRules&&h(e.redirectRules)},[h,e.redirectRules]),m.jsxs("div",{className:"d-flex flex-column gap-3",children:[m.jsx("header",{children:m.jsxs(Pr,{body:!0,children:[m.jsxs("h2",{className:"d-sm-flex justify-content-between align-items-center mb-0",children:[m.jsx(u1,{}),m.jsxs("div",{className:"text-center flex-grow-1",children:[r.loading&&m.jsx(m.Fragment,{children:"Loading..."}),!r.loading&&m.jsxs("small",{children:["Redirect rules for ",m.jsx(Er,{href:(u==null?void 0:u.shortUrl)??""})]})]})]}),m.jsx("hr",{}),m.jsxs("div",{children:[m.jsx("p",{className:"mb-2",children:"Configure dynamic conditions that will be checked at runtime."}),"If no conditions match, visitors will be redirected to: ",m.jsx(Er,{href:e.defaultLongUrl??""})]})]})}),m.jsx("div",{children:m.jsxs(Ye,{outline:!0,color:"primary",onClick:_,children:[m.jsx(je,{icon:Tp,className:"me-1"})," Add rule"]})}),m.jsxs("form",{onSubmit:A,children:[e.loading&&m.jsx(ta,{loading:!0}),d.length===0&&!e.loading&&m.jsx(Ot,{className:"text-center",children:m.jsx("i",{children:"This short URL has no dynamic redirect rules"})}),m.jsx("div",{className:"d-flex flex-column gap-2",ref:f,children:d.map((D,k)=>m.jsx(d6e,{redirectRule:D,priority:k+1,isLast:k===d.length-1,onDelete:()=>w(k),onMoveUp:()=>P(k),onMoveDown:()=>T(k),onUpdate:I=>S(k,I)},`${D.longUrl}_${k}`))}),m.jsx("div",{className:"text-center mt-3",children:m.jsx(Ye,{outline:!0,color:"primary",className:"btn-sm-block",disabled:v,"data-testid":"save-button",children:v?"Saving...":"Save rules"})})]}),y&&m.jsx(ur,{type:"error",children:m.jsx(So,{errorData:y,fallbackMessage:"An error occurred while saving short URL redirect rules :("})}),g&&m.jsx(ur,{type:"success",children:"Redirect rules properly saved."}),m.jsx(X9,{isOpen:x,toggle:_,onSave:b})]})},p6e=(e,t)=>{e.serviceFactory("ShortUrlRedirectRules",()=>h6e),e.decorator("ShortUrlRedirectRules",t(["shortUrlRedirectRules","shortUrlsDetails","shortUrlRedirectRulesSaving"],["getShortUrlRedirectRules","getShortUrlsDetails","setShortUrlRedirectRules","resetSetRules"])),e.serviceFactory("getShortUrlRedirectRules",uIe,"apiClientFactory"),e.serviceFactory("setShortUrlRedirectRules",aIe,"apiClientFactory"),e.serviceFactory("resetSetRules",n=>n.resetSetRules,"setShortUrlRedirectRulesReducerCreator"),e.serviceFactory("shortUrlRedirectRulesReducerCreator",cIe,"getShortUrlRedirectRules"),e.serviceFactory("shortUrlRedirectRulesReducer",n=>n.reducer,"shortUrlRedirectRulesReducerCreator"),e.serviceFactory("setShortUrlRedirectRulesReducerCreator",sIe,"setShortUrlRedirectRules"),e.serviceFactory("setShortUrlRedirectRulesReducer",n=>n.reducer,"setShortUrlRedirectRulesReducerCreator")},m6e=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}),Q9=({createShortUrl:e,shortUrlCreation:t,resetCreateShortUrl:n,basicMode:r=!1})=>{const{ShortUrlForm:i,CreateShortUrlResult:o}=It(Q9),a=jr("shortUrlCreation"),s=R.useMemo(()=>m6e(a),[a]);return m.jsxs(m.Fragment,{children:[m.jsx(i,{initialState:s,saving:t.saving,basicMode:r,onSave:async l=>(n(),e(l))}),m.jsx(o,{creation:t,resetCreateShortUrl:n,canBeClosed:r})]})},v6e=Dt(Q9,["ShortUrlForm","CreateShortUrlResult"]),J9=({shortUrlsDetails:e,getShortUrlsDetails:t,shortUrlEdition:n,editShortUrl:r})=>{const{ShortUrlForm:i}=It(J9),o=BT(),{loading:a,error:s,errorData:l,shortUrls:u}=e,f=o&&(u==null?void 0:u.get(o)),{saving:d,saved:h,error:v,errorData:g}=n,y=jr("shortUrlCreation"),x=R.useMemo(()=>d$e(f,y),[f,y]);return R.useEffect(()=>{o&&t([o])},[t,o]),a?m.jsx(ta,{loading:!0}):s?m.jsx(ur,{type:"error",children:m.jsx(So,{errorData:l,fallbackMessage:"An error occurred while loading short URL detail :("})}):m.jsxs(m.Fragment,{children:[m.jsx("header",{className:"mb-3",children:m.jsx(Pr,{body:!0,children:m.jsxs("h2",{className:"d-sm-flex justify-content-between align-items-center mb-0",children:[m.jsx(u1,{}),m.jsx("div",{className:"text-center flex-grow-1",children:m.jsxs("small",{children:["Edit ",m.jsx(Er,{href:(f==null?void 0:f.shortUrl)??""})]})})]})})}),m.jsx(i,{initialState:x,saving:d,onSave:async _=>{f&&r({...f,data:_})}}),h&&v&&m.jsx(ur,{type:"error",className:"mt-3",children:m.jsx(So,{errorData:g,fallbackMessage:"An error occurred while updating short URL :("})}),h&&!v&&m.jsx(ur,{type:"success",className:"mt-3",children:"Short URL properly edited."})]})},g6e=Dt(J9,["ShortUrlForm"]),ez=({text:e,onCopy:t},n=navigator)=>{var r;return(r=n.clipboard)==null?void 0:r.writeText(e).then(()=>t==null?void 0:t(e,!0)).catch(()=>t==null?void 0:t(e,!1))},tz=({creation:e,resetCreateShortUrl:t,canBeClosed:n=!1})=>{const{useTimeoutToggle:r}=It(tz),[i,o]=r(),{error:a,saved:s}=e;if(R.useEffect(()=>{t()},[t]),a)return m.jsxs(ur,{type:"error",className:"mt-3",children:[n&&m.jsx(je,{"data-testid":"error-close-button",icon:Pw,className:"float-end pointer",onClick:t}),m.jsx(So,{errorData:e.errorData,fallbackMessage:"An error occurred while creating the URL :("})]});if(!s)return null;const{shortUrl:l}=e.result;return m.jsxs(ur,{type:"success",className:"mt-3",children:[n&&m.jsx(je,{"data-testid":"success-close-button",icon:Pw,className:"float-end pointer",onClick:t}),m.jsxs("span",{children:[m.jsx("b",{children:"Great!"})," The short URL is ",m.jsx("b",{children:l})]}),m.jsxs("button",{className:"btn btn-light btn-sm create-short-url-result__copy-btn",id:"copyBtn",type:"button",onClick:()=>ez({text:l,onCopy:o}),children:[m.jsx(je,{icon:xF})," Copy ",m.jsxs("span",{className:"sr-only",children:[l," to clipboard"]})]}),m.jsx($p,{placement:"left",isOpen:i,target:"copyBtn",children:"Copied!"})]})},y6e=Dt(tz,["useTimeoutToggle"]),xx="delete",b6e=({shortUrl:e,toggle:t,isOpen:n,shortUrlDeletion:r,resetDeleteShortUrl:i,deleteShortUrl:o,shortUrlDeleted:a})=>{const[s,l]=R.useState("");R.useEffect(()=>i,[i]);const{loading:u,error:f,deleted:d,errorData:h}=r,v=R.useCallback(()=>{i(),t()},[i,t]),g=R.useCallback(y=>(y.preventDefault(),o(e).then(t)),[o,e,t]);return m.jsx(Po,{isOpen:n,toggle:v,centered:!0,onClosed:()=>d&&a(e),children:m.jsxs("form",{onSubmit:g,children:[m.jsx(Co,{toggle:v,children:m.jsx("span",{className:"text-danger",children:"Delete short URL"})}),m.jsxs(Wi,{children:[m.jsxs("p",{children:[m.jsx("b",{className:"text-danger",children:"Caution!"})," You are about to delete a short URL."]}),m.jsx("p",{children:"This action cannot be undone. Once you have deleted it, all the visits stats will be lost."}),m.jsxs("p",{children:["Write ",m.jsx("b",{children:xx})," to confirm deletion."]}),m.jsx("input",{type:"text",className:"form-control",placeholder:`Insert ${xx}`,value:s,onChange:y=>l(y.target.value)}),f&&m.jsx(ur,{type:s$e(h)?"warning":"error",small:!0,className:"mt-2",children:m.jsx(So,{errorData:h,fallbackMessage:"Something went wrong while deleting the URL :("})})]}),m.jsxs(gs,{children:[m.jsx("button",{type:"button",className:"btn btn-link",onClick:v,children:"Cancel"}),m.jsx("button",{type:"submit",className:"btn btn-danger",disabled:s!==xx||u,children:u?"Deleting...":"Delete"})]})]})})},nz=({amount:e=0,loading:t=!1,...n})=>m.jsxs(Ye,{...n,outline:!0,color:"primary",disabled:t,children:[m.jsx(je,{icon:sZ})," ",t?"Exporting...":m.jsxs(m.Fragment,{children:["Export (",Yt(e),")"]})]}),g$=20,rz=({amount:e=0})=>{const{apiClientFactory:t,ReportExporter:n}=It(rz),[{tags:r,search:i,startDate:o,endDate:a,orderBy:s,tagsMode:l}]=l1(),[u,,f,d]=Zt(),h=R.useCallback(async()=>{const v=e/g$,g=async(x=1)=>{const{data:_}=await t().listShortUrls({page:`${x}`,tags:r,searchTerm:i,startDate:o,endDate:a,orderBy:s,tagsMode:l,itemsPerPage:g$});return x>=v?_:_.concat(await g(x+1))};f();const y=await g();n.exportShortUrls(y.map(x=>{var _;const{hostname:b,pathname:w}=new URL(x.shortUrl),S=w.substring(1);return{createdAt:x.dateCreated,domain:b,shortCode:S,shortUrl:x.shortUrl,longUrl:x.longUrl,title:x.title??"",tags:x.tags.join("|"),visits:((_=x==null?void 0:x.visitsSummary)==null?void 0:_.total)??x.visitsCount??0}})),d()},[e,t,a,s,n,i,o,f,d,r,l]);return m.jsx(nz,{loading:u,className:"btn-md-block",amount:e,onClick:h})},_6e=Dt(rz,["apiClientFactory","ReportExporter"]),iz=({text:e,onCopy:t,copyToClipboard:n=ez})=>m.jsx(Nl,{className:"ms-2 p-0","aria-label":`Copy ${e} to clipboard`,onClick:()=>n({text:e,onCopy:t}),children:m.jsx(je,{icon:xF,className:"fs-5"})}),x6e=(e,{margin:t,...n})=>{const r=`${e}/qr-code`,i=ob({...n,margin:t>0?t:void 0});return`${r}${i?`?${i}`:""}`},w6e=({errorCorrection:e,setErrorCorrection:t})=>m.jsxs(fa,{text:`Error correction (${e})`,children:[m.jsxs(Ne,{active:e==="L",onClick:()=>t("L"),children:[m.jsx("b",{children:"L"}),"ow"]}),m.jsxs(Ne,{active:e==="M",onClick:()=>t("M"),children:[m.jsx("b",{children:"M"}),"edium"]}),m.jsxs(Ne,{active:e==="Q",onClick:()=>t("Q"),children:[m.jsx("b",{children:"Q"}),"uartile"]}),m.jsxs(Ne,{active:e==="H",onClick:()=>t("H"),children:[m.jsx("b",{children:"H"}),"igh"]})]}),O6e=({format:e,setFormat:t})=>m.jsxs(fa,{text:`Format (${e})`,children:[m.jsx(Ne,{active:e==="png",onClick:()=>t("png"),children:"PNG"}),m.jsx(Ne,{active:e==="svg",onClick:()=>t("svg"),children:"SVG"})]}),oz=({shortUrl:{shortUrl:e,shortCode:t},toggle:n,isOpen:r})=>{const{ImageDownloader:i}=It(oz),[o,a]=R.useState(300),[s,l]=R.useState(0),[u,f]=R.useState("png"),[d,h]=R.useState("L"),v=R.useMemo(()=>x6e(e,{size:o,format:u,margin:s,errorCorrection:d}),[e,o,u,s,d]),g=R.useMemo(()=>o+s,[o,s]),y=R.useMemo(()=>{if(!(g<500))return g<800?"lg":"xl"},[g]);return m.jsxs(Po,{isOpen:r,toggle:n,centered:!0,size:y,children:[m.jsxs(Co,{toggle:n,children:["QR code for ",m.jsx(Er,{href:e,children:e})]}),m.jsxs(Wi,{children:[m.jsxs(rr,{children:[m.jsxs(co,{className:"d-grid col-md-6",children:[m.jsxs("label",{htmlFor:"sizeControl",children:["Size: ",o,"px"]}),m.jsx("input",{id:"sizeControl",type:"range",className:"form-control-range",value:o,step:10,min:50,max:1e3,onChange:x=>a(Number(x.target.value))})]}),m.jsxs(co,{className:"d-grid col-md-6",children:[m.jsxs("label",{htmlFor:"marginControl",children:["Margin: ",s,"px"]}),m.jsx("input",{id:"marginControl",type:"range",className:"form-control-range",value:s,step:1,min:0,max:100,onChange:x=>l(Number(x.target.value))})]}),m.jsx(co,{className:"d-grid col-md-6",children:m.jsx(O6e,{format:u,setFormat:f})}),m.jsx(co,{className:"col-md-6",children:m.jsx(w6e,{errorCorrection:d,setErrorCorrection:h})})]}),m.jsxs("div",{className:"text-center",children:[m.jsxs("div",{className:"mb-3",children:[m.jsx(Er,{href:v}),m.jsx(iz,{text:v})]}),m.jsx("img",{src:v,className:"qr-code-modal__img",alt:"QR code"}),m.jsx("div",{className:"mt-3",children:m.jsxs(Ye,{block:!0,color:"primary",onClick:()=>{i.saveImage(v,`${t}-qr-code.${u}`).catch(()=>{})},children:["Download ",m.jsx(je,{icon:UD,className:"ms-1"})]})})]})]})]})},S6e=Dt(oz,["ImageDownloader"]),O0=({date:e,format:t=v9,relative:n=!1})=>{const r=MT(e)?e:as(e);return m.jsx("time",{dateTime:`${Yce(r)}000`,children:n?`${qce(us(),r)} ago`:by(r,t)})},E6e=e=>{const{meta:t,visitsCount:n,visitsSummary:r}=e,{maxVisits:i,validSince:o,validUntil:a}=t,s=(r==null?void 0:r.total)??n??0;return i&&s>=i?{icon:eX,className:"text-danger",description:m.jsxs(m.Fragment,{children:["This short URL cannot be currently visited because it has reached the maximum amount of ",m.jsx("b",{children:i})," visit",i>1?"s":"","."]})}:a&&_y(Dr(a),us())?{icon:wk,className:"text-danger",description:m.jsxs(m.Fragment,{children:["This short URL cannot be visited since ",m.jsx("b",{className:"indivisible",children:_p(Dr(a))}),"."]})}:o&&_y(us(),Dr(o))?{icon:wk,className:"text-warning",description:m.jsxs(m.Fragment,{children:["This short URL will start working on ",m.jsx("b",{className:"indivisible",children:_p(Dr(o))}),"."]})}:{icon:gh,className:"text-primary",description:"This short URL can be visited normally."}},P6e=({shortUrl:e})=>{const t=ca(),{icon:n,className:r,description:i}=E6e(e);return m.jsxs(m.Fragment,{children:[m.jsx("span",{style:{cursor:i?"help":void 0},ref:t,children:m.jsx(je,{icon:n,className:r})}),m.jsx(Tr,{target:t,placement:"bottom",children:i})]})},C6e=(e,{shortCode:t,domain:n},r)=>{const i=n?`?domain=${n}`:"";return`${e}/short-code/${p9(t)}/${r}${i}`},ig=({shortUrl:e,suffix:t,asLink:n,children:r,...i})=>{const o=Ss();return!n||!e?m.jsx("span",{...i,children:r}):m.jsx(Pt,{to:C6e(o,e,t),...i,children:r})},az=({visitsCount:e,shortUrl:t,active:n=!1,asLink:r=!1})=>{const i=ca(),{maxVisits:o,validSince:a,validUntil:s}=(t==null?void 0:t.meta)??{},l=!!o||!!a||!!s,u=m.jsx(ig,{shortUrl:t,suffix:"visits",asLink:r,children:m.jsx("strong",{className:Pe("short-url-visits-count__amount",{"short-url-visits-count__amount--big":n}),children:Yt(e)})});return l?m.jsxs(m.Fragment,{children:[m.jsxs("span",{className:"indivisible",children:[u,m.jsxs("small",{className:"short-urls-visits-count__max-visits-control",ref:i,children:[o&&m.jsxs(m.Fragment,{children:[" / ",Yt(o)]}),m.jsx("sup",{className:"ms-1",children:m.jsx(je,{icon:pP})})]})]}),m.jsx(Tr,{target:i,placement:"bottom",children:m.jsxs("ul",{className:"list-unstyled mb-0",children:[o&&m.jsxs("li",{className:"short-url-visits-count__tooltip-list-item",children:["This short URL will not accept more than ",m.jsx("b",{children:Yt(o)})," visit",o===1?"":"s","."]}),a&&m.jsxs("li",{className:"short-url-visits-count__tooltip-list-item",children:["This short URL will not accept visits before ",m.jsx("b",{className:"indivisible",children:_p(Dr(a))}),"."]}),s&&m.jsxs("li",{className:"short-url-visits-count__tooltip-list-item",children:["This short URL will not accept visits after ",m.jsx("b",{className:"indivisible",children:_p(Dr(s))}),"."]})]})})]}):u},T6e=e=>!!e.onClose,j6e=e=>!!e.onClick,c1=e=>{const{text:t,children:n,className:r,colorGenerator:i}=e,o=j6e(e),a=o?Nl:"span",s=R.useMemo(()=>i.stylesForKey(t),[t,i]);return m.jsxs(a,{className:Pe("badge tag fw-bold",r,{pointer:o}),style:s,onClick:o?e.onClick:void 0,children:[n??t,T6e(e)&&m.jsx(Nl,{"aria-label":`Remove ${t}`,className:"bg-transparent ms-1 opacity-100 p-0 fw-bold tag__close",onClick:e.onClose,children:"×"})]})},A6e=({tags:e,onTagClick:t,colorGenerator:n})=>e.length===0?m.jsx("i",{className:"indivisible",children:m.jsx("small",{children:"No tags"})}):m.jsx(m.Fragment,{children:e.map(r=>m.jsx(c1,{text:r,colorGenerator:n,onClick:()=>t==null?void 0:t(r)},r))}),sz=({shortUrl:e,onTagClick:t})=>{var n,r,i,o;const{ShortUrlsRowMenu:a,ColorGenerator:s,useTimeoutToggle:l}=It(sz),[u,f]=l(),[d,h]=l(!1,500),v=R.useRef(!0),[{excludeBots:g}]=l1(),y=jr("visits"),x=g??(y==null?void 0:y.excludeBots);return R.useEffect(()=>{!v.current&&h(),v.current=!1},[(n=e.visitsSummary)==null?void 0:n.total,(r=e.visitsSummary)==null?void 0:r.nonBots,e.visitsCount,h]),m.jsxs("tr",{className:"responsive-table__row",children:[m.jsx("td",{className:"indivisible short-urls-row__cell responsive-table__cell","data-th":"Created at",children:m.jsx(O0,{date:e.dateCreated})}),m.jsx("td",{className:"responsive-table__cell short-urls-row__cell","data-th":"Short URL",children:m.jsxs("span",{className:"position-relative short-urls-row__cell--indivisible",children:[m.jsx("span",{className:"short-urls-row__short-url-wrapper",children:m.jsx(Er,{href:e.shortUrl})}),m.jsx(iz,{text:e.shortUrl,onCopy:f}),m.jsx("span",{role:"status",className:"badge bg-warning text-black short-urls-row__copy-hint",hidden:!u,children:"Copied short URL!"})]})}),m.jsx("td",{className:"responsive-table__cell short-urls-row__cell short-urls-row__cell--break","data-th":`${e.title?"Title":"Long URL"}`,children:m.jsx(Er,{href:e.longUrl,children:e.title??e.longUrl})}),e.title&&m.jsx("td",{className:"short-urls-row__cell responsive-table__cell short-urls-row__cell--break d-lg-none","data-th":"Long URL",children:m.jsx(Er,{href:e.longUrl})}),m.jsx("td",{className:"responsive-table__cell short-urls-row__cell","data-th":"Tags",children:m.jsx(A6e,{tags:e.tags,colorGenerator:s,onTagClick:t})}),m.jsx("td",{className:"responsive-table__cell short-urls-row__cell text-lg-end","data-th":"Visits",children:m.jsx(az,{visitsCount:(x?(i=e.visitsSummary)==null?void 0:i.nonBots:(o=e.visitsSummary)==null?void 0:o.total)??e.visitsCount??0,shortUrl:e,active:d,asLink:!0})}),m.jsx("td",{className:"responsive-table__cell short-urls-row__cell","data-th":"Status",children:m.jsx(P6e,{shortUrl:e})}),m.jsx("td",{className:"responsive-table__cell short-urls-row__cell text-end",children:m.jsx(a,{shortUrl:e})})]})},k6e=Dt(sz,["ShortUrlsRowMenu","ColorGenerator","useTimeoutToggle"]),N6e=(e,{maxVersion:t,minVersion:n})=>{const r=!n||_O(e,n,">=");return(!t||_O(e,t,"<="))&&r},lz={excludeBotsOnShortUrls:{minVersion:"3.4.0"},filterDisabledUrls:{minVersion:"3.4.0"},deviceLongUrls:{minVersion:"3.5.0",maxVersion:"3.*.*"},shortUrlVisitsDeletion:{minVersion:"3.6.0"},orphanVisitsDeletion:{minVersion:"3.7.0"},shortUrlRedirectRules:{minVersion:"4.0.0"},urlValidation:{maxVersion:"3.*.*"}};Object.freeze(lz);const Ls=(e,t)=>t==="latest"||N6e(t,lz[e]),uz=e=>({excludeBotsOnShortUrls:Ls("excludeBotsOnShortUrls",e),filterDisabledUrls:Ls("filterDisabledUrls",e),deviceLongUrls:Ls("deviceLongUrls",e),shortUrlVisitsDeletion:Ls("shortUrlVisitsDeletion",e),orphanVisitsDeletion:Ls("orphanVisitsDeletion",e),shortUrlRedirectRules:Ls("shortUrlRedirectRules",e),urlValidation:Ls("urlValidation",e)}),cz=R.createContext(uz("0.0.0")),M6e=cz.Provider,R6e=e=>R.useMemo(()=>uz(e),[e]),fs=e=>R.useContext(cz)[e],fz=({shortUrl:e})=>{const{DeleteShortUrlModal:t,QrCodeModal:n}=It(fz),[r,,i,o]=Zt(),[a,,s,l]=Zt(),u=r1(),f=fs("shortUrlRedirectRules");return m.jsxs(ab,{minWidth:f?220:190,children:[m.jsxs(Ne,{tag:ig,shortUrl:e,suffix:"visits",asLink:!0,children:[m.jsx(je,{icon:hP,fixedWidth:!0})," Visit stats"]}),u&&m.jsxs(m.Fragment,{children:[m.jsxs(Ne,{disabled:!u.canAddItemWithName(e.shortUrl),onClick:()=>u.addItemToCompare({name:e.shortUrl,query:NT(e)}),children:[m.jsx(je,{icon:Z0,fixedWidth:!0})," Compare visits"]}),m.jsx(Ne,{divider:!0,tag:"hr"})]}),m.jsxs(Ne,{tag:ig,shortUrl:e,suffix:"edit",asLink:!0,children:[m.jsx(je,{icon:dP,fixedWidth:!0})," Edit short URL"]}),f&&m.jsxs(Ne,{tag:ig,shortUrl:e,suffix:"redirect-rules",asLink:!0,children:[m.jsx(je,{icon:nX,fixedWidth:!0})," Manage redirect rules"]}),m.jsxs(Ne,{onClick:i,children:[m.jsx(je,{icon:QZ,fixedWidth:!0})," QR code"]}),m.jsx(n,{shortUrl:e,isOpen:r,toggle:o}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsxs(Ne,{className:"dropdown-item--danger",onClick:s,children:[m.jsx(je,{icon:fP,fixedWidth:!0})," Delete short URL"]}),m.jsx(t,{shortUrl:e,isOpen:a,toggle:l})]})},L6e=Dt(fz,["DeleteShortUrlModal","QrCodeModal"]),dz="shlink/shortUrlCreation",y$={saving:!1,saved:!1,error:!1},$6e=e=>gn(`${dz}/createShortUrl`,t=>e().createShortUrl(t)),I6e=e=>{const{reducer:t,actions:n}=nn({name:dz,initialState:y$,reducers:{resetCreateShortUrl:()=>y$},extraReducers:i=>{i.addCase(e.pending,()=>({saving:!0,saved:!1,error:!1})),i.addCase(e.rejected,(o,{error:a})=>({saving:!1,saved:!1,error:!0,errorData:Yr(a)})),i.addCase(e.fulfilled,(o,{payload:a})=>({result:a,saving:!1,saved:!0,error:!1}))}}),{resetCreateShortUrl:r}=n;return{reducer:t,resetCreateShortUrl:r}},hz="shlink/shortUrlEdition",D6e={saving:!1,saved:!1,error:!1},F6e=e=>gn(`${hz}/editShortUrl`,({shortCode:t,domain:n,data:r})=>e().updateShortUrl(t,n,r)),B6e=e=>nn({name:hz,initialState:D6e,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:Yr(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>({shortUrl:r,saving:!1,error:!1,saved:!0}))}}),b$="shlink/shortUrlsDetails",_$={loading:!1,error:!1},U6e=e=>{const t=gn(`${b$}/getShortUrlsDetails`,async(r,{getState:i})=>{const{shortUrlsList:o}=i(),a=await Promise.all(r.map(async s=>{var l;const{shortCode:u,domain:f}=s,d=(l=o==null?void 0:o.shortUrls)==null?void 0:l.data.find(h=>Zd(h,u,f));return[s,d??await e().getShortUrl(u,f)]}));return new Map(a)}),{reducer:n}=nn({name:b$,initialState:_$,reducers:{},extraReducers:r=>{r.addCase(t.pending,()=>({loading:!0,error:!1})),r.addCase(t.rejected,(i,{error:o})=>({loading:!1,error:!0,errorData:Yr(o)})),r.addCase(t.fulfilled,(i,{payload:o})=>({..._$,shortUrls:o}))}});return{reducer:n,getShortUrlsDetails:t}},wx=({icon:e,className:t,...n})=>{const r=ca();return m.jsxs("div",{className:"icon-input-container",children:[m.jsx(qn,{className:Pe("icon-input-container__input",t),innerRef:r,...n}),m.jsx(je,{icon:e,fixedWidth:!0,className:"icon-input-container__icon",onClick:()=>{var i;return(i=r.current)==null?void 0:i.focus()}})]})},z6e=({minDate:e,maxDate:t,value:n,onChange:r,withTime:i=!1,...o})=>{const a=R.useCallback(({target:l})=>{if(!l.value){r==null||r(null);return}r==null||r(Dr(l.value))},[r]),s=R.useMemo(()=>i?_p:Ba,[i]);return m.jsx(qn,{...o,type:i?"datetime-local":"date",value:s(n)??"",max:s(t)??void 0,min:s(e)??void 0,onChange:a})},S0=({label:e,id:t,...n})=>{const r=R.useId();return m.jsxs(m.Fragment,{children:[m.jsxs("label",{htmlFor:t??r,className:"mb-1",children:[e,":"]}),m.jsx(z6e,{id:t??r,...n})]})},Ox=({children:e,infoTooltip:t,checked:n,onChange:r})=>m.jsxs("p",{children:[m.jsx(I8,{inline:!0,checked:n,className:t?"me-2":"",onChange:r,children:e}),t&&m.jsx(rg,{placement:"right",children:t})]}),V6e=({isOpen:e,toggle:t})=>m.jsxs(Po,{isOpen:e,toggle:t,centered:!0,size:"lg",children:[m.jsx(Co,{toggle:t,children:"Info"}),m.jsxs(Wi,{children:[m.jsxs("p",{children:["When the ",m.jsx("b",{children:m.jsx("i",{children:'"Use existing URL if found"'})})," checkbox is checked, the server will return an existing short URL if it matches provided params."]}),m.jsx("p",{children:"These are the checks performed by Shlink in order to determine if an existing short URL should be returned:"}),m.jsxs("ul",{children:[m.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."}),m.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.",m.jsx("br",{}),"If the slug is being used by another long URL, an error will be returned."]}),m.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"})]})]})]}),W6e=()=>{const[e,t]=Zt();return m.jsxs(m.Fragment,{children:[m.jsx(Nl,{className:"p-0",title:"What does this mean?",onClick:t,children:m.jsx(je,{icon:pP})}),m.jsx(V6e,{isOpen:e,toggle:t})]})},Tv=e=>typeof e=="string"?as(e):e,H6e=e=>"shortCodeLength"in e&&"customSlug"in e&&"domain"in e,G6e=e=>"error"in e,pz=({basicMode:e=!1,saving:t,onSave:n,initialState:r,tagsList:i})=>{var o,a,s;const{TagsSelector:l,DomainSelector:u}=It(pz),[f,d]=R.useState(r),h=H6e(f),v=fs("deviceLongUrls"),g=fs("urlValidation"),y=g||h,x=R.useCallback(()=>d(r),[r]),_=R.useCallback((P,T)=>Ks(P)?P:Ks(T)?null:void 0,[]),b=R.useCallback((P,T)=>d(({deviceLongUrls:A={},...D})=>{var k;return{...D,deviceLongUrls:{...A,[P]:_(T,(k=r.deviceLongUrls)==null?void 0:k[P])}}}),[r.deviceLongUrls,_]),w=R.useCallback(P=>d(T=>({...T,tags:P})),[]),S=R.useCallback(async P=>(P.preventDefault(),n(f).then(T=>h&&!G6e(T)&&x()).catch(()=>{})),[h,n,x,f]),E=R.useMemo(()=>m.jsxs("div",{className:"d-flex flex-column gap-3",children:[m.jsx(qn,{bsSize:"lg",type:"url",placeholder:"URL to be shortened",required:!0,value:f.longUrl,onChange:P=>d(T=>({...T,longUrl:P.target.value}))}),m.jsxs("div",{className:Pe("d-flex flex-column flex-lg-row gap-3",{"mb-3":e}),children:[e&&h&&m.jsx("div",{className:"w-100 w-lg-50",children:m.jsx(qn,{bsSize:"lg",placeholder:"Custom slug",value:f.customSlug??"",onChange:P=>d(T=>({...T,customSlug:P.target.value}))})}),m.jsx("div",{className:Pe("w-100",{"w-lg-50":e}),children:m.jsx(l,{tags:i.tags,selectedTags:f.tags??[],onChange:w})})]})]}),[l,e,w,h,f,i.tags]);return m.jsxs("form",{name:"shortUrlForm",className:"short-url-form",onSubmit:S,children:[e&&E,!e&&m.jsxs(m.Fragment,{children:[m.jsxs(rr,{children:[m.jsx("div",{className:Pe("mb-3",{"col-sm-6":v,"col-12":!v}),children:m.jsx(Ot,{title:"Main options",children:E})}),v&&m.jsx("div",{className:"col-sm-6 mb-3",children:m.jsxs(Ot,{title:"Device-specific long URLs",bodyClassName:"d-flex flex-column gap-3",children:[m.jsx(wx,{type:"url",icon:Gfe,placeholder:"Android-specific redirection",value:((o=f.deviceLongUrls)==null?void 0:o.android)??"",onChange:({target:P})=>b("android",P.value)}),m.jsx(wx,{type:"url",icon:Hfe,placeholder:"iOS-specific redirection",value:((a=f.deviceLongUrls)==null?void 0:a.ios)??"",onChange:({target:P})=>b("ios",P.value)}),m.jsx(wx,{type:"url",icon:tX,placeholder:"Desktop-specific redirection",value:((s=f.deviceLongUrls)==null?void 0:s.desktop)??"",onChange:({target:P})=>b("desktop",P.value)})]})})]}),m.jsxs(rr,{children:[m.jsx("div",{className:"col-sm-6 mb-3",children:m.jsxs(Ot,{title:"Customize the short URL",bodyClassName:"d-flex flex-column gap-3",children:[m.jsx(qn,{placeholder:"Title",value:f.title??"",onChange:({target:P})=>d(T=>({...T,title:_(P.value,r.title)}))}),h&&m.jsxs(m.Fragment,{children:[m.jsxs(rr,{children:[m.jsx("div",{className:"col-lg-6 mb-3 mb-lg-0",children:m.jsx(qn,{placeholder:"Custom slug",value:f.customSlug??"",onChange:P=>d(T=>({...T,customSlug:P.target.value})),disabled:Ks(f.shortCodeLength)})}),m.jsx("div",{className:"col-lg-6",children:m.jsx(qn,{type:"number",placeholder:"Short code length",value:f.shortCodeLength??"",onChange:P=>d(T=>({...T,shortCodeLength:P.target.value})),min:4,disabled:Ks(f.customSlug)})})]}),m.jsx(u,{value:f.domain,onChange:P=>d(T=>({...T,domain:P}))})]})]})}),m.jsx("div",{className:"col-sm-6 mb-3",children:m.jsxs(Ot,{title:"Limit access to the short URL",children:[m.jsxs("div",{className:"row mb-3",children:[m.jsx("div",{className:"col-lg-6",children:m.jsx(S0,{label:"Enabled since",withTime:!0,maxDate:f.validUntil?Tv(f.validUntil):void 0,value:f.validSince?Tv(f.validSince):null,onChange:P=>d(T=>({...T,validSince:cs(P)}))})}),m.jsx("div",{className:"col-lg-6 mt-3 mt-lg-0",children:m.jsx(S0,{label:"Enabled until",withTime:!0,minDate:f.validSince?Tv(f.validSince):void 0,value:f.validUntil?Tv(f.validUntil):null,onChange:P=>d(T=>({...T,validUntil:cs(P)}))})})]}),m.jsxs("div",{children:[m.jsx("label",{htmlFor:"maxVisits",className:"mb-1",children:"Maximum visits allowed:"}),m.jsx(qn,{id:"maxVisits",type:"number",min:1,placeholder:"25...",value:f.maxVisits??"",onChange:P=>d(T=>({...T,maxVisits:Ks(P.target.value)?Number(P.target.value):null}))})]})]})})]}),m.jsxs(rr,{children:[y&&m.jsx("div",{className:"col-sm-6 mb-3",children:m.jsxs(Ot,{title:"Extra checks",children:[g&&m.jsx(Ox,{infoTooltip:"If checked, Shlink will try to reach the long URL, failing in case it's not publicly accessible.",checked:f.validateUrl,onChange:P=>d(T=>({...T,validateUrl:P})),children:"Validate URL"}),h&&m.jsxs("p",{children:[m.jsx(I8,{inline:!0,className:"me-2",checked:f.findIfExists,onChange:P=>d(T=>({...T,findIfExists:P})),children:"Use existing URL if found"}),m.jsx(W6e,{})]})]})}),m.jsx("div",{className:Pe("mb-3",{"col-sm-6":y}),children:m.jsxs(Ot,{title:"Configure behavior",children:[m.jsx(Ox,{infoTooltip:"This short URL will be included in the robots.txt for your Shlink instance, allowing web crawlers (like Google) to index it.",checked:f.crawlable,onChange:P=>d(T=>({...T,crawlable:P})),children:"Make it crawlable"}),m.jsx(Ox,{infoTooltip:"When this short URL is visited, any query params appended to it will be forwarded to the long URL.",checked:f.forwardQuery,onChange:P=>d(T=>({...T,forwardQuery:P})),children:"Forward query params on redirect"})]})})]})]}),m.jsx("div",{className:"text-center",children:m.jsx(Ye,{outline:!0,color:"primary",disabled:t||!f.longUrl,className:"btn-xs-block",children:t?"Saving...":"Save"})})]})},q6e=Dt(pz,["TagsSelector","DomainSelector"]),K6e=({active:e,allText:t,onChange:n})=>m.jsxs(m.Fragment,{children:[m.jsx(Ne,{active:e==="all",onClick:()=>n("all"),children:t}),m.jsx(Ne,{divider:!0,tag:"hr"}),m$e.map(r=>m.jsx(Ne,{active:e===r,onClick:()=>n(r),children:_9(r)},r))]}),Y6e=({startDate:e,endDate:t,disabled:n=!1,onStartDateChange:r,onEndDateChange:i})=>m.jsxs("div",{className:"row",children:[m.jsx("div",{className:"col-md-6",children:m.jsx(S0,{label:"Since",value:e,maxDate:t??void 0,disabled:n,onChange:r})}),m.jsx("div",{className:"col-md-6 mt-3 mt-md-0",children:m.jsx(S0,{label:"Until",value:t,minDate:e??void 0,disabled:n,onChange:o=>i(o&&_c(o))})})]}),UT=({onDatesChange:e,dateRangeOrInterval:t,defaultText:n,disabled:r})=>{const i=R.useMemo(()=>_9(t)??n,[t,n]),[o,a]=R.useMemo(()=>_0(t)?[void 0,t]:[t,void 0],[t]),s=R.useCallback(l=>{_0(l)?e(x9(l),l):e(l)},[e]);return m.jsxs(fa,{disabled:r,text:i,children:[m.jsx(K6e,{allText:n,active:a,onChange:s}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsx("div",{className:"px-3 py-1",children:m.jsx(Y6e,{...o,onStartDateChange:l=>s({...o,startDate:l}),onEndDateChange:l=>s({...o,endDate:l})})})]})},Z6e={dateCreated:"Created at",shortCode:"Short URL",longUrl:"Long URL",title:"Title",visits:"Visits"},X6e=({onChange:e,selected:t={},className:n,supportsDisabledFiltering:r})=>{const{excludeBots:i=!1,excludeMaxVisitsReached:o=!1,excludePastValidUntil:a=!1}=t,s=l=>()=>e({...t,[l]:!(t!=null&&t[l])});return m.jsxs(fa,{text:"Filters",dropdownClassName:n,end:!0,minWidth:250,children:[m.jsx(Ne,{header:!0,"aria-hidden":!0,children:"Visits:"}),m.jsx(Ne,{active:i,onClick:s("excludeBots"),children:"Ignore visits from bots"}),r&&m.jsxs(m.Fragment,{children:[m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsx(Ne,{header:!0,"aria-hidden":!0,children:"Short URLs:"}),m.jsx(Ne,{active:o,onClick:s("excludeMaxVisitsReached"),children:"Exclude with visits reached"}),m.jsx(Ne,{active:a,onClick:s("excludePastValidUntil"),children:"Exclude enabled in the past"})]}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsx(Ne,{disabled:t.excludeBots===void 0&&t.excludeMaxVisitsReached===void 0&&t.excludePastValidUntil===void 0,onClick:()=>e({excludeBots:void 0,excludeMaxVisitsReached:void 0,excludePastValidUntil:void 0}),children:m.jsx("i",{children:"Reset to defaults"})})]})},mz=({className:e,shortUrlsAmount:t,order:n,handleOrderBy:r,tagsList:i})=>{const{ExportShortUrlsBtn:o,TagsSelector:a}=It(mz),[{search:s,tags:l,startDate:u,endDate:f,excludeBots:d,excludeMaxVisitsReached:h,excludePastValidUntil:v,tagsMode:g="any"},y]=l1(),x=fs("filterDisabledUrls"),_=jr("visits"),[b,w]=R.useState(),S=R.useCallback(({startDate:A,endDate:D},k)=>{y({startDate:cs(A)??void 0,endDate:cs(D)??void 0}),w(k)},[y]),E=R.useCallback(A=>y({search:A||void 0}),[y]),P=R.useCallback(A=>y({tags:A}),[y]),T=R.useCallback(()=>y({tagsMode:g==="any"?"all":"any"}),[g,y]);return m.jsxs("div",{className:Pe("short-urls-filtering-bar-container",e),children:[m.jsx(Up,{initialValue:s,onChange:E}),m.jsxs(ib,{className:"mt-3",children:[m.jsx(a,{immutable:!0,placeholder:"With tags...",tags:i.tags,selectedTags:l,onChange:P}),l.length>1&&m.jsxs(m.Fragment,{children:[m.jsx(Ye,{outline:!0,color:"secondary",onClick:T,id:"tagsModeBtn","aria-label":"Change tags mode",children:m.jsx(je,{className:"short-urls-filtering-bar__tags-icon",icon:g==="all"?BD:CZ})}),m.jsx(Tr,{target:"tagsModeBtn",placement:"left",children:g==="all"?"With all the tags.":"With any of the tags."})]})]}),m.jsxs(rr,{className:"flex-lg-row-reverse",children:[m.jsx("div",{className:"col-lg-8 col-xl-6 mt-3",children:m.jsxs("div",{className:"d-md-flex",children:[m.jsx("div",{className:"flex-grow-1",children:m.jsx(UT,{defaultText:"All short URLs",dateRangeOrInterval:b??b9(u,f),onDatesChange:S})}),m.jsx(X6e,{className:"ms-0 ms-md-2 mt-3 mt-md-0",selected:{excludeBots:d??(_==null?void 0:_.excludeBots),excludeMaxVisitsReached:h,excludePastValidUntil:v},onChange:y,supportsDisabledFiltering:x})]})}),m.jsx("div",{className:"col-6 col-lg-4 col-xl-6 mt-3",children:m.jsx(o,{amount:t})}),m.jsx("div",{className:"col-6 d-lg-none mt-3",children:m.jsx(zp,{prefixed:!1,items:Z6e,order:n,onChange:r})})]})]})},Q6e=Dt(mz,["ExportShortUrlsBtn","TagsSelector"]);function Xd({currentOrder:e,field:t,className:n="ms-1"}){return!e.dir||e.field!==t?null:m.jsx(je,{icon:e.dir==="ASC"?bZ:NZ,className:n})}const hu=2,rE="...",vz=(e,t)=>{const n=cC(Math.max(hu,e-hu),Math.min(t-1,e+hu)+1);return e-hu>hu&&n.unshift(rE),e+hue===rE,gz=e=>xp(e)?e:Yt(e),yz=(e,t)=>xp(e)?`${e}_${t}`:`${e}`,J6e=({paginator:e,currentQueryString:t=""})=>{const{currentPage:n=0,pagesCount:r=0}=e??{},i=Ss(),o=s=>`${i}/list-short-urls/${s}${t}`;if(r<=1)return m.jsx("div",{className:"pb-3"});const a=()=>vz(n,r).map((s,l)=>m.jsx(cl,{disabled:xp(s),active:n===s,children:m.jsx(fl,{tag:Pt,to:o(s),children:gz(s)})},yz(s,l)));return m.jsxs(HP,{className:"sticky-card-paginator py-3",listClassName:"flex-wrap justify-content-center mb-0",children:[m.jsx(cl,{disabled:n===1,children:m.jsx(fl,{previous:!0,tag:Pt,to:o(n-1)})}),a(),m.jsx(cl,{disabled:n>=r,children:m.jsx(fl,{next:!0,tag:Pt,to:o(n+1)})})]})},eDe={field:"dateCreated",dir:"DESC"},bz=Ki(({listShortUrls:e,shortUrlsList:t})=>{var n,r,i;const{ShortUrlsTable:o,ShortUrlsFilteringBar:a}=It(bz),{page:s}=qc(),l=pr(),[{tags:u,search:f,startDate:d,endDate:h,orderBy:v,tagsMode:g,excludeBots:y,excludePastValidUntil:x,excludeMaxVisitsReached:_},b]=l1(),w=pC(),[S,E]=R.useState(v??((n=w.shortUrlsList)==null?void 0:n.defaultOrdering)??eDe),{pagination:P}=(t==null?void 0:t.shortUrls)??{},T=R.useMemo(()=>{var X;return y??((X=w.visits)==null?void 0:X.excludeBots)},[y,(r=w.visits)==null?void 0:r.excludeBots]),A=fs("excludeBotsOnShortUrls"),D=R.useCallback((X,Q)=>{b({orderBy:{field:X,dir:Q}}),E({field:X,dir:Q})},[b]),k=X=>()=>D(X,sb(X,S.field,S.dir)),I=X=>m.jsx(Xd,{currentOrder:S,field:X}),F=R.useCallback(X=>b({tags:[...new Set([...u,X])]}),[u,b]),q=R.useCallback(({field:X,dir:Q})=>A&&T&&X==="visits"?{field:"nonBotVisits",dir:Q}:{field:X,dir:Q},[T,A]),W=jT();return R.useEffect(()=>{e({page:s,searchTerm:f,tags:u,startDate:d,endDate:h,orderBy:q(S),tagsMode:g,excludePastValidUntil:x,excludeMaxVisitsReached:_})},[e,q,s,f,u,d,h,S,g,x,_]),m.jsxs(TT,{value:W,children:[m.jsx(a,{shortUrlsAmount:(i=t.shortUrls)==null?void 0:i.pagination.totalItems,order:S,handleOrderBy:D,className:"mb-3"}),m.jsx(AT,{type:"short-urls",className:"mb-3"}),m.jsxs(Pr,{body:!0,className:Pe({"pb-0":!t.loading}),children:[m.jsx(o,{shortUrlsList:t,orderByColumn:k,renderOrderIcon:I,onTagClick:F}),!t.loading&&m.jsx(J6e,{paginator:P,currentQueryString:l.search})]})]})},()=>[fr.visits]),tDe=Dt(bz,["ShortUrlsTable","ShortUrlsFilteringBar"]),_z=({orderByColumn:e,renderOrderIcon:t,shortUrlsList:n,onTagClick:r,className:i})=>{const{ShortUrlsRow:o}=It(_z),{error:a,loading:s,shortUrls:l}=n,u=Pe({"short-urls-table__header-cell--with-action":!!e}),f=Pe("short-urls-table__header-cell",u),d=Pe("table table-hover responsive-table short-urls-table",i),h=()=>a?m.jsx("tr",{children:m.jsx("td",{colSpan:6,className:"text-center table-danger text-dark",children:"Something went wrong while loading short URLs :("})}):s?m.jsx("tr",{children:m.jsx("td",{colSpan:6,className:"text-center",children:"Loading..."})}):!s&&(!l||l.data.length===0)?m.jsx("tr",{children:m.jsx("td",{colSpan:6,className:"text-center",children:"No results found"})}):l==null?void 0:l.data.map(v=>m.jsx(o,{shortUrl:v,onTagClick:r},v.shortUrl));return m.jsxs("table",{className:d,children:[m.jsx("thead",{className:"responsive-table__header short-urls-table__header",children:m.jsxs("tr",{children:[m.jsxs("th",{className:f,onClick:e==null?void 0:e("dateCreated"),children:["Created at ",t==null?void 0:t("dateCreated")]}),m.jsxs("th",{className:f,onClick:e==null?void 0:e("shortCode"),children:["Short URL ",t==null?void 0:t("shortCode")]}),m.jsxs("th",{className:"short-urls-table__header-cell",children:[m.jsxs(Nl,{className:Pe("p-0",u),onClick:e==null?void 0:e("title"),children:["Title ",t==null?void 0:t("title")]}),"  /  ",m.jsxs(Nl,{className:Pe("p-0",u),onClick:e==null?void 0:e("longUrl"),children:[m.jsx("span",{className:"indivisible",children:"Long URL"})," ",t==null?void 0:t("longUrl")]})]}),m.jsx("th",{className:"short-urls-table__header-cell",children:"Tags"}),m.jsx("th",{className:f,onClick:e==null?void 0:e("visits"),children:m.jsxs("span",{className:"indivisible",children:["Visits ",t==null?void 0:t("visits")]})}),m.jsx("th",{className:"short-urls-table__header-cell",colSpan:2,"aria-hidden":!0})]})}),m.jsx("tbody",{children:h()})]})},nDe=Dt(_z,["ShortUrlsRow"]),rDe=(e,t)=>{e.factory("ShortUrlsList",tDe),e.decorator("ShortUrlsList",t(["mercureInfo","shortUrlsList"],["listShortUrls","createNewVisits","loadMercureInfo"])),e.factory("ShortUrlsTable",nDe),e.factory("ShortUrlsRow",k6e),e.factory("ShortUrlsRowMenu",L6e),e.factory("CreateShortUrlResult",y6e),e.factory("ShortUrlForm",q6e),e.decorator("ShortUrlForm",t(["tagsList"])),e.factory("CreateShortUrl",v6e),e.decorator("CreateShortUrl",t(["shortUrlCreation"],["createShortUrl","resetCreateShortUrl"])),e.factory("EditShortUrl",g6e),e.decorator("EditShortUrl",t(["shortUrlsDetails","shortUrlEdition"],["getShortUrlsDetails","editShortUrl"])),e.serviceFactory("DeleteShortUrlModal",()=>b6e),e.decorator("DeleteShortUrlModal",t(["shortUrlDeletion"],["deleteShortUrl","shortUrlDeleted","resetDeleteShortUrl"])),e.factory("QrCodeModal",S6e),e.factory("ExportShortUrlsBtn",_6e),e.factory("ShortUrlsFilteringBar",Q6e),e.decorator("ShortUrlsFilteringBar",t(["tagsList"])),e.serviceFactory("shortUrlsListReducerCreator",eIe,"listShortUrls","editShortUrl","createShortUrl"),e.serviceFactory("shortUrlsListReducer",n=>n.reducer,"shortUrlsListReducerCreator"),e.serviceFactory("shortUrlCreationReducerCreator",I6e,"createShortUrl"),e.serviceFactory("shortUrlCreationReducer",n=>n.reducer,"shortUrlCreationReducerCreator"),e.serviceFactory("shortUrlEditionReducerCreator",B6e,"editShortUrl"),e.serviceFactory("shortUrlEditionReducer",n=>n.reducer,"shortUrlEditionReducerCreator"),e.serviceFactory("shortUrlDeletionReducerCreator",X$e,"deleteShortUrl"),e.serviceFactory("shortUrlDeletionReducer",n=>n.reducer,"shortUrlDeletionReducerCreator"),e.serviceFactory("shortUrlsDetailsReducerCreator",U6e,"apiClientFactory"),e.serviceFactory("shortUrlsDetailsReducer",n=>n.reducer,"shortUrlsDetailsReducerCreator"),e.serviceFactory("listShortUrls",J$e,"apiClientFactory"),e.serviceFactory("createShortUrl",$6e,"apiClientFactory"),e.serviceFactory("resetCreateShortUrl",n=>n.resetCreateShortUrl,"shortUrlCreationReducerCreator"),e.serviceFactory("deleteShortUrl",Z$e,"apiClientFactory"),e.serviceFactory("resetDeleteShortUrl",n=>n.resetDeleteShortUrl,"shortUrlDeletionReducerCreator"),e.serviceFactory("shortUrlDeleted",()=>A9),e.serviceFactory("getShortUrlsDetails",n=>n.getShortUrlsDetails,"shortUrlsDetailsReducerCreator"),e.serviceFactory("editShortUrl",F6e,"apiClientFactory")},iDe=({tag:e,toggle:t,isOpen:n,deleteTag:r,tagDelete:i,tagDeleted:o})=>{const{deleting:a,error:s,deleted:l,errorData:u}=i;return m.jsxs(Po,{toggle:t,isOpen:n,centered:!0,onClosed:()=>l&&o(e),children:[m.jsx(Co,{toggle:t,className:"text-danger",children:"Delete tag"}),m.jsxs(Wi,{children:["Are you sure you want to delete tag ",m.jsx("b",{children:e}),"?",s&&m.jsx(ur,{type:"error",small:!0,className:"mt-2",children:m.jsx(So,{errorData:u,fallbackMessage:"Something went wrong while deleting the tag :("})})]}),m.jsxs(gs,{children:[m.jsx(Ye,{color:"link",onClick:t,children:"Cancel"}),m.jsx(Ye,{color:"danger",disabled:a,onClick:async()=>{await r(e),t()},children:a?"Deleting tag...":"Delete tag"})]})]})},xz=({tag:e,editTag:t,toggle:n,tagEdited:r,isOpen:i,tagEdit:o})=>{const{ColorGenerator:a}=It(xz),[s,l]=R.useState(e),[u,f]=R.useState(a.getColorForKey(e)),{editing:d,error:h,edited:v,errorData:g}=o,y=j9(async()=>{await t({oldName:e,newName:s,color:u}),n()}),x=R.useCallback(()=>v&&r({oldName:e,newName:s,color:u}),[u,v,s,e,r]);return m.jsx(Po,{isOpen:i,toggle:n,centered:!0,onClosed:x,children:m.jsxs("form",{name:"editTag",onSubmit:y,children:[m.jsx(Co,{toggle:n,children:"Edit tag"}),m.jsxs(Wi,{children:[m.jsxs(ib,{children:[m.jsxs("div",{className:"input-group-text p-0 position-relative",style:{backgroundColor:u,borderColor:u},children:[m.jsx(je,{icon:_Z,className:"position-absolute top-50 start-50 translate-middle text-white"}),m.jsx(qn,{className:"form-control-color opacity-0",type:"color",value:u,onChange:_=>f(_.target.value)})]}),m.jsx(qn,{value:s,placeholder:"Tag",required:!0,onChange:({target:_})=>l(_.value)})]}),h&&m.jsx(ur,{type:"error",small:!0,className:"mt-2",children:m.jsx(So,{errorData:g,fallbackMessage:"Something went wrong while editing the tag :("})})]}),m.jsxs(gs,{children:[m.jsx(Ye,{type:"button",color:"link",onClick:n,children:"Cancel"}),m.jsx(Ye,{color:"primary",disabled:d,children:d?"Saving...":"Save"})]})]})})},oDe=Dt(xz,["ColorGenerator"]),aDe=/\s+/g,wz=e=>e.trim().toLowerCase().replace(aDe,"-"),Oz=({color:e})=>m.jsx("div",{style:{backgroundColor:e},className:"color-bullet"}),Sz=({tag:e,colorGenerator:t})=>m.jsx(Oz,{color:t.getColorForKey(e)});let x$=1;const Ez="Tag not found",Pz="Add tag",sDe=e=>e!==Ez,lDe=e=>e===Pz,w$=e=>(x$+=1,{label:e,value:`${e}${x$}`}),uDe=e=>({tag:t,onClick:n})=>m.jsx(c1,{colorGenerator:e,text:t.label,className:"react-tags__tag",onClose:n}),cDe=(e,t)=>({option:n,classNames:r,...i})=>{var o;const a=sDe(n.label),s=lDe(n.label);return m.jsx("div",{className:Pe(r.option,{[r.optionIsActive]:a&&n.active,"react-tags__listbox-option--not-selectable":!a}),...i,children:a?m.jsxs(m.Fragment,{children:[!s&&m.jsx(Sz,{tag:`${n.label}`,colorGenerator:e}),s?m.jsxs("i",{children:['Add "',wz(((o=t.current)==null?void 0:o.input.value)??""),'"']}):n.label]}):m.jsx("i",{children:n.label})})},Cz=({selectedTags:e,onChange:t,placeholder:n,tags:r,immutable:i=!1})=>{const{ColorGenerator:o}=It(Cz),a=jr("shortUrlCreation"),s=(a==null?void 0:a.tagFilteringMode)??"startsWith",l=ca();return m.jsx(Vde,{ref:l,selected:e.map(w$),suggestions:r.filter(u=>!e.includes(u)).map(w$),renderTag:uDe(o),renderOption:cDe(o,l),activateFirstOption:!0,allowNew:!i,newOptionText:Pz,noOptionsText:Ez,placeholderText:n??"Add tags to the URL",delimiterKeys:["Enter",","],suggestionsTransform:(u,f)=>{const d=u.toLowerCase().trim();return d.length<1?[]:[...f.filter(({label:h})=>s==="includes"?h.includes(d):h.startsWith(d))].slice(0,5)},onDelete:u=>{const f=[...e];f.splice(u,1),t(f)},onAdd:({label:u})=>t([...new Set([...e,...u.split(",").map(wz)])])})},fDe=Dt(Cz,["ColorGenerator"]),iE="shlink/tagDelete",dDe={deleting:!1,deleted:!1,error:!1},Tz=mn(`${iE}/tagDeleted`),hDe=e=>{const t=gn(`${iE}/deleteTag`,async r=>{await e().deleteTags([r])}),{reducer:n}=nn({name:iE,initialState:dDe,reducers:{},extraReducers:r=>{r.addCase(t.pending,()=>({deleting:!0,deleted:!1,error:!1})),r.addCase(t.rejected,(i,{error:o})=>({deleting:!1,deleted:!1,error:!0,errorData:Yr(o)})),r.addCase(t.fulfilled,()=>({deleting:!1,deleted:!0,error:!1}))}});return{reducer:n,deleteTag:t}},zT="shlink/tagEdit",pDe={editing:!1,edited:!1,error:!1},jz=mn(`${zT}/tagEdited`),mDe=(e,t)=>gn(`${zT}/editTag`,async({oldName:n,newName:r,color:i})=>(await e().editTag(n,r),t.setColorForKey(r,i),{oldName:n,newName:r,color:i})),vDe=e=>nn({name:zT,initialState:pDe,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:Yr(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>{const{oldName:i,newName:o}=r;return{oldName:i,newName:o,editing:!1,edited:!0,error:!1}})}}),VT="shlink/tagsList",Sx={tags:[],filteredTags:[],stats:{},loading:!1,error:!1},O$=(e,t)=>n=>n===e?t:n,S$=(e,t)=>e.filter(n=>n!==t),gDe=(e,t)=>e.reduce((n,[r,i])=>{if(!n[r])return n;const{bots:o,nonBots:a}=i,s=n[r];return{...n,[r]:{...s,visitsSummary:s.visitsSummary&&{total:s.visitsSummary.total+o+a,bots:s.visitsSummary.bots+o,nonBots:s.visitsSummary.nonBots+a},visitsCount:(s.visitsCount??0)+o+a}}},{...t}),yDe=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),{})),bDe=e=>gn(`${VT}/listTags`,async()=>{const{data:t}=await e().tagsStats(),n=t.reduce((r,{tag:i,...o})=>(r[i]=o,r),{});return{tags:Object.keys(n),stats:n}}),Az=mn(`${VT}/filterTags`),_De=(e,t)=>nn({name:VT,initialState:Sx,reducers:{},extraReducers:n=>{n.addCase(Az,(r,{payload:i})=>({...r,filteredTags:r.tags.filter(o=>o.toLowerCase().match(i.toLowerCase()))})),n.addCase(e.pending,r=>({...r,loading:!0,error:!1})),n.addCase(e.rejected,(r,{error:i})=>({...Sx,error:!0,errorData:Yr(i)})),n.addCase(e.fulfilled,(r,{payload:i})=>({...Sx,stats:i.stats,tags:i.tags,filteredTags:i.tags})),n.addCase(Tz,({tags:r,filteredTags:i,...o},{payload:a})=>({...o,tags:S$(r,a),filteredTags:S$(i,a)})),n.addCase(jz,({tags:r,filteredTags:i,stats:o,...a},{payload:s})=>({...a,stats:{...o,[s.newName]:o[s.oldName]},tags:r.map(O$(s.oldName,s.newName)).sort(),filteredTags:i.map(O$(s.oldName,s.newName)).sort()})),n.addCase(_f,(r,{payload:i})=>({...r,stats:gDe(yDe(i.createdVisits),r.stats)})),n.addCase(t.fulfilled,({tags:r,...i},{payload:o})=>({...i,tags:r.concat(o.tags.filter(a=>!r.includes(a)))}))}}),xDe={tag:"Tag",shortUrls:"Short URLs",visits:"Visits"},kz=Ki(({filterTags:e,tagsList:t})=>{var n,r;const{TagsTable:i}=It(kz),o=pC(),[a,s]=R.useState(((n=o.tags)==null?void 0:n.defaultOrdering)??{}),l=R.useMemo(()=>{const f=t.filteredTags.map(d=>{var h,v,g;const y=t.stats[d],x=((h=o.visits)!=null&&h.excludeBots?(v=y==null?void 0:y.visitsSummary)==null?void 0:v.nonBots:(g=y==null?void 0:y.visitsSummary)==null?void 0:g.total)??(y==null?void 0:y.visitsCount)??0;return{tag:d,visits:x,shortUrls:(y==null?void 0:y.shortUrlsCount)??0}});return F8(f,a)},[a,(r=o.visits)==null?void 0:r.excludeBots,t.filteredTags,t.stats]),u=jT();return t.loading?m.jsx(ta,{loading:!0}):t.error?m.jsx(ur,{type:"error",children:m.jsx(So,{errorData:t.errorData,fallbackMessage:"Error loading tags :("})}):m.jsxs(TT,{value:u,children:[m.jsx(Up,{className:"mb-3",onChange:e}),m.jsx(rr,{className:"mb-3",children:m.jsx("div",{className:"col-lg-6 offset-lg-6",children:m.jsx(zp,{items:xDe,order:a,onChange:(f,d)=>s({field:f,dir:d})})})}),m.jsx(AT,{type:"tags",className:"mb-3"}),m.jsx(i,{sortedTags:l,currentOrder:a,orderByColumn:f=>()=>{const d=sb(f,a.field,a.dir);s({field:d?f:void 0,dir:d})}})]})},()=>[fr.visits]),wDe=Dt(kz,["TagsTable"]),WT=({pagesCount:e,currentPage:t,setCurrentPage:n,centered:r=!0})=>{if(e<2)return null;const i=o=>()=>!xp(o)&&n(o);return m.jsxs(HP,{listClassName:Pe("flex-wrap mb-0 simple-paginator",{"justify-content-center":r}),children:[m.jsx(cl,{disabled:t<=1,children:m.jsx(fl,{previous:!0,tag:"span",onClick:i(t-1)})}),vz(t,e).map((o,a)=>m.jsx(cl,{disabled:xp(o),active:t===o,children:m.jsx(fl,{role:"link",tag:"span",onClick:i(o),children:gz(o)})},yz(o,a))),m.jsx(cl,{disabled:t>=e,children:m.jsx(fl,{next:!0,tag:"span",onClick:i(t+1)})})]})},ODe=20,Nz=({sortedTags:e,orderByColumn:t,currentOrder:n})=>{const{TagsTableRow:r}=It(Nz),i=R.useRef(!0),{page:o=1}=Bp(),[a,s]=$$e("page",Number(o)),l=Ku(e,ODe),u=l.length>1,f=l[a-1]??[];return R.useEffect(()=>{!i.current&&s(1),i.current=!1},[s,e]),R.useEffect(()=>{scrollTo(0,0)},[a]),m.jsxs(Ot,{bodyClassName:u?"pb-1":"",children:[m.jsxs("table",{className:"table table-hover responsive-table mb-0",children:[m.jsxs("thead",{className:"responsive-table__header",children:[m.jsxs("tr",{children:[m.jsxs("th",{className:"tags-table__header-cell",onClick:t("tag"),children:["Tag ",m.jsx(Xd,{currentOrder:n,field:"tag"})]}),m.jsxs("th",{className:"tags-table__header-cell text-lg-end",onClick:t("shortUrls"),children:["Short URLs ",m.jsx(Xd,{currentOrder:n,field:"shortUrls"})]}),m.jsxs("th",{className:"tags-table__header-cell text-lg-end",onClick:t("visits"),children:["Visits ",m.jsx(Xd,{currentOrder:n,field:"visits"})]}),m.jsx("th",{className:"tags-table__header-cell",children:m.jsx("span",{className:"sr-only",children:"Options"})})]}),m.jsx("tr",{children:m.jsx("th",{"aria-hidden":!0,colSpan:4,className:"p-0 border-top-0"})})]}),m.jsxs("tbody",{children:[f.length===0&&m.jsx("tr",{children:m.jsx("td",{colSpan:4,className:"text-center",children:"No tags found"})}),f.map(d=>m.jsx(r,{tag:d},d.tag))]})]}),u&&m.jsx("div",{className:"sticky-card-paginator",children:m.jsx(WT,{pagesCount:l.length,currentPage:a,setCurrentPage:s})})]},a)},SDe=Dt(Nz,["TagsTableRow"]),Mz=({tag:e})=>{const{DeleteTagConfirmModal:t,EditTagModal:n,ColorGenerator:r}=It(Mz),[i,o]=Zt(),[a,s]=Zt(),l=Ss(),u=r1();return m.jsxs("tr",{className:"responsive-table__row",children:[m.jsxs("th",{className:"responsive-table__cell","data-th":"Tag",children:[m.jsx(Sz,{tag:e.tag,colorGenerator:r})," ",e.tag]}),m.jsx("td",{className:"responsive-table__cell text-lg-end","data-th":"Short URLs",children:m.jsx(Pt,{to:`${l}/list-short-urls/1?tags=${encodeURIComponent(e.tag)}`,children:Yt(e.shortUrls)})}),m.jsx("td",{className:"responsive-table__cell text-lg-end","data-th":"Visits",children:m.jsx(Pt,{to:`${l}/tag/${e.tag}/visits`,children:Yt(e.visits)})}),m.jsx("td",{className:"responsive-table__cell text-lg-end",children:m.jsxs(ab,{children:[m.jsxs(Ne,{onClick:s,children:[m.jsx(je,{icon:ID,fixedWidth:!0,className:"me-1"})," Edit"]}),m.jsxs(Ne,{disabled:!u||!u.canAddItemWithName(e.tag),onClick:()=>u==null?void 0:u.addItemToCompare({name:e.tag,query:e.tag,style:r.stylesForKey(e.tag)}),children:[m.jsx(je,{icon:Z0,fixedWidth:!0})," Compare visits"]}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsxs(Ne,{className:"dropdown-item--danger",onClick:o,children:[m.jsx(je,{icon:OZ,fixedWidth:!0,className:"me-1"})," Delete tag"]})]})}),m.jsx(n,{tag:e.tag,toggle:s,isOpen:a}),m.jsx(t,{tag:e.tag,toggle:o,isOpen:i})]})},EDe=Dt(Mz,["DeleteTagConfirmModal","EditTagModal","ColorGenerator"]),PDe=(e,t)=>{e.factory("TagsSelector",fDe),e.serviceFactory("DeleteTagConfirmModal",()=>iDe),e.decorator("DeleteTagConfirmModal",t(["tagDelete"],["deleteTag","tagDeleted"])),e.factory("EditTagModal",oDe),e.decorator("EditTagModal",t(["tagEdit"],["editTag","tagEdited"])),e.factory("TagsTableRow",EDe),e.factory("TagsTable",SDe),e.factory("TagsList",wDe),e.decorator("TagsList",t(["tagsList","mercureInfo"],["filterTags","createNewVisits","loadMercureInfo"])),e.serviceFactory("tagEditReducerCreator",vDe,"editTag"),e.serviceFactory("tagEditReducer",n=>n.reducer,"tagEditReducerCreator"),e.serviceFactory("tagDeleteReducerCreator",hDe,"apiClientFactory"),e.serviceFactory("tagDeleteReducer",n=>n.reducer,"tagDeleteReducerCreator"),e.serviceFactory("tagsListReducerCreator",_De,"listTags","createShortUrl"),e.serviceFactory("tagsListReducer",n=>n.reducer,"tagsListReducerCreator"),e.serviceFactory("listTags",bDe,"apiClientFactory"),e.serviceFactory("filterTags",()=>Az),e.serviceFactory("deleteTag",n=>n.deleteTag,"tagDeleteReducerCreator"),e.serviceFactory("tagDeleted",()=>Tz),e.serviceFactory("editTag",mDe,"apiClientFactory","ColorGenerator"),e.serviceFactory("tagEdited",()=>jz)},CDe=new jF,TDe=e=>CDe.parse(e),jDe=6,E$="0123456789ABCDEF",ADe=128,{floor:kDe,random:NDe,sqrt:MDe,round:RDe}=Math,LDe=()=>`#${$T(jDe,()=>E$[kDe(NDe()*E$.length)]).join("")}`,P$=e=>e.toLowerCase().trim(),$De=e=>(e.match(/../g)??[]).map(t=>parseInt(t,16)||0),IDe=(e=0,t=0,n=0)=>RDe(MDe(.299*e**2+.587*t**2+.114*n**2));class DDe{constructor(t){Ja(this,"colors"),Ja(this,"lights");var n;this.storage=t,this.colors=((n=this.storage)==null?void 0:n.getTagColors())??{},this.lights={}}getColorForKey(t){const n=P$(t);return this.colors[n]||this.setColorForKey(n,LDe())}setColorForKey(t,n){var r;const i=P$(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);if(this.lights[n]===void 0){const r=$De(n);this.lights[n]=IDe(...r)>=ADe}return this.lights[n]}}const Rz=({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)},FDe=(e,t,n)=>{const r=new Blob([t],{type:"text/csv;charset=utf-8;"}),i=URL.createObjectURL(r);Rz(e,i,n)};class BDe{constructor(t,n){this.fetch=t,this.window=n}async saveImage(t,n){const r=await this.fetch(t).then(o=>o.blob()),i=URL.createObjectURL(r);Rz(this.window,i,n)}}class UDe{constructor(t,n){Ja(this,"exportVisits",(r,i)=>{i.length&&this.exportCsv(r,i)}),Ja(this,"exportShortUrls",r=>{r.length&&this.exportCsv("short_urls.csv",r)}),Ja(this,"exportCsv",(r,i)=>{const o=this.jsonToCsv(i);FDe(this.window,o,r)}),this.window=t,this.jsonToCsv=n}}function zDe(e){e.constant("window",window),e.constant("fetch",window.fetch.bind(window)),e.service("ImageDownloader",BDe,"fetch","window"),e.service("ColorGenerator",DDe,"TagColorsStorage"),e.constant("jsonToCsv",TDe),e.service("ReportExporter",UDe,"window","jsonToCsv"),e.serviceFactory("useTimeoutToggle",()=>L8)}const am=({visits:e,shortUrl:t,children:n,title:r})=>m.jsx("header",{children:m.jsxs(Pr,{body:!0,children:[m.jsxs("h2",{className:"d-flex justify-content-between align-items-center mb-0",children:[m.jsx(u1,{}),m.jsx("span",{className:"text-center d-none d-sm-block",children:m.jsx("small",{children:r})}),m.jsxs("span",{className:"badge badge-main ms-3",children:["Visits:"," ",m.jsx(az,{visitsCount:e.length,shortUrl:t})]})]}),m.jsx("h3",{className:"text-center d-block d-sm-none mb-0 mt-3",children:m.jsx("small",{children:r})}),n&&m.jsx("div",{className:"mt-md-2",children:n})]})}),Lz=({title:e,footer:t,children:n})=>m.jsxs(Pr,{role:"document",children:[m.jsx(mc,{className:"chart-card__header",children:e}),m.jsx(pc,{children:n}),t&&m.jsx(e8,{className:"chart-card__footer--sticky",children:t})]}),$z={color:"white",background:"rgb(0 0 0 / .9)",border:"none",borderRadius:"5px"},VDe={marginBottom:"5px",fontWeight:"bold"},Iz={contentStyle:$z,labelStyle:VDe,itemStyle:{padding:0}},C$=["#97BBCD","#F7464A","#46BFBD","#FDB45C","#949FB1","#57A773","#414066","#08B2E3","#B6C454","#DCDCDC","#463730"],Dz=e=>C$[e%C$.length],E0="#46e587",WDe="rgba(70, 229, 135, 0.4)",HDe=({chartData:e,showNumbers:t})=>m.jsx("ul",{className:"doughnut-chart-legend",children:e.map(({name:n,color:r,value:i})=>m.jsxs("li",{className:"doughnut-chart-legend__item d-flex",children:[m.jsx("div",{className:"doughnut-chart-legend__item-color",style:{backgroundColor:r}}),m.jsxs("small",{className:"doughnut-chart-legend__item-text flex-fill",children:[n,t&&m.jsxs("b",{children:[" (",Yt(i),")"]})]})]},n))}),T$=e=>R.useMemo(()=>Object.entries(e).map(([t,n],r)=>({name:t,value:n,color:Dz(r)})),[e]),GDe=({stats:e,prevStats:t,showNumbersInLegend:n,dimensions:r})=>{const i=T$(e),o=T$(t),a=o.length>0,s=tC()?ple:hle;return m.jsxs("div",{className:"row align-items-center",children:[m.jsx("div",{className:"col-sm-12 col-md-7",children:m.jsx("div",{style:r??{width:"100%",height:300},children:m.jsx(r?R.Fragment:zC,{children:m.jsxs(N4e,{...r,children:[m.jsx(ii,{formatter:Yt,contentStyle:$z,itemStyle:{color:"white"}}),m.jsx(Oo,{data:i,dataKey:"value",nameKey:"name",startAngle:360,endAngle:0,outerRadius:"100%",innerRadius:a?"65%":"50%",animationBegin:0,children:i.map((l,u)=>m.jsx(Za,{fill:l.color,stroke:s},`${l.name}-${u}`))}),a&&m.jsx(Oo,{data:o,dataKey:"value",nameKey:"name",startAngle:360,endAngle:0,outerRadius:"55%",innerRadius:"20%",animationBegin:0,stroke:s,fill:E0})]})})})}),m.jsx("div",{className:"col-sm-12 col-md-5",children:m.jsx(HDe,{chartData:i,showNumbers:n})})]})},j$=({title:e,...t})=>{const[n,r]=Zt(!1);return m.jsx(Lz,{title:m.jsxs(m.Fragment,{children:[e,m.jsx("div",{className:"float-end",children:m.jsx(El,{checked:n,onChange:r,children:"Show numbers"})})]}),children:m.jsx(GDe,{...t,showNumbersInLegend:n})})},qDe=({visitsGroups:e})=>{const t=R.useMemo(()=>Object.entries(e),[e]);return t.length===0?null:m.jsx("ul",{className:"list-unstyled mb-0 mt-2 d-flex flex-wrap justify-content-center gap-3",children:t.map(([n,r],i)=>m.jsxs("li",{className:"d-inline",children:[m.jsx(Oz,{color:Fz(r)}),m.jsxs("strong",{children:[n," (",Yt(r.length),")"]})]},`${n}${i}`))})},KDe={monthly:"Month",weekly:"Week",daily:"Day",hourly:"Hour"},YDe={hourly:e=>({hours:e}),daily:e=>({days:e}),weekly:e=>({weeks:e}),monthly:e=>({months:e})},ZDe={hourly:zue,daily:Vp,weekly:Gue,monthly:yy},HT={hourly:e=>by(e,"yyyy-MM-dd HH:00"),daily:e=>Ba(e),weekly(e){const t=Ba(Rh(e)),n=Ba(Yue(e));return`${t} - ${n}`},monthly:e=>by(e,"yyyy-MM")},XDe=e=>{var t;const n=Object.values(e).filter(a=>a.length>0);if(n.length===0)return"monthly";const r=new Date,i=n.map(a=>as(a[a.length-1].date)),o=fF(i);return((t=[[()=>Vp(r,o)<=2,"hourly"],[()=>yy(r,o)<=1,"daily"],[()=>yy(r,o)<=6,"weekly"]].find(([a])=>a()))==null?void 0:t[1])??"monthly"},QDe=(e,t)=>Object.keys(t).reduce((n,r)=>(n[r]=oF(t[r],i=>HT[e](as(i.date))),n),{}),JDe=(e,t)=>t.reduce((n,r)=>{const i=HT[e](as(r.date));return n[i]=n[i]??[],n[i].push(r),n},{}),e5e=(e,t)=>{const n=Object.values(t).filter(d=>d.length>0).map(d=>[...d].reverse());if(n.length===0)return[];const r=ZDe[e],i=HT[e],o=YDe[e],a=n.map(d=>as(d[0].date)),s=n.map(d=>as(d[d.length-1].date)),l=fF(s),u=Due(a),f=r(l,u)+1;return[i(u),...$T(f,d=>i(Rue(u,o(d))))]},Fz=e=>{if(e.color)return e.color;const t={main:jh,highlighted:cO,previous:E0};return e.type?t[e.type]:jh},A$=(e,t)=>R.useMemo(()=>Object.values(e).find(n=>n.type===t)??[],[e,t]),t5e=(e,t,n)=>{const r=A$(e,"main"),i=A$(e,"highlighted"),o=R.useMemo(()=>n?JDe(t,r):{},[n,t,r]),a=R.useCallback((s,{payload:l})=>{const u=o[l.date]??[];n==null||n(u===i?[]:u)},[o,i,n]);return n&&{cursor:"pointer",onClick:a}},Bz=({visitsGroups:e,setSelectedVisits:t,dimensions:n,matchMedia:r})=>{const[i,o]=R.useState(XDe(e)),a=DT(767,r??window.matchMedia),s=R.useMemo(()=>{const d=QDe(i,e),h=Object.keys(d);return e5e(i,e).map(v=>({date:v,...h.reduce((g,y)=>(g[y]=d[y][v]??0,g),{})}))},[i,e]),l=t5e(e,i,t),u=n?R.Fragment:zC,f=R.useMemo(()=>n?{}:{width:"100%",height:a?300:400},[n,a]);return m.jsxs(Pr,{children:[m.jsxs(mc,{role:"heading","aria-level":4,children:["Visits over time",m.jsx("div",{className:"float-end",children:m.jsxs(Ip,{children:[m.jsx(Zc,{caret:!0,color:"link",className:"btn-sm p-0",children:"Group by"}),m.jsx(Yc,{end:!0,children:Object.entries(KDe).map(([d,h])=>m.jsx(Ne,{active:i===d,onClick:()=>o(d),children:h},d))})]})})]}),m.jsxs(pc,{children:[m.jsx(u,{...f,children:m.jsxs(k4e,{data:s,...n,children:[m.jsx(yf,{dataKey:"date"}),m.jsx(bf,{tickFormatter:Yt}),m.jsx(ii,{formatter:Yt,...Iz}),m.jsx(OT,{strokeOpacity:tC()?.1:.9}),Object.entries(e).map(([d,h])=>h.length>0&&m.jsx(gf,{dataKey:d,type:"monotone",stroke:Fz(h),strokeWidth:2,activeDot:h.type==="previous"?void 0:l,strokeDasharray:h.type==="previous"?"8 3":void 0},d))]})}),m.jsx(qDe,{visitsGroups:e})]})]})},n5e=({toggleClassName:e,ranges:t,value:n,setValue:r})=>m.jsxs(Ip,{children:[m.jsx(Zc,{caret:!0,color:"link",className:e,children:"Paginate"}),m.jsxs(Yc,{end:!0,children:[t.map(i=>m.jsxs(Ne,{active:i===n,onClick:()=>r(i),children:[m.jsx("b",{children:i})," items per page"]},i)),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsx(Ne,{disabled:n===1/0,onClick:()=>r(1/0),children:m.jsx("i",{children:"Clear pagination"})})]})]}),k$=e=>e.startsWith("hidden_"),r5e=({stats:e,prevStats:t,highlightedStats:n,highlightedLabel:r,max:i,onClick:o,dimensions:a})=>{const s=R.useMemo(()=>Object.entries(e).map(([d,h])=>{const v=(n==null?void 0:n[d])??0,g=(t==null?void 0:t[d])??0,y=k$(d);return{name:d,amount:Math.max(h,g),nonHighlightedAmount:y?null:h-v,highlightedAmount:y?null:v,prevAmount:y?null:g}}),[e,t,n]),l=R.useMemo(()=>{const d=s.reduce((h,{name:v})=>h>v.length?h:v.length,0);return Math.min(150,d*7)},[s]),u=a?R.Fragment:zC,f=R.useMemo(()=>a?{}:{width:"100%",height:Math.max(300,s.length*(t?44:22))},[a,s.length,t]);return m.jsx(u,{...f,children:m.jsxs(M4e,{layout:"vertical",data:s,barCategoryGap:3,...a,children:[m.jsx(yf,{type:"number",dataKey:"amount",tickFormatter:Yt,domain:i?[0,i]:void 0}),m.jsx(bf,{type:"category",dataKey:"name",width:l,interval:0,style:{fontSize:".8rem"},tickFormatter:d=>k$(d)?"":d}),m.jsx(OT,{strokeOpacity:tC()?.05:.9}),m.jsx(ii,{filterNull:!0,...Iz,formatter:(d,h)=>[Yt(d),h==="highlightedAmount"?r:h==="prevAmount"?"Previous period":n?"Non-selected":"Visits"]}),m.jsx(Go,{dataKey:"nonHighlightedAmount",stackId:"main",cursor:"pointer",fill:jh,onClick:({name:d})=>o==null?void 0:o(d),children:s.map(d=>m.jsx(Za,{fill:fle,stroke:jh,strokeWidth:2},d.name))}),n&&m.jsx(Go,{dataKey:"highlightedAmount",stackId:"main",cursor:"pointer",fill:cO,onClick:({name:d})=>o==null?void 0:o(d),children:s.map(d=>m.jsx(Za,{fill:dle,stroke:cO,strokeWidth:2},d.name))}),t&&m.jsx(Go,{dataKey:"prevAmount",fill:E0,children:s.map(d=>m.jsx(Za,{fill:WDe,stroke:E0,strokeWidth:2},d.name))})]})})},i5e=e=>typeof e=="string"?e.toLowerCase():e,o5e=([e])=>e,a5e=([,e])=>e,jv=({stats:e,prevStats:t,highlightedStats:n,title:r,sortingItems:i,extraHeaderContent:o,withPagination:a=!0,...s})=>{const[l,u]=R.useState({}),[f,d]=R.useState(1),[h,v]=R.useState(50),g=R.useCallback((A,D)=>{const k=Object.entries(A),I=l.field?Nue(k,([F,q])=>i5e(l.field===Object.keys(D)[0]?F:q)):k;return!l.dir||l.dir==="ASC"?I:[...I].reverse()},[l.dir,l.field]),y=R.useCallback(A=>{const D=A[f-1];if(f[`hidden_${I}`,0])]},[f]),x=R.useCallback(A=>m.jsx(WT,{currentPage:f,pagesCount:A,setCurrentPage:d}),[f]),_=R.useCallback((A,D,k,I)=>{const F=g(A,D),q=F.map(o5e),W=k&&Object.entries({...EN(q,q.map(()=>0)),...k}),X=I&&Object.entries({...EN(q,q.map(()=>0)),...I});if(F.length<=h)return{currentPageStats:Object.fromEntries(F),currentPageHighlightedStats:W&&Object.fromEntries(W),currentPagePrevStats:X&&Object.fromEntries(X)};const Q=Ku(F,h),ne=W&&Ku(W,h),Z=X&&Ku(X,h);return{currentPageStats:Object.fromEntries(y(Q)),currentPageHighlightedStats:ne&&Object.fromEntries(y(ne)),currentPagePrevStats:Z&&Object.fromEntries(y(Z)),pagination:x(Q.length),max:rIe(Math.max(...F.map(a5e)))}},[y,g,h,x]),{currentPageStats:b,currentPagePrevStats:w,currentPageHighlightedStats:S,pagination:E,max:P}=R.useMemo(()=>_(e,i,n&&Object.keys(n).length>0?n:void 0,t&&Object.keys(t).length>0?t:void 0),[_,n,t,i,e]),T=R.useMemo(()=>Object.keys(b),[b]);return m.jsx(Lz,{title:m.jsxs(m.Fragment,{children:[r,m.jsx("div",{className:"float-end",children:m.jsx(zp,{isButton:!1,right:!0,items:i,order:l,onChange:(A,D)=>{u({field:A,dir:D}),d(1)}})}),a&&Object.keys(e).length>50&&m.jsx("div",{className:"float-end",children:m.jsx(n5e,{toggleClassName:"btn-sm p-0 me-3",ranges:[50,100,200,500],value:h,setValue:A=>{v(A),d(1)}})}),o&&m.jsx("div",{className:"float-end",children:o(E?T:void 0)})]}),footer:E,children:m.jsx(r5e,{stats:b,prevStats:w,highlightedStats:S,max:P,...s})})},N$=(e,t)=>{if(!(!t||!(e in t)))return t[e]&&cs(t[e])||""},Uz=()=>{const e=Eo(),t=Bp(),{startDate:n,endDate:r,orphanVisitsType:i,excludeBots:o,loadPrevInterval:a,...s}=t,l=R.useMemo(()=>({dateRange:n!=null||r!=null?b9(n,r):void 0,visitsFilter:{orphanVisitsType:i,excludeBots:o!==void 0?o==="true":void 0},loadPrevInterval:a!==void 0?a==="true":void 0}),[r,o,a,i,n]),u=R.useCallback(f=>{const{dateRange:d,visitsFilter:h={},loadPrevInterval:v}=db(l,f),{excludeBots:g,orphanVisitsType:y}=h,x={...s,startDate:N$("startDate",d),endDate:N$("endDate",d),excludeBots:g===void 0?void 0:JS(g),orphanVisitsType:y,loadPrevInterval:v===void 0?void 0:JS(v)},_=ob(x),b=_?`?${_}`:"";e(b,{replace:!0,relative:"route"})},[l,e,s]);return[l,u]},s5e=()=>m.jsx(Z4e,{attribution:'© OpenStreetMap contributors',url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"}),l5e=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}},zz=({toggle:e,isOpen:t,title:n,locations:r=[]})=>m.jsx(Po,{toggle:e,isOpen:t,className:"map-modal__modal",contentClassName:"map-modal__modal-content",children:m.jsxs(Wi,{className:"map-modal__modal-body",children:[m.jsxs("h3",{className:"map-modal__modal-title",children:[n,m.jsx("button",{type:"button",className:"btn-close float-end","aria-label":"Close",onClick:e})]}),m.jsxs(q4e,{...l5e(r),children:[m.jsx(s5e,{}),r.map(({cityName:i,latLong:o,count:a},s)=>m.jsx(K4e,{position:o,children:m.jsxs(Y4e,{children:[m.jsx("b",{children:a})," visit",a>1?"s":""," from ",m.jsx("b",{children:i})]})},s))]})]})}),u5e=({modalTitle:e,activeCities:t,locations:n=[]})=>{const[r,,i,o]=Zt(),[a,s]=Zt(),[l,u]=R.useState([]),f=eC(),d=R.useCallback(h=>{u(h?n.filter(h):n),i()},[n,i]);return m.jsxs(m.Fragment,{children:[!t&&m.jsx(Ye,{color:"link",className:"open-map-modal-btn__btn",id:f,onClick:()=>d(),"aria-label":"Show in map",children:m.jsx(je,{icon:Ew})}),t&&m.jsxs(Rp,{isOpen:a,toggle:s,children:[m.jsx(Zc,{color:"link",className:"open-map-modal-btn__btn",id:f,children:m.jsx(je,{icon:Ew})}),m.jsxs(Yc,{end:!0,children:[m.jsx(Ne,{onClick:()=>d(),children:"Show all locations"}),m.jsx(Ne,{onClick:()=>d(({cityName:h})=>t.includes(h)),children:"Show locations in current page"})]})]}),m.jsx(Tr,{placement:"left",target:f,children:"Show in map"}),m.jsx(zz,{toggle:o,isOpen:r,title:e,locations:l})]})},Vz=({onChange:e,selected:t={},className:n,isOrphanVisits:r=!1,withPrevInterval:i=!1,disabled:o})=>{const{orphanVisitsType:a,excludeBots:s=!1,loadPrevInterval:l=!1}=t,u=h=>({active:a===h,onClick:()=>e({...t,orphanVisitsType:h===a?void 0:h})}),f=R.useCallback(()=>e({...t,excludeBots:!s}),[s,e,t]),d=R.useCallback(()=>e({...t,loadPrevInterval:!l}),[l,e,t]);return m.jsxs(fa,{disabled:o,text:"More",dropdownClassName:n,end:!0,minWidth:250,children:[i&&m.jsxs(m.Fragment,{children:[m.jsx(Ne,{active:l,onClick:d,children:"Compare with previous period"}),m.jsx(Ne,{divider:!0,tag:"hr"})]}),m.jsx(Ne,{header:!0,"aria-hidden":!0,children:"Bots:"}),m.jsx(Ne,{active:s,onClick:f,children:"Exclude potential bots"}),r&&m.jsxs(m.Fragment,{children:[m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsx(Ne,{header:!0,"aria-hidden":!0,children:"Orphan visits type:"}),m.jsx(Ne,{...u("base_url"),children:"Base URL"}),m.jsx(Ne,{...u("invalid_short_url"),children:"Invalid short URL"}),m.jsx(Ne,{...u("regular_404"),children:"Regular 404"})]}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsx(Ne,{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:m.jsx("i",{children:"Reset to defaults"})})]})},Wz=({info:e})=>{const{loading:t,errorData:n,progress:r}=e;return m.jsxs(m.Fragment,{children:[t&&r===null&&m.jsx(ta,{loading:!0}),t&&r!==null&&m.jsxs(ta,{loading:!0,children:["This is going to take a while... :S",m.jsx(o8,{value:r,striped:r>=100,className:"mt-3"})]}),n&&m.jsx(ur,{type:"error",children:m.jsx(So,{errorData:n,fallbackMessage:"An error occurred while loading visits :("})})]})},og=({children:e,showFallback:t})=>m.jsxs(m.Fragment,{children:[t&&m.jsx(ta,{className:"mt-3",children:"There are no visits matching current filter"}),!t&&m.jsx(m.Fragment,{children:e})]}),c5e=({visitsDeletion:e,deleteVisits:t})=>{const{deleting:n}=e,[r,,i]=Zt();return m.jsx(Ot,{title:m.jsx("span",{className:"text-danger fw-bold",children:"Danger zone"}),children:m.jsxs("div",{className:"d-flex justify-content-between align-items-center",children:[m.jsxs("dl",{className:"m-0 me-3",children:[m.jsx("dt",{children:"Delete visits."}),m.jsxs("dd",{className:"m-0",children:["This will delete ",m.jsx("b",{children:"all"})," visits, not only the ones matching current filter."]})]}),!r&&m.jsx(Ye,{color:"danger",className:"indivisible",onClick:i,children:"Delete visits"}),r&&m.jsxs(Ye,{color:"danger",disabled:n,className:"indivisible",onClick:t,innerRef:o=>{o==null||o.focus()},children:[!n&&m.jsx(m.Fragment,{children:"Click again to confirm"}),n&&m.jsx(m.Fragment,{children:"Deleting..."})]})]})})},Av="Others",f5e=["Android Browser","Chrome","Chromium","Firefox","Internet Explorer","Microsoft Edge","Opera","Safari","Samsung Internet for Android","Vivaldi","WeChat"],d5e=e=>{if(!Ks(e))return{browser:Av,os:Av};const{browser:{name:t},os:{name:n}}=n$e.parse(e);return{os:n??Av,browser:t&&f5e.includes(t)?t:Av}},h5e=e=>{var t;return Ks(e)?((t=e.split("/")[e.includes("://")?2:0])==null?void 0:t.split(":")[0])??"":"Direct"},Hz=(e,t)=>e[t]!==void 0,M$=e=>typeof e=="number"?e:e?parseFloat(e):0,p5e=(e,{os:t})=>{e[t]=(e[t]||0)+1},m5e=(e,{browser:t})=>{e[t]=(e[t]||0)+1},v5e=(e,{referer:t})=>{e[t]=(e[t]||0)+1},Gz=e=>(t,n)=>{const r=Hz(n,e)?n[e]:"Unknown";t[r]=(t[r]||0)+1},g5e=Gz("country"),y5e=Gz("city"),b5e=(e,t)=>{if(!Hz(t,"city")||t.city==="Unknown")return;const{city:n,latitude:r,longitude:i}=t,o=e[n]||{cityName:n,count:0,latLong:[M$(r),M$(i)]};o.count+=1,e[n]=o},_5e=(e,t)=>{if(!_$e(t))return;const{visitedUrl:n}=t;e[n]=(e[n]||0)+1},oE=e=>e.reduce((t,n)=>(p5e(t.os,n),m5e(t.browsers,n),v5e(t.referrers,n),g5e(t.countries,n),y5e(t.cities,n),b5e(t.citiesForMap,n),_5e(t.visitedUrls,n),t),{os:{},browsers:{},referrers:{},countries:{},cities:{},citiesForMap:{},visitedUrls:{}}),P0=e=>e.map(t=>{const{userAgent:n,date:r,referer:i,visitLocation:o,potentialBot:a}=t;return{date:r,potentialBot:a,...d5e(n),referer:h5e(i),country:(o==null?void 0:o.countryName)||"Unknown",city:(o==null?void 0:o.cityName)||"Unknown",latitude:o==null?void 0:o.latitude,longitude:o==null?void 0:o.longitude,visitedUrl:t.visitedUrl,type:LT(t)?t.type:void 0}}),x5e=Object.freeze(Object.defineProperty({__proto__:null,normalizeVisits:P0,processStatsFromVisits:oE},Symbol.toStringTag,{value:"Module"})),_d=20,w5e=({browser:e,os:t,referer:n,country:r,city:i,...o},a)=>`${e} ${t} ${n} ${r} ${i} ${o.visitedUrl}`.toLowerCase().includes(a.toLowerCase()),O5e=(e,t)=>t.filter(n=>w5e(n,e)),S5e=(e,t)=>F8(t,e),E5e=(e,t,n)=>{const r=t?O5e(t,e):[...e],i=S5e(n,r),o=i.length;return{visitsGroups:Ku(i,_d),total:o}},Ro="visits-table__header-cell visits-table__sticky",P5e=({visits:e,selectedVisits:t=[],setSelectedVisits:n,matchMedia:r=window.matchMedia})=>{var i;const o=DT(767,r),[a,s]=R.useState(void 0),l=R.useRef(a),[u,f]=R.useState({}),d=R.useMemo(()=>E5e(e,a,u),[e,a,u]),[h,v]=R.useState(1),g=h*_d,y=g-_d,x=R.useMemo(()=>{var S,E;return!!((E=(S=d.visitsGroups[h-1])==null?void 0:S[0])!=null&&E.visitedUrl)},[h,d.visitsGroups]),_=8+Number(x),b=S=>()=>f({field:S,dir:sb(S,u.field,u.dir)}),w=S=>m.jsx(Xd,{currentOrder:u,field:S,className:"visits-table__header-icon"});return R.useEffect(()=>{l.current!==a&&(v(1),n([])),l.current=a},[a,n]),m.jsx("div",{className:"table-responsive-md",children:m.jsxs("table",{className:"table table-bordered table-hover table-sm visits-table",children:[m.jsxs("thead",{className:"visits-table__header",children:[m.jsxs("tr",{children:[m.jsxs("th",{className:`${Ro} text-center`,onClick:()=>n(t.length0})})]}),m.jsxs("th",{className:`${Ro} text-center`,onClick:b("potentialBot"),children:[m.jsx("span",{className:"sr-only",children:"Is bot"}),m.jsx(je,{icon:Ok}),w("potentialBot")]}),m.jsxs("th",{className:Ro,onClick:b("date"),children:["Date",w("date")]}),m.jsxs("th",{className:Ro,onClick:b("country"),children:["Country",w("country")]}),m.jsxs("th",{className:Ro,onClick:b("city"),children:["City",w("city")]}),m.jsxs("th",{className:Ro,onClick:b("browser"),children:["Browser",w("browser")]}),m.jsxs("th",{className:Ro,onClick:b("os"),children:["OS",w("os")]}),m.jsxs("th",{className:Ro,onClick:b("referer"),children:["Referrer",w("referer")]}),x&&m.jsxs("th",{className:Ro,onClick:b("visitedUrl"),children:["Visited URL",w("visitedUrl")]})]}),m.jsx("tr",{children:m.jsx("td",{colSpan:_,className:"p-0",children:m.jsx(Up,{noBorder:!0,large:!1,onChange:s})})})]}),m.jsxs("tbody",{children:[d.total===0&&m.jsx("tr",{children:m.jsx("td",{colSpan:_,className:"text-center",children:"There are no visits matching current filter"})}),(i=d.visitsGroups[h-1])==null?void 0:i.map((S,E)=>{const P=t.includes(S);return m.jsxs("tr",{style:{cursor:"pointer"},className:Pe({"table-active":P}),onClick:()=>n(P?t.filter(T=>T!==S):[...t,S]),children:[m.jsx("td",{className:"text-center",children:P&&m.jsx(je,{icon:gh,className:"text-primary"})}),m.jsx("td",{className:"text-center",children:S.potentialBot&&m.jsxs(m.Fragment,{children:[m.jsx(je,{icon:Ok,id:`botIcon${E}`}),m.jsx(Tr,{placement:"right",target:`botIcon${E}`,children:"Potentially a visit from a bot or crawler"})]})}),m.jsx("td",{children:m.jsx(O0,{date:S.date})}),m.jsx("td",{children:S.country}),m.jsx("td",{children:S.city}),m.jsx("td",{children:S.browser}),m.jsx("td",{children:S.os}),m.jsx("td",{children:S.referer}),S.visitedUrl&&m.jsx("td",{children:S.visitedUrl})]},E)})]}),d.total>_d&&m.jsx("tfoot",{children:m.jsx("tr",{children:m.jsx("td",{colSpan:_,className:"visits-table__footer-cell visits-table__sticky",children:m.jsxs("div",{className:"row",children:[m.jsx("div",{className:"col-md-6",children:m.jsx(WT,{pagesCount:Math.ceil(d.total/_d),currentPage:h,setCurrentPage:v,centered:o})}),m.jsx("div",{className:Pe("col-md-6",{"d-flex align-items-center flex-row-reverse":!o,"text-center mt-3":o}),children:m.jsxs("div",{children:["Visits ",m.jsx("b",{children:Yt(y+1)})," to"," ",m.jsx("b",{children:Yt(Math.min(g,d.total))})," of"," ",m.jsx("b",{children:Yt(d.total)})]})})]})})})})]})})},Ea={byTime:{title:"By time",subPath:"by-time",icon:oZ},byContext:{title:"By context",subPath:"by-context",icon:hP},byLocation:{title:"By location",subPath:"by-location",icon:Ew},list:{title:"List",subPath:"list",icon:FD},options:{title:"Options",subPath:"options",icon:zD,shouldRender:({deletion:e})=>!!e}};Object.freeze(Ea);const Ex=({display:e})=>e&&m.jsx("div",{className:"mt-3 mx-auto w-75",children:m.jsx(Ot,{children:m.jsxs("div",{className:"d-flex gap-2",children:[m.jsx(je,{icon:iX,className:"mt-1"}),m.jsx("i",{children:"Could not calculate previous period because selected one does not have a strictly defined start date."})]})})});let kv;const sm=e=>{const{children:t,visitsInfo:n,getVisits:r,cancelGetVisits:i,deletion:o,exportCsv:a,isOrphanVisits:s=!1}=e,{visits:l,prevVisits:u,loading:f,errorData:d,fallbackInterval:h}=n,[{dateRange:v,visitsFilter:g,loadPrevInterval:y},x]=Uz(),_=jr("visits"),[b,w]=R.useState(),S=R.useCallback(({startDate:j,endDate:N},U)=>{x({dateRange:{startDate:j??void 0,endDate:N??void 0}}),w(U)},[x]),E=R.useRef(v??h??(_==null?void 0:_.defaultInterval)??"last30Days"),[P,T]=R.useState([]),[A,D]=R.useState(),k=R.useRef(!0),{search:I}=pr(),F=R.useCallback(j=>j?`${j}${I}`:I,[I]),q=R.useMemo(()=>P0(l),[l]),W=R.useMemo(()=>u&&P0(u),[u]),{os:X,browsers:Q,referrers:ne,countries:Z,cities:z,citiesForMap:B,visitedUrls:H}=R.useMemo(()=>oE(q),[q]),ee=R.useMemo(()=>oE(W??[]),[W]),K=R.useMemo(()=>Object.fromEntries([["Visits",Object.assign(q,{type:"main"})],W&&["Previous period",Object.assign(W,{type:"previous"})],P.length>0&&[A??"Selected",Object.assign(P,{type:"highlighted"})]].filter(Boolean)),[A,P,W,q]),te=R.useMemo(()=>({...g,excludeBots:g.excludeBots??(_==null?void 0:_.excludeBots),loadPrevInterval:y??(_==null?void 0:_.loadPrevInterval)}),[y,g,_==null?void 0:_.excludeBots,_==null?void 0:_.loadPrevInterval]),ie=R.useMemo(()=>Object.values(B),[B]),ae=R.useCallback(j=>{kv=void 0,T(j)},[]),fe=R.useCallback((j,N)=>{const U=`${j}_${N}`;kv===U?(T([]),D(void 0),kv=void 0):(T(q.filter(J=>J[j]===N)),D(N),kv=U)},[q]);return R.useEffect(()=>i,[i]),R.useEffect(()=>{const j=v??w9(E.current),{loadPrevInterval:N,...U}=te,J={doIntervalFallback:k.current,loadPrevInterval:N};r({dateRange:j,filter:U},J),ae([]),k.current=!1},[v,g,r,te,ae]),R.useEffect(()=>{h&&E.current===((_==null?void 0:_.defaultInterval)??"last30Days")&&(E.current=h)},[h,_==null?void 0:_.defaultInterval]),m.jsxs(m.Fragment,{children:[t,m.jsx("section",{className:"mt-3",children:m.jsxs("div",{className:"row flex-md-row-reverse",children:[m.jsx("div",{className:"col-lg-7 col-xl-6",children:m.jsxs("div",{className:"d-md-flex",children:[m.jsx("div",{className:"flex-grow-1",children:m.jsx(UT,{disabled:f,dateRangeOrInterval:b??v??E.current,defaultText:"All visits",onDatesChange:S})}),m.jsx(Vz,{disabled:f,className:"ms-0 ms-md-2 mt-3 mt-md-0",isOrphanVisits:s,withPrevInterval:!0,selected:te,onChange:({loadPrevInterval:j,...N})=>x({visitsFilter:N,loadPrevInterval:j})})]})}),l.length>0&&m.jsx("div",{className:"col-lg-5 col-xl-6 mt-3 mt-lg-0",children:m.jsxs("div",{className:"d-flex",children:[m.jsx(nz,{className:"btn-md-block",amount:q.length,onClick:()=>a(q)}),m.jsxs(Ye,{outline:!0,disabled:P.length===0,className:"btn-md-block ms-2",onClick:()=>ae([]),children:["Clear selection ",P.length>0&&m.jsxs(m.Fragment,{children:["(",Yt(P.length),")"]})]})]})})]})}),m.jsxs("section",{className:"mt-3",children:[m.jsx(Wz,{info:n}),!f&&!d&&m.jsxs(m.Fragment,{children:[m.jsx(D8,{fill:!0,children:Object.values(Ea).map(({title:j,icon:N,subPath:U,shouldRender:J},Y)=>!J||J(e)?m.jsxs(Fd,{to:F(U),replace:!0,children:[m.jsx(je,{icon:N}),m.jsx("span",{className:"ms-2 d-none d-lg-inline",children:j})]},Y):void 0).filter(Boolean)}),m.jsx(rr,{children:m.jsxs(K0,{children:[m.jsx(lt,{path:Ea.byTime.subPath,element:m.jsxs(og,{showFallback:l.length===0,children:[m.jsx("div",{className:"col-12 mt-3","data-testid":"line-chart-container",children:m.jsx(Bz,{visitsGroups:K,setSelectedVisits:ae})}),m.jsx(Ex,{display:!!te.loadPrevInterval&&!u})]})}),m.jsx(lt,{path:Ea.byContext.subPath,element:m.jsxs(og,{showFallback:l.length===0,children:[m.jsx("div",{className:Pe("mt-3 col-lg-6",{"col-xl-4":!s}),children:m.jsx(j$,{title:"Operating systems",stats:X,prevStats:ee.os})}),m.jsx("div",{className:Pe("mt-3 col-lg-6",{"col-xl-4":!s}),children:m.jsx(j$,{title:"Browsers",stats:Q,prevStats:ee.browsers})}),m.jsx("div",{className:Pe("mt-3",{"col-xl-4":!s,"col-lg-6":s}),children:m.jsx(jv,{title:"Referrers",withPagination:!1,stats:ne,prevStats:ee.referrers,highlightedStats:Ev(P,"referer"),highlightedLabel:A,sortingItems:{name:"Referrer name",amount:"Visits amount"},onClick:j=>fe("referer",j)})}),s&&m.jsx("div",{className:"mt-3 col-lg-6",children:m.jsx(jv,{title:"Visited URLs",stats:H,prevStats:ee.visitedUrls,highlightedStats:Ev(P,"visitedUrl"),highlightedLabel:A,sortingItems:{visitedUrl:"Visited URL",amount:"Visits amount"},onClick:j=>fe("visitedUrl",j)})}),m.jsx("div",{className:"col-12",children:m.jsx(Ex,{display:!!te.loadPrevInterval&&!u})})]})}),m.jsx(lt,{path:Ea.byLocation.subPath,element:m.jsxs(og,{showFallback:l.length===0,children:[m.jsx("div",{className:"col-lg-6 mt-3",children:m.jsx(jv,{title:"Countries",stats:Z,prevStats:ee.countries,highlightedStats:Ev(P,"country"),highlightedLabel:A,sortingItems:{name:"Country name",amount:"Visits amount"},onClick:j=>fe("country",j)})}),m.jsx("div",{className:"col-lg-6 mt-3",children:m.jsx(jv,{title:"Cities",stats:z,prevStats:ee.cities,highlightedStats:Ev(P,"city"),highlightedLabel:A,extraHeaderContent:j=>ie.length>0&&m.jsx(u5e,{modalTitle:"Cities",locations:ie,activeCities:j}),sortingItems:{name:"City name",amount:"Visits amount"},onClick:j=>fe("city",j)})}),m.jsx("div",{className:"col-12",children:m.jsx(Ex,{display:!!te.loadPrevInterval&&!u})})]})}),m.jsx(lt,{path:Ea.list.subPath,element:m.jsx("div",{className:"col-12",children:m.jsx(P5e,{visits:q,selectedVisits:P,setSelectedVisits:ae})})}),o&&m.jsx(lt,{path:Ea.options.subPath,element:m.jsx("div",{className:"col-12 mt-3",children:m.jsx(c5e,{...o})})}),m.jsx(lt,{path:"*",element:m.jsx(oP,{replace:!0,to:F(Ea.byTime.subPath)})})]})})]})]})]})},qz=Ki(({getDomainVisits:e,domainVisits:t,cancelGetDomainVisits:n})=>{const{ReportExporter:r}=It(qz),{domain:i=""}=qc(),[o,a=o]=i.split("_"),s=R.useCallback((u,f)=>e({domain:a,options:f,params:u}),[a,e]),l=R.useCallback(u=>r.exportVisits(`domain_${o}_visits.csv`,u),[o,r]);return m.jsx(sm,{getVisits:s,cancelGetVisits:n,visitsInfo:t,exportCsv:l,children:m.jsx(am,{visits:t.visits,title:`"${o}" visits`})})},()=>[fr.visits]),C5e=Dt(qz,["ReportExporter"]),Kz=Ki(({getNonOrphanVisits:e,nonOrphanVisits:t,cancelGetNonOrphanVisits:n})=>{const{ReportExporter:r}=It(Kz),i=R.useCallback(a=>r.exportVisits("non_orphan_visits.csv",a),[r]),o=R.useCallback((a,s)=>e({options:s,params:a}),[e]);return m.jsx(sm,{getVisits:o,cancelGetVisits:n,visitsInfo:t,exportCsv:i,children:m.jsx(am,{title:"Non-orphan visits",visits:t.visits})})},()=>[fr.visits]),T5e=Dt(Kz,["ReportExporter"]),Yz=Ki(({getOrphanVisits:e,orphanVisits:t,cancelGetOrphanVisits:n,deleteOrphanVisits:r,orphanVisitsDeletion:i})=>{const o=fs("orphanVisitsDeletion"),{ReportExporter:a}=It(Yz),s=R.useCallback(f=>a.exportVisits("orphan_visits.csv",f),[a]),l=R.useCallback((f,d)=>{var h;return e({options:d,params:f,orphanVisitsType:(h=f.filter)==null?void 0:h.orphanVisitsType})},[e]),u=R.useMemo(()=>o?{deleteVisits:r,visitsDeletion:i}:void 0,[r,i,o]);return m.jsx(sm,{getVisits:l,cancelGetVisits:n,visitsInfo:t,exportCsv:s,deletion:u,isOrphanVisits:!0,children:m.jsx(am,{title:"Orphan visits",visits:t.visits})})},()=>[fr.orphanVisits]),j5e=Dt(Yz,["ReportExporter"]),Zz="shlink/orphanVisits",A5e={visits:[],loading:!1,cancelLoad:!1,errorData:null,progress:null},k5e=e=>rm({typePrefix:`${Zz}/getNonOrphanVisits`,createLoaders:({options:t})=>{const n=e(),{doIntervalFallback:r=!1}=t,i=async a=>n.getNonOrphanVisits(a),o=nm(r,a=>n.getNonOrphanVisits(a));return{visitsLoader:i,lastVisitLoader:o}},shouldCancel:t=>t().orphanVisits.cancelLoad}),N5e=e=>im({name:Zz,initialState:A5e,asyncThunkCreator:e,filterCreatedVisits:({params:t},n)=>{const{startDate:r,endDate:i}=(t==null?void 0:t.dateRange)??{};return n.filter(({visit:o})=>tm(o.date,r,i))}}),Xz="shlink/orphanVisits",M5e={visits:[],loading:!1,cancelLoad:!1,errorData:null,progress:null},R5e=(e,t)=>!t||t===e.type,L5e=({data:e,...t},n)=>{const r=e.filter(i=>LT(i)&&R5e(i,n));return{...t,data:r}},$5e=e=>rm({typePrefix:`${Xz}/getOrphanVisits`,createLoaders:({orphanVisitsType:t,options:n})=>{const r=e(),{doIntervalFallback:i=!1}=n,o=async s=>r.getOrphanVisits({...s,type:t}).then(l=>L5e(l,t)),a=nm(i,s=>r.getOrphanVisits(s));return{visitsLoader:o,lastVisitLoader:a}},shouldCancel:t=>t().orphanVisits.cancelLoad}),I5e=(e,t)=>im({name:Xz,initialState:M5e,asyncThunkCreator:e,extraReducers:n=>{n.addCase(t.fulfilled,r=>({...r,visits:[]}))},filterCreatedVisits:({params:n},r)=>{const{startDate:i,endDate:o}=(n==null?void 0:n.dateRange)??{};return r.filter(({visit:a,shortUrl:s})=>!s&&tm(a.date,i,o))}}),Qz="shlink/orphanVisitsDeletion",R$={deletedVisits:0,deleting:!1,error:!1},D5e=e=>gn(`${Qz}/deleteOrphanVisits`,()=>e().deleteOrphanVisits()),F5e=e=>nn({name:Qz,initialState:R$,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:Yr(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>{const{deletedVisits:i}=r;return{...R$,deletedVisits:i}})}}),Jz="shlink/shortUrlVisits",B5e={visits:[],shortCode:"",loading:!1,errorData:null,cancelLoad:!1,progress:null},U5e=e=>rm({typePrefix:`${Jz}/getShortUrlVisits`,createLoaders:({shortCode:t,domain:n,options:r})=>{const i=e(),{doIntervalFallback:o=!1}=r,a=l=>i.getShortUrlVisits(t,{...l,domain:n}),s=nm(o,l=>i.getShortUrlVisits(t,{...l,domain:n}));return{visitsLoader:a,lastVisitLoader:s}},shouldCancel:t=>t().shortUrlVisits.cancelLoad}),z5e=(e,t)=>im({name:Jz,initialState:B5e,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},o)=>S9(o,{shortCode:n,domain:r},i==null?void 0:i.dateRange)}),eV="shlink/shortUrlVisitsDeletion",L$={shortCode:"",deletedVisits:0,deleting:!1,error:!1},V5e=e=>gn(`${eV}/deleteShortUrlVisits`,async({shortCode:t,domain:n})=>({...await e().deleteShortUrlVisits(t,n),shortCode:t,domain:n})),W5e=e=>nn({name:eV,initialState:L$,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:Yr(r)})),t.addCase(e.fulfilled,(n,{payload:r})=>{const{shortCode:i,domain:o,deletedVisits:a}=r;return{...L$,shortCode:i,domain:o,deletedVisits:a}})}}),tV="shlink/tagVisits",H5e={visits:[],tag:"",loading:!1,cancelLoad:!1,errorData:null,progress:null},G5e=e=>rm({typePrefix:`${tV}/getTagVisits`,createLoaders:({tag:t,options:n})=>{const r=e(),{doIntervalFallback:i=!1}=n,o=s=>r.getTagVisits(t,s),a=nm(i,async s=>r.getTagVisits(t,s));return{visitsLoader:o,lastVisitLoader:a}},shouldCancel:t=>t().tagVisits.cancelLoad}),q5e=e=>im({name:tV,initialState:H5e,asyncThunkCreator:e,filterCreatedVisits:({tag:t,params:n},r)=>P9(r,t,n==null?void 0:n.dateRange)}),nV="shlink/visitsOverview",Nv={nonOrphanVisits:{total:0},orphanVisits:{total:0},loading:!1,error:!1},$$=e=>e.filter(({visit:t})=>t.potentialBot).length,K5e=e=>gn(`${nV}/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}}))),Y5e=e=>nn({name:nV,initialState:Nv,reducers:{},extraReducers:t=>{t.addCase(e.pending,()=>({...Nv,loading:!0})),t.addCase(e.rejected,()=>({...Nv,error:!0})),t.addCase(e.fulfilled,(n,{payload:r})=>({...Nv,...r})),t.addCase(_f,({nonOrphanVisits:n,orphanVisits:r,...i},{payload:o})=>{const{nonOrphanVisits:a,orphanVisits:s}=x$e(o.createdVisits),l=a.length,u=$$(a),f=l-u,d=s.length,h=$$(s),v=d-h;return{...i,nonOrphanVisits:{total:n.total+l,bots:n.bots&&n.bots+u,nonBots:n.nonBots&&n.nonBots+f},orphanVisits:{total:r.total+d,bots:r.bots&&r.bots+h,nonBots:r.nonBots&&r.nonBots+v}}})}}),Z5e=({shortUrl:e,loading:t,shortUrlVisits:n})=>{const{visits:r}=n,i=(e==null?void 0:e.shortUrl)??"",o=(e==null?void 0:e.longUrl)??"",a=e==null?void 0:e.title;return m.jsxs(am,{title:m.jsxs(m.Fragment,{children:["Visits for ",m.jsx(Er,{href:i})]}),visits:r,shortUrl:e,children:[m.jsx("hr",{}),m.jsxs("div",{children:["Created: ",e?m.jsxs("span",{children:[m.jsx("b",{id:"created",className:"short-url-visits-header__created-at",children:m.jsx(O0,{date:e.dateCreated,relative:!0})}),m.jsx(Tr,{placement:"bottom",target:"created",children:m.jsx(O0,{date:e.dateCreated})})]}):m.jsx("small",{children:"Loading..."})]}),m.jsxs("div",{className:"long-url-container",children:[`${a?"Title":"Long URL"}: `,t&&m.jsx("small",{children:"Loading..."}),!t&&m.jsx(Er,{href:o,children:a??o})]})]})},rV=Ki(({shortUrlVisits:e,shortUrlVisitsDeletion:t,shortUrlsDetails:n,getShortUrlVisits:r,getShortUrlsDetails:i,deleteShortUrlVisits:o,cancelGetShortUrlVisits:a})=>{const s=fs("shortUrlVisitsDeletion"),{ReportExporter:l}=It(rV),u=BT(),f=R.useMemo(()=>{var g;return(g=n.shortUrls)==null?void 0:g.get(u)},[u,n.shortUrls]),d=R.useCallback((g,y)=>r({...u,options:y,params:g}),[r,u]),h=R.useCallback(g=>l.exportVisits(`short-url_${f==null?void 0:f.shortUrl.replace(/https?:\/\//g,"")}_visits.csv`,g),[l,f==null?void 0:f.shortUrl]),v=R.useMemo(()=>s?{deleteVisits:()=>o(u),visitsDeletion:t}:void 0,[o,u,t,s]);return R.useEffect(()=>{i([u])},[u,i]),m.jsx(sm,{getVisits:d,cancelGetVisits:a,visitsInfo:e,exportCsv:h,deletion:v,children:m.jsx(Z5e,{shortUrl:f,loading:n.loading,shortUrlVisits:e})})},e=>e.shortCode?[fr.shortUrlVisits(kT(e.shortCode))]:[]),X5e=Dt(rV,["ReportExporter"]),Q5e=({tagVisits:e,colorGenerator:t})=>{const{visits:n,tag:r}=e;return m.jsx(am,{title:m.jsxs("span",{className:"d-flex align-items-center justify-content-center",children:[m.jsx("span",{className:"me-2",children:"Visits for"}),m.jsx(c1,{text:r,colorGenerator:t})]}),visits:n})},iV=Ki(({getTagVisits:e,tagVisits:t,cancelGetTagVisits:n})=>{const{ColorGenerator:r,ReportExporter:i}=It(iV),{tag:o=""}=qc(),a=R.useCallback((l,u)=>e({tag:o,params:l,options:u}),[e,o]),s=R.useCallback(l=>i.exportVisits(`tag_${o}_visits.csv`,l),[i,o]);return m.jsx(sm,{getVisits:a,cancelGetVisits:n,visitsInfo:t,exportCsv:s,children:m.jsx(Q5e,{tagVisits:t,colorGenerator:r})})},()=>[fr.visits]),J5e=Dt(iV,["ColorGenerator","ReportExporter"]),GT=({title:e,colors:t,getVisitsForComparison:n,visitsComparisonInfo:r,cancelGetVisitsComparison:i})=>{const{loading:o,visitsGroups:a}=r,s=jr("visits"),l=R.useMemo(()=>Object.keys(a).reduce((b,w,S)=>(b[w]=Object.assign(P0(a[w]),{color:(t==null?void 0:t[w])??Dz(S)}),b),{}),[t,a]),u=R.useMemo(()=>Object.values(a).every(b=>b.length===0),[a]),[{dateRange:f,visitsFilter:d},h]=Uz(),[v,g]=R.useState(),y=R.useCallback(({startDate:b,endDate:w},S)=>{h({dateRange:{startDate:b??void 0,endDate:w??void 0}}),g(S)},[h]),x=R.useRef(f??(s==null?void 0:s.defaultInterval)??"last30Days"),_=R.useMemo(()=>({...d,excludeBots:d.excludeBots??(s==null?void 0:s.excludeBots)}),[d,s==null?void 0:s.excludeBots]);return R.useEffect(()=>{const b=f??w9(x.current);return n({params:{dateRange:b,filter:_}}),i},[i,f,n,_]),m.jsxs(m.Fragment,{children:[m.jsx("div",{className:"mb-3",children:m.jsxs(Ot,{bodyClassName:"d-flex",children:[m.jsx(u1,{}),m.jsx("h3",{className:"mb-0 flex-grow-1 text-center",children:e})]})}),m.jsx("div",{className:"col-lg-7 col-xl-6 offset-lg-5 offset-xl-6 mb-3",children:m.jsxs("div",{className:"d-md-flex",children:[m.jsx("div",{className:"flex-grow-1",children:m.jsx(UT,{disabled:o,defaultText:"All visits",dateRangeOrInterval:v??x.current,onDatesChange:y})}),m.jsx(Vz,{disabled:o,className:"ms-0 ms-md-2 mt-3 mt-md-0",selected:_,onChange:({orphanVisitsType:b,excludeBots:w})=>h({visitsFilter:{orphanVisitsType:b,excludeBots:w}})})]})}),m.jsx(Wz,{info:r}),!o&&m.jsx(og,{showFallback:u,children:m.jsx(Bz,{visitsGroups:l})})]})},e8e=Ki(({getDomainVisitsForComparison:e,domainVisitsComparison:t,cancelGetDomainVisitsComparison:n})=>{const r=IT("domains"),i=R.useCallback(o=>e({...o,domains:r}),[r,e]);return m.jsx(GT,{title:`Comparing "${r.join('", "')}"`,getVisitsForComparison:i,visitsComparisonInfo:t,cancelGetVisitsComparison:n})},()=>[fr.visits]),t8e=({visitsLoaders:e,shouldCancel:t,progressChanged:n})=>{const r=Object.keys(e),i=Math.max(1,Math.round(4/r.length)),o=Object.fromEntries(r.map(l=>[l,0])),a=(l,u)=>{o[l]=u;const f=Object.values(o),d=f.reduce((h,v)=>h+v,0);n(d/f.length)},s=Object.entries(e).map(([l,u])=>[l,C9({visitsLoader:u,batchSize:i,shouldCancel:t,progressChanged:f=>a(l,f)})]);return async l=>{const u=await Promise.all(s.map(async([f,d])=>{const h=await d(l);return[f,h]}));return Object.fromEntries(u)}},qT=({typePrefix:e,createLoaders:t,shouldCancel:n})=>{const r=mn(`${e}/progressChanged`),i=gn(e,async(o,{getState:a,dispatch:s})=>{const l=t(o),u=await t8e({visitsLoaders:l,shouldCancel:()=>n(a),progressChanged:f=>s(r(f))})(QS(o.params));return{...o,visitsGroups:u}});return Object.assign(i,{progressChanged:r})},KT=({name:e,asyncThunkCreator:t,initialState:n,filterCreatedVisitsForGroup:r})=>{const{pending:i,rejected:o,fulfilled:a,progressChanged:s}=t,{reducer:l,actions:u}=nn({name:e,initialState:n,reducers:{cancelGetVisits:d=>({...d,cancelLoad:!0})},extraReducers:d=>{d.addCase(i,()=>({...n,loading:!0})),d.addCase(o,(h,{error:v})=>({...n,errorData:Yr(v)??null})),d.addCase(a,(h,{payload:v})=>({...h,...v,loading:!1,progress:null,errorData:null})),d.addCase(s,(h,{payload:v})=>({...h,progress:v})),d.addCase(_f,(h,{payload:v})=>{const{visitsGroups:g,...y}=h,x=Object.keys(g).map(b=>{const w=r({...y,groupKey:b},v.createdVisits).map(({visit:S})=>S);return[b,[...w,...g[b]]]}),_=Object.fromEntries(x);return{...y,visitsGroups:_}})}}),{cancelGetVisits:f}=u;return{reducer:l,cancelGetVisits:f}},oV="shlink/domainVisitsComparison",n8e={visitsGroups:{},loading:!1,cancelLoad:!1,errorData:null,progress:null},r8e=e=>qT({typePrefix:`${oV}/getDomainVisitsForComparison`,createLoaders:({domains:t})=>{const n=e(),r=t.map(i=>[i,o=>n.getDomainVisits(i,o)]);return Object.fromEntries(r)},shouldCancel:t=>t().domainVisitsComparison.cancelLoad}),i8e=e=>KT({name:oV,initialState:n8e,asyncThunkCreator:e,filterCreatedVisitsForGroup:({groupKey:t,params:n},r)=>E9(r,t,n==null?void 0:n.dateRange)}),aV="shlink/shortUrlVisitsComparison",o8e={visitsGroups:{},loading:!1,cancelLoad:!1,errorData:null,progress:null},a8e=e=>qT({typePrefix:`${aV}/getShortUrlVisitsForComparison`,createLoaders:({shortUrls:t})=>{const n=e(),r=t.map(i=>[NT(i),o=>n.getShortUrlVisits(i.shortCode,{...o,domain:i.domain})]);return Object.fromEntries(r)},shouldCancel:t=>t().shortUrlVisitsComparison.cancelLoad}),s8e=e=>KT({name:aV,initialState:o8e,asyncThunkCreator:e,filterCreatedVisitsForGroup:({groupKey:t,params:n},r)=>S9(r,m9(t),n==null?void 0:n.dateRange)}),sV="shlink/tagVisitsComparison",l8e={visitsGroups:{},loading:!1,cancelLoad:!1,errorData:null,progress:null},u8e=e=>qT({typePrefix:`${sV}/getTagVisitsForComparison`,createLoaders:({tags:t})=>{const n=e(),r=t.map(i=>[i,o=>n.getTagVisits(i,o)]);return Object.fromEntries(r)},shouldCancel:t=>t().tagVisitsComparison.cancelLoad}),c8e=e=>KT({name:sV,initialState:l8e,asyncThunkCreator:e,filterCreatedVisitsForGroup:({groupKey:t,params:n},r)=>P9(r,t,n==null?void 0:n.dateRange)}),f8e=Ki(({getShortUrlVisitsForComparison:e,shortUrlVisitsComparison:t,cancelGetShortUrlVisitsComparison:n,shortUrlsDetails:r,getShortUrlsDetails:i})=>{const o=IT("short-urls"),a=R.useMemo(()=>o.map(m9),[o]),s=R.useCallback(f=>e({...f,shortUrls:a}),[e,a]),l=R.useMemo(()=>{var f;return[...((f=r.shortUrls)==null?void 0:f.values())??[]]},[r.shortUrls]),u=R.useMemo(()=>{const{visitsGroups:f,loading:d,...h}=t,v=l.reduce((g,y)=>(g[y.shortUrl]=f[NT(y)]??[],g),{});return{...h,visitsGroups:v,loading:d||r.loading}},[t,r.loading,l]);return R.useEffect(()=>{a.length>0&&i(a)},[i,a]),m.jsx(GT,{title:m.jsx("span",{"data-testid":"title",children:r.loading?"Loading...":`Comparing ${l.length} short URLs`}),getVisitsForComparison:s,visitsComparisonInfo:u,cancelGetVisitsComparison:n})},()=>[fr.visits]),lV=Ki(({getTagVisitsForComparison:e,tagVisitsComparison:t,cancelGetTagVisitsComparison:n})=>{const{ColorGenerator:r}=It(lV),i=IT("tags"),o=R.useCallback(l=>e({...l,tags:i}),[e,i]),{visitsGroups:a}=t,s=R.useMemo(()=>Object.keys(a).reduce((l,u)=>(l[u]=r.getColorForKey(u),l),{}),[r,a]);return m.jsx(GT,{title:m.jsxs(m.Fragment,{children:["Comparing ",i.map(l=>m.jsx(c1,{colorGenerator:r,text:l},l))]}),getVisitsForComparison:o,visitsComparisonInfo:t,cancelGetVisitsComparison:n,colors:s})},()=>[fr.visits]),d8e=Dt(lV,["ColorGenerator"]),h8e=(e,t)=>{const n=(r,i)=>t([...r,"mercureInfo"],[...i,"createNewVisits","loadMercureInfo"]);e.serviceFactory("MapModal",()=>zz),e.factory("ShortUrlVisits",X5e),e.decorator("ShortUrlVisits",t(["shortUrlVisits","shortUrlVisitsDeletion","shortUrlsDetails","mercureInfo"],["getShortUrlVisits","deleteShortUrlVisits","getShortUrlsDetails","cancelGetShortUrlVisits","createNewVisits","loadMercureInfo"])),e.factory("TagVisits",J5e),e.decorator("TagVisits",n(["tagVisits"],["getTagVisits","cancelGetTagVisits"])),e.factory("TagVisitsComparison",d8e),e.decorator("TagVisitsComparison",n(["tagVisitsComparison"],["getTagVisitsForComparison","cancelGetTagVisitsForComparison"])),e.serviceFactory("DomainVisitsComparison",()=>e8e),e.decorator("DomainVisitsComparison",n(["domainVisitsComparison"],["getDomainVisitsForComparison","cancelGetDomainVisitsForComparison"])),e.serviceFactory("ShortUrlVisitsComparison",()=>f8e),e.decorator("ShortUrlVisitsComparison",n(["shortUrlVisitsComparison","shortUrlsDetails"],["getShortUrlVisitsForComparison","cancelGetShortUrlVisitsForComparison","getShortUrlsDetails"])),e.factory("DomainVisits",C5e),e.decorator("DomainVisits",n(["domainVisits"],["getDomainVisits","cancelGetDomainVisits"])),e.factory("OrphanVisits",j5e),e.decorator("OrphanVisits",n(["orphanVisits","orphanVisitsDeletion"],["getOrphanVisits","cancelGetOrphanVisits","deleteOrphanVisits"])),e.factory("NonOrphanVisits",T5e),e.decorator("NonOrphanVisits",n(["nonOrphanVisits"],["getNonOrphanVisits","cancelGetNonOrphanVisits"])),e.serviceFactory("VisitsParser",()=>x5e),e.serviceFactory("getShortUrlVisits",U5e,"apiClientFactory"),e.serviceFactory("cancelGetShortUrlVisits",r=>r.cancelGetVisits,"shortUrlVisitsReducerCreator"),e.serviceFactory("getShortUrlVisitsForComparison",a8e,"apiClientFactory"),e.serviceFactory("cancelGetShortUrlVisitsForComparison",r=>r.cancelGetVisits,"shortUrlVisitsComparisonReducerCreator"),e.serviceFactory("deleteShortUrlVisits",V5e,"apiClientFactory"),e.serviceFactory("getTagVisits",G5e,"apiClientFactory"),e.serviceFactory("cancelGetTagVisits",r=>r.cancelGetVisits,"tagVisitsReducerCreator"),e.serviceFactory("getTagVisitsForComparison",u8e,"apiClientFactory"),e.serviceFactory("cancelGetTagVisitsForComparison",r=>r.cancelGetVisits,"tagVisitsComparisonReducerCreator"),e.serviceFactory("getDomainVisits",A$e,"apiClientFactory"),e.serviceFactory("cancelGetDomainVisits",r=>r.cancelGetVisits,"domainVisitsReducerCreator"),e.serviceFactory("getDomainVisitsForComparison",r8e,"apiClientFactory"),e.serviceFactory("cancelGetDomainVisitsForComparison",r=>r.cancelGetVisits,"domainVisitsComparisonReducerCreator"),e.serviceFactory("getOrphanVisits",$5e,"apiClientFactory"),e.serviceFactory("cancelGetOrphanVisits",r=>r.cancelGetVisits,"orphanVisitsReducerCreator"),e.serviceFactory("deleteOrphanVisits",D5e,"apiClientFactory"),e.serviceFactory("getNonOrphanVisits",k5e,"apiClientFactory"),e.serviceFactory("cancelGetNonOrphanVisits",r=>r.cancelGetVisits,"nonOrphanVisitsReducerCreator"),e.serviceFactory("createNewVisits",()=>_f),e.serviceFactory("loadVisitsOverview",K5e,"apiClientFactory"),e.serviceFactory("visitsOverviewReducerCreator",Y5e,"loadVisitsOverview"),e.serviceFactory("visitsOverviewReducer",r=>r.reducer,"visitsOverviewReducerCreator"),e.serviceFactory("domainVisitsReducerCreator",k$e,"getDomainVisits"),e.serviceFactory("domainVisitsReducer",r=>r.reducer,"domainVisitsReducerCreator"),e.serviceFactory("nonOrphanVisitsReducerCreator",N5e,"getNonOrphanVisits"),e.serviceFactory("nonOrphanVisitsReducer",r=>r.reducer,"nonOrphanVisitsReducerCreator"),e.serviceFactory("orphanVisitsReducerCreator",I5e,"getOrphanVisits","deleteOrphanVisits"),e.serviceFactory("orphanVisitsReducer",r=>r.reducer,"orphanVisitsReducerCreator"),e.serviceFactory("orphanVisitsDeletionReducerCreator",F5e,"deleteOrphanVisits"),e.serviceFactory("orphanVisitsDeletionReducer",r=>r.reducer,"orphanVisitsDeletionReducerCreator"),e.serviceFactory("shortUrlVisitsReducerCreator",z5e,"getShortUrlVisits","deleteShortUrlVisits"),e.serviceFactory("shortUrlVisitsReducer",r=>r.reducer,"shortUrlVisitsReducerCreator"),e.serviceFactory("shortUrlVisitsDeletionReducerCreator",W5e,"deleteShortUrlVisits"),e.serviceFactory("shortUrlVisitsDeletionReducer",r=>r.reducer,"shortUrlVisitsDeletionReducerCreator"),e.serviceFactory("tagVisitsReducerCreator",q5e,"getTagVisits"),e.serviceFactory("tagVisitsReducer",r=>r.reducer,"tagVisitsReducerCreator"),e.serviceFactory("tagVisitsComparisonReducerCreator",c8e,"getTagVisitsForComparison"),e.serviceFactory("tagVisitsComparisonReducer",r=>r.reducer,"tagVisitsComparisonReducerCreator"),e.serviceFactory("domainVisitsComparisonReducerCreator",i8e,"getDomainVisitsForComparison"),e.serviceFactory("domainVisitsComparisonReducer",r=>r.reducer,"domainVisitsComparisonReducerCreator"),e.serviceFactory("shortUrlVisitsComparisonReducerCreator",s8e,"getShortUrlVisitsForComparison"),e.serviceFactory("shortUrlVisitsComparisonReducer",r=>r.reducer,"shortUrlVisitsComparisonReducerCreator")},sd=({children:e,to:t,className:n,...r})=>m.jsx(OD,{className:({isActive:i})=>Pe("aside-menu__item",n,{"aside-menu__item--selected":i}),to:t,...r,children:e}),p8e=({routePrefix:e,showOnMobile:t=!1})=>{const{pathname:n}=pr(),r=Pe("aside-menu",{"aside-menu--hidden":!t}),i=o=>`${e}${o}`;return m.jsx("aside",{className:r,children:m.jsxs("nav",{className:"nav flex-column aside-menu__nav",children:[m.jsxs(sd,{to:i("/overview"),children:[m.jsx(je,{fixedWidth:!0,icon:$Z}),m.jsx("span",{className:"aside-menu__item-text",children:"Overview"})]}),m.jsxs(sd,{to:i("/list-short-urls/1"),className:Pe({"aside-menu__item--selected":n.match("/list-short-urls")!==null}),children:[m.jsx(je,{fixedWidth:!0,icon:FD}),m.jsx("span",{className:"aside-menu__item-text",children:"List short URLs"})]}),m.jsxs(sd,{to:i("/create-short-url"),children:[m.jsx(je,{fixedWidth:!0,icon:zZ,flip:"horizontal"}),m.jsx("span",{className:"aside-menu__item-text",children:"Create short URL"})]}),m.jsxs(sd,{to:i("/manage-tags"),children:[m.jsx(je,{fixedWidth:!0,icon:BD}),m.jsx("span",{className:"aside-menu__item-text",children:"Manage tags"})]}),m.jsxs(sd,{to:i("/manage-domains"),children:[m.jsx(je,{fixedWidth:!0,icon:pZ}),m.jsx("span",{className:"aside-menu__item-text",children:"Manage domains"})]})]})})},uV=({createNotFound:e})=>{const{TagsList:t,ShortUrlsList:n,CreateShortUrl:r,ShortUrlVisits:i,TagVisits:o,DomainVisits:a,OrphanVisits:s,NonOrphanVisits:l,Overview:u,EditShortUrl:f,ManageDomains:d,TagVisitsComparison:h,DomainVisitsComparison:v,ShortUrlVisitsComparison:g,ShortUrlRedirectRules:y}=It(uV),x=pr(),_=Ss(),[b,w,S,E]=Zt();R.useEffect(()=>E(),[x,E]);const P=Pe("shlink-layout__burger-icon",{"shlink-layout__burger-icon--active":b}),T=L$e(S,E),A=fs("shortUrlRedirectRules");return m.jsxs(m.Fragment,{children:[m.jsx(je,{icon:uZ,className:P,onClick:w}),m.jsx("div",{...T,className:"shlink-layout__swipeable",children:m.jsxs("div",{className:"shlink-layout__swipeable-inner",children:[m.jsx(p8e,{routePrefix:_,showOnMobile:b}),m.jsx("div",{className:"shlink-layout__container",onPointerDown:()=>E(),children:m.jsx("div",{className:"container-xl",children:m.jsxs(K0,{children:[m.jsx(lt,{index:!0,element:m.jsx(oP,{replace:!0,to:"overview"})}),m.jsx(lt,{path:"/overview",element:m.jsx(u,{})}),m.jsx(lt,{path:"/list-short-urls/:page",element:m.jsx(n,{})}),m.jsx(lt,{path:"/create-short-url",element:m.jsx(r,{})}),m.jsx(lt,{path:"/short-code/:shortCode/visits/*",element:m.jsx(i,{})}),m.jsx(lt,{path:"/short-code/:shortCode/edit",element:m.jsx(f,{})}),A&&m.jsx(lt,{path:"/short-code/:shortCode/redirect-rules",element:m.jsx(y,{})}),m.jsx(lt,{path:"/short-urls/compare-visits",element:m.jsx(g,{})}),m.jsx(lt,{path:"/tag/:tag/visits/*",element:m.jsx(o,{})}),m.jsx(lt,{path:"/tags/compare-visits",element:m.jsx(h,{})}),m.jsx(lt,{path:"/domain/:domain/visits/*",element:m.jsx(a,{})}),m.jsx(lt,{path:"/orphan-visits/*",element:m.jsx(s,{})}),m.jsx(lt,{path:"/non-orphan-visits/*",element:m.jsx(l,{})}),m.jsx(lt,{path:"/manage-tags",element:m.jsx(t,{})}),m.jsx(lt,{path:"/manage-domains",element:m.jsx(d,{})}),m.jsx(lt,{path:"/domains/compare-visits",element:m.jsx(v,{})}),e&&m.jsx(lt,{path:"*",element:e("/list-short-urls/1")})]})})})]})})]})},m8e=Dt(uV,["TagsList","ShortUrlsList","CreateShortUrl","ShortUrlVisits","TagVisits","DomainVisits","OrphanVisits","NonOrphanVisits","Overview","EditShortUrl","ManageDomains","TagVisitsComparison","DomainVisitsComparison","ShortUrlVisitsComparison","ShortUrlRedirectRules"]),v8e=!0,g8e=e=>tF({devTools:!v8e,reducer:iC({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})}),y8e=e=>{e.factory("Main",m8e),e.factory("store",g8e)},Yi=new RD,{container:b8e}=Yi,_8e=e=>t=>Object.fromEntries(e.map(n=>[n,t[n]])),x8e=(e,t)=>(...n)=>e[t](...n),w8e=(e,t)=>({...e,[t]:x8e(b8e,t)}),xf=(e,t=[])=>cD(e?_8e(e):null,t.reduce(w8e,{}));y8e(Yi);rDe(Yi,xf);PDe(Yi,xf);h8e(Yi,xf);K$e(Yi);H$e(Yi,xf);oIe(Yi,xf);zDe(Yi);p6e(Yi,xf);let I$;const O8e=e=>({serverVersion:t,apiClient:n,settings:r,routesPrefix:i="",createNotFound:o,tagColorsStorage:a})=>{const s=R6e(t),l=R.useRef(),[u,f]=R.useState(),d=$l(),h=R.useMemo(()=>d?R.Fragment:wD,[d]);return R.useEffect(()=>{I$=n,e.value("apiClientFactory",()=>I$),a&&e.value("TagColorsStorage",a);const{container:v}=e,{Main:g,store:y,loadMercureInfo:x,listTags:_}=v;l.current=m.jsx(g,{createNotFound:o}),f(y),y.dispatch(x(r)),y.dispatch(_())},[n,o,r,a]),u?m.jsx(fD,{store:u,children:m.jsx(_F,{value:r??{},children:m.jsx(M6e,{value:s,children:m.jsx(u$e,{value:i,children:m.jsx(h,{children:l.current})})})})}):m.jsx(m.Fragment,{})},S8e="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=",E8e="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==",P8e="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACkAAAApCAQAAAACach9AAACMUlEQVR4Ae3ShY7jQBAE0Aoz/f9/HTMzhg1zrdKUrJbdx+Kd2nD8VNudfsL/Th///dyQN2TH6f3y/BGpC379rV+S+qqetBOxImNQXL8JCAr2V4iMQXHGNJxeCfZXhSRBcQMfvkOWUdtfzlLgAENmZDcmo2TVmt8OSM2eXxBp3DjHSMFutqS7SbmemzBiR+xpKCNUIRkdkkYxhAkyGoBvyQFEJEefwSmmvBfJuJ6aKqKWnAkvGZOaZXTUgFqYULWNSHUckZuR1HIIimUExutRxwzOLROIG4vKmCKQt364mIlhSyzAf1m9lHZHJZrlAOMMztRRiKimp/rpdJDc9Awry5xTZCte7FHtuS8wJgeYGrex28xNTd086Dik7vUMscQOa8y4DoGtCCSkAKlNwpgNtphjrC6MIHUkR6YWxxs6Sc5xqn222mmCRFzIt8lEdKx+ikCtg91qS2WpwVfBelJCiQJwvzixfI9cxZQWgiSJelKnwBElKYtDOb2MFbhmUigbReQBV0Cg4+qMXSxXSyGUn4UbF8l+7qdSGnTC0XLCmahIgUHLhLOhpVCtw4CzYXvLQWQbJNmxoCsOKAxSgBJno75avolkRw8iIAFcsdc02e9iyCd8tHwmeSSoKTowIgvscSGZUOA7PuCN5b2BX9mQM7S0wYhMNU74zgsPBj3HU7wguAfnxxjFQGBE6pwN+GjME9zHY7zGp8wVxMShYX9NXvEWD3HbwJf4giO4CFIQxXScH1/TM+04kkBiAAAAAElFTkSuQmCC",C8e=()=>{delete r$.Icon.Default.prototype._getIconUrl,r$.Icon.Default.mergeOptions({iconRetinaUrl:E8e,iconUrl:S8e,shadowUrl:P8e})};C8e();const T8e=O8e(Yi);function C0(e){return t=>{const{resetSelectedServer:n}=t;return R.useEffect(()=>{n()},[n]),m.jsx(e,{...t})}}let j8e=class extends R.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 m.jsx("div",{className:"home",children:m.jsxs(Ot,{className:"p-4",children:[m.jsx("h1",{children:"Oops! This is awkward :S"}),m.jsx("p",{children:"It seems that something went wrong. Try refreshing the page or just click this button."}),m.jsx("br",{}),m.jsx(Ye,{outline:!0,color:"primary",onClick:()=>n.reload(),children:"Take me back"})]})});const{children:r}=this.props;return r}};const A8e=({id:e,name:t})=>m.jsxs(f8,{tag:Pt,to:`/server/${e}`,className:"servers-list__server-item",children:[t,m.jsx(je,{icon:KZ,className:"servers-list__server-item-icon"})]}),cV=({servers:e,children:t,embedded:n=!1})=>m.jsxs(m.Fragment,{children:[t&&m.jsx("div",{"data-testid":"title",className:"mb-0 fs-5 fw-normal lh-sm",children:t}),e.length>0&&m.jsx(l8,{"data-testid":"list",tag:"div",className:Pe("servers-list__list-group",{"servers-list__list-group--embedded":n}),children:e.map(({id:r,name:i})=>m.jsx(A8e,{id:r,name:i},r))})]}),fV=({color:e=jh,className:t})=>m.jsx("svg",{className:t,viewBox:"0 0 512 512",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:m.jsxs("g",{fill:e,children:[m.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"}),m.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"}),m.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"}),m.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"})]})}),k8e=({servers:e})=>{const t=Eo(),n=Object.values(e),r=n.length>0;return R.useEffect(()=>{const i=n.find(({autoConnect:o})=>o);i&&t(`/server/${i.id}`)},[n,t]),m.jsx("div",{className:"home",children:m.jsx(Pr,{className:"home__main-card",children:m.jsxs(rr,{className:"g-0",children:[m.jsx("div",{className:"col-md-5 d-none d-md-block",children:m.jsx("div",{className:"home__logo-wrapper",children:m.jsx("div",{className:"home__logo",children:m.jsx(fV,{})})})}),m.jsxs("div",{className:"col-md-7 home__servers-container",children:[m.jsx("div",{className:"home__title-wrapper",children:m.jsx("h1",{className:"home__title",children:"Welcome!"})}),m.jsx(cV,{embedded:!0,servers:n,children:!r&&m.jsxs("div",{className:"p-4 text-center",children:[m.jsx("p",{className:"mb-5",children:"This application will help you manage your Shlink servers."}),m.jsx("p",{children:m.jsxs(Pt,{to:"/server/create",className:"btn btn-outline-primary btn-lg me-2",children:[m.jsx(je,{icon:Tp})," ",m.jsx("span",{className:"ms-1",children:"Add a server"})]})}),m.jsx("p",{className:"mb-0 mt-5",children:m.jsx(Er,{href:"https://shlink.io/documentation",children:m.jsxs("small",{children:[m.jsx("span",{className:"me-1",children:"Learn more about Shlink"})," ",m.jsx(je,{icon:PZ})]})})})]})})]})]})})})},dV=()=>{const{ServersDropdown:e}=Hi(dV),[t,n,,r]=Zt(),i=pr(),{pathname:o}=i;R.useEffect(r,[i,r]);const a="/settings",s=Pe("main-header__toggle-icon",{"main-header__toggle-icon--opened":t});return m.jsxs(T5,{color:"primary",dark:!0,fixed:"top",className:"main-header",expand:"md",children:[m.jsxs(j5,{tag:Pt,to:"/",children:[m.jsx(fV,{className:"main-header__brand-logo",color:"white"})," Shlink"]}),m.jsx(A5,{onClick:n,children:m.jsx(je,{icon:HZ,className:s})}),m.jsx(Yne,{navbar:!0,isOpen:t,children:m.jsxs(AP,{navbar:!0,className:"ms-auto",children:[m.jsx(kP,{children:m.jsxs(M5,{tag:Pt,to:a,active:o.startsWith(a),children:[m.jsx(je,{icon:XZ}),"  Settings"]})}),m.jsx(e,{})]})})]})},N8e=Gi(dV,["ServersDropdown"]),M8e=({children:e})=>{const t=pr();return R.useEffect(()=>{scrollTo(0,0)},[t]),m.jsx(m.Fragment,{children:e})},hV=aF(e=>e,e=>{try{return _O(e,e,"=")}catch{return!1}}),pV=e=>hV(e)?`v${e}`:e,mV=(e,t="latest")=>hV(e)?e:t,R8e="%_VERSION_%",L8e=e=>pV(mV(e)),D$=({project:e,version:t})=>m.jsx(Er,{href:`https://github.com/shlinkio/${e}/releases/${t}`,className:"text-muted",children:m.jsx("b",{children:t})}),$8e=({selectedServer:e,clientVersion:t=R8e})=>{const n=L8e(t);return m.jsxs("small",{className:"text-muted",children:[cP(e)&&m.jsxs(m.Fragment,{children:["Server: ",m.jsx(D$,{project:"shlink",version:e.printableVersion})," - "]}),"Client: ",m.jsx(D$,{project:"shlink-web-client",version:n})]})},I8e=({selectedServer:e})=>m.jsx("div",{className:Pe("text-center",{"shlink-versions-container--with-sidebar":cP(e)}),children:m.jsx($8e,{selectedServer:e})}),wf=({children:e})=>m.jsx("div",{className:"no-menu-wrapper container-xl",children:e});function vV(e){const t=n=>{const{ServerError:r}=Hi(t),i=qc(),{selectServer:o,selectedServer:a}=n;return R.useEffect(()=>{i.serverId&&o(i.serverId)},[i.serverId,o]),a?XY(a)?m.jsx(r,{}):m.jsx(e,{...n}):m.jsx(wf,{children:m.jsx(ta,{loading:!0})})};return t}const gV=vV(R.memo(({selectedServer:e,settings:t})=>{const{buildShlinkApiClient:n,TagColorsStorage:r,ShlinkWebComponent:i,ServerError:o}=Hi(gV);if(!cP(e))return m.jsx(o,{});const a=`/server/${e.id}`;return m.jsx(i,{serverVersion:e.version,apiClient:n(e),settings:t,routesPrefix:a,tagColorsStorage:r,createNotFound:s=>m.jsx(B8,{to:`${a}${s}`,children:"List short URLs"})})})),D8e=Gi(gV,["buildShlinkApiClient","TagColorsStorage","ShlinkWebComponent","ServerError"]),F8e=(e,t)=>{e.constant("window",window),e.constant("console",console),e.constant("fetch",window.fetch.bind(window)),e.service("HttpClient",Aue,"fetch"),e.serviceFactory("ScrollToTop",()=>M8e),e.factory("MainHeader",N8e),e.serviceFactory("Home",()=>k8e),e.decorator("Home",C0),e.decorator("Home",t(["servers"],["resetSelectedServer"])),e.serviceFactory("ShlinkWebComponent",()=>T8e),e.factory("ShlinkWebComponentContainer",D8e),e.decorator("ShlinkWebComponentContainer",t(["selectedServer","settings"],["selectServer"])),e.serviceFactory("ShlinkVersionsContainer",()=>I8e),e.decorator("ShlinkVersionsContainer",t(["selectedServer"])),e.serviceFactory("ErrorHandler",()=>j8e)};var In=[];for(var Px=0;Px<256;++Px)In.push((Px+256).toString(16).slice(1));function B8e(e,t=0){return(In[e[t+0]]+In[e[t+1]]+In[e[t+2]]+In[e[t+3]]+"-"+In[e[t+4]]+In[e[t+5]]+"-"+In[e[t+6]]+In[e[t+7]]+"-"+In[e[t+8]]+In[e[t+9]]+"-"+In[e[t+10]]+In[e[t+11]]+In[e[t+12]]+In[e[t+13]]+In[e[t+14]]+In[e[t+15]]).toLowerCase()}var Mv,U8e=new Uint8Array(16);function z8e(){if(!Mv&&(Mv=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Mv))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Mv(U8e)}var V8e=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);const F$={randomUUID:V8e};function yV(e,t,n){if(F$.randomUUID&&!t&&!e)return F$.randomUUID();e=e||{};var r=e.random||(e.rng||z8e)();if(r[6]=r[6]&15|64,r[8]=r[8]&63|128,t){n=n||0;for(var i=0;i<16;++i)t[n+i]=r[i];return t}return B8e(r)}const bV=()=>{const e=Eo();return R.useCallback(()=>e(-1),[e])},W8e=()=>{const{search:e}=pr();return R.useMemo(()=>JP(e),[e])},_V=({isOpen:e,duplicatedServers:t,onDiscard:n,onSave:r})=>{const i=t.length>1;return m.jsxs(Po,{centered:!0,isOpen:e,children:[m.jsxs(Co,{children:["Duplicated server",i&&"s"]}),m.jsxs(Wi,{children:[m.jsx("p",{children:i?"The next servers already exist:":"There is already a server with:"}),m.jsx("ul",{children:t.map(({url:o,apiKey:a},s)=>i?m.jsxs("li",{children:[m.jsx("b",{children:o})," - ",m.jsx("b",{children:a})]},s):m.jsxs(R.Fragment,{children:[m.jsxs("li",{children:["URL: ",m.jsx("b",{children:o})]}),m.jsxs("li",{children:["API key: ",m.jsx("b",{children:a})]})]},s))}),m.jsxs("span",{children:[i?"Do you want to ignore duplicated servers":"Do you want to save this server anyway","?"]})]}),m.jsxs(gs,{children:[m.jsx(Ye,{color:"link",onClick:n,children:i?"Ignore duplicates":"Discard"}),m.jsx(Ye,{color:"primary",onClick:r,children:"Save anyway"})]})]})},H8e=e=>t=>{t.preventDefault(),e()},xV=({onSubmit:e,initialValues:t,children:n,title:r})=>{const[i,o]=R.useState(""),[a,s]=R.useState(""),[l,u]=R.useState(""),f=H8e(()=>e({name:i,url:a,apiKey:l}));return R.useEffect(()=>{t&&o(t.name),t&&s(t.url),t&&u(t.apiKey)},[t]),m.jsxs("form",{className:"server-form",name:"serverForm",onSubmit:f,children:[m.jsxs(Ot,{className:"mb-3",title:r,children:[m.jsx(Jv,{value:i,onChange:o,children:"Name"}),m.jsx(Jv,{type:"url",value:a,onChange:s,children:"URL"}),m.jsx(Jv,{value:l,onChange:u,children:"API key"})]}),m.jsx("div",{className:"text-end",children:n})]})},B$=4e3,U$=({type:e})=>m.jsx("div",{className:"mt-3",children:m.jsxs(ur,{type: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."]})}),wV=({servers:e,createServers:t})=>{const{ImportServersBtn:n,useTimeoutToggle:r}=Hi(wV),i=Eo(),o=bV(),a=!!Object.keys(e).length,[s,l]=r(!1,B$),[u,f]=r(!1,B$),[d,h]=Zt(),[v,g]=R.useState(),y=R.useCallback(x=>{const _=yV();t([{...x,id:_}]),i(`/server/${_}`)},[t,i]);return R.useEffect(()=>{if(!v)return;Object.values(e).some(({url:_,apiKey:b})=>(v==null?void 0:v.url)===_&&(v==null?void 0:v.apiKey)===b)?h():y(v)},[y,v,e,h]),m.jsxs(wf,{children:[m.jsxs(xV,{title:m.jsx("h5",{className:"mb-0",children:"Add new server"}),onSubmit:g,children:[!a&&m.jsx(n,{tooltipPlacement:"top",onImport:l,onImportError:f}),a&&m.jsx(Ye,{outline:!0,onClick:o,children:"Cancel"}),m.jsx(Ye,{outline:!0,color:"primary",className:"ms-2",children:"Create server"})]}),s&&m.jsx(U$,{type:"success"}),u&&m.jsx(U$,{type:"error"}),m.jsx(_V,{isOpen:d,duplicatedServers:v?[v]:[],onDiscard:o,onSave:()=>v&&y(v)})]})},G8e=Gi(wV,["ImportServersBtn","useTimeoutToggle"]),OV=({server:e,className:t,children:n,textClassName:r})=>{const{DeleteServerModal:i}=Hi(OV),[o,,a,s]=Zt();return m.jsxs(m.Fragment,{children:[m.jsxs("button",{type:"button",className:Pe(t,"p-0 bg-transparent border-0"),onClick:a,children:[!n&&m.jsx(je,{fixedWidth:!0,icon:fP}),m.jsx("span",{className:r,children:n??"Remove this server"})]}),m.jsx(i,{server:e,isOpen:o,toggle:s})]})},q8e=Gi(OV,["DeleteServerModal"]),K8e=({server:e,toggle:t,isOpen:n,deleteServer:r,redirectHome:i=!0})=>{const o=Eo(),a=R.useRef(!1),s=()=>{a.current=!0,t()},l=()=>{a.current&&(r(e),i&&o("/"))};return m.jsxs(Po,{isOpen:n,toggle:t,centered:!0,onClosed:l,children:[m.jsx(Co,{toggle:t,className:"text-danger",children:"Remove server"}),m.jsxs(Wi,{children:[m.jsxs("p",{children:["Are you sure you want to remove ",m.jsx("b",{children:e?e.name:""}),"?"]}),m.jsx("p",{children:m.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."})})]}),m.jsxs(gs,{children:[m.jsx(Ye,{color:"link",onClick:t,children:"Cancel"}),m.jsx(Ye,{color:"danger",onClick:s,children:"Delete"})]})]})},Y8e=vV(({editServer:e,selectedServer:t,selectServer:n})=>{const r=bV(),{reconnect:i}=W8e();if(!Ad(t))return null;const o=a=>{e(t.id,a),i==="true"&&n(t.id),r()};return m.jsx(wf,{children:m.jsxs(xV,{title:m.jsxs("h5",{className:"mb-0",children:['Edit "',t.name,'"']}),initialValues:t,onSubmit:o,children:[m.jsx(Ye,{outline:!0,className:"me-2",onClick:r,children:"Cancel"}),m.jsx(Ye,{outline:!0,color:"primary",children:"Save"})]})})}),Z8e=Gi(Y8e,["ServerError"]),z$=(e,{url:t,apiKey:n})=>e.some(r=>r.url===t&&r.apiKey===n),SV=({createServers:e,servers:t,children:n,onImport:r=()=>{},onImportError:i=()=>{},tooltipPlacement:o="bottom",className:a=""})=>{const{ServersImporter:s}=Hi(SV),l=ca(),[u,f]=R.useState([]),[d,,h,v]=Zt(),g=R.useRef([]),y=R.useCallback(w=>{e(w),r()},[e,r]),x=R.useCallback(async({target:w})=>{var S;return s.importServersFromFile((S=w.files)==null?void 0:S[0]).then(E=>{g.current=E;const P=Object.values(t),T=E.filter(D=>z$(P,D)),A=!!T.length;A?f(T):y(E),A&&h()}).then(()=>{w.value=null}).catch(i)},[y,i,t,s,h]),_=R.useCallback(()=>{y(g.current),v()},[y,v,g]),b=R.useCallback(()=>{y(g.current.filter(w=>!z$(u,w))),v()},[y,u,v]);return m.jsxs(m.Fragment,{children:[m.jsxs(Ye,{outline:!0,id:"importBtn",className:a,onClick:()=>{var w;return(w=l.current)==null?void 0:w.click()},children:[m.jsx(je,{icon:gZ,fixedWidth:!0})," ",n??"Import from file"]}),m.jsxs(Tr,{placement:o,target:"importBtn",children:["You can create servers by importing a CSV file with ",m.jsx("b",{children:"name"}),", ",m.jsx("b",{children:"apiKey"})," and ",m.jsx("b",{children:"url"})," columns."]}),m.jsx("input",{type:"file",accept:".csv",className:"d-none",ref:l,onChange:x,"aria-hidden":!0}),m.jsx(_V,{isOpen:d,duplicatedServers:u,onDiscard:b,onSave:_})]})},X8e=Gi(SV,["ServersImporter"]),EV=({servers:e,selectedServer:t})=>{const{DeleteServerButton:n}=Hi(EV);return m.jsx(wf,{children:m.jsxs("div",{className:"server-error__container flex-column",children:[m.jsxs(ta,{className:"w-100 mb-3 mb-md-5",type:"error",fullWidth:!0,children:[!Ad(t)&&"Could not find this Shlink server.",Ad(t)&&m.jsxs(m.Fragment,{children:[m.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."]})]}),m.jsx(cV,{servers:Object.values(e),children:m.jsxs("p",{className:"mb-md-3",children:["These are the Shlink servers currently configured. Choose one of them or ",m.jsx(Pt,{to:"/server/create",children:"add a new one"}),"."]})}),Ad(t)&&m.jsx("div",{className:"container mt-3 mt-md-5",children:m.jsxs("p",{className:"fs-5 fw-normal lh-sm",children:["Alternatively, if you think you may have miss-configured this server, you can ",m.jsx(n,{server:t,className:"server-error__delete-btn",children:"remove it"})," or ",m.jsx(Pt,{to:`/server/${t.id}/edit?reconnect=true`,children:"edit it"}),"."]})})]})})},Q8e=Gi(EV,["DeleteServerButton"]),J8e=4e3,PV=({servers:e})=>{const{ServersExporter:t,ImportServersBtn:n,useTimeoutToggle:r,ManageServersRow:i}=Hi(PV),o=Object.values(e),[a,s]=R.useState(o),l=h=>s(o.filter(({name:v,url:g})=>`${v} ${g}`.toLowerCase().match(h.toLowerCase()))),u=a.some(({autoConnect:h})=>!!h),[f,d]=r(!1,J8e);return R.useEffect(()=>{s(Object.values(e))},[e]),m.jsxs(wf,{children:[m.jsx(Up,{className:"mb-3",onChange:l}),m.jsxs(rr,{className:"mb-3",children:[m.jsxs("div",{className:"col-md-6 d-flex d-md-block mb-2 mb-md-0",children:[m.jsx(n,{className:"flex-fill",onImportError:d,children:"Import servers"}),o.length>0&&m.jsxs(Ye,{outline:!0,className:"ms-2 flex-fill",onClick:async()=>t.exportServers(),children:[m.jsx(je,{icon:UD,fixedWidth:!0})," Export servers"]})]}),m.jsx("div",{className:"col-md-6 text-md-end d-flex d-md-block",children:m.jsxs(Ye,{outline:!0,color:"primary",className:"flex-fill",tag:Pt,to:"/server/create",children:[m.jsx(je,{icon:Tp,fixedWidth:!0})," Add a server"]})})]}),m.jsx(Ot,{children:m.jsxs("table",{className:"table table-hover responsive-table mb-0",children:[m.jsx("thead",{className:"responsive-table__header",children:m.jsxs("tr",{children:[u&&m.jsx("th",{style:{width:"50px"},children:m.jsx("span",{className:"sr-only",children:"Auto-connect"})}),m.jsx("th",{children:"Name"}),m.jsx("th",{children:"Base URL"}),m.jsx("th",{children:m.jsx("span",{className:"sr-only",children:"Options"})})]})}),m.jsxs("tbody",{children:[!a.length&&m.jsx("tr",{className:"text-center",children:m.jsx("td",{colSpan:4,children:"No servers found."})}),a.map(h=>m.jsx(i,{server:h,hasAutoConnect:u},h.id))]})]})}),f&&m.jsx("div",{className:"mt-3",children:m.jsx(ur,{type:"error",children:"The servers could not be imported. Make sure the format is correct."})})]})},eFe=Gi(PV,["ServersExporter","ImportServersBtn","useTimeoutToggle","ManageServersRow"]),CV=({server:e,hasAutoConnect:t})=>{const{ManageServersRowDropdown:n}=Hi(CV);return m.jsxs("tr",{className:"responsive-table__row",children:[t&&m.jsx("td",{className:"responsive-table__cell","data-th":"Auto-connect",children:e.autoConnect&&m.jsxs(m.Fragment,{children:[m.jsx(je,{icon:gh,className:"text-primary",id:"autoConnectIcon"}),m.jsx(Tr,{target:"autoConnectIcon",placement:"right",children:"Auto-connect to this server"})]})}),m.jsx("th",{className:"responsive-table__cell","data-th":"Name",children:m.jsx(Pt,{to:`/server/${e.id}`,children:e.name})}),m.jsx("td",{className:"responsive-table__cell","data-th":"Base URL",children:e.url}),m.jsx("td",{className:"responsive-table__cell text-end",children:m.jsx(n,{server:e})})]})},tFe=Gi(CV,["ManageServersRowDropdown"]),TV=({server:e,setAutoConnect:t})=>{const{DeleteServerModal:n}=Hi(TV),[r,,i,o]=Zt(),a=`/server/${e.id}`,{autoConnect:s}=e,l=s?mZ:Ffe;return m.jsxs(ab,{minWidth:s?210:170,children:[m.jsxs(Ne,{tag:Pt,to:a,children:[m.jsx(je,{icon:hZ,fixedWidth:!0})," Connect"]}),m.jsxs(Ne,{tag:Pt,to:`${a}/edit`,children:[m.jsx(je,{icon:dP,fixedWidth:!0})," Edit server"]}),m.jsxs(Ne,{onClick:()=>t(e,!s),children:[m.jsx(je,{icon:l,fixedWidth:!0})," ",s?"Do not a":"A","uto-connect"]}),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsxs(Ne,{className:"dropdown-item--danger",onClick:i,children:[m.jsx(je,{icon:fP,fixedWidth:!0})," Remove server"]}),m.jsx(n,{redirectHome:!1,server:e,isOpen:r,toggle:o})]})},nFe=Gi(TV,["DeleteServerModal"]),jV=(e,t)=>iF(e,t,{serializeError:n=>n}),rFe={},iFe=e=>"id"in e?e:{...e,id:yV()},oFe=e=>e.reduce((t,n)=>({...t,[n.id]:n}),{}),{actions:aFe,reducer:sFe}=nn({name:"shlink/servers",initialState:rFe,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,o])=>[i,{...o,autoConnect:i===n}])):{...e,[n]:{...e[n],autoConnect:r}}:e}},createServers:{prepare:e=>({payload:oFe(e.map(iFe))}),reducer:(e,{payload:t})=>({...e,...t})}}}),{editServer:lFe,deleteServer:uFe,setAutoConnect:cFe,createServers:AV}=aFe,fFe=sFe,dFe=e=>Array.isArray(e)?e.filter(LD):[],hFe=e=>jV("shlink/remoteServers/fetchServers",async(t,{dispatch:n})=>{const r=await e.jsonRequest(`${Lg.homepage}/servers.json`),i=dFe(r);n(AV(i))}),YT="shlink/selectedServer",pFe="1.0.0",mFe="999.999.999",vFe="latest",gFe=e=>mV(e===vFe?mFe:e,pFe),yFe=aF(e=>`${e.id}_${e.url}_${e.apiKey}`,async(e,t)=>t().then(({version:n})=>({version:gFe(n),printableVersion:pV(n)}))),V$=null,ZT=mn(`${YT}/resetSelectedServer`),bFe=e=>jV(`${YT}/selectServer`,async(t,{dispatch:n,getState:r})=>{n(ZT());const{servers:i}=r(),o=i[t];if(!o)return{serverNotFound:!0};try{const a=e(o),{version:s,printableVersion:l}=await yFe(o,()=>a.health());return{...o,version:s,printableVersion:l}}catch{return{...o,serverNotReachable:!0}}}),_Fe=e=>nn({name:YT,initialState:V$,reducers:{},extraReducers:t=>{t.addCase(ZT,()=>V$),t.addCase(e.fulfilled,(n,{payload:r})=>r)}}),xFe=({servers:e,selectedServer:t})=>{const n=Object.values(e),r=()=>n.length===0?m.jsxs(Ne,{tag:Pt,to:"/server/create",children:[m.jsx(je,{icon:Tp})," ",m.jsx("span",{className:"ms-1",children:"Add a server"})]}):m.jsxs(m.Fragment,{children:[n.map(({name:i,id:o})=>m.jsx(Ne,{tag:Pt,to:`/server/${o}`,active:QY(t)===o,children:i},o)),m.jsx(Ne,{divider:!0,tag:"hr"}),m.jsxs(Ne,{tag:Pt,to:"/manage-servers",children:[m.jsx(je,{icon:xk})," ",m.jsx("span",{className:"ms-1",children:"Manage servers"})]})]});return m.jsxs(Ip,{nav:!0,inNavbar:!0,children:[m.jsxs(Zc,{nav:!0,caret:!0,children:[m.jsx(je,{icon:xk})," ",m.jsx("span",{className:"ms-1",children:"Servers"})]}),m.jsx(Yc,{end:!0,style:{right:0},children:r()})]})},wFe=({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)},OFe=(e,t,n)=>{const r=new Blob([t],{type:"text/csv;charset=utf-8;"}),i=URL.createObjectURL(r);wFe(e,i,n)},SFe="shlink-servers.csv";class EFe{constructor(t,n,r){Ql(this,"exportServers",async()=>{const t=Object.values(this.storage.get("servers")??{}).map(JY);try{const n=this.jsonToCsv(t);OFe(this.window,n,SFe)}catch(n){console.error(n)}});this.storage=t,this.window=n,this.jsonToCsv=r}}const PFe=e=>typeof e.url=="string"&&typeof e.apiKey=="string"&&typeof e.name=="string",CFe=e=>Array.isArray(e)&&e.every(PFe);class TFe{constructor(t){this.csvToJson=t}async importServersFromFile(t){if(!t)throw new Error("No file provided");const n=await t.text(),r=await this.csvToJson(n);if(!CFe(r))throw new Error("Provided file does not have the right format.");return r}}const jFe=(e,t)=>{e.factory("ManageServers",eFe),e.decorator("ManageServers",C0),e.decorator("ManageServers",t(["selectedServer","servers"],["resetSelectedServer"])),e.factory("ManageServersRow",tFe),e.factory("ManageServersRowDropdown",nFe),e.decorator("ManageServersRowDropdown",t(null,["setAutoConnect"])),e.factory("CreateServer",G8e),e.decorator("CreateServer",C0),e.decorator("CreateServer",t(["selectedServer","servers"],["createServers","resetSelectedServer"])),e.factory("EditServer",Z8e),e.decorator("EditServer",t(["selectedServer"],["editServer","selectServer","resetSelectedServer"])),e.serviceFactory("ServersDropdown",()=>xFe),e.decorator("ServersDropdown",t(["servers","selectedServer"])),e.serviceFactory("DeleteServerModal",()=>K8e),e.decorator("DeleteServerModal",t(null,["deleteServer"])),e.factory("DeleteServerButton",q8e),e.factory("ImportServersBtn",X8e),e.decorator("ImportServersBtn",t(["servers"],["createServers"])),e.factory("ServerError",Q8e),e.decorator("ServerError",t(["servers","selectedServer"])),e.service("ServersImporter",TFe,"csvToJson"),e.service("ServersExporter",EFe,"Storage","window","jsonToCsv"),e.serviceFactory("selectServer",bFe,"buildShlinkApiClient","loadMercureInfo"),e.serviceFactory("createServers",()=>AV),e.serviceFactory("deleteServer",()=>uFe),e.serviceFactory("editServer",()=>lFe),e.serviceFactory("setAutoConnect",()=>cFe),e.serviceFactory("fetchServers",hFe,"HttpClient"),e.serviceFactory("resetSelectedServer",()=>ZT),e.serviceFactory("selectedServerReducerCreator",_Fe,"selectServer"),e.serviceFactory("selectedServerReducer",n=>n.reducer,"selectedServerReducerCreator")},kV={field:"dateCreated",dir:"DESC"},AFe={realTimeUpdates:{enabled:!0},shortUrlCreation:{validateUrls:!1},ui:{theme:nC()},visits:{defaultInterval:"last30Days"},shortUrlsList:{defaultOrdering:kV}},{reducer:kFe,actions:NFe}=nn({name:"shlink/settings",initialState:AFe,reducers:{setSettings:(e,{payload:t})=>db(e,t)}}),{setSettings:MFe}=NFe,RFe=kFe,LFe=({settings:e,setSettings:t})=>m.jsx(wf,{children:m.jsx($fe,{settings:e,updateSettings:t,defaultShortUrlsListOrdering:kV})}),$Fe=(e,t)=>{e.serviceFactory("Settings",()=>LFe),e.decorator("Settings",C0),e.decorator("Settings",t(["settings"],["setSettings","resetSelectedServer"])),e.serviceFactory("setSettings",()=>MFe)};var IFe=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,o){n.o(r,i)||Object.defineProperty(r,i,{enumerable:!0,get:o})},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 o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:r}),2&i&&typeof r!="string")for(var a in r)n.d(o,a,(function(s){return r[s]}).bind(null,a));return o},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(g){var y=[];for(var x in g)y.push(x);return y};e.exports=d;var o=n(5);o.inherits=n(2);var a=n(23),s=n(14);o.inherits(d,a);for(var l=i(s.prototype),u=0;u * @license MIT */var i=n(38),o=n(39),a=n(40);function s(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function l(j,N){if(s()=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|j}function y(j,N){if(u.isBuffer(j))return j.length;if(typeof ArrayBuffer<"u"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(j)||j instanceof ArrayBuffer))return j.byteLength;typeof j!="string"&&(j=""+j);var U=j.length;if(U===0)return 0;for(var J=!1;;)switch(N){case"ascii":case"latin1":case"binary":return U;case"utf8":case"utf-8":case void 0:return ie(j).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*U;case"hex":return U>>>1;case"base64":return ae(j).length;default:if(J)return ie(j).length;N=(""+N).toLowerCase(),J=!0}}function x(j,N,U){var J=j[N];j[N]=j[U],j[U]=J}function _(j,N,U,J,Y){if(j.length===0)return-1;if(typeof U=="string"?(J=U,U=0):U>2147483647?U=2147483647:U<-2147483648&&(U=-2147483648),U=+U,isNaN(U)&&(U=Y?0:j.length-1),U<0&&(U=j.length+U),U>=j.length){if(Y)return-1;U=j.length-1}else if(U<0){if(!Y)return-1;U=0}if(typeof N=="string"&&(N=u.from(N,J)),u.isBuffer(N))return N.length===0?-1:b(j,N,U,J,Y);if(typeof N=="number")return N&=255,u.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?Y?Uint8Array.prototype.indexOf.call(j,N,U):Uint8Array.prototype.lastIndexOf.call(j,N,U):b(j,[N],U,J,Y);throw new TypeError("val must be string, number or Buffer")}function b(j,N,U,J,Y){var oe,he=1,Se=j.length,se=N.length;if(J!==void 0&&((J=String(J).toLowerCase())==="ucs2"||J==="ucs-2"||J==="utf16le"||J==="utf-16le")){if(j.length<2||N.length<2)return-1;he=2,Se/=2,se/=2,U/=2}function pe(Ce,Ae){return he===1?Ce[Ae]:Ce.readUInt16BE(Ae*he)}if(Y){var me=-1;for(oe=U;oeSe&&(U=Se-se),oe=U;oe>=0;oe--){for(var xe=!0,Te=0;TeY&&(J=Y):J=Y;var oe=N.length;if(oe%2!=0)throw new TypeError("Invalid hex string");J>oe/2&&(J=oe/2);for(var he=0;he>8,se=he%256,pe.push(se),pe.push(Se);return pe}(N,j.length-U),j,U,J)}function D(j,N,U){return N===0&&U===j.length?i.fromByteArray(j):i.fromByteArray(j.slice(N,U))}function k(j,N,U){U=Math.min(j.length,U);for(var J=[],Y=N;Y239?4:pe>223?3:pe>191?2:1;if(Y+xe<=U)switch(xe){case 1:pe<128&&(me=pe);break;case 2:(192&(oe=j[Y+1]))==128&&(se=(31&pe)<<6|63&oe)>127&&(me=se);break;case 3:oe=j[Y+1],he=j[Y+2],(192&oe)==128&&(192&he)==128&&(se=(15&pe)<<12|(63&oe)<<6|63&he)>2047&&(se<55296||se>57343)&&(me=se);break;case 4:oe=j[Y+1],he=j[Y+2],Se=j[Y+3],(192&oe)==128&&(192&he)==128&&(192&Se)==128&&(se=(15&pe)<<18|(63&oe)<<12|(63&he)<<6|63&Se)>65535&&se<1114112&&(me=se)}me===null?(me=65533,xe=1):me>65535&&(me-=65536,J.push(me>>>10&1023|55296),me=56320|1023&me),J.push(me),Y+=xe}return function(Te){var Ce=Te.length;if(Ce<=I)return String.fromCharCode.apply(String,Te);for(var Ae="",le=0;lethis.length||((J===void 0||J>this.length)&&(J=this.length),J<=0)||(J>>>=0)<=(U>>>=0))return"";for(N||(N="utf8");;)switch(N){case"hex":return W(this,U,J);case"utf8":case"utf-8":return k(this,U,J);case"ascii":return F(this,U,J);case"latin1":case"binary":return q(this,U,J);case"base64":return D(this,U,J);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return X(this,U,J);default:if(Y)throw new TypeError("Unknown encoding: "+N);N=(N+"").toLowerCase(),Y=!0}}).apply(this,arguments)},u.prototype.equals=function(j){if(!u.isBuffer(j))throw new TypeError("Argument must be a Buffer");return this===j||u.compare(this,j)===0},u.prototype.inspect=function(){var j="",N=t.INSPECT_MAX_BYTES;return this.length>0&&(j=this.toString("hex",0,N).match(/.{2}/g).join(" "),this.length>N&&(j+=" ... ")),""},u.prototype.compare=function(j,N,U,J,Y){if(!u.isBuffer(j))throw new TypeError("Argument must be a Buffer");if(N===void 0&&(N=0),U===void 0&&(U=j?j.length:0),J===void 0&&(J=0),Y===void 0&&(Y=this.length),N<0||U>j.length||J<0||Y>this.length)throw new RangeError("out of range index");if(J>=Y&&N>=U)return 0;if(J>=Y)return-1;if(N>=U)return 1;if(N>>>=0,U>>>=0,J>>>=0,Y>>>=0,this===j)return 0;for(var oe=Y-J,he=U-N,Se=Math.min(oe,he),se=this.slice(J,Y),pe=j.slice(N,U),me=0;meY)&&(U=Y),j.length>0&&(U<0||N<0)||N>this.length)throw new RangeError("Attempt to write outside buffer bounds");J||(J="utf8");for(var oe=!1;;)switch(J){case"hex":return w(this,j,N,U);case"utf8":case"utf-8":return S(this,j,N,U);case"ascii":return E(this,j,N,U);case"latin1":case"binary":return P(this,j,N,U);case"base64":return T(this,j,N,U);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,j,N,U);default:if(oe)throw new TypeError("Unknown encoding: "+J);J=(""+J).toLowerCase(),oe=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var I=4096;function F(j,N,U){var J="";U=Math.min(j.length,U);for(var Y=N;YJ)&&(U=J);for(var Y="",oe=N;oeU)throw new RangeError("Trying to access beyond buffer length")}function ne(j,N,U,J,Y,oe){if(!u.isBuffer(j))throw new TypeError('"buffer" argument must be a Buffer instance');if(N>Y||Nj.length)throw new RangeError("Index out of range")}function Z(j,N,U,J){N<0&&(N=65535+N+1);for(var Y=0,oe=Math.min(j.length-U,2);Y>>8*(J?Y:1-Y)}function z(j,N,U,J){N<0&&(N=4294967295+N+1);for(var Y=0,oe=Math.min(j.length-U,4);Y>>8*(J?Y:3-Y)&255}function B(j,N,U,J,Y,oe){if(U+J>j.length)throw new RangeError("Index out of range");if(U<0)throw new RangeError("Index out of range")}function H(j,N,U,J,Y){return Y||B(j,0,U,4),o.write(j,N,U,J,23,4),U+4}function ee(j,N,U,J,Y){return Y||B(j,0,U,8),o.write(j,N,U,J,52,8),U+8}u.prototype.slice=function(j,N){var U,J=this.length;if(j=~~j,N=N===void 0?J:~~N,j<0?(j+=J)<0&&(j=0):j>J&&(j=J),N<0?(N+=J)<0&&(N=0):N>J&&(N=J),N0&&(Y*=256);)J+=this[j+--N]*Y;return J},u.prototype.readUInt8=function(j,N){return N||Q(j,1,this.length),this[j]},u.prototype.readUInt16LE=function(j,N){return N||Q(j,2,this.length),this[j]|this[j+1]<<8},u.prototype.readUInt16BE=function(j,N){return N||Q(j,2,this.length),this[j]<<8|this[j+1]},u.prototype.readUInt32LE=function(j,N){return N||Q(j,4,this.length),(this[j]|this[j+1]<<8|this[j+2]<<16)+16777216*this[j+3]},u.prototype.readUInt32BE=function(j,N){return N||Q(j,4,this.length),16777216*this[j]+(this[j+1]<<16|this[j+2]<<8|this[j+3])},u.prototype.readIntLE=function(j,N,U){j|=0,N|=0,U||Q(j,N,this.length);for(var J=this[j],Y=1,oe=0;++oe=(Y*=128)&&(J-=Math.pow(2,8*N)),J},u.prototype.readIntBE=function(j,N,U){j|=0,N|=0,U||Q(j,N,this.length);for(var J=N,Y=1,oe=this[j+--J];J>0&&(Y*=256);)oe+=this[j+--J]*Y;return oe>=(Y*=128)&&(oe-=Math.pow(2,8*N)),oe},u.prototype.readInt8=function(j,N){return N||Q(j,1,this.length),128&this[j]?-1*(255-this[j]+1):this[j]},u.prototype.readInt16LE=function(j,N){N||Q(j,2,this.length);var U=this[j]|this[j+1]<<8;return 32768&U?4294901760|U:U},u.prototype.readInt16BE=function(j,N){N||Q(j,2,this.length);var U=this[j+1]|this[j]<<8;return 32768&U?4294901760|U:U},u.prototype.readInt32LE=function(j,N){return N||Q(j,4,this.length),this[j]|this[j+1]<<8|this[j+2]<<16|this[j+3]<<24},u.prototype.readInt32BE=function(j,N){return N||Q(j,4,this.length),this[j]<<24|this[j+1]<<16|this[j+2]<<8|this[j+3]},u.prototype.readFloatLE=function(j,N){return N||Q(j,4,this.length),o.read(this,j,!0,23,4)},u.prototype.readFloatBE=function(j,N){return N||Q(j,4,this.length),o.read(this,j,!1,23,4)},u.prototype.readDoubleLE=function(j,N){return N||Q(j,8,this.length),o.read(this,j,!0,52,8)},u.prototype.readDoubleBE=function(j,N){return N||Q(j,8,this.length),o.read(this,j,!1,52,8)},u.prototype.writeUIntLE=function(j,N,U,J){j=+j,N|=0,U|=0,J||ne(this,j,N,U,Math.pow(2,8*U)-1,0);var Y=1,oe=0;for(this[N]=255&j;++oe=0&&(oe*=256);)this[N+Y]=j/oe&255;return N+U},u.prototype.writeUInt8=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,1,255,0),u.TYPED_ARRAY_SUPPORT||(j=Math.floor(j)),this[N]=255&j,N+1},u.prototype.writeUInt16LE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[N]=255&j,this[N+1]=j>>>8):Z(this,j,N,!0),N+2},u.prototype.writeUInt16BE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[N]=j>>>8,this[N+1]=255&j):Z(this,j,N,!1),N+2},u.prototype.writeUInt32LE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[N+3]=j>>>24,this[N+2]=j>>>16,this[N+1]=j>>>8,this[N]=255&j):z(this,j,N,!0),N+4},u.prototype.writeUInt32BE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[N]=j>>>24,this[N+1]=j>>>16,this[N+2]=j>>>8,this[N+3]=255&j):z(this,j,N,!1),N+4},u.prototype.writeIntLE=function(j,N,U,J){if(j=+j,N|=0,!J){var Y=Math.pow(2,8*U-1);ne(this,j,N,U,Y-1,-Y)}var oe=0,he=1,Se=0;for(this[N]=255&j;++oe>0)-Se&255;return N+U},u.prototype.writeIntBE=function(j,N,U,J){if(j=+j,N|=0,!J){var Y=Math.pow(2,8*U-1);ne(this,j,N,U,Y-1,-Y)}var oe=U-1,he=1,Se=0;for(this[N+oe]=255&j;--oe>=0&&(he*=256);)j<0&&Se===0&&this[N+oe+1]!==0&&(Se=1),this[N+oe]=(j/he>>0)-Se&255;return N+U},u.prototype.writeInt8=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,1,127,-128),u.TYPED_ARRAY_SUPPORT||(j=Math.floor(j)),j<0&&(j=255+j+1),this[N]=255&j,N+1},u.prototype.writeInt16LE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[N]=255&j,this[N+1]=j>>>8):Z(this,j,N,!0),N+2},u.prototype.writeInt16BE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[N]=j>>>8,this[N+1]=255&j):Z(this,j,N,!1),N+2},u.prototype.writeInt32LE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[N]=255&j,this[N+1]=j>>>8,this[N+2]=j>>>16,this[N+3]=j>>>24):z(this,j,N,!0),N+4},u.prototype.writeInt32BE=function(j,N,U){return j=+j,N|=0,U||ne(this,j,N,4,2147483647,-2147483648),j<0&&(j=4294967295+j+1),u.TYPED_ARRAY_SUPPORT?(this[N]=j>>>24,this[N+1]=j>>>16,this[N+2]=j>>>8,this[N+3]=255&j):z(this,j,N,!1),N+4},u.prototype.writeFloatLE=function(j,N,U){return H(this,j,N,!0,U)},u.prototype.writeFloatBE=function(j,N,U){return H(this,j,N,!1,U)},u.prototype.writeDoubleLE=function(j,N,U){return ee(this,j,N,!0,U)},u.prototype.writeDoubleBE=function(j,N,U){return ee(this,j,N,!1,U)},u.prototype.copy=function(j,N,U,J){if(U||(U=0),J||J===0||(J=this.length),N>=j.length&&(N=j.length),N||(N=0),J>0&&J=this.length)throw new RangeError("sourceStart out of bounds");if(J<0)throw new RangeError("sourceEnd out of bounds");J>this.length&&(J=this.length),j.length-N=0;--Y)j[Y+N]=this[Y+U];else if(oe<1e3||!u.TYPED_ARRAY_SUPPORT)for(Y=0;Y>>=0,U=U===void 0?this.length:U>>>0,j||(j=0),typeof j=="number")for(oe=N;oe55295&&U<57344){if(!Y){if(U>56319){(N-=3)>-1&&oe.push(239,191,189);continue}if(he+1===J){(N-=3)>-1&&oe.push(239,191,189);continue}Y=U;continue}if(U<56320){(N-=3)>-1&&oe.push(239,191,189),Y=U;continue}U=65536+(Y-55296<<10|U-56320)}else Y&&(N-=3)>-1&&oe.push(239,191,189);if(Y=null,U<128){if((N-=1)<0)break;oe.push(U)}else if(U<2048){if((N-=2)<0)break;oe.push(U>>6|192,63&U|128)}else if(U<65536){if((N-=3)<0)break;oe.push(U>>12|224,U>>6&63|128,63&U|128)}else{if(!(U<1114112))throw new Error("Invalid code point");if((N-=4)<0)break;oe.push(U>>18|240,U>>12&63|128,U>>6&63|128,63&U|128)}}return oe}function ae(j){return i.toByteArray(function(N){if((N=function(U){return U.trim?U.trim():U.replace(/^\s+|\s+$/g,"")}(N).replace(K,"")).length<2)return"";for(;N.length%4!=0;)N+="=";return N}(j))}function fe(j,N,U,J){for(var Y=0;Y=N.length||Y>=j.length);++Y)N[Y+U]=j[Y];return Y}}).call(this,n(0))},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(x){if(n===setTimeout)return setTimeout(x,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(x,0);try{return n(x,0)}catch{try{return n.call(null,x,0)}catch{return n.call(this,x,0)}}}(function(){try{n=typeof setTimeout=="function"?setTimeout:o}catch{n=o}try{r=typeof clearTimeout=="function"?clearTimeout:a}catch{r=a}})();var l,u=[],f=!1,d=-1;function h(){f&&l&&(f=!1,l.length?u=l.concat(u):d=-1,u.length&&v())}function v(){if(!f){var x=s(h);f=!0;for(var _=u.length;_;){for(l=u,u=[];++d<_;)l&&l[d].run();d=-1,_=u.length}l=null,f=!1,function(b){if(r===clearTimeout)return clearTimeout(b);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(b);try{r(b)}catch{try{return r.call(null,b)}catch{return r.call(this,b)}}}(x)}}function g(x,_){this.fun=x,this.array=_}function y(){}i.nextTick=function(x){var _=new Array(arguments.length-1);if(arguments.length>1)for(var b=1;b=0&&(s._idleTimeoutId=setTimeout(function(){s._onTimeout&&s._onTimeout()},l))},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(a){return typeof a=="function"}function i(a){return typeof a=="object"&&a!==null}function o(a){return a===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(a){if(!function(s){return typeof s=="number"}(a)||a<0||isNaN(a))throw TypeError("n must be a positive number");return this._maxListeners=a,this},n.prototype.emit=function(a){var s,l,u,f,d,h;if(this._events||(this._events={}),a==="error"&&(!this._events.error||i(this._events.error)&&!this._events.error.length)){if((s=arguments[1])instanceof Error)throw s;var v=new Error('Uncaught, unspecified "error" event. ('+s+")");throw v.context=s,v}if(o(l=this._events[a]))return!1;if(r(l))switch(arguments.length){case 1:l.call(this);break;case 2:l.call(this,arguments[1]);break;case 3:l.call(this,arguments[1],arguments[2]);break;default:f=Array.prototype.slice.call(arguments,1),l.apply(this,f)}else if(i(l))for(f=Array.prototype.slice.call(arguments,1),u=(h=l.slice()).length,d=0;d0&&this._events[a].length>l&&(this._events[a].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[a].length),typeof console.trace=="function"&&console.trace()),this},n.prototype.on=n.prototype.addListener,n.prototype.once=function(a,s){if(!r(s))throw TypeError("listener must be a function");var l=!1;function u(){this.removeListener(a,u),l||(l=!0,s.apply(this,arguments))}return u.listener=s,this.on(a,u),this},n.prototype.removeListener=function(a,s){var l,u,f,d;if(!r(s))throw TypeError("listener must be a function");if(!this._events||!this._events[a])return this;if(f=(l=this._events[a]).length,u=-1,l===s||r(l.listener)&&l.listener===s)delete this._events[a],this._events.removeListener&&this.emit("removeListener",a,s);else if(i(l)){for(d=f;d-- >0;)if(l[d]===s||l[d].listener&&l[d].listener===s){u=d;break}if(u<0)return this;l.length===1?(l.length=0,delete this._events[a]):l.splice(u,1),this._events.removeListener&&this.emit("removeListener",a,s)}return this},n.prototype.removeAllListeners=function(a){var s,l;if(!this._events)return this;if(!this._events.removeListener)return arguments.length===0?this._events={}:this._events[a]&&delete this._events[a],this;if(arguments.length===0){for(s in this._events)s!=="removeListener"&&this.removeAllListeners(s);return this.removeAllListeners("removeListener"),this._events={},this}if(r(l=this._events[a]))this.removeListener(a,l);else if(l)for(;l.length;)this.removeListener(a,l[l.length-1]);return delete this._events[a],this},n.prototype.listeners=function(a){return this._events&&this._events[a]?r(this._events[a])?[this._events[a]]:this._events[a].slice():[]},n.prototype.listenerCount=function(a){if(this._events){var s=this._events[a];if(r(s))return 1;if(s)return s.length}return 0},n.listenerCount=function(a,s){return a.listenerCount(s)}},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,o){var a=n(6);function s(k){var I=this;this.next=null,this.entry=null,this.finish=function(){(function(F,q,W){var X=F.entry;for(F.entry=null;X;){var Q=X.callback;q.pendingcb--,Q(void 0),X=X.next}q.corkedRequestsFree?q.corkedRequestsFree.next=F:q.corkedRequestsFree=F})(I,k)}}e.exports=w;var l,u=!r.browser&&["v0.10","v0.9."].indexOf(r.version.slice(0,5))>-1?i:a.nextTick;w.WritableState=b;var f=n(5);f.inherits=n(2);var d,h={deprecate:n(44)},v=n(24),g=n(7).Buffer,y=o.Uint8Array||function(){},x=n(25);function _(){}function b(k,I){l=l||n(1),k=k||{};var F=I instanceof l;this.objectMode=!!k.objectMode,F&&(this.objectMode=this.objectMode||!!k.writableObjectMode);var q=k.highWaterMark,W=k.writableHighWaterMark,X=this.objectMode?16:16384;this.highWaterMark=q||q===0?q:F&&(W||W===0)?W:X,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 Q=k.decodeStrings===!1;this.decodeStrings=!Q,this.defaultEncoding=k.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(ne){(function(Z,z){var B=Z._writableState,H=B.sync,ee=B.writecb;if(function(te){te.writing=!1,te.writecb=null,te.length-=te.writelen,te.writelen=0}(B),z)(function(te,ie,ae,fe,j){--ie.pendingcb,ae?(a.nextTick(j,fe),a.nextTick(D,te,ie),te._writableState.errorEmitted=!0,te.emit("error",fe)):(j(fe),te._writableState.errorEmitted=!0,te.emit("error",fe),D(te,ie))})(Z,B,H,z,ee);else{var K=T(B);K||B.corked||B.bufferProcessing||!B.bufferedRequest||P(Z,B),H?u(E,Z,B,K,ee):E(Z,B,K,ee)}})(I,ne)},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 s(this)}function w(k){if(l=l||n(1),!(d.call(w,this)||this instanceof l))return new w(k);this._writableState=new b(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)),v.call(this)}function S(k,I,F,q,W,X,Q){I.writelen=q,I.writecb=Q,I.writing=!0,I.sync=!0,F?k._writev(W,I.onwrite):k._write(W,X,I.onwrite),I.sync=!1}function E(k,I,F,q){F||function(W,X){X.length===0&&X.needDrain&&(X.needDrain=!1,W.emit("drain"))}(k,I),I.pendingcb--,q(),D(k,I)}function P(k,I){I.bufferProcessing=!0;var F=I.bufferedRequest;if(k._writev&&F&&F.next){var q=I.bufferedRequestCount,W=new Array(q),X=I.corkedRequestsFree;X.entry=F;for(var Q=0,ne=!0;F;)W[Q]=F,F.isBuf||(ne=!1),F=F.next,Q+=1;W.allBuffers=ne,S(k,I,!0,I.length,W,"",X.finish),I.pendingcb++,I.lastBufferedRequest=null,X.next?(I.corkedRequestsFree=X.next,X.next=null):I.corkedRequestsFree=new s(I),I.bufferedRequestCount=0}else{for(;F;){var Z=F.chunk,z=F.encoding,B=F.callback;if(S(k,I,!1,I.objectMode?1:Z.length,Z,z,B),F=F.next,I.bufferedRequestCount--,I.writing)break}F===null&&(I.lastBufferedRequest=null)}I.bufferedRequest=F,I.bufferProcessing=!1}function T(k){return k.ending&&k.length===0&&k.bufferedRequest===null&&!k.finished&&!k.writing}function A(k,I){k._final(function(F){I.pendingcb--,F&&k.emit("error",F),I.prefinished=!0,k.emit("prefinish"),D(k,I)})}function D(k,I){var F=T(I);return F&&(function(q,W){W.prefinished||W.finalCalled||(typeof q._final=="function"?(W.pendingcb++,W.finalCalled=!0,a.nextTick(A,q,W)):(W.prefinished=!0,q.emit("prefinish")))}(k,I),I.pendingcb===0&&(I.finished=!0,k.emit("finish"))),F}f.inherits(w,v),b.prototype.getBuffer=function(){for(var k=this.bufferedRequest,I=[];k;)I.push(k),k=k.next;return I},function(){try{Object.defineProperty(b.prototype,"buffer",{get:h.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"?(d=Function.prototype[Symbol.hasInstance],Object.defineProperty(w,Symbol.hasInstance,{value:function(k){return!!d.call(this,k)||this===w&&k&&k._writableState instanceof b}})):d=function(k){return k instanceof this},w.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},w.prototype.write=function(k,I,F){var q=this._writableState,W=!1,X=!q.objectMode&&function(Q){return g.isBuffer(Q)||Q instanceof y}(k);return X&&!g.isBuffer(k)&&(k=function(Q){return g.from(Q)}(k)),typeof I=="function"&&(F=I,I=null),X?I="buffer":I||(I=q.defaultEncoding),typeof F!="function"&&(F=_),q.ended?function(Q,ne){var Z=new Error("write after end");Q.emit("error",Z),a.nextTick(ne,Z)}(this,F):(X||function(Q,ne,Z,z){var B=!0,H=!1;return Z===null?H=new TypeError("May not write null values to stream"):typeof Z=="string"||Z===void 0||ne.objectMode||(H=new TypeError("Invalid non-string/buffer chunk")),H&&(Q.emit("error",H),a.nextTick(z,H),B=!1),B}(this,q,k,F))&&(q.pendingcb++,W=function(Q,ne,Z,z,B,H){if(!Z){var ee=function(ae,fe,j){return ae.objectMode||ae.decodeStrings===!1||typeof fe!="string"||(fe=g.from(fe,j)),fe}(ne,z,B);z!==ee&&(Z=!0,B="buffer",z=ee)}var K=ne.objectMode?1:z.length;ne.length+=K;var te=ne.length-1))throw new TypeError("Unknown encoding: "+k);return this._writableState.defaultEncoding=k,this},Object.defineProperty(w.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),w.prototype._write=function(k,I,F){F(new Error("_write() is not implemented"))},w.prototype._writev=null,w.prototype.end=function(k,I,F){var q=this._writableState;typeof k=="function"?(F=k,k=null,I=null):typeof I=="function"&&(F=I,I=null),k!=null&&this.write(k,I),q.corked&&(q.corked=1,this.uncork()),q.ending||q.finished||function(W,X,Q){X.ending=!0,D(W,X),Q&&(X.finished?a.nextTick(Q):W.once("finish",Q)),X.ended=!0,W.writable=!1}(this,q,F)},Object.defineProperty(w.prototype,"destroyed",{get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(k){this._writableState&&(this._writableState.destroyed=k)}}),w.prototype.destroy=x.destroy,w.prototype._undestroy=x.undestroy,w.prototype._destroy=function(k,I){this.end(),I(k)}}).call(this,n(4),n(11).setImmediate,n(0))},function(e,t,n){(function(r,i,o){e.exports=function a(s,l,u){function f(v,g){if(!l[v]){if(!s[v]){var y=typeof _dereq_=="function"&&_dereq_;if(!g&&y)return y(v,!0);if(d)return d(v,!0);var x=new Error("Cannot find module '"+v+"'");throw x.code="MODULE_NOT_FOUND",x}var _=l[v]={exports:{}};s[v][0].call(_.exports,function(b){return f(s[v][1][b]||b)},_,_.exports,a,s,l,u)}return l[v].exports}for(var d=typeof _dereq_=="function"&&_dereq_,h=0;h0;){var b=_.shift();if(typeof b=="function"){var w=_.shift(),S=_.shift();b.call(w,S)}else b._settlePromises()}},v.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,this._drainQueue(this._lateQueue)},v.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},v.prototype._reset=function(){this._isTickUsed=!1},s.exports=v,s.exports.firstLineError=u},{"./queue":26,"./schedule":29,"./util":36}],3:[function(a,s,l){s.exports=function(u,f,d,h){var v=!1,g=function(b,w){this._reject(w)},y=function(b,w){w.promiseRejectionQueued=!0,w.bindingPromise._then(g,g,null,this,b)},x=function(b,w){!(50397184&this._bitField)&&this._resolveCallback(w.target)},_=function(b,w){w.promiseRejectionQueued||this._reject(b)};u.prototype.bind=function(b){v||(v=!0,u.prototype._propagateFrom=h.propagateFromFunction(),u.prototype._boundValue=h.boundValueFunction());var w=d(b),S=new u(f);S._propagateFrom(this,1);var E=this._target();if(S._setBoundTo(w),w instanceof u){var P={promiseRejectionQueued:!1,promise:S,target:E,bindingPromise:w};E._then(f,y,void 0,S,P),w._then(x,_,void 0,S,P),S._setOnCancel(w)}else S._resolveCallback(E);return S},u.prototype._setBoundTo=function(b){b!==void 0?(this._bitField=2097152|this._bitField,this._boundTo=b):this._bitField=-2097153&this._bitField},u.prototype._isBound=function(){return(2097152&this._bitField)==2097152},u.bind=function(b,w){return u.resolve(w).bind(b)}}},{}],4:[function(a,s,l){var u;typeof Promise<"u"&&(u=Promise);var f=a("./promise")();f.noConflict=function(){try{Promise===f&&(Promise=u)}catch{}return f},s.exports=f},{"./promise":22}],5:[function(a,s,l){var u=Object.create;if(u){var f=u(null),d=u(null);f[" size"]=d[" size"]=0}s.exports=function(h){var v=a("./util"),g=v.canEvaluate;function y(b){return function(w,S){var E;if(w!=null&&(E=w[S]),typeof E!="function"){var P="Object "+v.classString(w)+" has no method '"+v.toString(S)+"'";throw new h.TypeError(P)}return E}(b,this.pop()).apply(b,this)}function x(b){return b[this]}function _(b){var w=+this;return w<0&&(w=Math.max(0,w+b.length)),b[w]}v.isIdentifier,h.prototype.call=function(b){var w=[].slice.call(arguments,1);return w.push(b),this._then(y,void 0,void 0,w,void 0)},h.prototype.get=function(b){var w;if(typeof b=="number")w=_;else if(g){var S=(void 0)(b);w=S!==null?S:x}else w=x;return this._then(w,void 0,void 0,b,void 0)}}},{"./util":36}],6:[function(a,s,l){s.exports=function(u,f,d,h){var v=a("./util"),g=v.tryCatch,y=v.errorObj,x=u._async;u.prototype.break=u.prototype.cancel=function(){if(!h.cancellation())return this._warn("cancellation is disabled");for(var _=this,b=_;_._isCancellable();){if(!_._cancelBy(b)){b._isFollowing()?b._followee().cancel():b._cancelBranched();break}var w=_._cancellationParent;if(w==null||!w._isCancellable()){_._isFollowing()?_._followee().cancel():_._cancelBranched();break}_._isFollowing()&&_._followee().cancel(),_._setWillBeCancelled(),b=_,_=w}},u.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},u.prototype._enoughBranchesHaveCancelled=function(){return this._branchesRemainingToCancel===void 0||this._branchesRemainingToCancel<=0},u.prototype._cancelBy=function(_){return _===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(),x.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(_,b){if(v.isArray(_))for(var w=0;w<_.length;++w)this._doInvokeOnCancel(_[w],b);else if(_!==void 0)if(typeof _=="function"){if(!b){var S=g(_).call(this._boundValue());S===y&&(this._attachExtraTrace(S.e),x.throwLater(S.e))}}else _._resultCancelled(this)},u.prototype._invokeOnCancel=function(){var _=this._onCancel();this._unsetOnCancel(),x.invoke(this._doInvokeOnCancel,this,_)},u.prototype._invokeInternalOnCancel=function(){this._isCancellable()&&(this._doInvokeOnCancel(this._onCancel(),!0),this._unsetOnCancel())},u.prototype._resultCancelled=function(){this.cancel()}}},{"./util":36}],7:[function(a,s,l){s.exports=function(u){var f=a("./util"),d=a("./es5").keys,h=f.tryCatch,v=f.errorObj;return function(g,y,x){return function(_){var b=x._boundValue();e:for(var w=0;w=0)return d[g]}return u.prototype._promiseCreated=function(){},u.prototype._pushContext=function(){},u.prototype._popContext=function(){return null},u._peekContext=u.prototype._peekContext=function(){},h.prototype._pushContext=function(){this._trace!==void 0&&(this._trace._promiseCreated=null,d.push(this._trace))},h.prototype._popContext=function(){if(this._trace!==void 0){var g=d.pop(),y=g._promiseCreated;return g._promiseCreated=null,y}return null},h.CapturedTrace=null,h.create=function(){if(f)return new h},h.deactivateLongStackTraces=function(){},h.activateLongStackTraces=function(){var g=u.prototype._pushContext,y=u.prototype._popContext,x=u._peekContext,_=u.prototype._peekContext,b=u.prototype._promiseCreated;h.deactivateLongStackTraces=function(){u.prototype._pushContext=g,u.prototype._popContext=y,u._peekContext=x,u.prototype._peekContext=_,u.prototype._promiseCreated=b,f=!1},f=!0,u.prototype._pushContext=h.prototype._pushContext,u.prototype._popContext=h.prototype._popContext,u._peekContext=u.prototype._peekContext=v,u.prototype._promiseCreated=function(){var w=this._peekContext();w&&w._promiseCreated==null&&(w._promiseCreated=this)}},h}},{}],9:[function(a,s,l){s.exports=function(u,f){var d,h,v,g=u._getDomain,y=u._async,x=a("./errors").Warning,_=a("./util"),b=_.canAttachTrace,w=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,S=/\((?:timers\.js):\d+:\d+\)/,E=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,P=null,T=null,A=!1,D=_.env("BLUEBIRD_DEBUG")!=0,k=!(_.env("BLUEBIRD_WARNINGS")==0||!D&&!_.env("BLUEBIRD_WARNINGS")),I=!(_.env("BLUEBIRD_LONG_STACK_TRACES")==0||!D&&!_.env("BLUEBIRD_LONG_STACK_TRACES")),F=_.env("BLUEBIRD_W_FORGOTTEN_RETURN")!=0&&(k||!!_.env("BLUEBIRD_W_FORGOTTEN_RETURN"));u.prototype.suppressUnhandledRejections=function(){var le=this._target();le._bitField=-1048577&le._bitField|524288},u.prototype._ensurePossibleRejectionHandled=function(){if(!(524288&this._bitField)){this._setRejectionIsUnhandled();var le=this;setTimeout(function(){le._notifyUnhandledRejection()},1)}},u.prototype._notifyUnhandledRejectionIsHandled=function(){he("rejectionHandled",d,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 le=this._settledValue();this._setUnhandledRejectionIsNotified(),he("unhandledRejection",h,le,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(le,ce,ye){return U(le,ce,ye||this)},u.onPossiblyUnhandledRejection=function(le){var ce=g();h=typeof le=="function"?ce===null?le:_.domainBind(ce,le):void 0},u.onUnhandledRejectionHandled=function(le){var ce=g();d=typeof le=="function"?ce===null?le:_.domainBind(ce,le):void 0};var q=function(){};u.longStackTraces=function(){if(y.haveItemsQueued()&&!Ae.longStackTraces)throw new Error(`cannot enable long stack traces after promises have been created See http://goo.gl/MqrFmX `);if(!Ae.longStackTraces&&se()){var le=u.prototype._captureStackTrace,ce=u.prototype._attachExtraTrace;Ae.longStackTraces=!0,q=function(){if(y.haveItemsQueued()&&!Ae.longStackTraces)throw new Error(`cannot enable long stack traces after promises have been created See http://goo.gl/MqrFmX `);u.prototype._captureStackTrace=le,u.prototype._attachExtraTrace=ce,f.deactivateLongStackTraces(),y.enableTrampoline(),Ae.longStackTraces=!1},u.prototype._captureStackTrace=j,u.prototype._attachExtraTrace=N,f.activateLongStackTraces(),y.disableTrampolineIfNecessary()}},u.hasLongStackTraces=function(){return Ae.longStackTraces&&se()};var W=function(){try{if(typeof CustomEvent=="function"){var le=new CustomEvent("CustomEvent");return _.global.dispatchEvent(le),function(ce,ye){var ge=new CustomEvent(ce.toLowerCase(),{detail:ye,cancelable:!0});return!_.global.dispatchEvent(ge)}}return typeof Event=="function"?(le=new Event("CustomEvent"),_.global.dispatchEvent(le),function(ce,ye){var ge=new Event(ce.toLowerCase(),{cancelable:!0});return ge.detail=ye,!_.global.dispatchEvent(ge)}):((le=document.createEvent("CustomEvent")).initCustomEvent("testingtheevent",!1,!0,{}),_.global.dispatchEvent(le),function(ce,ye){var ge=document.createEvent("CustomEvent");return ge.initCustomEvent(ce.toLowerCase(),!1,!0,ye),!_.global.dispatchEvent(ge)})}catch{}return function(){return!1}}(),X=_.isNode?function(){return r.emit.apply(r,arguments)}:_.global?function(le){var ce="on"+le.toLowerCase(),ye=_.global[ce];return!!ye&&(ye.apply(_.global,[].slice.call(arguments,1)),!0)}:function(){return!1};function Q(le,ce){return{promise:ce}}var ne={promiseCreated:Q,promiseFulfilled:Q,promiseRejected:Q,promiseResolved:Q,promiseCancelled:Q,promiseChained:function(le,ce,ye){return{promise:ce,child:ye}},warning:function(le,ce){return{warning:ce}},unhandledRejection:function(le,ce,ye){return{reason:ce,promise:ye}},rejectionHandled:Q},Z=function(le){var ce=!1;try{ce=X.apply(null,arguments)}catch(ge){y.throwLater(ge),ce=!0}var ye=!1;try{ye=W(le,ne[le].apply(null,arguments))}catch(ge){y.throwLater(ge),ye=!0}return ye||ce};function z(){return!1}function B(le,ce,ye){var ge=this;try{le(ce,ye,function(we){if(typeof we!="function")throw new TypeError("onCancel must be a function, got: "+_.toString(we));ge._attachCancellationCallback(we)})}catch(we){return we}}function H(le){if(!this._isCancellable())return this;var ce=this._onCancel();ce!==void 0?_.isArray(ce)?ce.push(le):this._setOnCancel([ce,le]):this._setOnCancel(le)}function ee(){return this._onCancelField}function K(le){this._onCancelField=le}function te(){this._cancellationParent=void 0,this._onCancelField=void 0}function ie(le,ce){if(1&ce){this._cancellationParent=le;var ye=le._branchesRemainingToCancel;ye===void 0&&(ye=0),le._branchesRemainingToCancel=ye+1}2&ce&&le._isBound()&&this._setBoundTo(le._boundTo)}u.config=function(le){if("longStackTraces"in(le=Object(le))&&(le.longStackTraces?u.longStackTraces():!le.longStackTraces&&u.hasLongStackTraces()&&q()),"warnings"in le){var ce=le.warnings;Ae.warnings=!!ce,F=Ae.warnings,_.isObject(ce)&&"wForgottenReturn"in ce&&(F=!!ce.wForgottenReturn)}if("cancellation"in le&&le.cancellation&&!Ae.cancellation){if(y.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");u.prototype._clearCancellationData=te,u.prototype._propagateFrom=ie,u.prototype._onCancel=ee,u.prototype._setOnCancel=K,u.prototype._attachCancellationCallback=H,u.prototype._execute=B,ae=ie,Ae.cancellation=!0}return"monitoring"in le&&(le.monitoring&&!Ae.monitoring?(Ae.monitoring=!0,u.prototype._fireEvent=Z):!le.monitoring&&Ae.monitoring&&(Ae.monitoring=!1,u.prototype._fireEvent=z)),u},u.prototype._fireEvent=z,u.prototype._execute=function(le,ce,ye){try{le(ce,ye)}catch(ge){return ge}},u.prototype._onCancel=function(){},u.prototype._setOnCancel=function(le){},u.prototype._attachCancellationCallback=function(le){},u.prototype._captureStackTrace=function(){},u.prototype._attachExtraTrace=function(){},u.prototype._clearCancellationData=function(){},u.prototype._propagateFrom=function(le,ce){};var ae=function(le,ce){2&ce&&le._isBound()&&this._setBoundTo(le._boundTo)};function fe(){var le=this._boundTo;return le!==void 0&&le instanceof u?le.isFulfilled()?le.value():void 0:le}function j(){this._trace=new Te(this._peekContext())}function N(le,ce){if(b(le)){var ye=this._trace;if(ye!==void 0&&ce&&(ye=ye._parent),ye!==void 0)ye.attachExtraTrace(le);else if(!le.__stackCleaned__){var ge=Y(le);_.notEnumerableProp(le,"stack",ge.message+` `+ge.stack.join(` `)),_.notEnumerableProp(le,"__stackCleaned__",!0)}}}function U(le,ce,ye){if(Ae.warnings){var ge,we=new x(le);if(ce)ye._attachExtraTrace(we);else if(Ae.longStackTraces&&(ge=u._peekContext()))ge.attachExtraTrace(we);else{var ke=Y(we);we.stack=ke.message+` `+ke.stack.join(` `)}Z("warning",we)||oe(we,"",!0)}}function J(le){for(var ce=[],ye=0;ye0?function(ge){for(var we=ge.stack.replace(/\s+$/g,"").split(` `),ke=0;ke0&&ge.name!="SyntaxError"&&(we=we.slice(ke)),we}(le):[" (No stack trace)"],{message:ye,stack:le.name=="SyntaxError"?ce:J(ce)}}function oe(le,ce,ye){if(typeof console<"u"){var ge;if(_.isObject(le)){var we=le.stack;ge=ce+T(we,le)}else ge=ce+String(le);typeof v=="function"?v(ge,ye):typeof console.log!="function"&&typeof console.log!="object"||console.log(ge)}}function he(le,ce,ye,ge){var we=!1;try{typeof ce=="function"&&(we=!0,le==="rejectionHandled"?ce(ge):ce(ye,ge))}catch(ke){y.throwLater(ke)}le==="unhandledRejection"?Z(le,ye,ge)||we||oe(ye,"Unhandled rejection "):Z(le,ge)}function Se(le){var ce;if(typeof le=="function")ce="[function "+(le.name||"anonymous")+"]";else{if(ce=le&&typeof le.toString=="function"?le.toString():_.toString(le),/\[object [a-zA-Z0-9$_]+\]/.test(ce))try{ce=JSON.stringify(le)}catch{}ce.length===0&&(ce="(empty array)")}return"(<"+function(ye){return ye.length<41?ye:ye.substr(0,38)+"..."}(ce)+">, no stack trace)"}function se(){return typeof Ce=="function"}var pe=function(){return!1},me=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;function xe(le){var ce=le.match(me);if(ce)return{fileName:ce[1],line:parseInt(ce[2],10)}}function Te(le){this._parent=le,this._promisesCreated=0;var ce=this._length=1+(le===void 0?0:le._length);Ce(this,Te),ce>32&&this.uncycle()}_.inherits(Te,Error),f.CapturedTrace=Te,Te.prototype.uncycle=function(){var le=this._length;if(!(le<2)){for(var ce=[],ye={},ge=0,we=this;we!==void 0;++ge)ce.push(we),we=we._parent;for(ge=(le=this._length=ge)-1;ge>=0;--ge){var ke=ce[ge].stack;ye[ke]===void 0&&(ye[ke]=ge)}for(ge=0;ge0&&(ce[Me-1]._parent=void 0,ce[Me-1]._length=1),ce[ge]._parent=void 0,ce[ge]._length=1;var et=ge>0?ce[ge-1]:this;Me=0;--Ze)ce[Ze]._length=nt,nt++;return}}}},Te.prototype.attachExtraTrace=function(le){if(!le.__stackCleaned__){this.uncycle();for(var ce=Y(le),ye=ce.message,ge=[ce.stack],we=this;we!==void 0;)ge.push(J(we.stack.split(` `))),we=we._parent;(function(ke){for(var Me=ke[0],et=1;et=0;--bn)if(nt[bn]===Gt){Ft=bn;break}for(bn=Ft;bn>=0;--bn){var Xn=nt[bn];if(Me[Ze]!==Xn)break;Me.pop(),Ze--}Me=nt}})(ge),function(ke){for(var Me=0;Me=0)return P=/@/,T=ce,A=!0,function(ke){ke.stack=new Error().stack};try{throw new Error}catch(ke){ge="stack"in ke}return"stack"in we||!ge||typeof Error.stackTraceLimit!="number"?(T=function(ke,Me){return typeof ke=="string"?ke:typeof Me!="object"&&typeof Me!="function"||Me.name===void 0||Me.message===void 0?Se(Me):Me.toString()},null):(P=le,T=ce,function(ke){Error.stackTraceLimit+=6;try{throw new Error}catch(Me){ke.stack=Me.stack}Error.stackTraceLimit-=6})}();typeof console<"u"&&console.warn!==void 0&&(v=function(le){console.warn(le)},_.isNode&&r.stderr.isTTY?v=function(le,ce){var ye=ce?"\x1B[33m":"\x1B[31m";console.warn(ye+le+`\x1B[0m `)}:_.isNode||typeof new Error().stack!="string"||(v=function(le,ce){console.warn("%c"+le,ce?"color: darkorange":"color: red")}));var Ae={warnings:k,longStackTraces:!1,cancellation:!1,monitoring:!1};return I&&u.longStackTraces(),{longStackTraces:function(){return Ae.longStackTraces},warnings:function(){return Ae.warnings},cancellation:function(){return Ae.cancellation},monitoring:function(){return Ae.monitoring},propagateFromFunction:function(){return ae},boundValueFunction:function(){return fe},checkForgottenReturns:function(le,ce,ye,ge,we){if(le===void 0&&ce!==null&&F){if(we!==void 0&&we._returnedNonUndefined()||!(65535&ge._bitField))return;ye&&(ye+=" ");var ke="",Me="";if(ce._trace){for(var et=ce._trace.stack.split(` `),nt=J(et),Ze=nt.length-1;Ze>=0;--Ze){var Gt=nt[Ze];if(!S.test(Gt)){var Ft=Gt.match(E);Ft&&(ke="at "+Ft[1]+":"+Ft[2]+":"+Ft[3]+" ");break}}if(nt.length>0){var bn=nt[0];for(Ze=0;Ze0&&(Me=` `+et[Ze-1]);break}}}var Xn="a promise was created in a "+ye+"handler "+ke+"but was not returned from it, see http://goo.gl/rRqMUw"+Me;ge._warn(Xn,!0,ce)}},setBounds:function(le,ce){if(se()){for(var ye,ge,we=le.stack.split(` `),ke=ce.stack.split(` `),Me=-1,et=-1,nt=0;nt=et||(pe=function(Gt){if(w.test(Gt))return!0;var Ft=xe(Gt);return!!(Ft&&Ft.fileName===ye&&Me<=Ft.line&&Ft.line<=et)})}},warn:U,deprecated:function(le,ce){var ye=le+" is deprecated and will be removed in a future version.";return ce&&(ye+=" Use "+ce+" instead."),U(ye)},CapturedTrace:Te,fireDomEvent:W,fireGlobalEvent:X}}},{"./errors":12,"./util":36}],10:[function(a,s,l){s.exports=function(u){function f(){return this.value}function d(){throw this.reason}u.prototype.return=u.prototype.thenReturn=function(h){return h instanceof u&&h.suppressUnhandledRejections(),this._then(f,void 0,void 0,{value:h},void 0)},u.prototype.throw=u.prototype.thenThrow=function(h){return this._then(d,void 0,void 0,{reason:h},void 0)},u.prototype.catchThrow=function(h){if(arguments.length<=1)return this._then(void 0,d,void 0,{reason:h},void 0);var v=arguments[1];return this.caught(h,function(){throw v})},u.prototype.catchReturn=function(h){if(arguments.length<=1)return h instanceof u&&h.suppressUnhandledRejections(),this._then(void 0,f,void 0,{value:h},void 0);var v=arguments[1];return v instanceof u&&v.suppressUnhandledRejections(),this.caught(h,function(){return v})}}},{}],11:[function(a,s,l){s.exports=function(u,f){var d=u.reduce,h=u.all;function v(){return h(this)}u.prototype.each=function(g){return d(this,g,f,0)._then(v,void 0,void 0,this,void 0)},u.prototype.mapSeries=function(g){return d(this,g,f,f)},u.each=function(g,y){return d(g,y,f,0)._then(v,void 0,void 0,g,void 0)},u.mapSeries=function(g,y){return d(g,y,f,f)}}},{}],12:[function(a,s,l){var u,f,d=a("./es5"),h=d.freeze,v=a("./util"),g=v.inherits,y=v.notEnumerableProp;function x(k,I){function F(q){if(!(this instanceof F))return new F(q);y(this,"message",typeof q=="string"?q:I),y(this,"name",k),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)}return g(F,Error),F}var _=x("Warning","warning"),b=x("CancellationError","cancellation error"),w=x("TimeoutError","timeout error"),S=x("AggregateError","aggregate error");try{u=TypeError,f=RangeError}catch{u=x("TypeError","type error"),f=x("RangeError","range error")}for(var E="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),P=0;P1?P.cancelPromise._reject(T):P.cancelPromise._cancel(),P.cancelPromise=null,!0)}function w(){return E.call(this,this.promise._target()._settledValue())}function S(P){if(!b(this,P))return g.e=P,g}function E(P){var T=this.promise,A=this.handler;if(!this.called){this.called=!0;var D=this.isFinallyHandler()?A.call(T._boundValue()):A.call(T._boundValue(),P);if(D===d)return D;if(D!==void 0){T._setReturnedNonUndefined();var k=f(D,T);if(k instanceof u){if(this.cancelPromise!=null){if(k._isCancelled()){var I=new v("late cancellation observer");return T._attachExtraTrace(I),g.e=I,g}k.isPending()&&k._attachCancellationCallback(new _(this))}return k._then(w,S,void 0,this,void 0)}}}return T.isRejected()?(b(this),g.e=P,g):(b(this),P)}return x.prototype.isFinallyHandler=function(){return this.type===0},_.prototype._resultCancelled=function(){b(this.finallyHandler)},u.prototype._passThrough=function(P,T,A,D){return typeof P!="function"?this.then():this._then(A,D,void 0,new x(this,T,P),void 0)},u.prototype.lastly=u.prototype.finally=function(P){return this._passThrough(P,0,E,E)},u.prototype.tap=function(P){return this._passThrough(P,1,E)},u.prototype.tapCatch=function(P){var T=arguments.length;if(T===1)return this._passThrough(P,1,void 0,E);var A,D=new Array(T-1),k=0;for(A=0;A0&&typeof arguments[_]=="function"&&(x=arguments[_]);var b=[].slice.call(arguments);x&&b.pop();var w=new f(b).promise();return x!==void 0?w.spread(x):w}}},{"./util":36}],18:[function(a,s,l){s.exports=function(u,f,d,h,v,g){var y=u._getDomain,x=a("./util"),_=x.tryCatch,b=x.errorObj,w=u._async;function S(P,T,A,D){this.constructor$(P),this._promise._captureStackTrace();var k=y();this._callback=k===null?T:x.domainBind(k,T),this._preservedValues=D===v?new Array(this.length()):null,this._limit=A,this._inFlight=0,this._queue=[],w.invoke(this._asyncInit,this,void 0)}function E(P,T,A,D){if(typeof T!="function")return d("expecting a function but got "+x.classString(T));var k=0;if(A!==void 0){if(typeof A!="object"||A===null)return u.reject(new TypeError("options argument must be an object but it is "+x.classString(A)));if(typeof A.concurrency!="number")return u.reject(new TypeError("'concurrency' must be a number but it is "+x.classString(A.concurrency)));k=A.concurrency}return new S(P,T,k=typeof k=="number"&&isFinite(k)&&k>=1?k:0,D).promise()}x.inherits(S,f),S.prototype._asyncInit=function(){this._init$(void 0,-2)},S.prototype._init=function(){},S.prototype._promiseFulfilled=function(P,T){var A=this._values,D=this.length(),k=this._preservedValues,I=this._limit;if(T<0){if(A[T=-1*T-1]=P,I>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(I>=1&&this._inFlight>=I)return A[T]=P,this._queue.push(T),!1;k!==null&&(k[T]=P);var F=this._promise,q=this._callback,W=F._boundValue();F._pushContext();var X=_(q).call(W,P,T,D),Q=F._popContext();if(g.checkForgottenReturns(X,Q,k!==null?"Promise.filter":"Promise.map",F),X===b)return this._reject(X.e),!0;var ne=h(X,this._promise);if(ne instanceof u){var Z=(ne=ne._target())._bitField;if(!(50397184&Z))return I>=1&&this._inFlight++,A[T]=ne,ne._proxy(this,-1*(T+1)),!1;if(!(33554432&Z))return 16777216&Z?(this._reject(ne._reason()),!0):(this._cancel(),!0);X=ne._value()}A[T]=X}return++this._totalResolved>=D&&(k!==null?this._filter(A,k):this._resolve(A),!0)},S.prototype._drainQueue=function(){for(var P=this._queue,T=this._limit,A=this._values;P.length>0&&this._inFlight1){v.deprecated("calling Promise.try with more than 1 argument");var w=arguments[1],S=arguments[2];_=g.isArray(w)?y(x).apply(S,w):y(x).call(S,w)}else _=y(x)();var E=b._popContext();return v.checkForgottenReturns(_,E,"Promise.try",b),b._resolveFromSyncValue(_),b},u.prototype._resolveFromSyncValue=function(x){x===g.errorObj?this._rejectCallback(x.e,!1):this._resolveCallback(x,!0)}}},{"./util":36}],20:[function(a,s,l){var u=a("./util"),f=u.maybeWrapAsError,d=a("./errors").OperationalError,h=a("./es5"),v=/^(?:name|message|stack|cause)$/;function g(y){var x;if(function(S){return S instanceof Error&&h.getPrototypeOf(S)===Error.prototype}(y)){(x=new d(y)).name=y.name,x.message=y.message,x.stack=y.stack;for(var _=h.keys(y),b=0;b<_.length;++b){var w=_[b];v.test(w)||(x[w]=y[w])}return x}return u.markAsOriginatingFromRejection(y),y}s.exports=function(y,x){return function(_,b){if(y!==null){if(_){var w=g(f(_));y._attachExtraTrace(w),y._reject(w)}else if(x){var S=[].slice.call(arguments,1);y._fulfill(S)}else y._fulfill(b);y=null}}}},{"./errors":12,"./es5":13,"./util":36}],21:[function(a,s,l){s.exports=function(u){var f=a("./util"),d=u._async,h=f.tryCatch,v=f.errorObj;function g(_,b){if(!f.isArray(_))return y.call(this,_,b);var w=h(b).apply(this._boundValue(),[null].concat(_));w===v&&d.throwLater(w.e)}function y(_,b){var w=this._boundValue(),S=_===void 0?h(b).call(w,null):h(b).call(w,null,_);S===v&&d.throwLater(S.e)}function x(_,b){if(!_){var w=new Error(_+"");w.cause=_,_=w}var S=h(b).call(this._boundValue(),_);S===v&&d.throwLater(S.e)}u.prototype.asCallback=u.prototype.nodeify=function(_,b){if(typeof _=="function"){var w=y;b!==void 0&&Object(b).spread&&(w=g),this._then(w,x,void 0,this,_)}return this}}},{"./util":36}],22:[function(a,s,l){s.exports=function(){var u=function(){return new S(`circular promise resolution chain See http://goo.gl/MqrFmX `)},f=function(){return new z.PromiseInspection(this._target())},d=function(K){return z.reject(new S(K))};function h(){}var v,g={},y=a("./util");v=y.isNode?function(){var K=r.domain;return K===void 0&&(K=null),K}:function(){return null},y.notEnumerableProp(z,"_getDomain",v);var x=a("./es5"),_=a("./async"),b=new _;x.defineProperty(z,"_async",{value:b});var w=a("./errors"),S=z.TypeError=w.TypeError;z.RangeError=w.RangeError;var E=z.CancellationError=w.CancellationError;z.TimeoutError=w.TimeoutError,z.OperationalError=w.OperationalError,z.RejectionError=w.OperationalError,z.AggregateError=w.AggregateError;var P=function(){},T={},A={},D=a("./thenables")(z,P),k=a("./promise_array")(z,P,D,d,h),I=a("./context")(z),F=I.create,q=a("./debuggability")(z,I),W=(q.CapturedTrace,a("./finally")(z,D,A)),X=a("./catch_filter")(A),Q=a("./nodeback"),ne=y.errorObj,Z=y.tryCatch;function z(K){K!==P&&function(te,ie){if(te==null||te.constructor!==z)throw new S(`the promise constructor cannot be invoked directly See http://goo.gl/MqrFmX `);if(typeof ie!="function")throw new S("expecting a function but got "+y.classString(ie))}(this,K),this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._resolveFromExecutor(K),this._promiseCreated(),this._fireEvent("promiseCreated",this)}function B(K){this.promise._resolveCallback(K)}function H(K){this.promise._rejectCallback(K,!1)}function ee(K){var te=new z(P);te._fulfillmentHandler0=K,te._rejectionHandler0=K,te._promise0=K,te._receiver0=K}return z.prototype.toString=function(){return"[object Promise]"},z.prototype.caught=z.prototype.catch=function(K){var te=arguments.length;if(te>1){var ie,ae=new Array(te-1),fe=0;for(ie=0;ie0&&typeof K!="function"&&typeof te!="function"){var ie=".then() only accepts functions but was passed: "+y.classString(K);arguments.length>1&&(ie+=", "+y.classString(te)),this._warn(ie)}return this._then(K,te,void 0,void 0,void 0)},z.prototype.done=function(K,te){this._then(K,te,void 0,void 0,void 0)._setIsFinal()},z.prototype.spread=function(K){return typeof K!="function"?d("expecting a function but got "+y.classString(K)):this.all()._then(K,void 0,void 0,T,void 0)},z.prototype.toJSON=function(){var K={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(K.fulfillmentValue=this.value(),K.isFulfilled=!0):this.isRejected()&&(K.rejectionReason=this.reason(),K.isRejected=!0),K},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(K){return this.caught(y.originatesFromRejection,K)},z.getNewLibraryCopy=s.exports,z.is=function(K){return K instanceof z},z.fromNode=z.fromCallback=function(K){var te=new z(P);te._captureStackTrace();var ie=arguments.length>1&&!!Object(arguments[1]).multiArgs,ae=Z(K)(Q(te,ie));return ae===ne&&te._rejectCallback(ae.e,!0),te._isFateSealed()||te._setAsyncGuaranteed(),te},z.all=function(K){return new k(K).promise()},z.cast=function(K){var te=D(K);return te instanceof z||((te=new z(P))._captureStackTrace(),te._setFulfilled(),te._rejectionHandler0=K),te},z.resolve=z.fulfilled=z.cast,z.reject=z.rejected=function(K){var te=new z(P);return te._captureStackTrace(),te._rejectCallback(K,!0),te},z.setScheduler=function(K){if(typeof K!="function")throw new S("expecting a function but got "+y.classString(K));return b.setScheduler(K)},z.prototype._then=function(K,te,ie,ae,fe){var j=fe!==void 0,N=j?fe:new z(P),U=this._target(),J=U._bitField;j||(N._propagateFrom(this,3),N._captureStackTrace(),ae===void 0&&2097152&this._bitField&&(ae=50397184&J?this._boundValue():U===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,N));var Y=v();if(50397184&J){var oe,he,Se=U._settlePromiseCtx;33554432&J?(he=U._rejectionHandler0,oe=K):16777216&J?(he=U._fulfillmentHandler0,oe=te,U._unsetRejectionIsUnhandled()):(Se=U._settlePromiseLateCancellationObserver,he=new E("late cancellation observer"),U._attachExtraTrace(he),oe=te),b.invoke(Se,U,{handler:Y===null?oe:typeof oe=="function"&&y.domainBind(Y,oe),promise:N,receiver:ae,value:he})}else U._addCallbacks(K,te,N,ae,Y);return N},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(K){this._bitField=-65536&this._bitField|65535&K},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(){b.hasCustomScheduler()||(this._bitField=134217728|this._bitField)},z.prototype._receiverAt=function(K){var te=K===0?this._receiver0:this[4*K-4+3];if(te!==g)return te===void 0&&this._isBound()?this._boundValue():te},z.prototype._promiseAt=function(K){return this[4*K-4+2]},z.prototype._fulfillmentHandlerAt=function(K){return this[4*K-4+0]},z.prototype._rejectionHandlerAt=function(K){return this[4*K-4+1]},z.prototype._boundValue=function(){},z.prototype._migrateCallback0=function(K){K._bitField;var te=K._fulfillmentHandler0,ie=K._rejectionHandler0,ae=K._promise0,fe=K._receiverAt(0);fe===void 0&&(fe=g),this._addCallbacks(te,ie,ae,fe,null)},z.prototype._migrateCallbackAt=function(K,te){var ie=K._fulfillmentHandlerAt(te),ae=K._rejectionHandlerAt(te),fe=K._promiseAt(te),j=K._receiverAt(te);j===void 0&&(j=g),this._addCallbacks(ie,ae,fe,j,null)},z.prototype._addCallbacks=function(K,te,ie,ae,fe){var j=this._length();if(j>=65531&&(j=0,this._setLength(0)),j===0)this._promise0=ie,this._receiver0=ae,typeof K=="function"&&(this._fulfillmentHandler0=fe===null?K:y.domainBind(fe,K)),typeof te=="function"&&(this._rejectionHandler0=fe===null?te:y.domainBind(fe,te));else{var N=4*j-4;this[N+2]=ie,this[N+3]=ae,typeof K=="function"&&(this[N+0]=fe===null?K:y.domainBind(fe,K)),typeof te=="function"&&(this[N+1]=fe===null?te:y.domainBind(fe,te))}return this._setLength(j+1),j},z.prototype._proxy=function(K,te){this._addCallbacks(void 0,void 0,te,K,null)},z.prototype._resolveCallback=function(K,te){if(!(117506048&this._bitField)){if(K===this)return this._rejectCallback(u(),!1);var ie=D(K,this);if(!(ie instanceof z))return this._fulfill(K);te&&this._propagateFrom(ie,2);var ae=ie._target();if(ae!==this){var fe=ae._bitField;if(50397184&fe)if(33554432&fe)this._fulfill(ae._value());else if(16777216&fe)this._reject(ae._reason());else{var U=new E("late cancellation observer");ae._attachExtraTrace(U),this._reject(U)}else{var j=this._length();j>0&&ae._migrateCallback0(this);for(var N=1;N>>16)){if(K===this){var ie=u();return this._attachExtraTrace(ie),this._reject(ie)}this._setFulfilled(),this._rejectionHandler0=K,(65535&te)>0&&(134217728&te?this._settlePromises():b.settlePromises(this))}},z.prototype._reject=function(K){var te=this._bitField;if(!((117506048&te)>>>16)){if(this._setRejected(),this._fulfillmentHandler0=K,this._isFinal())return b.fatalError(K,y.isNode);(65535&te)>0?b.settlePromises(this):this._ensurePossibleRejectionHandled()}},z.prototype._fulfillPromises=function(K,te){for(var ie=1;ie0){if(16842752&K){var ie=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,ie,K),this._rejectPromises(te,ie)}else{var ae=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,ae,K),this._fulfillPromises(te,ae)}this._setLength(0)}this._clearCancellationData()},z.prototype._settledValue=function(){var K=this._bitField;return 33554432&K?this._rejectionHandler0:16777216&K?this._fulfillmentHandler0:void 0},z.defer=z.pending=function(){return q.deprecated("Promise.defer","new Promise"),{promise:new z(P),resolve:B,reject:H}},y.notEnumerableProp(z,"_makeSelfResolutionError",u),a("./method")(z,P,D,d,q),a("./bind")(z,P,D,q),a("./cancel")(z,k,d,q),a("./direct_resolve")(z),a("./synchronous_inspection")(z),a("./join")(z,k,D,P,b,v),z.Promise=z,z.version="3.5.1",a("./map.js")(z,k,d,D,P,q),a("./call_get.js")(z),a("./using.js")(z,d,D,F,P,q),a("./timers.js")(z,P,q),a("./generators.js")(z,d,P,D,h,q),a("./nodeify.js")(z),a("./promisify.js")(z,P),a("./props.js")(z,k,D,d),a("./race.js")(z,P,D,d),a("./reduce.js")(z,k,d,D,P,q),a("./settle.js")(z,k,q),a("./some.js")(z,k,d),a("./filter.js")(z,P),a("./each.js")(z,P),a("./any.js")(z),y.toFastProperties(z),y.toFastProperties(z.prototype),ee({a:1}),ee({b:2}),ee({c:3}),ee(1),ee(function(){}),ee(void 0),ee(!1),ee(new z(P)),q.setBounds(_.firstLineError,y.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(a,s,l){s.exports=function(u,f,d,h,v){var g=a("./util");function y(x){var _=this._promise=new u(f);x instanceof u&&_._propagateFrom(x,3),_._setOnCancel(this),this._values=x,this._length=0,this._totalResolved=0,this._init(void 0,-2)}return g.isArray,g.inherits(y,v),y.prototype.length=function(){return this._length},y.prototype.promise=function(){return this._promise},y.prototype._init=function x(_,b){var w=d(this._values,this._promise);if(w instanceof u){var S=(w=w._target())._bitField;if(this._values=w,(50397184&S)==0)return this._promise._setAsyncGuaranteed(),w._then(x,this._reject,void 0,this,b);if(!(33554432&S))return 16777216&S?this._reject(w._reason()):this._cancel();w=w._value()}if((w=g.asArray(w))!==null)w.length!==0?this._iterate(w):b===-5?this._resolveEmptyArray():this._resolve(function(P){switch(b){case-2:return[];case-3:return{};case-6:return new Map}}());else{var E=h("expecting an array or an iterable object but got "+g.classString(w)).reason();this._promise._rejectCallback(E,!1)}},y.prototype._iterate=function(x){var _=this.getActualLength(x.length);this._length=_,this._values=this.shouldCopyValues()?new Array(_):this._values;for(var b=this._promise,w=!1,S=null,E=0;E<_;++E){var P=d(x[E],b);S=P instanceof u?(P=P._target())._bitField:null,w?S!==null&&P.suppressUnhandledRejections():S!==null?50397184&S?w=33554432&S?this._promiseFulfilled(P._value(),E):16777216&S?this._promiseRejected(P._reason(),E):this._promiseCancelled(E):(P._proxy(this,E),this._values[E]=P):w=this._promiseFulfilled(P,E)}w||b._setAsyncGuaranteed()},y.prototype._isResolved=function(){return this._values===null},y.prototype._resolve=function(x){this._values=null,this._promise._fulfill(x)},y.prototype._cancel=function(){!this._isResolved()&&this._promise._isCancellable()&&(this._values=null,this._promise._cancel())},y.prototype._reject=function(x){this._values=null,this._promise._rejectCallback(x,!1)},y.prototype._promiseFulfilled=function(x,_){return this._values[_]=x,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},y.prototype._promiseCancelled=function(){return this._cancel(),!0},y.prototype._promiseRejected=function(x){return this._totalResolved++,this._reject(x),!0},y.prototype._resultCancelled=function(){if(!this._isResolved()){var x=this._values;if(this._cancel(),x instanceof u)x.cancel();else for(var _=0;_=this._length){var P;if(this._isMap)P=function(k){for(var I=new v,F=k.length/2|0,q=0;q>1},u.prototype.props=function(){return w(this)},u.props=function(S){return w(S)}}},{"./es5":13,"./util":36}],26:[function(a,s,l){function u(f){this._capacity=f,this._length=0,this._front=0}u.prototype._willBeOverCapacity=function(f){return this._capacity"u"){var h=i.setImmediate,v=r.nextTick;u=f.isRecentNode?function(y){h.call(i,y)}:function(y){v.call(r,y)}}else if(typeof d=="function"&&typeof d.resolve=="function"){var g=d.resolve();u=function(y){g.then(y)}}else u=typeof MutationObserver>"u"||typeof window<"u"&&window.navigator&&(window.navigator.standalone||window.cordova)?o!==void 0?function(y){o(y)}:typeof setTimeout<"u"?function(y){setTimeout(y,0)}:function(){throw new Error(`No async scheduler available See http://goo.gl/MqrFmX `)}:function(){var y=document.createElement("div"),x={attributes:!0},_=!1,b=document.createElement("div");return new MutationObserver(function(){y.classList.toggle("foo"),_=!1}).observe(b,x),function(w){var S=new MutationObserver(function(){S.disconnect(),w()});S.observe(y,x),_||(_=!0,b.classList.toggle("foo"))}}();s.exports=u},{"./util":36}],30:[function(a,s,l){s.exports=function(u,f,d){var h=u.PromiseInspection;function v(g){this.constructor$(g)}a("./util").inherits(v,f),v.prototype._promiseResolved=function(g,y){return this._values[g]=y,++this._totalResolved>=this._length&&(this._resolve(this._values),!0)},v.prototype._promiseFulfilled=function(g,y){var x=new h;return x._bitField=33554432,x._settledValueField=g,this._promiseResolved(y,x)},v.prototype._promiseRejected=function(g,y){var x=new h;return x._bitField=16777216,x._settledValueField=g,this._promiseResolved(y,x)},u.settle=function(g){return d.deprecated(".settle()",".reflect()"),new v(g).promise()},u.prototype.settle=function(){return u.settle(this)}}},{"./util":36}],31:[function(a,s,l){s.exports=function(u,f,d){var h=a("./util"),v=a("./errors").RangeError,g=a("./errors").AggregateError,y=h.isArray,x={};function _(w){this.constructor$(w),this._howMany=0,this._unwrap=!1,this._initialized=!1}function b(w,S){if((0|S)!==S||S<0)return d(`expecting a positive integer See http://goo.gl/MqrFmX `);var E=new _(w),P=E.promise();return E.setHowMany(S),E.init(),P}h.inherits(_,f),_.prototype._init=function(){if(this._initialized)if(this._howMany!==0){this._init$(void 0,-5);var w=y(this._values);!this._isResolved()&&w&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}else this._resolve([])},_.prototype.init=function(){this._initialized=!0,this._init()},_.prototype.setUnwrap=function(){this._unwrap=!0},_.prototype.howMany=function(){return this._howMany},_.prototype.setHowMany=function(w){this._howMany=w},_.prototype._promiseFulfilled=function(w){return this._addFulfilled(w),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),this.howMany()===1&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)},_.prototype._promiseRejected=function(w){return this._addRejected(w),this._checkOutcome()},_.prototype._promiseCancelled=function(){return this._values instanceof u||this._values==null?this._cancel():(this._addRejected(x),this._checkOutcome())},_.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var w=new g,S=this.length();S0?this._reject(w):this._cancel(),!0}return!1},_.prototype._fulfilled=function(){return this._totalResolved},_.prototype._rejected=function(){return this._values.length-this.length()},_.prototype._addRejected=function(w){this._values.push(w)},_.prototype._addFulfilled=function(w){this._values[this._totalResolved++]=w},_.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},_.prototype._getRangeError=function(w){var S="Input array must contain at least "+this._howMany+" items but contains only "+w+" items";return new v(S)},_.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},u.some=function(w,S){return b(w,S)},u.prototype.some=function(w){return b(this,w)},u._SomePromiseArray=_}},{"./errors":12,"./util":36}],32:[function(a,s,l){s.exports=function(u){function f(_){_!==void 0?(_=_._target(),this._bitField=_._bitField,this._settledValueField=_._isFateSealed()?_._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}f.prototype._settledValue=function(){return this._settledValueField};var d=f.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()},h=f.prototype.error=f.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()},v=f.prototype.isFulfilled=function(){return(33554432&this._bitField)!=0},g=f.prototype.isRejected=function(){return(16777216&this._bitField)!=0},y=f.prototype.isPending=function(){return(50397184&this._bitField)==0},x=f.prototype.isResolved=function(){return(50331648&this._bitField)!=0};f.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 y.call(this._target())},u.prototype.isRejected=function(){return g.call(this._target())},u.prototype.isFulfilled=function(){return v.call(this._target())},u.prototype.isResolved=function(){return x.call(this._target())},u.prototype.value=function(){return d.call(this._target())},u.prototype.reason=function(){var _=this._target();return _._unsetRejectionIsUnhandled(),h.call(_)},u.prototype._value=function(){return this._settledValue()},u.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},u.PromiseInspection=f}},{}],33:[function(a,s,l){s.exports=function(u,f){var d=a("./util"),h=d.errorObj,v=d.isObject,g={}.hasOwnProperty;return function(y,x){if(v(y)){if(y instanceof u)return y;var _=function(w){try{return function(S){return S.then}(w)}catch(S){return h.e=S,h}}(y);if(_===h){x&&x._pushContext();var b=u.reject(_.e);return x&&x._popContext(),b}if(typeof _=="function")return function(w){try{return g.call(w,"_promise0")}catch{return!1}}(y)?(b=new u(f),y._then(b._fulfill,b._reject,void 0,b,null),b):function(w,S,E){var P=new u(f),T=P;E&&E._pushContext(),P._captureStackTrace(),E&&E._popContext();var A=!0,D=d.tryCatch(S).call(w,function(k){P&&(P._resolveCallback(k),P=null)},function(k){P&&(P._rejectCallback(k,A,!0),P=null)});return A=!1,P&&D===h&&(P._rejectCallback(D.e,!0,!0),P=null),T}(y,_,x)}return y}}},{"./util":36}],34:[function(a,s,l){s.exports=function(u,f,d){var h=a("./util"),v=u.TimeoutError;function g(w){this.handle=w}g.prototype._resultCancelled=function(){clearTimeout(this.handle)};var y=function(w){return x(+this).thenReturn(w)},x=u.delay=function(w,S){var E,P;return S!==void 0?(E=u.resolve(S)._then(y,null,null,w,void 0),d.cancellation()&&S instanceof u&&E._setOnCancel(S)):(E=new u(f),P=setTimeout(function(){E._fulfill()},+w),d.cancellation()&&E._setOnCancel(new g(P)),E._captureStackTrace()),E._setAsyncGuaranteed(),E};function _(w){return clearTimeout(this.handle),w}function b(w){throw clearTimeout(this.handle),w}u.prototype.delay=function(w){return x(w,this)},u.prototype.timeout=function(w,S){var E,P;w=+w;var T=new g(setTimeout(function(){E.isPending()&&function(A,D,k){var I;I=typeof D!="string"?D instanceof Error?D:new v("operation timed out"):new v(D),h.markAsOriginatingFromRejection(I),A._attachExtraTrace(I),A._reject(I),k!=null&&k.cancel()}(E,S,P)},w));return d.cancellation()?(P=this.then(),(E=P._then(_,b,void 0,T,void 0))._setOnCancel(T)):E=this._then(_,b,void 0,T,void 0),E}}},{"./util":36}],35:[function(a,s,l){s.exports=function(u,f,d,h,v,g){var y=a("./util"),x=a("./errors").TypeError,_=a("./util").inherits,b=y.errorObj,w=y.tryCatch,S={};function E(I){setTimeout(function(){throw I},0)}function P(I,F){var q=0,W=I.length,X=new u(v);return function Q(){if(q>=W)return X._fulfill();var ne=function(Z){var z=d(Z);return z!==Z&&typeof Z._isDisposable=="function"&&typeof Z._getDisposer=="function"&&Z._isDisposable()&&z._setDisposable(Z._getDisposer()),z}(I[q++]);if(ne instanceof u&&ne._isDisposable()){try{ne=d(ne._getDisposer().tryDispose(F),I.promise)}catch(Z){return E(Z)}if(ne instanceof u)return ne._then(Q,E,null,null,null)}Q()}(),X}function T(I,F,q){this._data=I,this._promise=F,this._context=q}function A(I,F,q){this.constructor$(I,F,q)}function D(I){return T.isDisposer(I)?(this.resources[this.index]._setDisposable(I),I.promise()):I}function k(I){this.length=I,this.promise=null,this[I-1]=null}T.prototype.data=function(){return this._data},T.prototype.promise=function(){return this._promise},T.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():S},T.prototype.tryDispose=function(I){var F=this.resource(),q=this._context;q!==void 0&&q._pushContext();var W=F!==S?this.doDispose(F,I):null;return q!==void 0&&q._popContext(),this._promise._unsetDisposable(),this._data=null,W},T.isDisposer=function(I){return I!=null&&typeof I.resource=="function"&&typeof I.tryDispose=="function"},_(A,T),A.prototype.doDispose=function(I,F){return this.data().call(I,I,F)},k.prototype._resultCancelled=function(){for(var I=this.length,F=0;F0},u.prototype._getDisposer=function(){return this._disposer},u.prototype._unsetDisposable=function(){this._bitField=-131073&this._bitField,this._disposer=void 0},u.prototype.disposer=function(I){if(typeof I=="function")return new A(I,this,h());throw new x}}},{"./errors":12,"./util":36}],36:[function(a,s,l){var u,f=a("./es5"),d=typeof navigator>"u",h={e:{}},v=typeof self<"u"?self:typeof window<"u"?window:i!==void 0?i:this!==void 0?this:null;function g(){try{var W=u;return u=null,W.apply(this,arguments)}catch(X){return h.e=X,h}}function y(W){return W==null||W===!0||W===!1||typeof W=="string"||typeof W=="number"}function x(W,X,Q){if(y(W))return W;var ne={value:Q,configurable:!0,enumerable:!1,writable:!0};return f.defineProperty(W,X,ne),W}var _=function(){var W=[Array.prototype,Object.prototype,Function.prototype],X=function(Z){for(var z=0;z1,ne=X.length>0&&!(X.length===1&&X[0]==="constructor"),Z=b.test(W+"")&&f.names(W).length>0;if(Q||ne||Z)return!0}return!1}catch{return!1}},isIdentifier:function(W){return w.test(W)},inheritedDataKeys:_,getDataPropertyOrDefault:function(W,X,Q){if(!f.isES5)return{}.hasOwnProperty.call(W,X)?W[X]:void 0;var ne=Object.getOwnPropertyDescriptor(W,X);return ne!=null?ne.get==null&&ne.set==null?ne.value:Q:void 0},thrower:function(W){throw W},isArray:f.isArray,asArray:D,notEnumerableProp:x,isPrimitive:y,isObject:function(W){return typeof W=="function"||typeof W=="object"&&W!==null},isError:E,canEvaluate:d,errorObj:h,tryCatch:function(W){return u=W,g},inherits:function(W,X){var Q={}.hasOwnProperty;function ne(){for(var Z in this.constructor=W,this.constructor$=X,X.prototype)Q.call(X.prototype,Z)&&Z.charAt(Z.length-1)!=="$"&&(this[Z+"$"]=X.prototype[Z])}return ne.prototype=X.prototype,W.prototype=new ne,W.prototype},withAppended:function(W,X){var Q,ne=W.length,Z=new Array(ne+1);for(Q=0;Q10||W[0]>0}(),q.isNode&&q.toFastProperties(r);try{throw new Error}catch(W){q.lastLineError=W}s.exports=q},{"./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 o=0,a=r.length;o0?(typeof H=="string"||ae.objectMode||Object.getPrototypeOf(H)===f.prototype||(H=function(fe){return f.from(fe)}(H)),K?ae.endEmitted?B.emit("error",new Error("stream.unshift() after end event")):P(B,ae,H,!0):ae.ended?B.emit("error",new Error("stream.push() after EOF")):(ae.reading=!1,ae.decoder&&!ee?(H=ae.decoder.write(H),ae.objectMode||H.length!==0?P(B,ae,H,!1):I(B,ae)):P(B,ae,H,!1))):K||(ae.reading=!1)),function(fe){return!fe.ended&&(fe.needReadable||fe.lengthH.highWaterMark&&(H.highWaterMark=function(ee){return ee>=T?ee=T:(ee--,ee|=ee>>>1,ee|=ee>>>2,ee|=ee>>>4,ee|=ee>>>8,ee|=ee>>>16,ee++),ee}(B)),B<=H.length?B:H.ended?H.length:(H.needReadable=!0,0))}function D(B){var H=B._readableState;H.needReadable=!1,H.emittedReadable||(g("emitReadable",H.flowing),H.emittedReadable=!0,H.sync?o.nextTick(k,B):k(B))}function k(B){g("emit readable"),B.emit("readable"),X(B)}function I(B,H){H.readingMore||(H.readingMore=!0,o.nextTick(F,B,H))}function F(B,H){for(var ee=H.length;!H.reading&&!H.flowing&&!H.ended&&H.length=H.length?(ee=H.decoder?H.buffer.join(""):H.buffer.length===1?H.buffer.head.data:H.buffer.concat(H.length),H.buffer.clear()):ee=function(K,te,ie){var ae;return KY.length?Y.length:fe;if(oe===Y.length?J+=Y:J+=Y.slice(0,fe),(fe-=oe)==0){oe===Y.length?(++U,N.next?j.head=N.next:j.head=j.tail=null):(j.head=N,N.data=Y.slice(oe));break}++U}return j.length-=U,J}(K,te):function(fe,j){var N=f.allocUnsafe(fe),U=j.head,J=1;for(U.data.copy(N),fe-=U.data.length;U=U.next;){var Y=U.data,oe=fe>Y.length?Y.length:fe;if(Y.copy(N,N.length-fe,0,oe),(fe-=oe)==0){oe===Y.length?(++J,U.next?j.head=U.next:j.head=j.tail=null):(j.head=U,U.data=Y.slice(oe));break}++J}return j.length-=J,N}(K,te),ae}(B,H.buffer,H.decoder),ee);var ee}function ne(B){var H=B._readableState;if(H.length>0)throw new Error('"endReadable()" called on non-empty stream');H.endEmitted||(H.ended=!0,o.nextTick(Z,H,B))}function Z(B,H){B.endEmitted||B.length!==0||(B.endEmitted=!0,H.readable=!1,H.emit("end"))}function z(B,H){for(var ee=0,K=B.length;ee=H.highWaterMark||H.ended))return g("read: emitReadable",H.length,H.ended),H.length===0&&H.ended?ne(this):D(this),null;if((B=A(B,H))===0&&H.ended)return H.length===0&&ne(this),null;var K,te=H.needReadable;return g("need readable",te),(H.length===0||H.length-B0?Q(B,H):null)===null?(H.needReadable=!0,B=0):H.length-=B,H.length===0&&(H.ended||(H.needReadable=!0),ee!==B&&H.ended&&ne(this)),K!==null&&this.emit("data",K),K},S.prototype._read=function(B){this.emit("error",new Error("_read() is not implemented"))},S.prototype.pipe=function(B,H){var ee=this,K=this._readableState;switch(K.pipesCount){case 0:K.pipes=B;break;case 1:K.pipes=[K.pipes,B];break;default:K.pipes.push(B)}K.pipesCount+=1,g("pipe count=%d opts=%j",K.pipesCount,H);var te=H&&H.end===!1||B===i.stdout||B===i.stderr?oe:ie;function ie(){g("onend"),B.end()}K.endEmitted?o.nextTick(te):ee.once("end",te),B.on("unpipe",function he(Se,se){g("onunpipe"),Se===ee&&se&&se.hasUnpiped===!1&&(se.hasUnpiped=!0,g("cleanup"),B.removeListener("close",J),B.removeListener("finish",Y),B.removeListener("drain",ae),B.removeListener("error",U),B.removeListener("unpipe",he),ee.removeListener("end",ie),ee.removeListener("end",oe),ee.removeListener("data",N),fe=!0,!K.awaitDrain||B._writableState&&!B._writableState.needDrain||ae())});var ae=function(he){return function(){var Se=he._readableState;g("pipeOnDrain",Se.awaitDrain),Se.awaitDrain&&Se.awaitDrain--,Se.awaitDrain===0&&l(he,"data")&&(Se.flowing=!0,X(he))}}(ee);B.on("drain",ae);var fe=!1,j=!1;function N(he){g("ondata"),j=!1,B.write(he)!==!1||j||((K.pipesCount===1&&K.pipes===B||K.pipesCount>1&&z(K.pipes,B)!==-1)&&!fe&&(g("false write response, pause",ee._readableState.awaitDrain),ee._readableState.awaitDrain++,j=!0),ee.pause())}function U(he){g("onerror",he),oe(),B.removeListener("error",U),l(B,"error")===0&&B.emit("error",he)}function J(){B.removeListener("finish",Y),oe()}function Y(){g("onfinish"),B.removeListener("close",J),oe()}function oe(){g("unpipe"),ee.unpipe(B)}return ee.on("data",N),function(he,Se,se){if(typeof he.prependListener=="function")return he.prependListener(Se,se);he._events&&he._events[Se]?s(he._events[Se])?he._events[Se].unshift(se):he._events[Se]=[se,he._events[Se]]:he.on(Se,se)}(B,"error",U),B.once("close",J),B.once("finish",Y),B.emit("pipe",ee),K.flowing||(g("pipe resume"),ee.resume()),B},S.prototype.unpipe=function(B){var H=this._readableState,ee={hasUnpiped:!1};if(H.pipesCount===0)return this;if(H.pipesCount===1)return B&&B!==H.pipes?this:(B||(B=H.pipes),H.pipes=null,H.pipesCount=0,H.flowing=!1,B&&B.emit("unpipe",this,ee),this);if(!B){var K=H.pipes,te=H.pipesCount;H.pipes=null,H.pipesCount=0,H.flowing=!1;for(var ie=0;ie>5==6?2:g>>4==14?3:g>>3==30?4:g>>6==2?-1:-2}function s(g){var y=this.lastTotal-this.lastNeed,x=function(_,b,w){if((192&b[0])!=128)return _.lastNeed=0,"�";if(_.lastNeed>1&&b.length>1){if((192&b[1])!=128)return _.lastNeed=1,"�";if(_.lastNeed>2&&b.length>2&&(192&b[2])!=128)return _.lastNeed=2,"�"}}(this,g);return x!==void 0?x:this.lastNeed<=g.length?(g.copy(this.lastChar,y,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(g.copy(this.lastChar,y,0,g.length),void(this.lastNeed-=g.length))}function l(g,y){if((g.length-y)%2==0){var x=g.toString("utf16le",y);if(x){var _=x.charCodeAt(x.length-1);if(_>=55296&&_<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1],x.slice(0,-1)}return x}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=g[g.length-1],g.toString("utf16le",y,g.length-1)}function u(g){var y=g&&g.length?this.write(g):"";if(this.lastNeed){var x=this.lastTotal-this.lastNeed;return y+this.lastChar.toString("utf16le",0,x)}return y}function f(g,y){var x=(g.length-y)%3;return x===0?g.toString("base64",y):(this.lastNeed=3-x,this.lastTotal=3,x===1?this.lastChar[0]=g[g.length-1]:(this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1]),g.toString("base64",y,g.length-x))}function d(g){var y=g&&g.length?this.write(g):"";return this.lastNeed?y+this.lastChar.toString("base64",0,3-this.lastNeed):y}function h(g){return g.toString(this.encoding)}function v(g){return g&&g.length?this.write(g):""}t.StringDecoder=o,o.prototype.write=function(g){if(g.length===0)return"";var y,x;if(this.lastNeed){if((y=this.fillLast(g))===void 0)return"";x=this.lastNeed,this.lastNeed=0}else x=0;return x=0?(P>0&&(b.lastNeed=P-1),P):--E=0?(P>0&&(b.lastNeed=P-2),P):--E=0?(P>0&&(P===2?P=0:b.lastNeed=P-3),P):0}(this,g,y);if(!this.lastNeed)return g.toString("utf8",y);this.lastTotal=x;var _=g.length-(x-this.lastNeed);return g.copy(this.lastChar,0,_),g.toString("utf8",y,_)},o.prototype.fillLast=function(g){if(this.lastNeed<=g.length)return g.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,this.lastTotal-this.lastNeed,0,g.length),this.lastNeed-=g.length}},function(e,t,n){e.exports=o;var r=n(1),i=n(5);function o(l){if(!(this instanceof o))return new o(l);r.call(this,l),this._transformState={afterTransform:(function(u,f){var d=this._transformState;d.transforming=!1;var h=d.writecb;if(!h)return this.emit("error",new Error("write callback called multiple times"));d.writechunk=null,d.writecb=null,f!=null&&this.push(f),h(u);var v=this._readableState;v.reading=!1,(v.needReadable||v.length-1&&a.push(i[s]);return a},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 o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)s.hasOwnProperty(l)&&(a[l]=s[l])};return function(a,s){function l(){this.constructor=a}o(a,s),a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}}();Object.defineProperty(t,"__esModule",{value:!0});var i=function(o){function a(s,l,u){var f=o.call(this,"Error: "+s+". JSON Line number: "+l+(u?" near: "+u:""))||this;return f.err=s,f.line=l,f.extra=u,f.name="CSV Parse Error",f}return r(a,o),a.column_mismatched=function(s,l){return new a("column_mismatched",s,l)},a.unclosed_quote=function(s,l){return new a("unclosed_quote",s,l)},a.fromJSON=function(s){return new a(s.err,s.line,s.extra)},a.prototype.toJSON=function(){return{err:this.err,line:this.line,extra:this.extra}},a}(Error);t.default=i},function(e,t,n){var r=n(18),i=n(68),o=n(69),a=r?r.toStringTag:void 0;e.exports=function(s){return s==null?s===void 0?"[object Undefined]":"[object Null]":a&&a in Object(s)?i(s):o(s)}},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(o,a){return new r.Converter(o,a)};i.csv=i,i.Converter=r.Converter,e.exports=i},function(e,t,n){(function(r){var i=this&&this.__extends||function(){var v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,y){g.__proto__=y}||function(g,y){for(var x in y)y.hasOwnProperty(x)&&(g[x]=y[x])};return function(g,y){function x(){this.constructor=g}v(g,y),g.prototype=y===null?Object.create(y):(x.prototype=y.prototype,new x)}}(),o=this&&this.__importDefault||function(v){return v&&v.__esModule?v:{default:v}};Object.defineProperty(t,"__esModule",{value:!0});var a=n(36),s=n(50),l=n(51),u=o(n(15)),f=n(52),d=n(105),h=function(v){function g(y,x){x===void 0&&(x={});var _=v.call(this,x)||this;return _.options=x,_.params=s.mergeParams(y),_.runtime=l.initParseRuntime(_),_.result=new d.Result(_),_.processor=new f.ProcessorLocal(_),_.once("error",function(b){r(function(){_.result.processError(b),_.emit("done",b)})}),_.once("done",function(){_.processor.destroy()}),_}return i(g,v),g.prototype.preRawData=function(y){return this.runtime.preRawDataHook=y,this},g.prototype.preFileLine=function(y){return this.runtime.preFileLineHook=y,this},g.prototype.subscribe=function(y,x,_){return this.parseRuntime.subscribe={onNext:y,onError:x,onCompleted:_},this},g.prototype.fromFile=function(y,x){var _=this,b=n(!function(){var w=new Error("Cannot find module 'fs'");throw w.code="MODULE_NOT_FOUND",w}());return b.exists(y,function(w){w?b.createReadStream(y,x).pipe(_):_.emit("error",new Error("File does not exist. Check to make sure the file path to your csv is correct."))}),this},g.prototype.fromStream=function(y){return y.pipe(this),this},g.prototype.fromString=function(y){y.toString();var x=new a.Readable,_=0;return x._read=function(b){if(_>=y.length)this.push(null);else{var w=y.substr(_,b);this.push(w),_+=b}},this.fromStream(x)},g.prototype.then=function(y,x){var _=this;return new u.default(function(b,w){_.parseRuntime.then={onfulfilled:function(S){b(y?y(S):S)},onrejected:function(S){x?b(x(S)):w(S)}}})},Object.defineProperty(g.prototype,"parseParam",{get:function(){return this.params},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"parseRuntime",{get:function(){return this.runtime},enumerable:!0,configurable:!0}),g.prototype._transform=function(y,x,_){var b=this;this.processor.process(y).then(function(w){if(w.length>0)return b.runtime.started=!0,b.result.processResult(w)}).then(function(){b.emit("drained"),_()},function(w){b.runtime.hasError=!0,b.runtime.error=w,b.emit("error",w),_()})},g.prototype._flush=function(y){var x=this;this.processor.flush().then(function(_){if(_.length>0)return x.result.processResult(_)}).then(function(){x.processEnd(y)},function(_){x.emit("error",_),y()})},g.prototype.processEnd=function(y){this.result.endProcess(),this.emit("done"),y()},Object.defineProperty(g.prototype,"parsedLineNumber",{get:function(){return this.runtime.parsedLineNumber},enumerable:!0,configurable:!0}),g}(a.Transform);t.Converter=h}).call(this,n(11).setImmediate)},function(e,t,n){(function(r,i){(function(o,a){if(!o.setImmediate){var s,l=1,u={},f=!1,d=o.document,h=Object.getPrototypeOf&&Object.getPrototypeOf(o);h=h&&h.setTimeout?h:o,{}.toString.call(o.process)==="[object process]"?s=function(y){i.nextTick(function(){g(y)})}:function(){if(o.postMessage&&!o.importScripts){var y=!0,x=o.onmessage;return o.onmessage=function(){y=!1},o.postMessage("","*"),o.onmessage=x,y}}()?function(){var y="setImmediate$"+Math.random()+"$",x=function(_){_.source===o&&typeof _.data=="string"&&_.data.indexOf(y)===0&&g(+_.data.slice(y.length))};o.addEventListener?o.addEventListener("message",x,!1):o.attachEvent("onmessage",x),s=function(_){o.postMessage(y+_,"*")}}():o.MessageChannel?function(){var y=new MessageChannel;y.port1.onmessage=function(x){g(x.data)},s=function(x){y.port2.postMessage(x)}}():d&&"onreadystatechange"in d.createElement("script")?function(){var y=d.documentElement;s=function(x){var _=d.createElement("script");_.onreadystatechange=function(){g(x),_.onreadystatechange=null,y.removeChild(_),_=null},y.appendChild(_)}}():s=function(y){setTimeout(g,0,y)},h.setImmediate=function(y){typeof y!="function"&&(y=new Function(""+y));for(var x=new Array(arguments.length-1),_=0;_"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(o,a){var s=this;function l(y){o.writable&&o.write(y)===!1&&s.pause&&s.pause()}function u(){s.readable&&s.resume&&s.resume()}s.on("data",l),o.on("drain",u),o._isStdio||a&&a.end===!1||(s.on("end",d),s.on("close",h));var f=!1;function d(){f||(f=!0,o.end())}function h(){f||(f=!0,typeof o.destroy=="function"&&o.destroy())}function v(y){if(g(),r.listenerCount(this,"error")===0)throw y}function g(){s.removeListener("data",l),o.removeListener("drain",u),s.removeListener("end",d),s.removeListener("close",h),s.removeListener("error",v),o.removeListener("error",v),s.removeListener("end",g),s.removeListener("close",g),o.removeListener("close",g)}return s.on("error",v),o.on("error",v),s.on("end",g),s.on("close",g),o.on("close",g),o.emit("pipe",s),o}},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(h){var v=u(h),g=v[0],y=v[1];return 3*(g+y)/4-y},t.toByteArray=function(h){for(var v,g=u(h),y=g[0],x=g[1],_=new o(3*(y+x)/4-x),b=0,w=x>0?y-4:y,S=0;S>16&255,_[b++]=v>>8&255,_[b++]=255&v;return x===2&&(v=i[h.charCodeAt(S)]<<2|i[h.charCodeAt(S+1)]>>4,_[b++]=255&v),x===1&&(v=i[h.charCodeAt(S)]<<10|i[h.charCodeAt(S+1)]<<4|i[h.charCodeAt(S+2)]>>2,_[b++]=v>>8&255,_[b++]=255&v),_},t.fromByteArray=function(h){for(var v,g=h.length,y=g%3,x=[],_=0,b=g-y;_b?b:_+16383));return y===1?(v=h[g-1],x.push(r[v>>2]+r[v<<4&63]+"==")):y===2&&(v=(h[g-2]<<8)+h[g-1],x.push(r[v>>10]+r[v>>4&63]+r[v<<2&63]+"=")),x.join("")};for(var r=[],i=[],o=typeof Uint8Array<"u"?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,l=a.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var g=h.indexOf("=");return g===-1&&(g=v),[g,g===v?0:4-g%4]}function f(h){return r[h>>18&63]+r[h>>12&63]+r[h>>6&63]+r[63&h]}function d(h,v,g){for(var y,x=[],_=v;_>1,h=-7,v=i?a-1:0,g=i?-1:1,y=n[r+v];for(v+=g,s=y&(1<<-h)-1,y>>=-h,h+=u;h>0;s=256*s+n[r+v],v+=g,h-=8);for(l=s&(1<<-h)-1,s>>=-h,h+=o;h>0;l=256*l+n[r+v],v+=g,h-=8);if(s===0)s=1-d;else{if(s===f)return l?NaN:1/0*(y?-1:1);l+=Math.pow(2,o),s-=d}return(y?-1:1)*l*Math.pow(2,s-o)},t.write=function(n,r,i,o,a,s){var l,u,f,d=8*s-a-1,h=(1<>1,g=a===23?Math.pow(2,-24)-Math.pow(2,-77):0,y=o?0:s-1,x=o?1:-1,_=r<0||r===0&&1/r<0?1:0;for(r=Math.abs(r),isNaN(r)||r===1/0?(u=isNaN(r)?1:0,l=h):(l=Math.floor(Math.log(r)/Math.LN2),r*(f=Math.pow(2,-l))<1&&(l--,f*=2),(r+=l+v>=1?g/f:g*Math.pow(2,1-v))*f>=2&&(l++,f/=2),l+v>=h?(u=0,l=h):l+v>=1?(u=(r*f-1)*Math.pow(2,a),l+=v):(u=r*Math.pow(2,v-1)*Math.pow(2,a),l=0));a>=8;n[i+y]=255&u,y+=x,u/=256,a-=8);for(l=l<0;n[i+y]=255&l,y+=x,l/=256,d-=8);n[i+y-x]|=128*_}},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 o(a,s,l){a.copy(s,l)}e.exports=function(){function a(){(function(s,l){if(!(s instanceof l))throw new TypeError("Cannot call a class as a function")})(this,a),this.head=null,this.tail=null,this.length=0}return a.prototype.push=function(s){var l={data:s,next:null};this.length>0?this.tail.next=l:this.head=l,this.tail=l,++this.length},a.prototype.unshift=function(s){var l={data:s,next:this.head};this.length===0&&(this.tail=l),this.head=l,++this.length},a.prototype.shift=function(){if(this.length!==0){var s=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,s}},a.prototype.clear=function(){this.head=this.tail=null,this.length=0},a.prototype.join=function(s){if(this.length===0)return"";for(var l=this.head,u=""+l.data;l=l.next;)u+=s+l.data;return u},a.prototype.concat=function(s){if(this.length===0)return r.alloc(0);if(this.length===1)return this.head.data;for(var l=r.allocUnsafe(s>>>0),u=this.head,f=0;u;)o(u.data,l,f),f+=u.data.length,u=u.next;return l},a}(),i&&i.inspect&&i.inspect.custom&&(e.exports.prototype[i.inspect.custom]=function(){var a=i.inspect({length:this.length});return this.constructor.name+" "+a})},function(e,t){},function(e,t,n){(function(r){function i(o){try{if(!r.localStorage)return!1}catch{return!1}var a=r.localStorage[o];return a!=null&&String(a).toLowerCase()==="true"}e.exports=function(o,a){if(i("noDeprecation"))return o;var s=!1;return function(){if(!s){if(i("throwDeprecation"))throw new Error(a);i("traceDeprecation")?console.trace(a):console.warn(a),s=!0}return o.apply(this,arguments)}}}).call(this,n(0))},function(e,t,n){e.exports=o;var r=n(27),i=n(5);function o(a){if(!(this instanceof o))return new o(a);r.call(this,a)}i.inherits=n(2),i.inherits(o,r),o.prototype._transform=function(a,s,l){l(null,a)}},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 o in r||(r={}),r)r.hasOwnProperty(o)&&(Array.isArray(r[o])?i[o]=[].concat(r[o]):i[o]=r[o]);return i}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.initParseRuntime=function(r){var i=r.parseParam,o={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&&(o.needProcessIgnoreColumn=!0),i.includeColumns&&(o.needProcessIncludeColumn=!0),o}},function(e,t,n){(function(r){var i=this&&this.__extends||function(){var x=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,b){_.__proto__=b}||function(_,b){for(var w in b)b.hasOwnProperty(w)&&(_[w]=b[w])};return function(_,b){function w(){this.constructor=_}x(_,b),_.prototype=b===null?Object.create(b):(w.prototype=b.prototype,new w)}}(),o=this&&this.__importDefault||function(x){return x&&x.__esModule?x:{default:x}};Object.defineProperty(t,"__esModule",{value:!0});var a=n(53),s=o(n(15)),l=n(54),u=o(n(16)),f=n(57),d=n(28),h=n(58),v=o(n(59)),g=o(n(29)),y=function(x){function _(){var b=x!==null&&x.apply(this,arguments)||this;return b.rowSplit=new h.RowSplit(b.converter),b.eolEmitted=!1,b._needEmitEol=void 0,b.headEmitted=!1,b._needEmitHead=void 0,b}return i(_,x),_.prototype.flush=function(){var b=this;if(this.runtime.csvLineBuffer&&this.runtime.csvLineBuffer.length>0){var w=this.runtime.csvLineBuffer;return this.runtime.csvLineBuffer=void 0,this.process(w,!0).then(function(S){return b.runtime.csvLineBuffer&&b.runtime.csvLineBuffer.length>0?s.default.reject(g.default.unclosed_quote(b.runtime.parsedLineNumber,b.runtime.csvLineBuffer.toString())):s.default.resolve(S)})}return s.default.resolve([])},_.prototype.destroy=function(){return s.default.resolve()},Object.defineProperty(_.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(_.prototype,"needEmitHead",{get:function(){return this._needEmitHead===void 0&&(this._needEmitHead=this.converter.listeners("header").length>0),this._needEmitHead},enumerable:!0,configurable:!0}),_.prototype.process=function(b,w){var S,E=this;return w===void 0&&(w=!1),S=w?b.toString():l.prepareData(b,this.converter.parseRuntime),s.default.resolve().then(function(){return E.runtime.preRawDataHook?E.runtime.preRawDataHook(S):S}).then(function(P){return P&&P.length>0?E.processCSV(P,w):s.default.resolve([])})},_.prototype.processCSV=function(b,w){var S=this,E=this.params,P=this.runtime;P.eol||u.default(b,P),this.needEmitEol&&!this.eolEmitted&&P.eol&&(this.converter.emit("eol",P.eol),this.eolEmitted=!0),E.ignoreEmpty&&!P.started&&(b=d.trimLeft(b));var T=f.stringToLines(b,P);return w?(T.lines.push(T.partial),T.partial=""):this.prependLeftBuf(d.bufFromString(T.partial)),T.lines.length>0?(P.preFileLineHook?this.runPreLineHook(T.lines):s.default.resolve(T.lines)).then(function(A){return P.started||S.runtime.headers?S.processCSVBody(A):S.processDataWithHead(A)}):s.default.resolve([])},_.prototype.processDataWithHead=function(b){if(this.params.noheader)this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=[];else{for(var w="",S=[];b.length;){var E=w+b.shift(),P=this.rowSplit.parse(E);if(P.closed){S=P.cells,w="";break}w=E+u.default(E,this.runtime)}if(this.prependLeftBuf(d.bufFromString(w)),S.length===0)return[];this.params.headers?this.runtime.headers=this.params.headers:this.runtime.headers=S}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(b)},_.prototype.filterHeader=function(){if(this.runtime.selectedColumns=[],this.runtime.headers){for(var b=this.runtime.headers,w=0;w=T.length)k();else if(A.preFileLineHook){var I=T[D],F=A.preFileLineHook(I,A.parsedLineNumber+D);if(D++,F&&F.then)F.then(function(q){T[D-1]=q,P(T,A,D,k)});else{for(T[D-1]=F;D0?r.concat([d.csvLineBuffer,f]):f}(a,s);s.csvLineBuffer=void 0;var u=function(f,d){var h=f.length-1;if(128&f[h]){for(;(192&f[h])==128;)h--;h--}return h!=f.length-1?(d.csvLineBuffer=f.slice(h+1),f.slice(0,h+1)):f}(l,s).toString("utf8");return s.started===!1?o.default(u):u}}).call(this,n(3).Buffer)},function(e,t,n){(function(r){var i=n(56);e.exports=function(o){return typeof o=="string"&&o.charCodeAt(0)===65279?o.slice(1):r.isBuffer(o)&&i(o)&&o[0]===239&&o[1]===187&&o[2]===191?o.slice(3):o}}).call(this,n(3).Buffer)},function(e,t){e.exports=function(n){for(var r=0;r0),this._needEmitDelimiter},enumerable:!0,configurable:!0}),l.prototype.parse=function(u){if(u.length===0||this.conv.parseParam.ignoreEmpty&&u.trim().length===0)return{cells:[],closed:!0};var f=this.quote,d=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 h=this.conv.parseRuntime.delimiter,v=u.split(h);if(f==="off"){if(d)for(var g=0;gd&&(h=v,d=g)}),h},l.prototype.isQuoteOpen=function(u){var f=this.quote,d=this.escape;return u[0]===f&&(u[1]!==f||u[1]===d&&(u[2]===f||u.length===2))},l.prototype.isQuoteClose=function(u){var f=this.quote,d=this.escape;this.conv.parseParam.trim&&(u=o.trimRight(u));for(var h=0,v=u.length-1;u[v]===f||u[v]===d;)v--,h++;return h%2!=0},l.prototype.escapeQuote=function(u){var f="es|"+this.quote+"|"+this.escape;this.cachedRegExp[f]===void 0&&(this.cachedRegExp[f]=new RegExp("\\"+this.escape+"\\"+this.quote,"g"));var d=this.cachedRegExp[f];return u.replace(d,this.quote)},l.prototype.parseMultiLines=function(u){for(var f=[],d="";u.length;){var h=d+u.shift(),v=this.parse(h);v.cells.length===0&&this.conv.parseParam.ignoreEmpty||(v.closed||this.conv.parseParam.alwaysSplitAtEOL?(this.conv.parseRuntime.selectedColumns?f.push(o.filterArray(v.cells,this.conv.parseRuntime.selectedColumns)):f.push(v.cells),d=""):d=h+(i.default(h,this.conv.parseRuntime)||` `))}return{rowsCells:f,partial:d}},l}();t.RowSplit=s},function(e,t,n){var r=this&&this.__importDefault||function(_){return _&&_.__esModule?_:{default:_}};Object.defineProperty(t,"__esModule",{value:!0});var i=r(n(29)),o=r(n(60)),a=/^[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?$/;function s(_,b,w){if(b.parseParam.checkColumn&&b.parseRuntime.headers&&_.length!==b.parseRuntime.headers.length)throw i.default.column_mismatched(b.parseRuntime.parsedLineNumber+w);return function(S,E,P){for(var T=!1,A={},D=0,k=S.length;D-1){for(var P=b.split("."),T=!0;P.length>0;)if(P.shift().length===0){T=!1;break}!T||S.parseParam.colParser[b]&&S.parseParam.colParser[b].flat?S.parseRuntime.columnValueSetter[E]=d:S.parseRuntime.columnValueSetter[E]=h}else S.parseRuntime.columnValueSetter[E]=d;S.parseParam.nullObject===!0&&w==="null"&&(w=null),S.parseRuntime.columnValueSetter[E](_,b,w)}function d(_,b,w){_[b]=w}function h(_,b,w){o.default(_,b,w)}function v(_,b,w,S){return S.parseRuntime.headerType[w]?S.parseRuntime.headerType[w]:b.indexOf("number#!")>-1?S.parseRuntime.headerType[w]=g:b.indexOf("string#!")>-1?S.parseRuntime.headerType[w]=y:S.parseParam.checkType?S.parseRuntime.headerType[w]=x:S.parseRuntime.headerType[w]=y}function g(_){var b=parseFloat(_);return isNaN(b)?_:b}function y(_){return _.toString()}function x(_){var b=_.trim();return b===""?y(_):a.test(b)?g(_):b.length===5&&b.toLowerCase()==="false"||b.length===4&&b.toLowerCase()==="true"?function(w){var S=w.trim();return S.length!==5||S.toLowerCase()!=="false"}(_):b[0]==="{"&&b[b.length-1]==="}"||b[0]==="["&&b[b.length-1]==="]"?function(w){try{return JSON.parse(w)}catch{return w}}(_):y(_)}},function(e,t,n){var r=n(61);e.exports=function(i,o,a){return i==null?i:r(i,o,a)}},function(e,t,n){var r=n(62),i=n(74),o=n(103),a=n(20),s=n(104);e.exports=function(l,u,f,d){if(!a(l))return l;for(var h=-1,v=(u=i(u,l)).length,g=v-1,y=l;y!=null&&++h-1}},function(e,t,n){var r=n(9);e.exports=function(i,o){var a=this.__data__,s=r(a,i);return s<0?(++this.size,a.push([i,o])):a[s][1]=o,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 o=r(this,i).delete(i);return this.size-=o?1:0,o}},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,o){var a=r(this,i),s=a.size;return a.set(i,o),this.size+=a.size==s?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),o=n(21),a=n(22),s=r?r.prototype:void 0,l=s?s.toString:void 0;e.exports=function u(f){if(typeof f=="string")return f;if(o(f))return i(f,u)+"";if(a(f))return l?l.call(f):"";var d=f+"";return d=="0"&&1/f==-1/0?"-0":d}},function(e,t){e.exports=function(n,r){for(var i=-1,o=n==null?0:n.length,a=Array(o);++i-1&&r%1==0&&r0||this.converter.listeners("readable").length>0),this._needPushDownstream},enumerable:!0,configurable:!0}),Object.defineProperty(l.prototype,"needEmitAll",{get:function(){return!!this.converter.parseRuntime.then&&this.converter.parseParam.needEmitAll},enumerable:!0,configurable:!0}),l.prototype.processResult=function(u){var f=this,d=this.converter.parseRuntime.parsedLineNumber;return this.needPushDownstream&&this.converter.parseParam.downstreamFormat==="array"&&d===0&&s(this.converter,"["+o.EOL),new i.default(function(h,v){f.needEmitLine?function g(y,x,_,b,w){if(_>=y.length)w();else if(x.parseRuntime.subscribe&&x.parseRuntime.subscribe.onNext){var S=x.parseRuntime.subscribe.onNext,E=y[_],P=S(E,x.parseRuntime.parsedLineNumber+_);if(_++,P&&P.then)P.then(function(){(function(A,D,k,I,F,q,W){F&&s(k,W),g(A,k,I,F,q)})(y,0,x,_,b,w,E)},w);else{for(b&&s(x,E);_new Promise(t=>{DFe().fromString(e).then(t)}),BFe=new jF,UFe=e=>BFe.parse(e),zFe="shlink",W$=e=>`${zFe}.${e}`;class VFe{constructor(t){Ql(this,"get",t=>{const n=this.localStorage.getItem(W$(t));return n?JSON.parse(n):void 0});Ql(this,"set",(t,n)=>this.localStorage.setItem(W$(t),JSON.stringify(n)));this.localStorage=t}}class WFe{constructor(t){this.storage=t}getTagColors(){return this.storage.get("colors")??{}}storeTagColors(t){this.storage.set("colors",t)}}const HFe=e=>{e.constant("localStorage",window.localStorage),e.service("Storage",VFe,"localStorage"),e.service("TagColorsStorage",WFe,"Storage"),e.constant("csvToJson",FFe),e.constant("jsonToCsv",UFe),e.serviceFactory("useTimeoutToggle",()=>L8)},zl=new RD,{container:XT}=zl,GFe=(e,t)=>(...n)=>e[t](...n),qFe=(e,t)=>({...e,[t]:GFe(XT,t)}),KFe=e=>t=>Object.fromEntries(e.map(n=>[n,t[n]])),f1=(e,t=[])=>cD(e?KFe(e):null,t.reduce(qFe,{}));jue(zl,f1);F8e(zl,f1);rZ(zl);jFe(zl,f1);HFe(zl);$Fe(zl,f1);var QT={},aE={exports:{}};(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=[],f=0;fz.length)&&(B=z.length);for(var H=0,ee=Array(B);HiC({appUpdated:Tue,servers:fFe,selectedServer:e.selectedServerReducer,settings:RFe}),XFe=e=>{var t;return e.settings&&((t=e.settings.visits)==null?void 0:t.defaultInterval)==="last180days"&&e.settings.visits&&(e.settings.visits.defaultInterval="last180Days"),e},QFe=!0,NV={states:["settings","servers"],namespace:"shlink",namespaceSeparator:".",debounce:300},JFe=XFe(QT.load(NV)),e7e=e=>tF({devTools:!QFe,reducer:ZFe(e),preloadedState:JFe,middleware:t=>t({immutableCheck:!1,serializableCheck:!1}).concat(QT.save(NV))}),t7e=!!(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 n7e(e){if("serviceWorker"in navigator){if(new URL(Lg.homepage,window.location.href).origin!==window.location.origin)return;window.addEventListener("load",()=>{const n=`${Lg.homepage}/service-worker.js`;t7e?(r7e(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")})):MV(n,e)})}}function MV(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 r7e(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()})}):MV(e,t)}).catch(()=>{console.log("No internet connection found. App is running in offline mode.")})}const RV=e7e(XT),{App:i7e,ScrollToTop:o7e,ErrorHandler:a7e,appUpdateAvailable:s7e}=XT;rD(document.getElementById("root")).render(m.jsx(fD,{store:RV,children:m.jsx(wD,{basename:Lg.homepage,children:m.jsx(a7e,{children:m.jsx(o7e,{children:m.jsx(i7e,{})})})})}));n7e({onUpdate(){RV.dispatch(s7e())}});