diff --git a/assets/index-8db0b7c9.js b/assets/index-8db0b7c9.js new file mode 100644 index 0000000..43f8c84 --- /dev/null +++ b/assets/index-8db0b7c9.js @@ -0,0 +1,117 @@ +(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))i(r);new MutationObserver(r=>{for(const s of r)if(s.type==="childList")for(const u of s.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&i(u)}).observe(document,{childList:!0,subtree:!0});function n(r){const s={};return r.integrity&&(s.integrity=r.integrity),r.referrerPolicy&&(s.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?s.credentials="include":r.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function i(r){if(r.ep)return;r.ep=!0;const s=n(r);fetch(r.href,s)}})();var a2=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Lt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var E_={exports:{}},Br={},M_={exports:{}},ye={};/** + * @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 m9=Symbol.for("react.element"),GC=Symbol.for("react.portal"),qC=Symbol.for("react.fragment"),VC=Symbol.for("react.strict_mode"),YC=Symbol.for("react.profiler"),XC=Symbol.for("react.provider"),KC=Symbol.for("react.context"),JC=Symbol.for("react.forward_ref"),eN=Symbol.for("react.suspense"),tN=Symbol.for("react.memo"),nN=Symbol.for("react.lazy"),wp=Symbol.iterator;function iN(e){return e===null||typeof e!="object"?null:(e=wp&&e[wp]||e["@@iterator"],typeof e=="function"?e:null)}var A_={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},k_=Object.assign,T_={};function e0(e,t,n){this.props=e,this.context=t,this.refs=T_,this.updater=n||A_}e0.prototype.isReactComponent={};e0.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")};e0.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function P_(){}P_.prototype=e0.prototype;function Sc(e,t,n){this.props=e,this.context=t,this.refs=T_,this.updater=n||A_}var Ec=Sc.prototype=new P_;Ec.constructor=Sc;k_(Ec,e0.prototype);Ec.isPureReactComponent=!0;var xp=Array.isArray,C_=Object.prototype.hasOwnProperty,Mc={current:null},N_={key:!0,ref:!0,__self:!0,__source:!0};function O_(e,t,n){var i,r={},s=null,u=null;if(t!=null)for(i in t.ref!==void 0&&(u=t.ref),t.key!==void 0&&(s=""+t.key),t)C_.call(t,i)&&!N_.hasOwnProperty(i)&&(r[i]=t[i]);var f=arguments.length-2;if(f===1)r.children=n;else if(1>>1,k1=Y[w1];if(0>>1;w1r(v1,f1))d1r(I1,v1)?(Y[w1]=I1,Y[d1]=f1,w1=d1):(Y[w1]=v1,Y[O1]=f1,w1=O1);else if(d1r(I1,f1))Y[w1]=I1,Y[d1]=f1,w1=d1;else break e}}return g1}function r(Y,g1){var f1=Y.sortIndex-g1.sortIndex;return f1!==0?f1:Y.id-g1.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var u=Date,f=u.now();e.unstable_now=function(){return u.now()-f}}var d=[],p=[],m=1,h=null,_=3,S=!1,E=!1,k=!1,O=typeof setTimeout=="function"?setTimeout:null,x=typeof clearTimeout=="function"?clearTimeout:null,w=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function b(Y){for(var g1=n(p);g1!==null;){if(g1.callback===null)i(p);else if(g1.startTime<=Y)i(p),g1.sortIndex=g1.expirationTime,t(d,g1);else break;g1=n(p)}}function N(Y){if(k=!1,b(Y),!E)if(n(d)!==null)E=!0,l1(B);else{var g1=n(p);g1!==null&&r1(N,g1.startTime-Y)}}function B(Y,g1){E=!1,k&&(k=!1,x($),$=-1),S=!0;var f1=_;try{for(b(g1),h=n(d);h!==null&&(!(h.expirationTime>g1)||Y&&!Q());){var w1=h.callback;if(typeof w1=="function"){h.callback=null,_=h.priorityLevel;var k1=w1(h.expirationTime<=g1);g1=e.unstable_now(),typeof k1=="function"?h.callback=k1:h===n(d)&&i(d),b(g1)}else i(d);h=n(d)}if(h!==null)var U1=!0;else{var O1=n(p);O1!==null&&r1(N,O1.startTime-g1),U1=!1}return U1}finally{h=null,_=f1,S=!1}}var R=!1,j=null,$=-1,K=5,H=-1;function Q(){return!(e.unstable_now()-HY||125w1?(Y.sortIndex=f1,t(p,Y),n(d)===null&&Y===n(p)&&(k?(x($),$=-1):k=!0,r1(N,f1-w1))):(Y.sortIndex=k1,t(d,Y),E||S||(E=!0,l1(B))),Y},e.unstable_shouldYield=Q,e.unstable_wrapCallback=function(Y){var g1=_;return function(){var f1=_;_=g1;try{return Y.apply(this,arguments)}finally{_=f1}}}})(R_);I_.exports=R_;var pN=I_.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 U_=G,w4=pN;function A1(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"),Iu=Object.prototype.hasOwnProperty,gN=/^[: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]*$/,Sp={},Ep={};function mN(e){return Iu.call(Ep,e)?!0:Iu.call(Sp,e)?!1:gN.test(e)?Ep[e]=!0:(Sp[e]=!0,!1)}function yN(e,t,n,i){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return i?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function _N(e,t,n,i){if(t===null||typeof t>"u"||yN(e,t,n,i))return!0;if(i)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 qt(e,t,n,i,r,s,u){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=i,this.attributeNamespace=r,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=u}var xt={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){xt[e]=new qt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];xt[t]=new qt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){xt[e]=new qt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){xt[e]=new qt(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){xt[e]=new qt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){xt[e]=new qt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){xt[e]=new qt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){xt[e]=new qt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){xt[e]=new qt(e,5,!1,e.toLowerCase(),null,!1,!1)});var kc=/[\-:]([a-z])/g;function Tc(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(kc,Tc);xt[t]=new qt(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(kc,Tc);xt[t]=new qt(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(kc,Tc);xt[t]=new qt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){xt[e]=new qt(e,1,!1,e.toLowerCase(),null,!1,!1)});xt.xlinkHref=new qt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){xt[e]=new qt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Pc(e,t,n,i){var r=xt.hasOwnProperty(t)?xt[t]:null;(r!==null?r.type!==0:i||!(2f||r[u]!==s[f]){var d=` +`+r[u].replace(" at new "," at ");return e.displayName&&d.includes("")&&(d=d.replace("",e.displayName)),d}while(1<=u&&0<=f);break}}}finally{La=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?g7(e):""}function vN(e){switch(e.tag){case 5:return g7(e.type);case 16:return g7("Lazy");case 13:return g7("Suspense");case 19:return g7("SuspenseList");case 0:case 2:case 15:return e=Fa(e.type,!1),e;case 11:return e=Fa(e.type.render,!1),e;case 1:return e=Fa(e.type,!0),e;default:return""}}function Bu(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 p6:return"Fragment";case h6:return"Portal";case Ru:return"Profiler";case Cc:return"StrictMode";case Uu:return"Suspense";case $u:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case z_:return(e.displayName||"Context")+".Consumer";case B_:return(e._context.displayName||"Context")+".Provider";case Nc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Oc:return t=e.displayName||null,t!==null?t:Bu(e.type)||"Memo";case $3:t=e._payload,e=e._init;try{return Bu(e(t))}catch{}}return null}function wN(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 Bu(t);case 8:return t===Cc?"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 tn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function D_(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function xN(e){var t=D_(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),i=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var r=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return r.call(this)},set:function(u){i=""+u,s.call(this,u)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(u){i=""+u},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Ii(e){e._valueTracker||(e._valueTracker=xN(e))}function Q_(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=D_(e)?e.checked?"true":"false":e.value),e=i,e!==n?(t.setValue(e),!0):!1}function $8(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 zu(e,t){var n=t.checked;return qe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Ap(e,t){var n=t.defaultValue==null?"":t.defaultValue,i=t.checked!=null?t.checked:t.defaultChecked;n=tn(t.value!=null?t.value:n),e._wrapperState={initialChecked:i,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function W_(e,t){t=t.checked,t!=null&&Pc(e,"checked",t,!1)}function ju(e,t){W_(e,t);var n=tn(t.value),i=t.type;if(n!=null)i==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(i==="submit"||i==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Du(e,t.type,n):t.hasOwnProperty("defaultValue")&&Du(e,t.type,tn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function kp(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var i=t.type;if(!(i!=="submit"&&i!=="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 Du(e,t,n){(t!=="number"||$8(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var m7=Array.isArray;function C6(e,t,n,i){if(e=e.options,t){t={};for(var r=0;r"+t.valueOf().toString()+"",t=Ri.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function U7(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var b7={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},bN=["Webkit","ms","Moz","O"];Object.keys(b7).forEach(function(e){bN.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),b7[t]=b7[e]})});function q_(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||b7.hasOwnProperty(e)&&b7[e]?(""+t).trim():t+"px"}function V_(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var i=n.indexOf("--")===0,r=q_(n,t[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,r):e[n]=r}}var SN=qe({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 Hu(e,t){if(t){if(SN[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(A1(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(A1(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(A1(61))}if(t.style!=null&&typeof t.style!="object")throw Error(A1(62))}}function Zu(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 Gu=null;function Lc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var qu=null,N6=null,O6=null;function Cp(e){if(e=v9(e)){if(typeof qu!="function")throw Error(A1(280));var t=e.stateNode;t&&(t=Wr(t),qu(e.stateNode,e.type,t))}}function Y_(e){N6?O6?O6.push(e):O6=[e]:N6=e}function X_(){if(N6){var e=N6,t=O6;if(O6=N6=null,Cp(e),t)for(e=0;e>>=0,e===0?32:31-(FN(e)/IN|0)|0}var Ui=64,$i=4194304;function y7(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 D8(e,t){var n=e.pendingLanes;if(n===0)return 0;var i=0,r=e.suspendedLanes,s=e.pingedLanes,u=n&268435455;if(u!==0){var f=u&~r;f!==0?i=y7(f):(s&=u,s!==0&&(i=y7(s)))}else u=n&~r,u!==0?i=y7(u):s!==0&&(i=y7(s));if(i===0)return 0;if(t!==0&&t!==i&&!(t&r)&&(r=i&-i,s=t&-t,r>=s||r===16&&(s&4194240)!==0))return t;if(i&4&&(i|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=i;0n;n++)t.push(e);return t}function y9(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-c2(t),e[t]=n}function BN(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 i=e.eventTimes;for(e=e.expirationTimes;0=E7),Bp=String.fromCharCode(32),zp=!1;function yv(e,t){switch(e){case"keyup":return hO.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _v(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var g6=!1;function gO(e,t){switch(e){case"compositionend":return _v(t);case"keypress":return t.which!==32?null:(zp=!0,Bp);case"textInput":return e=t.data,e===Bp&&zp?null:e;default:return null}}function mO(e,t){if(g6)return e==="compositionend"||!jc&&yv(e,t)?(e=gv(),w8=$c=D3=null,g6=!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=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Wp(n)}}function bv(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?bv(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Sv(){for(var e=window,t=$8();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=$8(e.document)}return t}function Dc(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 MO(e){var t=Sv(),n=e.focusedElem,i=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&bv(n.ownerDocument.documentElement,n)){if(i!==null&&Dc(n)){if(t=i.start,e=i.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 r=n.textContent.length,s=Math.min(i.start,r);i=i.end===void 0?s:Math.min(i.end,r),!e.extend&&s>i&&(r=i,i=s,s=r),r=Hp(n,s);var u=Hp(n,i);r&&u&&(e.rangeCount!==1||e.anchorNode!==r.node||e.anchorOffset!==r.offset||e.focusNode!==u.node||e.focusOffset!==u.offset)&&(t=t.createRange(),t.setStart(r.node,r.offset),e.removeAllRanges(),s>i?(e.addRange(t),e.extend(u.node,u.offset)):(t.setEnd(u.node,u.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,m6=null,el=null,A7=null,tl=!1;function Zp(e,t,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;tl||m6==null||m6!==$8(i)||(i=m6,"selectionStart"in i&&Dc(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),A7&&Q7(A7,i)||(A7=i,i=H8(el,"onSelect"),0v6||(e.current=al[v6],al[v6]=null,v6--)}function Ie(e,t){v6++,al[v6]=e.current,e.current=t}var nn={},Ot=an(nn),o4=an(!1),a5=nn;function D6(e,t){var n=e.type.contextTypes;if(!n)return nn;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===t)return i.__reactInternalMemoizedMaskedChildContext;var r={},s;for(s in n)r[s]=t[s];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=r),r}function s4(e){return e=e.childContextTypes,e!=null}function G8(){Be(o4),Be(Ot)}function Jp(e,t,n){if(Ot.current!==nn)throw Error(A1(168));Ie(Ot,t),Ie(o4,n)}function Ov(e,t,n){var i=e.stateNode;if(t=t.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var r in i)if(!(r in t))throw Error(A1(108,wN(e)||"Unknown",r));return qe({},n,i)}function q8(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||nn,a5=Ot.current,Ie(Ot,e),Ie(o4,o4.current),!0}function eg(e,t,n){var i=e.stateNode;if(!i)throw Error(A1(169));n?(e=Ov(e,t,a5),i.__reactInternalMemoizedMergedChildContext=e,Be(o4),Be(Ot),Ie(Ot,e)):Be(o4),Ie(o4,n)}var s3=null,Hr=!1,qa=!1;function Lv(e){s3===null?s3=[e]:s3.push(e)}function UO(e){Hr=!0,Lv(e)}function un(){if(!qa&&s3!==null){qa=!0;var e=0,t=Te;try{var n=s3;for(Te=1;e>=u,r-=u,a3=1<<32-c2(t)+r|n<$?(K=j,j=null):K=j.sibling;var H=_(x,j,b[$],N);if(H===null){j===null&&(j=K);break}e&&j&&H.alternate===null&&t(x,j),w=s(H,w,$),R===null?B=H:R.sibling=H,R=H,j=K}if($===b.length)return n(x,j),De&&zn(x,$),B;if(j===null){for(;$$?(K=j,j=null):K=j.sibling;var Q=_(x,j,H.value,N);if(Q===null){j===null&&(j=K);break}e&&j&&Q.alternate===null&&t(x,j),w=s(Q,w,$),R===null?B=Q:R.sibling=Q,R=Q,j=K}if(H.done)return n(x,j),De&&zn(x,$),B;if(j===null){for(;!H.done;$++,H=b.next())H=h(x,H.value,N),H!==null&&(w=s(H,w,$),R===null?B=H:R.sibling=H,R=H);return De&&zn(x,$),B}for(j=i(x,j);!H.done;$++,H=b.next())H=S(j,x,$,H.value,N),H!==null&&(e&&H.alternate!==null&&j.delete(H.key===null?$:H.key),w=s(H,w,$),R===null?B=H:R.sibling=H,R=H);return e&&j.forEach(function(e1){return t(x,e1)}),De&&zn(x,$),B}function O(x,w,b,N){if(typeof b=="object"&&b!==null&&b.type===p6&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case Fi:e:{for(var B=b.key,R=w;R!==null;){if(R.key===B){if(B=b.type,B===p6){if(R.tag===7){n(x,R.sibling),w=r(R,b.props.children),w.return=x,x=w;break e}}else if(R.elementType===B||typeof B=="object"&&B!==null&&B.$$typeof===$3&&ag(B)===R.type){n(x,R.sibling),w=r(R,b.props),w.ref=i7(x,R,b),w.return=x,x=w;break e}n(x,R);break}else t(x,R);R=R.sibling}b.type===p6?(w=n5(b.props.children,x.mode,N,b.key),w.return=x,x=w):(N=T8(b.type,b.key,b.props,null,x.mode,N),N.ref=i7(x,w,b),N.return=x,x=N)}return u(x);case h6:e:{for(R=b.key;w!==null;){if(w.key===R)if(w.tag===4&&w.stateNode.containerInfo===b.containerInfo&&w.stateNode.implementation===b.implementation){n(x,w.sibling),w=r(w,b.children||[]),w.return=x,x=w;break e}else{n(x,w);break}else t(x,w);w=w.sibling}w=nu(b,x.mode,N),w.return=x,x=w}return u(x);case $3:return R=b._init,O(x,w,R(b._payload),N)}if(m7(b))return E(x,w,b,N);if(K0(b))return k(x,w,b,N);Hi(x,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,w!==null&&w.tag===6?(n(x,w.sibling),w=r(w,b),w.return=x,x=w):(n(x,w),w=tu(b,x.mode,N),w.return=x,x=w),u(x)):n(x,w)}return O}var W6=jv(!0),Dv=jv(!1),w9={},O2=an(w9),G7=an(w9),q7=an(w9);function qn(e){if(e===w9)throw Error(A1(174));return e}function Xc(e,t){switch(Ie(q7,t),Ie(G7,e),Ie(O2,w9),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Wu(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Wu(t,e)}Be(O2),Ie(O2,t)}function H6(){Be(O2),Be(G7),Be(q7)}function Qv(e){qn(q7.current);var t=qn(O2.current),n=Wu(t,e.type);t!==n&&(Ie(G7,e),Ie(O2,n))}function Kc(e){G7.current===e&&(Be(O2),Be(G7))}var Ze=an(0);function er(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Va=[];function Jc(){for(var e=0;en?n:4,e(!0);var i=Ya.transition;Ya.transition={};try{e(!1),t()}finally{Te=n,Ya.transition=i}}function ow(){return W4().memoizedState}function jO(e,t,n){var i=K3(e);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},sw(e))aw(t,n);else if(n=Uv(e,t,n,i),n!==null){var r=Zt();f2(n,e,i,r),uw(n,t,i)}}function DO(e,t,n){var i=K3(e),r={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(sw(e))aw(t,r);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var u=t.lastRenderedState,f=s(u,n);if(r.hasEagerState=!0,r.eagerState=f,d2(f,u)){var d=t.interleaved;d===null?(r.next=r,Vc(t)):(r.next=d.next,d.next=r),t.interleaved=r;return}}catch{}finally{}n=Uv(e,t,r,i),n!==null&&(r=Zt(),f2(n,e,i,r),uw(n,t,i))}}function sw(e){var t=e.alternate;return e===Ge||t!==null&&t===Ge}function aw(e,t){k7=tr=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function uw(e,t,n){if(n&4194240){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Ic(e,n)}}var nr={readContext:Q4,useCallback:kt,useContext:kt,useEffect:kt,useImperativeHandle:kt,useInsertionEffect:kt,useLayoutEffect:kt,useMemo:kt,useReducer:kt,useRef:kt,useState:kt,useDebugValue:kt,useDeferredValue:kt,useTransition:kt,useMutableSource:kt,useSyncExternalStore:kt,useId:kt,unstable_isNewReconciler:!1},QO={readContext:Q4,useCallback:function(e,t){return k2().memoizedState=[e,t===void 0?null:t],e},useContext:Q4,useEffect:lg,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,E8(4194308,4,ew.bind(null,t,e),n)},useLayoutEffect:function(e,t){return E8(4194308,4,e,t)},useInsertionEffect:function(e,t){return E8(4,2,e,t)},useMemo:function(e,t){var n=k2();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var i=k2();return t=n!==void 0?n(t):t,i.memoizedState=i.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},i.queue=e,e=e.dispatch=jO.bind(null,Ge,e),[i.memoizedState,e]},useRef:function(e){var t=k2();return e={current:e},t.memoizedState=e},useState:ug,useDebugValue:of,useDeferredValue:function(e){return k2().memoizedState=e},useTransition:function(){var e=ug(!1),t=e[0];return e=zO.bind(null,e[1]),k2().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var i=Ge,r=k2();if(De){if(n===void 0)throw Error(A1(407));n=n()}else{if(n=t(),dt===null)throw Error(A1(349));l5&30||Zv(i,t,n)}r.memoizedState=n;var s={value:n,getSnapshot:t};return r.queue=s,lg(qv.bind(null,i,s,e),[e]),i.flags|=2048,X7(9,Gv.bind(null,i,s,n,t),void 0,null),n},useId:function(){var e=k2(),t=dt.identifierPrefix;if(De){var n=u3,i=a3;n=(i&~(1<<32-c2(i)-1)).toString(32)+n,t=":"+t+"R"+n,n=V7++,0<\/script>",e=e.removeChild(e.firstChild)):typeof i.is=="string"?e=u.createElement(n,{is:i.is}):(e=u.createElement(n),n==="select"&&(u=e,i.multiple?u.multiple=!0:i.size&&(u.size=i.size))):e=u.createElementNS(e,n),e[P2]=t,e[Z7]=i,yw(e,t,!1,!1),t.stateNode=e;e:{switch(u=Zu(n,i),n){case"dialog":Ue("cancel",e),Ue("close",e),r=i;break;case"iframe":case"object":case"embed":Ue("load",e),r=i;break;case"video":case"audio":for(r=0;r<_7.length;r++)Ue(_7[r],e);r=i;break;case"source":Ue("error",e),r=i;break;case"img":case"image":case"link":Ue("error",e),Ue("load",e),r=i;break;case"details":Ue("toggle",e),r=i;break;case"input":Ap(e,i),r=zu(e,i),Ue("invalid",e);break;case"option":r=i;break;case"select":e._wrapperState={wasMultiple:!!i.multiple},r=qe({},i,{value:void 0}),Ue("invalid",e);break;case"textarea":Tp(e,i),r=Qu(e,i),Ue("invalid",e);break;default:r=i}Hu(n,r),f=r;for(s in f)if(f.hasOwnProperty(s)){var d=f[s];s==="style"?V_(e,d):s==="dangerouslySetInnerHTML"?(d=d?d.__html:void 0,d!=null&&G_(e,d)):s==="children"?typeof d=="string"?(n!=="textarea"||d!=="")&&U7(e,d):typeof d=="number"&&U7(e,""+d):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(R7.hasOwnProperty(s)?d!=null&&s==="onScroll"&&Ue("scroll",e):d!=null&&Pc(e,s,d,u))}switch(n){case"input":Ii(e),kp(e,i,!1);break;case"textarea":Ii(e),Pp(e);break;case"option":i.value!=null&&e.setAttribute("value",""+tn(i.value));break;case"select":e.multiple=!!i.multiple,s=i.value,s!=null?C6(e,!!i.multiple,s,!1):i.defaultValue!=null&&C6(e,!!i.multiple,i.defaultValue,!0);break;default:typeof r.onClick=="function"&&(e.onclick=Z8)}switch(n){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}}i&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Tt(t),null;case 6:if(e&&t.stateNode!=null)vw(e,t,e.memoizedProps,i);else{if(typeof i!="string"&&t.stateNode===null)throw Error(A1(166));if(n=qn(q7.current),qn(O2.current),Wi(t)){if(i=t.stateNode,n=t.memoizedProps,i[P2]=t,(s=i.nodeValue!==n)&&(e=v4,e!==null))switch(e.tag){case 3:Qi(i.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Qi(i.nodeValue,n,(e.mode&1)!==0)}s&&(t.flags|=4)}else i=(n.nodeType===9?n:n.ownerDocument).createTextNode(i),i[P2]=t,t.stateNode=i}return Tt(t),null;case 13:if(Be(Ze),i=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(De&&y4!==null&&t.mode&1&&!(t.flags&128))Rv(),Q6(),t.flags|=98560,s=!1;else if(s=Wi(t),i!==null&&i.dehydrated!==null){if(e===null){if(!s)throw Error(A1(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(A1(317));s[P2]=t}else Q6(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Tt(t),s=!1}else o2!==null&&(Al(o2),o2=null),s=!0;if(!s)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(i=i!==null,i!==(e!==null&&e.memoizedState!==null)&&i&&(t.child.flags|=8192,t.mode&1&&(e===null||Ze.current&1?at===0&&(at=3):df())),t.updateQueue!==null&&(t.flags|=4),Tt(t),null);case 4:return H6(),_l(e,t),e===null&&W7(t.stateNode.containerInfo),Tt(t),null;case 10:return qc(t.type._context),Tt(t),null;case 17:return s4(t.type)&&G8(),Tt(t),null;case 19:if(Be(Ze),s=t.memoizedState,s===null)return Tt(t),null;if(i=(t.flags&128)!==0,u=s.rendering,u===null)if(i)r7(s,!1);else{if(at!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(u=er(e),u!==null){for(t.flags|=128,r7(s,!1),i=u.updateQueue,i!==null&&(t.updateQueue=i,t.flags|=4),t.subtreeFlags=0,i=n,n=t.child;n!==null;)s=n,e=i,s.flags&=14680066,u=s.alternate,u===null?(s.childLanes=0,s.lanes=e,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=u.childLanes,s.lanes=u.lanes,s.child=u.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=u.memoizedProps,s.memoizedState=u.memoizedState,s.updateQueue=u.updateQueue,s.type=u.type,e=u.dependencies,s.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Ie(Ze,Ze.current&1|2),t.child}e=e.sibling}s.tail!==null&&tt()>G6&&(t.flags|=128,i=!0,r7(s,!1),t.lanes=4194304)}else{if(!i)if(e=er(u),e!==null){if(t.flags|=128,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),r7(s,!0),s.tail===null&&s.tailMode==="hidden"&&!u.alternate&&!De)return Tt(t),null}else 2*tt()-s.renderingStartTime>G6&&n!==1073741824&&(t.flags|=128,i=!0,r7(s,!1),t.lanes=4194304);s.isBackwards?(u.sibling=t.child,t.child=u):(n=s.last,n!==null?n.sibling=u:t.child=u,s.last=u)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=tt(),t.sibling=null,n=Ze.current,Ie(Ze,i?n&1|2:n&1),t):(Tt(t),null);case 22:case 23:return ff(),i=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(t.flags|=8192),i&&t.mode&1?m4&1073741824&&(Tt(t),t.subtreeFlags&6&&(t.flags|=8192)):Tt(t),null;case 24:return null;case 25:return null}throw Error(A1(156,t.tag))}function XO(e,t){switch(Wc(t),t.tag){case 1:return s4(t.type)&&G8(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return H6(),Be(o4),Be(Ot),Jc(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Kc(t),null;case 13:if(Be(Ze),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(A1(340));Q6()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Be(Ze),null;case 4:return H6(),null;case 10:return qc(t.type._context),null;case 22:case 23:return ff(),null;case 24:return null;default:return null}}var Gi=!1,Ct=!1,KO=typeof WeakSet=="function"?WeakSet:Set,F1=null;function S6(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Xe(e,t,i)}else n.current=null}function vl(e,t,n){try{n()}catch(i){Xe(e,t,i)}}var _g=!1;function JO(e,t){if(nl=Q8,e=Sv(),Dc(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var r=i.anchorOffset,s=i.focusNode;i=i.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var u=0,f=-1,d=-1,p=0,m=0,h=e,_=null;t:for(;;){for(var S;h!==n||r!==0&&h.nodeType!==3||(f=u+r),h!==s||i!==0&&h.nodeType!==3||(d=u+i),h.nodeType===3&&(u+=h.nodeValue.length),(S=h.firstChild)!==null;)_=h,h=S;for(;;){if(h===e)break t;if(_===n&&++p===r&&(f=u),_===s&&++m===i&&(d=u),(S=h.nextSibling)!==null)break;h=_,_=h.parentNode}h=S}n=f===-1||d===-1?null:{start:f,end:d}}else n=null}n=n||{start:0,end:0}}else n=null;for(il={focusedElem:e,selectionRange:n},Q8=!1,F1=t;F1!==null;)if(t=F1,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,F1=e;else for(;F1!==null;){t=F1;try{var E=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(E!==null){var k=E.memoizedProps,O=E.memoizedState,x=t.stateNode,w=x.getSnapshotBeforeUpdate(t.elementType===t.type?k:i2(t.type,k),O);x.__reactInternalSnapshotBeforeUpdate=w}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(A1(163))}}catch(N){Xe(t,t.return,N)}if(e=t.sibling,e!==null){e.return=t.return,F1=e;break}F1=t.return}return E=_g,_g=!1,E}function T7(e,t,n){var i=t.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var r=i=i.next;do{if((r.tag&e)===e){var s=r.destroy;r.destroy=void 0,s!==void 0&&vl(t,n,s)}r=r.next}while(r!==i)}}function qr(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 i=n.create;n.destroy=i()}n=n.next}while(n!==t)}}function wl(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 ww(e){var t=e.alternate;t!==null&&(e.alternate=null,ww(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[P2],delete t[Z7],delete t[sl],delete t[IO],delete t[RO])),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 xw(e){return e.tag===5||e.tag===3||e.tag===4}function vg(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||xw(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 xl(e,t,n){var i=e.tag;if(i===5||i===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=Z8));else if(i!==4&&(e=e.child,e!==null))for(xl(e,t,n),e=e.sibling;e!==null;)xl(e,t,n),e=e.sibling}function bl(e,t,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(i!==4&&(e=e.child,e!==null))for(bl(e,t,n),e=e.sibling;e!==null;)bl(e,t,n),e=e.sibling}var vt=null,r2=!1;function R3(e,t,n){for(n=n.child;n!==null;)bw(e,t,n),n=n.sibling}function bw(e,t,n){if(N2&&typeof N2.onCommitFiberUnmount=="function")try{N2.onCommitFiberUnmount(zr,n)}catch{}switch(n.tag){case 5:Ct||S6(n,t);case 6:var i=vt,r=r2;vt=null,R3(e,t,n),vt=i,r2=r,vt!==null&&(r2?(e=vt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):vt.removeChild(n.stateNode));break;case 18:vt!==null&&(r2?(e=vt,n=n.stateNode,e.nodeType===8?Ga(e.parentNode,n):e.nodeType===1&&Ga(e,n),j7(e)):Ga(vt,n.stateNode));break;case 4:i=vt,r=r2,vt=n.stateNode.containerInfo,r2=!0,R3(e,t,n),vt=i,r2=r;break;case 0:case 11:case 14:case 15:if(!Ct&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){r=i=i.next;do{var s=r,u=s.destroy;s=s.tag,u!==void 0&&(s&2||s&4)&&vl(n,t,u),r=r.next}while(r!==i)}R3(e,t,n);break;case 1:if(!Ct&&(S6(n,t),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(f){Xe(n,t,f)}R3(e,t,n);break;case 21:R3(e,t,n);break;case 22:n.mode&1?(Ct=(i=Ct)||n.memoizedState!==null,R3(e,t,n),Ct=i):R3(e,t,n);break;default:R3(e,t,n)}}function wg(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new KO),t.forEach(function(i){var r=uL.bind(null,e,i);n.has(i)||(n.add(i),i.then(r,r))})}}function n2(e,t){var n=t.deletions;if(n!==null)for(var i=0;ir&&(r=u),i&=~s}if(i=r,i=tt()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*tL(i/1960))-i,10e?16:e,Q3===null)var i=!1;else{if(e=Q3,Q3=null,or=0,Ee&6)throw Error(A1(331));var r=Ee;for(Ee|=4,F1=e.current;F1!==null;){var s=F1,u=s.child;if(F1.flags&16){var f=s.deletions;if(f!==null){for(var d=0;dtt()-lf?t5(e,0):uf|=n),a4(e,t)}function Cw(e,t){t===0&&(e.mode&1?(t=$i,$i<<=1,!($i&130023424)&&($i=4194304)):t=1);var n=Zt();e=p3(e,t),e!==null&&(y9(e,t,n),a4(e,n))}function aL(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Cw(e,n)}function uL(e,t){var n=0;switch(e.tag){case 13:var i=e.stateNode,r=e.memoizedState;r!==null&&(n=r.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(A1(314))}i!==null&&i.delete(t),Cw(e,n)}var Nw;Nw=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||o4.current)i4=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return i4=!1,VO(e,t,n);i4=!!(e.flags&131072)}else i4=!1,De&&t.flags&1048576&&Fv(t,Y8,t.index);switch(t.lanes=0,t.tag){case 2:var i=t.type;M8(e,t),e=t.pendingProps;var r=D6(t,Ot.current);F6(t,n),r=tf(null,t,i,e,r,n);var s=nf();return t.flags|=1,typeof r=="object"&&r!==null&&typeof r.render=="function"&&r.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,s4(i)?(s=!0,q8(t)):s=!1,t.memoizedState=r.state!==null&&r.state!==void 0?r.state:null,Yc(t),r.updater=Zr,t.stateNode=r,r._reactInternals=t,dl(t,i,e,n),t=gl(null,t,i,!0,s,n)):(t.tag=0,De&&s&&Qc(t),Qt(null,t,r,n),t=t.child),t;case 16:i=t.elementType;e:{switch(M8(e,t),e=t.pendingProps,r=i._init,i=r(i._payload),t.type=i,r=t.tag=cL(i),e=i2(i,e),r){case 0:t=pl(null,t,i,e,n);break e;case 1:t=gg(null,t,i,e,n);break e;case 11:t=hg(null,t,i,e,n);break e;case 14:t=pg(null,t,i,i2(i.type,e),n);break e}throw Error(A1(306,i,""))}return t;case 0:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:i2(i,r),pl(e,t,i,r,n);case 1:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:i2(i,r),gg(e,t,i,r,n);case 3:e:{if(pw(t),e===null)throw Error(A1(387));i=t.pendingProps,s=t.memoizedState,r=s.element,$v(e,t),J8(t,i,null,n);var u=t.memoizedState;if(i=u.element,s.isDehydrated)if(s={element:i,isDehydrated:!1,cache:u.cache,pendingSuspenseBoundaries:u.pendingSuspenseBoundaries,transitions:u.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){r=Z6(Error(A1(423)),t),t=mg(e,t,i,n,r);break e}else if(i!==r){r=Z6(Error(A1(424)),t),t=mg(e,t,i,n,r);break e}else for(y4=V3(t.stateNode.containerInfo.firstChild),v4=t,De=!0,o2=null,n=Dv(t,null,i,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Q6(),i===r){t=g3(e,t,n);break e}Qt(e,t,i,n)}t=t.child}return t;case 5:return Qv(t),e===null&&ll(t),i=t.type,r=t.pendingProps,s=e!==null?e.memoizedProps:null,u=r.children,rl(i,r)?u=null:s!==null&&rl(i,s)&&(t.flags|=32),hw(e,t),Qt(e,t,u,n),t.child;case 6:return e===null&&ll(t),null;case 13:return gw(e,t,n);case 4:return Xc(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=W6(t,null,i,n):Qt(e,t,i,n),t.child;case 11:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:i2(i,r),hg(e,t,i,r,n);case 7:return Qt(e,t,t.pendingProps,n),t.child;case 8:return Qt(e,t,t.pendingProps.children,n),t.child;case 12:return Qt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(i=t.type._context,r=t.pendingProps,s=t.memoizedProps,u=r.value,Ie(X8,i._currentValue),i._currentValue=u,s!==null)if(d2(s.value,u)){if(s.children===r.children&&!o4.current){t=g3(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var f=s.dependencies;if(f!==null){u=s.child;for(var d=f.firstContext;d!==null;){if(d.context===i){if(s.tag===1){d=f3(-1,n&-n),d.tag=2;var p=s.updateQueue;if(p!==null){p=p.shared;var m=p.pending;m===null?d.next=d:(d.next=m.next,m.next=d),p.pending=d}}s.lanes|=n,d=s.alternate,d!==null&&(d.lanes|=n),cl(s.return,n,t),f.lanes|=n;break}d=d.next}}else if(s.tag===10)u=s.type===t.type?null:s.child;else if(s.tag===18){if(u=s.return,u===null)throw Error(A1(341));u.lanes|=n,f=u.alternate,f!==null&&(f.lanes|=n),cl(u,n,t),u=s.sibling}else u=s.child;if(u!==null)u.return=s;else for(u=s;u!==null;){if(u===t){u=null;break}if(s=u.sibling,s!==null){s.return=u.return,u=s;break}u=u.return}s=u}Qt(e,t,r.children,n),t=t.child}return t;case 9:return r=t.type,i=t.pendingProps.children,F6(t,n),r=Q4(r),i=i(r),t.flags|=1,Qt(e,t,i,n),t.child;case 14:return i=t.type,r=i2(i,t.pendingProps),r=i2(i.type,r),pg(e,t,i,r,n);case 15:return fw(e,t,t.type,t.pendingProps,n);case 17:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:i2(i,r),M8(e,t),t.tag=1,s4(i)?(e=!0,q8(t)):e=!1,F6(t,n),zv(t,i,r),dl(t,i,r,n),gl(null,t,i,!0,e,n);case 19:return mw(e,t,n);case 22:return dw(e,t,n)}throw Error(A1(156,t.tag))};function Ow(e,t){return rv(e,t)}function lL(e,t,n,i){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=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function B4(e,t,n,i){return new lL(e,t,n,i)}function hf(e){return e=e.prototype,!(!e||!e.isReactComponent)}function cL(e){if(typeof e=="function")return hf(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Nc)return 11;if(e===Oc)return 14}return 2}function J3(e,t){var n=e.alternate;return n===null?(n=B4(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 T8(e,t,n,i,r,s){var u=2;if(i=e,typeof e=="function")hf(e)&&(u=1);else if(typeof e=="string")u=5;else e:switch(e){case p6:return n5(n.children,r,s,t);case Cc:u=8,r|=8;break;case Ru:return e=B4(12,n,t,r|2),e.elementType=Ru,e.lanes=s,e;case Uu:return e=B4(13,n,t,r),e.elementType=Uu,e.lanes=s,e;case $u:return e=B4(19,n,t,r),e.elementType=$u,e.lanes=s,e;case j_:return Yr(n,r,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case B_:u=10;break e;case z_:u=9;break e;case Nc:u=11;break e;case Oc:u=14;break e;case $3:u=16,i=null;break e}throw Error(A1(130,e==null?e:typeof e,""))}return t=B4(u,n,t,r),t.elementType=e,t.type=i,t.lanes=s,t}function n5(e,t,n,i){return e=B4(7,e,i,t),e.lanes=n,e}function Yr(e,t,n,i){return e=B4(22,e,i,t),e.elementType=j_,e.lanes=n,e.stateNode={isHidden:!1},e}function tu(e,t,n){return e=B4(6,e,null,t),e.lanes=n,e}function nu(e,t,n){return t=B4(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function fL(e,t,n,i,r){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=Ra(0),this.expirationTimes=Ra(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ra(0),this.identifierPrefix=i,this.onRecoverableError=r,this.mutableSourceEagerHydrationData=null}function pf(e,t,n,i,r,s,u,f,d){return e=new fL(e,t,n,f,d),t===1?(t=1,s===!0&&(t|=8)):t=0,s=B4(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Yc(s),e}function dL(e,t,n){var i=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Rw)}catch(e){console.error(e)}}Rw(),F_.exports=x4;var _f=F_.exports,Uw,Tg=_f;Uw=Tg.createRoot,Tg.hydrateRoot;const $w={years:31536e6,months:2592e6,days:864e5,hours:36e5,minutes:6e4,seconds:1e3};function yL(e,t="floor"){var n,i,r=Date.now()-+e;for([n,i]of Object.entries($w)){var s=n,u=Math[t](r/i);if(1<=u)return[u,s]}return[0,"seconds"]}const vf=G.memo(({date:e,locale:t=navigator.language,formatOptions:n,hideSeconds:i,roundStrategy:r})=>{const[s,u]=G.useState(""),[f,d]=G.useState(),p=G.useMemo(()=>new Intl.RelativeTimeFormat(t,{localeMatcher:"best fit",numeric:"always",style:"long",...n}),[t,n]),m=G.useCallback(()=>{var[h,_]=yL(e instanceof Date?e:new Date(e),r);u(_==="seconds"&&i?p.format(-1,"minute"):p.format(-h,_)),d(_)},[e,p,i,r]);return G.useEffect(m,[m]),G.useEffect(()=>{if(f){var h=$w[f];const _=setInterval(m,h);return()=>clearInterval(_)}},[f,m]),s});vf.displayName="TimeAgo";const Bw={PERFECT:[1,"Data is already perfect","No action required","#76d9a1"],EXISTS_BUT_WRONG_DATA:[2,"Address exists but the data is wrong","Select a suburb in the tool","#fada5e","data-wrong.txt"],EXISTS_BUT_NO_LINZ_REF:[3,"Address exists but no linz ref","Select a suburb in the tool","#fada5e","needs-linz-ref.txt"],MULTIPLE_EXIST_BUT_NO_LINZ_REF:[4,"Multiple addresses exists, none have linz ref","manual action required","#fada5e","needs-linz-ref-but-multiple.txt"],MULTIPLE_EXIST:[5,"Multiple addresses exists with same linz ref","manual action required","#ff7272","duplicate-linz-ref.txt"],EXISTS_BUT_LOCATION_WRONG:[6,"Addresses exist but location is very wrong",'Select the suburb called "ZZ Special Location Wrong".',"#fada5e","location-wrong.txt"],TOTALLY_MISSING:[7,"Addresses totally missing from OSM","Select a suburb in the tool","#fada5e"],NEEDS_DELETE:[8,"Addresses in OSM that have been deleted by LINZ","Select a suburb in the tool","#fada5e","needs-delete.txt"],NEEDS_DELETE_NON_TRIVIAL:[9,"Addresses in OSM that have been deleted by LINZ, but are on a OSM business/POI","manual action required","#ff7272","needs-delete-non-trivial.txt"],CORRUPT:[10,"There are multiple LINZ refs on the same OSM node","manual action required","#fada5e","corrupt.txt"],LINZ_REF_CHANGED:[11,"LINZ has changed their ID for an address, but not the data","Select the suburb called 'ZZ Special Linz Ref Changed'","#fada5e","linz-ref-changed.txt"],COULD_BE_STACKED:[13,"Addresses in OSM that are perfect, but the flats/units could be stacked if this is desired.","N/A. Just for statistics","#76d9a1","could-be-stacked.txt"],NEEDS_DELETE_ON_BUILDING:[14,"Addresses in OSM that have been deleted by LINZ, but are on a OSM building","Select a suburb in the tool","#fada5e","needs-delete-on-building.txt"],REPLACED_BY_BUILDING:[15,"Addresses in OSM that exist twice - once on a building and once on an imported node","Select a suburb in the tool","#fada5e","replaced-by-building.txt"]};var zw={exports:{}},_L="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",vL=_L,wL=vL;function jw(){}function Dw(){}Dw.resetWarningCache=jw;var xL=function(){function e(i,r,s,u,f,d){if(d!==wL){var p=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 p.name="Invariant Violation",p}}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:Dw,resetWarningCache:jw};return n.PropTypes=n,n};zw.exports=xL();var bL=zw.exports;const C=Lt(bL);var SL=Object.defineProperty,EL=(e,t)=>{for(var n in t)SL(e,n,{get:t[n],enumerable:!0})},h2={};EL(h2,{assign:()=>kL,colors:()=>en,createStringInterpolator:()=>Af,skipAnimation:()=>Vw,to:()=>qw,willAdvance:()=>kf});var wf=b9(),ie=e=>x9(e,wf),xf=b9();ie.write=e=>x9(e,xf);var to=b9();ie.onStart=e=>x9(e,to);var bf=b9();ie.onFrame=e=>x9(e,bf);var Sf=b9();ie.onFinish=e=>x9(e,Sf);var R6=[];ie.setTimeout=(e,t)=>{const n=ie.now()+t,i=()=>{const s=R6.findIndex(u=>u.cancel==i);~s&&R6.splice(s,1),H3-=~s?1:0},r={time:n,handler:e,cancel:i};return R6.splice(Qw(n),0,r),H3+=1,Ww(),r};var Qw=e=>~(~R6.findIndex(t=>t.time>e)||~R6.length);ie.cancel=e=>{to.delete(e),bf.delete(e),Sf.delete(e),wf.delete(e),xf.delete(e)};ie.sync=e=>{kl=!0,ie.batchedUpdates(e),kl=!1};ie.throttle=e=>{let t;function n(){try{e(...t)}finally{t=null}}function i(...r){t=r,ie.onStart(n)}return i.handler=e,i.cancel=()=>{to.delete(n),t=null},i};var Ef=typeof window<"u"?window.requestAnimationFrame:()=>{};ie.use=e=>Ef=e;ie.now=typeof performance<"u"?()=>performance.now():Date.now;ie.batchedUpdates=e=>e();ie.catch=console.error;ie.frameLoop="always";ie.advance=()=>{ie.frameLoop!=="demand"?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):Zw()};var W3=-1,H3=0,kl=!1;function x9(e,t){kl?(t.delete(e),e(0)):(t.add(e),Ww())}function Ww(){W3<0&&(W3=0,ie.frameLoop!=="demand"&&Ef(Hw))}function ML(){W3=-1}function Hw(){~W3&&(Ef(Hw),ie.batchedUpdates(Zw))}function Zw(){const e=W3;W3=ie.now();const t=Qw(W3);if(t&&(Gw(R6.splice(0,t),n=>n.handler()),H3-=t),!H3){ML();return}to.flush(),wf.flush(e?Math.min(64,W3-e):16.667),bf.flush(),xf.flush(),Sf.flush()}function b9(){let e=new Set,t=e;return{add(n){H3+=t==e&&!e.has(n)?1:0,e.add(n)},delete(n){return H3-=t==e&&e.has(n)?1:0,e.delete(n)},flush(n){t.size&&(e=new Set,H3-=t.size,Gw(t,i=>i(n)&&e.add(i)),H3+=e.size,t=e)}}}function Gw(e,t){e.forEach(n=>{try{t(n)}catch(i){ie.catch(i)}})}function Tl(){}var AL=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),M1={arr:Array.isArray,obj:e=>!!e&&e.constructor.name==="Object",fun:e=>typeof e=="function",str:e=>typeof e=="string",num:e=>typeof e=="number",und:e=>e===void 0};function o3(e,t){if(M1.arr(e)){if(!M1.arr(t)||e.length!==t.length)return!1;for(let n=0;ne.forEach(t);function I2(e,t,n){if(M1.arr(e)){for(let i=0;iM1.und(e)?[]:M1.arr(e)?e:[e];function N7(e,t){if(e.size){const n=Array.from(e);e.clear(),Y1(n,t)}}var v7=(e,...t)=>N7(e,n=>n(...t)),Mf=()=>typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),Af,qw,en=null,Vw=!1,kf=Tl,kL=e=>{e.to&&(qw=e.to),e.now&&(ie.now=e.now),e.colors!==void 0&&(en=e.colors),e.skipAnimation!=null&&(Vw=e.skipAnimation),e.createStringInterpolator&&(Af=e.createStringInterpolator),e.requestAnimationFrame&&ie.use(e.requestAnimationFrame),e.batchedUpdates&&(ie.batchedUpdates=e.batchedUpdates),e.willAdvance&&(kf=e.willAdvance),e.frameLoop&&(ie.frameLoop=e.frameLoop)},O7=new Set,$4=[],iu=[],ur=0,no={get idle(){return!O7.size&&!$4.length},start(e){ur>e.priority?(O7.add(e),ie.onStart(TL)):(Yw(e),ie(Pl))},advance:Pl,sort(e){if(ur)ie.onFrame(()=>no.sort(e));else{const t=$4.indexOf(e);~t&&($4.splice(t,1),Xw(e))}},clear(){$4=[],O7.clear()}};function TL(){O7.forEach(Yw),O7.clear(),ie(Pl)}function Yw(e){$4.includes(e)||Xw(e)}function Xw(e){$4.splice(PL($4,t=>t.priority>e.priority),0,e)}function Pl(e){const t=iu;for(let n=0;n<$4.length;n++){const i=$4[n];ur=i.priority,i.idle||(kf(i),i.advance(e),i.idle||t.push(i))}return ur=0,iu=$4,iu.length=0,$4=t,$4.length>0}function PL(e,t){const n=e.findIndex(t);return n<0?e.length:n}var CL=(e,t,n)=>Math.min(Math.max(n,e),t),NL={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},l2="[-+]?\\d*\\.?\\d+",lr=l2+"%";function io(...e){return"\\(\\s*("+e.join(")\\s*,\\s*(")+")\\s*\\)"}var OL=new RegExp("rgb"+io(l2,l2,l2)),LL=new RegExp("rgba"+io(l2,l2,l2,l2)),FL=new RegExp("hsl"+io(l2,lr,lr)),IL=new RegExp("hsla"+io(l2,lr,lr,l2)),RL=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,UL=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,$L=/^#([0-9a-fA-F]{6})$/,BL=/^#([0-9a-fA-F]{8})$/;function zL(e){let t;return typeof e=="number"?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=$L.exec(e))?parseInt(t[1]+"ff",16)>>>0:en&&en[e]!==void 0?en[e]:(t=OL.exec(e))?(o6(t[1])<<24|o6(t[2])<<16|o6(t[3])<<8|255)>>>0:(t=LL.exec(e))?(o6(t[1])<<24|o6(t[2])<<16|o6(t[3])<<8|Ng(t[4]))>>>0:(t=RL.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=BL.exec(e))?parseInt(t[1],16)>>>0:(t=UL.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=FL.exec(e))?(Pg(Cg(t[1]),Yi(t[2]),Yi(t[3]))|255)>>>0:(t=IL.exec(e))?(Pg(Cg(t[1]),Yi(t[2]),Yi(t[3]))|Ng(t[4]))>>>0:null}function ru(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Pg(e,t,n){const i=n<.5?n*(1+t):n+t-n*t,r=2*n-i,s=ru(r,i,e+1/3),u=ru(r,i,e),f=ru(r,i,e-1/3);return Math.round(s*255)<<24|Math.round(u*255)<<16|Math.round(f*255)<<8}function o6(e){const t=parseInt(e,10);return t<0?0:t>255?255:t}function Cg(e){return(parseFloat(e)%360+360)%360/360}function Ng(e){const t=parseFloat(e);return t<0?0:t>1?255:Math.round(t*255)}function Yi(e){const t=parseFloat(e);return t<0?0:t>100?1:t/100}function Og(e){let t=zL(e);if(t===null)return e;t=t||0;const n=(t&4278190080)>>>24,i=(t&16711680)>>>16,r=(t&65280)>>>8,s=(t&255)/255;return`rgba(${n}, ${i}, ${r}, ${s})`}var J7=(e,t,n)=>{if(M1.fun(e))return e;if(M1.arr(e))return J7({range:e,output:t,extrapolate:n});if(M1.str(e.output[0]))return Af(e);const i=e,r=i.output,s=i.range||[0,1],u=i.extrapolateLeft||i.extrapolate||"extend",f=i.extrapolateRight||i.extrapolate||"extend",d=i.easing||(p=>p);return p=>{const m=DL(p,s);return jL(p,s[m],s[m+1],r[m],r[m+1],d,u,f,i.map)}};function jL(e,t,n,i,r,s,u,f,d){let p=d?d(e):e;if(pn){if(f==="identity")return p;f==="clamp"&&(p=n)}return i===r?i:t===n?e<=t?i:r:(t===-1/0?p=-p:n===1/0?p=p-t:p=(p-t)/(n-t),p=s(p),i===-1/0?p=-p:r===1/0?p=p+i:p=p*(r-i)+i,p)}function DL(e,t){for(var n=1;n=e);++n);return n-1}var QL=(e,t="end")=>n=>{n=t==="end"?Math.min(n,.999):Math.max(n,.001);const i=n*e,r=t==="end"?Math.floor(i):Math.ceil(i);return CL(0,1,r/e)},cr=1.70158,Xi=cr*1.525,Lg=cr+1,Fg=2*Math.PI/3,Ig=2*Math.PI/4.5,Ki=e=>e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375,WL={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>1-(1-e)*(1-e),easeInOutQuad:e=>e<.5?2*e*e:1-Math.pow(-2*e+2,2)/2,easeInCubic:e=>e*e*e,easeOutCubic:e=>1-Math.pow(1-e,3),easeInOutCubic:e=>e<.5?4*e*e*e:1-Math.pow(-2*e+2,3)/2,easeInQuart:e=>e*e*e*e,easeOutQuart:e=>1-Math.pow(1-e,4),easeInOutQuart:e=>e<.5?8*e*e*e*e:1-Math.pow(-2*e+2,4)/2,easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>1-Math.pow(1-e,5),easeInOutQuint:e=>e<.5?16*e*e*e*e*e:1-Math.pow(-2*e+2,5)/2,easeInSine:e=>1-Math.cos(e*Math.PI/2),easeOutSine:e=>Math.sin(e*Math.PI/2),easeInOutSine:e=>-(Math.cos(Math.PI*e)-1)/2,easeInExpo:e=>e===0?0:Math.pow(2,10*e-10),easeOutExpo:e=>e===1?1:1-Math.pow(2,-10*e),easeInOutExpo:e=>e===0?0:e===1?1:e<.5?Math.pow(2,20*e-10)/2:(2-Math.pow(2,-20*e+10))/2,easeInCirc:e=>1-Math.sqrt(1-Math.pow(e,2)),easeOutCirc:e=>Math.sqrt(1-Math.pow(e-1,2)),easeInOutCirc:e=>e<.5?(1-Math.sqrt(1-Math.pow(2*e,2)))/2:(Math.sqrt(1-Math.pow(-2*e+2,2))+1)/2,easeInBack:e=>Lg*e*e*e-cr*e*e,easeOutBack:e=>1+Lg*Math.pow(e-1,3)+cr*Math.pow(e-1,2),easeInOutBack:e=>e<.5?Math.pow(2*e,2)*((Xi+1)*2*e-Xi)/2:(Math.pow(2*e-2,2)*((Xi+1)*(e*2-2)+Xi)+2)/2,easeInElastic:e=>e===0?0:e===1?1:-Math.pow(2,10*e-10)*Math.sin((e*10-10.75)*Fg),easeOutElastic:e=>e===0?0:e===1?1:Math.pow(2,-10*e)*Math.sin((e*10-.75)*Fg)+1,easeInOutElastic:e=>e===0?0:e===1?1:e<.5?-(Math.pow(2,20*e-10)*Math.sin((20*e-11.125)*Ig))/2:Math.pow(2,-20*e+10)*Math.sin((20*e-11.125)*Ig)/2+1,easeInBounce:e=>1-Ki(1-e),easeOutBounce:Ki,easeInOutBounce:e=>e<.5?(1-Ki(1-2*e))/2:(1+Ki(2*e-1))/2,steps:QL},e9=Symbol.for("FluidValue.get"),q6=Symbol.for("FluidValue.observers"),U4=e=>!!(e&&e[e9]),e4=e=>e&&e[e9]?e[e9]():e,Rg=e=>e[q6]||null;function HL(e,t){e.eventObserved?e.eventObserved(t):e(t)}function t9(e,t){const n=e[q6];n&&n.forEach(i=>{HL(i,t)})}var Kw=class{constructor(e){if(!e&&!(e=this.get))throw Error("Unknown getter");ZL(this,e)}},ZL=(e,t)=>Jw(e,e9,t);function i0(e,t){if(e[e9]){let n=e[q6];n||Jw(e,q6,n=new Set),n.has(t)||(n.add(t),e.observerAdded&&e.observerAdded(n.size,t))}return t}function n9(e,t){const n=e[q6];if(n&&n.has(t)){const i=n.size-1;i?n.delete(t):e[q6]=null,e.observerRemoved&&e.observerRemoved(i,t)}}var Jw=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),P8=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,GL=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Ug=new RegExp(`(${P8.source})(%|[a-z]+)`,"i"),qL=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,ro=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,ex=e=>{const[t,n]=VL(e);if(!t||Mf())return e;const i=window.getComputedStyle(document.documentElement).getPropertyValue(t);if(i)return i.trim();if(n&&n.startsWith("--")){const r=window.getComputedStyle(document.documentElement).getPropertyValue(n);return r||e}else{if(n&&ro.test(n))return ex(n);if(n)return n}return e},VL=e=>{const t=ro.exec(e);if(!t)return[,];const[,n,i]=t;return[n,i]},ou,YL=(e,t,n,i,r)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(i)}, ${r})`,tx=e=>{ou||(ou=en?new RegExp(`(${Object.keys(en).join("|")})(?!\\w)`,"g"):/^\b$/);const t=e.output.map(s=>e4(s).replace(ro,ex).replace(GL,Og).replace(ou,Og)),n=t.map(s=>s.match(P8).map(Number)),r=n[0].map((s,u)=>n.map(f=>{if(!(u in f))throw Error('The arity of each "output" value must be equal');return f[u]})).map(s=>J7({...e,output:s}));return s=>{var d;const u=!Ug.test(t[0])&&((d=t.find(p=>Ug.test(p)))==null?void 0:d.replace(P8,""));let f=0;return t[0].replace(P8,()=>`${r[f++](s)}${u||""}`).replace(qL,YL)}},Tf="react-spring: ",nx=e=>{const t=e;let n=!1;if(typeof t!="function")throw new TypeError(`${Tf}once requires a function parameter`);return(...i)=>{n||(t(...i),n=!0)}},XL=nx(console.warn);function KL(){XL(`${Tf}The "interpolate" function is deprecated in v9 (use "to" instead)`)}var JL=nx(console.warn);function eF(){JL(`${Tf}Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions`)}function oo(e){return M1.str(e)&&(e[0]=="#"||/\d/.test(e)||!Mf()&&ro.test(e)||e in(en||{}))}var Vn=Mf()?G.useEffect:G.useLayoutEffect,tF=()=>{const e=G.useRef(!1);return Vn(()=>(e.current=!0,()=>{e.current=!1}),[]),e};function Pf(){const e=G.useState()[1],t=tF();return()=>{t.current&&e(Math.random())}}function nF(e,t){const[n]=G.useState(()=>({inputs:t,result:e()})),i=G.useRef(),r=i.current;let s=r;return s?t&&s.inputs&&iF(t,s.inputs)||(s={inputs:t,result:e()}):s=n,G.useEffect(()=>{i.current=s,r==n&&(n.inputs=n.result=void 0)},[s]),s.result}function iF(e,t){if(e.length!==t.length)return!1;for(let n=0;nG.useEffect(e,rF),rF=[];function Cl(e){const t=G.useRef();return G.useEffect(()=>{t.current=e}),t.current}var i9=Symbol.for("Animated:node"),oF=e=>!!e&&e[i9]===e,T2=e=>e&&e[i9],Nf=(e,t)=>AL(e,i9,t),so=e=>e&&e[i9]&&e[i9].getPayload(),ix=class{constructor(){Nf(this,this)}getPayload(){return this.payload||[]}},S9=class extends ix{constructor(e){super(),this._value=e,this.done=!0,this.durationProgress=0,M1.num(this._value)&&(this.lastPosition=this._value)}static create(e){return new S9(e)}getPayload(){return[this]}getValue(){return this._value}setValue(e,t){return M1.num(e)&&(this.lastPosition=e,t&&(e=Math.round(e/t)*t,this.done&&(this.lastPosition=e))),this._value===e?!1:(this._value=e,!0)}reset(){const{done:e}=this;this.done=!1,M1.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,e&&(this.lastVelocity=null),this.v0=null)}},r9=class extends S9{constructor(e){super(0),this._string=null,this._toString=J7({output:[e,e]})}static create(e){return new r9(e)}getValue(){const e=this._string;return e??(this._string=this._toString(this._value))}setValue(e){if(M1.str(e)){if(e==this._string)return!1;this._string=e,this._value=1}else if(super.setValue(e))this._string=null;else return!1;return!0}reset(e){e&&(this._toString=J7({output:[this.getValue(),e]})),this._value=0,super.reset()}},fr={dependencies:null},ao=class extends ix{constructor(e){super(),this.source=e,this.setValue(e)}getValue(e){const t={};return I2(this.source,(n,i)=>{oF(n)?t[i]=n.getValue(e):U4(n)?t[i]=e4(n):e||(t[i]=n)}),t}setValue(e){this.source=e,this.payload=this._makePayload(e)}reset(){this.payload&&Y1(this.payload,e=>e.reset())}_makePayload(e){if(e){const t=new Set;return I2(e,this._addToPayload,t),Array.from(t)}}_addToPayload(e){fr.dependencies&&U4(e)&&fr.dependencies.add(e);const t=so(e);t&&Y1(t,n=>this.add(n))}},rx=class extends ao{constructor(e){super(e)}static create(e){return new rx(e)}getValue(){return this.source.map(e=>e.getValue())}setValue(e){const t=this.getPayload();return e.length==t.length?t.map((n,i)=>n.setValue(e[i])).some(Boolean):(super.setValue(e.map(sF)),!0)}};function sF(e){return(oo(e)?r9:S9).create(e)}function Nl(e){const t=T2(e);return t?t.constructor:M1.arr(e)?rx:oo(e)?r9:S9}var $g=(e,t)=>{const n=!M1.fun(e)||e.prototype&&e.prototype.isReactComponent;return G.forwardRef((i,r)=>{const s=G.useRef(null),u=n&&G.useCallback(E=>{s.current=lF(r,E)},[r]),[f,d]=uF(i,t),p=Pf(),m=()=>{const E=s.current;if(n&&!E)return;(E?t.applyAnimatedValues(E,f.getValue(!0)):!1)===!1&&p()},h=new aF(m,d),_=G.useRef();Vn(()=>(_.current=h,Y1(d,E=>i0(E,h)),()=>{_.current&&(Y1(_.current.deps,E=>n9(E,_.current)),ie.cancel(_.current.update))})),G.useEffect(m,[]),Cf(()=>()=>{const E=_.current;Y1(E.deps,k=>n9(k,E))});const S=t.getComponentProps(f.getValue());return G.createElement(e,{...S,ref:u})})},aF=class{constructor(e,t){this.update=e,this.deps=t}eventObserved(e){e.type=="change"&&ie.write(this.update)}};function uF(e,t){const n=new Set;return fr.dependencies=n,e.style&&(e={...e,style:t.createAnimatedStyle(e.style)}),e=new ao(e),fr.dependencies=null,[e,n]}function lF(e,t){return e&&(M1.fun(e)?e(t):e.current=t),t}var Bg=Symbol.for("AnimatedComponent"),cF=(e,{applyAnimatedValues:t=()=>!1,createAnimatedStyle:n=r=>new ao(r),getComponentProps:i=r=>r}={})=>{const r={applyAnimatedValues:t,createAnimatedStyle:n,getComponentProps:i},s=u=>{const f=zg(u)||"Anonymous";return M1.str(u)?u=s[u]||(s[u]=$g(u,r)):u=u[Bg]||(u[Bg]=$g(u,r)),u.displayName=`Animated(${f})`,u};return I2(e,(u,f)=>{M1.arr(e)&&(f=zg(u)),s[f]=s(u)}),{animated:s}},zg=e=>M1.str(e)?e:e&&M1.str(e.displayName)?e.displayName:M1.fun(e)&&e.name||null;function t4(e,...t){return M1.fun(e)?e(...t):e}var L7=(e,t)=>e===!0||!!(t&&e&&(M1.fun(e)?e(t):Wt(e).includes(t))),ox=(e,t)=>M1.obj(e)?t&&e[t]:e,sx=(e,t)=>e.default===!0?e[t]:e.default?e.default[t]:void 0,fF=e=>e,uo=(e,t=fF)=>{let n=dF;e.default&&e.default!==!0&&(e=e.default,n=Object.keys(e));const i={};for(const r of n){const s=t(e[r],r);M1.und(s)||(i[r]=s)}return i},dF=["config","onProps","onStart","onChange","onPause","onResume","onRest"],hF={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function pF(e){const t={};let n=0;if(I2(e,(i,r)=>{hF[r]||(t[r]=i,n++)}),n)return t}function Of(e){const t=pF(e);if(t){const n={to:t};return I2(e,(i,r)=>r in t||(n[r]=i)),n}return{...e}}function o9(e){return e=e4(e),M1.arr(e)?e.map(o9):oo(e)?h2.createStringInterpolator({range:[0,1],output:[e,e]})(1):e}function ax(e){for(const t in e)return!0;return!1}function Ol(e){return M1.fun(e)||M1.arr(e)&&M1.obj(e[0])}function Ll(e,t){var n;(n=e.ref)==null||n.delete(e),t==null||t.delete(e)}function ux(e,t){var n;t&&e.ref!==t&&((n=e.ref)==null||n.delete(e),t.add(e),e.ref=t)}var Lf={default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}},Fl={...Lf.default,mass:1,damping:1,easing:WL.linear,clamp:!1},gF=class{constructor(){this.velocity=0,Object.assign(this,Fl)}};function mF(e,t,n){n&&(n={...n},jg(n,t),t={...n,...t}),jg(e,t),Object.assign(e,t);for(const u in Fl)e[u]==null&&(e[u]=Fl[u]);let{frequency:i,damping:r}=e;const{mass:s}=e;return M1.und(i)||(i<.01&&(i=.01),r<0&&(r=0),e.tension=Math.pow(2*Math.PI/i,2)*s,e.friction=4*Math.PI*r*s/i),e}function jg(e,t){if(!M1.und(t.decay))e.duration=void 0;else{const n=!M1.und(t.tension)||!M1.und(t.friction);(n||!M1.und(t.frequency)||!M1.und(t.damping)||!M1.und(t.mass))&&(e.duration=void 0,e.decay=void 0),n&&(e.frequency=void 0)}}var Dg=[],yF=class{constructor(){this.changed=!1,this.values=Dg,this.toValues=null,this.fromValues=Dg,this.config=new gF,this.immediate=!1}};function lx(e,{key:t,props:n,defaultProps:i,state:r,actions:s}){return new Promise((u,f)=>{let d,p,m=L7(n.cancel??(i==null?void 0:i.cancel),t);if(m)S();else{M1.und(n.pause)||(r.paused=L7(n.pause,t));let E=i==null?void 0:i.pause;E!==!0&&(E=r.paused||L7(E,t)),d=t4(n.delay||0,t),E?(r.resumeQueue.add(_),s.pause()):(s.resume(),_())}function h(){r.resumeQueue.add(_),r.timeouts.delete(p),p.cancel(),d=p.time-ie.now()}function _(){d>0&&!h2.skipAnimation?(r.delayed=!0,p=ie.setTimeout(S,d),r.pauseQueue.add(h),r.timeouts.add(p)):S()}function S(){r.delayed&&(r.delayed=!1),r.pauseQueue.delete(h),r.timeouts.delete(p),e<=(r.cancelId||0)&&(m=!0);try{s.start({...n,callId:e,cancel:m},u)}catch(E){f(E)}}})}var Ff=(e,t)=>t.length==1?t[0]:t.some(n=>n.cancelled)?U6(e.get()):t.every(n=>n.noop)?cx(e.get()):s2(e.get(),t.every(n=>n.finished)),cx=e=>({value:e,noop:!0,finished:!0,cancelled:!1}),s2=(e,t,n=!1)=>({value:e,finished:t,cancelled:n}),U6=e=>({value:e,cancelled:!0,finished:!1});function fx(e,t,n,i){const{callId:r,parentId:s,onRest:u}=t,{asyncTo:f,promise:d}=n;return!s&&e===f&&!t.reset?d:n.promise=(async()=>{n.asyncId=r,n.asyncTo=e;const p=uo(t,(O,x)=>x==="onRest"?void 0:O);let m,h;const _=new Promise((O,x)=>(m=O,h=x)),S=O=>{const x=r<=(n.cancelId||0)&&U6(i)||r!==n.asyncId&&s2(i,!1);if(x)throw O.result=x,h(O),O},E=(O,x)=>{const w=new Qg,b=new Wg;return(async()=>{if(h2.skipAnimation)throw s9(n),b.result=s2(i,!1),h(b),b;S(w);const N=M1.obj(O)?{...O}:{...x,to:O};N.parentId=r,I2(p,(R,j)=>{M1.und(N[j])&&(N[j]=R)});const B=await i.start(N);return S(w),n.paused&&await new Promise(R=>{n.resumeQueue.add(R)}),B})()};let k;if(h2.skipAnimation)return s9(n),s2(i,!1);try{let O;M1.arr(e)?O=(async x=>{for(const w of x)await E(w)})(e):O=Promise.resolve(e(E,i.stop.bind(i))),await Promise.all([O.then(m),_]),k=s2(i.get(),!0,!1)}catch(O){if(O instanceof Qg)k=O.result;else if(O instanceof Wg)k=O.result;else throw O}finally{r==n.asyncId&&(n.asyncId=s,n.asyncTo=s?f:void 0,n.promise=s?d:void 0)}return M1.fun(u)&&ie.batchedUpdates(()=>{u(k,i,i.item)}),k})()}function s9(e,t){N7(e.timeouts,n=>n.cancel()),e.pauseQueue.clear(),e.resumeQueue.clear(),e.asyncId=e.asyncTo=e.promise=void 0,t&&(e.cancelId=t)}var Qg=class extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise.")}},Wg=class extends Error{constructor(){super("SkipAnimationSignal")}},Il=e=>e instanceof If,_F=1,If=class extends Kw{constructor(){super(...arguments),this.id=_F++,this._priority=0}get priority(){return this._priority}set priority(e){this._priority!=e&&(this._priority=e,this._onPriorityChange(e))}get(){const e=T2(this);return e&&e.getValue()}to(...e){return h2.to(this,e)}interpolate(...e){return KL(),h2.to(this,e)}toJSON(){return this.get()}observerAdded(e){e==1&&this._attach()}observerRemoved(e){e==0&&this._detach()}_attach(){}_detach(){}_onChange(e,t=!1){t9(this,{type:"change",parent:this,value:e,idle:t})}_onPriorityChange(e){this.idle||no.sort(this),t9(this,{type:"priority",parent:this,priority:e})}},d5=Symbol.for("SpringPhase"),dx=1,Rl=2,Ul=4,su=e=>(e[d5]&dx)>0,U3=e=>(e[d5]&Rl)>0,s7=e=>(e[d5]&Ul)>0,Hg=(e,t)=>t?e[d5]|=Rl|dx:e[d5]&=~Rl,Zg=(e,t)=>t?e[d5]|=Ul:e[d5]&=~Ul,vF=class extends If{constructor(e,t){if(super(),this.animation=new yF,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!M1.und(e)||!M1.und(t)){const n=M1.obj(e)?{...e}:{...t,from:e};M1.und(n.default)&&(n.default=!0),this.start(n)}}get idle(){return!(U3(this)||this._state.asyncTo)||s7(this)}get goal(){return e4(this.animation.to)}get velocity(){const e=T2(this);return e instanceof S9?e.lastVelocity||0:e.getPayload().map(t=>t.lastVelocity||0)}get hasAnimated(){return su(this)}get isAnimating(){return U3(this)}get isPaused(){return s7(this)}get isDelayed(){return this._state.delayed}advance(e){let t=!0,n=!1;const i=this.animation;let{toValues:r}=i;const{config:s}=i,u=so(i.to);!u&&U4(i.to)&&(r=Wt(e4(i.to))),i.values.forEach((p,m)=>{if(p.done)return;const h=p.constructor==r9?1:u?u[m].lastPosition:r[m];let _=i.immediate,S=h;if(!_){if(S=p.lastPosition,s.tension<=0){p.done=!0;return}let E=p.elapsedTime+=e;const k=i.fromValues[m],O=p.v0!=null?p.v0:p.v0=M1.arr(s.velocity)?s.velocity[m]:s.velocity;let x;const w=s.precision||(k==h?.005:Math.min(1,Math.abs(h-k)*.001));if(M1.und(s.duration))if(s.decay){const b=s.decay===!0?.998:s.decay,N=Math.exp(-(1-b)*E);S=k+O/(1-b)*(1-N),_=Math.abs(p.lastPosition-S)<=w,x=O*N}else{x=p.lastVelocity==null?O:p.lastVelocity;const b=s.restVelocity||w/10,N=s.clamp?0:s.bounce,B=!M1.und(N),R=k==h?p.v0>0:kb,!(!j&&(_=Math.abs(h-S)<=w,_)));++Q){B&&($=S==h||S>h==R,$&&(x=-x*N,S=h));const e1=-s.tension*1e-6*(S-h),X=-s.friction*.001*x,o1=(e1+X)/s.mass;x=x+o1*K,S=S+x*K}}else{let b=1;s.duration>0&&(this._memoizedDuration!==s.duration&&(this._memoizedDuration=s.duration,p.durationProgress>0&&(p.elapsedTime=s.duration*p.durationProgress,E=p.elapsedTime+=e)),b=(s.progress||0)+E/this._memoizedDuration,b=b>1?1:b<0?0:b,p.durationProgress=b),S=k+s.easing(b)*(h-k),x=(S-p.lastPosition)/e,_=b==1}p.lastVelocity=x,Number.isNaN(S)&&(console.warn("Got NaN while animating:",this),_=!0)}u&&!u[m].done&&(_=!1),_?p.done=!0:t=!1,p.setValue(S,s.round)&&(n=!0)});const f=T2(this),d=f.getValue();if(t){const p=e4(i.to);(d!==p||n)&&!s.decay?(f.setValue(p),this._onChange(p)):n&&s.decay&&this._onChange(d),this._stop()}else n&&this._onChange(d)}set(e){return ie.batchedUpdates(()=>{this._stop(),this._focus(e),this._set(e)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(U3(this)){const{to:e,config:t}=this.animation;ie.batchedUpdates(()=>{this._onStart(),t.decay||this._set(e,!1),this._stop()})}return this}update(e){return(this.queue||(this.queue=[])).push(e),this}start(e,t){let n;return M1.und(e)?(n=this.queue||[],this.queue=[]):n=[M1.obj(e)?e:{...t,to:e}],Promise.all(n.map(i=>this._update(i))).then(i=>Ff(this,i))}stop(e){const{to:t}=this.animation;return this._focus(this.get()),s9(this._state,e&&this._lastCallId),ie.batchedUpdates(()=>this._stop(t,e)),this}reset(){this._update({reset:!0})}eventObserved(e){e.type=="change"?this._start():e.type=="priority"&&(this.priority=e.priority+1)}_prepareNode(e){const t=this.key||"";let{to:n,from:i}=e;n=M1.obj(n)?n[t]:n,(n==null||Ol(n))&&(n=void 0),i=M1.obj(i)?i[t]:i,i==null&&(i=void 0);const r={to:n,from:i};return su(this)||(e.reverse&&([n,i]=[i,n]),i=e4(i),M1.und(i)?T2(this)||this._set(n):this._set(i)),r}_update({...e},t){const{key:n,defaultProps:i}=this;e.default&&Object.assign(i,uo(e,(u,f)=>/^on/.test(f)?ox(u,n):u)),qg(this,e,"onProps"),u7(this,"onProps",e,this);const r=this._prepareNode(e);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");const s=this._state;return lx(++this._lastCallId,{key:n,props:e,defaultProps:i,state:s,actions:{pause:()=>{s7(this)||(Zg(this,!0),v7(s.pauseQueue),u7(this,"onPause",s2(this,a7(this,this.animation.to)),this))},resume:()=>{s7(this)&&(Zg(this,!1),U3(this)&&this._resume(),v7(s.resumeQueue),u7(this,"onResume",s2(this,a7(this,this.animation.to)),this))},start:this._merge.bind(this,r)}}).then(u=>{if(e.loop&&u.finished&&!(t&&u.noop)){const f=hx(e);if(f)return this._update(f,!0)}return u})}_merge(e,t,n){if(t.cancel)return this.stop(!0),n(U6(this));const i=!M1.und(e.to),r=!M1.und(e.from);if(i||r)if(t.callId>this._lastToId)this._lastToId=t.callId;else return n(U6(this));const{key:s,defaultProps:u,animation:f}=this,{to:d,from:p}=f;let{to:m=d,from:h=p}=e;r&&!i&&(!t.default||M1.und(m))&&(m=h),t.reverse&&([m,h]=[h,m]);const _=!o3(h,p);_&&(f.from=h),h=e4(h);const S=!o3(m,d);S&&this._focus(m);const E=Ol(t.to),{config:k}=f,{decay:O,velocity:x}=k;(i||r)&&(k.velocity=0),t.config&&!E&&mF(k,t4(t.config,s),t.config!==u.config?t4(u.config,s):void 0);let w=T2(this);if(!w||M1.und(m))return n(s2(this,!0));const b=M1.und(t.reset)?r&&!t.default:!M1.und(h)&&L7(t.reset,s),N=b?h:this.get(),B=o9(m),R=M1.num(B)||M1.arr(B)||oo(B),j=!E&&(!R||L7(u.immediate||t.immediate,s));if(S){const Q=Nl(m);if(Q!==w.constructor)if(j)w=this._set(B);else throw Error(`Cannot animate between ${w.constructor.name} and ${Q.name}, as the "to" prop suggests`)}const $=w.constructor;let K=U4(m),H=!1;if(!K){const Q=b||!su(this)&&_;(S||Q)&&(H=o3(o9(N),B),K=!H),(!o3(f.immediate,j)&&!j||!o3(k.decay,O)||!o3(k.velocity,x))&&(K=!0)}if(H&&U3(this)&&(f.changed&&!b?K=!0:K||this._stop(d)),!E&&((K||U4(d))&&(f.values=w.getPayload(),f.toValues=U4(m)?null:$==r9?[1]:Wt(B)),f.immediate!=j&&(f.immediate=j,!j&&!b&&this._set(d)),K)){const{onRest:Q}=f;Y1(xF,X=>qg(this,t,X));const e1=s2(this,a7(this,d));v7(this._pendingCalls,e1),this._pendingCalls.add(n),f.changed&&ie.batchedUpdates(()=>{var X;f.changed=!b,Q==null||Q(e1,this),b?t4(u.onRest,e1):(X=f.onStart)==null||X.call(f,e1,this)})}b&&this._set(N),E?n(fx(t.to,t,this._state,this)):K?this._start():U3(this)&&!S?this._pendingCalls.add(n):n(cx(N))}_focus(e){const t=this.animation;e!==t.to&&(Rg(this)&&this._detach(),t.to=e,Rg(this)&&this._attach())}_attach(){let e=0;const{to:t}=this.animation;U4(t)&&(i0(t,this),Il(t)&&(e=t.priority+1)),this.priority=e}_detach(){const{to:e}=this.animation;U4(e)&&n9(e,this)}_set(e,t=!0){const n=e4(e);if(!M1.und(n)){const i=T2(this);if(!i||!o3(n,i.getValue())){const r=Nl(n);!i||i.constructor!=r?Nf(this,r.create(n)):i.setValue(n),i&&ie.batchedUpdates(()=>{this._onChange(n,t)})}}return T2(this)}_onStart(){const e=this.animation;e.changed||(e.changed=!0,u7(this,"onStart",s2(this,a7(this,e.to)),this))}_onChange(e,t){t||(this._onStart(),t4(this.animation.onChange,e,this)),t4(this.defaultProps.onChange,e,this),super._onChange(e,t)}_start(){const e=this.animation;T2(this).reset(e4(e.to)),e.immediate||(e.fromValues=e.values.map(t=>t.lastPosition)),U3(this)||(Hg(this,!0),s7(this)||this._resume())}_resume(){h2.skipAnimation?this.finish():no.start(this)}_stop(e,t){if(U3(this)){Hg(this,!1);const n=this.animation;Y1(n.values,r=>{r.done=!0}),n.toValues&&(n.onChange=n.onPause=n.onResume=void 0),t9(this,{type:"idle",parent:this});const i=t?U6(this.get()):s2(this.get(),a7(this,e??n.to));v7(this._pendingCalls,i),n.changed&&(n.changed=!1,u7(this,"onRest",i,this))}}};function a7(e,t){const n=o9(t),i=o9(e.get());return o3(i,n)}function hx(e,t=e.loop,n=e.to){const i=t4(t);if(i){const r=i!==!0&&Of(i),s=(r||e).reverse,u=!r||r.reset;return a9({...e,loop:t,default:!1,pause:void 0,to:!s||Ol(n)?n:void 0,from:u?e.from:void 0,reset:u,...r})}}function a9(e){const{to:t,from:n}=e=Of(e),i=new Set;return M1.obj(t)&&Gg(t,i),M1.obj(n)&&Gg(n,i),e.keys=i.size?Array.from(i):null,e}function wF(e){const t=a9(e);return M1.und(t.default)&&(t.default=uo(t)),t}function Gg(e,t){I2(e,(n,i)=>n!=null&&t.add(i))}var xF=["onStart","onRest","onChange","onPause","onResume"];function qg(e,t,n){e.animation[n]=t[n]!==sx(t,n)?ox(t[n],e.key):void 0}function u7(e,t,...n){var i,r,s,u;(r=(i=e.animation)[t])==null||r.call(i,...n),(u=(s=e.defaultProps)[t])==null||u.call(s,...n)}var bF=["onStart","onChange","onRest"],SF=1,px=class{constructor(e,t){this.id=SF++,this.springs={},this.queue=[],this._lastAsyncId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),t&&(this._flush=t),e&&this.start({default:!0,...e})}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(e=>e.idle&&!e.isDelayed&&!e.isPaused)}get item(){return this._item}set item(e){this._item=e}get(){const e={};return this.each((t,n)=>e[n]=t.get()),e}set(e){for(const t in e){const n=e[t];M1.und(n)||this.springs[t].set(n)}}update(e){return e&&this.queue.push(a9(e)),this}start(e){let{queue:t}=this;return e?t=Wt(e).map(a9):this.queue=[],this._flush?this._flush(this,t):(vx(this,t),$l(this,t))}stop(e,t){if(e!==!!e&&(t=e),t){const n=this.springs;Y1(Wt(t),i=>n[i].stop(!!e))}else s9(this._state,this._lastAsyncId),this.each(n=>n.stop(!!e));return this}pause(e){if(M1.und(e))this.start({pause:!0});else{const t=this.springs;Y1(Wt(e),n=>t[n].pause())}return this}resume(e){if(M1.und(e))this.start({pause:!1});else{const t=this.springs;Y1(Wt(e),n=>t[n].resume())}return this}each(e){I2(this.springs,e)}_onFrame(){const{onStart:e,onChange:t,onRest:n}=this._events,i=this._active.size>0,r=this._changed.size>0;(i&&!this._started||r&&!this._started)&&(this._started=!0,N7(e,([f,d])=>{d.value=this.get(),f(d,this,this._item)}));const s=!i&&this._started,u=r||s&&n.size?this.get():null;r&&t.size&&N7(t,([f,d])=>{d.value=u,f(d,this,this._item)}),s&&(this._started=!1,N7(n,([f,d])=>{d.value=u,f(d,this,this._item)}))}eventObserved(e){if(e.type=="change")this._changed.add(e.parent),e.idle||this._active.add(e.parent);else if(e.type=="idle")this._active.delete(e.parent);else return;ie.onFrame(this._onFrame)}};function $l(e,t){return Promise.all(t.map(n=>gx(e,n))).then(n=>Ff(e,n))}async function gx(e,t,n){const{keys:i,to:r,from:s,loop:u,onRest:f,onResolve:d}=t,p=M1.obj(t.default)&&t.default;u&&(t.loop=!1),r===!1&&(t.to=null),s===!1&&(t.from=null);const m=M1.arr(r)||M1.fun(r)?r:void 0;m?(t.to=void 0,t.onRest=void 0,p&&(p.onRest=void 0)):Y1(bF,k=>{const O=t[k];if(M1.fun(O)){const x=e._events[k];t[k]=({finished:w,cancelled:b})=>{const N=x.get(O);N?(w||(N.finished=!1),b&&(N.cancelled=!0)):x.set(O,{value:null,finished:w||!1,cancelled:b||!1})},p&&(p[k]=t[k])}});const h=e._state;t.pause===!h.paused?(h.paused=t.pause,v7(t.pause?h.pauseQueue:h.resumeQueue)):h.paused&&(t.pause=!0);const _=(i||Object.keys(e.springs)).map(k=>e.springs[k].start(t)),S=t.cancel===!0||sx(t,"cancel")===!0;(m||S&&h.asyncId)&&_.push(lx(++e._lastAsyncId,{props:t,state:h,actions:{pause:Tl,resume:Tl,start(k,O){S?(s9(h,e._lastAsyncId),O(U6(e))):(k.onRest=f,O(fx(m,k,h,e)))}}})),h.paused&&await new Promise(k=>{h.resumeQueue.add(k)});const E=Ff(e,await Promise.all(_));if(u&&E.finished&&!(n&&E.noop)){const k=hx(t,u,r);if(k)return vx(e,[k]),gx(e,k,!0)}return d&&ie.batchedUpdates(()=>d(E,e,e.item)),E}function Bl(e,t){const n={...e.springs};return t&&Y1(Wt(t),i=>{M1.und(i.keys)&&(i=a9(i)),M1.obj(i.to)||(i={...i,to:void 0}),_x(n,i,r=>yx(r))}),mx(e,n),n}function mx(e,t){I2(t,(n,i)=>{e.springs[i]||(e.springs[i]=n,i0(n,e))})}function yx(e,t){const n=new vF;return n.key=e,t&&i0(n,t),n}function _x(e,t,n){t.keys&&Y1(t.keys,i=>{(e[i]||(e[i]=n(i)))._prepareNode(t)})}function vx(e,t){Y1(t,n=>{_x(e.springs,n,i=>yx(i,e))})}var E9=({children:e,...t})=>{const n=G.useContext(dr),i=t.pause||!!n.pause,r=t.immediate||!!n.immediate;t=nF(()=>({pause:i,immediate:r}),[i,r]);const{Provider:s}=dr;return G.createElement(s,{value:t},e)},dr=EF(E9,{});E9.Provider=dr.Provider;E9.Consumer=dr.Consumer;function EF(e,t){return Object.assign(e,G.createContext(t)),e.Provider._context=e,e.Consumer._context=e,e}var wx=()=>{const e=[],t=function(i){eF();const r=[];return Y1(e,(s,u)=>{if(M1.und(i))r.push(s.start());else{const f=n(i,s,u);f&&r.push(s.start(f))}}),r};t.current=e,t.add=function(i){e.includes(i)||e.push(i)},t.delete=function(i){const r=e.indexOf(i);~r&&e.splice(r,1)},t.pause=function(){return Y1(e,i=>i.pause(...arguments)),this},t.resume=function(){return Y1(e,i=>i.resume(...arguments)),this},t.set=function(i){Y1(e,(r,s)=>{const u=M1.fun(i)?i(s,r):i;u&&r.set(u)})},t.start=function(i){const r=[];return Y1(e,(s,u)=>{if(M1.und(i))r.push(s.start());else{const f=this._getProps(i,s,u);f&&r.push(s.start(f))}}),r},t.stop=function(){return Y1(e,i=>i.stop(...arguments)),this},t.update=function(i){return Y1(e,(r,s)=>r.update(this._getProps(i,r,s))),this};const n=function(i,r,s){return M1.fun(i)?i(s,r):i};return t._getProps=n,t};function MF(e,t,n){const i=M1.fun(t)&&t;i&&!n&&(n=[]);const r=G.useMemo(()=>i||arguments.length==3?wx():void 0,[]),s=G.useRef(0),u=Pf(),f=G.useMemo(()=>({ctrls:[],queue:[],flush(x,w){const b=Bl(x,w);return s.current>0&&!f.queue.length&&!Object.keys(b).some(B=>!x.springs[B])?$l(x,w):new Promise(B=>{mx(x,b),f.queue.push(()=>{B($l(x,w))}),u()})}}),[]),d=G.useRef([...f.ctrls]),p=[],m=Cl(e)||0;G.useMemo(()=>{Y1(d.current.slice(e,m),x=>{Ll(x,r),x.stop(!0)}),d.current.length=e,h(m,e)},[e]),G.useMemo(()=>{h(0,Math.min(m,e))},n);function h(x,w){for(let b=x;bBl(x,p[w])),S=G.useContext(E9),E=Cl(S),k=S!==E&&ax(S);Vn(()=>{s.current++,f.ctrls=d.current;const{queue:x}=f;x.length&&(f.queue=[],Y1(x,w=>w())),Y1(d.current,(w,b)=>{r==null||r.add(w),k&&w.start({default:S});const N=p[b];N&&(ux(w,N.ref),w.ref?w.queue.push(N):w.start(N))})}),Cf(()=>()=>{Y1(f.ctrls,x=>x.stop(!0))});const O=_.map(x=>({...x}));return r?[O,r]:O}function r0(e,t){const n=M1.fun(e),[[i],r]=MF(1,n?e:[e],n?t||[]:t);return n||arguments.length==2?[i,r]:i}function xx(e,t,n){const i=M1.fun(t)&&t,{reset:r,sort:s,trail:u=0,expires:f=!0,exitBeforeEnter:d=!1,onDestroyed:p,ref:m,config:h}=i?i():t,_=G.useMemo(()=>i||arguments.length==3?wx():void 0,[]),S=Wt(e),E=[],k=G.useRef(null),O=r?null:k.current;Vn(()=>{k.current=E}),Cf(()=>(Y1(E,o1=>{_==null||_.add(o1.ctrl),o1.ctrl.ref=_}),()=>{Y1(k.current,o1=>{o1.expired&&clearTimeout(o1.expirationId),Ll(o1.ctrl,_),o1.ctrl.stop(!0)})}));const x=kF(S,i?i():t,O),w=r&&k.current||[];Vn(()=>Y1(w,({ctrl:o1,item:n1,key:l1})=>{Ll(o1,_),t4(p,n1,l1)}));const b=[];if(O&&Y1(O,(o1,n1)=>{o1.expired?(clearTimeout(o1.expirationId),w.push(o1)):(n1=b[n1]=x.indexOf(o1.key),~n1&&(E[n1]=o1))}),Y1(S,(o1,n1)=>{E[n1]||(E[n1]={key:x[n1],item:o1,phase:"mount",ctrl:new px},E[n1].ctrl.item=o1)}),b.length){let o1=-1;const{leave:n1}=i?i():t;Y1(b,(l1,r1)=>{const Y=O[r1];~l1?(o1=E.indexOf(Y),E[o1]={...Y,item:S[l1]}):n1&&E.splice(++o1,0,Y)})}M1.fun(s)&&E.sort((o1,n1)=>s(o1.item,n1.item));let N=-u;const B=Pf(),R=uo(t),j=new Map,$=G.useRef(new Map),K=G.useRef(!1);Y1(E,(o1,n1)=>{const l1=o1.key,r1=o1.phase,Y=i?i():t;let g1,f1;const w1=t4(Y.delay||0,l1);if(r1=="mount")g1=Y.enter,f1="enter";else{const v1=x.indexOf(l1)<0;if(r1!="leave")if(v1)g1=Y.leave,f1="leave";else if(g1=Y.update)f1="update";else return;else if(!v1)g1=Y.enter,f1="enter";else return}if(g1=t4(g1,o1.item,n1),g1=M1.obj(g1)?Of(g1):{to:g1},!g1.config){const v1=h||R.config;g1.config=t4(v1,o1.item,n1,f1)}N+=u;const k1={...R,delay:w1+N,ref:m,immediate:Y.immediate,reset:!1,...g1};if(f1=="enter"&&M1.und(k1.from)){const v1=i?i():t,d1=M1.und(v1.initial)||O?v1.from:v1.initial;k1.from=t4(d1,o1.item,n1)}const{onResolve:U1}=k1;k1.onResolve=v1=>{t4(U1,v1);const d1=k.current,I1=d1.find(W1=>W1.key===l1);if(I1&&!(v1.cancelled&&I1.phase!="update")&&I1.ctrl.idle){const W1=d1.every(E1=>E1.ctrl.idle);if(I1.phase=="leave"){const E1=t4(f,I1.item);if(E1!==!1){const L1=E1===!0?0:E1;if(I1.expired=!0,!W1&&L1>0){L1<=2147483647&&(I1.expirationId=setTimeout(B,L1));return}}}W1&&d1.some(E1=>E1.expired)&&($.current.delete(I1),d&&(K.current=!0),B())}};const O1=Bl(o1.ctrl,k1);f1==="leave"&&d?$.current.set(o1,{phase:f1,springs:O1,payload:k1}):j.set(o1,{phase:f1,springs:O1,payload:k1})});const H=G.useContext(E9),Q=Cl(H),e1=H!==Q&&ax(H);Vn(()=>{e1&&Y1(E,o1=>{o1.ctrl.start({default:H})})},[H]),Y1(j,(o1,n1)=>{if($.current.size){const l1=E.findIndex(r1=>r1.key===n1.key);E.splice(l1,1)}}),Vn(()=>{Y1($.current.size?$.current:j,({phase:o1,payload:n1},l1)=>{const{ctrl:r1}=l1;l1.phase=o1,_==null||_.add(r1),e1&&o1=="enter"&&r1.start({default:H}),n1&&(ux(r1,n1.ref),(r1.ref||_)&&!K.current?r1.update(n1):(r1.start(n1),K.current&&(K.current=!1)))})},r?void 0:n);const X=o1=>G.createElement(G.Fragment,null,E.map((n1,l1)=>{const{springs:r1}=j.get(n1)||n1.ctrl,Y=o1({...r1},n1.item,n1,l1);return Y&&Y.type?G.createElement(Y.type,{...Y.props,key:M1.str(n1.key)||M1.num(n1.key)?n1.key:n1.ctrl.id,ref:Y.ref}):Y}));return _?[X,_]:X}var AF=1;function kF(e,{key:t,keys:n=t},i){if(n===null){const r=new Set;return e.map(s=>{const u=i&&i.find(f=>f.item===s&&f.phase!=="leave"&&!r.has(f));return u?(r.add(u),u.key):AF++})}return M1.und(n)?e:M1.fun(n)?e.map(n):Wt(n)}var bx=class extends If{constructor(e,t){super(),this.source=e,this.idle=!0,this._active=new Set,this.calc=J7(...t);const n=this._get(),i=Nl(n);Nf(this,i.create(n))}advance(e){const t=this._get(),n=this.get();o3(t,n)||(T2(this).setValue(t),this._onChange(t,this.idle)),!this.idle&&Vg(this._active)&&au(this)}_get(){const e=M1.arr(this.source)?this.source.map(e4):Wt(e4(this.source));return this.calc(...e)}_start(){this.idle&&!Vg(this._active)&&(this.idle=!1,Y1(so(this),e=>{e.done=!1}),h2.skipAnimation?(ie.batchedUpdates(()=>this.advance()),au(this)):no.start(this))}_attach(){let e=1;Y1(Wt(this.source),t=>{U4(t)&&i0(t,this),Il(t)&&(t.idle||this._active.add(t),e=Math.max(e,t.priority+1))}),this.priority=e,this._start()}_detach(){Y1(Wt(this.source),e=>{U4(e)&&n9(e,this)}),this._active.clear(),au(this)}eventObserved(e){e.type=="change"?e.idle?this.advance():(this._active.add(e.parent),this._start()):e.type=="idle"?this._active.delete(e.parent):e.type=="priority"&&(this.priority=Wt(this.source).reduce((t,n)=>Math.max(t,(Il(n)?n.priority:0)+1),0))}};function TF(e){return e.idle!==!1}function Vg(e){return!e.size||Array.from(e).every(TF)}function au(e){e.idle||(e.idle=!0,Y1(so(e),t=>{t.done=!0}),t9(e,{type:"idle",parent:e}))}var PF=(e,...t)=>new bx(e,t);h2.assign({createStringInterpolator:tx,to:(e,t)=>new bx(e,t)});var Sx=/^--/;function CF(e,t){return t==null||typeof t=="boolean"||t===""?"":typeof t=="number"&&t!==0&&!Sx.test(e)&&!(F7.hasOwnProperty(e)&&F7[e])?t+"px":(""+t).trim()}var Yg={};function NF(e,t){if(!e.nodeType||!e.setAttribute)return!1;const n=e.nodeName==="filter"||e.parentNode&&e.parentNode.nodeName==="filter",{style:i,children:r,scrollTop:s,scrollLeft:u,viewBox:f,...d}=t,p=Object.values(d),m=Object.keys(d).map(h=>n||e.hasAttribute(h)?h:Yg[h]||(Yg[h]=h.replace(/([A-Z])/g,_=>"-"+_.toLowerCase())));r!==void 0&&(e.textContent=r);for(const h in i)if(i.hasOwnProperty(h)){const _=CF(h,i[h]);Sx.test(h)?e.style.setProperty(h,_):e.style[h]=_}m.forEach((h,_)=>{e.setAttribute(h,p[_])}),s!==void 0&&(e.scrollTop=s),u!==void 0&&(e.scrollLeft=u),f!==void 0&&e.setAttribute("viewBox",f)}var F7={animationIterationCount:!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,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},OF=(e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1),LF=["Webkit","Ms","Moz","O"];F7=Object.keys(F7).reduce((e,t)=>(LF.forEach(n=>e[OF(n,t)]=e[t]),e),F7);var FF=/^(matrix|translate|scale|rotate|skew)/,IF=/^(translate)/,RF=/^(rotate|skew)/,uu=(e,t)=>M1.num(e)&&e!==0?e+t:e,C8=(e,t)=>M1.arr(e)?e.every(n=>C8(n,t)):M1.num(e)?e===t:parseFloat(e)===t,UF=class extends ao{constructor({x:e,y:t,z:n,...i}){const r=[],s=[];(e||t||n)&&(r.push([e||0,t||0,n||0]),s.push(u=>[`translate3d(${u.map(f=>uu(f,"px")).join(",")})`,C8(u,0)])),I2(i,(u,f)=>{if(f==="transform")r.push([u||""]),s.push(d=>[d,d===""]);else if(FF.test(f)){if(delete i[f],M1.und(u))return;const d=IF.test(f)?"px":RF.test(f)?"deg":"";r.push(Wt(u)),s.push(f==="rotate3d"?([p,m,h,_])=>[`rotate3d(${p},${m},${h},${uu(_,d)})`,C8(_,0)]:p=>[`${f}(${p.map(m=>uu(m,d)).join(",")})`,C8(p,f.startsWith("scale")?1:0)])}}),r.length&&(i.transform=new $F(r,s)),super(i)}},$F=class extends Kw{constructor(e,t){super(),this.inputs=e,this.transforms=t,this._value=null}get(){return this._value||(this._value=this._get())}_get(){let e="",t=!0;return Y1(this.inputs,(n,i)=>{const r=e4(n[0]),[s,u]=this.transforms[i](M1.arr(r)?r:n.map(e4));e+=" "+s,t=t&&u}),t?"none":e}observerAdded(e){e==1&&Y1(this.inputs,t=>Y1(t,n=>U4(n)&&i0(n,this)))}observerRemoved(e){e==0&&Y1(this.inputs,t=>Y1(t,n=>U4(n)&&n9(n,this)))}eventObserved(e){e.type=="change"&&(this._value=null),t9(this,e)}},BF=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"];h2.assign({batchedUpdates:_f.unstable_batchedUpdates,createStringInterpolator:tx,colors:NL});var zF=cF(BF,{applyAnimatedValues:NF,createAnimatedStyle:e=>new UF(e),getComponentProps:({scrollTop:e,scrollLeft:t,...n})=>n}),R2=zF.animated;function h5(){return h5=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&h.height>0,O=Math.round(n[0]),x=Math.round(n[1]);k&&(i==="top"?(O-=h.width/2,x-=h.height+14):i==="right"?(O+=14,x-=h.height/2):i==="bottom"?(O-=h.width/2,x+=14):i==="left"?(O-=h.width+14,x-=h.height/2):i==="center"&&(O-=h.width/2,x-=h.height/2),S={transform:Xg(O,x)},_.current||(E=!0),_.current=[O,x]);var w=r0({to:S,config:d,immediate:!f||E}),b=h5({},jF,s.tooltip,{transform:(t=w.transform)!=null?t:Xg(O,x)});return F.jsx(R2.div,{ref:m,style:b,children:r})});Ex.displayName="TooltipWrapper";var Mx=G.memo(function(e){var t=e.size,n=t===void 0?12:t,i=e.color,r=e.style;return F.jsx("span",{style:h5({display:"block",width:n,height:n,background:i},r===void 0?{}:r)})}),DF=G.memo(function(e){var t,n=e.id,i=e.value,r=e.format,s=e.enableChip,u=s!==void 0&&s,f=e.color,d=e.renderContent,p=Ft(),m=lc(r);if(typeof d=="function")t=d();else{var h=i;m!==void 0&&h!==void 0&&(h=m(h)),t=F.jsxs("div",{style:p.tooltip.basic,children:[u&&F.jsx(Mx,{color:f,style:p.tooltip.chip}),h!==void 0?F.jsxs("span",{children:[n,": ",F.jsx("strong",{children:""+h})]}):n]})}return F.jsx("div",{style:p.tooltip.container,children:t})}),QF={width:"100%",borderCollapse:"collapse"},Ax=G.memo(function(e){var t,n=e.title,i=e.rows,r=i===void 0?[]:i,s=e.renderContent,u=Ft();return r.length?(t=typeof s=="function"?s():F.jsxs("div",{children:[n&&n,F.jsx("table",{style:h5({},QF,u.tooltip.table),children:F.jsx("tbody",{children:r.map(function(f,d){return F.jsx("tr",{children:f.map(function(p,m){return F.jsx("td",{style:u.tooltip.tableCell,children:p},m)})},d)})})})]}),F.jsx("div",{style:u.tooltip.container,children:t})):null});Ax.displayName="TableTooltip";var zl=G.memo(function(e){var t=e.x0,n=e.x1,i=e.y0,r=e.y1,s=Ft(),u=M5(),f=u.animate,d=u.config,p=G.useMemo(function(){return h5({},s.crosshair.line,{pointerEvents:"none"})},[s.crosshair.line]),m=r0({x1:t,x2:n,y1:i,y2:r,config:d,immediate:!f});return F.jsx(R2.line,h5({},m,{fill:"none",style:p}))});zl.displayName="CrosshairLine";var jl=G.memo(function(e){var t,n,i=e.width,r=e.height,s=e.type,u=e.x,f=e.y;return s==="cross"?(t={x0:u,x1:u,y0:0,y1:r},n={x0:0,x1:i,y0:f,y1:f}):s==="top-left"?(t={x0:u,x1:u,y0:0,y1:f},n={x0:0,x1:u,y0:f,y1:f}):s==="top"?t={x0:u,x1:u,y0:0,y1:f}:s==="top-right"?(t={x0:u,x1:u,y0:0,y1:f},n={x0:u,x1:i,y0:f,y1:f}):s==="right"?n={x0:u,x1:i,y0:f,y1:f}:s==="bottom-right"?(t={x0:u,x1:u,y0:f,y1:r},n={x0:u,x1:i,y0:f,y1:f}):s==="bottom"?t={x0:u,x1:u,y0:f,y1:r}:s==="bottom-left"?(t={x0:u,x1:u,y0:f,y1:r},n={x0:0,x1:u,y0:f,y1:f}):s==="left"?n={x0:0,x1:u,y0:f,y1:f}:s==="x"?t={x0:u,x1:u,y0:0,y1:r}:s==="y"&&(n={x0:0,x1:i,y0:f,y1:f}),F.jsxs(F.Fragment,{children:[t&&F.jsx(zl,{x0:t.x0,x1:t.x1,y0:t.y0,y1:t.y1}),n&&F.jsx(zl,{x0:n.x0,x1:n.x1,y0:n.y0,y1:n.y1})]})});jl.displayName="Crosshair";var kx=G.createContext({showTooltipAt:function(){},showTooltipFromEvent:function(){},hideTooltip:function(){}}),Dl={isVisible:!1,position:[null,null],content:null,anchor:null},Tx=G.createContext(Dl),WF=function(e){var t=G.useState(Dl),n=t[0],i=t[1],r=G.useCallback(function(f,d,p){var m=d[0],h=d[1];p===void 0&&(p="top"),i({isVisible:!0,position:[m,h],anchor:p,content:f})},[i]),s=G.useCallback(function(f,d,p){p===void 0&&(p="top");var m=e.current.getBoundingClientRect(),h=e.current.offsetWidth,_=h===m.width?1:h/m.width,S=(d.clientX-m.left)*_,E=(d.clientY-m.top)*_;p!=="left"&&p!=="right"||(p=S-1}var cI=lI,fI=lo;function dI(e,t){var n=this.__data__,i=fI(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}var hI=dI,pI=YF,gI=rI,mI=aI,yI=cI,_I=hI;function o0(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1&&e%1==0&&e<=C$}var Df=N$,O$=fo,L$=Df;function F$(e){return e!=null&&L$(e.length)&&!O$(e)}var l0=F$,I$=l0,R$=ln;function U$(e){return R$(e)&&I$(e)}var Bx=U$,pr={exports:{}};function $$(){return!1}var B$=$$;pr.exports;(function(e,t){var n=$2,i=B$,r=t&&!t.nodeType&&t,s=r&&!0&&e&&!e.nodeType&&e,u=s&&s.exports===r,f=u?n.Buffer:void 0,d=f?f.isBuffer:void 0,p=d||i;e.exports=p})(pr,pr.exports);var Qf=pr.exports,z$=w5,j$=Ux,D$=ln,Q$="[object Object]",W$=Function.prototype,H$=Object.prototype,zx=W$.toString,Z$=H$.hasOwnProperty,G$=zx.call(Object);function q$(e){if(!D$(e)||z$(e)!=Q$)return!1;var t=j$(e);if(t===null)return!0;var n=Z$.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&zx.call(n)==G$}var jx=q$;const V$=Lt(jx);var Y$=w5,X$=Df,K$=ln,J$="[object Arguments]",eB="[object Array]",tB="[object Boolean]",nB="[object Date]",iB="[object Error]",rB="[object Function]",oB="[object Map]",sB="[object Number]",aB="[object Object]",uB="[object RegExp]",lB="[object Set]",cB="[object String]",fB="[object WeakMap]",dB="[object ArrayBuffer]",hB="[object DataView]",pB="[object Float32Array]",gB="[object Float64Array]",mB="[object Int8Array]",yB="[object Int16Array]",_B="[object Int32Array]",vB="[object Uint8Array]",wB="[object Uint8ClampedArray]",xB="[object Uint16Array]",bB="[object Uint32Array]",$e={};$e[pB]=$e[gB]=$e[mB]=$e[yB]=$e[_B]=$e[vB]=$e[wB]=$e[xB]=$e[bB]=!0;$e[J$]=$e[eB]=$e[dB]=$e[tB]=$e[hB]=$e[nB]=$e[iB]=$e[rB]=$e[oB]=$e[sB]=$e[aB]=$e[uB]=$e[lB]=$e[cB]=$e[fB]=!1;function SB(e){return K$(e)&&X$(e.length)&&!!$e[Y$(e)]}var EB=SB;function MB(e){return function(t){return e(t)}}var mo=MB,gr={exports:{}};gr.exports;(function(e,t){var n=Px,i=t&&!t.nodeType&&t,r=i&&!0&&e&&!e.nodeType&&e,s=r&&r.exports===i,u=s&&n.process,f=function(){try{var d=r&&r.require&&r.require("util").types;return d||u&&u.binding&&u.binding("util")}catch{}}();e.exports=f})(gr,gr.exports);var Dx=gr.exports,AB=EB,kB=mo,um=Dx,lm=um&&um.isTypedArray,TB=lm?kB(lm):AB,Wf=TB;function PB(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var Qx=PB,CB=zf,NB=M9,OB=Object.prototype,LB=OB.hasOwnProperty;function FB(e,t,n){var i=e[t];(!(LB.call(e,t)&&NB(i,n))||n===void 0&&!(t in e))&&CB(e,t,n)}var Wx=FB,IB=Wx,RB=zf;function UB(e,t,n,i){var r=!n;n||(n={});for(var s=-1,u=t.length;++s-1&&e%1==0&&e0){if(++t>=qz)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Kz=Xz,Jz=Gz,ej=Kz,tj=ej(Jz),Vx=tj,nj=_o,ij=qx,rj=Vx;function oj(e,t){return rj(ij(e,t,nj),e+"")}var Hf=oj,sj=M9,aj=l0,uj=yo,lj=y3;function cj(e,t,n){if(!lj(n))return!1;var i=typeof t;return(i=="number"?aj(n)&&uj(t,n.length):i=="string"&&t in n)?sj(n[t],e):!1}var Yx=cj,fj=Hf,dj=Yx;function hj(e){return fj(function(t,n){var i=-1,r=n.length,s=r>1?n[r-1]:void 0,u=r>2?n[2]:void 0;for(s=e.length>3&&typeof s=="function"?(r--,s):void 0,u&&dj(n[0],n[1],u)&&(s=r<3?void 0:s,r=1),t=Object(t);++i>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Ji(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Ji(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=yD.exec(e))?new Ht(t[1],t[2],t[3],1):(t=_D.exec(e))?new Ht(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=vD.exec(e))?Ji(t[1],t[2],t[3],t[4]):(t=wD.exec(e))?Ji(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=xD.exec(e))?Am(t[1],t[2]/100,t[3]/100,1):(t=bD.exec(e))?Am(t[1],t[2]/100,t[3]/100,t[4]):wm.hasOwnProperty(e)?Sm(wm[e]):e==="transparent"?new Ht(NaN,NaN,NaN,0):null}function Sm(e){return new Ht(e>>16&255,e>>8&255,e&255,1)}function Ji(e,t,n,i){return i<=0&&(e=t=n=NaN),new Ht(e,t,n,i)}function tb(e){return e instanceof c0||(e=l9(e)),e?(e=e.rgb(),new Ht(e.r,e.g,e.b,e.opacity)):new Ht}function c9(e,t,n,i){return arguments.length===1?tb(e):new Ht(e,t,n,i??1)}function Ht(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}bo(Ht,c9,Vf(c0,{brighter:function(e){return e=e==null?V6:Math.pow(V6,e),new Ht(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=e==null?p5:Math.pow(p5,e),new Ht(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){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:Em,formatHex:Em,formatRgb:Mm,toString:Mm}));function Em(){return"#"+cu(this.r)+cu(this.g)+cu(this.b)}function Mm(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(e===1?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(e===1?")":", "+e+")")}function cu(e){return e=Math.max(0,Math.min(255,Math.round(e)||0)),(e<16?"0":"")+e.toString(16)}function Am(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new C2(e,t,n,i)}function nb(e){if(e instanceof C2)return new C2(e.h,e.s,e.l,e.opacity);if(e instanceof c0||(e=l9(e)),!e)return new C2;if(e instanceof C2)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,r=Math.min(t,n,i),s=Math.max(t,n,i),u=NaN,f=s-r,d=(s+r)/2;return f?(t===s?u=(n-i)/f+(n0&&d<1?0:u,new C2(u,f,d,e.opacity)}function ED(e,t,n,i){return arguments.length===1?nb(e):new C2(e,t,n,i??1)}function C2(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}bo(C2,ED,Vf(c0,{brighter:function(e){return e=e==null?V6:Math.pow(V6,e),new C2(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=e==null?p5:Math.pow(p5,e),new C2(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*t,r=2*n-i;return new Ht(fu(e>=240?e-240:e+120,r,i),fu(e,r,i),fu(e<120?e+240:e-120,r,i),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(e===1?"hsl(":"hsla(")+(this.h||0)+", "+(this.s||0)*100+"%, "+(this.l||0)*100+"%"+(e===1?")":", "+e+")")}}));function fu(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 MD=Math.PI/180,AD=180/Math.PI;var ib=-.14861,Yf=1.78277,Xf=-.29227,So=-.90649,f9=1.97294,km=f9*So,Tm=f9*Yf,Pm=Yf*Xf-So*ib;function kD(e){if(e instanceof r5)return new r5(e.h,e.s,e.l,e.opacity);e instanceof Ht||(e=tb(e));var t=e.r/255,n=e.g/255,i=e.b/255,r=(Pm*i+km*t-Tm*n)/(Pm+km-Tm),s=i-r,u=(f9*(n-r)-Xf*s)/So,f=Math.sqrt(u*u+s*s)/(f9*r*(1-r)),d=f?Math.atan2(u,s)*AD-120:NaN;return new r5(d<0?d+360:d,f,r,e.opacity)}function U2(e,t,n,i){return arguments.length===1?kD(e):new r5(e,t,n,i??1)}function r5(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}bo(r5,U2,Vf(c0,{brighter:function(e){return e=e==null?V6:Math.pow(V6,e),new r5(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=e==null?p5:Math.pow(p5,e),new r5(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*MD,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),i=Math.cos(e),r=Math.sin(e);return new Ht(255*(t+n*(ib*i+Yf*r)),255*(t+n*(Xf*i+So*r)),255*(t+n*(f9*i)),this.opacity)}}));function TD(e,t,n,i,r){var s=e*e,u=s*e;return((1-3*e+3*s-u)*t+(4-6*s+3*u)*n+(1+3*e+3*s-3*u)*i+u*r)/6}function PD(e){var t=e.length-1;return function(n){var i=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),r=e[i],s=e[i+1],u=i>0?e[i-1]:2*r-s,f=i()=>e;function rb(e,t){return function(n){return e+n*t}}function CD(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(i){return Math.pow(e+i*t,n)}}function ND(e,t){var n=t-e;return n?rb(e,n>180||n<-180?n-360*Math.round(n/360):n):Eo(isNaN(e)?t:e)}function OD(e){return(e=+e)==1?B6:function(t,n){return n-t?CD(t,n,e):Eo(isNaN(t)?n:t)}}function B6(e,t){var n=t-e;return n?rb(e,n):Eo(isNaN(e)?t:e)}const Cm=function e(t){var n=OD(t);function i(r,s){var u=n((r=c9(r)).r,(s=c9(s)).r),f=n(r.g,s.g),d=n(r.b,s.b),p=B6(r.opacity,s.opacity);return function(m){return r.r=u(m),r.g=f(m),r.b=d(m),r.opacity=p(m),r+""}}return i.gamma=e,i}(1);function LD(e){return function(t){var n=t.length,i=new Array(n),r=new Array(n),s=new Array(n),u,f;for(u=0;un&&(s=t.slice(n,s),f[u]?f[u]+=s:f[++u]=s),(i=i[0])===(r=r[0])?f[u]?f[u]+=r:f[++u]=r:(f[++u]=null,d.push({i:u,x:mr(i,r)})),n=du.lastIndex;return n + * Copyright OpenJS Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */yr.exports;(function(e,t){(function(){var n,i="4.17.21",r=200,s="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",u="Expected a function",f="Invalid `variable` option passed into `_.template`",d="__lodash_hash_undefined__",p=500,m="__lodash_placeholder__",h=1,_=2,S=4,E=1,k=2,O=1,x=2,w=4,b=8,N=16,B=32,R=64,j=128,$=256,K=512,H=30,Q="...",e1=800,X=16,o1=1,n1=2,l1=3,r1=1/0,Y=9007199254740991,g1=17976931348623157e292,f1=0/0,w1=4294967295,k1=w1-1,U1=w1>>>1,O1=[["ary",j],["bind",O],["bindKey",x],["curry",b],["curryRight",N],["flip",K],["partial",B],["partialRight",R],["rearg",$]],v1="[object Arguments]",d1="[object Array]",I1="[object AsyncFunction]",W1="[object Boolean]",E1="[object Date]",L1="[object DOMException]",R1="[object Error]",p1="[object Function]",J1="[object GeneratorFunction]",D1="[object Map]",se="[object Number]",we="[object Null]",pe="[object Object]",ge="[object Promise]",Qe="[object Proxy]",W="[object RegExp]",T="[object Set]",P="[object String]",Z="[object Symbol]",a1="[object Undefined]",_1="[object WeakMap]",b1="[object WeakSet]",G1="[object ArrayBuffer]",X1="[object DataView]",T1="[object Float32Array]",q1="[object Float64Array]",fe="[object Int8Array]",de="[object Int16Array]",mt="[object Int32Array]",S4="[object Uint8Array]",B2="[object Uint8ClampedArray]",H4="[object Uint16Array]",E4="[object Uint32Array]",P5=/\b__p \+= '';/g,z2=/\b(__p \+=) '' \+/g,fn=/(__e\(.*?\)|\b__t\)) \+\n'';/g,u4=/&(?:amp|lt|gt|quot|#39);/g,dn=/[&<>"']/g,Z4=RegExp(u4.source),hn=RegExp(dn.source),hs=/<%-([\s\S]+?)%>/g,ps=/<%([\s\S]+?)%>/g,N9=/<%=([\s\S]+?)%>/g,gs=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,h0=/^\w*$/,ms=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,p0=/[\\^$.*+?()[\]{}|]/g,ys=RegExp(p0.source),g0=/^\s+/,M4=/\s/,B1=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,O9=/\{\n\/\* \[wrapped with (.+)\] \*/,L9=/,? & /,F9=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,I9=/[()=,{}\[\]\/\s]/,m0=/\\(\\)?/g,R9=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,j2=/\w*$/,U9=/^[-+]0x[0-9a-f]+$/i,_s=/^0b[01]+$/i,vs=/^\[object .+?Constructor\]$/,ws=/^0o[0-7]+$/i,xs=/^(?:0|[1-9]\d*)$/,$9=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,C5=/($^)/,N5=/['\n\r\u2028\u2029\\]/g,O5="\\ud800-\\udfff",bs="\\u0300-\\u036f",Ss="\\ufe20-\\ufe2f",Es="\\u20d0-\\u20ff",B9=bs+Ss+Es,L5="\\u2700-\\u27bf",_3="a-z\\xdf-\\xf6\\xf8-\\xff",z9="\\xac\\xb1\\xd7\\xf7",j9="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",pn="\\u2000-\\u206f",xe=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Oe="A-Z\\xc0-\\xd6\\xd8-\\xde",gn="\\ufe0e\\ufe0f",D2=z9+j9+pn+xe,m2="['’]",y0="["+O5+"]",ee="["+D2+"]",Le="["+B9+"]",F5="\\d+",I5="["+L5+"]",It="["+_3+"]",D9="[^"+O5+D2+F5+L5+_3+Oe+"]",v3="\\ud83c[\\udffb-\\udfff]",Q2="(?:"+Le+"|"+v3+")",We="[^"+O5+"]",G4="(?:\\ud83c[\\udde6-\\uddff]){2}",W2="[\\ud800-\\udbff][\\udc00-\\udfff]",A4="["+Oe+"]",R5="\\u200d",w3="(?:"+It+"|"+D9+")",_0="(?:"+A4+"|"+D9+")",U5="(?:"+m2+"(?:d|ll|m|re|s|t|ve))?",mn="(?:"+m2+"(?:D|LL|M|RE|S|T|VE))?",$5=Q2+"?",B5="["+gn+"]?",z5="(?:"+R5+"(?:"+[We,G4,W2].join("|")+")"+B5+$5+")*",Q9="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",v0="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",W9=B5+$5+z5,K1="(?:"+[I5,G4,W2].join("|")+")"+W9,k4="(?:"+[We+Le+"?",Le,G4,W2,y0].join("|")+")",Pe=RegExp(m2,"g"),H9=RegExp(Le,"g"),yn=RegExp(v3+"(?="+v3+")|"+k4+W9,"g"),w0=RegExp([A4+"?"+It+"+"+U5+"(?="+[ee,A4,"$"].join("|")+")",_0+"+"+mn+"(?="+[ee,A4+w3,"$"].join("|")+")",A4+"?"+w3+"+"+U5,A4+"+"+mn,v0,Q9,F5,K1].join("|"),"g"),x0=RegExp("["+R5+O5+B9+gn+"]"),H2=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,b0=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],_n=-1,te={};te[T1]=te[q1]=te[fe]=te[de]=te[mt]=te[S4]=te[B2]=te[H4]=te[E4]=!0,te[v1]=te[d1]=te[G1]=te[W1]=te[X1]=te[E1]=te[R1]=te[p1]=te[D1]=te[se]=te[pe]=te[W]=te[T]=te[P]=te[_1]=!1;var be={};be[v1]=be[d1]=be[G1]=be[X1]=be[W1]=be[E1]=be[T1]=be[q1]=be[fe]=be[de]=be[mt]=be[D1]=be[se]=be[pe]=be[W]=be[T]=be[P]=be[Z]=be[S4]=be[B2]=be[H4]=be[E4]=!0,be[R1]=be[p1]=be[_1]=!1;var Z9={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},G9={"&":"&","<":"<",">":">",'"':""","'":"'"},Ms={"&":"&","<":"<",">":">",""":'"',"'":"'"},q9={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},S0=parseFloat,As=parseInt,E0=typeof a2=="object"&&a2&&a2.Object===Object&&a2,me=typeof self=="object"&&self&&self.Object===Object&&self,rt=E0||me||Function("return this")(),Rt=t&&!t.nodeType&&t,l4=Rt&&!0&&e&&!e.nodeType&&e,M0=l4&&l4.exports===Rt,A0=M0&&E0.process,bt=function(){try{var t1=l4&&l4.require&&l4.require("util").types;return t1||A0&&A0.binding&&A0.binding("util")}catch{}}(),V9=bt&&bt.isArrayBuffer,k0=bt&&bt.isDate,Y9=bt&&bt.isMap,X9=bt&&bt.isRegExp,j5=bt&&bt.isSet,K9=bt&&bt.isTypedArray;function ze(t1,h1,c1){switch(c1.length){case 0:return t1.call(h1);case 1:return t1.call(h1,c1[0]);case 2:return t1.call(h1,c1[0],c1[1]);case 3:return t1.call(h1,c1[0],c1[1],c1[2])}return t1.apply(h1,c1)}function ks(t1,h1,c1,N1){for(var V1=-1,Se=t1==null?0:t1.length;++V1-1}function P0(t1,h1,c1){for(var N1=-1,V1=t1==null?0:t1.length;++N1-1;);return c1}function ii(t1,h1){for(var c1=t1.length;c1--&&b3(h1,t1[c1],0)>-1;);return c1}function S3(t1,h1){for(var c1=t1.length,N1=0;c1--;)t1[c1]===h1&&++N1;return N1}var Cs=O0(Z9),Sn=O0(G9);function ri(t1){return"\\"+q9[t1]}function W5(t1,h1){return t1==null?n:t1[h1]}function E3(t1){return x0.test(t1)}function v2(t1){return H2.test(t1)}function H5(t1){for(var h1,c1=[];!(h1=t1.next()).done;)c1.push(h1.value);return c1}function R0(t1){var h1=-1,c1=Array(t1.size);return t1.forEach(function(N1,V1){c1[++h1]=[V1,N1]}),c1}function Z5(t1,h1){return function(c1){return t1(h1(c1))}}function w2(t1,h1){for(var c1=-1,N1=t1.length,V1=0,Se=[];++c1-1}function _M(a,c){var y=this.__data__,M=fi(y,a);return M<0?(++this.size,y.push([a,c])):y[M][1]=c,this}q2.prototype.clear=pM,q2.prototype.delete=gM,q2.prototype.get=mM,q2.prototype.has=yM,q2.prototype.set=_M;function V2(a){var c=-1,y=a==null?0:a.length;for(this.clear();++c=c?a:c)),a}function N4(a,c,y,M,I,D){var q,J=c&h,i1=c&_,m1=c&S;if(y&&(q=I?y(a,M,I,D):y(a)),q!==n)return q;if(!He(a))return a;var y1=ne(a);if(y1){if(q=bA(a),!J)return Yt(a,q)}else{var S1=At(a),P1=S1==p1||S1==J1;if(I3(a))return fh(a,J);if(S1==pe||S1==v1||P1&&!I){if(q=i1||P1?{}:Ch(a),!J)return i1?fA(a,FM(q,a)):cA(a,jd(q,a))}else{if(!be[S1])return I?a:{};q=SA(a,S1,J)}}D||(D=new J4);var $1=D.get(a);if($1)return $1;D.set(a,q),op(a)?a.forEach(function(Z1){q.add(N4(Z1,c,y,Z1,a,D))}):ip(a)&&a.forEach(function(Z1,he){q.set(he,N4(Z1,c,y,he,a,D))});var H1=m1?i1?ua:aa:i1?Kt:ct,ae=y1?n:H1(a);return Ut(ae||a,function(Z1,he){ae&&(he=Z1,Z1=a[he]),Q0(q,he,N4(Z1,c,y,he,a,D))}),q}function IM(a){var c=ct(a);return function(y){return Dd(y,a,c)}}function Dd(a,c,y){var M=y.length;if(a==null)return!M;for(a=Ae(a);M--;){var I=y[M],D=c[I],q=a[I];if(q===n&&!(I in a)||!D(q))return!1}return!0}function Qd(a,c,y){if(typeof a!="function")throw new yt(u);return Y0(function(){a.apply(n,y)},c)}function W0(a,c,y,M){var I=-1,D=x3,q=!0,J=a.length,i1=[],m1=c.length;if(!J)return i1;y&&(c=Ce(c,Re(y))),M?(D=P0,q=!1):c.length>=r&&(D=bn,q=!1,c=new Fn(c));e:for(;++II?0:I+y),M=M===n||M>I?I:oe(M),M<0&&(M+=I),M=y>M?0:ap(M);y0&&y(J)?c>1?_t(J,c-1,y,M,I):V4(I,J):M||(I[I.length]=J)}return I}var Qs=yh(),Zd=yh(!0);function S2(a,c){return a&&Qs(a,c,ct)}function Ws(a,c){return a&&Zd(a,c,ct)}function hi(a,c){return q4(c,function(y){return e3(a[y])})}function Rn(a,c){c=L3(c,a);for(var y=0,M=c.length;a!=null&&yc}function $M(a,c){return a!=null&&_e.call(a,c)}function BM(a,c){return a!=null&&c in Ae(a)}function zM(a,c,y){return a>=U(c,y)&&a=120&&y1.length>=120)?new Fn(q&&y1):n}y1=a[0];var S1=-1,P1=J[0];e:for(;++S1-1;)J!==a&&kn.call(J,i1,1),kn.call(a,i1,1);return a}function ih(a,c){for(var y=a?c.length:0,M=y-1;y--;){var I=c[y];if(y==M||I!==D){var D=I;J2(I)?kn.call(a,I,1):ea(a,I)}}return a}function Xs(a,c){return a+Cn(u1()*(c-a+1))}function JM(a,c,y,M){for(var I=-1,D=A(Pn((c-a)/(y||1)),0),q=c1(D);D--;)q[M?D:++I]=a,a+=y;return q}function Ks(a,c){var y="";if(!a||c<1||c>Y)return y;do c%2&&(y+=a),c=Cn(c/2),c&&(a+=a);while(c);return y}function ce(a,c){return ga(Lh(a,c,Jt),a+"")}function eA(a){return zd(i6(a))}function tA(a,c){var y=i6(a);return Ei(y,In(c,0,y.length))}function G0(a,c,y,M){if(!He(a))return a;c=L3(c,a);for(var I=-1,D=c.length,q=D-1,J=a;J!=null&&++II?0:I+c),y=y>I?I:y,y<0&&(y+=I),I=c>y?0:y-c>>>0,c>>>=0;for(var D=c1(I);++M>>1,q=a[D];q!==null&&!d4(q)&&(y?q<=c:q=r){var m1=c?null:gA(a);if(m1)return Vt(m1);q=!1,I=bn,i1=new Fn}else i1=c?[]:J;e:for(;++M=M?a:O4(a,c,y)}var ch=ui||function(a){return rt.clearTimeout(a)};function fh(a,c){if(c)return a.slice();var y=a.length,M=si?si(y):new a.constructor(y);return a.copy(M),M}function ra(a){var c=new a.constructor(a.byteLength);return new x2(c).set(new x2(a)),c}function sA(a,c){var y=c?ra(a.buffer):a.buffer;return new a.constructor(y,a.byteOffset,a.byteLength)}function aA(a){var c=new a.constructor(a.source,j2.exec(a));return c.lastIndex=a.lastIndex,c}function uA(a){return Fe?Ae(Fe.call(a)):{}}function dh(a,c){var y=c?ra(a.buffer):a.buffer;return new a.constructor(y,a.byteOffset,a.length)}function hh(a,c){if(a!==c){var y=a!==n,M=a===null,I=a===a,D=d4(a),q=c!==n,J=c===null,i1=c===c,m1=d4(c);if(!J&&!m1&&!D&&a>c||D&&q&&i1&&!J&&!m1||M&&q&&i1||!y&&i1||!I)return 1;if(!M&&!D&&!m1&&a=J)return i1;var m1=y[M];return i1*(m1=="desc"?-1:1)}}return a.index-c.index}function ph(a,c,y,M){for(var I=-1,D=a.length,q=y.length,J=-1,i1=c.length,m1=A(D-q,0),y1=c1(i1+m1),S1=!M;++J1?y[I-1]:n,q=I>2?y[2]:n;for(D=a.length>3&&typeof D=="function"?(I--,D):n,q&&zt(y[0],y[1],q)&&(D=I<3?n:D,I=1),c=Ae(c);++M-1?I[D?c[q]:q]:n}}function wh(a){return K2(function(c){var y=c.length,M=y,I=Mt.prototype.thru;for(a&&c.reverse();M--;){var D=c[M];if(typeof D!="function")throw new yt(u);if(I&&!q&&bi(D)=="wrapper")var q=new Mt([],!0)}for(M=q?M:y;++M1&&ve.reverse(),y1&&i1J))return!1;var m1=D.get(a),y1=D.get(c);if(m1&&y1)return m1==c&&y1==a;var S1=-1,P1=!0,$1=y&k?new Fn:n;for(D.set(a,c),D.set(c,a);++S11?"& ":"")+c[M],c=c.join(y>2?", ":" "),a.replace(B1,`{ +/* [wrapped with `+c+`] */ +`)}function MA(a){return ne(a)||Bn(a)||!!(ai&&a&&a[ai])}function J2(a,c){var y=typeof a;return c=c??Y,!!c&&(y=="number"||y!="symbol"&&xs.test(a))&&a>-1&&a%1==0&&a0){if(++c>=e1)return arguments[0]}else c=0;return a.apply(n,arguments)}}function Ei(a,c){var y=-1,M=a.length,I=M-1;for(c=c===n?M:c;++y1?a[c-1]:n;return y=typeof y=="function"?(a.pop(),y):n,Hh(a,y)});function Zh(a){var c=z(a);return c.__chain__=!0,c}function Rk(a,c){return c(a),a}function Mi(a,c){return c(a)}var Uk=K2(function(a){var c=a.length,y=c?a[0]:0,M=this.__wrapped__,I=function(D){return Ds(D,a)};return c>1||this.__actions__.length||!(M instanceof le)||!J2(y)?this.thru(I):(M=M.slice(y,+y+(c?1:0)),M.__actions__.push({func:Mi,args:[I],thisArg:n}),new Mt(M,this.__chain__).thru(function(D){return c&&!D.length&&D.push(n),D}))});function $k(){return Zh(this)}function Bk(){return new Mt(this.value(),this.__chain__)}function zk(){this.__values__===n&&(this.__values__=sp(this.value()));var a=this.__index__>=this.__values__.length,c=a?n:this.__values__[this.__index__++];return{done:a,value:c}}function jk(){return this}function Dk(a){for(var c,y=this;y instanceof K5;){var M=Bh(y);M.__index__=0,M.__values__=n,c?I.__wrapped__=M:c=M;var I=M;y=y.__wrapped__}return I.__wrapped__=a,c}function Qk(){var a=this.__wrapped__;if(a instanceof le){var c=a;return this.__actions__.length&&(c=new le(this)),c=c.reverse(),c.__actions__.push({func:Mi,args:[ma],thisArg:n}),new Mt(c,this.__chain__)}return this.thru(ma)}function Wk(){return uh(this.__wrapped__,this.__actions__)}var Hk=yi(function(a,c,y){_e.call(a,y)?++a[y]:Y2(a,y,1)});function Zk(a,c,y){var M=ne(a)?T0:RM;return y&&zt(a,c,y)&&(c=n),M(a,Q1(c,3))}function Gk(a,c){var y=ne(a)?q4:Hd;return y(a,Q1(c,3))}var qk=vh(zh),Vk=vh(jh);function Yk(a,c){return _t(Ai(a,c),1)}function Xk(a,c){return _t(Ai(a,c),r1)}function Kk(a,c,y){return y=y===n?1:oe(y),_t(Ai(a,c),y)}function Gh(a,c){var y=ne(a)?Ut:N3;return y(a,Q1(c,3))}function qh(a,c){var y=ne(a)?y2:Wd;return y(a,Q1(c,3))}var Jk=yi(function(a,c,y){_e.call(a,y)?a[y].push(c):Y2(a,y,[c])});function eT(a,c,y,M){a=Xt(a)?a:i6(a),y=y&&!M?oe(y):0;var I=a.length;return y<0&&(y=A(I+y,0)),Ni(a)?y<=I&&a.indexOf(c,y)>-1:!!I&&b3(a,c,y)>-1}var tT=ce(function(a,c,y){var M=-1,I=typeof c=="function",D=Xt(a)?c1(a.length):[];return N3(a,function(q){D[++M]=I?ze(c,q,y):H0(q,c,y)}),D}),nT=yi(function(a,c,y){Y2(a,y,c)});function Ai(a,c){var y=ne(a)?Ce:Xd;return y(a,Q1(c,3))}function iT(a,c,y,M){return a==null?[]:(ne(c)||(c=c==null?[]:[c]),y=M?n:y,ne(y)||(y=y==null?[]:[y]),th(a,c,y))}var rT=yi(function(a,c,y){a[y?0:1].push(c)},function(){return[[],[]]});function oT(a,c,y){var M=ne(a)?C0:Q5,I=arguments.length<3;return M(a,Q1(c,4),y,I,N3)}function sT(a,c,y){var M=ne(a)?Ts:Q5,I=arguments.length<3;return M(a,Q1(c,4),y,I,Wd)}function aT(a,c){var y=ne(a)?q4:Hd;return y(a,Pi(Q1(c,3)))}function uT(a){var c=ne(a)?zd:eA;return c(a)}function lT(a,c,y){(y?zt(a,c,y):c===n)?c=1:c=oe(c);var M=ne(a)?NM:tA;return M(a,c)}function cT(a){var c=ne(a)?OM:iA;return c(a)}function fT(a){if(a==null)return 0;if(Xt(a))return Ni(a)?St(a):a.length;var c=At(a);return c==D1||c==T?a.size:qs(a).length}function dT(a,c,y){var M=ne(a)?vn:rA;return y&&zt(a,c,y)&&(c=n),M(a,Q1(c,3))}var hT=ce(function(a,c){if(a==null)return[];var y=c.length;return y>1&&zt(a,c[0],c[1])?c=[]:y>2&&zt(c[0],c[1],c[2])&&(c=[c[0]]),th(a,_t(c,1),[])}),ki=li||function(){return rt.Date.now()};function pT(a,c){if(typeof c!="function")throw new yt(u);return a=oe(a),function(){if(--a<1)return c.apply(this,arguments)}}function Vh(a,c,y){return c=y?n:c,c=a&&c==null?a.length:c,X2(a,j,n,n,n,n,c)}function Yh(a,c){var y;if(typeof c!="function")throw new yt(u);return a=oe(a),function(){return--a>0&&(y=c.apply(this,arguments)),a<=1&&(c=n),y}}var _a=ce(function(a,c,y){var M=O;if(y.length){var I=w2(y,t6(_a));M|=B}return X2(a,M,c,y,I)}),Xh=ce(function(a,c,y){var M=O|x;if(y.length){var I=w2(y,t6(Xh));M|=B}return X2(c,M,a,y,I)});function Kh(a,c,y){c=y?n:c;var M=X2(a,b,n,n,n,n,n,c);return M.placeholder=Kh.placeholder,M}function Jh(a,c,y){c=y?n:c;var M=X2(a,N,n,n,n,n,n,c);return M.placeholder=Jh.placeholder,M}function ep(a,c,y){var M,I,D,q,J,i1,m1=0,y1=!1,S1=!1,P1=!0;if(typeof a!="function")throw new yt(u);c=F4(c)||0,He(y)&&(y1=!!y.leading,S1="maxWait"in y,D=S1?A(F4(y.maxWait)||0,c):D,P1="trailing"in y?!!y.trailing:P1);function $1(et){var t2=M,n3=I;return M=I=n,m1=et,q=a.apply(n3,t2),q}function H1(et){return m1=et,J=Y0(he,c),y1?$1(et):q}function ae(et){var t2=et-i1,n3=et-m1,vp=c-t2;return S1?U(vp,D-n3):vp}function Z1(et){var t2=et-i1,n3=et-m1;return i1===n||t2>=c||t2<0||S1&&n3>=D}function he(){var et=ki();if(Z1(et))return ve(et);J=Y0(he,ae(et))}function ve(et){return J=n,P1&&M?$1(et):(M=I=n,q)}function h4(){J!==n&&ch(J),m1=0,M=i1=I=J=n}function jt(){return J===n?q:ve(ki())}function p4(){var et=ki(),t2=Z1(et);if(M=arguments,I=this,i1=et,t2){if(J===n)return H1(i1);if(S1)return ch(J),J=Y0(he,c),$1(i1)}return J===n&&(J=Y0(he,c)),q}return p4.cancel=h4,p4.flush=jt,p4}var gT=ce(function(a,c){return Qd(a,1,c)}),mT=ce(function(a,c,y){return Qd(a,F4(c)||0,y)});function yT(a){return X2(a,K)}function Ti(a,c){if(typeof a!="function"||c!=null&&typeof c!="function")throw new yt(u);var y=function(){var M=arguments,I=c?c.apply(this,M):M[0],D=y.cache;if(D.has(I))return D.get(I);var q=a.apply(this,M);return y.cache=D.set(I,q)||D,q};return y.cache=new(Ti.Cache||V2),y}Ti.Cache=V2;function Pi(a){if(typeof a!="function")throw new yt(u);return function(){var c=arguments;switch(c.length){case 0:return!a.call(this);case 1:return!a.call(this,c[0]);case 2:return!a.call(this,c[0],c[1]);case 3:return!a.call(this,c[0],c[1],c[2])}return!a.apply(this,c)}}function _T(a){return Yh(2,a)}var vT=oA(function(a,c){c=c.length==1&&ne(c[0])?Ce(c[0],Re(Q1())):Ce(_t(c,1),Re(Q1()));var y=c.length;return ce(function(M){for(var I=-1,D=U(M.length,y);++I=c}),Bn=qd(function(){return arguments}())?qd:function(a){return Ye(a)&&_e.call(a,"callee")&&!j0.call(a,"callee")},ne=c1.isArray,FT=V9?Re(V9):DM;function Xt(a){return a!=null&&Ci(a.length)&&!e3(a)}function Je(a){return Ye(a)&&Xt(a)}function IT(a){return a===!0||a===!1||Ye(a)&&Bt(a)==W1}var I3=o||Ca,RT=k0?Re(k0):QM;function UT(a){return Ye(a)&&a.nodeType===1&&!X0(a)}function $T(a){if(a==null)return!0;if(Xt(a)&&(ne(a)||typeof a=="string"||typeof a.splice=="function"||I3(a)||n6(a)||Bn(a)))return!a.length;var c=At(a);if(c==D1||c==T)return!a.size;if(V0(a))return!qs(a).length;for(var y in a)if(_e.call(a,y))return!1;return!0}function BT(a,c){return Z0(a,c)}function zT(a,c,y){y=typeof y=="function"?y:n;var M=y?y(a,c):n;return M===n?Z0(a,c,n,y):!!M}function wa(a){if(!Ye(a))return!1;var c=Bt(a);return c==R1||c==L1||typeof a.message=="string"&&typeof a.name=="string"&&!X0(a)}function jT(a){return typeof a=="number"&&l(a)}function e3(a){if(!He(a))return!1;var c=Bt(a);return c==p1||c==J1||c==I1||c==Qe}function np(a){return typeof a=="number"&&a==oe(a)}function Ci(a){return typeof a=="number"&&a>-1&&a%1==0&&a<=Y}function He(a){var c=typeof a;return a!=null&&(c=="object"||c=="function")}function Ye(a){return a!=null&&typeof a=="object"}var ip=Y9?Re(Y9):HM;function DT(a,c){return a===c||Gs(a,c,ca(c))}function QT(a,c,y){return y=typeof y=="function"?y:n,Gs(a,c,ca(c),y)}function WT(a){return rp(a)&&a!=+a}function HT(a){if(TA(a))throw new V1(s);return Vd(a)}function ZT(a){return a===null}function GT(a){return a==null}function rp(a){return typeof a=="number"||Ye(a)&&Bt(a)==se}function X0(a){if(!Ye(a)||Bt(a)!=pe)return!1;var c=G2(a);if(c===null)return!0;var y=_e.call(c,"constructor")&&c.constructor;return typeof y=="function"&&y instanceof y&&X5.call(y)==oi}var xa=X9?Re(X9):ZM;function qT(a){return np(a)&&a>=-Y&&a<=Y}var op=j5?Re(j5):GM;function Ni(a){return typeof a=="string"||!ne(a)&&Ye(a)&&Bt(a)==P}function d4(a){return typeof a=="symbol"||Ye(a)&&Bt(a)==Z}var n6=K9?Re(K9):qM;function VT(a){return a===n}function YT(a){return Ye(a)&&At(a)==_1}function XT(a){return Ye(a)&&Bt(a)==b1}var KT=xi(Vs),JT=xi(function(a,c){return a<=c});function sp(a){if(!a)return[];if(Xt(a))return Ni(a)?Et(a):Yt(a);if(P3&&a[P3])return H5(a[P3]());var c=At(a),y=c==D1?R0:c==T?Vt:i6;return y(a)}function t3(a){if(!a)return a===0?a:0;if(a=F4(a),a===r1||a===-r1){var c=a<0?-1:1;return c*g1}return a===a?a:0}function oe(a){var c=t3(a),y=c%1;return c===c?y?c-y:c:0}function ap(a){return a?In(oe(a),0,w1):0}function F4(a){if(typeof a=="number")return a;if(d4(a))return f1;if(He(a)){var c=typeof a.valueOf=="function"?a.valueOf():a;a=He(c)?c+"":c}if(typeof a!="string")return a===0?a:+a;a=ni(a);var y=_s.test(a);return y||ws.test(a)?As(a.slice(2),y?2:8):U9.test(a)?f1:+a}function up(a){return E2(a,Kt(a))}function eP(a){return a?In(oe(a),-Y,Y):a===0?a:0}function ke(a){return a==null?"":f4(a)}var tP=J5(function(a,c){if(V0(c)||Xt(c)){E2(c,ct(c),a);return}for(var y in c)_e.call(c,y)&&Q0(a,y,c[y])}),lp=J5(function(a,c){E2(c,Kt(c),a)}),Oi=J5(function(a,c,y,M){E2(c,Kt(c),a,M)}),nP=J5(function(a,c,y,M){E2(c,ct(c),a,M)}),iP=K2(Ds);function rP(a,c){var y=C3(a);return c==null?y:jd(y,c)}var oP=ce(function(a,c){a=Ae(a);var y=-1,M=c.length,I=M>2?c[2]:n;for(I&&zt(c[0],c[1],I)&&(M=1);++y1),D}),E2(a,ua(a),y),M&&(y=N4(y,h|_|S,mA));for(var I=c.length;I--;)ea(y,c[I]);return y});function SP(a,c){return fp(a,Pi(Q1(c)))}var EP=K2(function(a,c){return a==null?{}:XM(a,c)});function fp(a,c){if(a==null)return{};var y=Ce(ua(a),function(M){return[M]});return c=Q1(c),nh(a,y,function(M,I){return c(M,I[0])})}function MP(a,c,y){c=L3(c,a);var M=-1,I=c.length;for(I||(I=1,a=n);++Mc){var M=a;a=c,c=M}if(y||a%1||c%1){var I=u1();return U(a+I*(c-a+S0("1e-"+((I+"").length-1))),c)}return Xs(a,c)}var RP=e6(function(a,c,y){return c=c.toLowerCase(),a+(y?pp(c):c)});function pp(a){return Ea(ke(a).toLowerCase())}function gp(a){return a=ke(a),a&&a.replace($9,Cs).replace(H9,"")}function UP(a,c,y){a=ke(a),c=f4(c);var M=a.length;y=y===n?M:In(oe(y),0,M);var I=y;return y-=c.length,y>=0&&a.slice(y,I)==c}function $P(a){return a=ke(a),a&&hn.test(a)?a.replace(dn,Sn):a}function BP(a){return a=ke(a),a&&ys.test(a)?a.replace(p0,"\\$&"):a}var zP=e6(function(a,c,y){return a+(y?"-":"")+c.toLowerCase()}),jP=e6(function(a,c,y){return a+(y?" ":"")+c.toLowerCase()}),DP=_h("toLowerCase");function QP(a,c,y){a=ke(a),c=oe(c);var M=c?St(a):0;if(!c||M>=c)return a;var I=(c-M)/2;return wi(Cn(I),y)+a+wi(Pn(I),y)}function WP(a,c,y){a=ke(a),c=oe(c);var M=c?St(a):0;return c&&M>>0,y?(a=ke(a),a&&(typeof c=="string"||c!=null&&!xa(c))&&(c=f4(c),!c&&E3(a))?F3(Et(a),0,y):a.split(c,y)):[]}var XP=e6(function(a,c,y){return a+(y?" ":"")+Ea(c)});function KP(a,c,y){return a=ke(a),y=y==null?0:In(oe(y),0,a.length),c=f4(c),a.slice(y,y+c.length)==c}function JP(a,c,y){var M=z.templateSettings;y&&zt(a,c,y)&&(c=n),a=ke(a),c=Oi({},c,M,Mh);var I=Oi({},c.imports,M.imports,Mh),D=ct(I),q=_2(I,D),J,i1,m1=0,y1=c.interpolate||C5,S1="__p += '",P1=z0((c.escape||C5).source+"|"+y1.source+"|"+(y1===N9?R9:C5).source+"|"+(c.evaluate||C5).source+"|$","g"),$1="//# sourceURL="+(_e.call(c,"sourceURL")?(c.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++_n+"]")+` +`;a.replace(P1,function(Z1,he,ve,h4,jt,p4){return ve||(ve=h4),S1+=a.slice(m1,p4).replace(N5,ri),he&&(J=!0,S1+=`' + +__e(`+he+`) + +'`),jt&&(i1=!0,S1+=`'; +`+jt+`; +__p += '`),ve&&(S1+=`' + +((__t = (`+ve+`)) == null ? '' : __t) + +'`),m1=p4+Z1.length,Z1}),S1+=`'; +`;var H1=_e.call(c,"variable")&&c.variable;if(!H1)S1=`with (obj) { +`+S1+` +} +`;else if(I9.test(H1))throw new V1(f);S1=(i1?S1.replace(P5,""):S1).replace(z2,"$1").replace(fn,"$1;"),S1="function("+(H1||"obj")+`) { +`+(H1?"":`obj || (obj = {}); +`)+"var __t, __p = ''"+(J?", __e = _.escape":"")+(i1?`, __j = Array.prototype.join; +function print() { __p += __j.call(arguments, '') } +`:`; +`)+S1+`return __p +}`;var ae=yp(function(){return Se(D,$1+"return "+S1).apply(n,q)});if(ae.source=S1,wa(ae))throw ae;return ae}function eC(a){return ke(a).toLowerCase()}function tC(a){return ke(a).toUpperCase()}function nC(a,c,y){if(a=ke(a),a&&(y||c===n))return ni(a);if(!a||!(c=f4(c)))return a;var M=Et(a),I=Et(c),D=P4(M,I),q=ii(M,I)+1;return F3(M,D,q).join("")}function iC(a,c,y){if(a=ke(a),a&&(y||c===n))return a.slice(0,U0(a)+1);if(!a||!(c=f4(c)))return a;var M=Et(a),I=ii(M,Et(c))+1;return F3(M,0,I).join("")}function rC(a,c,y){if(a=ke(a),a&&(y||c===n))return a.replace(g0,"");if(!a||!(c=f4(c)))return a;var M=Et(a),I=P4(M,Et(c));return F3(M,I).join("")}function oC(a,c){var y=H,M=Q;if(He(c)){var I="separator"in c?c.separator:I;y="length"in c?oe(c.length):y,M="omission"in c?f4(c.omission):M}a=ke(a);var D=a.length;if(E3(a)){var q=Et(a);D=q.length}if(y>=D)return a;var J=y-St(M);if(J<1)return M;var i1=q?F3(q,0,J).join(""):a.slice(0,J);if(I===n)return i1+M;if(q&&(J+=i1.length-J),xa(I)){if(a.slice(J).search(I)){var m1,y1=i1;for(I.global||(I=z0(I.source,ke(j2.exec(I))+"g")),I.lastIndex=0;m1=I.exec(y1);)var S1=m1.index;i1=i1.slice(0,S1===n?J:S1)}}else if(a.indexOf(f4(I),J)!=J){var P1=i1.lastIndexOf(I);P1>-1&&(i1=i1.slice(0,P1))}return i1+M}function sC(a){return a=ke(a),a&&Z4.test(a)?a.replace(u4,$0):a}var aC=e6(function(a,c,y){return a+(y?" ":"")+c.toUpperCase()}),Ea=_h("toUpperCase");function mp(a,c,y){return a=ke(a),c=y?n:c,c===n?v2(a)?q5(a):ei(a):a.match(c)||[]}var yp=ce(function(a,c){try{return ze(a,n,c)}catch(y){return wa(y)?y:new V1(y)}}),uC=K2(function(a,c){return Ut(c,function(y){y=M2(y),Y2(a,y,_a(a[y],a))}),a});function lC(a){var c=a==null?0:a.length,y=Q1();return a=c?Ce(a,function(M){if(typeof M[1]!="function")throw new yt(u);return[y(M[0]),M[1]]}):[],ce(function(M){for(var I=-1;++IY)return[];var y=w1,M=U(a,w1);c=Q1(c),a-=w1;for(var I=I0(M,c);++y0||c<0)?new le(y):(a<0?y=y.takeRight(-a):a&&(y=y.drop(a)),c!==n&&(c=oe(c),y=c<0?y.dropRight(-c):y.take(c-a)),y)},le.prototype.takeRightWhile=function(a){return this.reverse().takeWhile(a).reverse()},le.prototype.toArray=function(){return this.take(w1)},S2(le.prototype,function(a,c){var y=/^(?:filter|find|map|reject)|While$/.test(c),M=/^(?:head|last)$/.test(c),I=z[M?"take"+(c=="last"?"Right":""):c],D=M||/^find/.test(c);I&&(z.prototype[c]=function(){var q=this.__wrapped__,J=M?[1]:arguments,i1=q instanceof le,m1=J[0],y1=i1||ne(q),S1=function(he){var ve=I.apply(z,V4([he],J));return M&&P1?ve[0]:ve};y1&&y&&typeof m1=="function"&&m1.length!=1&&(i1=y1=!1);var P1=this.__chain__,$1=!!this.__actions__.length,H1=D&&!P1,ae=i1&&!$1;if(!D&&y1){q=ae?q:new le(this);var Z1=a.apply(q,J);return Z1.__actions__.push({func:Mi,args:[S1],thisArg:n}),new Mt(Z1,P1)}return H1&&ae?a.apply(this,J):(Z1=this.thru(S1),H1?M?Z1.value()[0]:Z1.value():Z1)})}),Ut(["pop","push","shift","sort","splice","unshift"],function(a){var c=V5[a],y=/^(?:push|sort|unshift)$/.test(a)?"tap":"thru",M=/^(?:pop|shift)$/.test(a);z.prototype[a]=function(){var I=arguments;if(M&&!this.__chain__){var D=this.value();return c.apply(ne(D)?D:[],I)}return this[y](function(q){return c.apply(ne(q)?q:[],I)})}}),S2(le.prototype,function(a,c){var y=z[c];if(y){var M=y.name+"";_e.call(c4,M)||(c4[M]=[]),c4[M].push({name:c,func:y})}}),c4[_i(n,x).name]=[{name:"wrapper",func:n}],le.prototype.clone=zs,le.prototype.reverse=aM,le.prototype.value=uM,z.prototype.at=Uk,z.prototype.chain=$k,z.prototype.commit=Bk,z.prototype.next=zk,z.prototype.plant=Dk,z.prototype.reverse=Qk,z.prototype.toJSON=z.prototype.valueOf=z.prototype.value=Wk,z.prototype.first=z.prototype.head,P3&&(z.prototype[P3]=jk),z},Y4=A3();l4?((l4.exports=Y4)._=Y4,Rt._=Y4):rt._=Y4}).call(a2)})(yr,yr.exports);var o5=yr.exports;function QD(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var WD=QD;const z1=Lt(WD);function ab(e,t){return et?1:e>=t?0:NaN}function ed(e){let t=e,n=e;e.length===1&&(t=(u,f)=>e(u)-f,n=HD(e));function i(u,f,d,p){for(d==null&&(d=0),p==null&&(p=u.length);d>>1;n(u[m],f)<0?d=m+1:p=m}return d}function r(u,f,d,p){for(d==null&&(d=0),p==null&&(p=u.length);d>>1;n(u[m],f)>0?p=m:d=m+1}return d}function s(u,f,d,p){d==null&&(d=0),p==null&&(p=u.length);const m=i(u,f,d,p-1);return m>d&&t(u[m-1],f)>-t(u[m],f)?m-1:m}return{left:i,center:s,right:r}}function HD(e){return(t,n)=>ab(e(t),n)}function ZD(e){return e===null?NaN:+e}const GD=ed(ab),qD=GD.right;ed(ZD).center;const VD=qD;var Hl=Math.sqrt(50),Zl=Math.sqrt(10),Gl=Math.sqrt(2);function ql(e,t,n){var i,r=-1,s,u,f;if(t=+t,e=+e,n=+n,e===t&&n>0)return[e];if((i=t0){let d=Math.round(e/f),p=Math.round(t/f);for(d*ft&&--p,u=new Array(s=p-d+1);++rt&&--p,u=new Array(s=p-d+1);++r=0?(s>=Hl?10:s>=Zl?5:s>=Gl?2:1)*Math.pow(10,r):-Math.pow(10,-r)/(s>=Hl?10:s>=Zl?5:s>=Gl?2:1)}function Vl(e,t,n){var i=Math.abs(t-e)/Math.max(0,n),r=Math.pow(10,Math.floor(Math.log(i)/Math.LN10)),s=i/r;return s>=Hl?r*=10:s>=Zl?r*=5:s>=Gl&&(r*=2),tt&&(n=e,e=t,t=n),function(i){return Math.max(e,Math.min(t,i))}}function tQ(e,t,n){var i=e[0],r=e[1],s=t[0],u=t[1];return r2?nQ:tQ,d=p=null,h}function h(_){return _==null||isNaN(_=+_)?s:(d||(d=f(e.map(i),t,n)))(i(u(_)))}return h.invert=function(_){return u(r((p||(p=f(t,e.map(i),mr)))(_)))},h.domain=function(_){return arguments.length?(e=Array.from(_,JD),m()):e.slice()},h.range=function(_){return arguments.length?(t=Array.from(_),m()):t.slice()},h.rangeRound=function(_){return t=Array.from(_),n=DD,m()},h.clamp=function(_){return arguments.length?(u=_?!0:M6,m()):u!==M6},h.interpolate=function(_){return arguments.length?(n=_,m()):n},h.unknown=function(_){return arguments.length?(s=_,h):s},function(_,S){return i=_,r=S,m()}}function cb(){return nd()(M6,M6)}function iQ(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function _r(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,i=e.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function Y6(e){return e=_r(Math.abs(e)),e?e[1]:NaN}function rQ(e,t){return function(n,i){for(var r=n.length,s=[],u=0,f=e[0],d=0;r>0&&f>0&&(d+f+1>i&&(f=Math.max(1,i-d)),s.push(n.substring(r-=f,r+f)),!((d+=f+1)>i));)f=e[u=(u+1)%e.length];return s.reverse().join(t)}}function oQ(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var sQ=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function vr(e){if(!(t=sQ.exec(e)))throw new Error("invalid format: "+e);var t;return new id({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]})}vr.prototype=id.prototype;function id(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+""}id.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 aQ(e){e:for(var t=e.length,n=1,i=-1,r;n0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(r+1):e}var fb;function uQ(e,t){var n=_r(e,t);if(!n)return e+"";var i=n[0],r=n[1],s=r-(fb=Math.max(-8,Math.min(8,Math.floor(r/3)))*3)+1,u=i.length;return s===u?i:s>u?i+new Array(s-u+1).join("0"):s>0?i.slice(0,s)+"."+i.slice(s):"0."+new Array(1-s).join("0")+_r(e,Math.max(0,t+s-1))[0]}function Lm(e,t){var n=_r(e,t);if(!n)return e+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")}const Fm={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:iQ,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)=>Lm(e*100,t),r:Lm,s:uQ,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Im(e){return e}var Rm=Array.prototype.map,Um=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function lQ(e){var t=e.grouping===void 0||e.thousands===void 0?Im:rQ(Rm.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",r=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?Im:oQ(Rm.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",f=e.minus===void 0?"−":e.minus+"",d=e.nan===void 0?"NaN":e.nan+"";function p(h){h=vr(h);var _=h.fill,S=h.align,E=h.sign,k=h.symbol,O=h.zero,x=h.width,w=h.comma,b=h.precision,N=h.trim,B=h.type;B==="n"?(w=!0,B="g"):Fm[B]||(b===void 0&&(b=12),N=!0,B="g"),(O||_==="0"&&S==="=")&&(O=!0,_="0",S="=");var R=k==="$"?n:k==="#"&&/[boxX]/.test(B)?"0"+B.toLowerCase():"",j=k==="$"?i:/[%p]/.test(B)?u:"",$=Fm[B],K=/[defgprs%]/.test(B);b=b===void 0?6:/[gprs]/.test(B)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function H(Q){var e1=R,X=j,o1,n1,l1;if(B==="c")X=$(Q)+X,Q="";else{Q=+Q;var r1=Q<0||1/Q<0;if(Q=isNaN(Q)?d:$(Math.abs(Q),b),N&&(Q=aQ(Q)),r1&&+Q==0&&E!=="+"&&(r1=!1),e1=(r1?E==="("?E:f:E==="-"||E==="("?"":E)+e1,X=(B==="s"?Um[8+fb/3]:"")+X+(r1&&E==="("?")":""),K){for(o1=-1,n1=Q.length;++o1l1||l1>57){X=(l1===46?r+Q.slice(o1+1):Q.slice(o1))+X,Q=Q.slice(0,o1);break}}}w&&!O&&(Q=t(Q,1/0));var Y=e1.length+Q.length+X.length,g1=Y>1)+e1+Q+X+g1.slice(Y);break;default:Q=g1+e1+Q+X;break}return s(Q)}return H.toString=function(){return h+""},H}function m(h,_){var S=p((h=vr(h),h.type="f",h)),E=Math.max(-8,Math.min(8,Math.floor(Y6(_)/3)))*3,k=Math.pow(10,-E),O=Um[8+E/3];return function(x){return S(k*x)+O}}return{format:p,formatPrefix:m}}var e8,rd,db;cQ({thousands:",",grouping:[3],currency:["$",""]});function cQ(e){return e8=lQ(e),rd=e8.format,db=e8.formatPrefix,e8}function fQ(e){return Math.max(0,-Y6(Math.abs(e)))}function dQ(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Y6(t)/3)))*3-Y6(Math.abs(e)))}function hQ(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Y6(t)-Y6(e))+1}function pQ(e,t,n,i){var r=Vl(e,t,n),s;switch(i=vr(i??",f"),i.type){case"s":{var u=Math.max(Math.abs(e),Math.abs(t));return i.precision==null&&!isNaN(s=dQ(r,u))&&(i.precision=s),db(i,u)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(s=hQ(r,Math.max(Math.abs(e),Math.abs(t))))&&(i.precision=s-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(s=fQ(r))&&(i.precision=s-(i.type==="%")*2);break}}return rd(i)}function hb(e){var t=e.domain;return e.ticks=function(n){var i=t();return ql(i[0],i[i.length-1],n??10)},e.tickFormat=function(n,i){var r=t();return pQ(r[0],r[r.length-1],n??10,i)},e.nice=function(n){n==null&&(n=10);var i=t(),r=0,s=i.length-1,u=i[r],f=i[s],d,p,m=10;for(f0;){if(p=ub(u,f,n),p===d)return i[r]=u,i[s]=f,t(i);if(p>0)u=Math.floor(u/p)*p,f=Math.ceil(f/p)*p;else if(p<0)u=Math.ceil(u*p)/p,f=Math.floor(f*p)/p;else break;d=p}return e},e}function pb(){var e=cb();return e.copy=function(){return Mo(e,pb())},b5.apply(e,arguments),hb(e)}function gb(e,t){e=e.slice();var n=0,i=e.length-1,r=e[n],s=e[i],u;return s0){for(;_<=S;++_)for(k=1,E=s(_);km)break;w.push(O)}}else for(;_<=S;++_)for(k=i-1,E=s(_);k>=1;--k)if(O=E*k,!(Om)break;w.push(O)}w.length*20))return d;do d.push(p=new Date(+s)),t(s,f),e(s);while(p=u)for(;e(u),!s(u);)u.setTime(u-1)},function(u,f){if(u>=u)if(f<0)for(;++f<=0;)for(;t(u,-1),!s(u););else for(;--f>=0;)for(;t(u,1),!s(u););})},n&&(r.count=function(s,u){return hu.setTime(+s),pu.setTime(+u),e(hu),e(pu),Math.floor(n(hu,pu))},r.every=function(s){return s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?r.filter(i?function(u){return i(u)%s===0}:function(u){return r.count(0,u)%s===0}):r}),r}var wr=pt(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});wr.every=function(e){return e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?pt(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):wr};const bQ=wr;wr.range;const l3=1e3,z4=l3*60,c3=z4*60,g5=c3*24,od=g5*7,Qm=g5*30,gu=g5*365;var _b=pt(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+t*l3)},function(e,t){return(t-e)/l3},function(e){return e.getUTCSeconds()});const A6=_b;_b.range;var vb=pt(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*l3)},function(e,t){e.setTime(+e+t*z4)},function(e,t){return(t-e)/z4},function(e){return e.getMinutes()});const wb=vb;vb.range;var xb=pt(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*l3-e.getMinutes()*z4)},function(e,t){e.setTime(+e+t*c3)},function(e,t){return(t-e)/c3},function(e){return e.getHours()});const bb=xb;xb.range;var Sb=pt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*z4)/g5,e=>e.getDate()-1);const Ao=Sb;Sb.range;function S5(e){return pt(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(t,n){t.setDate(t.getDate()+n*7)},function(t,n){return(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*z4)/od})}var ko=S5(0),xr=S5(1),SQ=S5(2),EQ=S5(3),X6=S5(4),MQ=S5(5),AQ=S5(6);ko.range;xr.range;SQ.range;EQ.range;X6.range;MQ.range;AQ.range;var Eb=pt(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12},function(e){return e.getMonth()});const Mb=Eb;Eb.range;var sd=pt(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()});sd.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:pt(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)})};const m5=sd;sd.range;var Ab=pt(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*z4)},function(e,t){return(t-e)/z4},function(e){return e.getUTCMinutes()});const kb=Ab;Ab.range;var Tb=pt(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+t*c3)},function(e,t){return(t-e)/c3},function(e){return e.getUTCHours()});const Pb=Tb;Tb.range;var Cb=pt(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/g5},function(e){return e.getUTCDate()-1});const To=Cb;Cb.range;function E5(e){return pt(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCDate(t.getUTCDate()+n*7)},function(t,n){return(n-t)/od})}var Po=E5(0),br=E5(1),kQ=E5(2),TQ=E5(3),K6=E5(4),PQ=E5(5),CQ=E5(6);Po.range;br.range;kQ.range;TQ.range;K6.range;PQ.range;CQ.range;var Nb=pt(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12},function(e){return e.getUTCMonth()});const Ob=Nb;Nb.range;var ad=pt(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()});ad.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:pt(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})};const y5=ad;ad.range;function Lb(e,t,n,i,r,s){const u=[[A6,1,l3],[A6,5,5*l3],[A6,15,15*l3],[A6,30,30*l3],[s,1,z4],[s,5,5*z4],[s,15,15*z4],[s,30,30*z4],[r,1,c3],[r,3,3*c3],[r,6,6*c3],[r,12,12*c3],[i,1,g5],[i,2,2*g5],[n,1,od],[t,1,Qm],[t,3,3*Qm],[e,1,gu]];function f(p,m,h){const _=mO).right(u,_);if(S===u.length)return e.every(Vl(p/gu,m/gu,h));if(S===0)return bQ.every(Math.max(Vl(p,m,h),1));const[E,k]=u[_/u[S-1][2]53)return null;"w"in p1||(p1.w=1),"Z"in p1?(D1=yu(c7(p1.y,0,1)),se=D1.getUTCDay(),D1=se>4||se===0?br.ceil(D1):br(D1),D1=To.offset(D1,(p1.V-1)*7),p1.y=D1.getUTCFullYear(),p1.m=D1.getUTCMonth(),p1.d=D1.getUTCDate()+(p1.w+6)%7):(D1=mu(c7(p1.y,0,1)),se=D1.getDay(),D1=se>4||se===0?xr.ceil(D1):xr(D1),D1=Ao.offset(D1,(p1.V-1)*7),p1.y=D1.getFullYear(),p1.m=D1.getMonth(),p1.d=D1.getDate()+(p1.w+6)%7)}else("W"in p1||"U"in p1)&&("w"in p1||(p1.w="u"in p1?p1.u%7:"W"in p1?1:0),se="Z"in p1?yu(c7(p1.y,0,1)).getUTCDay():mu(c7(p1.y,0,1)).getDay(),p1.m=0,p1.d="W"in p1?(p1.w+6)%7+p1.W*7-(se+5)%7:p1.w+p1.U*7-(se+6)%7);return"Z"in p1?(p1.H+=p1.Z/100|0,p1.M+=p1.Z%100,yu(p1)):mu(p1)}}function $(E1,L1,R1,p1){for(var J1=0,D1=L1.length,se=R1.length,we,pe;J1=se)return-1;if(we=L1.charCodeAt(J1++),we===37){if(we=L1.charAt(J1++),pe=B[we in Wm?L1.charAt(J1++):we],!pe||(p1=pe(E1,R1,p1))<0)return-1}else if(we!=R1.charCodeAt(p1++))return-1}return p1}function K(E1,L1,R1){var p1=p.exec(L1.slice(R1));return p1?(E1.p=m.get(p1[0].toLowerCase()),R1+p1[0].length):-1}function H(E1,L1,R1){var p1=S.exec(L1.slice(R1));return p1?(E1.w=E.get(p1[0].toLowerCase()),R1+p1[0].length):-1}function Q(E1,L1,R1){var p1=h.exec(L1.slice(R1));return p1?(E1.w=_.get(p1[0].toLowerCase()),R1+p1[0].length):-1}function e1(E1,L1,R1){var p1=x.exec(L1.slice(R1));return p1?(E1.m=w.get(p1[0].toLowerCase()),R1+p1[0].length):-1}function X(E1,L1,R1){var p1=k.exec(L1.slice(R1));return p1?(E1.m=O.get(p1[0].toLowerCase()),R1+p1[0].length):-1}function o1(E1,L1,R1){return $(E1,t,L1,R1)}function n1(E1,L1,R1){return $(E1,n,L1,R1)}function l1(E1,L1,R1){return $(E1,i,L1,R1)}function r1(E1){return u[E1.getDay()]}function Y(E1){return s[E1.getDay()]}function g1(E1){return d[E1.getMonth()]}function f1(E1){return f[E1.getMonth()]}function w1(E1){return r[+(E1.getHours()>=12)]}function k1(E1){return 1+~~(E1.getMonth()/3)}function U1(E1){return u[E1.getUTCDay()]}function O1(E1){return s[E1.getUTCDay()]}function v1(E1){return d[E1.getUTCMonth()]}function d1(E1){return f[E1.getUTCMonth()]}function I1(E1){return r[+(E1.getUTCHours()>=12)]}function W1(E1){return 1+~~(E1.getUTCMonth()/3)}return{format:function(E1){var L1=R(E1+="",b);return L1.toString=function(){return E1},L1},parse:function(E1){var L1=j(E1+="",!1);return L1.toString=function(){return E1},L1},utcFormat:function(E1){var L1=R(E1+="",N);return L1.toString=function(){return E1},L1},utcParse:function(E1){var L1=j(E1+="",!0);return L1.toString=function(){return E1},L1}}}var Wm={"-":"",_:" ",0:"0"},gt=/^\s*\d+/,RQ=/^%/,UQ=/[\\^$*+?|[\]().{}]/g;function Me(e,t,n){var i=e<0?"-":"",r=(i?-e:e)+"",s=r.length;return i+(s[t.toLowerCase(),n]))}function BQ(e,t,n){var i=gt.exec(t.slice(n,n+1));return i?(e.w=+i[0],n+i[0].length):-1}function zQ(e,t,n){var i=gt.exec(t.slice(n,n+1));return i?(e.u=+i[0],n+i[0].length):-1}function jQ(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.U=+i[0],n+i[0].length):-1}function DQ(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.V=+i[0],n+i[0].length):-1}function QQ(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.W=+i[0],n+i[0].length):-1}function Hm(e,t,n){var i=gt.exec(t.slice(n,n+4));return i?(e.y=+i[0],n+i[0].length):-1}function Zm(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function WQ(e,t,n){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return i?(e.Z=i[1]?0:-(i[2]+(i[3]||"00")),n+i[0].length):-1}function HQ(e,t,n){var i=gt.exec(t.slice(n,n+1));return i?(e.q=i[0]*3-3,n+i[0].length):-1}function ZQ(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.m=i[0]-1,n+i[0].length):-1}function Gm(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.d=+i[0],n+i[0].length):-1}function GQ(e,t,n){var i=gt.exec(t.slice(n,n+3));return i?(e.m=0,e.d=+i[0],n+i[0].length):-1}function qm(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.H=+i[0],n+i[0].length):-1}function qQ(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.M=+i[0],n+i[0].length):-1}function VQ(e,t,n){var i=gt.exec(t.slice(n,n+2));return i?(e.S=+i[0],n+i[0].length):-1}function YQ(e,t,n){var i=gt.exec(t.slice(n,n+3));return i?(e.L=+i[0],n+i[0].length):-1}function XQ(e,t,n){var i=gt.exec(t.slice(n,n+6));return i?(e.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function KQ(e,t,n){var i=RQ.exec(t.slice(n,n+1));return i?n+i[0].length:-1}function JQ(e,t,n){var i=gt.exec(t.slice(n));return i?(e.Q=+i[0],n+i[0].length):-1}function eW(e,t,n){var i=gt.exec(t.slice(n));return i?(e.s=+i[0],n+i[0].length):-1}function Vm(e,t){return Me(e.getDate(),t,2)}function tW(e,t){return Me(e.getHours(),t,2)}function nW(e,t){return Me(e.getHours()%12||12,t,2)}function iW(e,t){return Me(1+Ao.count(m5(e),e),t,3)}function Fb(e,t){return Me(e.getMilliseconds(),t,3)}function rW(e,t){return Fb(e,t)+"000"}function oW(e,t){return Me(e.getMonth()+1,t,2)}function sW(e,t){return Me(e.getMinutes(),t,2)}function aW(e,t){return Me(e.getSeconds(),t,2)}function uW(e){var t=e.getDay();return t===0?7:t}function lW(e,t){return Me(ko.count(m5(e)-1,e),t,2)}function Ib(e){var t=e.getDay();return t>=4||t===0?X6(e):X6.ceil(e)}function cW(e,t){return e=Ib(e),Me(X6.count(m5(e),e)+(m5(e).getDay()===4),t,2)}function fW(e){return e.getDay()}function dW(e,t){return Me(xr.count(m5(e)-1,e),t,2)}function hW(e,t){return Me(e.getFullYear()%100,t,2)}function pW(e,t){return e=Ib(e),Me(e.getFullYear()%100,t,2)}function gW(e,t){return Me(e.getFullYear()%1e4,t,4)}function mW(e,t){var n=e.getDay();return e=n>=4||n===0?X6(e):X6.ceil(e),Me(e.getFullYear()%1e4,t,4)}function yW(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Me(t/60|0,"0",2)+Me(t%60,"0",2)}function Ym(e,t){return Me(e.getUTCDate(),t,2)}function _W(e,t){return Me(e.getUTCHours(),t,2)}function vW(e,t){return Me(e.getUTCHours()%12||12,t,2)}function wW(e,t){return Me(1+To.count(y5(e),e),t,3)}function Rb(e,t){return Me(e.getUTCMilliseconds(),t,3)}function xW(e,t){return Rb(e,t)+"000"}function bW(e,t){return Me(e.getUTCMonth()+1,t,2)}function SW(e,t){return Me(e.getUTCMinutes(),t,2)}function EW(e,t){return Me(e.getUTCSeconds(),t,2)}function MW(e){var t=e.getUTCDay();return t===0?7:t}function AW(e,t){return Me(Po.count(y5(e)-1,e),t,2)}function Ub(e){var t=e.getUTCDay();return t>=4||t===0?K6(e):K6.ceil(e)}function kW(e,t){return e=Ub(e),Me(K6.count(y5(e),e)+(y5(e).getUTCDay()===4),t,2)}function TW(e){return e.getUTCDay()}function PW(e,t){return Me(br.count(y5(e)-1,e),t,2)}function CW(e,t){return Me(e.getUTCFullYear()%100,t,2)}function NW(e,t){return e=Ub(e),Me(e.getUTCFullYear()%100,t,2)}function OW(e,t){return Me(e.getUTCFullYear()%1e4,t,4)}function LW(e,t){var n=e.getUTCDay();return e=n>=4||n===0?K6(e):K6.ceil(e),Me(e.getUTCFullYear()%1e4,t,4)}function FW(){return"+0000"}function Xm(){return"%"}function Km(e){return+e}function Jm(e){return Math.floor(+e/1e3)}var s6,Co,$b,Bb,zb;IW({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 IW(e){return s6=IQ(e),Co=s6.format,$b=s6.parse,Bb=s6.utcFormat,zb=s6.utcParse,s6}function RW(e){return new Date(e)}function UW(e){return e instanceof Date?+e:+new Date(+e)}function ud(e,t,n,i,r,s,u,f,d,p){var m=cb(),h=m.invert,_=m.domain,S=p(".%L"),E=p(":%S"),k=p("%I:%M"),O=p("%I %p"),x=p("%a %d"),w=p("%b %d"),b=p("%B"),N=p("%Y");function B(R){return(d(R)FD(e[e.length-1]);var No=new Array(3).concat("d8b365f5f5f55ab4ac","a6611adfc27d80cdc1018571","a6611adfc27df5f5f580cdc1018571","8c510ad8b365f6e8c3c7eae55ab4ac01665e","8c510ad8b365f6e8c3f5f5f5c7eae55ab4ac01665e","8c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e","8c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e","5430058c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e003c30","5430058c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e003c30").map(ue);const zW=Ne(No);var Oo=new Array(3).concat("af8dc3f7f7f77fbf7b","7b3294c2a5cfa6dba0008837","7b3294c2a5cff7f7f7a6dba0008837","762a83af8dc3e7d4e8d9f0d37fbf7b1b7837","762a83af8dc3e7d4e8f7f7f7d9f0d37fbf7b1b7837","762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b7837","762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b7837","40004b762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b783700441b","40004b762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b783700441b").map(ue);const jW=Ne(Oo);var Lo=new Array(3).concat("e9a3c9f7f7f7a1d76a","d01c8bf1b6dab8e1864dac26","d01c8bf1b6daf7f7f7b8e1864dac26","c51b7de9a3c9fde0efe6f5d0a1d76a4d9221","c51b7de9a3c9fde0eff7f7f7e6f5d0a1d76a4d9221","c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221","c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221","8e0152c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221276419","8e0152c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221276419").map(ue);const DW=Ne(Lo);var Fo=new Array(3).concat("998ec3f7f7f7f1a340","5e3c99b2abd2fdb863e66101","5e3c99b2abd2f7f7f7fdb863e66101","542788998ec3d8daebfee0b6f1a340b35806","542788998ec3d8daebf7f7f7fee0b6f1a340b35806","5427888073acb2abd2d8daebfee0b6fdb863e08214b35806","5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b35806","2d004b5427888073acb2abd2d8daebfee0b6fdb863e08214b358067f3b08","2d004b5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b358067f3b08").map(ue);const QW=Ne(Fo);var Io=new Array(3).concat("ef8a62f7f7f767a9cf","ca0020f4a58292c5de0571b0","ca0020f4a582f7f7f792c5de0571b0","b2182bef8a62fddbc7d1e5f067a9cf2166ac","b2182bef8a62fddbc7f7f7f7d1e5f067a9cf2166ac","b2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac","b2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac","67001fb2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac053061","67001fb2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac053061").map(ue);const WW=Ne(Io);var Ro=new Array(3).concat("ef8a62ffffff999999","ca0020f4a582bababa404040","ca0020f4a582ffffffbababa404040","b2182bef8a62fddbc7e0e0e09999994d4d4d","b2182bef8a62fddbc7ffffffe0e0e09999994d4d4d","b2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d","b2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d","67001fb2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d1a1a1a","67001fb2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d1a1a1a").map(ue);const HW=Ne(Ro);var Uo=new Array(3).concat("fc8d59ffffbf91bfdb","d7191cfdae61abd9e92c7bb6","d7191cfdae61ffffbfabd9e92c7bb6","d73027fc8d59fee090e0f3f891bfdb4575b4","d73027fc8d59fee090ffffbfe0f3f891bfdb4575b4","d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4","d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4","a50026d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4313695","a50026d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4313695").map(ue);const ZW=Ne(Uo);var $o=new Array(3).concat("fc8d59ffffbf91cf60","d7191cfdae61a6d96a1a9641","d7191cfdae61ffffbfa6d96a1a9641","d73027fc8d59fee08bd9ef8b91cf601a9850","d73027fc8d59fee08bffffbfd9ef8b91cf601a9850","d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850","d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850","a50026d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850006837","a50026d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850006837").map(ue);const GW=Ne($o);var Bo=new Array(3).concat("fc8d59ffffbf99d594","d7191cfdae61abdda42b83ba","d7191cfdae61ffffbfabdda42b83ba","d53e4ffc8d59fee08be6f59899d5943288bd","d53e4ffc8d59fee08bffffbfe6f59899d5943288bd","d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd","d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd","9e0142d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd5e4fa2","9e0142d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd5e4fa2").map(ue);const qW=Ne(Bo);var zo=new Array(3).concat("e5f5f999d8c92ca25f","edf8fbb2e2e266c2a4238b45","edf8fbb2e2e266c2a42ca25f006d2c","edf8fbccece699d8c966c2a42ca25f006d2c","edf8fbccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45006d2c00441b").map(ue);const VW=Ne(zo);var jo=new Array(3).concat("e0ecf49ebcda8856a7","edf8fbb3cde38c96c688419d","edf8fbb3cde38c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d810f7c4d004b").map(ue);const YW=Ne(jo);var Do=new Array(3).concat("e0f3dba8ddb543a2ca","f0f9e8bae4bc7bccc42b8cbe","f0f9e8bae4bc7bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe0868ac084081").map(ue);const XW=Ne(Do);var Qo=new Array(3).concat("fee8c8fdbb84e34a33","fef0d9fdcc8afc8d59d7301f","fef0d9fdcc8afc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301fb300007f0000").map(ue);const KW=Ne(Qo);var Wo=new Array(3).concat("ece2f0a6bddb1c9099","f6eff7bdc9e167a9cf02818a","f6eff7bdc9e167a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016c59014636").map(ue);const JW=Ne(Wo);var Ho=new Array(3).concat("ece7f2a6bddb2b8cbe","f1eef6bdc9e174a9cf0570b0","f1eef6bdc9e174a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0045a8d023858").map(ue);const eH=Ne(Ho);var Zo=new Array(3).concat("e7e1efc994c7dd1c77","f1eef6d7b5d8df65b0ce1256","f1eef6d7b5d8df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125698004367001f").map(ue);const tH=Ne(Zo);var Go=new Array(3).concat("fde0ddfa9fb5c51b8a","feebe2fbb4b9f768a1ae017e","feebe2fbb4b9f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a017749006a").map(ue);const nH=Ne(Go);var qo=new Array(3).concat("edf8b17fcdbb2c7fb8","ffffcca1dab441b6c4225ea8","ffffcca1dab441b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea8253494081d58").map(ue);const iH=Ne(qo);var Vo=new Array(3).concat("f7fcb9addd8e31a354","ffffccc2e69978c679238443","ffffccc2e69978c67931a354006837","ffffccd9f0a3addd8e78c67931a354006837","ffffccd9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443006837004529").map(ue);const rH=Ne(Vo);var Yo=new Array(3).concat("fff7bcfec44fd95f0e","ffffd4fed98efe9929cc4c02","ffffd4fed98efe9929d95f0e993404","ffffd4fee391fec44ffe9929d95f0e993404","ffffd4fee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c02993404662506").map(ue);const oH=Ne(Yo);var Xo=new Array(3).concat("ffeda0feb24cf03b20","ffffb2fecc5cfd8d3ce31a1c","ffffb2fecc5cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cbd0026800026").map(ue);const sH=Ne(Xo);var Ko=new Array(3).concat("deebf79ecae13182bd","eff3ffbdd7e76baed62171b5","eff3ffbdd7e76baed63182bd08519c","eff3ffc6dbef9ecae16baed63182bd08519c","eff3ffc6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b508519c08306b").map(ue);const aH=Ne(Ko);var Jo=new Array(3).concat("e5f5e0a1d99b31a354","edf8e9bae4b374c476238b45","edf8e9bae4b374c47631a354006d2c","edf8e9c7e9c0a1d99b74c47631a354006d2c","edf8e9c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45006d2c00441b").map(ue);const uH=Ne(Jo);var es=new Array(3).concat("f0f0f0bdbdbd636363","f7f7f7cccccc969696525252","f7f7f7cccccc969696636363252525","f7f7f7d9d9d9bdbdbd969696636363252525","f7f7f7d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525000000").map(ue);const lH=Ne(es);var ts=new Array(3).concat("efedf5bcbddc756bb1","f2f0f7cbc9e29e9ac86a51a3","f2f0f7cbc9e29e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a354278f3f007d").map(ue);const cH=Ne(ts);var ns=new Array(3).concat("fee0d2fc9272de2d26","fee5d9fcae91fb6a4acb181d","fee5d9fcae91fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181da50f1567000d").map(ue);const fH=Ne(ns);var is=new Array(3).concat("fee6cefdae6be6550d","feeddefdbe85fd8d3cd94701","feeddefdbe85fd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d94801a636037f2704").map(ue);const dH=Ne(is);function hH(e){return e=Math.max(0,Math.min(1,e)),"rgb("+Math.max(0,Math.min(255,Math.round(-4.54-e*(35.34-e*(2381.73-e*(6402.7-e*(7024.72-e*2710.57)))))))+", "+Math.max(0,Math.min(255,Math.round(32.49+e*(170.73+e*(52.82-e*(131.46-e*(176.58-e*67.37)))))))+", "+Math.max(0,Math.min(255,Math.round(81.24+e*(442.36-e*(2482.43-e*(6167.24-e*(6614.94-e*2475.67)))))))+")"}const pH=Jf(U2(300,.5,0),U2(-240,.5,1));var gH=Jf(U2(-100,.75,.35),U2(80,1.5,.8)),mH=Jf(U2(260,.75,.35),U2(80,1.5,.8)),t8=U2();function yH(e){(e<0||e>1)&&(e-=Math.floor(e));var t=Math.abs(e-.5);return t8.h=360*e-100,t8.s=1.5-1.5*t,t8.l=.8-.9*t,t8+""}var n8=c9(),_H=Math.PI/3,vH=Math.PI*2/3;function wH(e){var t;return e=(.5-e)*Math.PI,n8.r=255*(t=Math.sin(e))*t,n8.g=255*(t=Math.sin(e+_H))*t,n8.b=255*(t=Math.sin(e+vH))*t,n8+""}function xH(e){return e=Math.max(0,Math.min(1,e)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+e*(1172.33-e*(10793.56-e*(33300.12-e*(38394.49-e*14825.05)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+e*(557.33+e*(1225.33-e*(3574.96-e*(1073.77+e*707.56)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+e*(3211.1-e*(15327.97-e*(27814-e*(22569.18-e*6838.66)))))))+")"}function rs(e){var t=e.length;return function(n){return e[Math.max(0,Math.min(t-1,Math.floor(n*t)))]}}const bH=rs(ue("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725"));var SH=rs(ue("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),EH=rs(ue("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),MH=rs(ue("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921")),AH="__lodash_hash_undefined__";function kH(e){return this.__data__.set(e,AH),this}var TH=kH;function PH(e){return this.__data__.has(e)}var CH=PH,NH=$f,OH=TH,LH=CH;function Sr(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new NH;++t-1}var Vb=ZH;function GH(e,t,n){for(var i=-1,r=e==null?0:e.length;++i=tZ&&(s=eZ,u=!1,t=new VH(t));e:for(;++rDn)if(!(Math.abs(m*f-d*p)>Dn)||!r)this._+="L"+(this._x1=e)+","+(this._y1=t);else{var _=n-s,S=i-u,E=f*f+d*d,k=_*_+S*S,O=Math.sqrt(E),x=Math.sqrt(h),w=r*Math.tan((Xl-Math.acos((E+h-k)/(2*O*x)))/2),b=w/x,N=w/O;Math.abs(b-1)>Dn&&(this._+="L"+(e+b*p)+","+(t+b*m)),this._+="A"+r+","+r+",0,0,"+ +(m*_>p*S)+","+(this._x1=e+N*f)+","+(this._y1=t+N*d)}},arc:function(e,t,n,i,r,s){e=+e,t=+t,n=+n,s=!!s;var u=n*Math.cos(i),f=n*Math.sin(i),d=e+u,p=t+f,m=1^s,h=s?i-r:r-i;if(n<0)throw new Error("negative radius: "+n);this._x1===null?this._+="M"+d+","+p:(Math.abs(this._x1-d)>Dn||Math.abs(this._y1-p)>Dn)&&(this._+="L"+d+","+p),n&&(h<0&&(h=h%Kl+Kl),h>lZ?this._+="A"+n+","+n+",0,1,"+m+","+(e-u)+","+(t-f)+"A"+n+","+n+",0,1,"+m+","+(this._x1=d)+","+(this._y1=p):h>Dn&&(this._+="A"+n+","+n+",0,"+ +(h>=Xl)+","+m+","+(this._x1=e+n*Math.cos(r))+","+(this._y1=t+n*Math.sin(r))))},rect:function(e,t,n,i){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +i+"h"+-n+"Z"},toString:function(){return this._}};function g4(e){return function(){return e}}var ey=1e-12;function Kb(e){this._context=e}Kb.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 hd(e){return new Kb(e)}function Jb(e){return e[0]}function eS(e){return e[1]}function tS(){var e=Jb,t=eS,n=g4(!0),i=null,r=hd,s=null;function u(f){var d,p=f.length,m,h=!1,_;for(i==null&&(s=r(_=dd())),d=0;d<=p;++d)!(d=_;--S)f.point(w[S],b[S]);f.lineEnd(),f.areaEnd()}O&&(w[h]=+e(k,h,m),b[h]=+n(k,h,m),f.point(t?+t(k,h,m):w[h],i?+i(k,h,m):b[h]))}if(x)return f=null,x+""||null}function p(){return tS().defined(r).curve(u).context(s)}return d.x=function(m){return arguments.length?(e=typeof m=="function"?m:g4(+m),t=null,d):e},d.x0=function(m){return arguments.length?(e=typeof m=="function"?m:g4(+m),d):e},d.x1=function(m){return arguments.length?(t=m==null?null:typeof m=="function"?m:g4(+m),d):t},d.y=function(m){return arguments.length?(n=typeof m=="function"?m:g4(+m),i=null,d):n},d.y0=function(m){return arguments.length?(n=typeof m=="function"?m:g4(+m),d):n},d.y1=function(m){return arguments.length?(i=m==null?null:typeof m=="function"?m:g4(+m),d):i},d.lineX0=d.lineY0=function(){return p().x(e).y(n)},d.lineY1=function(){return p().x(e).y(i)},d.lineX1=function(){return p().x(t).y(n)},d.defined=function(m){return arguments.length?(r=typeof m=="function"?m:g4(!!m),d):r},d.curve=function(m){return arguments.length?(u=m,s!=null&&(f=u(s)),d):u},d.context=function(m){return arguments.length?(m==null?s=f=null:f=u(s=m),d):s},d}function rn(){}function Er(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 os(e){this._context=e}os.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:Er(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:Er(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function fZ(e){return new os(e)}function nS(e){this._context=e}nS.prototype={areaStart:rn,areaEnd:rn,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:Er(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function dZ(e){return new nS(e)}function iS(e){this._context=e}iS.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,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,i):this._context.moveTo(n,i);break;case 3:this._point=4;default:Er(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function hZ(e){return new iS(e)}function rS(e,t){this._basis=new os(e),this._beta=t}rS.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var i=e[0],r=t[0],s=e[n]-i,u=t[n]-r,f=-1,d;++f<=n;)d=f/n,this._basis.point(this._beta*e[f]+(1-this._beta)*(i+d*s),this._beta*t[f]+(1-this._beta)*(r+d*u));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const pZ=function e(t){function n(i){return t===1?new os(i):new rS(i,t)}return n.beta=function(i){return e(+i)},n}(.85);function Mr(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function pd(e,t){this._context=e,this._k=(1-t)/6}pd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Mr(this,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,this._x1=e,this._y1=t;break;case 2:this._point=3;default:Mr(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const gZ=function e(t){function n(i){return new pd(i,t)}return n.tension=function(i){return e(+i)},n}(0);function gd(e,t){this._context=e,this._k=(1-t)/6}gd.prototype={areaStart:rn,areaEnd:rn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Mr(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const mZ=function e(t){function n(i){return new gd(i,t)}return n.tension=function(i){return e(+i)},n}(0);function md(e,t){this._context=e,this._k=(1-t)/6}md.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=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,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Mr(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const yZ=function e(t){function n(i){return new md(i,t)}return n.tension=function(i){return e(+i)},n}(0);function yd(e,t,n){var i=e._x1,r=e._y1,s=e._x2,u=e._y2;if(e._l01_a>ey){var f=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,d=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*f-e._x0*e._l12_2a+e._x2*e._l01_2a)/d,r=(r*f-e._y0*e._l12_2a+e._y2*e._l01_2a)/d}if(e._l23_a>ey){var p=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,m=3*e._l23_a*(e._l23_a+e._l12_a);s=(s*p+e._x1*e._l23_2a-t*e._l12_2a)/m,u=(u*p+e._y1*e._l23_2a-n*e._l12_2a)/m}e._context.bezierCurveTo(i,r,s,u,e._x2,e._y2)}function oS(e,t){this._context=e,this._alpha=t}oS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}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;default:yd(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const _Z=function e(t){function n(i){return t?new oS(i,t):new pd(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function sS(e,t){this._context=e,this._alpha=t}sS.prototype={areaStart:rn,areaEnd:rn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:yd(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const vZ=function e(t){function n(i){return t?new sS(i,t):new gd(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function aS(e,t){this._context=e,this._alpha=t}aS.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=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){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:yd(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const wZ=function e(t){function n(i){return t?new aS(i,t):new md(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function uS(e){this._context=e}uS.prototype={areaStart:rn,areaEnd:rn,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 xZ(e){return new uS(e)}function ty(e){return e<0?-1:1}function ny(e,t,n){var i=e._x1-e._x0,r=t-e._x1,s=(e._y1-e._y0)/(i||r<0&&-0),u=(n-e._y1)/(r||i<0&&-0),f=(s*r+u*i)/(i+r);return(ty(s)+ty(u))*Math.min(Math.abs(s),Math.abs(u),.5*Math.abs(f))||0}function iy(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function _u(e,t,n){var i=e._x0,r=e._y0,s=e._x1,u=e._y1,f=(s-i)/3;e._context.bezierCurveTo(i+f,r+f*t,s-f,u-f*n,s,u)}function Ar(e){this._context=e}Ar.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:_u(this,this._t0,iy(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,_u(this,iy(this,n=ny(this,e,t)),n);break;default:_u(this,this._t0,n=ny(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function lS(e){this._context=new cS(e)}(lS.prototype=Object.create(Ar.prototype)).point=function(e,t){Ar.prototype.point.call(this,t,e)};function cS(e){this._context=e}cS.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,i,r,s){this._context.bezierCurveTo(t,e,i,n,s,r)}};function bZ(e){return new Ar(e)}function SZ(e){return new lS(e)}function fS(e){this._context=e}fS.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 i=ry(e),r=ry(t),s=0,u=1;u=0;--t)r[t]=(u[t]-r[t+1])/s[t];for(s[n-1]=(e[n]+r[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 MZ(e){return new ss(e,.5)}function AZ(e){return new ss(e,0)}function kZ(e){return new ss(e,1)}function as(e,t){if((u=e.length)>1)for(var n=1,i,r,s=e[t[0]],u,f=s.length;n=0;)n[t]=t;return n}function TZ(e,t){if((i=e.length)>0){for(var n,i,r=0,s=e[0].length,u;r0)for(var n,i=0,r,s,u,f,d,p=e[t[0]].length;i0?(r[0]=u,r[1]=u+=s):s<0?(r[1]=f,r[0]=f+=s):(r[0]=0,r[1]=s)}function CZ(e,t){if((r=e.length)>0){for(var n=0,i=e[t[0]],r,s=i.length;n0)||!((s=(r=e[t[0]]).length)>0))){for(var n=0,i=1,r,s,u;is&&(s=r,n=t);return n}function dS(e){var t=e.map(hS);return us(e).sort(function(n,i){return t[n]-t[i]})}function hS(e){for(var t=0,n=-1,i=e.length,r;++n=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function kr(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,i=e.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function $Z(e){return e=kr(Math.abs(e)),e?e[1]:NaN}function BZ(e,t){return function(n,i){for(var r=n.length,s=[],u=0,f=e[0],d=0;r>0&&f>0&&(d+f+1>i&&(f=Math.max(1,i-d)),s.push(n.substring(r-=f,r+f)),!((d+=f+1)>i));)f=e[u=(u+1)%e.length];return s.reverse().join(t)}}function zZ(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var jZ=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ec(e){if(!(t=jZ.exec(e)))throw new Error("invalid format: "+e);var t;return new _d({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]})}ec.prototype=_d.prototype;function _d(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+""}_d.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 DZ(e){e:for(var t=e.length,n=1,i=-1,r;n0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(r+1):e}var pS;function QZ(e,t){var n=kr(e,t);if(!n)return e+"";var i=n[0],r=n[1],s=r-(pS=Math.max(-8,Math.min(8,Math.floor(r/3)))*3)+1,u=i.length;return s===u?i:s>u?i+new Array(s-u+1).join("0"):s>0?i.slice(0,s)+"."+i.slice(s):"0."+new Array(1-s).join("0")+kr(e,Math.max(0,t+s-1))[0]}function oy(e,t){var n=kr(e,t);if(!n)return e+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")}const sy={"%":function(e,t){return(e*100).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:UZ,e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return oy(e*100,t)},r:oy,s:QZ,X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}};function ay(e){return e}var uy=Array.prototype.map,ly=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function WZ(e){var t=e.grouping===void 0||e.thousands===void 0?ay:BZ(uy.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",r=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?ay:zZ(uy.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",f=e.minus===void 0?"-":e.minus+"",d=e.nan===void 0?"NaN":e.nan+"";function p(h){h=ec(h);var _=h.fill,S=h.align,E=h.sign,k=h.symbol,O=h.zero,x=h.width,w=h.comma,b=h.precision,N=h.trim,B=h.type;B==="n"?(w=!0,B="g"):sy[B]||(b===void 0&&(b=12),N=!0,B="g"),(O||_==="0"&&S==="=")&&(O=!0,_="0",S="=");var R=k==="$"?n:k==="#"&&/[boxX]/.test(B)?"0"+B.toLowerCase():"",j=k==="$"?i:/[%p]/.test(B)?u:"",$=sy[B],K=/[defgprs%]/.test(B);b=b===void 0?6:/[gprs]/.test(B)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function H(Q){var e1=R,X=j,o1,n1,l1;if(B==="c")X=$(Q)+X,Q="";else{Q=+Q;var r1=Q<0||1/Q<0;if(Q=isNaN(Q)?d:$(Math.abs(Q),b),N&&(Q=DZ(Q)),r1&&+Q==0&&E!=="+"&&(r1=!1),e1=(r1?E==="("?E:f:E==="-"||E==="("?"":E)+e1,X=(B==="s"?ly[8+pS/3]:"")+X+(r1&&E==="("?")":""),K){for(o1=-1,n1=Q.length;++o1l1||l1>57){X=(l1===46?r+Q.slice(o1+1):Q.slice(o1))+X,Q=Q.slice(0,o1);break}}}w&&!O&&(Q=t(Q,1/0));var Y=e1.length+Q.length+X.length,g1=Y>1)+e1+Q+X+g1.slice(Y);break;default:Q=g1+e1+Q+X;break}return s(Q)}return H.toString=function(){return h+""},H}function m(h,_){var S=p((h=ec(h),h.type="f",h)),E=Math.max(-8,Math.min(8,Math.floor($Z(_)/3)))*3,k=Math.pow(10,-E),O=ly[8+E/3];return function(x){return S(k*x)+O}}return{format:p,formatPrefix:m}}var i8,ls;HZ({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"});function HZ(e){return i8=WZ(e),ls=i8.format,i8.formatPrefix,i8}var ZZ=xo,GZ=eb,qZ=wo;function VZ(e,t,n){for(var i=-1,r=t.length,s={};++i0&&n(f)?t>1?yS(f,t-1,n,i,r):vG(r,f):i||(r[r.length]=f)}return r}var _S=yS,xG=_S;function bG(e){var t=e==null?0:e.length;return t?xG(e,1):[]}var SG=bG,EG=SG,MG=qx,AG=Vx;function kG(e){return AG(MG(e,void 0,EG),e+"")}var TG=kG,PG=hG,CG=TG,NG=CG(function(e,t){return e==null?{}:PG(e,t)}),OG=NG;const LG=Lt(OG);function FG(e,t){for(var n=-1,i=e==null?0:e.length;++nf))return!1;var p=s.get(e),m=s.get(t);if(p&&m)return p==t&&m==e;var h=-1,_=!0,S=n&zG?new RG:void 0;for(s.set(e,t),s.set(t,e);++h=0||(r[n]=e[n]);return r}var on={fill:C.string,fontSize:C.number,fontFamily:C.string},TV=C.shape({domain:C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired}).isRequired,ticks:C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired,text:C.shape(ut({},on)).isRequired}).isRequired,legend:C.shape({text:C.shape(ut({},on)).isRequired}).isRequired}),PV=C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired}),CV=C.shape({hidden:C.shape({symbol:C.shape({fill:C.string.isRequired,opacity:C.number}).isRequired,text:C.shape(ut({},on,{opacity:C.number})).isRequired}).isRequired,text:C.shape(ut({},on)).isRequired}),NV=C.shape({text:C.shape(ut({},on)).isRequired}),OV=C.shape({text:C.shape(ut({},on)).isRequired}),LV=C.shape({text:C.shape(ut({},on)).isRequired}),FV=C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired}),IV=C.shape({text:C.shape(ut({},on,{outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired})).isRequired,link:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired}).isRequired,outline:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired}).isRequired,symbol:C.shape({fill:C.string.isRequired,outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired}).isRequired});C.shape({background:C.string.isRequired,fontFamily:C.string.isRequired,fontSize:C.number.isRequired,textColor:C.string.isRequired,axis:TV.isRequired,grid:PV.isRequired,legends:CV.isRequired,labels:NV.isRequired,dots:OV.isRequired,markers:LV,crosshair:FV.isRequired,annotations:IV.isRequired});var RV={background:"transparent",fontFamily:"sans-serif",fontSize:11,textColor:"#333333",axis:{domain:{line:{stroke:"transparent",strokeWidth:1}},ticks:{line:{stroke:"#777777",strokeWidth:1},text:{}},legend:{text:{fontSize:12}}},grid:{line:{stroke:"#dddddd",strokeWidth:1}},legends:{hidden:{symbol:{fill:"#333333",opacity:.6},text:{fill:"#333333",opacity:.6}},text:{},ticks:{line:{stroke:"#777777",strokeWidth:1},text:{fontSize:10}},title:{text:{}}},labels:{text:{}},markers:{lineColor:"#000000",lineStrokeWidth:1,text:{}},dots:{text:{}},tooltip:{container:{background:"white",color:"inherit",fontSize:"inherit",borderRadius:"2px",boxShadow:"0 1px 2px rgba(0, 0, 0, 0.25)",padding:"5px 9px"},basic:{whiteSpace:"pre",display:"flex",alignItems:"center"},chip:{marginRight:7},table:{},tableCell:{padding:"3px 5px"},tableCellValue:{fontWeight:"bold"}},crosshair:{line:{stroke:"#000000",strokeWidth:1,strokeOpacity:.75,strokeDasharray:"6 6"}},annotations:{text:{fontSize:13,outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1},link:{stroke:"#000000",strokeWidth:1,outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1},outline:{fill:"none",stroke:"#000000",strokeWidth:2,outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1},symbol:{fill:"#000000",outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1}}},UV=["axis.ticks.text","axis.legend.text","legends.title.text","legends.text","legends.ticks.text","legends.title.text","labels.text","dots.text","markers.text","annotations.text"],$V=function(e,t){var n=vj({},e,t);return UV.forEach(function(i){i5(n,i+".fontFamily")===void 0&&Yn(n,i+".fontFamily",n.fontFamily),i5(n,i+".fontSize")===void 0&&Yn(n,i+".fontSize",n.fontSize),i5(n,i+".fill")===void 0&&Yn(n,i+".fill",n.textColor)}),n},SS=G.createContext(),Sd=function(e){var t=e.children,n=e.animate,i=e.config,r=G.useMemo(function(){var s=o5.isString(i)?Lf[i]:i;return{animate:n,config:s}},[n,i]);return F.jsx(SS.Provider,{value:r,children:t})},ac={animate:C.bool,motionConfig:C.oneOfType([C.oneOf(Object.keys(Lf)),C.shape({mass:C.number,tension:C.number,friction:C.number,clamp:C.bool,precision:C.number,velocity:C.number,duration:C.number,easing:C.func})])};Sd.propTypes={children:C.node.isRequired,animate:ac.animate,config:ac.motionConfig};var BV={animate:!0,config:"default"};Sd.defaultProps=BV;var M5=function(){return G.useContext(SS)},ES=function(e){var t=M5(),n=t.animate,i=t.config,r=function(f){var d=G.useRef();return G.useEffect(function(){d.current=f},[f]),d.current}(e),s=G.useMemo(function(){return ob(r,e)},[r,e]),u=r0({from:{value:0},to:{value:1},reset:!0,config:i,immediate:!n}).value;return PF(u,s)},zV={nivo:["#d76445","#f47560","#e8c1a0","#97e3d5","#61cdbb","#00b0a7"],BrBG:z1(No),PRGn:z1(Oo),PiYG:z1(Lo),PuOr:z1(Fo),RdBu:z1(Io),RdGy:z1(Ro),RdYlBu:z1(Uo),RdYlGn:z1($o),spectral:z1(Bo),blues:z1(Ko),greens:z1(Jo),greys:z1(es),oranges:z1(is),purples:z1(ts),reds:z1(ns),BuGn:z1(zo),BuPu:z1(jo),GnBu:z1(Do),OrRd:z1(Qo),PuBuGn:z1(Wo),PuBu:z1(Ho),PuRd:z1(Zo),RdPu:z1(Go),YlGnBu:z1(qo),YlGn:z1(Vo),YlOrBr:z1(Yo),YlOrRd:z1(Xo)},jV=Object.keys(zV);z1(No),z1(Oo),z1(Lo),z1(Fo),z1(Io),z1(Ro),z1(Uo),z1($o),z1(Bo),z1(Ko),z1(Jo),z1(es),z1(is),z1(ts),z1(ns),z1(zo),z1(jo),z1(Do),z1(Qo),z1(Wo),z1(Ho),z1(Zo),z1(Go),z1(qo),z1(Vo),z1(Yo),z1(Xo);C.oneOfType([C.oneOf(jV),C.func,C.arrayOf(C.string)]);var uc={basis:fZ,basisClosed:dZ,basisOpen:hZ,bundle:pZ,cardinal:gZ,cardinalClosed:mZ,cardinalOpen:yZ,catmullRom:_Z,catmullRomClosed:vZ,catmullRomOpen:wZ,linear:hd,linearClosed:xZ,monotoneX:bZ,monotoneY:SZ,natural:EZ,step:MZ,stepAfter:kZ,stepBefore:AZ},cs=Object.keys(uc);C.oneOf(cs);cs.filter(function(e){return e.endsWith("Closed")});Xb(cs,"bundle","basisClosed","basisOpen","cardinalClosed","cardinalOpen","catmullRomClosed","catmullRomOpen","linearClosed");var DV=Xb(cs,"bundle","basisClosed","basisOpen","cardinalClosed","cardinalOpen","catmullRomClosed","catmullRomOpen","linearClosed"),QV=C.oneOf(DV),MS=function(e){if(!uc[e])throw new TypeError("'"+e+"', is not a valid curve interpolator identifier.");return uc[e]},WV={defs:C.arrayOf(C.shape({id:C.string.isRequired})).isRequired,fill:C.arrayOf(C.shape({id:C.string.isRequired,match:C.oneOfType([C.oneOf(["*"]),C.object,C.func]).isRequired})).isRequired},HV={ascending:dS,descending:FZ,insideOut:IZ,none:us,reverse:RZ},ZV=Object.keys(HV);C.oneOf(ZV);var GV={expand:TZ,diverging:PZ,none:as,silhouette:CZ,wiggle:NZ},qV=Object.keys(GV);C.oneOf(qV);C.shape({top:C.number,right:C.number,bottom:C.number,left:C.number}).isRequired;var VV=["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Ed=C.oneOf(VV);Xn(ld);var YV={top:0,right:0,bottom:0,left:0},AS=function(e,t,n){return n===void 0&&(n={}),G.useMemo(function(){var i=ut({},YV,n);return{margin:i,innerWidth:e-i.left-i.right,innerHeight:t-i.top-i.bottom,outerWidth:e,outerHeight:t}},[e,t,n.top,n.right,n.bottom,n.left])},kS=function(){var e=G.useRef(null),t=G.useState({left:0,top:0,width:0,height:0}),n=t[0],i=t[1],r=G.useState(function(){return typeof ResizeObserver>"u"?null:new ResizeObserver(function(s){var u=s[0];return i(u.contentRect)})})[0];return G.useEffect(function(){return e.current&&r!==null&&r.observe(e.current),function(){r!==null&&r.disconnect()}},[]),[e,n]},XV=function(e){return G.useMemo(function(){return $V(RV,e)},[e])},KV=function(e){return typeof e=="function"?e:typeof e=="string"?e.indexOf("time:")===0?Co(e.slice("5")):ls(e):function(t){return""+t}},lc=function(e){return G.useMemo(function(){return KV(e)},[e])},TS=G.createContext(),JV={},PS=function(e){var t=e.theme,n=t===void 0?JV:t,i=e.children,r=XV(n);return F.jsx(TS.Provider,{value:r,children:i})};PS.propTypes={children:C.node.isRequired,theme:C.object};var Ft=function(){return G.useContext(TS)},CS=function(e){var t=e.children,n=e.condition,i=e.wrapper;return n?G.cloneElement(i,{},t):t};CS.propTypes={children:C.node.isRequired,condition:C.bool.isRequired,wrapper:C.element.isRequired};var eY={position:"relative"},NS=function(e){var t=e.children,n=e.theme,i=e.renderWrapper,r=i===void 0||i,s=e.isInteractive,u=s===void 0||s,f=e.animate,d=e.motionConfig,p=G.useRef(null);return F.jsx(PS,{theme:n,children:F.jsx(Sd,{animate:f,config:d,children:F.jsx(qF,{container:p,children:F.jsxs(CS,{condition:r,wrapper:F.jsx("div",{style:eY,ref:p}),children:[t,u&&F.jsx(GF,{})]})})})})};NS.propTypes={children:C.element.isRequired,isInteractive:C.bool,renderWrapper:C.bool,theme:C.object,animate:C.bool,motionConfig:C.string};C.func.isRequired,C.bool,C.bool,C.object.isRequired,C.bool.isRequired,C.string;var OS=function(e){var t=e.children,n=kS(),i=n[0],r=n[1],s=r.width>0&&r.height>0;return F.jsx("div",{ref:i,style:{width:"100%",height:"100%"},children:s&&t({width:r.width,height:r.height})})};OS.propTypes={children:C.func.isRequired};var tY=["id","colors"],LS=function(e){var t=e.id,n=e.colors,i=bd(e,tY);return F.jsx("linearGradient",ut({id:t,x1:0,x2:0,y1:0,y2:1},i,{children:n.map(function(r){var s=r.offset,u=r.color,f=r.opacity;return F.jsx("stop",{offset:s+"%",stopColor:u,stopOpacity:f!==void 0?f:1},s)})}))};LS.propTypes={id:C.string.isRequired,colors:C.arrayOf(C.shape({offset:C.number.isRequired,color:C.string.isRequired,opacity:C.number})).isRequired,gradientTransform:C.string};var FS={linearGradient:LS},N8=G.memo(function(e){var t=e.id,n=e.background,i=e.color,r=e.size,s=e.padding,u=e.stagger,f=r+s,d=r/2,p=s/2;return u===!0&&(f=2*r+2*s),F.jsxs("pattern",{id:t,width:f,height:f,patternUnits:"userSpaceOnUse",children:[F.jsx("rect",{width:f,height:f,fill:n}),F.jsx("circle",{cx:p+d,cy:p+d,r:d,fill:i}),u&&F.jsx("circle",{cx:1.5*s+r+d,cy:1.5*s+r+d,r:d,fill:i})]})});N8.displayName="PatternDots",N8.propTypes={id:C.string.isRequired,color:C.string.isRequired,background:C.string.isRequired,size:C.number.isRequired,padding:C.number.isRequired,stagger:C.bool.isRequired},N8.defaultProps={color:"#000000",background:"#ffffff",size:4,padding:4,stagger:!1};var Tr=function(e){return e*Math.PI/180},nY={svg:{align:{left:"start",center:"middle",right:"end",start:"start",middle:"middle",end:"end"},baseline:{top:"text-before-edge",center:"central",bottom:"alphabetic"}},canvas:{align:{left:"left",center:"center",right:"right",start:"left",middle:"center",end:"right"},baseline:{top:"top",center:"middle",bottom:"bottom"}}},O8=G.memo(function(e){var t=e.id,n=e.spacing,i=e.rotation,r=e.background,s=e.color,u=e.lineWidth,f=Math.round(i)%360,d=Math.abs(n);f>180?f-=360:f>90?f-=180:f<-180?f+=360:f<-90&&(f+=180);var p,m=d,h=d;return f===0?p=` + M 0 0 L `+m+` 0 + M 0 `+h+" L "+m+" "+h+` + `:f===90?p=` + M 0 0 L 0 `+h+` + M `+m+" 0 L "+m+" "+h+` + `:(m=Math.abs(d/Math.sin(Tr(f))),h=d/Math.sin(Tr(90-f)),p=f>0?` + M 0 `+-h+" L "+2*m+" "+h+` + M `+-m+" "+-h+" L "+m+" "+h+` + M `+-m+" 0 L "+m+" "+2*h+` + `:` + M `+-m+" "+h+" L "+m+" "+-h+` + M `+-m+" "+2*h+" L "+2*m+" "+-h+` + M 0 `+2*h+" L "+2*m+` 0 + `),F.jsxs("pattern",{id:t,width:m,height:h,patternUnits:"userSpaceOnUse",children:[F.jsx("rect",{width:m,height:h,fill:r,stroke:"rgba(255, 0, 0, 0.1)",strokeWidth:0}),F.jsx("path",{d:p,strokeWidth:u,stroke:s,strokeLinecap:"square"})]})});O8.displayName="PatternLines",O8.propTypes={id:C.string.isRequired,spacing:C.number.isRequired,rotation:C.number.isRequired,background:C.string.isRequired,color:C.string.isRequired,lineWidth:C.number.isRequired},O8.defaultProps={spacing:5,rotation:0,color:"#000000",background:"#ffffff",lineWidth:2};var L8=G.memo(function(e){var t=e.id,n=e.background,i=e.color,r=e.size,s=e.padding,u=e.stagger,f=r+s,d=s/2;return u===!0&&(f=2*r+2*s),F.jsxs("pattern",{id:t,width:f,height:f,patternUnits:"userSpaceOnUse",children:[F.jsx("rect",{width:f,height:f,fill:n}),F.jsx("rect",{x:d,y:d,width:r,height:r,fill:i}),u&&F.jsx("rect",{x:1.5*s+r,y:1.5*s+r,width:r,height:r,fill:i})]})});L8.displayName="PatternSquares",L8.propTypes={id:C.string.isRequired,color:C.string.isRequired,background:C.string.isRequired,size:C.number.isRequired,padding:C.number.isRequired,stagger:C.bool.isRequired},L8.defaultProps={color:"#000000",background:"#ffffff",size:4,padding:4,stagger:!1};var IS={patternDots:N8,patternLines:O8,patternSquares:L8},iY=["type"],cc=ut({},FS,IS),RS=function(e){var t=e.defs;return!t||t.length<1?null:F.jsx("defs",{"aria-hidden":!0,children:t.map(function(n){var i=n.type,r=bd(n,iY);return cc[i]?G.createElement(cc[i],ut({key:r.id},r)):null})})};RS.propTypes={defs:C.arrayOf(C.shape({type:C.oneOf(Object.keys(cc)).isRequired,id:C.string.isRequired}))};var rY=G.memo(RS),US=function(e){var t=e.width,n=e.height,i=e.margin,r=e.defs,s=e.children,u=e.role,f=e.ariaLabel,d=e.ariaLabelledBy,p=e.ariaDescribedBy,m=e.isFocusable,h=Ft();return F.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:n,role:u,"aria-label":f,"aria-labelledby":d,"aria-describedby":p,focusable:m,tabIndex:m?0:void 0,children:[F.jsx(rY,{defs:r}),F.jsx("rect",{width:t,height:n,fill:h.background}),F.jsx("g",{transform:"translate("+i.left+","+i.top+")",children:s})]})};US.propTypes={width:C.number.isRequired,height:C.number.isRequired,margin:C.shape({top:C.number.isRequired,left:C.number.isRequired}).isRequired,defs:C.array,children:C.oneOfType([C.arrayOf(C.node),C.node]).isRequired,role:C.string,isFocusable:C.bool,ariaLabel:C.string,ariaLabelledBy:C.string,ariaDescribedBy:C.string};var $S=function(e){var t=e.size,n=e.color,i=e.borderWidth,r=e.borderColor;return F.jsx("circle",{r:t/2,fill:n,stroke:r,strokeWidth:i,style:{pointerEvents:"none"}})};$S.propTypes={size:C.number.isRequired,color:C.string.isRequired,borderWidth:C.number.isRequired,borderColor:C.string.isRequired};var oY=G.memo($S),BS=function(e){var t=e.x,n=e.y,i=e.symbol,r=i===void 0?oY:i,s=e.size,u=e.datum,f=e.color,d=e.borderWidth,p=e.borderColor,m=e.label,h=e.labelTextAnchor,_=h===void 0?"middle":h,S=e.labelYOffset,E=S===void 0?-12:S,k=Ft(),O=M5(),x=O.animate,w=O.config,b=r0({transform:"translate("+t+", "+n+")",config:w,immediate:!x});return F.jsxs(R2.g,{transform:b.transform,style:{pointerEvents:"none"},children:[G.createElement(r,{size:s,color:f,datum:u,borderWidth:d,borderColor:p}),m&&F.jsx("text",{textAnchor:_,y:E,style:k.dots.text,children:m})]})};BS.propTypes={x:C.number.isRequired,y:C.number.isRequired,datum:C.object.isRequired,size:C.number.isRequired,color:C.string.isRequired,borderWidth:C.number.isRequired,borderColor:C.string.isRequired,symbol:C.oneOfType([C.func,C.object]),label:C.oneOfType([C.string,C.number]),labelTextAnchor:C.oneOf(["start","middle","end"]),labelYOffset:C.number};var sY=G.memo(BS),fc=function(e){var t=e.width,n=e.height,i=e.axis,r=e.scale,s=e.value,u=e.lineStyle,f=e.textStyle,d=e.legend,p=e.legendPosition,m=e.legendOffsetX,h=e.legendOffsetY,_=e.legendOrientation,S=Ft(),E=0,k=0,O=0,x=0;i==="y"?(O=r(s),k=t):(E=r(s),x=n);var w=null;if(d){var b=function(N){var B=N.axis,R=N.width,j=N.height,$=N.position,K=N.offsetX,H=N.offsetY,Q=N.orientation,e1=0,X=0,o1=Q==="vertical"?-90:0,n1="start";if(B==="x")switch($){case"top-left":e1=-K,X=H,n1="end";break;case"top":X=-H,n1=Q==="horizontal"?"middle":"start";break;case"top-right":e1=K,X=H,n1=Q==="horizontal"?"start":"end";break;case"right":e1=K,X=j/2,n1=Q==="horizontal"?"start":"middle";break;case"bottom-right":e1=K,X=j-H,n1="start";break;case"bottom":X=j+H,n1=Q==="horizontal"?"middle":"end";break;case"bottom-left":X=j-H,e1=-K,n1=Q==="horizontal"?"end":"start";break;case"left":e1=-K,X=j/2,n1=Q==="horizontal"?"end":"middle"}else switch($){case"top-left":e1=K,X=-H,n1="start";break;case"top":e1=R/2,X=-H,n1=Q==="horizontal"?"middle":"start";break;case"top-right":e1=R-K,X=-H,n1=Q==="horizontal"?"end":"start";break;case"right":e1=R+K,n1=Q==="horizontal"?"start":"middle";break;case"bottom-right":e1=R-K,X=H,n1="end";break;case"bottom":e1=R/2,X=H,n1=Q==="horizontal"?"middle":"end";break;case"bottom-left":e1=K,X=H,n1=Q==="horizontal"?"start":"end";break;case"left":e1=-K,n1=Q==="horizontal"?"end":"middle"}return{x:e1,y:X,rotation:o1,textAnchor:n1}}({axis:i,width:t,height:n,position:p,offsetX:m,offsetY:h,orientation:_});w=F.jsx("text",{transform:"translate("+b.x+", "+b.y+") rotate("+b.rotation+")",textAnchor:b.textAnchor,dominantBaseline:"central",style:f,children:d})}return F.jsxs("g",{transform:"translate("+E+", "+O+")",children:[F.jsx("line",{x1:0,x2:k,y1:0,y2:x,stroke:S.markers.lineColor,strokeWidth:S.markers.lineStrokeWidth,style:u}),w]})};fc.propTypes={width:C.number.isRequired,height:C.number.isRequired,axis:C.oneOf(["x","y"]).isRequired,scale:C.func.isRequired,value:C.oneOfType([C.number,C.string,C.instanceOf(Date)]).isRequired,lineStyle:C.object,textStyle:C.object,legend:C.string,legendPosition:C.oneOf(["top-left","top","top-right","right","bottom-right","bottom","bottom-left","left"]),legendOffsetX:C.number.isRequired,legendOffsetY:C.number.isRequired,legendOrientation:C.oneOf(["horizontal","vertical"]).isRequired},fc.defaultProps={legendPosition:"top-right",legendOffsetX:14,legendOffsetY:14,legendOrientation:"horizontal"};var aY=G.memo(fc),zS=function(e){var t=e.markers,n=e.width,i=e.height,r=e.xScale,s=e.yScale;return t&&t.length!==0?t.map(function(u,f){return F.jsx(aY,ut({},u,{width:n,height:i,scale:u.axis==="y"?s:r}),f)}):null};zS.propTypes={width:C.number.isRequired,height:C.number.isRequired,xScale:C.func.isRequired,yScale:C.func.isRequired,markers:C.arrayOf(C.shape({axis:C.oneOf(["x","y"]).isRequired,value:C.oneOfType([C.number,C.string,C.instanceOf(Date)]).isRequired,lineStyle:C.object,textStyle:C.object}))};var uY=G.memo(zS),lY=["theme","renderWrapper","animate","motionConfig"],jS=function(e){return function(t){var n,i;function r(){return t.apply(this,arguments)||this}return i=t,(n=r).prototype=Object.create(i.prototype),n.prototype.constructor=n,sc(n,i),r.prototype.render=function(){var s=this.props,u=s.theme,f=s.renderWrapper,d=s.animate,p=s.motionConfig,m=bd(s,lY);return F.jsx(NS,{theme:u,renderWrapper:f,isInteractive:m.isInteractive,animate:d,motionConfig:p,children:F.jsx(e,ut({},m))})},r}(G.Component)},cY=function(e,t){var n,i=Ql(e)?e:function(r){return i5(r,e)};return t&&(n=Ql(t)?t:ls(t)),n?function(r){return n(i(r))}:i},fY=function(e,t,n,i,r,s){return e<=r&&r<=e+n&&t<=s&&s<=t+i},DS=function(e,t){var n,i=t.clientX,r=t.clientY,s=e.getBoundingClientRect(),u=(n=e.getBBox!==void 0?e.getBBox():{width:e.offsetWidth,height:e.offsetHeight}).width===s.width?1:n.width/s.width;return[(i-s.left)*u,(r-s.top)*u]},dY=Object.keys(FS),hY=Object.keys(IS),pY=function(e,t,n){if(e==="*")return!0;if(Ql(e))return e(t);if(V$(e)){var i=n?i5(t,n):t;return kV(LG(i,Object.keys(e)),e)}return!1},gY=function(e,t,n,i){var r=i===void 0?{}:i,s=r.dataKey,u=r.colorKey,f=u===void 0?"color":u,d=r.targetKey,p=d===void 0?"fill":d,m=[],h={};return e.length&&t.length&&(m=[].concat(e),t.forEach(function(_){for(var S=function(){var k=n[E],O=k.id,x=k.match;if(pY(x,_,s)){var w=e.find(function(H){return H.id===O});if(w){if(hY.includes(w.type))if(w.background==="inherit"||w.color==="inherit"){var b=i5(_,f),N=w.background,B=w.color,R=O;w.background==="inherit"&&(R=R+".bg."+b,N=b),w.color==="inherit"&&(R=R+".fg."+b,B=b),Yn(_,p,"url(#"+R+")"),h[R]||(m.push(ut({},w,{id:R,background:N,color:B})),h[R]=1)}else Yn(_,p,"url(#"+O+")");else if(dY.includes(w.type))if(w.colors.map(function(H){return H.color}).includes("inherit")){var j=i5(_,f),$=O,K=ut({},w,{colors:w.colors.map(function(H,Q){return H.color!=="inherit"?H:($=$+"."+Q+"."+j,ut({},H,{color:H.color==="inherit"?j:H.color}))})});K.id=$,Yn(_,p,"url(#"+$+")"),h[$]||(m.push(K),h[$]=1)}else Yn(_,p,"url(#"+O+")")}return"break"}},E=0;E>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?o8(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?o8(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=yY.exec(e))?new r4(t[1],t[2],t[3],1):(t=_Y.exec(e))?new r4(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=vY.exec(e))?o8(t[1],t[2],t[3],t[4]):(t=wY.exec(e))?o8(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=xY.exec(e))?Iy(t[1],t[2]/100,t[3]/100,1):(t=bY.exec(e))?Iy(t[1],t[2]/100,t[3]/100,t[4]):Py.hasOwnProperty(e)?Oy(Py[e]):e==="transparent"?new r4(NaN,NaN,NaN,0):null}function Oy(e){return new r4(e>>16&255,e>>8&255,e&255,1)}function o8(e,t,n,i){return i<=0&&(e=t=n=NaN),new r4(e,t,n,i)}function MY(e){return e instanceof T9||(e=Ad(e)),e?(e=e.rgb(),new r4(e.r,e.g,e.b,e.opacity)):new r4}function WS(e,t,n,i){return arguments.length===1?MY(e):new r4(e,t,n,i??1)}function r4(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}Md(r4,WS,QS(T9,{brighter(e){return e=e==null?Pr:Math.pow(Pr,e),new r4(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?d9:Math.pow(d9,e),new r4(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new r4(s5(this.r),s5(this.g),s5(this.b),Cr(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:Ly,formatHex:Ly,formatHex8:AY,formatRgb:Fy,toString:Fy}));function Ly(){return`#${Kn(this.r)}${Kn(this.g)}${Kn(this.b)}`}function AY(){return`#${Kn(this.r)}${Kn(this.g)}${Kn(this.b)}${Kn((isNaN(this.opacity)?1:this.opacity)*255)}`}function Fy(){const e=Cr(this.opacity);return`${e===1?"rgb(":"rgba("}${s5(this.r)}, ${s5(this.g)}, ${s5(this.b)}${e===1?")":`, ${e})`}`}function Cr(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function s5(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Kn(e){return e=s5(e),(e<16?"0":"")+e.toString(16)}function Iy(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new u2(e,t,n,i)}function HS(e){if(e instanceof u2)return new u2(e.h,e.s,e.l,e.opacity);if(e instanceof T9||(e=Ad(e)),!e)return new u2;if(e instanceof u2)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,r=Math.min(t,n,i),s=Math.max(t,n,i),u=NaN,f=s-r,d=(s+r)/2;return f?(t===s?u=(n-i)/f+(n0&&d<1?0:u,new u2(u,f,d,e.opacity)}function kY(e,t,n,i){return arguments.length===1?HS(e):new u2(e,t,n,i??1)}function u2(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}Md(u2,kY,QS(T9,{brighter(e){return e=e==null?Pr:Math.pow(Pr,e),new u2(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?d9:Math.pow(d9,e),new u2(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,i=n+(n<.5?n:1-n)*t,r=2*n-i;return new r4(xu(e>=240?e-240:e+120,r,i),xu(e,r,i),xu(e<120?e+240:e-120,r,i),this.opacity)},clamp(){return new u2(Ry(this.h),s8(this.s),s8(this.l),Cr(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=Cr(this.opacity);return`${e===1?"hsl(":"hsla("}${Ry(this.h)}, ${s8(this.s)*100}%, ${s8(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ry(e){return e=(e||0)%360,e<0?e+360:e}function s8(e){return Math.max(0,Math.min(1,e||0))}function xu(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}function Nr(){return Nr=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,i=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var ZS={nivo:["#e8c1a0","#f47560","#f1e15b","#e8a838","#61cdbb","#97e3d5"],category10:jb,accent:Db,dark2:Qb,paired:Wb,pastel1:Hb,pastel2:Zb,set1:Gb,set2:qb,set3:ld},PY=Object.keys(ZS),GS={brown_blueGreen:No,purpleRed_green:Oo,pink_yellowGreen:Lo,purple_orange:Fo,red_blue:Io,red_grey:Ro,red_yellow_blue:Uo,red_yellow_green:$o,spectral:Bo},CY=Object.keys(GS),NY={brown_blueGreen:zW,purpleRed_green:jW,pink_yellowGreen:DW,purple_orange:QW,red_blue:WW,red_grey:HW,red_yellow_blue:ZW,red_yellow_green:GW,spectral:qW},qS={blues:Ko,greens:Jo,greys:es,oranges:is,purples:ts,reds:ns,blue_green:zo,blue_purple:jo,green_blue:Do,orange_red:Qo,purple_blue_green:Wo,purple_blue:Ho,purple_red:Zo,red_purple:Go,yellow_green_blue:qo,yellow_green:Vo,yellow_orange_brown:Yo,yellow_orange_red:Xo},OY=Object.keys(qS),LY={blues:aH,greens:uH,greys:lH,oranges:dH,purples:cH,reds:fH,turbo:xH,viridis:bH,inferno:EH,magma:SH,plasma:MH,cividis:hH,warm:gH,cool:mH,cubehelixDefault:pH,blue_green:VW,blue_purple:YW,green_blue:XW,orange_red:KW,purple_blue_green:JW,purple_blue:eH,purple_red:tH,red_purple:nH,yellow_green_blue:iH,yellow_green:rH,yellow_orange_brown:oH,yellow_orange_red:sH},F8=Nr({},ZS,GS,qS),FY=Object.keys(F8),IY=function(e){return PY.includes(e)},RY=function(e){return CY.includes(e)},UY=function(e){return OY.includes(e)},$Y={rainbow:yH,sinebow:wH};Nr({},NY,LY,$Y);var BY=function(e,t){if(typeof e=="function")return e;if(o5.isPlainObject(e)){if(function(d){return d.theme!==void 0}(e)){if(t===void 0)throw new Error("Unable to use color from theme as no theme was provided");var n=o5.get(t,e.theme);if(n===void 0)throw new Error("Color from theme is undefined at path: '"+e.theme+"'");return function(){return n}}if(function(d){return d.from!==void 0}(e)){var i=function(d){return o5.get(d,e.from)};if(Array.isArray(e.modifiers)){for(var r,s=[],u=function(){var d=r.value,p=d[0],m=d[1];if(p==="brighter")s.push(function(h){return h.brighter(m)});else if(p==="darker")s.push(function(h){return h.darker(m)});else{if(p!=="opacity")throw new Error("Invalid color modifier: '"+p+"', must be one of: 'brighter', 'darker', 'opacity'");s.push(function(h){return h.opacity=m,h})}},f=TY(e.modifiers);!(r=f()).done;)u();return s.length===0?i:function(d){return s.reduce(function(p,m){return m(p)},WS(i(d))).toString()}}return i}throw new Error("Invalid color spec, you should either specify 'theme' or 'from' when using a config object")}return function(){return e}},Or=function(e,t){return G.useMemo(function(){return BY(e,t)},[e,t])},zY=C.oneOfType([C.func,C.arrayOf(C.string),C.shape({scheme:C.oneOf(FY).isRequired,size:C.number}),C.shape({datum:C.string.isRequired}),C.string]);C.oneOfType([C.string,C.func,C.shape({theme:C.string.isRequired}),C.shape({from:C.string.isRequired,modifiers:C.arrayOf(C.array)})]);var jY=function(e,t){if(typeof e=="function")return e;var n=typeof t=="function"?t:function(h){return o5.get(h,t)};if(Array.isArray(e)){var i=Xn(e),r=function(h){return i(n(h))};return r.scale=i,r}if(o5.isPlainObject(e)){if(function(h){return h.datum!==void 0}(e))return function(h){return o5.get(h,e.datum)};if(function(h){return h.scheme!==void 0}(e)){if(IY(e.scheme)){var s=Xn(F8[e.scheme]),u=function(h){return s(n(h))};return u.scale=s,u}if(RY(e.scheme)){if(e.size!==void 0&&(e.size<3||e.size>11))throw new Error("Invalid size '"+e.size+"' for diverging color scheme '"+e.scheme+"', must be between 3~11");var f=Xn(F8[e.scheme][e.size||11]),d=function(h){return f(n(h))};return d.scale=f,d}if(UY(e.scheme)){if(e.size!==void 0&&(e.size<3||e.size>9))throw new Error("Invalid size '"+e.size+"' for sequential color scheme '"+e.scheme+"', must be between 3~9");var p=Xn(F8[e.scheme][e.size||9]),m=function(h){return p(n(h))};return m.scale=p,m}}throw new Error("Invalid colors, when using an object, you should either pass a 'datum' or a 'scheme' property")}return function(){return e}},DY=function(e,t){return G.useMemo(function(){return jY(e,t)},[e,t])};function QY(){}var WY=QY,bu=wS,HY=WY,ZY=vd,GY=1/0,qY=bu&&1/ZY(new bu([,-0]))[1]==GY?function(e){return new bu(e)}:HY,VY=qY,YY=cd,XY=Vb,KY=Yb,JY=fd,eX=VY,tX=vd,nX=200;function iX(e,t,n){var i=-1,r=XY,s=e.length,u=!0,f=[],d=f;if(n)u=!1,r=KY;else if(s>=nX){var p=t?null:eX(e);if(p)return tX(p);u=!1,r=JY,d=new YY}else d=t?[]:f;e:for(;++it||s&&u&&d&&!f&&!p||i&&u&&d||!n&&d||!r)return 1;if(!i&&!s&&!p&&e=f)return d;var p=n[i];return d*(p=="desc"?-1:1)}}return e.index-t.index}var MK=EK,Su=qf,AK=xo,kK=KS,TK=_K,PK=wK,CK=mo,NK=MK,OK=_o,LK=g2;function FK(e,t,n){t.length?t=Su(t,function(s){return LK(s)?function(u){return AK(u,s.length===1?s[0]:s)}:s}):t=[OK];var i=-1;t=Su(t,CK(kK));var r=TK(e,function(s,u,f){var d=Su(t,function(p){return p(s)});return{criteria:d,index:++i,value:s}});return PK(r,function(s,u){return NK(s,u,n)})}var IK=FK,RK=_S,UK=IK,$K=Hf,zy=Yx,BK=$K(function(e,t){if(e==null)return[];var n=t.length;return n>1&&zy(e,t[0],t[1])?t=[]:n>2&&zy(t[0],t[1],t[2])&&(t=[t[0]]),UK(e,RK(t,1),[])}),zK=BK;const jK=Lt(zK);var DK=w5,QK=ln,WK="[object Date]";function HK(e){return QK(e)&&DK(e)==WK}var ZK=HK,GK=ZK,qK=mo,jy=Dx,Dy=jy&&jy.isDate,VK=Dy?qK(Dy):GK,YK=VK;const XK=Lt(YK);var Eu=new Date,Mu=new Date;function ht(e,t,n,i){function r(s){return e(s=arguments.length===0?new Date:new Date(+s)),s}return r.floor=function(s){return e(s=new Date(+s)),s},r.ceil=function(s){return e(s=new Date(s-1)),t(s,1),e(s),s},r.round=function(s){var u=r(s),f=r.ceil(s);return s-u0))return d;do d.push(p=new Date(+s)),t(s,f),e(s);while(p=u)for(;e(u),!s(u);)u.setTime(u-1)},function(u,f){if(u>=u)if(f<0)for(;++f<=0;)for(;t(u,-1),!s(u););else for(;--f>=0;)for(;t(u,1),!s(u););})},n&&(r.count=function(s,u){return Eu.setTime(+s),Mu.setTime(+u),e(Eu),e(Mu),Math.floor(n(Eu,Mu))},r.every=function(s){return s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?r.filter(i?function(u){return i(u)%s===0}:function(u){return r.count(0,u)%s===0}):r}),r}var Lr=ht(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});Lr.every=function(e){return e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?ht(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):Lr};const Qy=Lr;Lr.range;var Fr=1e3,J6=6e4,Ir=36e5,JS=6048e5,eE=ht(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+t*Fr)},function(e,t){return(t-e)/Fr},function(e){return e.getUTCSeconds()});const Wy=eE;eE.range;var tE=ht(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*Fr)},function(e,t){e.setTime(+e+t*J6)},function(e,t){return(t-e)/J6},function(e){return e.getMinutes()});const KK=tE;tE.range;var nE=ht(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*Fr-e.getMinutes()*J6)},function(e,t){e.setTime(+e+t*Ir)},function(e,t){return(t-e)/Ir},function(e){return e.getHours()});const JK=nE;nE.range;function A5(e){return ht(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(t,n){t.setDate(t.getDate()+n*7)},function(t,n){return(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*J6)/JS})}var dc=A5(0),iE=A5(1),rE=A5(2),oE=A5(3),sE=A5(4),aE=A5(5),uE=A5(6);dc.range;iE.range;rE.range;oE.range;sE.range;aE.range;uE.range;var lE=ht(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12},function(e){return e.getMonth()});const eJ=lE;lE.range;var kd=ht(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()});kd.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:ht(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)})};const tJ=kd;kd.range;var cE=ht(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*J6)},function(e,t){return(t-e)/J6},function(e){return e.getUTCMinutes()});const nJ=cE;cE.range;var fE=ht(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+t*Ir)},function(e,t){return(t-e)/Ir},function(e){return e.getUTCHours()});const iJ=fE;fE.range;function k5(e){return ht(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCDate(t.getUTCDate()+n*7)},function(t,n){return(n-t)/JS})}var hc=k5(0),dE=k5(1),hE=k5(2),pE=k5(3),gE=k5(4),mE=k5(5),yE=k5(6);hc.range;dE.range;hE.range;pE.range;gE.range;mE.range;yE.range;var _E=ht(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12},function(e){return e.getUTCMonth()});const rJ=_E;_E.range;var Td=ht(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()});Td.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:ht(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})};const oJ=Td;Td.range;function Hn(){return Hn=Object.assign?Object.assign.bind():function(e){for(var t=1;t0?(x=_.align[O?"left":"right"],w=_.baseline.center):(r==="after"&&d>0||r==="before"&&d<0)&&(x=_.align[O?"right":"left"],w=_.baseline.center)):(t=function(b){var N;return{x:0,y:(N=S(b))!=null?N:0}},E.lineX=u*(r==="after"?1:-1),k.textX=(u+f)*(r==="after"?1:-1),x=r==="after"?_.align.left:_.align.right),{ticks:h.map(function(b){return p2({key:b instanceof Date?""+b.valueOf():""+b,value:b},t(b),E,k)}),textAlign:x,textBaseline:w}},ME=function(e,t){if(e===void 0||typeof e=="function")return e;if(t.type==="time"){var n=Co(e);return function(i){return n(i instanceof Date?i:new Date(i))}}return ls(e)},pc=function(e){var t,n=e.width,i=e.height,r=e.scale,s=e.axis,u=e.values,f=(t=u,(Array.isArray(t)?u:void 0)||SE(r,u)),d="bandwidth"in r?xE(r):r,p=s==="x"?f.map(function(m){var h,_;return{key:m instanceof Date?""+m.valueOf():""+m,x1:(h=d(m))!=null?h:0,x2:(_=d(m))!=null?_:0,y1:0,y2:i}}):f.map(function(m){var h,_;return{key:m instanceof Date?""+m.valueOf():""+m,x1:0,x2:n,y1:(h=d(m))!=null?h:0,y2:(_=d(m))!=null?_:0}});return p},MJ=G.memo(function(e){var t,n=e.value,i=e.format,r=e.lineX,s=e.lineY,u=e.onClick,f=e.textBaseline,d=e.textAnchor,p=e.animatedProps,m=Ft(),h=(t=i==null?void 0:i(n))!=null?t:n,_=G.useMemo(function(){var S={opacity:p.opacity};return u?{style:p2({},S,{cursor:"pointer"}),onClick:function(E){return u(E,h)}}:{style:S}},[p.opacity,u,h]);return F.jsxs(R2.g,p2({transform:p.transform},_,{children:[F.jsx("line",{x1:0,x2:r,y1:0,y2:s,style:m.axis.ticks.line}),F.jsx(R2.text,{dominantBaseline:f,textAnchor:d,transform:p.textTransform,style:m.axis.ticks.text,children:""+h})]}))}),AJ=G.memo(function(e){var t=e.axis,n=e.scale,i=e.x,r=i===void 0?0:i,s=e.y,u=s===void 0?0:s,f=e.length,d=e.ticksPosition,p=e.tickValues,m=e.tickSize,h=m===void 0?5:m,_=e.tickPadding,S=_===void 0?5:_,E=e.tickRotation,k=E===void 0?0:E,O=e.format,x=e.renderTick,w=x===void 0?MJ:x,b=e.legend,N=e.legendPosition,B=N===void 0?"end":N,R=e.legendOffset,j=R===void 0?0:R,$=e.onClick,K=e.ariaHidden,H=Ft(),Q=G.useMemo(function(){return ME(O,n)},[O,n]),e1=EE({axis:t,scale:n,ticksPosition:d,tickValues:p,tickSize:h,tickPadding:S,tickRotation:k}),X=e1.ticks,o1=e1.textAlign,n1=e1.textBaseline,l1=null;if(b!==void 0){var r1,Y=0,g1=0,f1=0;t==="y"?(f1=-90,Y=j,B==="start"?(r1="start",g1=f):B==="middle"?(r1="middle",g1=f/2):B==="end"&&(r1="end")):(g1=j,B==="start"?r1="start":B==="middle"?(r1="middle",Y=f/2):B==="end"&&(r1="end",Y=f)),l1=F.jsx("text",{transform:"translate("+Y+", "+g1+") rotate("+f1+")",textAnchor:r1,style:p2({dominantBaseline:"central"},H.axis.legend.text),children:b})}var w1=M5(),k1=w1.animate,U1=w1.config,O1=r0({transform:"translate("+r+","+u+")",lineX2:t==="x"?f:0,lineY2:t==="x"?0:f,config:U1,immediate:!k1}),v1=xx(X,{keys:function(d1){return d1.key},initial:function(d1){return{opacity:1,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},from:function(d1){return{opacity:0,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},enter:function(d1){return{opacity:1,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},update:function(d1){return{opacity:1,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},leave:{opacity:0},config:U1,immediate:!k1});return F.jsxs(R2.g,{transform:O1.transform,"aria-hidden":K,children:[v1(function(d1,I1,W1,E1){return G.createElement(w,p2({tickIndex:E1,format:Q,rotate:k,textBaseline:n1,textAnchor:o1,animatedProps:d1},I1,$?{onClick:$}:{}))}),F.jsx(R2.line,{style:H.axis.domain.line,x1:0,x2:O1.lineX2,y1:0,y2:O1.lineY2}),l1]})}),kJ={ticksPosition:C.oneOf(["before","after"]),tickValues:C.oneOfType([C.number,C.arrayOf(C.oneOfType([C.number,C.string,C.instanceOf(Date)])),C.string]),tickSize:C.number,tickPadding:C.number,tickRotation:C.number,format:C.oneOfType([C.func,C.string]),renderTick:C.func,legend:C.node,legendPosition:C.oneOf(["start","middle","end"]),legendOffset:C.number,ariaHidden:C.bool},a8=C.shape(kJ),AE=["top","right","bottom","left"],TJ=G.memo(function(e){var t=e.xScale,n=e.yScale,i=e.width,r=e.height,s={top:e.top,right:e.right,bottom:e.bottom,left:e.left};return F.jsx(F.Fragment,{children:AE.map(function(u){var f=s[u];if(!f)return null;var d=u==="top"||u==="bottom";return F.jsx(AJ,p2({},f,{axis:d?"x":"y",x:u==="right"?i:0,y:u==="bottom"?r:0,scale:d?t:n,length:d?i:r,ticksPosition:u==="top"||u==="left"?"before":"after"}),u)})})}),PJ=G.memo(function(e){var t=e.animatedProps,n=Ft();return F.jsx(R2.line,p2({},t,n.grid.line))}),qy=G.memo(function(e){var t=e.lines,n=M5(),i=n.animate,r=n.config,s=xx(t,{keys:function(u){return u.key},initial:function(u){return{opacity:1,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},from:function(u){return{opacity:0,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},enter:function(u){return{opacity:1,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},update:function(u){return{opacity:1,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},leave:{opacity:0},config:r,immediate:!i});return F.jsx("g",{children:s(function(u,f){return G.createElement(PJ,p2({},f,{key:f.key,animatedProps:u}))})})}),CJ=G.memo(function(e){var t=e.width,n=e.height,i=e.xScale,r=e.yScale,s=e.xValues,u=e.yValues,f=G.useMemo(function(){return!!i&&pc({width:t,height:n,scale:i,axis:"x",values:s})},[i,s,t,n]),d=G.useMemo(function(){return!!r&&pc({width:t,height:n,scale:r,axis:"y",values:u})},[n,t,r,u]);return F.jsxs(F.Fragment,{children:[f&&F.jsx(qy,{lines:f}),d&&F.jsx(qy,{lines:d})]})}),NJ=function(e,t){var n,i=t.axis,r=t.scale,s=t.x,u=s===void 0?0:s,f=t.y,d=f===void 0?0:f,p=t.length,m=t.ticksPosition,h=t.tickValues,_=t.tickSize,S=_===void 0?5:_,E=t.tickPadding,k=E===void 0?5:E,O=t.tickRotation,x=O===void 0?0:O,w=t.format,b=t.legend,N=t.legendPosition,B=N===void 0?"end":N,R=t.legendOffset,j=R===void 0?0:R,$=t.theme,K=EE({axis:i,scale:r,ticksPosition:m,tickValues:h,tickSize:S,tickPadding:k,tickRotation:x,engine:"canvas"}),H=K.ticks,Q=K.textAlign,e1=K.textBaseline;e.save(),e.translate(u,d),e.textAlign=Q,e.textBaseline=e1,e.font=($.axis.ticks.text.fontWeight?$.axis.ticks.text.fontWeight+" ":"")+$.axis.ticks.text.fontSize+"px "+$.axis.ticks.text.fontFamily,((n=$.axis.domain.line.strokeWidth)!=null?n:0)>0&&(e.lineWidth=Number($.axis.domain.line.strokeWidth),e.lineCap="square",$.axis.domain.line.stroke&&(e.strokeStyle=$.axis.domain.line.stroke),e.beginPath(),e.moveTo(0,0),e.lineTo(i==="x"?p:0,i==="x"?0:p),e.stroke());var X=typeof w=="function"?w:function(Y){return""+Y};if(H.forEach(function(Y){var g1;((g1=$.axis.ticks.line.strokeWidth)!=null?g1:0)>0&&(e.lineWidth=Number($.axis.ticks.line.strokeWidth),e.lineCap="square",$.axis.ticks.line.stroke&&(e.strokeStyle=$.axis.ticks.line.stroke),e.beginPath(),e.moveTo(Y.x,Y.y),e.lineTo(Y.x+Y.lineX,Y.y+Y.lineY),e.stroke());var f1=X(Y.value);e.save(),e.translate(Y.x+Y.textX,Y.y+Y.textY),e.rotate(Tr(x)),$.axis.ticks.text.fill&&(e.fillStyle=$.axis.ticks.text.fill),e.fillText(String(f1),0,0),e.restore()}),b!==void 0){var o1=0,n1=0,l1=0,r1="center";i==="y"?(l1=-90,o1=j,B==="start"?(r1="start",n1=p):B==="middle"?(r1="center",n1=p/2):B==="end"&&(r1="end")):(n1=j,B==="start"?r1="start":B==="middle"?(r1="center",o1=p/2):B==="end"&&(r1="end",o1=p)),e.translate(o1,n1),e.rotate(Tr(l1)),e.font=($.axis.legend.text.fontWeight?$.axis.legend.text.fontWeight+" ":"")+$.axis.legend.text.fontSize+"px "+$.axis.legend.text.fontFamily,$.axis.legend.text.fill&&(e.fillStyle=$.axis.legend.text.fill),e.textAlign=r1,e.textBaseline="middle",e.fillText(b,0,0)}e.restore()},OJ=function(e,t){var n=t.xScale,i=t.yScale,r=t.width,s=t.height,u=t.top,f=t.right,d=t.bottom,p=t.left,m=t.theme,h={top:u,right:f,bottom:d,left:p};AE.forEach(function(_){var S=h[_];if(!S)return null;var E=_==="top"||_==="bottom",k=_==="top"||_==="left"?"before":"after",O=E?n:i,x=ME(S.format,O);NJ(e,p2({},S,{axis:E?"x":"y",x:_==="right"?r:0,y:_==="bottom"?s:0,scale:O,format:x,length:E?r:s,ticksPosition:k,theme:m}))})},Vy=function(e,t){var n=t.width,i=t.height,r=t.scale,s=t.axis,u=t.values;pc({width:n,height:i,scale:r,axis:s,values:u}).forEach(function(f){e.beginPath(),e.moveTo(f.x1,f.y1),e.lineTo(f.x2,f.y2),e.stroke()})},LJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,s=e.opacity,u=s===void 0?1:s,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return F.jsx("circle",{r:i/2,cx:t+i/2,cy:n+i/2,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,style:{pointerEvents:"none"}})},FJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,s=e.opacity,u=s===void 0?1:s,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return F.jsx("g",{transform:"translate("+t+","+n+")",children:F.jsx("path",{d:` + M`+i/2+` 0 + L`+.8*i+" "+i/2+` + L`+i/2+" "+i+` + L`+.2*i+" "+i/2+` + L`+i/2+` 0 + `,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,style:{pointerEvents:"none"}})})},IJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,s=e.opacity,u=s===void 0?1:s,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return F.jsx("rect",{x:t,y:n,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,width:i,height:i,style:{pointerEvents:"none"}})},RJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,s=e.opacity,u=s===void 0?1:s,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return F.jsx("g",{transform:"translate("+t+","+n+")",children:F.jsx("path",{d:` + M`+i/2+` 0 + L`+i+" "+i+` + L0 `+i+` + L`+i/2+` 0 + `,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,style:{pointerEvents:"none"}})})};function Jn(){return Jn=Object.assign?Object.assign.bind():function(e){for(var t=1;t>1;if(n>0&&typeof t[0]!="number")throw new Error("Expected coords to contain numbers.");this.coords=t;const i=Math.max(2*n-5,0);this._triangles=new Uint32Array(i*3),this._halfedges=new Int32Array(i*3),this._hashSize=Math.ceil(Math.sqrt(n)),this._hullPrev=new Uint32Array(n),this._hullNext=new Uint32Array(n),this._hullTri=new Uint32Array(n),this._hullHash=new Int32Array(this._hashSize).fill(-1),this._ids=new Uint32Array(n),this._dists=new Float64Array(n),this.update()}update(){const{coords:t,_hullPrev:n,_hullNext:i,_hullTri:r,_hullHash:s}=this,u=t.length>>1;let f=1/0,d=1/0,p=-1/0,m=-1/0;for(let H=0;Hp&&(p=Q),e1>m&&(m=e1),this._ids[H]=H}const h=(f+p)/2,_=(d+m)/2;let S=1/0,E,k,O;for(let H=0;H0&&(k=H,S=Q)}let b=t[2*k],N=t[2*k+1],B=1/0;for(let H=0;HX&&(H[Q++]=o1,X=this._dists[o1])}this.hull=H.subarray(0,Q),this.triangles=new Uint32Array(0),this.halfedges=new Uint32Array(0);return}if(l8(x,w,b,N,R,j)){const H=k,Q=b,e1=N;k=O,b=R,N=j,O=H,R=Q,j=e1}const $=qJ(x,w,b,N,R,j);this._cx=$.x,this._cy=$.y;for(let H=0;H0&&Math.abs(o1-Q)<=Yy&&Math.abs(n1-e1)<=Yy||(Q=o1,e1=n1,X===E||X===k||X===O))continue;let l1=0;for(let w1=0,k1=this._hashKey(o1,n1);w10?3-n:1+n)/4}function Au(e,t,n,i){const r=e-n,s=t-i;return r*r+s*s}function ku(e,t,n,i,r,s){const u=(i-t)*(r-e),f=(n-e)*(s-t);return Math.abs(u-f)>=33306690738754716e-32*Math.abs(u+f)?u-f:0}function l8(e,t,n,i,r,s){return(ku(r,s,e,t,n,i)||ku(e,t,n,i,r,s)||ku(n,i,r,s,e,t))<0}function ZJ(e,t,n,i,r,s,u,f){const d=e-u,p=t-f,m=n-u,h=i-f,_=r-u,S=s-f,E=d*d+p*p,k=m*m+h*h,O=_*_+S*S;return d*(h*O-k*S)-p*(m*O-k*_)+E*(m*S-h*_)<0}function GJ(e,t,n,i,r,s){const u=n-e,f=i-t,d=r-e,p=s-t,m=u*u+f*f,h=d*d+p*p,_=.5/(u*p-f*d),S=(p*m-f*h)*_,E=(u*h-d*m)*_;return S*S+E*E}function qJ(e,t,n,i,r,s){const u=n-e,f=i-t,d=r-e,p=s-t,m=u*u+f*f,h=d*d+p*p,_=.5/(u*p-f*d),S=e+(p*m-f*h)*_,E=t+(u*h-d*m)*_;return{x:S,y:E}}function k6(e,t,n,i){if(i-n<=20)for(let r=n+1;r<=i;r++){const s=e[r],u=t[s];let f=r-1;for(;f>=n&&t[e[f]]>u;)e[f+1]=e[f--];e[f+1]=s}else{const r=n+i>>1;let s=n+1,u=i;h7(e,r,s),t[e[n]]>t[e[i]]&&h7(e,n,i),t[e[s]]>t[e[i]]&&h7(e,s,i),t[e[n]]>t[e[s]]&&h7(e,n,s);const f=e[s],d=t[f];for(;;){do s++;while(t[e[s]]d);if(u=u-n?(k6(e,t,s,i),k6(e,t,n,u-1)):(k6(e,t,n,u-1),k6(e,t,s,i))}}function h7(e,t,n){const i=e[t];e[t]=e[n],e[n]=i}function VJ(e){return e[0]}function YJ(e){return e[1]}const Xy=1e-6;class e5{constructor(){this._x0=this._y0=this._x1=this._y1=null,this._=""}moveTo(t,n){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")}lineTo(t,n){this._+=`L${this._x1=+t},${this._y1=+n}`}arc(t,n,i){t=+t,n=+n,i=+i;const r=t+i,s=n;if(i<0)throw new Error("negative radius");this._x1===null?this._+=`M${r},${s}`:(Math.abs(this._x1-r)>Xy||Math.abs(this._y1-s)>Xy)&&(this._+="L"+r+","+s),i&&(this._+=`A${i},${i},0,1,1,${t-i},${n}A${i},${i},0,1,1,${this._x1=r},${this._y1=s}`)}rect(t,n,i,r){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${+i}v${+r}h${-i}Z`}value(){return this._||null}}let gc=class{constructor(){this._=[]}moveTo(t,n){this._.push([t,n])}closePath(){this._.push(this._[0].slice())}lineTo(t,n){this._.push([t,n])}value(){return this._.length?this._:null}};class XJ{constructor(t,[n,i,r,s]=[0,0,960,500]){if(!((r=+r)>=(n=+n))||!((s=+s)>=(i=+i)))throw new Error("invalid bounds");this.delaunay=t,this._circumcenters=new Float64Array(t.points.length*2),this.vectors=new Float64Array(t.points.length*2),this.xmax=r,this.xmin=n,this.ymax=s,this.ymin=i,this._init()}update(){return this.delaunay.update(),this._init(),this}_init(){const{delaunay:{points:t,hull:n,triangles:i},vectors:r}=this,s=this.circumcenters=this._circumcenters.subarray(0,i.length/3*2);for(let S=0,E=0,k=i.length,O,x;S1;)s-=2;for(let u=2;u4)for(let u=0;u0){if(n>=this.ymax)return null;(u=(this.ymax-n)/r)0){if(t>=this.xmax)return null;(u=(this.xmax-t)/i)this.xmax?2:0)|(nthis.ymax?8:0)}}const KJ=2*Math.PI,u6=Math.pow;function JJ(e){return e[0]}function e11(e){return e[1]}function t11(e){const{triangles:t,coords:n}=e;for(let i=0;i1e-10)return!1}return!0}function n11(e,t,n){return[e+Math.sin(e+t)*n,t+Math.cos(e-t)*n]}class Cd{static from(t,n=JJ,i=e11,r){return new Cd("length"in t?i11(t,n,i,r):Float64Array.from(r11(t,n,i,r)))}constructor(t){this._delaunator=new Rr(t),this.inedges=new Int32Array(t.length/2),this._hullIndex=new Int32Array(t.length/2),this.points=this._delaunator.coords,this._init()}update(){return this._delaunator.update(),this._init(),this}_init(){const t=this._delaunator,n=this.points;if(t.hull&&t.hull.length>2&&t11(t)){this.collinear=Int32Array.from({length:n.length/2},(_,S)=>S).sort((_,S)=>n[2*_]-n[2*S]||n[2*_+1]-n[2*S+1]);const d=this.collinear[0],p=this.collinear[this.collinear.length-1],m=[n[2*d],n[2*d+1],n[2*p],n[2*p+1]],h=1e-8*Math.hypot(m[3]-m[1],m[2]-m[0]);for(let _=0,S=n.length/2;_0&&(this.triangles=new Int32Array(3).fill(-1),this.halfedges=new Int32Array(3).fill(-1),this.triangles[0]=r[0],this.triangles[1]=r[1],this.triangles[2]=r[1],u[r[0]]=1,r.length===2&&(u[r[1]]=0))}voronoi(t){return new XJ(this,t)}*neighbors(t){const{inedges:n,hull:i,_hullIndex:r,halfedges:s,triangles:u,collinear:f}=this;if(f){const h=f.indexOf(t);h>0&&(yield f[h-1]),h=0&&s!==i&&s!==r;)i=s;return s}_step(t,n,i){const{inedges:r,hull:s,_hullIndex:u,halfedges:f,triangles:d,points:p}=this;if(r[t]===-1||!p.length)return(t+1)%(p.length>>1);let m=t,h=u6(n-p[t*2],2)+u6(i-p[t*2+1],2);const _=r[t];let S=_;do{let E=d[S];const k=u6(n-p[E*2],2)+u6(i-p[E*2+1],2);if(k-1?d1.filter(function(I1){return I1!==v1}):[].concat(d1,[v1])})},[]),U1=function(v1){var d1=v1.series,I1=v1.getPointColor,W1=v1.getPointBorderColor,E1=v1.formatX,L1=v1.formatY;return G.useMemo(function(){return d1.reduce(function(R1,p1){return[].concat(R1,p1.data.filter(function(J1){return J1.position.x!==null&&J1.position.y!==null}).map(function(J1,D1){var se={id:p1.id+"."+D1,index:R1.length+D1,serieId:p1.id,serieColor:p1.color,x:J1.position.x,y:J1.position.y};return se.color=I1(p1),se.borderColor=W1(se),se.data=Nt({},J1.data,{xFormatted:E1(J1.data.x),yFormatted:L1(J1.data.y)}),se}))},[])},[d1,I1,W1,E1,L1])}({series:w1,getPointColor:H,getPointBorderColor:Q,formatX:R,formatY:j}),O1=y11({enableSlices:B,points:U1,width:d,height:p});return{legendData:f1,toggleSerie:k1,lineGenerator:g11({curve:S}),areaGenerator:m11({curve:S,yScale:r1,areaBaselineValue:k}),getColor:$,series:w1,xScale:l1,yScale:r1,slices:O1,points:U1}},IE=function(e){var t=e.areaBlendMode,n=e.areaOpacity,i=e.color,r=e.fill,s=e.path,u=M5(),f=u.animate,d=u.config,p=ES(s),m=r0({color:i,config:d,immediate:!f});return F.jsx(R2.path,{d:p,fill:r||m.color,fillOpacity:n,strokeWidth:0,style:{mixBlendMode:t}})};IE.propTypes={areaBlendMode:Ed.isRequired,areaOpacity:C.number.isRequired,color:C.string,fill:C.string,path:C.string.isRequired};var RE=function(e){var t=e.areaGenerator,n=e.areaOpacity,i=e.areaBlendMode,r=e.lines.slice(0).reverse();return F.jsx("g",{children:r.map(function(s){return F.jsx(IE,Nt({path:t(s.data.map(function(u){return u.position}))},Nt({areaOpacity:n,areaBlendMode:i},s)),s.id)})})};RE.propTypes={areaGenerator:C.func.isRequired,areaOpacity:C.number.isRequired,areaBlendMode:Ed.isRequired,lines:C.arrayOf(C.object).isRequired};var _11=G.memo(RE),UE=function(e){var t=e.lineGenerator,n=e.points,i=e.color,r=e.thickness,s=G.useMemo(function(){return t(n)},[t,n]),u=ES(s);return F.jsx(R2.path,{d:u,fill:"none",strokeWidth:r,stroke:i})};UE.propTypes={points:C.arrayOf(C.shape({x:C.oneOfType([C.string,C.number]),y:C.oneOfType([C.string,C.number])})),lineGenerator:C.func.isRequired,color:C.string.isRequired,thickness:C.number.isRequired};var v11=G.memo(UE),$E=function(e){var t=e.lines,n=e.lineGenerator,i=e.lineWidth;return t.slice(0).reverse().map(function(r){var s=r.id,u=r.data,f=r.color;return F.jsx(v11,{id:s,points:u.map(function(d){return d.position}),lineGenerator:n,color:f,thickness:i},s)})};$E.propTypes={lines:C.arrayOf(C.shape({id:C.oneOfType([C.string,C.number]).isRequired,color:C.string.isRequired,data:C.arrayOf(C.shape({data:C.shape({x:C.oneOfType([C.string,C.number,C.instanceOf(Date)]),y:C.oneOfType([C.string,C.number,C.instanceOf(Date)])}).isRequired,position:C.shape({x:C.number,y:C.number}).isRequired})).isRequired})).isRequired,lineWidth:C.number.isRequired,lineGenerator:C.func.isRequired};var w11=G.memo($E),BE=function(e){var t=e.slice,n=e.axis,i=e.debug,r=e.tooltip,s=e.isCurrent,u=e.setCurrent,f=e.onMouseEnter,d=e.onMouseMove,p=e.onMouseLeave,m=e.onClick,h=Rf(),_=h.showTooltipFromEvent,S=h.hideTooltip,E=G.useCallback(function(w){_(G.createElement(r,{slice:t,axis:n}),w,"right"),u(t),f&&f(t,w)},[_,r,t,f]),k=G.useCallback(function(w){_(G.createElement(r,{slice:t,axis:n}),w,"right"),d&&d(t,w)},[_,r,t,d]),O=G.useCallback(function(w){S(),u(null),p&&p(t,w)},[S,t,p]),x=G.useCallback(function(w){m&&m(t,w)},[t,m]);return F.jsx("rect",{x:t.x0,y:t.y0,width:t.width,height:t.height,stroke:"red",strokeWidth:i?1:0,strokeOpacity:.75,fill:"red",fillOpacity:s&&i?.35:0,onMouseEnter:E,onMouseMove:k,onMouseLeave:O,onClick:x,"data-testid":"slice-"+t.id})};BE.propTypes={slice:C.object.isRequired,axis:C.oneOf(["x","y"]).isRequired,debug:C.bool.isRequired,height:C.number.isRequired,tooltip:C.oneOfType([C.func,C.object]),isCurrent:C.bool.isRequired,setCurrent:C.func.isRequired,onMouseEnter:C.func,onMouseMove:C.func,onMouseLeave:C.func,onClick:C.func};var x11=G.memo(BE),zE=function(e){var t=e.slices,n=e.axis,i=e.debug,r=e.height,s=e.tooltip,u=e.current,f=e.setCurrent,d=e.onMouseEnter,p=e.onMouseMove,m=e.onMouseLeave,h=e.onClick;return t.map(function(_){return F.jsx(x11,{slice:_,axis:n,debug:i,height:r,tooltip:s,setCurrent:f,isCurrent:u!==null&&u.id===_.id,onMouseEnter:d,onMouseMove:p,onMouseLeave:m,onClick:h},_.id)})};zE.propTypes={slices:C.arrayOf(C.shape({id:C.oneOfType([C.number,C.string,C.instanceOf(Date)]).isRequired,x:C.number.isRequired,y:C.number.isRequired,points:C.arrayOf(C.object).isRequired})).isRequired,axis:C.oneOf(["x","y"]).isRequired,debug:C.bool.isRequired,height:C.number.isRequired,tooltip:C.oneOfType([C.func,C.object]).isRequired,current:C.object,setCurrent:C.func.isRequired,onMouseEnter:C.func,onMouseMove:C.func,onMouseLeave:C.func,onClick:C.func};var b11=G.memo(zE),jE=function(e){var t=e.points,n=e.symbol,i=e.size,r=e.borderWidth,s=e.enableLabel,u=e.label,f=e.labelYOffset,d=Ft(),p=cY(u),m=t.slice(0).reverse().map(function(h){return{id:h.id,x:h.x,y:h.y,datum:h.data,fill:h.color,stroke:h.borderColor,label:s?p(h.data):null}});return F.jsx("g",{children:m.map(function(h){return F.jsx(sY,{x:h.x,y:h.y,datum:h.datum,symbol:n,size:i,color:h.fill,borderWidth:r,borderColor:h.stroke,label:h.label,labelYOffset:f,theme:d},h.id)})})};jE.propTypes={points:C.arrayOf(C.object),symbol:C.func,size:C.number.isRequired,color:C.func.isRequired,borderWidth:C.number.isRequired,borderColor:C.func.isRequired,enableLabel:C.bool.isRequired,label:C.oneOfType([C.string,C.func]).isRequired,labelYOffset:C.number};var S11=G.memo(jE),DE=function(e){var t=e.points,n=e.width,i=e.height,r=e.margin,s=e.setCurrent,u=e.onMouseEnter,f=e.onMouseMove,d=e.onMouseLeave,p=e.onClick,m=e.tooltip,h=e.debug,_=Rf(),S=_.showTooltipAt,E=_.hideTooltip,k=G.useCallback(function(b,N){S(G.createElement(m,{point:b}),[b.x+r.left,b.y+r.top],"top"),s(b),u&&u(b,N)},[s,S,m,u,r]),O=G.useCallback(function(b,N){S(G.createElement(m,{point:b}),[b.x+r.left,b.y+r.top],"top"),s(b),f&&f(b,N)},[s,S,m,f]),x=G.useCallback(function(b,N){E(),s(null),d&&d(b,N)},[E,s,d]),w=G.useCallback(function(b,N){p&&p(b,N)},[p]);return F.jsx(a11,{nodes:t,width:n,height:i,onMouseEnter:k,onMouseMove:O,onMouseLeave:x,onClick:w,debug:h})};DE.propTypes={points:C.arrayOf(C.object).isRequired,width:C.number.isRequired,height:C.number.isRequired,margin:C.object.isRequired,setCurrent:C.func.isRequired,onMouseEnter:C.func,onMouseMove:C.func,onMouseLeave:C.func,onClick:C.func,tooltip:C.oneOfType([C.func,C.object]).isRequired,debug:C.bool.isRequired};var E11=G.memo(DE),mc=function(e){var t=e.data,n=e.xScale,i=e.xFormat,r=e.yScale,s=e.yFormat,u=e.layers,f=e.curve,d=e.areaBaselineValue,p=e.colors,m=e.margin,h=e.width,_=e.height,S=e.axisTop,E=e.axisRight,k=e.axisBottom,O=e.axisLeft,x=e.enableGridX,w=e.enableGridY,b=e.gridXValues,N=e.gridYValues,B=e.lineWidth,R=e.enableArea,j=e.areaOpacity,$=e.areaBlendMode,K=e.enablePoints,H=e.pointSymbol,Q=e.pointSize,e1=e.pointColor,X=e.pointBorderWidth,o1=e.pointBorderColor,n1=e.enablePointLabel,l1=e.pointLabel,r1=e.pointLabelYOffset,Y=e.defs,g1=e.fill,f1=e.markers,w1=e.legends,k1=e.isInteractive,U1=e.useMesh,O1=e.debugMesh,v1=e.onMouseEnter,d1=e.onMouseMove,I1=e.onMouseLeave,W1=e.onClick,E1=e.tooltip,L1=e.enableSlices,R1=e.debugSlices,p1=e.sliceTooltip,J1=e.enableCrosshair,D1=e.crosshairType,se=e.role,we=AS(h,_,m),pe=we.margin,ge=we.innerWidth,Qe=we.innerHeight,W=we.outerWidth,T=we.outerHeight,P=FE({data:t,xScale:n,xFormat:i,yScale:r,yFormat:s,width:ge,height:Qe,colors:p,curve:f,areaBaselineValue:d,pointColor:e1,pointBorderColor:o1,enableSlices:L1}),Z=P.legendData,a1=P.toggleSerie,_1=P.lineGenerator,b1=P.areaGenerator,G1=P.series,X1=P.xScale,T1=P.yScale,q1=P.slices,fe=P.points,de=Ft(),mt=Or(e1,de),S4=Or(o1,de),B2=G.useState(null),H4=B2[0],E4=B2[1],P5=G.useState(null),z2=P5[0],fn=P5[1],u4={grid:F.jsx(CJ,{theme:de,width:ge,height:Qe,xScale:x?X1:null,yScale:w?T1:null,xValues:b,yValues:N},"grid"),markers:F.jsx(uY,{markers:f1,width:ge,height:Qe,xScale:X1,yScale:T1,theme:de},"markers"),axes:F.jsx(TJ,{xScale:X1,yScale:T1,width:ge,height:Qe,theme:de,top:S,right:E,bottom:k,left:O},"axes"),areas:null,lines:F.jsx(w11,{lines:G1,lineGenerator:_1,lineWidth:B},"lines"),slices:null,points:null,crosshair:null,mesh:null,legends:w1.map(function(Z4,hn){return F.jsx(jJ,Nt({},Z4,{containerWidth:ge,containerHeight:Qe,data:Z4.data||Z,theme:de,toggleSerie:Z4.toggleSerie?a1:void 0}),"legend."+hn)})},dn=gY(Y,G1,g1);return R&&(u4.areas=F.jsx(_11,{areaGenerator:b1,areaOpacity:j,areaBlendMode:$,lines:G1},"areas")),k1&&L1!==!1&&(u4.slices=F.jsx(b11,{slices:q1,axis:L1,debug:R1,height:Qe,tooltip:p1,current:z2,setCurrent:fn,onMouseEnter:v1,onMouseMove:d1,onMouseLeave:I1,onClick:W1},"slices")),K&&(u4.points=F.jsx(S11,{points:fe,symbol:H,size:Q,color:mt,borderWidth:X,borderColor:S4,enableLabel:n1,label:l1,labelYOffset:r1},"points")),k1&&J1&&(H4!==null&&(u4.crosshair=F.jsx(jl,{width:ge,height:Qe,x:H4.x,y:H4.y,type:D1},"crosshair")),z2!==null&&(u4.crosshair=F.jsx(jl,{width:ge,height:Qe,x:z2.x,y:z2.y,type:L1},"crosshair"))),k1&&U1&&L1===!1&&(u4.mesh=F.jsx(E11,{points:fe,width:ge,height:Qe,margin:pe,current:H4,setCurrent:E4,onMouseEnter:v1,onMouseMove:d1,onMouseLeave:I1,onClick:W1,tooltip:E1,debug:O1},"mesh")),F.jsx(US,{defs:dn,width:W,height:T,margin:pe,role:se,children:u.map(function(Z4,hn){return typeof Z4=="function"?F.jsx(G.Fragment,{children:Z4(Nt({},e,{innerWidth:ge,innerHeight:Qe,series:G1,slices:q1,points:fe,xScale:X1,yScale:T1,lineGenerator:_1,areaGenerator:b1,currentPoint:H4,setCurrentPoint:E4,currentSlice:z2,setCurrentSlice:fn}))},hn):u4[Z4]})})};mc.propTypes=d11,mc.defaultProps=i3;var M11=jS(mc),yc=function(e){var t=e.width,n=e.height,i=e.margin,r=e.pixelRatio,s=e.data,u=e.xScale,f=e.xFormat,d=e.yScale,p=e.yFormat,m=e.curve,h=e.layers,_=e.colors,S=e.lineWidth,E=e.enableArea,k=e.areaBaselineValue,O=e.areaOpacity,x=e.enablePoints,w=e.pointSize,b=e.pointColor,N=e.pointBorderWidth,B=e.pointBorderColor,R=e.enableGridX,j=e.gridXValues,$=e.enableGridY,K=e.gridYValues,H=e.axisTop,Q=e.axisRight,e1=e.axisBottom,X=e.axisLeft,o1=e.legends,n1=e.isInteractive,l1=e.debugMesh,r1=e.onMouseLeave,Y=e.onClick,g1=e.tooltip,f1=e.canvasRef,w1=G.useRef(null),k1=AS(t,n,i),U1=k1.margin,O1=k1.innerWidth,v1=k1.innerHeight,d1=k1.outerWidth,I1=k1.outerHeight,W1=Ft(),E1=G.useState(null),L1=E1[0],R1=E1[1],p1=FE({data:s,xScale:u,xFormat:f,yScale:d,yFormat:p,width:O1,height:v1,colors:_,curve:m,areaBaselineValue:k,pointColor:b,pointBorderColor:B}),J1=p1.lineGenerator,D1=p1.areaGenerator,se=p1.series,we=p1.xScale,pe=p1.yScale,ge=p1.points,Qe=PE({points:ge,width:O1,height:v1,debug:l1}),W=Qe.delaunay,T=Qe.voronoi;G.useEffect(function(){f1&&(f1.current=w1.current),w1.current.width=d1*r,w1.current.height=I1*r;var T1=w1.current.getContext("2d");T1.scale(r,r),T1.fillStyle=W1.background,T1.fillRect(0,0,d1,I1),T1.translate(U1.left,U1.top),h.forEach(function(q1){if(typeof q1=="function"&&q1({ctx:T1,innerWidth:O1,innerHeight:v1,series:se,points:ge,xScale:we,yScale:pe,lineWidth:S,lineGenerator:J1,areaGenerator:D1,currentPoint:L1,setCurrentPoint:R1}),q1==="grid"&&W1.grid.line.strokeWidth>0&&(T1.lineWidth=W1.grid.line.strokeWidth,T1.strokeStyle=W1.grid.line.stroke,R&&Vy(T1,{width:O1,height:v1,scale:we,axis:"x",values:j}),$&&Vy(T1,{width:O1,height:v1,scale:pe,axis:"y",values:K})),q1==="axes"&&OJ(T1,{xScale:we,yScale:pe,width:O1,height:v1,top:H,right:Q,bottom:e1,left:X,theme:W1}),q1==="areas"&&E===!0&&(T1.save(),T1.globalAlpha=O,D1.context(T1),se.forEach(function(de){T1.fillStyle=de.color,T1.beginPath(),D1(de.data.map(function(mt){return mt.position})),T1.fill()}),T1.restore()),q1==="lines"&&(J1.context(T1),se.forEach(function(de){T1.strokeStyle=de.color,T1.lineWidth=S,T1.beginPath(),J1(de.data.map(function(mt){return mt.position})),T1.stroke()})),q1==="points"&&x===!0&&w>0&&ge.forEach(function(de){T1.fillStyle=de.color,T1.beginPath(),T1.arc(de.x,de.y,w/2,0,2*Math.PI),T1.fill(),N>0&&(T1.strokeStyle=de.borderColor,T1.lineWidth=N,T1.stroke())}),q1==="mesh"&&l1===!0&&(u11(T1,T),L1&&l11(T1,T,L1.index)),q1==="legends"){var fe=se.map(function(de){return{id:de.id,label:de.id,color:de.color}}).reverse();o1.forEach(function(de){QJ(T1,Nt({},de,{data:de.data||fe,containerWidth:O1,containerHeight:v1,theme:W1}))})}})},[w1,d1,I1,h,W1,J1,se,we,pe,R,j,$,K,H,Q,e1,X,o1,ge,x,w,L1]);var P=G.useCallback(function(T1){var q1=DS(w1.current,T1),fe=q1[0],de=q1[1];if(!fY(U1.left,U1.top,O1,v1,fe,de))return null;var mt=W.find(fe-U1.left,de-U1.top);return ge[mt]},[w1,U1,O1,v1,W]),Z=Rf(),a1=Z.showTooltipFromEvent,_1=Z.hideTooltip,b1=G.useCallback(function(T1){var q1=P(T1);R1(q1),q1?a1(G.createElement(g1,{point:q1}),T1):_1()},[P,R1,a1,_1,g1]),G1=G.useCallback(function(T1){_1(),R1(null),L1&&r1&&r1(L1,T1)},[_1,R1,r1]),X1=G.useCallback(function(T1){if(Y){var q1=P(T1);q1&&Y(q1,T1)}},[P,Y]);return F.jsx("canvas",{ref:w1,width:d1*r,height:I1*r,style:{width:d1,height:I1,cursor:n1?"auto":"normal"},onMouseEnter:n1?b1:void 0,onMouseMove:n1?b1:void 0,onMouseLeave:n1?G1:void 0,onClick:n1?X1:void 0})};yc.propTypes=h11,yc.defaultProps=p11;var A11=jS(yc),k11=G.forwardRef(function(e,t){return F.jsx(A11,Nt({},e,{canvasRef:t}))});G.forwardRef(function(e,t){return F.jsx(OS,{children:function(n){var i=n.width,r=n.height;return F.jsx(k11,Nt({width:i,height:r},e,{ref:t}))}})});function T11(e){const t=e.replaceAll("\r","").split("---")[1].trim().split(` +`),n=t[0].split("|").map(r=>r.replaceAll(" ","_"));return t.slice(2).map(r=>Object.fromEntries(r.split("|").map((s,u)=>[n[u],s])))}const P11=()=>{const[e,t]=G.useState(),[n,i]=G.useState(90);G.useEffect(()=>{fetch("https://api.github.com/repos/osm-nz/linz-address-import/issues/1").then(s=>s.json()).then(s=>t(s.body))},[]);const r=G.useMemo(()=>{if(!e)return[];const s=T11(e);return Object.entries(Bw).map(([f,d])=>{const p=f,[,,,m]=d;return{id:p,color:m,data:s.filter((h,_)=>{var S;return h.Sync_Date!==((S=s[_-1])==null?void 0:S.Sync_Date)}).map(h=>{const _=+(100*(+h[p]/+h.Total)).toFixed(2);return{x:h.Sync_Date,y:Number.isNaN(_)?0:_}})}})},[e]);return r.length?(console.log({chartData:r}),F.jsxs("div",{children:[F.jsx(M11,{width:window.innerWidth,height:500,data:r,margin:{top:50,right:110,bottom:50,left:60},xScale:{type:"time",format:"%Y-%m-%d",useUTC:!1},xFormat:"time:%Y-%m-%d",yScale:{type:"linear",min:n,max:"auto",stacked:!0},axisBottom:null,axisRight:null,axisTop:{legend:"Time",legendOffset:36,legendPosition:"middle",format:"%Y-%m",tickValues:"every 2 months"},axisLeft:{legend:"Percentage",legendOffset:-40,legendPosition:"middle"},pointSize:0,colors:s=>s.color,enableArea:!0,areaOpacity:1}),F.jsx("button",{type:"button",onClick:()=>i(s=>Math.max(0,s-2)),children:"➖"}),F.jsx("button",{type:"button",onClick:()=>i(s=>Math.min(99,s+2)),children:"➕"})]})):F.jsx(F.Fragment,{children:"Loading…"})},Jy="https://linz-addr-cdn.kyle.kiwi",C11=()=>{const[e,t]=G.useState(),[n,i]=G.useState();if(G.useEffect(()=>{fetch(`${Jy}/stats.json`).then(s=>s.json()).then(i).catch(t)},[]),e)return F.jsx(F.Fragment,{children:"Error."});if(!n)return F.jsx(F.Fragment,{children:"Loading..."});const r=new Date(n.date);return F.jsxs("div",{style:{margin:15},children:[F.jsx("a",{href:"./RapiD/",className:"start",children:"✨ Click to start mapping!"}),F.jsxs("table",{className:"busy",children:[F.jsx("thead",{children:F.jsxs("tr",{style:{fontWeight:600},children:[F.jsx("td",{children:"Code"}),F.jsx("td",{children:"Data Category"}),F.jsx("td",{children:"No. of addresses"}),F.jsx("td",{children:"Percentage of total"}),F.jsx("td",{children:"How to action"}),F.jsx("td",{children:"Raw data"})]})}),F.jsx("tbody",{children:Object.entries(n.count).map(([s,u])=>{const[f,d,p,m,h]=Bw[s];return F.jsxs("tr",{children:[F.jsx("td",{style:{backgroundColor:m},children:f}),F.jsx("td",{children:d}),F.jsx("td",{children:u.toLocaleString("en-nz")}),F.jsxs("td",{children:[(u/n.total*100).toFixed(2),"%"]}),F.jsx("td",{children:p}),h&&F.jsx("td",{children:F.jsx("a",{href:`${Jy}/${h}`,children:"download"})})]},s)})})]}),F.jsx(P11,{}),F.jsxs("p",{style:{margin:12},children:["Statistics last updated"," ",F.jsx("strong",{children:F.jsx(vf,{date:r})})]}),F.jsxs("footer",{children:["For more infomation, see:",F.jsxs("ul",{children:[F.jsx("li",{children:F.jsx("a",{href:"https://wiki.openstreetmap.org/wiki/Import/New_Zealand_Street_Addresses_(2021)",children:"the wiki page"})}),F.jsx("li",{children:F.jsx("a",{href:"https://github.com/osm-nz/linz-address-import",children:"the repository containing the source code"})}),F.jsx("li",{children:F.jsx("a",{href:"https://osmcha.org/?aoi=5a4d6cbe-37f9-4b5b-a6d6-0c69dd488a07",children:"All changesets uploaded so far"})}),F.jsx("li",{children:F.jsx("a",{href:"#/map",children:"A map of all the sectors requiring attention"})})]})]})]})},N11=()=>F.jsxs("div",{style:{margin:16},children:[F.jsx("h1",{children:"OpenStreetMap NZ"}),F.jsxs("ul",{children:[F.jsx("li",{children:F.jsx("a",{href:"#/address-import",children:"LINZ Address Import"})}),F.jsx("li",{children:F.jsx("a",{href:"/missing-streets",children:"Missing Streets"})})]})]});function QE(e,t){const n=G.useRef(t);G.useEffect(function(){t!==n.current&&e.attributionControl!=null&&(n.current!=null&&e.attributionControl.removeAttribution(n.current),t!=null&&e.attributionControl.addAttribution(t)),n.current=t},[e,t])}const O11=1;function L11(e){return Object.freeze({__version:O11,map:e})}function d0(e,t){return Object.freeze({...e,...t})}const WE=G.createContext(null),Nd=WE.Provider;function P9(){const e=G.useContext(WE);if(e==null)throw new Error("No context provided: useLeafletContext() can only be used in a descendant of ");return e}function Od(e){function t(n,i){const{instance:r,context:s}=e(n).current;return G.useImperativeHandle(i,()=>r),n.children==null?null:U8.createElement(Nd,{value:s},n.children)}return G.forwardRef(t)}function F11(e){function t(n,i){const[r,s]=G.useState(!1),{instance:u}=e(n,s).current;G.useImperativeHandle(i,()=>u),G.useEffect(function(){r&&u.update()},[u,r,n.children]);const f=u._contentNode;return f?_f.createPortal(n.children,f):null}return G.forwardRef(t)}function I11(e){function t(n,i){const{instance:r}=e(n).current;return G.useImperativeHandle(i,()=>r),null}return G.forwardRef(t)}function R11(e){return function(n){const i=P9(),r=e(n,i),{instance:s}=r.current,u=G.useRef(n.position),{position:f}=n;return G.useEffect(function(){return s.addTo(i.map),function(){s.remove()}},[i.map,s]),G.useEffect(function(){f!=null&&f!==u.current&&(s.setPosition(f),u.current=f)},[s,f]),r}}function Ld(e,t){const n=G.useRef();G.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 fs(e,t){const n=e.pane??t.pane;return n?{...e,pane:n}:e}function U11(e,t){return function(i,r){const s=P9(),u=e(fs(i,s),s);return QE(s.map,i.attribution),Ld(u.current,i.eventHandlers),t(u.current,s,i,r),u}}var _c={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,i){i(t)})(a2,function(n){var i="1.9.4";function r(o){var l,g,v,A;for(g=1,v=arguments.length;g"u"||!L||!L.Mixin)){o=b(o)?o:[o];for(var l=0;l0?Math.floor(o):Math.ceil(o)};Y.prototype={clone:function(){return new Y(this.x,this.y)},add:function(o){return this.clone()._add(f1(o))},_add:function(o){return this.x+=o.x,this.y+=o.y,this},subtract:function(o){return this.clone()._subtract(f1(o))},_subtract:function(o){return this.x-=o.x,this.y-=o.y,this},divideBy:function(o){return this.clone()._divideBy(o)},_divideBy:function(o){return this.x/=o,this.y/=o,this},multiplyBy:function(o){return this.clone()._multiplyBy(o)},_multiplyBy:function(o){return this.x*=o,this.y*=o,this},scaleBy:function(o){return new Y(this.x*o.x,this.y*o.y)},unscaleBy:function(o){return new Y(this.x/o.x,this.y/o.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=g1(this.x),this.y=g1(this.y),this},distanceTo:function(o){o=f1(o);var l=o.x-this.x,g=o.y-this.y;return Math.sqrt(l*l+g*g)},equals:function(o){return o=f1(o),o.x===this.x&&o.y===this.y},contains:function(o){return o=f1(o),Math.abs(o.x)<=Math.abs(this.x)&&Math.abs(o.y)<=Math.abs(this.y)},toString:function(){return"Point("+_(this.x)+", "+_(this.y)+")"}};function f1(o,l,g){return o instanceof Y?o:b(o)?new Y(o[0],o[1]):o==null?o:typeof o=="object"&&"x"in o&&"y"in o?new Y(o.x,o.y):new Y(o,l,g)}function w1(o,l){if(o)for(var g=l?[o,l]:o,v=0,A=g.length;v=this.min.x&&g.x<=this.max.x&&l.y>=this.min.y&&g.y<=this.max.y},intersects:function(o){o=k1(o);var l=this.min,g=this.max,v=o.min,A=o.max,U=A.x>=l.x&&v.x<=g.x,V=A.y>=l.y&&v.y<=g.y;return U&&V},overlaps:function(o){o=k1(o);var l=this.min,g=this.max,v=o.min,A=o.max,U=A.x>l.x&&v.xl.y&&v.y=l.lat&&A.lat<=g.lat&&v.lng>=l.lng&&A.lng<=g.lng},intersects:function(o){o=O1(o);var l=this._southWest,g=this._northEast,v=o.getSouthWest(),A=o.getNorthEast(),U=A.lat>=l.lat&&v.lat<=g.lat,V=A.lng>=l.lng&&v.lng<=g.lng;return U&&V},overlaps:function(o){o=O1(o);var l=this._southWest,g=this._northEast,v=o.getSouthWest(),A=o.getNorthEast(),U=A.lat>l.lat&&v.latl.lng&&v.lng1,N9=function(){var o=!1;try{var l=Object.defineProperty({},"passive",{get:function(){o=!0}});window.addEventListener("testPassiveEventSupport",h,l),window.removeEventListener("testPassiveEventSupport",h,l)}catch{}return o}(),gs=function(){return!!document.createElement("canvas").getContext}(),h0=!!(document.createElementNS&&se("svg").createSVGRect),ms=!!h0&&function(){var o=document.createElement("div");return o.innerHTML="",(o.firstChild&&o.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"}(),p0=!h0&&function(){try{var o=document.createElement("div");o.innerHTML='';var l=o.firstChild;return l.style.behavior="url(#default#VML)",l&&typeof l.adj=="object"}catch{return!1}}(),ys=navigator.platform.indexOf("Mac")===0,g0=navigator.platform.indexOf("Linux")===0;function M4(o){return navigator.userAgent.toLowerCase().indexOf(o)>=0}var B1={ie:ge,ielt9:Qe,edge:W,webkit:T,android:P,android23:Z,androidStock:_1,opera:b1,chrome:G1,gecko:X1,safari:T1,phantom:q1,opera12:fe,win:de,ie3d:mt,webkit3d:S4,gecko3d:B2,any3d:H4,mobile:E4,mobileWebkit:P5,mobileWebkit3d:z2,msPointer:fn,pointer:u4,touch:Z4,touchNative:dn,mobileOpera:hn,mobileGecko:hs,retina:ps,passiveEvents:N9,canvas:gs,svg:h0,vml:p0,inlineSvg:ms,mac:ys,linux:g0},O9=B1.msPointer?"MSPointerDown":"pointerdown",L9=B1.msPointer?"MSPointerMove":"pointermove",F9=B1.msPointer?"MSPointerUp":"pointerup",I9=B1.msPointer?"MSPointerCancel":"pointercancel",m0={touchstart:O9,touchmove:L9,touchend:F9,touchcancel:I9},R9={touchstart:O5,touchmove:N5,touchend:N5,touchcancel:N5},j2={},U9=!1;function _s(o,l,g){return l==="touchstart"&&C5(),R9[l]?(g=R9[l].bind(this,g),o.addEventListener(m0[l],g,!1),g):(console.warn("wrong event specified:",l),h)}function vs(o,l,g){if(!m0[l]){console.warn("wrong event specified:",l);return}o.removeEventListener(m0[l],g,!1)}function ws(o){j2[o.pointerId]=o}function xs(o){j2[o.pointerId]&&(j2[o.pointerId]=o)}function $9(o){delete j2[o.pointerId]}function C5(){U9||(document.addEventListener(O9,ws,!0),document.addEventListener(L9,xs,!0),document.addEventListener(F9,$9,!0),document.addEventListener(I9,$9,!0),U9=!0)}function N5(o,l){if(l.pointerType!==(l.MSPOINTER_TYPE_MOUSE||"mouse")){l.touches=[];for(var g in j2)l.touches.push(j2[g]);l.changedTouches=[l],o(l)}}function O5(o,l){l.MSPOINTER_TYPE_TOUCH&&l.pointerType===l.MSPOINTER_TYPE_TOUCH&&te(l),N5(o,l)}function bs(o){var l={},g,v;for(v in o)g=o[v],l[v]=g&&g.bind?g.bind(o):g;return o=l,l.type="dblclick",l.detail=2,l.isTrusted=!1,l._simulated=!0,l}var Ss=200;function Es(o,l){o.addEventListener("dblclick",l);var g=0,v;function A(U){if(U.detail!==1){v=U.detail;return}if(!(U.pointerType==="mouse"||U.sourceCapabilities&&!U.sourceCapabilities.firesTouchEvents)){var V=Z9(U);if(!(V.some(function(u1){return u1 instanceof HTMLLabelElement&&u1.attributes.for})&&!V.some(function(u1){return u1 instanceof HTMLInputElement||u1 instanceof HTMLSelectElement}))){var s1=Date.now();s1-g<=Ss?(v++,v===2&&l(bs(U))):v=1,g=s1}}}return o.addEventListener("click",A),{dblclick:l,simDblclick:A}}function B9(o,l){o.removeEventListener("dblclick",l.dblclick),o.removeEventListener("click",l.simDblclick)}var L5=v3(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),_3=v3(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),z9=_3==="webkitTransition"||_3==="OTransition"?_3+"End":"transitionend";function j9(o){return typeof o=="string"?document.getElementById(o):o}function pn(o,l){var g=o.style[l]||o.currentStyle&&o.currentStyle[l];if((!g||g==="auto")&&document.defaultView){var v=document.defaultView.getComputedStyle(o,null);g=v?v[l]:null}return g==="auto"?null:g}function xe(o,l,g){var v=document.createElement(o);return v.className=l||"",g&&g.appendChild(v),v}function Oe(o){var l=o.parentNode;l&&l.removeChild(o)}function gn(o){for(;o.firstChild;)o.removeChild(o.firstChild)}function D2(o){var l=o.parentNode;l&&l.lastChild!==o&&l.appendChild(o)}function m2(o){var l=o.parentNode;l&&l.firstChild!==o&&l.insertBefore(o,l.firstChild)}function y0(o,l){if(o.classList!==void 0)return o.classList.contains(l);var g=I5(o);return g.length>0&&new RegExp("(^|\\s)"+l+"(\\s|$)").test(g)}function ee(o,l){if(o.classList!==void 0)for(var g=E(l),v=0,A=g.length;v0?2*window.devicePixelRatio:1;function q9(o){return B1.edge?o.wheelDeltaY/2:o.deltaY&&o.deltaMode===0?-o.deltaY/Ms:o.deltaY&&o.deltaMode===1?-o.deltaY*20:o.deltaY&&o.deltaMode===2?-o.deltaY*60:o.deltaX||o.deltaZ?0:o.wheelDelta?(o.wheelDeltaY||o.wheelDelta)/2:o.detail&&Math.abs(o.detail)<32765?-o.detail*20:o.detail?o.detail/-32765*60:0}function S0(o,l){var g=l.relatedTarget;if(!g)return!0;try{for(;g&&g!==o;)g=g.parentNode}catch{return!1}return g!==o}var As={__proto__:null,on:K1,off:Pe,stopPropagation:H2,disableScrollPropagation:b0,disableClickPropagation:_n,preventDefault:te,stop:be,getPropagationPath:Z9,getMousePosition:G9,getWheelDelta:q9,isExternalTarget:S0,addListener:K1,removeListener:Pe},E0=r1.extend({run:function(o,l,g,v){this.stop(),this._el=o,this._inProgress=!0,this._duration=g||.25,this._easeOutPower=1/Math.max(v||.5,.2),this._startPos=G4(o),this._offset=l.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=Q(this._animate,this),this._step()},_step:function(o){var l=+new Date-this._startTime,g=this._duration*1e3;lthis.options.maxZoom)?this.setZoom(o):this},panInsideBounds:function(o,l){this._enforcingBounds=!0;var g=this.getCenter(),v=this._limitCenter(g,this._zoom,O1(o));return g.equals(v)||this.panTo(v,l),this._enforcingBounds=!1,this},panInside:function(o,l){l=l||{};var g=f1(l.paddingTopLeft||l.padding||[0,0]),v=f1(l.paddingBottomRight||l.padding||[0,0]),A=this.project(this.getCenter()),U=this.project(o),V=this.getPixelBounds(),s1=k1([V.min.add(g),V.max.subtract(v)]),u1=s1.getSize();if(!s1.contains(U)){this._enforcingBounds=!0;var x1=U.subtract(s1.getCenter()),C1=s1.extend(U).getSize().subtract(u1);A.x+=x1.x<0?-C1.x:C1.x,A.y+=x1.y<0?-C1.y:C1.y,this.panTo(this.unproject(A),l),this._enforcingBounds=!1}return this},invalidateSize:function(o){if(!this._loaded)return this;o=r({animate:!1,pan:!0},o===!0?{animate:!0}:o);var l=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var g=this.getSize(),v=l.divideBy(2).round(),A=g.divideBy(2).round(),U=v.subtract(A);return!U.x&&!U.y?this:(o.animate&&o.pan?this.panBy(U):(o.pan&&this._rawPanBy(U),this.fire("move"),o.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(u(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:l,newSize:g}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(o){if(o=this._locateOptions=r({timeout:1e4,watch:!1},o),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var l=u(this._handleGeolocationResponse,this),g=u(this._handleGeolocationError,this);return o.watch?this._locationWatchId=navigator.geolocation.watchPosition(l,g,o):navigator.geolocation.getCurrentPosition(l,g,o),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(o){if(this._container._leaflet_id){var l=o.code,g=o.message||(l===1?"permission denied":l===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:l,message:"Geolocation error: "+g+"."})}},_handleGeolocationResponse:function(o){if(this._container._leaflet_id){var l=o.coords.latitude,g=o.coords.longitude,v=new v1(l,g),A=v.toBounds(o.coords.accuracy*2),U=this._locateOptions;if(U.setView){var V=this.getBoundsZoom(A);this.setView(v,U.maxZoom?Math.min(V,U.maxZoom):V)}var s1={latlng:v,bounds:A,timestamp:o.timestamp};for(var u1 in o.coords)typeof o.coords[u1]=="number"&&(s1[u1]=o.coords[u1]);this.fire("locationfound",s1)}},addHandler:function(o,l){if(!l)return this;var g=this[o]=new l(this);return this._handlers.push(g),this.options[o]&&g.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(),Oe(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(e1(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var o;for(o in this._layers)this._layers[o].remove();for(o in this._panes)Oe(this._panes[o]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(o,l){var g="leaflet-pane"+(o?" leaflet-"+o.replace("Pane","")+"-pane":""),v=xe("div",g,l||this._mapPane);return o&&(this._panes[o]=v),v},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var o=this.getPixelBounds(),l=this.unproject(o.getBottomLeft()),g=this.unproject(o.getTopRight());return new U1(l,g)},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(o,l,g){o=O1(o),g=f1(g||[0,0]);var v=this.getZoom()||0,A=this.getMinZoom(),U=this.getMaxZoom(),V=o.getNorthWest(),s1=o.getSouthEast(),u1=this.getSize().subtract(g),x1=k1(this.project(s1,v),this.project(V,v)).getSize(),C1=B1.any3d?this.options.zoomSnap:1,j1=u1.x/x1.x,re=u1.y/x1.y,Ve=l?Math.max(j1,re):Math.min(j1,re);return v=this.getScaleZoom(Ve,v),C1&&(v=Math.round(v/(C1/100))*(C1/100),v=l?Math.ceil(v/C1)*C1:Math.floor(v/C1)*C1),Math.max(A,Math.min(U,v))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new Y(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(o,l){var g=this._getTopLeftPoint(o,l);return new w1(g,g.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(o){return this.options.crs.getProjectedBounds(o===void 0?this.getZoom():o)},getPane:function(o){return typeof o=="string"?this._panes[o]:o},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(o,l){var g=this.options.crs;return l=l===void 0?this._zoom:l,g.scale(o)/g.scale(l)},getScaleZoom:function(o,l){var g=this.options.crs;l=l===void 0?this._zoom:l;var v=g.zoom(o*g.scale(l));return isNaN(v)?1/0:v},project:function(o,l){return l=l===void 0?this._zoom:l,this.options.crs.latLngToPoint(d1(o),l)},unproject:function(o,l){return l=l===void 0?this._zoom:l,this.options.crs.pointToLatLng(f1(o),l)},layerPointToLatLng:function(o){var l=f1(o).add(this.getPixelOrigin());return this.unproject(l)},latLngToLayerPoint:function(o){var l=this.project(d1(o))._round();return l._subtract(this.getPixelOrigin())},wrapLatLng:function(o){return this.options.crs.wrapLatLng(d1(o))},wrapLatLngBounds:function(o){return this.options.crs.wrapLatLngBounds(O1(o))},distance:function(o,l){return this.options.crs.distance(d1(o),d1(l))},containerPointToLayerPoint:function(o){return f1(o).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(o){return f1(o).add(this._getMapPanePos())},containerPointToLatLng:function(o){var l=this.containerPointToLayerPoint(f1(o));return this.layerPointToLatLng(l)},latLngToContainerPoint:function(o){return this.layerPointToContainerPoint(this.latLngToLayerPoint(d1(o)))},mouseEventToContainerPoint:function(o){return G9(o,this._container)},mouseEventToLayerPoint:function(o){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(o))},mouseEventToLatLng:function(o){return this.layerPointToLatLng(this.mouseEventToLayerPoint(o))},_initContainer:function(o){var l=this._container=j9(o);if(l){if(l._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");K1(l,"scroll",this._onScroll,this),this._containerId=d(l)},_initLayout:function(){var o=this._container;this._fadeAnimated=this.options.fadeAnimation&&B1.any3d,ee(o,"leaflet-container"+(B1.touch?" leaflet-touch":"")+(B1.retina?" leaflet-retina":"")+(B1.ielt9?" leaflet-oldie":"")+(B1.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var l=pn(o,"position");l!=="absolute"&&l!=="relative"&&l!=="fixed"&&l!=="sticky"&&(o.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var o=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),We(this._mapPane,new Y(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(ee(o.markerPane,"leaflet-zoom-hide"),ee(o.shadowPane,"leaflet-zoom-hide"))},_resetView:function(o,l,g){We(this._mapPane,new Y(0,0));var v=!this._loaded;this._loaded=!0,l=this._limitZoom(l),this.fire("viewprereset");var A=this._zoom!==l;this._moveStart(A,g)._move(o,l)._moveEnd(A),this.fire("viewreset"),v&&this.fire("load")},_moveStart:function(o,l){return o&&this.fire("zoomstart"),l||this.fire("movestart"),this},_move:function(o,l,g,v){l===void 0&&(l=this._zoom);var A=this._zoom!==l;return this._zoom=l,this._lastCenter=o,this._pixelOrigin=this._getNewPixelOrigin(o),v?g&&g.pinch&&this.fire("zoom",g):((A||g&&g.pinch)&&this.fire("zoom",g),this.fire("move",g)),this},_moveEnd:function(o){return o&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return e1(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(o){We(this._mapPane,this._getMapPanePos().subtract(o))},_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(o){this._targets={},this._targets[d(this._container)]=this;var l=o?Pe:K1;l(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&l(window,"resize",this._onResize,this),B1.any3d&&this.options.transform3DLimit&&(o?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){e1(this._resizeRequest),this._resizeRequest=Q(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var o=this._getMapPanePos();Math.max(Math.abs(o.x),Math.abs(o.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(o,l){for(var g=[],v,A=l==="mouseout"||l==="mouseover",U=o.target||o.srcElement,V=!1;U;){if(v=this._targets[d(U)],v&&(l==="click"||l==="preclick")&&this._draggableMoved(v)){V=!0;break}if(v&&v.listens(l,!0)&&(A&&!S0(U,o)||(g.push(v),A))||U===this._container)break;U=U.parentNode}return!g.length&&!V&&!A&&this.listens(l,!0)&&(g=[this]),g},_isClickDisabled:function(o){for(;o&&o!==this._container;){if(o._leaflet_disable_click)return!0;o=o.parentNode}},_handleDOMEvent:function(o){var l=o.target||o.srcElement;if(!(!this._loaded||l._leaflet_disable_events||o.type==="click"&&this._isClickDisabled(l))){var g=o.type;g==="mousedown"&&B5(l),this._fireDOMEvent(o,g)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(o,l,g){if(o.type==="click"){var v=r({},o);v.type="preclick",this._fireDOMEvent(v,v.type,g)}var A=this._findEventTargets(o,l);if(g){for(var U=[],V=0;V0?Math.round(o-l)/2:Math.max(0,Math.ceil(o))-Math.max(0,Math.floor(l))},_limitZoom:function(o){var l=this.getMinZoom(),g=this.getMaxZoom(),v=B1.any3d?this.options.zoomSnap:1;return v&&(o=Math.round(o/v)*v),Math.max(l,Math.min(g,o))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){Le(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(o,l){var g=this._getCenterOffset(o)._trunc();return(l&&l.animate)!==!0&&!this.getSize().contains(g)?!1:(this.panBy(g,l),!0)},_createAnimProxy:function(){var o=this._proxy=xe("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(o),this.on("zoomanim",function(l){var g=L5,v=this._proxy.style[g];Q2(this._proxy,this.project(l.center,l.zoom),this.getZoomScale(l.zoom,1)),v===this._proxy.style[g]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){Oe(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var o=this.getCenter(),l=this.getZoom();Q2(this._proxy,this.project(o,l),this.getZoomScale(l,1))},_catchTransitionEnd:function(o){this._animatingZoom&&o.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(o,l,g){if(this._animatingZoom)return!0;if(g=g||{},!this._zoomAnimated||g.animate===!1||this._nothingToAnimate()||Math.abs(l-this._zoom)>this.options.zoomAnimationThreshold)return!1;var v=this.getZoomScale(l),A=this._getCenterOffset(o)._divideBy(1-1/v);return g.animate!==!0&&!this.getSize().contains(A)?!1:(Q(function(){this._moveStart(!0,g.noMoveStart||!1)._animateZoom(o,l,!0)},this),!0)},_animateZoom:function(o,l,g,v){this._mapPane&&(g&&(this._animatingZoom=!0,this._animateToCenter=o,this._animateToZoom=l,ee(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:o,zoom:l,noUpdate:v}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(u(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&Le(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 rt(o,l){return new me(o,l)}var Rt=o1.extend({options:{position:"topright"},initialize:function(o){k(this,o)},getPosition:function(){return this.options.position},setPosition:function(o){var l=this._map;return l&&l.removeControl(this),this.options.position=o,l&&l.addControl(this),this},getContainer:function(){return this._container},addTo:function(o){this.remove(),this._map=o;var l=this._container=this.onAdd(o),g=this.getPosition(),v=o._controlCorners[g];return ee(l,"leaflet-control"),g.indexOf("bottom")!==-1?v.insertBefore(l,v.firstChild):v.appendChild(l),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(Oe(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(o){this._map&&o&&o.screenX>0&&o.screenY>0&&this._map.getContainer().focus()}}),l4=function(o){return new Rt(o)};me.include({addControl:function(o){return o.addTo(this),this},removeControl:function(o){return o.remove(),this},_initControlPos:function(){var o=this._controlCorners={},l="leaflet-",g=this._controlContainer=xe("div",l+"control-container",this._container);function v(A,U){var V=l+A+" "+l+U;o[A+U]=xe("div",V,g)}v("top","left"),v("top","right"),v("bottom","left"),v("bottom","right")},_clearControlPos:function(){for(var o in this._controlCorners)Oe(this._controlCorners[o]);Oe(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var M0=Rt.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(o,l,g,v){return g1,this._baseLayersList.style.display=o?"":"none"),this._separator.style.display=l&&o?"":"none",this},_onLayerChange:function(o){this._handlingClick||this._update();var l=this._getLayer(d(o.target)),g=l.overlay?o.type==="add"?"overlayadd":"overlayremove":o.type==="add"?"baselayerchange":null;g&&this._map.fire(g,l)},_createRadioElement:function(o,l){var g='",v=document.createElement("div");return v.innerHTML=g,v.firstChild},_addItem:function(o){var l=document.createElement("label"),g=this._map.hasLayer(o.layer),v;o.overlay?(v=document.createElement("input"),v.type="checkbox",v.className="leaflet-control-layers-selector",v.defaultChecked=g):v=this._createRadioElement("leaflet-base-layers_"+d(this),g),this._layerControlInputs.push(v),v.layerId=d(o.layer),K1(v,"click",this._onInputClick,this);var A=document.createElement("span");A.innerHTML=" "+o.name;var U=document.createElement("span");l.appendChild(U),U.appendChild(v),U.appendChild(A);var V=o.overlay?this._overlaysList:this._baseLayersList;return V.appendChild(l),this._checkDisabledLayers(),l},_onInputClick:function(){if(!this._preventClick){var o=this._layerControlInputs,l,g,v=[],A=[];this._handlingClick=!0;for(var U=o.length-1;U>=0;U--)l=o[U],g=this._getLayer(l.layerId).layer,l.checked?v.push(g):l.checked||A.push(g);for(U=0;U=0;A--)l=o[A],g=this._getLayer(l.layerId).layer,l.disabled=g.options.minZoom!==void 0&&vg.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var o=this._section;this._preventClick=!0,K1(o,"click",te),this.expand();var l=this;setTimeout(function(){Pe(o,"click",te),l._preventClick=!1})}}),A0=function(o,l,g){return new M0(o,l,g)},bt=Rt.extend({options:{position:"topleft",zoomInText:'',zoomInTitle:"Zoom in",zoomOutText:'',zoomOutTitle:"Zoom out"},onAdd:function(o){var l="leaflet-control-zoom",g=xe("div",l+" leaflet-bar"),v=this.options;return this._zoomInButton=this._createButton(v.zoomInText,v.zoomInTitle,l+"-in",g,this._zoomIn),this._zoomOutButton=this._createButton(v.zoomOutText,v.zoomOutTitle,l+"-out",g,this._zoomOut),this._updateDisabled(),o.on("zoomend zoomlevelschange",this._updateDisabled,this),g},onRemove:function(o){o.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(o){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(o.shiftKey?3:1))},_createButton:function(o,l,g,v,A){var U=xe("a",g,v);return U.innerHTML=o,U.href="#",U.title=l,U.setAttribute("role","button"),U.setAttribute("aria-label",l),_n(U),K1(U,"click",be),K1(U,"click",A,this),K1(U,"click",this._refocusOnMap,this),U},_updateDisabled:function(){var o=this._map,l="leaflet-disabled";Le(this._zoomInButton,l),Le(this._zoomOutButton,l),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||o._zoom===o.getMinZoom())&&(ee(this._zoomOutButton,l),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||o._zoom===o.getMaxZoom())&&(ee(this._zoomInButton,l),this._zoomInButton.setAttribute("aria-disabled","true"))}});me.mergeOptions({zoomControl:!0}),me.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new bt,this.addControl(this.zoomControl))});var V9=function(o){return new bt(o)},k0=Rt.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(o){var l="leaflet-control-scale",g=xe("div",l),v=this.options;return this._addScales(v,l+"-line",g),o.on(v.updateWhenIdle?"moveend":"move",this._update,this),o.whenReady(this._update,this),g},onRemove:function(o){o.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(o,l,g){o.metric&&(this._mScale=xe("div",l,g)),o.imperial&&(this._iScale=xe("div",l,g))},_update:function(){var o=this._map,l=o.getSize().y/2,g=o.distance(o.containerPointToLatLng([0,l]),o.containerPointToLatLng([this.options.maxWidth,l]));this._updateScales(g)},_updateScales:function(o){this.options.metric&&o&&this._updateMetric(o),this.options.imperial&&o&&this._updateImperial(o)},_updateMetric:function(o){var l=this._getRoundNum(o),g=l<1e3?l+" m":l/1e3+" km";this._updateScale(this._mScale,g,l/o)},_updateImperial:function(o){var l=o*3.2808399,g,v,A;l>5280?(g=l/5280,v=this._getRoundNum(g),this._updateScale(this._iScale,v+" mi",v/g)):(A=this._getRoundNum(l),this._updateScale(this._iScale,A+" ft",A/l))},_updateScale:function(o,l,g){o.style.width=Math.round(this.options.maxWidth*g)+"px",o.innerHTML=l},_getRoundNum:function(o){var l=Math.pow(10,(Math.floor(o)+"").length-1),g=o/l;return g=g>=10?10:g>=5?5:g>=3?3:g>=2?2:1,l*g}}),Y9=function(o){return new k0(o)},X9='',j5=Rt.extend({options:{position:"bottomright",prefix:''+(B1.inlineSvg?X9+" ":"")+"Leaflet"},initialize:function(o){k(this,o),this._attributions={}},onAdd:function(o){o.attributionControl=this,this._container=xe("div","leaflet-control-attribution"),_n(this._container);for(var l in o._layers)o._layers[l].getAttribution&&this.addAttribution(o._layers[l].getAttribution());return this._update(),o.on("layeradd",this._addAttribution,this),this._container},onRemove:function(o){o.off("layeradd",this._addAttribution,this)},_addAttribution:function(o){o.layer.getAttribution&&(this.addAttribution(o.layer.getAttribution()),o.layer.once("remove",function(){this.removeAttribution(o.layer.getAttribution())},this))},setPrefix:function(o){return this.options.prefix=o,this._update(),this},addAttribution:function(o){return o?(this._attributions[o]||(this._attributions[o]=0),this._attributions[o]++,this._update(),this):this},removeAttribution:function(o){return o?(this._attributions[o]&&(this._attributions[o]--,this._update()),this):this},_update:function(){if(this._map){var o=[];for(var l in this._attributions)this._attributions[l]&&o.push(l);var g=[];this.options.prefix&&g.push(this.options.prefix),o.length&&g.push(o.join(", ")),this._container.innerHTML=g.join(' ')}}});me.mergeOptions({attributionControl:!0}),me.addInitHook(function(){this.options.attributionControl&&new j5().addTo(this)});var K9=function(o){return new j5(o)};Rt.Layers=M0,Rt.Zoom=bt,Rt.Scale=k0,Rt.Attribution=j5,l4.layers=A0,l4.zoom=V9,l4.scale=Y9,l4.attribution=K9;var ze=o1.extend({initialize:function(o){this._map=o},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}});ze.addTo=function(o,l){return o.addHandler(l,this),this};var ks={Events:l1},Ut=B1.touch?"touchstart mousedown":"mousedown",y2=r1.extend({options:{clickTolerance:3},initialize:function(o,l,g,v){k(this,v),this._element=o,this._dragStartTarget=l||o,this._preventOutline=g},enable:function(){this._enabled||(K1(this._dragStartTarget,Ut,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(y2._dragging===this&&this.finishDrag(!0),Pe(this._dragStartTarget,Ut,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(o){if(this._enabled&&(this._moved=!1,!y0(this._element,"leaflet-zoom-anim"))){if(o.touches&&o.touches.length!==1){y2._dragging===this&&this.finishDrag();return}if(!(y2._dragging||o.shiftKey||o.which!==1&&o.button!==1&&!o.touches)&&(y2._dragging=this,this._preventOutline&&B5(this._element),_0(),W2(),!this._moving)){this.fire("down");var l=o.touches?o.touches[0]:o,g=Q9(this._element);this._startPoint=new Y(l.clientX,l.clientY),this._startPos=G4(this._element),this._parentScale=v0(g);var v=o.type==="mousedown";K1(document,v?"mousemove":"touchmove",this._onMove,this),K1(document,v?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(o){if(this._enabled){if(o.touches&&o.touches.length>1){this._moved=!0;return}var l=o.touches&&o.touches.length===1?o.touches[0]:o,g=new Y(l.clientX,l.clientY)._subtract(this._startPoint);!g.x&&!g.y||Math.abs(g.x)+Math.abs(g.y)U&&(V=s1,U=u1);U>g&&(l[V]=1,vn(o,l,g,v,V),vn(o,l,g,V,A))}function Ps(o,l){for(var g=[o[0]],v=1,A=0,U=o.length;vl&&(g.push(o[v]),A=v);return Al.max.x&&(g|=2),o.yl.max.y&&(g|=8),g}function b3(o,l){var g=l.x-o.x,v=l.y-o.y;return g*g+v*v}function xn(o,l,g,v){var A=l.x,U=l.y,V=g.x-A,s1=g.y-U,u1=V*V+s1*s1,x1;return u1>0&&(x1=((o.x-A)*V+(o.y-U)*s1)/u1,x1>1?(A=g.x,U=g.y):x1>0&&(A+=V*x1,U+=s1*x1)),V=o.x-A,s1=o.y-U,v?V*V+s1*s1:new Y(A,U)}function $t(o){return!b(o[0])||typeof o[0][0]!="object"&&typeof o[0][0]<"u"}function N0(o){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),$t(o)}function D5(o,l){var g,v,A,U,V,s1,u1,x1;if(!o||o.length===0)throw new Error("latlngs not passed");$t(o)||(console.warn("latlngs are not flat! Only the first ring will be used"),o=o[0]);var C1=d1([0,0]),j1=O1(o),re=j1.getNorthWest().distanceTo(j1.getSouthWest())*j1.getNorthEast().distanceTo(j1.getNorthWest());re<1700&&(C1=x3(o));var Ve=o.length,je=[];for(g=0;gv){u1=(U-v)/A,x1=[s1.x-u1*(s1.x-V.x),s1.y-u1*(s1.y-V.y)];break}var ot=l.unproject(f1(x1));return d1([ot.lat+C1.lat,ot.lng+C1.lng])}var O0={__proto__:null,simplify:Ce,pointToSegmentDistance:V4,closestPointOnSegment:C0,clipSegment:ei,_getEdgeIntersection:wn,_getBitCode:T4,_sqClosestPointOnSegment:xn,isFlat:$t,_flat:N0,polylineCenter:D5},Q5={project:function(o){return new Y(o.lng,o.lat)},unproject:function(o){return new v1(o.y,o.x)},bounds:new w1([-180,-90],[180,90])},L0={R:6378137,R_MINOR:6356752314245179e-9,bounds:new w1([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(o){var l=Math.PI/180,g=this.R,v=o.lat*l,A=this.R_MINOR/g,U=Math.sqrt(1-A*A),V=U*Math.sin(v),s1=Math.tan(Math.PI/4-v/2)/Math.pow((1-V)/(1+V),U/2);return v=-g*Math.log(Math.max(s1,1e-10)),new Y(o.lng*l*g,v)},unproject:function(o){for(var l=180/Math.PI,g=this.R,v=this.R_MINOR/g,A=Math.sqrt(1-v*v),U=Math.exp(-o.y/g),V=Math.PI/2-2*Math.atan(U),s1=0,u1=.1,x1;s1<15&&Math.abs(u1)>1e-7;s1++)x1=A*Math.sin(V),x1=Math.pow((1-x1)/(1+x1),A/2),u1=Math.PI/2-2*Math.atan(U*x1)-V,V+=u1;return new v1(V*l,o.x*l/g)}},F0={__proto__:null,LonLat:Q5,Mercator:L0,SphericalMercator:L1},I0=r({},W1,{code:"EPSG:3395",projection:L0,transformation:function(){var o=.5/(Math.PI*L0.R);return p1(o,.5,-o,.5)}()}),ti=r({},W1,{code:"EPSG:4326",projection:Q5,transformation:p1(1/180,1,-1/180,.5)}),ni=r({},I1,{projection:Q5,transformation:p1(1,0,-1,0),scale:function(o){return Math.pow(2,o)},zoom:function(o){return Math.log(o)/Math.LN2},distance:function(o,l){var g=l.lng-o.lng,v=l.lat-o.lat;return Math.sqrt(g*g+v*v)},infinite:!0});I1.Earth=W1,I1.EPSG3395=I0,I1.EPSG3857=J1,I1.EPSG900913=D1,I1.EPSG4326=ti,I1.Simple=ni;var Re=r1.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(o){return o.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(o){return o&&o.removeLayer(this),this},getPane:function(o){return this._map.getPane(o?this.options[o]||o:this.options.pane)},addInteractiveTarget:function(o){return this._map._targets[d(o)]=this,this},removeInteractiveTarget:function(o){return delete this._map._targets[d(o)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(o){var l=o.target;if(l.hasLayer(this)){if(this._map=l,this._zoomAnimated=l._zoomAnimated,this.getEvents){var g=this.getEvents();l.on(g,this),this.once("remove",function(){l.off(g,this)},this)}this.onAdd(l),this.fire("add"),l.fire("layeradd",{layer:this})}}});me.include({addLayer:function(o){if(!o._layerAdd)throw new Error("The provided object is not a Layer.");var l=d(o);return this._layers[l]?this:(this._layers[l]=o,o._mapToAdd=this,o.beforeAdd&&o.beforeAdd(this),this.whenReady(o._layerAdd,o),this)},removeLayer:function(o){var l=d(o);return this._layers[l]?(this._loaded&&o.onRemove(this),delete this._layers[l],this._loaded&&(this.fire("layerremove",{layer:o}),o.fire("remove")),o._map=o._mapToAdd=null,this):this},hasLayer:function(o){return d(o)in this._layers},eachLayer:function(o,l){for(var g in this._layers)o.call(l,this._layers[g]);return this},_addLayers:function(o){o=o?b(o)?o:[o]:[];for(var l=0,g=o.length;lthis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()=2&&l[0]instanceof v1&&l[0].equals(l[g-1])&&l.pop(),l},_setLatLngs:function(o){Vt.prototype._setLatLngs.call(this,o),$t(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return $t(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var o=this._renderer._bounds,l=this.options.weight,g=new Y(l,l);if(o=new w1(o.min.subtract(g),o.max.add(g)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(o))){if(this.options.noClip){this._parts=this._rings;return}for(var v=0,A=this._rings.length,U;vo.y!=A.y>o.y&&o.x<(A.x-v.x)*(o.y-v.y)/(A.y-v.y)+v.x&&(l=!l);return l||Vt.prototype._containsPoint.call(this,o,!0)}});function Os(o,l){return new M3(o,l)}var St=P4.extend({initialize:function(o,l){k(this,l),this._layers={},o&&this.addData(o)},addData:function(o){var l=b(o)?o:o.features,g,v,A;if(l){for(g=0,v=l.length;g0&&A.push(A[0].slice()),A}function A3(o,l){return o.feature?r({},o.feature,{geometry:l}):Y4(l)}function Y4(o){return o.type==="Feature"||o.type==="FeatureCollection"?o:{type:"Feature",properties:{},geometry:o}}var t1={toGeoJSON:function(o){return A3(this,{type:"Point",coordinates:B0(this.getLatLng(),o)})}};W5.include(t1),Z5.include(t1),H5.include(t1),Vt.include({toGeoJSON:function(o){var l=!$t(this._latlngs),g=q5(this._latlngs,l?1:0,!1,o);return A3(this,{type:(l?"Multi":"")+"LineString",coordinates:g})}}),M3.include({toGeoJSON:function(o){var l=!$t(this._latlngs),g=l&&!$t(this._latlngs[0]),v=q5(this._latlngs,g?2:l?1:0,!0,o);return l||(v=[v]),A3(this,{type:(g?"Multi":"")+"Polygon",coordinates:v})}}),_2.include({toMultiPoint:function(o){var l=[];return this.eachLayer(function(g){l.push(g.toGeoJSON(o).geometry.coordinates)}),A3(this,{type:"MultiPoint",coordinates:l})},toGeoJSON:function(o){var l=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(l==="MultiPoint")return this.toMultiPoint(o);var g=l==="GeometryCollection",v=[];return this.eachLayer(function(A){if(A.toGeoJSON){var U=A.toGeoJSON(o);if(g)v.push(U.geometry);else{var V=Y4(U);V.type==="FeatureCollection"?v.push.apply(v,V.features):v.push(V)}}}),g?A3(this,{geometries:v,type:"GeometryCollection"}):{type:"FeatureCollection",features:v}}});function h1(o,l){return new St(o,l)}var c1=h1,N1=Re.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(o,l,g){this._url=o,this._bounds=O1(l),k(this,g)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(ee(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){Oe(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(o){return this.options.opacity=o,this._image&&this._updateOpacity(),this},setStyle:function(o){return o.opacity&&this.setOpacity(o.opacity),this},bringToFront:function(){return this._map&&D2(this._image),this},bringToBack:function(){return this._map&&m2(this._image),this},setUrl:function(o){return this._url=o,this._image&&(this._image.src=o),this},setBounds:function(o){return this._bounds=O1(o),this._map&&this._reset(),this},getEvents:function(){var o={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(o.zoomanim=this._animateZoom),o},setZIndex:function(o){return this.options.zIndex=o,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var o=this._url.tagName==="IMG",l=this._image=o?this._url:xe("img");if(ee(l,"leaflet-image-layer"),this._zoomAnimated&&ee(l,"leaflet-zoom-animated"),this.options.className&&ee(l,this.options.className),l.onselectstart=h,l.onmousemove=h,l.onload=u(this.fire,this,"load"),l.onerror=u(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(l.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),o){this._url=l.src;return}l.src=this._url,l.alt=this.options.alt},_animateZoom:function(o){var l=this._map.getZoomScale(o.zoom),g=this._map._latLngBoundsToNewLayerBounds(this._bounds,o.zoom,o.center).min;Q2(this._image,g,l)},_reset:function(){var o=this._image,l=new w1(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),g=l.getSize();We(o,l.min),o.style.width=g.x+"px",o.style.height=g.y+"px"},_updateOpacity:function(){It(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 o=this.options.errorOverlayUrl;o&&this._url!==o&&(this._url=o,this._image.src=o)},getCenter:function(){return this._bounds.getCenter()}}),V1=function(o,l,g){return new N1(o,l,g)},Se=N1.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var o=this._url.tagName==="VIDEO",l=this._image=o?this._url:xe("video");if(ee(l,"leaflet-image-layer"),this._zoomAnimated&&ee(l,"leaflet-zoom-animated"),this.options.className&&ee(l,this.options.className),l.onselectstart=h,l.onmousemove=h,l.onloadeddata=u(this.fire,this,"load"),o){for(var g=l.getElementsByTagName("source"),v=[],A=0;A0?v:[l.src];return}b(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(l.style,"objectFit")&&(l.style.objectFit="fill"),l.autoplay=!!this.options.autoplay,l.loop=!!this.options.loop,l.muted=!!this.options.muted,l.playsInline=!!this.options.playsInline;for(var U=0;UA?(l.height=A+"px",ee(o,U)):Le(o,U),this._containerWidth=this._container.offsetWidth},_animateZoom:function(o){var l=this._map._latLngToNewLayerPoint(this._latlng,o.zoom,o.center),g=this._getAnchor();We(this._container,l.add(g))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var o=this._map,l=parseInt(pn(this._container,"marginBottom"),10)||0,g=this._container.offsetHeight+l,v=this._containerWidth,A=new Y(this._containerLeft,-g-this._containerBottom);A._add(G4(this._container));var U=o.layerPointToContainerPoint(A),V=f1(this.options.autoPanPadding),s1=f1(this.options.autoPanPaddingTopLeft||V),u1=f1(this.options.autoPanPaddingBottomRight||V),x1=o.getSize(),C1=0,j1=0;U.x+v+u1.x>x1.x&&(C1=U.x+v-x1.x+u1.x),U.x-C1-s1.x<0&&(C1=U.x-s1.x),U.y+g+u1.y>x1.y&&(j1=U.y+g-x1.y+u1.y),U.y-j1-s1.y<0&&(j1=U.y-s1.y),(C1||j1)&&(this.options.keepInView&&(this._autopanning=!0),o.fire("autopanstart").panBy([C1,j1]))}},_getAnchor:function(){return f1(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),V5=function(o,l){return new yt(o,l)};me.mergeOptions({closePopupOnClick:!0}),me.include({openPopup:function(o,l,g){return this._initOverlay(yt,o,l,g).openOn(this),this},closePopup:function(o){return o=arguments.length?o:this._popup,o&&o.close(),this}}),Re.include({bindPopup:function(o,l){return this._popup=this._initOverlay(yt,this._popup,o,l),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(o){return this._popup&&(this instanceof P4||(this._popup._source=this),this._popup._prepareOpen(o||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(o){return this._popup&&this._popup.setContent(o),this},getPopup:function(){return this._popup},_openPopup:function(o){if(!(!this._popup||!this._map)){be(o);var l=o.layer||o.target;if(this._popup._source===l&&!(l instanceof v2)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(o.latlng);return}this._popup._source=l,this.openPopup(o.latlng)}},_movePopup:function(o){this._popup.setLatLng(o.latlng)},_onKeyPress:function(o){o.originalEvent.keyCode===13&&this._openPopup(o)}});var Y5=C4.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(o){C4.prototype.onAdd.call(this,o),this.setOpacity(this.options.opacity),o.fire("tooltipopen",{tooltip:this}),this._source&&(this.addEventParent(this._source),this._source.fire("tooltipopen",{tooltip:this},!0))},onRemove:function(o){C4.prototype.onRemove.call(this,o),o.fire("tooltipclose",{tooltip:this}),this._source&&(this.removeEventParent(this._source),this._source.fire("tooltipclose",{tooltip:this},!0))},getEvents:function(){var o=C4.prototype.getEvents.call(this);return this.options.permanent||(o.preclick=this.close),o},_initLayout:function(){var o="leaflet-tooltip",l=o+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=xe("div",l),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+d(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(o){var l,g,v=this._map,A=this._container,U=v.latLngToContainerPoint(v.getCenter()),V=v.layerPointToContainerPoint(o),s1=this.options.direction,u1=A.offsetWidth,x1=A.offsetHeight,C1=f1(this.options.offset),j1=this._getAnchor();s1==="top"?(l=u1/2,g=x1):s1==="bottom"?(l=u1/2,g=0):s1==="center"?(l=u1/2,g=x1/2):s1==="right"?(l=0,g=x1/2):s1==="left"?(l=u1,g=x1/2):V.xthis.options.maxZoom||gv?this._retainParent(A,U,V,v):!1)},_retainChildren:function(o,l,g,v){for(var A=2*o;A<2*o+2;A++)for(var U=2*l;U<2*l+2;U++){var V=new Y(A,U);V.z=g+1;var s1=this._tileCoordsToKey(V),u1=this._tiles[s1];if(u1&&u1.active){u1.retain=!0;continue}else u1&&u1.loaded&&(u1.retain=!0);g+1this.options.maxZoom||this.options.minZoom!==void 0&&A1){this._setView(o,g);return}for(var j1=A.min.y;j1<=A.max.y;j1++)for(var re=A.min.x;re<=A.max.x;re++){var Ve=new Y(re,j1);if(Ve.z=this._tileZoom,!!this._isValidTile(Ve)){var je=this._tiles[this._tileCoordsToKey(Ve)];je?je.current=!0:V.push(Ve)}}if(V.sort(function(ot,c4){return ot.distanceTo(U)-c4.distanceTo(U)}),V.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var lt=document.createDocumentFragment();for(re=0;reg.max.x)||!l.wrapLat&&(o.yg.max.y))return!1}if(!this.options.bounds)return!0;var v=this._tileCoordsToBounds(o);return O1(this.options.bounds).overlaps(v)},_keyToBounds:function(o){return this._tileCoordsToBounds(this._keyToTileCoords(o))},_tileCoordsToNwSe:function(o){var l=this._map,g=this.getTileSize(),v=o.scaleBy(g),A=v.add(g),U=l.unproject(v,o.z),V=l.unproject(A,o.z);return[U,V]},_tileCoordsToBounds:function(o){var l=this._tileCoordsToNwSe(o),g=new U1(l[0],l[1]);return this.options.noWrap||(g=this._map.wrapLatLngBounds(g)),g},_tileCoordsToKey:function(o){return o.x+":"+o.y+":"+o.z},_keyToTileCoords:function(o){var l=o.split(":"),g=new Y(+l[0],+l[1]);return g.z=+l[2],g},_removeTile:function(o){var l=this._tiles[o];l&&(Oe(l.el),delete this._tiles[o],this.fire("tileunload",{tile:l.el,coords:this._keyToTileCoords(o)}))},_initTile:function(o){ee(o,"leaflet-tile");var l=this.getTileSize();o.style.width=l.x+"px",o.style.height=l.y+"px",o.onselectstart=h,o.onmousemove=h,B1.ielt9&&this.options.opacity<1&&It(o,this.options.opacity)},_addTile:function(o,l){var g=this._getTilePos(o),v=this._tileCoordsToKey(o),A=this.createTile(this._wrapCoords(o),u(this._tileReady,this,o));this._initTile(A),this.createTile.length<2&&Q(u(this._tileReady,this,o,null,A)),We(A,g),this._tiles[v]={el:A,coords:o,current:!0},l.appendChild(A),this.fire("tileloadstart",{tile:A,coords:o})},_tileReady:function(o,l,g){l&&this.fire("tileerror",{error:l,tile:g,coords:o});var v=this._tileCoordsToKey(o);g=this._tiles[v],g&&(g.loaded=+new Date,this._map._fadeAnimated?(It(g.el,0),e1(this._fadeFrame),this._fadeFrame=Q(this._updateOpacity,this)):(g.active=!0,this._pruneTiles()),l||(ee(g.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:g.el,coords:o})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),B1.ielt9||!this._map._fadeAnimated?Q(this._pruneTiles,this):setTimeout(u(this._pruneTiles,this),250)))},_getTilePos:function(o){return o.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(o){var l=new Y(this._wrapX?m(o.x,this._wrapX):o.x,this._wrapY?m(o.y,this._wrapY):o.y);return l.z=o.z,l},_pxBoundsToTileRange:function(o){var l=this.getTileSize();return new w1(o.min.unscaleBy(l).floor(),o.max.unscaleBy(l).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var o in this._tiles)if(!this._tiles[o].loaded)return!1;return!0}});function Ls(o){return new _e(o)}var Z2=_e.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1,referrerPolicy:!1},initialize:function(o,l){this._url=o,l=k(this,l),l.detectRetina&&B1.retina&&l.maxZoom>0?(l.tileSize=Math.floor(l.tileSize/2),l.zoomReverse?(l.zoomOffset--,l.minZoom=Math.min(l.maxZoom,l.minZoom+1)):(l.zoomOffset++,l.maxZoom=Math.max(l.minZoom,l.maxZoom-1)),l.minZoom=Math.max(0,l.minZoom)):l.zoomReverse?l.minZoom=Math.min(l.maxZoom,l.minZoom):l.maxZoom=Math.max(l.minZoom,l.maxZoom),typeof l.subdomains=="string"&&(l.subdomains=l.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(o,l){return this._url===o&&l===void 0&&(l=!0),this._url=o,l||this.redraw(),this},createTile:function(o,l){var g=document.createElement("img");return K1(g,"load",u(this._tileOnLoad,this,l,g)),K1(g,"error",u(this._tileOnError,this,l,g)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(g.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(g.referrerPolicy=this.options.referrerPolicy),g.alt="",g.src=this.getTileUrl(o),g},getTileUrl:function(o){var l={r:B1.retina?"@2x":"",s:this._getSubdomain(o),x:o.x,y:o.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var g=this._globalTileRange.max.y-o.y;this.options.tms&&(l.y=g),l["-y"]=g}return w(this._url,r(l,this.options))},_tileOnLoad:function(o,l){B1.ielt9?setTimeout(u(o,this,null,l),0):o(null,l)},_tileOnError:function(o,l,g){var v=this.options.errorTileUrl;v&&l.getAttribute("src")!==v&&(l.src=v),o(g,l)},_onTileRemove:function(o){o.tile.onload=null},_getZoomForUrl:function(){var o=this._tileZoom,l=this.options.maxZoom,g=this.options.zoomReverse,v=this.options.zoomOffset;return g&&(o=l-o),o+v},_getSubdomain:function(o){var l=Math.abs(o.x+o.y)%this.options.subdomains.length;return this.options.subdomains[l]},_abortLoading:function(){var o,l;for(o in this._tiles)if(this._tiles[o].coords.z!==this._tileZoom&&(l=this._tiles[o].el,l.onload=h,l.onerror=h,!l.complete)){l.src=B;var g=this._tiles[o].coords;Oe(l),delete this._tiles[o],this.fire("tileabort",{tile:l,coords:g})}},_removeTile:function(o){var l=this._tiles[o];if(l)return l.el.setAttribute("src",B),_e.prototype._removeTile.call(this,o)},_tileReady:function(o,l,g){if(!(!this._map||g&&g.getAttribute("src")===B))return _e.prototype._tileReady.call(this,o,l,g)}});function Mn(o,l){return new Z2(o,l)}var oi=Z2.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(o,l){this._url=o;var g=r({},this.defaultWmsParams);for(var v in l)v in this.options||(g[v]=l[v]);l=k(this,l);var A=l.detectRetina&&B1.retina?2:1,U=this.getTileSize();g.width=U.x*A,g.height=U.y*A,this.wmsParams=g},onAdd:function(o){this._crs=this.options.crs||o.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var l=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[l]=this._crs.code,Z2.prototype.onAdd.call(this,o)},getTileUrl:function(o){var l=this._tileCoordsToNwSe(o),g=this._crs,v=k1(g.project(l[0]),g.project(l[1])),A=v.min,U=v.max,V=(this._wmsVersion>=1.3&&this._crs===ti?[A.y,A.x,U.y,U.x]:[A.x,A.y,U.x,U.y]).join(","),s1=Z2.prototype.getTileUrl.call(this,o);return s1+O(this.wmsParams,s1,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+V},setParams:function(o,l){return r(this.wmsParams,o),l||this.redraw(),this}});function Fs(o,l){return new oi(o,l)}Z2.WMS=oi,Mn.wms=Fs;var X4=Re.extend({options:{padding:.1},initialize:function(o){k(this,o),d(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),ee(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 o={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(o.zoomanim=this._onAnimZoom),o},_onAnimZoom:function(o){this._updateTransform(o.center,o.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(o,l){var g=this._map.getZoomScale(l,this._zoom),v=this._map.getSize().multiplyBy(.5+this.options.padding),A=this._map.project(this._center,l),U=v.multiplyBy(-g).add(A).subtract(this._map._getNewPixelOrigin(o,l));B1.any3d?Q2(this._container,U,g):We(this._container,U)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var o in this._layers)this._layers[o]._reset()},_onZoomEnd:function(){for(var o in this._layers)this._layers[o]._project()},_updatePaths:function(){for(var o in this._layers)this._layers[o]._update()},_update:function(){var o=this.options.padding,l=this._map.getSize(),g=this._map.containerPointToLayerPoint(l.multiplyBy(-o)).round();this._bounds=new w1(g,g.add(l.multiplyBy(1+o*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),An=X4.extend({options:{tolerance:0},getEvents:function(){var o=X4.prototype.getEvents.call(this);return o.viewprereset=this._onViewPreReset,o},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){X4.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var o=this._container=document.createElement("canvas");K1(o,"mousemove",this._onMouseMove,this),K1(o,"click dblclick mousedown mouseup contextmenu",this._onClick,this),K1(o,"mouseout",this._handleMouseOut,this),o._leaflet_disable_events=!0,this._ctx=o.getContext("2d")},_destroyContainer:function(){e1(this._redrawRequest),delete this._ctx,Oe(this._container),Pe(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var o;this._redrawBounds=null;for(var l in this._layers)o=this._layers[l],o._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){X4.prototype._update.call(this);var o=this._bounds,l=this._container,g=o.getSize(),v=B1.retina?2:1;We(l,o.min),l.width=v*g.x,l.height=v*g.y,l.style.width=g.x+"px",l.style.height=g.y+"px",B1.retina&&this._ctx.scale(2,2),this._ctx.translate(-o.min.x,-o.min.y),this.fire("update")}},_reset:function(){X4.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(o){this._updateDashArray(o),this._layers[d(o)]=o;var l=o._order={layer:o,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=l),this._drawLast=l,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(o){this._requestRedraw(o)},_removePath:function(o){var l=o._order,g=l.next,v=l.prev;g?g.prev=v:this._drawLast=v,v?v.next=g:this._drawFirst=g,delete o._order,delete this._layers[d(o)],this._requestRedraw(o)},_updatePath:function(o){this._extendRedrawBounds(o),o._project(),o._update(),this._requestRedraw(o)},_updateStyle:function(o){this._updateDashArray(o),this._requestRedraw(o)},_updateDashArray:function(o){if(typeof o.options.dashArray=="string"){var l=o.options.dashArray.split(/[, ]+/),g=[],v,A;for(A=0;A')}}catch{}return function(o){return document.createElement("<"+o+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),si={_initContainer:function(){this._container=xe("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(X4.prototype._update.call(this),this.fire("update"))},_initPath:function(o){var l=o._container=x2("shape");ee(l,"leaflet-vml-shape "+(this.options.className||"")),l.coordsize="1 1",o._path=x2("path"),l.appendChild(o._path),this._updateStyle(o),this._layers[d(o)]=o},_addPath:function(o){var l=o._container;this._container.appendChild(l),o.options.interactive&&o.addInteractiveTarget(l)},_removePath:function(o){var l=o._container;Oe(l),o.removeInteractiveTarget(l),delete this._layers[d(o)]},_updateStyle:function(o){var l=o._stroke,g=o._fill,v=o.options,A=o._container;A.stroked=!!v.stroke,A.filled=!!v.fill,v.stroke?(l||(l=o._stroke=x2("stroke")),A.appendChild(l),l.weight=v.weight+"px",l.color=v.color,l.opacity=v.opacity,v.dashArray?l.dashStyle=b(v.dashArray)?v.dashArray.join(" "):v.dashArray.replace(/( *, *)/g," "):l.dashStyle="",l.endcap=v.lineCap.replace("butt","flat"),l.joinstyle=v.lineJoin):l&&(A.removeChild(l),o._stroke=null),v.fill?(g||(g=o._fill=x2("fill")),A.appendChild(g),g.color=v.fillColor||v.color,g.opacity=v.fillOpacity):g&&(A.removeChild(g),o._fill=null)},_updateCircle:function(o){var l=o._point.round(),g=Math.round(o._radius),v=Math.round(o._radiusY||g);this._setPath(o,o._empty()?"M0 0":"AL "+l.x+","+l.y+" "+g+","+v+" 0,"+65535*360)},_setPath:function(o,l){o._path.v=l},_bringToFront:function(o){D2(o._container)},_bringToBack:function(o){m2(o._container)}},G2=B1.vml?x2:se,T3=X4.extend({_initContainer:function(){this._container=G2("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=G2("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){Oe(this._container),Pe(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){X4.prototype._update.call(this);var o=this._bounds,l=o.getSize(),g=this._container;(!this._svgSize||!this._svgSize.equals(l))&&(this._svgSize=l,g.setAttribute("width",l.x),g.setAttribute("height",l.y)),We(g,o.min),g.setAttribute("viewBox",[o.min.x,o.min.y,l.x,l.y].join(" ")),this.fire("update")}},_initPath:function(o){var l=o._path=G2("path");o.options.className&&ee(l,o.options.className),o.options.interactive&&ee(l,"leaflet-interactive"),this._updateStyle(o),this._layers[d(o)]=o},_addPath:function(o){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(o._path),o.addInteractiveTarget(o._path)},_removePath:function(o){Oe(o._path),o.removeInteractiveTarget(o._path),delete this._layers[d(o)]},_updatePath:function(o){o._project(),o._update()},_updateStyle:function(o){var l=o._path,g=o.options;l&&(g.stroke?(l.setAttribute("stroke",g.color),l.setAttribute("stroke-opacity",g.opacity),l.setAttribute("stroke-width",g.weight),l.setAttribute("stroke-linecap",g.lineCap),l.setAttribute("stroke-linejoin",g.lineJoin),g.dashArray?l.setAttribute("stroke-dasharray",g.dashArray):l.removeAttribute("stroke-dasharray"),g.dashOffset?l.setAttribute("stroke-dashoffset",g.dashOffset):l.removeAttribute("stroke-dashoffset")):l.setAttribute("stroke","none"),g.fill?(l.setAttribute("fill",g.fillColor||g.color),l.setAttribute("fill-opacity",g.fillOpacity),l.setAttribute("fill-rule",g.fillRule||"evenodd")):l.setAttribute("fill","none"))},_updatePoly:function(o,l){this._setPath(o,we(o._parts,l))},_updateCircle:function(o){var l=o._point,g=Math.max(Math.round(o._radius),1),v=Math.max(Math.round(o._radiusY),1)||g,A="a"+g+","+v+" 0 1,0 ",U=o._empty()?"M0 0":"M"+(l.x-g)+","+l.y+A+g*2+",0 "+A+-g*2+",0 ";this._setPath(o,U)},_setPath:function(o,l){o._path.setAttribute("d",l)},_bringToFront:function(o){D2(o._path)},_bringToBack:function(o){m2(o._path)}});B1.vml&&T3.include(si);function j0(o){return B1.svg||B1.vml?new T3(o):null}me.include({getRenderer:function(o){var l=o.options.renderer||this._getPaneRenderer(o.options.pane)||this.options.renderer||this._renderer;return l||(l=this._renderer=this._createRenderer()),this.hasLayer(l)||this.addLayer(l),l},_getPaneRenderer:function(o){if(o==="overlayPane"||o===void 0)return!1;var l=this._paneRenderers[o];return l===void 0&&(l=this._createRenderer({pane:o}),this._paneRenderers[o]=l),l},_createRenderer:function(o){return this.options.preferCanvas&&K4(o)||j0(o)}});var kn=M3.extend({initialize:function(o,l){M3.prototype.initialize.call(this,this._boundsToLatLngs(o),l)},setBounds:function(o){return this.setLatLngs(this._boundsToLatLngs(o))},_boundsToLatLngs:function(o){return o=O1(o),[o.getSouthWest(),o.getNorthWest(),o.getNorthEast(),o.getSouthEast()]}});function ai(o,l){return new kn(o,l)}T3.create=G2,T3.pointsToPath=we,St.geometryToLayer=Et,St.coordsToLatLng=$0,St.coordsToLatLngs=G5,St.latLngToCoords=B0,St.latLngsToCoords=q5,St.getFeature=A3,St.asFeature=Y4,me.mergeOptions({boxZoom:!0});var P3=ze.extend({initialize:function(o){this._map=o,this._container=o._container,this._pane=o._panes.overlayPane,this._resetStateTimeout=0,o.on("unload",this._destroy,this)},addHooks:function(){K1(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){Pe(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){Oe(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(o){if(!o.shiftKey||o.which!==1&&o.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),W2(),_0(),this._startPoint=this._map.mouseEventToContainerPoint(o),K1(document,{contextmenu:be,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(o){this._moved||(this._moved=!0,this._box=xe("div","leaflet-zoom-box",this._container),ee(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(o);var l=new w1(this._point,this._startPoint),g=l.getSize();We(this._box,l.min),this._box.style.width=g.x+"px",this._box.style.height=g.y+"px"},_finish:function(){this._moved&&(Oe(this._box),Le(this._container,"leaflet-crosshair")),A4(),U5(),Pe(document,{contextmenu:be,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(o){if(!(o.which!==1&&o.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(u(this._resetState,this),0);var l=new U1(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(l).fire("boxzoomend",{boxZoomBounds:l})}},_onKeyDown:function(o){o.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});me.addInitHook("addHandler","boxZoom",P3),me.mergeOptions({doubleClickZoom:!0});var b2=ze.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(o){var l=this._map,g=l.getZoom(),v=l.options.zoomDelta,A=o.originalEvent.shiftKey?g-v:g+v;l.options.doubleClickZoom==="center"?l.setZoom(A):l.setZoomAround(o.containerPoint,A)}});me.addInitHook("addHandler","doubleClickZoom",b2),me.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var Tn=ze.extend({addHooks:function(){if(!this._draggable){var o=this._map;this._draggable=new y2(o._mapPane,o._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),o.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),o.on("zoomend",this._onZoomEnd,this),o.whenReady(this._onZoomEnd,this))}ee(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){Le(this._map._container,"leaflet-grab"),Le(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 o=this._map;if(o._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var l=O1(this._map.options.maxBounds);this._offsetLimit=k1(this._map.latLngToContainerPoint(l.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(l.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;o.fire("movestart").fire("dragstart"),o.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(o){if(this._map.options.inertia){var l=this._lastTime=+new Date,g=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(g),this._times.push(l),this._prunePositions(l)}this._map.fire("move",o).fire("drag",o)},_prunePositions:function(o){for(;this._positions.length>1&&o-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var o=this._map.getSize().divideBy(2),l=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=l.subtract(o).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(o,l){return o-(o-l)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var o=this._draggable._newPos.subtract(this._draggable._startPos),l=this._offsetLimit;o.xl.max.x&&(o.x=this._viscousLimit(o.x,l.max.x)),o.y>l.max.y&&(o.y=this._viscousLimit(o.y,l.max.y)),this._draggable._newPos=this._draggable._startPos.add(o)}},_onPreDragWrap:function(){var o=this._worldWidth,l=Math.round(o/2),g=this._initialWorldOffset,v=this._draggable._newPos.x,A=(v-l+g)%o+l-g,U=(v+l+g)%o-l-g,V=Math.abs(A+g)0?U:-U))-l;this._delta=0,this._startTime=null,V&&(o.options.scrollWheelZoom==="center"?o.setZoom(l+V):o.setZoomAround(this._lastMousePos,l+V))}});me.addInitHook("addHandler","scrollWheelZoom",li);var Is=600;me.mergeOptions({tapHold:B1.touchNative&&B1.safari&&B1.mobile,tapTolerance:15});var Pn=ze.extend({addHooks:function(){K1(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){Pe(this._map._container,"touchstart",this._onDown,this)},_onDown:function(o){if(clearTimeout(this._holdTimeout),o.touches.length===1){var l=o.touches[0];this._startPos=this._newPos=new Y(l.clientX,l.clientY),this._holdTimeout=setTimeout(u(function(){this._cancel(),this._isTapValid()&&(K1(document,"touchend",te),K1(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",l))},this),Is),K1(document,"touchend touchcancel contextmenu",this._cancel,this),K1(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function o(){Pe(document,"touchend",te),Pe(document,"touchend touchcancel",o)},_cancel:function(){clearTimeout(this._holdTimeout),Pe(document,"touchend touchcancel contextmenu",this._cancel,this),Pe(document,"touchmove",this._onMove,this)},_onMove:function(o){var l=o.touches[0];this._newPos=new Y(l.clientX,l.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(o,l){var g=new MouseEvent(o,{bubbles:!0,cancelable:!0,view:window,screenX:l.screenX,screenY:l.screenY,clientX:l.clientX,clientY:l.clientY});g._simulated=!0,l.target.dispatchEvent(g)}});me.addInitHook("addHandler","tapHold",Pn),me.mergeOptions({touchZoom:B1.touch,bounceAtZoomLimits:!0});var Cn=ze.extend({addHooks:function(){ee(this._map._container,"leaflet-touch-zoom"),K1(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){Le(this._map._container,"leaflet-touch-zoom"),Pe(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(o){var l=this._map;if(!(!o.touches||o.touches.length!==2||l._animatingZoom||this._zooming)){var g=l.mouseEventToContainerPoint(o.touches[0]),v=l.mouseEventToContainerPoint(o.touches[1]);this._centerPoint=l.getSize()._divideBy(2),this._startLatLng=l.containerPointToLatLng(this._centerPoint),l.options.touchZoom!=="center"&&(this._pinchStartLatLng=l.containerPointToLatLng(g.add(v)._divideBy(2))),this._startDist=g.distanceTo(v),this._startZoom=l.getZoom(),this._moved=!1,this._zooming=!0,l._stop(),K1(document,"touchmove",this._onTouchMove,this),K1(document,"touchend touchcancel",this._onTouchEnd,this),te(o)}},_onTouchMove:function(o){if(!(!o.touches||o.touches.length!==2||!this._zooming)){var l=this._map,g=l.mouseEventToContainerPoint(o.touches[0]),v=l.mouseEventToContainerPoint(o.touches[1]),A=g.distanceTo(v)/this._startDist;if(this._zoom=l.getScaleZoom(A,this._startZoom),!l.options.bounceAtZoomLimits&&(this._zooml.getMaxZoom()&&A>1)&&(this._zoom=l._limitZoom(this._zoom)),l.options.touchZoom==="center"){if(this._center=this._startLatLng,A===1)return}else{var U=g._add(v)._divideBy(2)._subtract(this._centerPoint);if(A===1&&U.x===0&&U.y===0)return;this._center=l.unproject(l.project(this._pinchStartLatLng,this._zoom).subtract(U),this._zoom)}this._moved||(l._moveStart(!0,!1),this._moved=!0),e1(this._animRequest);var V=u(l._move,l,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=Q(V,this,!0),te(o)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,e1(this._animRequest),Pe(document,"touchmove",this._onTouchMove,this),Pe(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))}});me.addInitHook("addHandler","touchZoom",Cn),me.BoxZoom=P3,me.DoubleClickZoom=b2,me.Drag=Tn,me.Keyboard=ui,me.ScrollWheelZoom=li,me.TapHold=Pn,me.TouchZoom=Cn,n.Bounds=w1,n.Browser=B1,n.CRS=I1,n.Canvas=An,n.Circle=Z5,n.CircleMarker=H5,n.Class=o1,n.Control=Rt,n.DivIcon=En,n.DivOverlay=C4,n.DomEvent=As,n.DomUtil=W9,n.Draggable=y2,n.Evented=r1,n.FeatureGroup=P4,n.GeoJSON=St,n.GridLayer=_e,n.Handler=ze,n.Icon=S3,n.ImageOverlay=N1,n.LatLng=v1,n.LatLngBounds=U1,n.Layer=Re,n.LayerGroup=_2,n.LineUtil=O0,n.Map=me,n.Marker=W5,n.Mixin=ks,n.Path=v2,n.Point=Y,n.PolyUtil=P0,n.Polygon=M3,n.Polyline=Vt,n.Popup=yt,n.PosAnimation=E0,n.Projection=F0,n.Rectangle=kn,n.Renderer=X4,n.SVG=T3,n.SVGOverlay=Ae,n.TileLayer=Z2,n.Tooltip=Y5,n.Transformation=R1,n.Util=X,n.VideoOverlay=Se,n.bind=u,n.bounds=k1,n.canvas=K4,n.circle=w2,n.circleMarker=R0,n.control=l4,n.divIcon=X5,n.extend=r,n.featureGroup=ii,n.geoJSON=h1,n.geoJson=c1,n.gridLayer=Ls,n.icon=Cs,n.imageOverlay=V1,n.latLng=d1,n.latLngBounds=O1,n.layerGroup=bn,n.map=rt,n.marker=E3,n.point=f1,n.polygon=Os,n.polyline=Ns,n.popup=V5,n.rectangle=ai,n.setOptions=k,n.stamp=d,n.svg=j0,n.svgOverlay=z0,n.tileLayer=Mn,n.tooltip=k3,n.transformation=p1,n.version=i,n.videoOverlay=Ke;var D0=window.L;n.noConflict=function(){return window.L=D0,this},window.L=n})})(_c,_c.exports);var _4=_c.exports;function T5(e,t,n){return Object.freeze({instance:e,context:t,container:n})}function C9(e,t){return t==null?function(i,r){const s=G.useRef();return s.current||(s.current=e(i,r)),s}:function(i,r){const s=G.useRef();s.current||(s.current=e(i,r));const u=G.useRef(i),{instance:f}=s.current;return G.useEffect(function(){u.current!==i&&(t(f,i,u.current),u.current=i)},[f,i,r]),s}}function HE(e,t){G.useEffect(function(){return(t.layerContainer??t.map).addLayer(e.instance),function(){var s;(s=t.layerContainer)==null||s.removeLayer(e.instance),t.map.removeLayer(e.instance)}},[t,e])}function ZE(e){return function(n){const i=P9(),r=e(fs(n,i),i);return QE(i.map,n.attribution),Ld(r.current,n.eventHandlers),HE(r.current,i),r}}function $11(e,t){const n=G.useRef();G.useEffect(function(){if(t.pathOptions!==n.current){const r=t.pathOptions??{};e.instance.setStyle(r),n.current=r}},[e,t])}function B11(e){return function(n){const i=P9(),r=e(fs(n,i),i);return Ld(r.current,n.eventHandlers),HE(r.current,i),$11(r.current,n),r}}function z11(e,t){const n=C9(e,t),i=ZE(n);return Od(i)}function j11(e,t){const n=C9(e),i=U11(n,t);return F11(i)}function Fd(e,t){const n=C9(e,t),i=B11(n);return Od(i)}function D11(e,t){const n=C9(e,t),i=ZE(n);return I11(i)}function Q11(e,t,n){const{opacity:i,zIndex:r}=t;i!=null&&i!==n.opacity&&e.setOpacity(i),r!=null&&r!==n.zIndex&&e.setZIndex(r)}const e_=Fd(function({children:t,...n},i){const r=new _4.FeatureGroup([],n);return T5(r,d0(i,{layerContainer:r,overlayContainer:r}))}),W11=Fd(function({data:t,...n},i){const r=new _4.GeoJSON(t,n);return T5(r,d0(i,{overlayContainer:r}))},function(t,n,i){n.style!==i.style&&(n.style==null?t.resetStyle():t.setStyle(n.style))}),H11=C9(function({children:t,...n},i){const r=new _4.Control.Layers(void 0,void 0,n);return T5(r,d0(i,{layersControl:r}))},function(t,n,i){n.collapsed!==i.collapsed&&(n.collapsed===!0?t.collapse():t.expand())}),Z11=R11(H11),T6=Od(Z11);function GE(e){return function(n){const i=P9(),r=G.useRef(n),[s,u]=G.useState(null),{layersControl:f,map:d}=i,p=G.useCallback(_=>{f!=null&&(r.current.checked&&d.addLayer(_),e(f,_,r.current.name),u(_))},[f,d]),m=G.useCallback(_=>{f==null||f.removeLayer(_),u(null)},[f]),h=G.useMemo(()=>d0(i,{layerContainer:{addLayer:p,removeLayer:m}}),[i,p,m]);return G.useEffect(()=>{s!==null&&r.current!==n&&(n.checked===!0&&(r.current.checked==null||r.current.checked===!1)?d.addLayer(s):r.current.checked===!0&&(n.checked==null||n.checked===!1)&&d.removeLayer(s),r.current=n)}),n.children?U8.createElement(Nd,{value:h},n.children):null}}T6.BaseLayer=GE(function(t,n,i){t.addBaseLayer(n,i)});T6.Overlay=GE(function(t,n,i){t.addOverlay(n,i)});function vc(){return vc=Object.assign||function(e){for(var t=1;t(S==null?void 0:S.map)??null,[S]);const k=G.useCallback(x=>{if(x!==null&&S===null){const w=new _4.Map(x,m);n!=null&&p!=null?w.setView(n,p):e!=null&&w.fitBounds(e,t),d!=null&&w.whenReady(d),E(L11(w))}},[]);G.useEffect(()=>()=>{S==null||S.map.remove()},[S]);const O=S?U8.createElement(Nd,{value:S},i):u??null;return U8.createElement("div",vc({},_,{ref:k}),O)}const qE=G.forwardRef(G11),q11=z11(function({position:t,...n},i){const r=new _4.Marker(t,n);return T5(r,d0(i,{overlayContainer:r}))},function(t,n,i){n.position!==i.position&&t.setLatLng(n.position),n.icon!=null&&n.icon!==i.icon&&t.setIcon(n.icon),n.zIndexOffset!=null&&n.zIndexOffset!==i.zIndexOffset&&t.setZIndexOffset(n.zIndexOffset),n.opacity!=null&&n.opacity!==i.opacity&&t.setOpacity(n.opacity),t.dragging!=null&&n.draggable!==i.draggable&&(n.draggable===!0?t.dragging.enable():t.dragging.disable())}),VE=Fd(function({positions:t,...n},i){const r=new _4.Polygon(t,n);return T5(r,d0(i,{overlayContainer:r}))},function(t,n,i){n.positions!==i.positions&&t.setLatLngs(n.positions)}),Tu=D11(function({url:t,...n},i){const r=new _4.TileLayer(t,fs(n,i));return T5(r,i)},function(t,n,i){Q11(t,n,i);const{url:r}=n;r!=null&&r!==i.url&&t.setUrl(r)}),V11=j11(function(t,n){const i=new _4.Tooltip(t,n.overlayContainer);return T5(i,n)},function(t,n,{position:i},r){G.useEffect(function(){const u=n.overlayContainer;if(u==null)return;const{instance:f}=t,d=m=>{m.tooltip===f&&(i!=null&&f.setLatLng(i),f.update(),r(!0))},p=m=>{m.tooltip===f&&r(!1)};return u.on({tooltipopen:d,tooltipclose:p}),u.bindTooltip(f),function(){u.off({tooltipopen:d,tooltipclose:p}),u._map!=null&&u.unbindTooltip()}},[t,n,r,i])}),Y11=(e,t)=>[...new Map(t.map(n=>[n[e],n])).values()],X11=e=>!!e;var Id={exports:{}},YE={exports:{}};(function(e,t){(function(n,i){e.exports=i()})(a2,function(){function n(u,f,d,p,m){i(u,f,d||0,p||u.length-1,m||s)}function i(u,f,d,p,m){for(;p>d;){if(p-d>600){var h=p-d+1,_=f-d+1,S=Math.log(h),E=.5*Math.exp(2*S/3),k=.5*Math.sqrt(S*E*(h-E)/h)*(_-h/2<0?-1:1),O=Math.max(d,Math.floor(f-_*E/h+k)),x=Math.min(p,Math.floor(f+(h-_)*E/h+k));i(u,f,O,x,m)}var w=u[f],b=d,N=p;for(r(u,d,f),m(u[p],w)>0&&r(u,d,p);b0;)N--}m(u[d],w)===0?r(u,d,N):(N++,r(u,N,p)),N<=f&&(d=N+1),f<=N&&(p=N-1)}}function r(u,f,d){var p=u[f];u[f]=u[d],u[d]=p}function s(u,f){return uf?1:0}return n})})(YE);var K11=YE.exports;Id.exports=p9;Id.exports.default=p9;var J11=K11;function p9(e,t){if(!(this instanceof p9))return new p9(e,t);this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4)),t&&this._initFormat(t),this.clear()}p9.prototype={all:function(){return this._all(this.data,[])},search:function(e){var t=this.data,n=[],i=this.toBBox;if(!f8(e,t))return n;for(var r=[],s,u,f,d;t;){for(s=0,u=t.children.length;s=0&&s[t].children.length>this._maxEntries;)this._split(s,t),t--;this._adjustParentBBoxes(r,s,t)},_split:function(e,t){var n=e[t],i=n.children.length,r=this._minEntries;this._chooseSplitAxis(n,r,i);var s=this._chooseSplitIndex(n,r,i),u=d6(n.children.splice(s,n.children.length-s));u.height=n.height,u.leaf=n.leaf,l6(n,this.toBBox),l6(u,this.toBBox),t?e[t-1].children.push(u):this._splitRoot(n,u)},_splitRoot:function(e,t){this.data=d6([e,t]),this.data.height=e.height+1,this.data.leaf=!1,l6(this.data,this.toBBox)},_chooseSplitIndex:function(e,t,n){var i,r,s,u,f,d,p,m;for(d=p=1/0,i=t;i<=n-t;i++)r=w7(e,0,i,this.toBBox),s=w7(e,i,n,this.toBBox),u=ne1(r,s),f=Pu(r)+Pu(s),u=t;d--)p=e.children[d],x7(u,e.leaf?r(p):p),f+=c8(u);return f},_adjustParentBBoxes:function(e,t,n){for(var i=n;i>=0;i--)x7(t[i],e)},_condense:function(e){for(var t=e.length-1,n;t>=0;t--)e[t].children.length===0?t>0?(n=e[t-1].children,n.splice(n.indexOf(e[t]),1)):this.clear():l6(e[t],this.toBBox)},_initFormat:function(e){var t=["return a"," - b",";"];this.compareMinX=new Function("a","b",t.join(e[0])),this.compareMinY=new Function("a","b",t.join(e[1])),this.toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}};function ee1(e,t,n){if(!n)return t.indexOf(e);for(var i=0;i=e.minX&&t.maxY>=e.minY}function d6(e){return{children:e,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function i_(e,t,n,i,r){for(var s=[t,n],u;s.length;)n=s.pop(),t=s.pop(),!(n-t<=i)&&(u=t+Math.ceil((n-t)/i/2)*i,J11(e,u,t,n,r),s.push(t,u,u,n))}var ie1=Id.exports,re1=Ur;Ur.polyline=Ur;Ur.polygon=oe1;function Ur(e,t,n){var i=e.length,r=P6(e[0],t),s=[],u,f,d,p,m;for(n||(n=[]),u=1;ut[2]&&(n|=2),e[1]t[3]&&(n|=8),n}var se1=ie1,ae1=re1,ue1=le1;function le1(e){for(var t=[],n=0;n0)return!0;return!1}function XE(e,t){for(var n=!1,i=0,r=e.length;ie[1]!=n[1]>e[1]&&e[0]<(n[0]-t[0])*(e[1]-t[1])/(n[1]-t[1])+t[0]}function r_(e,t){for(var n={minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0,coords:e,props:t},i=0;iPt[w].properties.id),k(x);for(const x of e.features)m(x),h(x),_(x),S(x),p(x);for(const x of e.features)x.properties.groups.sort((w,b)=>c6.indexOf(Pt[w].properties.level)-c6.indexOf(Pt[b].properties.level)),x.properties.members&&x.properties.members.sort((w,b)=>{const N=c6.indexOf(Pt[w].properties.level)-c6.indexOf(Pt[b].properties.level);return N===0?e.features.indexOf(Pt[w])-e.features.indexOf(Pt[b]):N});de1({type:"FeatureCollection",features:n});function r(x){const w=x.properties;w.groups||(w.groups=[]),x.geometry&&w.country&&w.groups.push(w.country),w.m49!=="001"&&w.groups.push("001")}function s(x){const w=x.properties;!w.m49&&w.iso1N3&&(w.m49=w.iso1N3)}function u(x){const w=x.properties;w.level!=="unitedNations"&&!w.ccTLD&&w.iso1A2&&(w.ccTLD="."+w.iso1A2.toLowerCase())}function f(x){const w=x.properties;!w.isoStatus&&w.iso1A2&&(w.isoStatus="official")}function d(x){const w=x.properties;w.level||(w.country?!w.iso1A2||w.isoStatus==="official"?w.level="territory":w.level="subterritory":w.level="country")}function p(x){const w=x.properties;if(x.geometry||!w.members)return;const b=c6.indexOf(w.level);let N=[];w.members.forEach((B,R)=>{const $=Pt[B].properties.groups.filter(K=>K!==x.properties.id&&b$.indexOf(K)!==-1)}),w.groups=w.groups.concat(N.filter(B=>w.groups.indexOf(B)===-1));for(const B of N){const R=Pt[B];R.properties.members.indexOf(w.id)===-1&&R.properties.members.push(w.id)}}function m(x){const w=x.properties;if(x.geometry)w.roadSpeedUnit||(w.roadSpeedUnit="km/h");else if(w.members){const b=Array.from(new Set(w.members.map(N=>{const B=Pt[N];if(B.geometry)return B.properties.roadSpeedUnit||"km/h"}).filter(Boolean)));b.length===1&&(w.roadSpeedUnit=b[0])}}function h(x){const w=x.properties;if(x.geometry)w.roadHeightUnit||(w.roadHeightUnit="m");else if(w.members){const b=Array.from(new Set(w.members.map(N=>{const B=Pt[N];if(B.geometry)return B.properties.roadHeightUnit||"m"}).filter(Boolean)));b.length===1&&(w.roadHeightUnit=b[0])}}function _(x){const w=x.properties;if(x.geometry)w.driveSide||(w.driveSide="right");else if(w.members){const b=Array.from(new Set(w.members.map(N=>{const B=Pt[N];if(B.geometry)return B.properties.driveSide||"right"}).filter(Boolean)));b.length===1&&(w.driveSide=b[0])}}function S(x){const w=x.properties;!x.geometry&&w.members&&(w.callingCodes=Array.from(new Set(w.members.reduce((b,N)=>{const B=Pt[N];return B.geometry&&B.properties.callingCodes?b.concat(B.properties.callingCodes):b},[]))))}function E(x){if(!x.properties.iso1A2)return;const w=x.properties.iso1A2.replace(/./g,function(b){return String.fromCodePoint(b.charCodeAt(0)+127397)});x.properties.emojiFlag=w}function k(x){for(const w of x.properties.groups){const b=Pt[w];b.properties.members||(b.properties.members=[]),b.properties.members.push(x.properties.id)}}function O(x){let w=[];for(const b of t){const N=x.properties[b];N&&w.push(N)}for(const b of x.properties.aliases||[])w.push(b);for(const b of w){const N=me1(b);Pt[N]=x}}}const KE=()=>F.jsxs(T6,{position:"topright",children:[F.jsx(T6.BaseLayer,{checked:!0,name:"OpenStreetMap",children:F.jsx(Tu,{attribution:'© OpenStreetMap contributors',url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"})}),F.jsx(T6.BaseLayer,{name:"LINZ Aerial Imagery",children:F.jsx(Tu,{attribution:'Sourced from LINZ CC-BY 4.0',url:"https://basemaps.linz.govt.nz/v1/tiles/aerial/EPSG:3857/{z}/{x}/{y}.jpg?api=d01egend5f8dv4zcbfj6z2t7rs3"})}),F.jsx(T6.BaseLayer,{name:"LINZ Topo50",children:F.jsx(Tu,{attribution:'Sourced from LINZ CC-BY 4.0',url:"https://map.cazzaserver.com/linz_topo/{z}/{x}/{y}.png"})})]});class _e1 extends G.Component{static getDerivedStateFromError(t){return{error:t}}render(){var t;return(t=this.state)!=null&&t.error?F.jsx("div",{style:{margin:32},children:"Map preview unavailable. This layer probably uses complex geometry."}):this.props.children}}const o_="https://linz-addr-cdn.kyle.kiwi",s_=!!window.opener;function ve1(e,t){if(t){const[n,i]=t,r=`Check back in a day. + +If you continue, you might override or duplicate their work!`,s=i==="done"?`This dataset may already have been uploaded by someone else! ${r}`:`Someone else (${n}) started editing this dataset ${i} minutes ago. ${r}`;if(!confirm(s))return}window.opener.postMessage(`ADD_SECTOR=${e}`),window.close()}function JE(e){return e>1e3?"#3a0000":e>500?"#67001f":e>200?"#980043":e>100?"#ce1256":e>60?"#e7298a":e>40?"#df65b0":e>20?"#c994c7":"#d4b9da"}function we1(e,t){return{color:t?"#aaaaaa":JE(e.totalCount),fillOpacity:.3,opacity:1,stroke:!0,weight:2}}let a_="orange";function u_(e,t){t?(a_=e.target.options.color,e.target.setStyle({color:"yellow"})):e.target.setStyle({color:a_})}function xe1([[e,t],[n,i]]){return[[i,e],[i,n],[t,n],[t,e]]}const l_={Expires:"Tue, 01 Jan 1980 1:00:00 GMT","Cache-Control":"no-cache, no-store, max-age=0",Pragma:"no-cache"},be1=()=>{const[e,t]=G.useState(!1),[n,i]=G.useState(),[r,s]=G.useState(),[u,f]=G.useState(),[d,p]=G.useState([]);if(G.useEffect(()=>{Promise.all([fetch(`${o_}/index.json?nocache=${Math.random()}`,{headers:l_}).then(_=>_.json()),fetch(`${o_}/__locked?nocache=${Math.random()}`,{headers:l_}).then(_=>_.json()).catch(()=>({}))]).then(f).catch(s)},[]),r)return F.jsx(F.Fragment,{children:"Error"});if(!u)return F.jsx(F.Fragment,{children:"Loading..."});const m=Y11("name",u[0].results.map(_=>({name:_.name.split(" - ").slice(0,-1).join(" - "),isPreview:_.groupCategories[0]==="/Categories/Preview"})).filter(_=>e||!_.isPreview)),h=_=>u[1][_.id]?`Someone else ${u[1][_.id][1]==="done"?"may have already uploaded":"is working on"} this dataset! Check back in one day.`:"";return F.jsxs(F.Fragment,{children:[F.jsxs("div",{style:{height:200},children:[s_&&F.jsxs("div",{style:{textAlign:"center"},children:[F.jsx("h3",{style:{margin:0},children:"Please select a suburb to edit"}),"You can close this page and use the list if you prefer"]}),F.jsx("input",{type:"checkbox",checked:e,onChange:_=>t(_.target.checked)}),"Show Preview Layers",F.jsx("br",{}),F.jsx("br",{}),F.jsx("div",{style:{display:"flex",flexWrap:"wrap"},children:m.map(_=>F.jsx("button",{type:"button",className:[n===_.name?"active-layer":"inactive-layer",_.isPreview?"preview-layer":""].join(" "),onClick:()=>i(_.name),children:_.name},_.name))})]}),F.jsx(_e1,{children:F.jsxs(qE,{style:{width:"100vw",height:"calc(100vh - 200px)"},center:[-40.98,166.9],zoom:6,scrollWheelZoom:!0,children:[F.jsx(KE,{}),n&&u[0].results.filter(_=>_.name.startsWith(n)).filter(_=>!d.includes(_.id)).map(_=>F.jsx(VE,{pathOptions:we1(_,u[1][_.id]),positions:xe1(_.extent),eventHandlers:{click:()=>{s_&&ve1(_.id,u[1][_.id])},contextmenu:()=>p(S=>[...S,_.id]),mouseover:S=>u_(S,!0),mouseout:S=>u_(S,!1)},children:F.jsxs(V11,{direction:"bottom",sticky:!0,children:[F.jsx("strong",{children:_.name}),F.jsx("br",{}),_.snippet,F.jsx("br",{}),h(_)]})},_.id)),F.jsxs("div",{className:"legend leaflet-bottom leaflet-left",style:{margin:20},children:[F.jsx("strong",{children:"# of changes"}),F.jsx("br",{}),[0,20,40,60,100,200,500,1e3].map((_,S,E)=>F.jsxs(G.Fragment,{children:[F.jsx("i",{style:{background:JE(E[S]+1)}}),E[S],E[S+1]?F.jsxs(F.Fragment,{children:["–",E[S+1],F.jsx("br",{})]}):"+"]},_))]})]})},n)]})};function d8(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var eM={exports:{}};(function(e,t){(function(n){e.exports=n()})(function(){return function(){function n(i,r,s){function u(p,m){if(!r[p]){if(!i[p]){var h=typeof d8=="function"&&d8;if(!m&&h)return h(p,!0);if(f)return f(p,!0);var _=new Error("Cannot find module '"+p+"'");throw _.code="MODULE_NOT_FOUND",_}var S=r[p]={exports:{}};i[p][0].call(S.exports,function(E){var k=i[p][1][E];return u(k||E)},S,S.exports,n,i,r,s)}return r[p].exports}for(var f=typeof d8=="function"&&d8,d=0;d0)throw new Error("Invalid string. Length must be a multiple of 4");var N=w.indexOf("=");N===-1&&(N=b);var B=N===b?0:4-N%4;return[N,B]}function _(w){var b=h(w),N=b[0],B=b[1];return(N+B)*3/4-B}function S(w,b,N){return(b+N)*3/4-N}function E(w){var b,N=h(w),B=N[0],R=N[1],j=new f(S(w,B,R)),$=0,K=R>0?B-4:B,H;for(H=0;H>16&255,j[$++]=b>>8&255,j[$++]=b&255;return R===2&&(b=u[w.charCodeAt(H)]<<2|u[w.charCodeAt(H+1)]>>4,j[$++]=b&255),R===1&&(b=u[w.charCodeAt(H)]<<10|u[w.charCodeAt(H+1)]<<4|u[w.charCodeAt(H+2)]>>2,j[$++]=b>>8&255,j[$++]=b&255),j}function k(w){return s[w>>18&63]+s[w>>12&63]+s[w>>6&63]+s[w&63]}function O(w,b,N){for(var B,R=[],j=b;jK?K:$+j));return B===1?(b=w[N-1],R.push(s[b>>2]+s[b<<4&63]+"==")):B===2&&(b=(w[N-2]<<8)+w[N-1],R.push(s[b>>10]+s[b>>4&63]+s[b<<2&63]+"=")),R.join("")}},{}],2:[function(n,i,r){(function(s){(function(){var u=n("base64-js"),f=n("ieee754");r.Buffer=h,r.SlowBuffer=B,r.INSPECT_MAX_BYTES=50;var d=2147483647;r.kMaxLength=d,h.TYPED_ARRAY_SUPPORT=p(),!h.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function p(){try{var W=new Uint8Array(1);return W.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},W.foo()===42}catch{return!1}}Object.defineProperty(h.prototype,"parent",{enumerable:!0,get:function(){if(h.isBuffer(this))return this.buffer}}),Object.defineProperty(h.prototype,"offset",{enumerable:!0,get:function(){if(h.isBuffer(this))return this.byteOffset}});function m(W){if(W>d)throw new RangeError('The value "'+W+'" is invalid for option "size"');var T=new Uint8Array(W);return T.__proto__=h.prototype,T}function h(W,T,P){if(typeof W=="number"){if(typeof T=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return k(W)}return _(W,T,P)}typeof Symbol<"u"&&Symbol.species!=null&&h[Symbol.species]===h&&Object.defineProperty(h,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),h.poolSize=8192;function _(W,T,P){if(typeof W=="string")return O(W,T);if(ArrayBuffer.isView(W))return x(W);if(W==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof W);if(ge(W,ArrayBuffer)||W&&ge(W.buffer,ArrayBuffer))return w(W,T,P);if(typeof W=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var Z=W.valueOf&&W.valueOf();if(Z!=null&&Z!==W)return h.from(Z,T,P);var a1=b(W);if(a1)return a1;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof W[Symbol.toPrimitive]=="function")return h.from(W[Symbol.toPrimitive]("string"),T,P);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof W)}h.from=function(W,T,P){return _(W,T,P)},h.prototype.__proto__=Uint8Array.prototype,h.__proto__=Uint8Array;function S(W){if(typeof W!="number")throw new TypeError('"size" argument must be of type number');if(W<0)throw new RangeError('The value "'+W+'" is invalid for option "size"')}function E(W,T,P){return S(W),W<=0?m(W):T!==void 0?typeof P=="string"?m(W).fill(T,P):m(W).fill(T):m(W)}h.alloc=function(W,T,P){return E(W,T,P)};function k(W){return S(W),m(W<0?0:N(W)|0)}h.allocUnsafe=function(W){return k(W)},h.allocUnsafeSlow=function(W){return k(W)};function O(W,T){if((typeof T!="string"||T==="")&&(T="utf8"),!h.isEncoding(T))throw new TypeError("Unknown encoding: "+T);var P=R(W,T)|0,Z=m(P),a1=Z.write(W,T);return a1!==P&&(Z=Z.slice(0,a1)),Z}function x(W){for(var T=W.length<0?0:N(W.length)|0,P=m(T),Z=0;Z=d)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+d.toString(16)+" bytes");return W|0}function B(W){return+W!=W&&(W=0),h.alloc(+W)}h.isBuffer=function(T){return T!=null&&T._isBuffer===!0&&T!==h.prototype},h.compare=function(T,P){if(ge(T,Uint8Array)&&(T=h.from(T,T.offset,T.byteLength)),ge(P,Uint8Array)&&(P=h.from(P,P.offset,P.byteLength)),!h.isBuffer(T)||!h.isBuffer(P))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(T===P)return 0;for(var Z=T.length,a1=P.length,_1=0,b1=Math.min(Z,a1);_12&&arguments[2]===!0;if(!Z&&P===0)return 0;for(var a1=!1;;)switch(T){case"ascii":case"latin1":case"binary":return P;case"utf8":case"utf-8":return J1(W).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P*2;case"hex":return P>>>1;case"base64":return we(W).length;default:if(a1)return Z?-1:J1(W).length;T=(""+T).toLowerCase(),a1=!0}}h.byteLength=R;function j(W,T,P){var Z=!1;if((T===void 0||T<0)&&(T=0),T>this.length||((P===void 0||P>this.length)&&(P=this.length),P<=0)||(P>>>=0,T>>>=0,P<=T))return"";for(W||(W="utf8");;)switch(W){case"hex":return U1(this,T,P);case"utf8":case"utf-8":return Y(this,T,P);case"ascii":return w1(this,T,P);case"latin1":case"binary":return k1(this,T,P);case"base64":return r1(this,T,P);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return O1(this,T,P);default:if(Z)throw new TypeError("Unknown encoding: "+W);W=(W+"").toLowerCase(),Z=!0}}h.prototype._isBuffer=!0;function $(W,T,P){var Z=W[T];W[T]=W[P],W[P]=Z}h.prototype.swap16=function(){var T=this.length;if(T%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var P=0;PP&&(T+=" ... "),""},h.prototype.compare=function(T,P,Z,a1,_1){if(ge(T,Uint8Array)&&(T=h.from(T,T.offset,T.byteLength)),!h.isBuffer(T))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof T);if(P===void 0&&(P=0),Z===void 0&&(Z=T?T.length:0),a1===void 0&&(a1=0),_1===void 0&&(_1=this.length),P<0||Z>T.length||a1<0||_1>this.length)throw new RangeError("out of range index");if(a1>=_1&&P>=Z)return 0;if(a1>=_1)return-1;if(P>=Z)return 1;if(P>>>=0,Z>>>=0,a1>>>=0,_1>>>=0,this===T)return 0;for(var b1=_1-a1,G1=Z-P,X1=Math.min(b1,G1),T1=this.slice(a1,_1),q1=T.slice(P,Z),fe=0;fe2147483647?P=2147483647:P<-2147483648&&(P=-2147483648),P=+P,Qe(P)&&(P=a1?0:W.length-1),P<0&&(P=W.length+P),P>=W.length){if(a1)return-1;P=W.length-1}else if(P<0)if(a1)P=0;else return-1;if(typeof T=="string"&&(T=h.from(T,Z)),h.isBuffer(T))return T.length===0?-1:H(W,T,P,Z,a1);if(typeof T=="number")return T=T&255,typeof Uint8Array.prototype.indexOf=="function"?a1?Uint8Array.prototype.indexOf.call(W,T,P):Uint8Array.prototype.lastIndexOf.call(W,T,P):H(W,[T],P,Z,a1);throw new TypeError("val must be string, number or Buffer")}function H(W,T,P,Z,a1){var _1=1,b1=W.length,G1=T.length;if(Z!==void 0&&(Z=String(Z).toLowerCase(),Z==="ucs2"||Z==="ucs-2"||Z==="utf16le"||Z==="utf-16le")){if(W.length<2||T.length<2)return-1;_1=2,b1/=2,G1/=2,P/=2}function X1(mt,S4){return _1===1?mt[S4]:mt.readUInt16BE(S4*_1)}var T1;if(a1){var q1=-1;for(T1=P;T1b1&&(P=b1-G1),T1=P;T1>=0;T1--){for(var fe=!0,de=0;dea1&&(Z=a1)):Z=a1;var _1=T.length;Z>_1/2&&(Z=_1/2);for(var b1=0;b1>>0,isFinite(Z)?(Z=Z>>>0,a1===void 0&&(a1="utf8")):(a1=Z,Z=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var _1=this.length-P;if((Z===void 0||Z>_1)&&(Z=_1),T.length>0&&(Z<0||P<0)||P>this.length)throw new RangeError("Attempt to write outside buffer bounds");a1||(a1="utf8");for(var b1=!1;;)switch(a1){case"hex":return Q(this,T,P,Z);case"utf8":case"utf-8":return e1(this,T,P,Z);case"ascii":return X(this,T,P,Z);case"latin1":case"binary":return o1(this,T,P,Z);case"base64":return n1(this,T,P,Z);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return l1(this,T,P,Z);default:if(b1)throw new TypeError("Unknown encoding: "+a1);a1=(""+a1).toLowerCase(),b1=!0}},h.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function r1(W,T,P){return T===0&&P===W.length?u.fromByteArray(W):u.fromByteArray(W.slice(T,P))}function Y(W,T,P){P=Math.min(W.length,P);for(var Z=[],a1=T;a1239?4:_1>223?3:_1>191?2:1;if(a1+G1<=P){var X1,T1,q1,fe;switch(G1){case 1:_1<128&&(b1=_1);break;case 2:X1=W[a1+1],(X1&192)===128&&(fe=(_1&31)<<6|X1&63,fe>127&&(b1=fe));break;case 3:X1=W[a1+1],T1=W[a1+2],(X1&192)===128&&(T1&192)===128&&(fe=(_1&15)<<12|(X1&63)<<6|T1&63,fe>2047&&(fe<55296||fe>57343)&&(b1=fe));break;case 4:X1=W[a1+1],T1=W[a1+2],q1=W[a1+3],(X1&192)===128&&(T1&192)===128&&(q1&192)===128&&(fe=(_1&15)<<18|(X1&63)<<12|(T1&63)<<6|q1&63,fe>65535&&fe<1114112&&(b1=fe))}}b1===null?(b1=65533,G1=1):b1>65535&&(b1-=65536,Z.push(b1>>>10&1023|55296),b1=56320|b1&1023),Z.push(b1),a1+=G1}return f1(Z)}var g1=4096;function f1(W){var T=W.length;if(T<=g1)return String.fromCharCode.apply(String,W);for(var P="",Z=0;ZZ)&&(P=Z);for(var a1="",_1=T;_1Z&&(T=Z),P<0?(P+=Z,P<0&&(P=0)):P>Z&&(P=Z),PP)throw new RangeError("Trying to access beyond buffer length")}h.prototype.readUIntLE=function(T,P,Z){T=T>>>0,P=P>>>0,Z||v1(T,P,this.length);for(var a1=this[T],_1=1,b1=0;++b1>>0,P=P>>>0,Z||v1(T,P,this.length);for(var a1=this[T+--P],_1=1;P>0&&(_1*=256);)a1+=this[T+--P]*_1;return a1},h.prototype.readUInt8=function(T,P){return T=T>>>0,P||v1(T,1,this.length),this[T]},h.prototype.readUInt16LE=function(T,P){return T=T>>>0,P||v1(T,2,this.length),this[T]|this[T+1]<<8},h.prototype.readUInt16BE=function(T,P){return T=T>>>0,P||v1(T,2,this.length),this[T]<<8|this[T+1]},h.prototype.readUInt32LE=function(T,P){return T=T>>>0,P||v1(T,4,this.length),(this[T]|this[T+1]<<8|this[T+2]<<16)+this[T+3]*16777216},h.prototype.readUInt32BE=function(T,P){return T=T>>>0,P||v1(T,4,this.length),this[T]*16777216+(this[T+1]<<16|this[T+2]<<8|this[T+3])},h.prototype.readIntLE=function(T,P,Z){T=T>>>0,P=P>>>0,Z||v1(T,P,this.length);for(var a1=this[T],_1=1,b1=0;++b1=_1&&(a1-=Math.pow(2,8*P)),a1},h.prototype.readIntBE=function(T,P,Z){T=T>>>0,P=P>>>0,Z||v1(T,P,this.length);for(var a1=P,_1=1,b1=this[T+--a1];a1>0&&(_1*=256);)b1+=this[T+--a1]*_1;return _1*=128,b1>=_1&&(b1-=Math.pow(2,8*P)),b1},h.prototype.readInt8=function(T,P){return T=T>>>0,P||v1(T,1,this.length),this[T]&128?(255-this[T]+1)*-1:this[T]},h.prototype.readInt16LE=function(T,P){T=T>>>0,P||v1(T,2,this.length);var Z=this[T]|this[T+1]<<8;return Z&32768?Z|4294901760:Z},h.prototype.readInt16BE=function(T,P){T=T>>>0,P||v1(T,2,this.length);var Z=this[T+1]|this[T]<<8;return Z&32768?Z|4294901760:Z},h.prototype.readInt32LE=function(T,P){return T=T>>>0,P||v1(T,4,this.length),this[T]|this[T+1]<<8|this[T+2]<<16|this[T+3]<<24},h.prototype.readInt32BE=function(T,P){return T=T>>>0,P||v1(T,4,this.length),this[T]<<24|this[T+1]<<16|this[T+2]<<8|this[T+3]},h.prototype.readFloatLE=function(T,P){return T=T>>>0,P||v1(T,4,this.length),f.read(this,T,!0,23,4)},h.prototype.readFloatBE=function(T,P){return T=T>>>0,P||v1(T,4,this.length),f.read(this,T,!1,23,4)},h.prototype.readDoubleLE=function(T,P){return T=T>>>0,P||v1(T,8,this.length),f.read(this,T,!0,52,8)},h.prototype.readDoubleBE=function(T,P){return T=T>>>0,P||v1(T,8,this.length),f.read(this,T,!1,52,8)};function d1(W,T,P,Z,a1,_1){if(!h.isBuffer(W))throw new TypeError('"buffer" argument must be a Buffer instance');if(T>a1||T<_1)throw new RangeError('"value" argument is out of bounds');if(P+Z>W.length)throw new RangeError("Index out of range")}h.prototype.writeUIntLE=function(T,P,Z,a1){if(T=+T,P=P>>>0,Z=Z>>>0,!a1){var _1=Math.pow(2,8*Z)-1;d1(this,T,P,Z,_1,0)}var b1=1,G1=0;for(this[P]=T&255;++G1>>0,Z=Z>>>0,!a1){var _1=Math.pow(2,8*Z)-1;d1(this,T,P,Z,_1,0)}var b1=Z-1,G1=1;for(this[P+b1]=T&255;--b1>=0&&(G1*=256);)this[P+b1]=T/G1&255;return P+Z},h.prototype.writeUInt8=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,1,255,0),this[P]=T&255,P+1},h.prototype.writeUInt16LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,65535,0),this[P]=T&255,this[P+1]=T>>>8,P+2},h.prototype.writeUInt16BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,65535,0),this[P]=T>>>8,this[P+1]=T&255,P+2},h.prototype.writeUInt32LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,4294967295,0),this[P+3]=T>>>24,this[P+2]=T>>>16,this[P+1]=T>>>8,this[P]=T&255,P+4},h.prototype.writeUInt32BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,4294967295,0),this[P]=T>>>24,this[P+1]=T>>>16,this[P+2]=T>>>8,this[P+3]=T&255,P+4},h.prototype.writeIntLE=function(T,P,Z,a1){if(T=+T,P=P>>>0,!a1){var _1=Math.pow(2,8*Z-1);d1(this,T,P,Z,_1-1,-_1)}var b1=0,G1=1,X1=0;for(this[P]=T&255;++b1>0)-X1&255;return P+Z},h.prototype.writeIntBE=function(T,P,Z,a1){if(T=+T,P=P>>>0,!a1){var _1=Math.pow(2,8*Z-1);d1(this,T,P,Z,_1-1,-_1)}var b1=Z-1,G1=1,X1=0;for(this[P+b1]=T&255;--b1>=0&&(G1*=256);)T<0&&X1===0&&this[P+b1+1]!==0&&(X1=1),this[P+b1]=(T/G1>>0)-X1&255;return P+Z},h.prototype.writeInt8=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,1,127,-128),T<0&&(T=255+T+1),this[P]=T&255,P+1},h.prototype.writeInt16LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,32767,-32768),this[P]=T&255,this[P+1]=T>>>8,P+2},h.prototype.writeInt16BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,32767,-32768),this[P]=T>>>8,this[P+1]=T&255,P+2},h.prototype.writeInt32LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,2147483647,-2147483648),this[P]=T&255,this[P+1]=T>>>8,this[P+2]=T>>>16,this[P+3]=T>>>24,P+4},h.prototype.writeInt32BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,2147483647,-2147483648),T<0&&(T=4294967295+T+1),this[P]=T>>>24,this[P+1]=T>>>16,this[P+2]=T>>>8,this[P+3]=T&255,P+4};function I1(W,T,P,Z,a1,_1){if(P+Z>W.length)throw new RangeError("Index out of range");if(P<0)throw new RangeError("Index out of range")}function W1(W,T,P,Z,a1){return T=+T,P=P>>>0,a1||I1(W,T,P,4),f.write(W,T,P,Z,23,4),P+4}h.prototype.writeFloatLE=function(T,P,Z){return W1(this,T,P,!0,Z)},h.prototype.writeFloatBE=function(T,P,Z){return W1(this,T,P,!1,Z)};function E1(W,T,P,Z,a1){return T=+T,P=P>>>0,a1||I1(W,T,P,8),f.write(W,T,P,Z,52,8),P+8}h.prototype.writeDoubleLE=function(T,P,Z){return E1(this,T,P,!0,Z)},h.prototype.writeDoubleBE=function(T,P,Z){return E1(this,T,P,!1,Z)},h.prototype.copy=function(T,P,Z,a1){if(!h.isBuffer(T))throw new TypeError("argument should be a Buffer");if(Z||(Z=0),!a1&&a1!==0&&(a1=this.length),P>=T.length&&(P=T.length),P||(P=0),a1>0&&a1=this.length)throw new RangeError("Index out of range");if(a1<0)throw new RangeError("sourceEnd out of bounds");a1>this.length&&(a1=this.length),T.length-P=0;--b1)T[b1+P]=this[b1+Z];else Uint8Array.prototype.set.call(T,this.subarray(Z,a1),P);return _1},h.prototype.fill=function(T,P,Z,a1){if(typeof T=="string"){if(typeof P=="string"?(a1=P,P=0,Z=this.length):typeof Z=="string"&&(a1=Z,Z=this.length),a1!==void 0&&typeof a1!="string")throw new TypeError("encoding must be a string");if(typeof a1=="string"&&!h.isEncoding(a1))throw new TypeError("Unknown encoding: "+a1);if(T.length===1){var _1=T.charCodeAt(0);(a1==="utf8"&&_1<128||a1==="latin1")&&(T=_1)}}else typeof T=="number"&&(T=T&255);if(P<0||this.length>>0,Z=Z===void 0?this.length:Z>>>0,T||(T=0);var b1;if(typeof T=="number")for(b1=P;b155295&&P<57344){if(!a1){if(P>56319){(T-=3)>-1&&_1.push(239,191,189);continue}else if(b1+1===Z){(T-=3)>-1&&_1.push(239,191,189);continue}a1=P;continue}if(P<56320){(T-=3)>-1&&_1.push(239,191,189),a1=P;continue}P=(a1-55296<<10|P-56320)+65536}else a1&&(T-=3)>-1&&_1.push(239,191,189);if(a1=null,P<128){if((T-=1)<0)break;_1.push(P)}else if(P<2048){if((T-=2)<0)break;_1.push(P>>6|192,P&63|128)}else if(P<65536){if((T-=3)<0)break;_1.push(P>>12|224,P>>6&63|128,P&63|128)}else if(P<1114112){if((T-=4)<0)break;_1.push(P>>18|240,P>>12&63|128,P>>6&63|128,P&63|128)}else throw new Error("Invalid code point")}return _1}function D1(W){for(var T=[],P=0;P>8,a1=P%256,_1.push(a1),_1.push(Z);return _1}function we(W){return u.toByteArray(R1(W))}function pe(W,T,P,Z){for(var a1=0;a1=T.length||a1>=W.length);++a1)T[a1+P]=W[a1];return a1}function ge(W,T){return W instanceof T||W!=null&&W.constructor!=null&&W.constructor.name!=null&&W.constructor.name===T.name}function Qe(W){return W!==W}}).call(this)}).call(this,n("buffer").Buffer)},{"base64-js":1,buffer:2,ieee754:14}],3:[function(n,i,r){const s=n("./validator"),u=n("./xmlparser/XMLParser"),f=n("./xmlbuilder/json2xml");i.exports={XMLParser:u,XMLValidator:s,XMLBuilder:f}},{"./validator":5,"./xmlbuilder/json2xml":6,"./xmlparser/XMLParser":11}],4:[function(n,i,r){const s=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",u=s+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",f="["+s+"]["+u+"]*",d=new RegExp("^"+f+"$"),p=function(h,_){const S=[];let E=_.exec(h);for(;E;){const k=[];k.startIndex=_.lastIndex-E[0].length;const O=E.length;for(let x=0;x"u")};r.isExist=function(h){return typeof h<"u"},r.isEmptyObject=function(h){return Object.keys(h).length===0},r.merge=function(h,_,S){if(_){const E=Object.keys(_),k=E.length;for(let O=0;O"&&R[Q]!==" "&&R[Q]!==" "&&R[Q]!==` +`&&R[Q]!=="\r";Q++)o1+=R[Q];if(o1=o1.trim(),o1[o1.length-1]==="/"&&(o1=o1.substring(0,o1.length-1),Q--),!b(o1)){let r1;return o1.trim().length===0?r1="Invalid space after '<'.":r1="Tag '"+o1+"' is an invalid name.",x("InvalidTag",r1,N(R,Q))}const n1=_(R,Q);if(n1===!1)return x("InvalidAttr","Attributes for '"+o1+"' have open quote.",N(R,Q));let l1=n1.value;if(Q=n1.index,l1[l1.length-1]==="/"){const r1=Q-l1.length;l1=l1.substring(0,l1.length-1);const Y=E(l1,j);if(Y===!0)K=!0;else return x(Y.err.code,Y.err.msg,N(R,r1+Y.err.line))}else if(X)if(n1.tagClosed){if(l1.trim().length>0)return x("InvalidTag","Closing tag '"+o1+"' can't have attributes or invalid starting.",N(R,e1));{const r1=$.pop();if(o1!==r1.tagName){let Y=N(R,r1.tagStartPos);return x("InvalidTag","Expected closing tag '"+r1.tagName+"' (opened in line "+Y.line+", col "+Y.col+") instead of closing tag '"+o1+"'.",N(R,e1))}$.length==0&&(H=!0)}}else return x("InvalidTag","Closing tag '"+o1+"' doesn't have proper closing.",N(R,Q));else{const r1=E(l1,j);if(r1!==!0)return x(r1.err.code,r1.err.msg,N(R,Q-l1.length+r1.err.line));if(H===!0)return x("InvalidXml","Multiple possible root nodes found.",N(R,Q));j.unpairedTags.indexOf(o1)!==-1||$.push({tagName:o1,tagStartPos:e1}),K=!0}for(Q++;Q0)return x("InvalidXml","Invalid '"+JSON.stringify($.map(Q=>Q.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return x("InvalidXml","Start tag expected.",1);return!0};function f(R){return R===" "||R===" "||R===` +`||R==="\r"}function d(R,j){const $=j;for(;j5&&K==="xml")return x("InvalidXml","XML declaration allowed only at the start of the document.",N(R,j));if(R[j]=="?"&&R[j+1]==">"){j++;break}else continue}return j}function p(R,j){if(R.length>j+5&&R[j+1]==="-"&&R[j+2]==="-"){for(j+=3;j"){j+=2;break}}else if(R.length>j+8&&R[j+1]==="D"&&R[j+2]==="O"&&R[j+3]==="C"&&R[j+4]==="T"&&R[j+5]==="Y"&&R[j+6]==="P"&&R[j+7]==="E"){let $=1;for(j+=8;j"&&($--,$===0))break}else if(R.length>j+9&&R[j+1]==="["&&R[j+2]==="C"&&R[j+3]==="D"&&R[j+4]==="A"&&R[j+5]==="T"&&R[j+6]==="A"&&R[j+7]==="["){for(j+=8;j"){j+=2;break}}return j}const m='"',h="'";function _(R,j){let $="",K="",H=!1;for(;j"&&K===""){H=!0;break}$+=R[j]}return K!==""?!1:{value:$,index:j,tagClosed:H}}const S=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function E(R,j){const $=s.getAllMatches(R,S),K={};for(let H=0;H<$.length;H++){if($[H][1].length===0)return x("InvalidAttr","Attribute '"+$[H][2]+"' has no space in starting.",B($[H]));if($[H][3]!==void 0&&$[H][4]===void 0)return x("InvalidAttr","Attribute '"+$[H][2]+"' is without value.",B($[H]));if($[H][3]===void 0&&!j.allowBooleanAttributes)return x("InvalidAttr","boolean attribute '"+$[H][2]+"' is not allowed.",B($[H]));const Q=$[H][2];if(!w(Q))return x("InvalidAttr","Attribute '"+Q+"' is an invalid name.",B($[H]));if(!K.hasOwnProperty(Q))K[Q]=1;else return x("InvalidAttr","Attribute '"+Q+"' is repeated.",B($[H]))}return!0}function k(R,j){let $=/\d/;for(R[j]==="x"&&(j++,$=/[\da-fA-F]/);j","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[]};function f(x){this.options=Object.assign({},u,x),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=O),this.processTextOrObjNode=p,this.options.format?(this.indentate=k,this.tagEndChar=`> +`,this.newLine=` +`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine=""),this.options.suppressEmptyNode?(this.buildTextNode=E,this.buildObjNode=h):(this.buildTextNode=_,this.buildObjNode=m),this.buildTextValNode=_,this.buildObjectNode=m,this.replaceEntitiesValue=S,this.buildAttrPairStr=d}f.prototype.build=function(x){return this.options.preserveOrder?s(x,this.options):(Array.isArray(x)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(x={[this.options.arrayNodeName]:x}),this.j2x(x,0).val)},f.prototype.j2x=function(x,w){let b="",N="";for(let B in x)if(!(typeof x[B]>"u"))if(x[B]===null)B[0]==="?"?N+=this.indentate(w)+"<"+B+"?"+this.tagEndChar:N+=this.indentate(w)+"<"+B+"/"+this.tagEndChar;else if(x[B]instanceof Date)N+=this.buildTextNode(x[B],B,"",w);else if(typeof x[B]!="object"){const R=this.isAttribute(B);if(R)b+=this.buildAttrPairStr(R,""+x[B]);else if(B===this.options.textNodeName){let j=this.options.tagValueProcessor(B,""+x[B]);N+=this.replaceEntitiesValue(j)}else N+=this.buildTextNode(x[B],B,"",w)}else if(Array.isArray(x[B])){const R=x[B].length;for(let j=0;j"u"||($===null?B[0]==="?"?N+=this.indentate(w)+"<"+B+"?"+this.tagEndChar:N+=this.indentate(w)+"<"+B+"/"+this.tagEndChar:typeof $=="object"?N+=this.processTextOrObjNode($,B,w):N+=this.buildTextNode($,B,"",w))}}else if(this.options.attributesGroupName&&B===this.options.attributesGroupName){const R=Object.keys(x[B]),j=R.length;for(let $=0;$"+x+B:this.options.commentPropName!==!1&&w===this.options.commentPropName&&R.length===0?this.indentate(N)+``+this.newLine:this.indentate(N)+"<"+w+b+R+this.tagEndChar+x+this.indentate(N)+B}function h(x,w,b,N){return x!==""?this.buildObjectNode(x,w,b,N):w[0]==="?"?this.indentate(N)+"<"+w+b+"?"+this.tagEndChar:this.indentate(N)+"<"+w+b+"/"+this.tagEndChar}function _(x,w,b,N){if(this.options.cdataPropName!==!1&&w===this.options.cdataPropName)return this.indentate(N)+``+this.newLine;if(this.options.commentPropName!==!1&&w===this.options.commentPropName)return this.indentate(N)+``+this.newLine;{let B=this.options.tagValueProcessor(w,x);return B=this.replaceEntitiesValue(B),B===""&&this.options.unpairedTags.indexOf(w)!==-1?this.options.suppressUnpairedNode?this.indentate(N)+"<"+w+this.tagEndChar:this.indentate(N)+"<"+w+"/"+this.tagEndChar:this.indentate(N)+"<"+w+b+">"+B+"0&&this.options.processEntities)for(let w=0;w0&&(x=s+""+S.indentBy.repeat(k));for(let w=0;w<_.length;w++){const b=_[w],N=d(b);let B="";if(E.length===0?B=N:B=`${E}.${N}`,N===S.textNodeName){let K=b[N];m(B,S)||(K=S.tagValueProcessor(N,K),K=h(K,S)),O+=x+K;continue}else if(N===S.cdataPropName){O+=x+``;continue}else if(N===S.commentPropName){O+=x+``;continue}else if(N[0]==="?"){const K=p(b[":@"],S),H=N==="?xml"?"":x;let Q=b[N][0][S.textNodeName];Q=Q.length!==0?" "+Q:"",O+=H+`<${N}${Q}${K}?>`;continue}const R=p(b[":@"],S);let j=x+`<${N}${R}`,$=f(b[N],S,B,k+1);S.unpairedTags.indexOf(N)!==-1?S.suppressUnpairedNode?O+=j+">":O+=j+"/>":(!$||$.length===0)&&S.suppressEmptyNode?O+=j+"/>":O+=j+`>${$}${x}`}return O}function d(_){const S=Object.keys(_);for(let E=0;E0&&S.processEntities)for(let E=0;E"){if(E)if(d[p-1]==="-"&&d[p-2]==="-")E=!1;else throw new Error("Invalid XML comment in DOCTYPE");else S&&(f(k,m),S=!1);if(h--,h===0)break}else d[p]==="["?_=!0:k+=d[p];if(h!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:m,i:p}}const u=RegExp(`^\\s([a-zA-z0-0]+)[ ](['"])([^&]+)\\2`);function f(d,p){const m=u.exec(d);m&&(p[m[1]]={regx:RegExp(`&${m[1]};`,"g"),val:m[3]})}i.exports=s},{}],9:[function(n,i,r){const s={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0},tagValueProcessor:function(f,d){return d},attributeValueProcessor:function(f,d){return d},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1},u=function(f){return Object.assign({},s,f)};r.buildOptions=u,r.defaultOptions=s},{}],10:[function(n,i,r){const s=n("../util"),u=n("./xmlNode"),f=n("./DocTypeReader"),d=n("strnum");"<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,s.nameRegexp);class p{constructor(K){this.options=K,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={amp:{regex:/&(amp|#38|#x26);/g,val:"&"},apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"}},this.addExternalEntities=m,this.parseXml=k,this.parseTextData=h,this.resolveNameSpace=_,this.buildAttributesMap=E,this.isItStopNode=w,this.replaceEntitiesValue=O,this.readStopNodeData=R,this.saveTextToParentTag=x}}function m($){const K=Object.keys($);for(let H=0;H0)){o1||($=this.replaceEntitiesValue($));const n1=this.options.tagValueProcessor(K,$,H,e1,X);return n1==null?$:typeof n1!=typeof $||n1!==$?n1:this.options.trimValues?j($,this.options.parseTagValue,this.options.numberParseOptions):$.trim()===$?j($,this.options.parseTagValue,this.options.numberParseOptions):$}}function _($){if(this.options.removeNSPrefix){const K=$.split(":"),H=$.charAt(0)==="/"?"/":"";if(K[0]==="xmlns")return"";K.length===2&&($=H+K[1])}return $}const S=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function E($,K){if(!this.options.ignoreAttributes&&typeof $=="string"){const H=s.getAllMatches($,S),Q=H.length,e1={};for(let X=0;X",X,"Closing Tag is not closed.");let l1=$.substring(X+2,n1).trim();if(this.options.removeNSPrefix){const r1=l1.indexOf(":");r1!==-1&&(l1=l1.substr(r1+1))}H&&(Q=this.saveTextToParentTag(Q,H,e1)),e1=e1.substr(0,e1.lastIndexOf(".")),H=this.tagsNodeStack.pop(),Q="",X=n1}else if($[X+1]==="?"){let n1=B($,X,!1,"?>");if(!n1)throw new Error("Pi Tag is not closed.");if(Q=this.saveTextToParentTag(Q,H,e1),!(this.options.ignoreDeclaration&&n1.tagName==="?xml"||this.options.ignorePiTags)){const l1=new u(n1.tagName);l1.add(this.options.textNodeName,""),n1.tagName!==n1.tagExp&&n1.attrExpPresent&&(l1[":@"]=this.buildAttributesMap(n1.tagExp,e1)),H.addChild(l1)}X=n1.closeIndex+1}else if($.substr(X+1,3)==="!--"){const n1=N($,"-->",X+4,"Comment is not closed.");if(this.options.commentPropName){const l1=$.substring(X+4,n1-2);Q=this.saveTextToParentTag(Q,H,e1),H.add(this.options.commentPropName,[{[this.options.textNodeName]:l1}])}X=n1}else if($.substr(X+1,2)==="!D"){const n1=f($,X);this.docTypeEntities=n1.entities,X=n1.i}else if($.substr(X+1,2)==="!["){const n1=N($,"]]>",X,"CDATA is not closed.")-2,l1=$.substring(X+9,n1);if(Q=this.saveTextToParentTag(Q,H,e1),this.options.cdataPropName)H.add(this.options.cdataPropName,[{[this.options.textNodeName]:l1}]);else{let r1=this.parseTextData(l1,H.tagname,e1,!0,!1,!0);r1||(r1=""),H.add(this.options.textNodeName,r1)}X=n1+2}else{let n1=B($,X,this.options.removeNSPrefix),l1=n1.tagName,r1=n1.tagExp,Y=n1.attrExpPresent,g1=n1.closeIndex;H&&Q&&H.tagname!=="!xml"&&(Q=this.saveTextToParentTag(Q,H,e1,!1)),l1!==K.tagname&&(e1+=e1?"."+l1:l1);const f1=H;if(f1&&this.options.unpairedTags.indexOf(f1.tagname)!==-1&&(H=this.tagsNodeStack.pop()),this.isItStopNode(this.options.stopNodes,e1,l1)){let w1="";if(r1.length>0&&r1.lastIndexOf("/")===r1.length-1)X=n1.closeIndex;else if(this.options.unpairedTags.indexOf(l1)!==-1)X=n1.closeIndex;else{const U1=this.readStopNodeData($,l1,g1+1);if(!U1)throw new Error(`Unexpected end of ${l1}`);X=U1.i,w1=U1.tagContent}const k1=new u(l1);l1!==r1&&Y&&(k1[":@"]=this.buildAttributesMap(r1,e1)),w1&&(w1=this.parseTextData(w1,l1,e1,!0,Y,!0,!0)),e1=e1.substr(0,e1.lastIndexOf(".")),k1.add(this.options.textNodeName,w1),H.addChild(k1)}else{if(r1.length>0&&r1.lastIndexOf("/")===r1.length-1){l1[l1.length-1]==="/"?(l1=l1.substr(0,l1.length-1),r1=l1):r1=r1.substr(0,r1.length-1);const w1=new u(l1);l1!==r1&&Y&&(w1[":@"]=this.buildAttributesMap(r1,e1)),e1=e1.substr(0,e1.lastIndexOf(".")),H.addChild(w1)}else{const w1=new u(l1);this.tagsNodeStack.push(H),l1!==r1&&Y&&(w1[":@"]=this.buildAttributesMap(r1,e1)),H.addChild(w1),H=w1}Q="",X=g1}}else Q+=$[X];return K.child},O=function($){if(this.options.processEntities){for(let K in this.docTypeEntities){const H=this.docTypeEntities[K];$=$.replace(H.regx,H.val)}for(let K in this.lastEntities){const H=this.lastEntities[K];$=$.replace(H.regex,H.val)}if(this.options.htmlEntities)for(let K in this.htmlEntities){const H=this.htmlEntities[K];$=$.replace(H.regex,H.val)}}return $};function x($,K,H,Q){return $&&(Q===void 0&&(Q=Object.keys(K.child).length===0),$=this.parseTextData($,K.tagname,H,!1,K[":@"]?Object.keys(K[":@"]).length!==0:!1,Q),$!==void 0&&$!==""&&K.add(this.options.textNodeName,$),$=""),$}function w($,K,H){const Q="*."+H;for(const e1 in $){const X=$[e1];if(Q===X||K===X)return!0}return!1}function b($,K,H=">"){let Q,e1="";for(let X=K;X<$.length;X++){let o1=$[X];if(Q)o1===Q&&(Q="");else if(o1==='"'||o1==="'")Q=o1;else if(o1===H[0])if(H[1]){if($[X+1]===H[1])return{data:e1,index:X}}else return{data:e1,index:X};else o1===" "&&(o1=" ");e1+=o1}}function N($,K,H,Q){const e1=$.indexOf(K,H);if(e1===-1)throw new Error(Q);return e1+K.length-1}function B($,K,H,Q=">"){const e1=b($,K+1,Q);if(!e1)return;let X=e1.data;const o1=e1.index,n1=X.search(/\s/);let l1=X,r1=!0;if(n1!==-1&&(l1=X.substr(0,n1).replace(/\s\s*$/,""),X=X.substr(n1+1)),H){const Y=l1.indexOf(":");Y!==-1&&(l1=l1.substr(Y+1),r1=l1!==e1.data.substr(Y+1))}return{tagName:l1,tagExp:X,closeIndex:o1,attrExpPresent:r1}}function R($,K,H){const Q=H;for(;H<$.length;H++)if($[H]==="<"&&$[H+1]==="/"){const e1=N($,">",H,`${K} is not closed`);if($.substring(H+2,e1).trim()===K)return{tagContent:$.substring(Q,H),i:e1};H=e1}}function j($,K,H){if(K&&typeof $=="string"){const Q=$.trim();return Q==="true"?!0:Q==="false"?!1:d($,H)}else return s.isExist($)?$:""}i.exports=p},{"../util":4,"./DocTypeReader":8,"./xmlNode":13,strnum:15}],11:[function(n,i,r){const{buildOptions:s}=n("./OptionsBuilder"),u=n("./OrderedObjParser"),{prettify:f}=n("./node2json"),d=n("../validator");class p{constructor(h){this.externalEntities={},this.options=s(h)}parse(h,_){if(typeof h!="string")if(h.toString)h=h.toString();else throw new Error("XML data is accepted in String or Bytes[] form.");if(_){_===!0&&(_={});const k=d.validate(h,_);if(k!==!0)throw Error(`${k.err.msg}:${k.err.line}:${k.err.col}`)}const S=new u(this.options);S.addExternalEntities(this.externalEntities);const E=S.parseXml(h);return this.options.preserveOrder||E===void 0?E:f(E,this.options)}addEntity(h,_){if(_.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(h.indexOf("&")!==-1||h.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for ' '");this.externalEntities[h]=_}}i.exports=p},{"../validator":5,"./OptionsBuilder":9,"./OrderedObjParser":10,"./node2json":12}],12:[function(n,i,r){function s(m,h){return u(m,h)}function u(m,h,_){let S;const E={};for(let k=0;k0&&(E[h.textNodeName]=S):S!==void 0&&(E[h.textNodeName]=S),E}function f(m){const h=Object.keys(m);for(let _=0;_0?this.child.push({[f.tagname]:f.child,":@":f[":@"]}):this.child.push({[f.tagname]:f.child})}}i.exports=s},{}],14:[function(n,i,r){/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */r.read=function(s,u,f,d,p){var m,h,_=p*8-d-1,S=(1<<_)-1,E=S>>1,k=-7,O=f?p-1:0,x=f?-1:1,w=s[u+O];for(O+=x,m=w&(1<<-k)-1,w>>=-k,k+=_;k>0;m=m*256+s[u+O],O+=x,k-=8);for(h=m&(1<<-k)-1,m>>=-k,k+=d;k>0;h=h*256+s[u+O],O+=x,k-=8);if(m===0)m=1-E;else{if(m===S)return h?NaN:(w?-1:1)*(1/0);h=h+Math.pow(2,d),m=m-E}return(w?-1:1)*h*Math.pow(2,m-d)},r.write=function(s,u,f,d,p,m){var h,_,S,E=m*8-p-1,k=(1<>1,x=p===23?Math.pow(2,-24)-Math.pow(2,-77):0,w=d?0:m-1,b=d?1:-1,N=u<0||u===0&&1/u<0?1:0;for(u=Math.abs(u),isNaN(u)||u===1/0?(_=isNaN(u)?1:0,h=k):(h=Math.floor(Math.log(u)/Math.LN2),u*(S=Math.pow(2,-h))<1&&(h--,S*=2),h+O>=1?u+=x/S:u+=x*Math.pow(2,1-O),u*S>=2&&(h++,S/=2),h+O>=k?(_=0,h=k):h+O>=1?(_=(u*S-1)*Math.pow(2,p),h=h+O):(_=u*Math.pow(2,O-1)*Math.pow(2,p),h=0));p>=8;s[f+w]=_&255,w+=b,_/=256,p-=8);for(h=h<0;s[f+w]=h&255,w+=b,h/=256,E-=8);s[f+w-b]|=N*128}},{}],15:[function(n,i,r){const s=/^[-+]?0x[a-fA-F0-9]+$/,u=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);const f={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function d(m,h={}){if(h=Object.assign({},f,h),!m||typeof m!="string")return m;let _=m.trim();if(h.skipLike!==void 0&&h.skipLike.test(_))return m;if(h.hex&&s.test(_))return Number.parseInt(_,16);{const S=u.exec(_);if(S){const E=S[1],k=S[2];let O=p(S[3]);const x=S[4]||S[6];if(!h.leadingZeros&&k.length>0&&E&&_[2]!==".")return m;if(!h.leadingZeros&&k.length>0&&!E&&_[1]!==".")return m;{const w=Number(_),b=""+w;return b.search(/[eE]/)!==-1||x?h.eNotation?w:m:_.indexOf(".")!==-1?b==="0"&&O===""||b===O||E&&b==="-"+O?w:m:k?O===b||E+O===b?w:m:_===b||_===E+b?w:m}}else return m}}function p(m){return m&&m.indexOf(".")!==-1&&(m=m.replace(/0+$/,""),m==="."?m="0":m[0]==="."?m="0"+m:m[m.length-1]==="."&&(m=m.substr(0,m.length-1))),m}i.exports=d},{}],16:[function(n,i,r){(function(s){(function(){var u=this&&this.__awaiter||function(_,S,E,k){function O(x){return x instanceof E?x:new E(function(w){w(x)})}return new(E||(E=Promise))(function(x,w){function b(R){try{B(k.next(R))}catch(j){w(j)}}function N(R){try{B(k.throw(R))}catch(j){w(j)}}function B(R){R.done?x(R.value):O(R.value).then(b,N)}B((k=k.apply(_,S||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.osmFetch=void 0;const f=n("../auth"),d=n("../config"),p=n("./_xml"),m=_=>typeof btoa>"u"?s.from(_,"binary").toString("base64"):btoa(_);function h(_,S,E){return u(this,void 0,void 0,function*(){const{apiUrl:k,authHeader:O,basicAuth:x,userAgent:w}=(0,d.getConfig)(),b=x&&`Basic ${m(`${x.username}:${x.password}`)}`,N=(0,f.getAuthToken)()&&`Bearer ${(0,f.getAuthToken)()}`;let B=new URLSearchParams(S).toString();B&&(B=`?${B}`);const R=yield fetch(`${k}/api${_}${B}`,Object.assign(Object.assign({},E),{headers:Object.assign({Authorization:O||b||N||"","User-Agent":w},E==null?void 0:E.headers)})),j=R.headers.get("Content-Type");if(j!=null&&j.startsWith("application/xml")){const $=yield R.text();return yield p.xmlParser.parse($)}if(j!=null&&j.startsWith("application/json"))return R.json();if(R.ok)return yield R.text();throw new Error(`OSM API: ${yield R.text()}`)})}r.osmFetch=h}).call(this)}).call(this,n("buffer").Buffer)},{"../auth":37,"../config":39,"./_xml":17,buffer:2}],17:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.xmlParser=void 0;const s=n("fast-xml-parser");r.xmlParser=new s.XMLParser({ignoreAttributes:!1,attributesGroupName:"$",attributeNamePrefix:"",isArray:u=>u!=="$"})},{"fast-xml-parser":3}],18:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.createOsmChangeXml=r.createChangesetMetaXml=void 0;const s=n("fast-xml-parser"),u=new s.XMLBuilder({ignoreAttributes:!1,attributeNamePrefix:"$",format:!0,suppressEmptyNode:!0,suppressBooleanAttributes:!1});function f(m){return u.build({osm:{changeset:{tag:Object.entries(m).map(([h,_])=>({$k:h,$v:_}))}}})}r.createChangesetMetaXml=f;const d=(m,h,_)=>h.reduce((S,E)=>{const k={$id:E.id,$version:_?0:E.version,$changeset:m,tag:Object.entries(E.tags||{}).map(([O,x])=>({$k:O,$v:x}))};switch(E.type){case"node":{const O=Object.assign(Object.assign({},k),{$lat:E.lat,$lon:E.lon});return Object.assign(Object.assign({},S),{node:[...S.node,O]})}case"way":{if(!E.nodes)throw new Error("Way has no nodes");const O=Object.assign(Object.assign({},k),{nd:E.nodes.map(x=>({$ref:x}))});return Object.assign(Object.assign({},S),{way:[...S.way,O]})}case"relation":{if(!E.members)throw new Error("Relation has no members");const O=Object.assign(Object.assign({},k),{member:E.members.map(x=>({$type:x.type,$ref:x.ref,$role:x.role}))});return Object.assign(Object.assign({},S),{relation:[...S.relation,O]})}default:return S}},{node:[],way:[],relation:[]});function p(m,h,_){return u.build({osmChange:Object.assign(Object.assign({$version:"0.6",$generator:"osm-api-js"},_),{create:[d(m,h.create,!0)],modify:[d(m,h.modify)],delete:[Object.assign({"$if-unused":!0},d(m,h.delete))]})})}r.createOsmChangeXml=p},{"fast-xml-parser":3}],19:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.parseOsmChangeXml=r.parseOsmChangeJson=void 0;const s=n("../_xml");function u(m){return{changeset:+m.$.changeset,id:+m.$.id,timestamp:m.$.timestamp,uid:+m.$.uid,user:m.$.user,version:+m.$.version,tags:m.tag?Object.fromEntries(m.tag.map(h=>[h.$.k,h.$.v])):void 0}}const f=m=>{const h=[];if(m.node){const _=m.node.map(S=>Object.assign(Object.assign({type:"node"},u(S)),{lat:+S.$.lat,lon:+S.$.lon}));h.push(..._)}if(m.way){const _=m.way.map(S=>{var E;return Object.assign(Object.assign({type:"way"},u(S)),{nodes:((E=S.nd)===null||E===void 0?void 0:E.map(k=>+k.$.ref))||[]})});h.push(..._)}if(m.relation){const _=m.relation.map(S=>{var E;return Object.assign(Object.assign({type:"relation"},u(S)),{members:((E=S.member)===null||E===void 0?void 0:E.map(k=>({ref:+k.$.ref,role:k.$.role,type:k.$.type})))||[]})});h.push(..._)}return h};function d(m){var h,_,S;return{create:((h=m.osmChange[0].create)===null||h===void 0?void 0:h.flatMap(f))||[],modify:((_=m.osmChange[0].modify)===null||_===void 0?void 0:_.flatMap(f))||[],delete:((S=m.osmChange[0].delete)===null||S===void 0?void 0:S.flatMap(f))||[]}}r.parseOsmChangeJson=d;function p(m){const h=s.xmlParser.parse(m);return d(h)}r.parseOsmChangeXml=p},{"../_xml":17}],20:[function(n,i,r){var s=this&&this.__awaiter||function(d,p,m,h){function _(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):_(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.createChangesetComment=void 0;const u=n("../_osmFetch");function f(d,p){return s(this,void 0,void 0,function*(){yield(0,u.osmFetch)(`/0.6/changeset/${d}/comment`,void 0,{method:"POST",body:`text=${encodeURIComponent(p)}`,headers:{"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"}})})}r.createChangesetComment=f},{"../_osmFetch":16}],21:[function(n,i,r){var s=this&&this.__awaiter||function(p,m,h,_){function S(E){return E instanceof h?E:new h(function(k){k(E)})}return new(h||(h=Promise))(function(E,k){function O(b){try{w(_.next(b))}catch(N){k(N)}}function x(b){try{w(_.throw(b))}catch(N){k(N)}}function w(b){b.done?E(b.value):S(b.value).then(O,x)}w((_=_.apply(p,m||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getChangesetDiff=void 0;const u=n("../_osmFetch"),f=n("./_parseOsmChangeXml");function d(p){return s(this,void 0,void 0,function*(){const m=yield(0,u.osmFetch)(`/0.6/changeset/${p}/download`);return(0,f.parseOsmChangeJson)(m)})}r.getChangesetDiff=d},{"../_osmFetch":16,"./_parseOsmChangeXml":19}],22:[function(n,i,r){var s=this&&this.__awaiter||function(h,_,S,E){function k(O){return O instanceof S?O:new S(function(x){x(O)})}return new(S||(S=Promise))(function(O,x){function w(B){try{N(E.next(B))}catch(R){x(R)}}function b(B){try{N(E.throw(B))}catch(R){x(R)}}function N(B){B.done?O(B.value):k(B.value).then(w,b)}N((E=E.apply(h,_||[])).next())})},u=this&&this.__rest||function(h,_){var S={};for(var E in h)Object.prototype.hasOwnProperty.call(h,E)&&_.indexOf(E)<0&&(S[E]=h[E]);if(h!=null&&typeof Object.getOwnPropertySymbols=="function")for(var k=0,E=Object.getOwnPropertySymbols(h);k{var _;return{id:+h.$.id,created_at:new Date(h.$.created_at),closed_at:new Date(h.$.closed_at),open:h.$.open==="true",comments_count:+h.$.comments_count,changes_count:+h.$.changes_count,min_lat:+h.$.min_lat,min_lon:+h.$.min_lon,max_lat:+h.$.max_lat,max_lon:+h.$.max_lon,uid:+h.$.uid,user:h.$.user,tags:Object.fromEntries(h.tag.map(S=>[S.$.k,S.$.v])),discussion:(_=h.discussion)===null||_===void 0?void 0:_[0].comment.map(S=>({date:new Date(S.$.date),user:S.$.user,uid:S.$.uid,text:S.text[0]}))}};function p(h){var _;return s(this,void 0,void 0,function*(){const{only:S}=h,E=u(h,["only"]);return((_=(yield(0,f.osmFetch)("/0.6/changesets",Object.assign(Object.assign({},S&&{[S]:!0}),E))).osm[0].changeset)===null||_===void 0?void 0:_.map(d))||[]})}r.listChangesets=p;function m(h,_=!0){return s(this,void 0,void 0,function*(){return(yield(0,f.osmFetch)(`/0.6/changeset/${h}`,{include_discussion:_})).osm[0].changeset.map(d)[0]})}r.getChangeset=m},{"../_osmFetch":16}],23:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(p,m,h,_){_===void 0&&(_=h);var S=Object.getOwnPropertyDescriptor(m,h);(!S||("get"in S?!m.__esModule:S.writable||S.configurable))&&(S={enumerable:!0,get:function(){return m[h]}}),Object.defineProperty(p,_,S)}:function(p,m,h,_){_===void 0&&(_=h),p[_]=m[h]}),u=this&&this.__exportStar||function(p,m){for(var h in p)h!=="default"&&!Object.prototype.hasOwnProperty.call(m,h)&&s(m,p,h)};Object.defineProperty(r,"__esModule",{value:!0}),r.createOsmChangeXml=r.parseOsmChangeXml=void 0,u(n("./createChangesetComment"),r),u(n("./getChangesetDiff"),r),u(n("./getChangesets"),r),u(n("./uploadChangeset"),r);var f=n("./_parseOsmChangeXml");Object.defineProperty(r,"parseOsmChangeXml",{enumerable:!0,get:function(){return f.parseOsmChangeXml}});var d=n("./_createOsmChangeXml");Object.defineProperty(r,"createOsmChangeXml",{enumerable:!0,get:function(){return d.createOsmChangeXml}})},{"./_createOsmChangeXml":18,"./_parseOsmChangeXml":19,"./createChangesetComment":20,"./getChangesetDiff":21,"./getChangesets":22,"./uploadChangeset":24}],24:[function(n,i,r){var s=this&&this.__awaiter||function(p,m,h,_){function S(E){return E instanceof h?E:new h(function(k){k(E)})}return new(h||(h=Promise))(function(E,k){function O(b){try{w(_.next(b))}catch(N){k(N)}}function x(b){try{w(_.throw(b))}catch(N){k(N)}}function w(b){b.done?E(b.value):S(b.value).then(O,x)}w((_=_.apply(p,m||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.uploadChangeset=void 0;const u=n("../_osmFetch"),f=n("./_createOsmChangeXml");function d(p,m){return s(this,void 0,void 0,function*(){const h=(0,f.createChangesetMetaXml)(p),_=+(yield(0,u.osmFetch)("/0.6/changeset/create",void 0,{method:"PUT",body:h,headers:{"content-type":"application/xml; charset=utf-8"}})),S=(0,f.createOsmChangeXml)(_,m);return yield(0,u.osmFetch)(`/0.6/changeset/${_}/upload`,void 0,{method:"POST",body:S,headers:{"content-type":"application/xml; charset=utf-8"}}),yield(0,u.osmFetch)(`/0.6/changeset/${_}/close`,void 0,{method:"PUT"}),+_})}r.uploadChangeset=d},{"../_osmFetch":16,"./_createOsmChangeXml":18}],25:[function(n,i,r){var s=this&&this.__awaiter||function(d,p,m,h){function _(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):_(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getCapabilities=void 0;const u=n("./_osmFetch");function f(){return s(this,void 0,void 0,function*(){const d=yield(0,u.osmFetch)("/capabilities");return{limits:{maxArea:+d.osm[0].api[0].area[0].$.maximum,maxNoteArea:+d.osm[0].api[0].note_area[0].$.maximum,maxTracepointPerPage:+d.osm[0].api[0].tracepoints[0].$.per_page,maxWayNodes:+d.osm[0].api[0].waynodes[0].$.maximum,maxChangesetElements:+d.osm[0].api[0].changesets[0].$.maximum_elements,maxTimeout:+d.osm[0].api[0].timeout[0].$.seconds},policy:{imageryBlacklist:d.osm[0].policy[0].imagery[0].blacklist.map(m=>m.$.regex)}}})}r.getCapabilities=f},{"./_osmFetch":16}],26:[function(n,i,r){var s=this&&this.__awaiter||function(S,E,k,O){function x(w){return w instanceof k?w:new k(function(b){b(w)})}return new(k||(k=Promise))(function(w,b){function N(j){try{R(O.next(j))}catch($){b($)}}function B(j){try{R(O.throw(j))}catch($){b($)}}function R(j){j.done?w(j.value):x(j.value).then(N,B)}R((O=O.apply(S,E||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getRelationsForElement=r.getWaysForNode=r.getFeatureHistory=r.getFeatureAtVersion=r.getFeatures=r.getFeature=void 0;const u=n("./_osmFetch");function f(S,E,k){return s(this,void 0,void 0,function*(){const O=k&&S!=="node"?"/full":"";return(yield(0,u.osmFetch)(`/0.6/${S}/${E}${O}.json`)).elements})}r.getFeature=f;function d(S,E){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}s.json?${S}s=${E.join(",")}`)).elements})}r.getFeatures=d;function p(S,E,k){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}/${E}/${k}.json`)).elements[0]})}r.getFeatureAtVersion=p;function m(S,E){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}/${E}/history.json`)).elements})}r.getFeatureHistory=m;function h(S){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/node/${S}/ways.json`)).elements})}r.getWaysForNode=h;function _(S,E){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}/${E}/relations.json`)).elements})}r.getRelationsForElement=_},{"./_osmFetch":16}],27:[function(n,i,r){var s=this&&this.__awaiter||function(d,p,m,h){function _(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):_(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getMapData=void 0;const u=n("./_osmFetch");function f(d){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)("/0.6/map.json",{bbox:d})).elements})}r.getMapData=f},{"./_osmFetch":16}],28:[function(n,i,r){var s=this&&this.__awaiter||function(d,p,m,h){function _(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):_(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getUIdFromDisplayName=void 0;const u=n("./changesets");function f(d){return s(this,void 0,void 0,function*(){const p=yield(0,u.listChangesets)({display_name:d});if(!p.length)throw new Error("Could not get uid because the user has never edited the map");return p[0].uid})}r.getUIdFromDisplayName=f},{"./changesets":23}],29:[function(n,i,r){var s=this&&this.__awaiter||function(p,m,h,_){function S(E){return E instanceof h?E:new h(function(k){k(E)})}return new(h||(h=Promise))(function(E,k){function O(b){try{w(_.next(b))}catch(N){k(N)}}function x(b){try{w(_.throw(b))}catch(N){k(N)}}function w(b){b.done?E(b.value):S(b.value).then(O,x)}w((_=_.apply(p,m||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getUsers=r.getUser=void 0;const u=n("./_osmFetch");function f(p){return s(this,void 0,void 0,function*(){const m=yield(0,u.osmFetch)(`/0.6/user/${p==="me"?"details":p}.json`);return Object.assign(Object.assign({},m.user),{account_created:new Date(m.user.account_created)})})}r.getUser=f;function d(p){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)("/0.6/users",{users:p})).users.map(h=>Object.assign(Object.assign({},h),{account_created:new Date(h.account_created)}))})}r.getUsers=d},{"./_osmFetch":16}],30:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&s(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./changesets"),r),u(n("./notes"),r),u(n("./getCapabilities"),r),u(n("./getFeature"),r),u(n("./getMapData"),r),u(n("./getUIdFromDisplayName"),r),u(n("./getUser"),r)},{"./changesets":23,"./getCapabilities":25,"./getFeature":26,"./getMapData":27,"./getUIdFromDisplayName":28,"./getUser":29,"./notes":32}],31:[function(n,i,r){var s=this&&this.__awaiter||function(_,S,E,k){function O(x){return x instanceof E?x:new E(function(w){w(x)})}return new(E||(E=Promise))(function(x,w){function b(R){try{B(k.next(R))}catch(j){w(j)}}function N(R){try{B(k.throw(R))}catch(j){w(j)}}function B(R){R.done?x(R.value):O(R.value).then(b,N)}B((k=k.apply(_,S||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getNote=r.getNotesForArea=r.getNotesForQuery=void 0;const u=n("../_osmFetch"),f=_=>{const[S,E]=_.geometry.coordinates;return Object.assign(Object.assign({},_.properties),{location:{lat:E,lng:S}})};function d(_,S){return s(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/notes${S?"/search":""}.json`,_)).features.map(f)})}function p(_){return d(_,!0)}r.getNotesForQuery=p;function m(_){return d({bbox:_},!1)}r.getNotesForArea=m;function h(_){return s(this,void 0,void 0,function*(){const S=yield(0,u.osmFetch)(`/0.6/notes/${_}.json`);return f(S)})}r.getNote=h},{"../_osmFetch":16}],32:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&s(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./getNotes"),r),u(n("./noteActions"),r)},{"./getNotes":31,"./noteActions":33}],33:[function(n,i,r){var s=this&&this.__awaiter||function(m,h,_,S){function E(k){return k instanceof _?k:new _(function(O){O(k)})}return new(_||(_=Promise))(function(k,O){function x(N){try{b(S.next(N))}catch(B){O(B)}}function w(N){try{b(S.throw(N))}catch(B){O(B)}}function b(N){N.done?k(N.value):E(N.value).then(x,w)}b((S=S.apply(m,h||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.reopenNote=r.commentOnNote=r.createNote=void 0;const u=n("../_osmFetch");function f(m,h,_){return s(this,void 0,void 0,function*(){yield(0,u.osmFetch)("/0.6/notes",{lat:m,lon:h,text:_})})}r.createNote=f;function d(m,h){return s(this,void 0,void 0,function*(){yield(0,u.osmFetch)(`/0.6/notes/${m}/comment`,{text:h})})}r.commentOnNote=d;function p(m,h){return s(this,void 0,void 0,function*(){yield(0,u.osmFetch)(`/0.6/notes/${m}/reopen`,{text:h})})}r.reopenNote=p},{"../_osmFetch":16}],34:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.createPopup=void 0;function s(u){let f=!1;return new Promise((d,p)=>{const[m,h]=[600,550],_=Object.entries({width:m,height:h,left:window.screen.width/2-m/2,top:window.screen.height/2-h/2}).map(([k,O])=>`${k}=${O}`).join(","),S=window.open("about:blank","oauth_window",_);if(!S)throw new Error("Popup was blocked");S.location=u,window.authComplete=k=>{d(k),f=!0};const E=setInterval(()=>{S.closed&&(f||p(new Error("Cancelled")),clearInterval(E))},500)})}r.createPopup=s},{}],35:[function(n,i,r){var s=this&&this.__awaiter||function(d,p,m,h){function _(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):_(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.exchangeCode=void 0;const u=n("./helpers");function f(d,{options:p,pkceVerifier:m,state:h}){return s(this,void 0,void 0,function*(){const _=new URL(d).searchParams,S=_.get("error_description"),E=_.get("code"),k=_.get("state");if(S)throw new Error(S);if(!E)throw new Error("No code in OAuth response");if(!m||!h)throw new Error("No login in progress");if(h!==k)throw new Error("State Mismatch");const O={grant_type:"authorization_code",code:E,redirect_uri:p.redirectUrl,client_id:p.clientId,code_verifier:m},x=`${(0,u.getOAuthBaseUrl)()}/oauth2/token?${new URLSearchParams(O).toString()}`,b=yield(yield fetch(x,{method:"POST",body:"",headers:{"Content-Type":"application/x-www-form-urlencoded"}})).json();if("error_description"in b)throw new Error(b.error_description);const N={issuedAt:new Date(b.created_at*1e3).toISOString(),accessToken:b.access_token,scopes:b.scope.split(" ")};return localStorage.setItem("__osmAuth",JSON.stringify(N)),delete window.authComplete,N})}r.exchangeCode=f},{"./helpers":36}],36:[function(n,i,r){var s=this&&this.__awaiter||function(m,h,_,S){function E(k){return k instanceof _?k:new _(function(O){O(k)})}return new(_||(_=Promise))(function(k,O){function x(N){try{b(S.next(N))}catch(B){O(B)}}function w(N){try{b(S.throw(N))}catch(B){O(B)}}function b(N){N.done?k(N.value):E(N.value).then(x,w)}b((S=S.apply(m,h||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getOAuthBaseUrl=r.getRandomString=r.sha256=void 0;const u=n("../config");function f(m){return s(this,void 0,void 0,function*(){const h=new TextEncoder().encode(m),_=yield window.crypto.subtle.digest("SHA-256",h);return btoa(String.fromCharCode(...new Uint8Array(_))).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")})}r.sha256=f;function d(){return[...window.crypto.getRandomValues(new Uint32Array(32))].map(m=>`0${m.toString(16)}`.slice(-2)).join("")}r.getRandomString=d;function p(){let m=(0,u.getConfig)().apiUrl;return m==="https://api.openstreetmap.org"&&(m="https://www.openstreetmap.org"),m}r.getOAuthBaseUrl=p},{"../config":39}],37:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&s(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./oauth2"),r)},{"./oauth2":38}],38:[function(n,i,r){var s=this&&this.__awaiter||function(S,E,k,O){function x(w){return w instanceof k?w:new k(function(b){b(w)})}return new(k||(k=Promise))(function(w,b){function N(j){try{R(O.next(j))}catch($){b($)}}function B(j){try{R(O.throw(j))}catch($){b($)}}function R(j){j.done?w(j.value):x(j.value).then(N,B)}R((O=O.apply(S,E||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.logout=r.isLoggedIn=r.getAuthToken=r.authReady=r.login=void 0;const u=n("./createPopup"),f=n("./exchangeCode"),d=n("./helpers");function p(S){return s(this,void 0,void 0,function*(){if(!S.redirectUrl)throw new Error("You must include the 'redirectUrl' option");if(!S.clientId)throw new Error("You must include the 'clientId' option");if(!S.scopes)throw new Error("You must include the 'scopes' option");const E=(0,d.getRandomString)(),k=(0,d.getRandomString)(),O=yield(0,d.sha256)(k),x={scope:S.scopes.join(" "),include_granted_scopes:"true",response_type:"code",state:E,redirect_uri:S.redirectUrl,client_id:S.clientId,code_challenge_method:"S256",code_challenge:O},w=`${(0,d.getOAuthBaseUrl)()}/oauth2/authorize?${new URLSearchParams(x).toString()}`,b={state:E,pkceVerifier:k,options:S};if(S.mode==="popup"){const N=yield(0,u.createPopup)(w);return(0,f.exchangeCode)(N,b)}if(S.mode==="redirect"){localStorage.set("__osmAuthTemp",JSON.stringify(b)),window.location.replace(w);return}throw new Error("options.mode must be 'popup' or 'redirect'")})}r.login=p,r.authReady=(()=>s(void 0,void 0,void 0,function*(){var S;if(typeof window>"u")return;const E=window.location.href,k=localStorage.getItem("__osmAuthTemp");if(new URL(E).searchParams.get("code")){if(!((S=window.opener)===null||S===void 0)&&S.authComplete)window.opener.authComplete(E),window.close();else if(k)try{const O=JSON.parse(k);yield(0,f.exchangeCode)(E,O),localStorage.removeItem("__osmAuthTemp")}catch(O){console.error("OSM Auth Error",O)}}}))();const m=()=>{try{const S=localStorage.getItem("__osmAuth");return S?JSON.parse(S).accessToken:void 0}catch{return}};r.getAuthToken=m;const h=()=>!!(0,r.getAuthToken)();r.isLoggedIn=h;function _(){localStorage.removeItem("__osmAuth")}r.logout=_},{"./createPopup":34,"./exchangeCode":35,"./helpers":36}],39:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.configure=r.getConfig=void 0;const s={apiUrl:"https://api.openstreetmap.org",userAgent:"https://github.com/k-yle/osm-api-js"},u=()=>s;r.getConfig=u;function f(d){Object.assign(s,d)}r.configure=f},{}],40:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&s(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),n("./polyfill"),u(n("./api"),r),u(n("./auth"),r),u(n("./config"),r),u(n("./types"),r)},{"./api":30,"./auth":37,"./config":39,"./polyfill":41,"./types":45}],41:[function(n,i,r){if(typeof fetch>"u")try{n("isomorphic-fetch")}catch{console.error([` +========== +`,"(!) The `fetch` API is not available, and the polyfill (`isomorphic-fetch`) is also not available.","Run `npm install isomorphic-fetch`, or make sure that the global variable `fetch` exists",` +========== +`].join(` +`))}},{"isomorphic-fetch":"isomorphic-fetch"}],42:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0})},{}],43:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}],44:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}],45:[function(n,i,r){var s=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&s(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./changesets"),r),u(n("./features"),r),u(n("./general"),r),u(n("./notes"),r),u(n("./user"),r)},{"./changesets":42,"./features":43,"./general":44,"./notes":46,"./user":47}],46:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}],47:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}]},{},[40])(40)})})(eM);var j4=eM.exports;function Se1(e,t=!1){const n=e.length;let i=0,r="",s=0,u=16,f=0,d=0,p=0,m=0,h=0;function _(b,N){let B=0,R=0;for(;B=48&&j<=57)R=R*16+j-48;else if(j>=65&&j<=70)R=R*16+j-65+10;else if(j>=97&&j<=102)R=R*16+j-97+10;else break;i++,B++}return B=n){b+=e.substring(N,i),h=2;break}const B=e.charCodeAt(i);if(B===34){b+=e.substring(N,i),i++;break}if(B===92){if(b+=e.substring(N,i),i++,i>=n){h=2;break}switch(e.charCodeAt(i++)){case 34:b+='"';break;case 92:b+="\\";break;case 47:b+="/";break;case 98:b+="\b";break;case 102:b+="\f";break;case 110:b+=` +`;break;case 114:b+="\r";break;case 116:b+=" ";break;case 117:const j=_(4,!0);j>=0?b+=String.fromCharCode(j):h=4;break;default:h=5}N=i;continue}if(B>=0&&B<=31)if(p7(B)){b+=e.substring(N,i),h=2;break}else h=6;i++}return b}function O(){if(r="",h=0,s=i,d=f,m=p,i>=n)return s=n,u=17;let b=e.charCodeAt(i);if(Nu(b)){do i++,r+=String.fromCharCode(b),b=e.charCodeAt(i);while(Nu(b));return u=15}if(p7(b))return i++,r+=String.fromCharCode(b),b===13&&e.charCodeAt(i)===10&&(i++,r+=` +`),f++,p=i,u=14;switch(b){case 123:return i++,u=1;case 125:return i++,u=2;case 91:return i++,u=3;case 93:return i++,u=4;case 58:return i++,u=6;case 44:return i++,u=5;case 34:return i++,r=k(),u=10;case 47:const N=i-1;if(e.charCodeAt(i+1)===47){for(i+=2;i=12&&b<=15);return b}return{setPosition:S,getPosition:()=>i,scan:t?w:O,getToken:()=>u,getTokenValue:()=>r,getTokenOffset:()=>s,getTokenLength:()=>i-s,getTokenStartLine:()=>d,getTokenStartCharacter:()=>s-m,getTokenError:()=>h}}function Nu(e){return e===32||e===9}function p7(e){return e===10||e===13}function f6(e){return e>=48&&e<=57}var c_;(function(e){e[e.lineFeed=10]="lineFeed",e[e.carriageReturn=13]="carriageReturn",e[e.space=32]="space",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e.asterisk=42]="asterisk",e[e.backslash=92]="backslash",e[e.closeBrace=125]="closeBrace",e[e.closeBracket=93]="closeBracket",e[e.colon=58]="colon",e[e.comma=44]="comma",e[e.dot=46]="dot",e[e.doubleQuote=34]="doubleQuote",e[e.minus=45]="minus",e[e.openBrace=123]="openBrace",e[e.openBracket=91]="openBracket",e[e.plus=43]="plus",e[e.slash=47]="slash",e[e.formFeed=12]="formFeed",e[e.tab=9]="tab"})(c_||(c_={}));var $r;(function(e){e.DEFAULT={allowTrailingComma:!1}})($r||($r={}));function Ee1(e,t=[],n=$r.DEFAULT){let i=null,r=[];const s=[];function u(d){Array.isArray(r)?r.push(d):i!==null&&(r[i]=d)}return Me1(e,{onObjectBegin:()=>{const d={};u(d),s.push(r),r=d,i=null},onObjectProperty:d=>{i=d},onObjectEnd:()=>{r=s.pop()},onArrayBegin:()=>{const d=[];u(d),s.push(r),r=d,i=null},onArrayEnd:()=>{r=s.pop()},onLiteralValue:u,onError:(d,p,m)=>{t.push({error:d,offset:p,length:m})}},n),r[0]}function Me1(e,t,n=$r.DEFAULT){const i=Se1(e,!1),r=[];function s(e1){return e1?()=>e1(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter()):()=>!0}function u(e1){return e1?()=>e1(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter(),()=>r.slice()):()=>!0}function f(e1){return e1?X=>e1(X,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter()):()=>!0}function d(e1){return e1?X=>e1(X,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter(),()=>r.slice()):()=>!0}const p=u(t.onObjectBegin),m=d(t.onObjectProperty),h=s(t.onObjectEnd),_=u(t.onArrayBegin),S=s(t.onArrayEnd),E=d(t.onLiteralValue),k=f(t.onSeparator),O=s(t.onComment),x=f(t.onError),w=n&&n.disallowComments,b=n&&n.allowTrailingComma;function N(){for(;;){const e1=i.scan();switch(i.getTokenError()){case 4:B(14);break;case 5:B(15);break;case 3:B(13);break;case 1:w||B(11);break;case 2:B(12);break;case 6:B(16);break}switch(e1){case 12:case 13:w?B(10):O();break;case 16:B(1);break;case 15:case 14:break;default:return e1}}}function B(e1,X=[],o1=[]){if(x(e1),X.length+o1.length>0){let n1=i.getToken();for(;n1!==17;){if(X.indexOf(n1)!==-1){N();break}else if(o1.indexOf(n1)!==-1)break;n1=N()}}}function R(e1){const X=i.getTokenValue();return e1?E(X):(m(X),r.push(X)),N(),!0}function j(){switch(i.getToken()){case 11:const e1=i.getTokenValue();let X=Number(e1);isNaN(X)&&(B(2),X=0),E(X);break;case 7:E(null);break;case 8:E(!0);break;case 9:E(!1);break;default:return!1}return N(),!0}function $(){return i.getToken()!==10?(B(3,[],[2,5]),!1):(R(!1),i.getToken()===6?(k(":"),N(),Q()||B(4,[],[2,5])):B(5,[],[2,5]),r.pop(),!0)}function K(){p(),N();let e1=!1;for(;i.getToken()!==2&&i.getToken()!==17;){if(i.getToken()===5){if(e1||B(4,[],[]),k(","),N(),i.getToken()===2&&b)break}else e1&&B(6,[],[]);$()||B(4,[],[2,5]),e1=!0}return h(),i.getToken()!==2?B(7,[2],[]):N(),!0}function H(){_(),N();let e1=!0,X=!1;for(;i.getToken()!==4&&i.getToken()!==17;){if(i.getToken()===5){if(X||B(4,[],[]),k(","),N(),i.getToken()===4&&b)break}else X&&B(6,[],[]);e1?(r.push(0),e1=!1):r[r.length-1]++,Q()||B(4,[],[4,5]),X=!0}return S(),e1||r.pop(),i.getToken()!==4?B(8,[4],[]):N(),!0}function Q(){switch(i.getToken()){case 3:return H();case 1:return K();case 10:return R(!0);default:return j()}}return N(),i.getToken()===17?n.allowEmptyContent?!0:(B(4,[],[]),!1):Q()?(i.getToken()!==17&&B(9,[],[]),!0):(B(4,[],[]),!1)}var f_;(function(e){e[e.None=0]="None",e[e.UnexpectedEndOfComment=1]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=2]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=3]="UnexpectedEndOfNumber",e[e.InvalidUnicode=4]="InvalidUnicode",e[e.InvalidEscapeCharacter=5]="InvalidEscapeCharacter",e[e.InvalidCharacter=6]="InvalidCharacter"})(f_||(f_={}));var d_;(function(e){e[e.OpenBraceToken=1]="OpenBraceToken",e[e.CloseBraceToken=2]="CloseBraceToken",e[e.OpenBracketToken=3]="OpenBracketToken",e[e.CloseBracketToken=4]="CloseBracketToken",e[e.CommaToken=5]="CommaToken",e[e.ColonToken=6]="ColonToken",e[e.NullKeyword=7]="NullKeyword",e[e.TrueKeyword=8]="TrueKeyword",e[e.FalseKeyword=9]="FalseKeyword",e[e.StringLiteral=10]="StringLiteral",e[e.NumericLiteral=11]="NumericLiteral",e[e.LineCommentTrivia=12]="LineCommentTrivia",e[e.BlockCommentTrivia=13]="BlockCommentTrivia",e[e.LineBreakTrivia=14]="LineBreakTrivia",e[e.Trivia=15]="Trivia",e[e.Unknown=16]="Unknown",e[e.EOF=17]="EOF"})(d_||(d_={}));const Ae1=Ee1;var h_;(function(e){e[e.InvalidSymbol=1]="InvalidSymbol",e[e.InvalidNumberFormat=2]="InvalidNumberFormat",e[e.PropertyNameExpected=3]="PropertyNameExpected",e[e.ValueExpected=4]="ValueExpected",e[e.ColonExpected=5]="ColonExpected",e[e.CommaExpected=6]="CommaExpected",e[e.CloseBraceExpected=7]="CloseBraceExpected",e[e.CloseBracketExpected=8]="CloseBracketExpected",e[e.EndOfFileExpected=9]="EndOfFileExpected",e[e.InvalidCommentToken=10]="InvalidCommentToken",e[e.UnexpectedEndOfComment=11]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=12]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=13]="UnexpectedEndOfNumber",e[e.InvalidUnicode=14]="InvalidUnicode",e[e.InvalidEscapeCharacter=15]="InvalidEscapeCharacter",e[e.InvalidCharacter=16]="InvalidCharacter"})(h_||(h_={}));function tM(e){var t,n,i="";if(typeof e=="string"||typeof e=="number")i+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t{const[t,n]=G.useState(),[i,r]=G.useState(!1),[s,u]=G.useState(j4.isLoggedIn()),[f,d]=G.useState();G.useEffect(()=>{s&&j4.getUser("me").then(d).catch(n)},[s]);const p=G.useCallback(async()=>{try{r(!0),await j4.login({clientId:window.location.hostname==="127.0.0.1"?"oPbyNuXQIEh8ZI3zbjVWVmVyIaNB2guU6uLP2gQ3sfs":"ZkRBVnOoBeMgwSajgG7E2bhgP5bR61knGYxsh9KKaHc",mode:"popup",redirectUrl:window.location.hostname==="127.0.0.1"?"http://127.0.0.1:3000/land.html":"https://osm-nz.github.io/land.html",scopes:["read_prefs","write_api","write_notes"]}),u(!0),r(!1),n(void 0)}catch(_){n(_),r(!1)}},[]),m=G.useCallback(()=>{j4.logout(),u(!1),d(void 0),n(void 0)},[]),h=G.useMemo(()=>({user:f,logout:m}),[f,m]);return t?F.jsxs(F.Fragment,{children:["Failed to login!",F.jsx("br",{}),`${t}`,F.jsx("br",{}),F.jsx("button",{type:"button",onClick:p,children:"Try Again"}),F.jsx("button",{type:"button",onClick:m,children:"Logout"})]}):i?F.jsx(F.Fragment,{children:"Login in progress... (use the popup window)"}):s?f?F.jsx(ds.Provider,{value:h,children:e}):F.jsx(F.Fragment,{children:"Loading..."}):F.jsxs(F.Fragment,{children:["You need to login to use this feature",F.jsx("br",{}),F.jsx("button",{type:"button",onClick:p,children:"Login"})]})},h8={shadowUrl:"https://cdnjs.cloudflare.com/ajax/libs/leaflet/0.7.7/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],shadowSize:[41,41]},ke1={red:new _4.Icon({iconUrl:"https://raw.githubusercontent.com/pointhi/leaflet-color-markers/master/img/marker-icon-2x-red.png",...h8}),gold:new _4.Icon({iconUrl:"https://raw.githubusercontent.com/pointhi/leaflet-color-markers/master/img/marker-icon-2x-gold.png",...h8}),green:new _4.Icon({iconUrl:"https://raw.githubusercontent.com/pointhi/leaflet-color-markers/master/img/marker-icon-2x-green.png",...h8}),violet:new _4.Icon({iconUrl:"https://raw.githubusercontent.com/pointhi/leaflet-color-markers/master/img/marker-icon-2x-violet.png",...h8})};function rM(e,t){switch(e.type){case"node":return[e];case"way":return e.nodes.map(n=>t==null?void 0:t[`n${n}`]).filter(X11);case"relation":return e.members.flatMap(({type:n,ref:i})=>{const r=t==null?void 0:t[`${n[0]}${i}`];return r?rM(r,t):[]});default:return[]}}const oM=()=>({minLat:1/0,minLng:1/0,maxLat:-1/0,maxLng:-1/0});function Te1(e,t,n){const i=n||oM(),r=Object.values(e).flat().flatMap(s=>rM(s,t));for(const s of r)s.lati.maxLat&&(i.maxLat=s.lat),s.lon>i.maxLng&&(i.maxLng=s.lon);return i}function Pe1(e){const t=[];for(const i of e.features)if("coordinates"in i.geometry){const r=i.geometry.coordinates.flat(3);t.push(...r)}const n=oM();for(let i=0;in.maxLat&&(n.maxLat=r)}else{const r=t[i];rn.maxLng&&(n.maxLng=r)}return n}const Ce1={delete:"red",move:"violet",edit:"gold","":"green"},Ne1=({diff:e,osmPatch:t,fetchCache:n,bboxFromOsmPatch:i,setFocusedFeature:r})=>{const s=G.useRef(null),u=G.useMemo(()=>Te1(e,n,i),[e,n,i]);return Object.values(u).some(f=>!Number.isFinite(f))?F.jsx(F.Fragment,{children:"No preview available"}):F.jsxs(qE,{style:{width:500,height:500,margin:"auto"},scrollWheelZoom:!0,bounds:new _4.LatLngBounds({lat:u.minLat,lng:u.minLng},{lat:u.maxLat,lng:u.maxLng}),children:[F.jsx(KE,{}),F.jsx(e_,{ref:s,children:F.jsx(VE,{positions:[[u.maxLat,u.minLng],[u.maxLat,u.maxLng],[u.minLat,u.maxLng],[u.minLat,u.minLng]]})}),t&&F.jsx(e_,{children:t.features.map(f=>{const d=Ce1[f.properties.__action||""];if(f.geometry.type==="Point"){const[p,m]=f.geometry.coordinates;return F.jsx(q11,{position:{lat:m,lng:p},icon:ke1[d],eventHandlers:{click:()=>r(f)}},f.id)}return F.jsx(W11,{data:f,pathOptions:{color:d},eventHandlers:{click:()=>r(f)}},f.id)})})]})};function*Oe1(e,t){for(let n=0;n!(t!=null&&t[s[0]+f]));for(const f of Oe1(u,100)){console.log(`Fetching ${f.length} ${s}s...`);const d=await j4.getFeatures(s,f);for(const p of d){const m=p.type[0]+p.id;n[m]=p}}}return{...t,...n}}function Le1(e,t){const n=window.URL.createObjectURL(e),i=document.createElement("a");i.href=n,i.download=t,document.body.append(i),i.click(),window.URL.revokeObjectURL(n),setTimeout(()=>i.remove(),0)}const Fe1="_added_fvc69_9",Ie1="_removed_fvc69_12",Re1="_deleted_fvc69_15",Ue1="_changedOld_fvc69_18",$e1="_changedNew_fvc69_21",Be1="_uploadRoot_fvc69_25",ze1="_tagChanges_fvc69_30",je1="_alert_fvc69_35",De1="_error_fvc69_45",Qe1="_diffTable_fvc69_50",nt={added:Fe1,removed:Ie1,deleted:Re1,changedOld:Ue1,changedNew:$e1,uploadRoot:Be1,tagChanges:ze1,alert:je1,error:De1,diffTable:Qe1},I8="→";async function We1(e,t){var s,u,f,d,p,m,h,_,S,E;const n={added:{},removed:{},featureDeleted:{},changed:{}};for(const k of e.create)if(k.tags)for(const O in k.tags){const x=k.tags[O];(s=n.added)[O]||(s[O]={}),(u=n.added[O])[x]||(u[x]=0),n.added[O][x]+=1}for(const k of e.delete)if(k.tags)for(const O in k.tags){const x=k.tags[O];(f=n.featureDeleted)[O]||(f[O]={}),(d=n.featureDeleted[O])[x]||(d[x]=0),n.featureDeleted[O][x]+=1}const i=e.modify.reduce((k,O)=>({...k,[O.type]:[...k[O.type],O.id]}),{node:[],way:[],relation:[]}),r=await Rd(i,t);for(const k of e.modify){const O=r[k.type[0]+k.id].tags||{},x=k.tags||{},w=Object.keys({...O,...x});for(const b of w)if(x[b]&&!O[b]){const N=x[b];(p=n.added)[b]||(p[b]={}),(m=n.added[b])[N]||(m[N]=0),n.added[b][N]+=1}else if(!x[b]&&O[b]){const N=O[b];(h=n.removed)[b]||(h[b]={}),(_=n.removed[b])[N]||(_[N]=0),n.removed[b][N]+=1}else if(x[b]!==O[b]){const N=`${O[b]} ${I8} ${x[b]}`;(S=n.changed)[b]||(S[b]={}),(E=n.changed[b])[N]||(E[N]=0),n.changed[b][N]+=1}}return n}const Ou=({value:e,className:t})=>{if(e.includes(I8)){const[n,i]=e.split(I8);return F.jsxs("span",{children:[F.jsx("code",{className:nt.changedOld,children:n.trim()})," ",I8," ",F.jsx("code",{className:nt.changedNew,children:i.trim()})]})}return F.jsx("code",{className:t,children:e})},p8=(e,t,n)=>Object.entries(e).map(([i,r])=>{const s=Object.entries(r);let u,f;return s.length>1?s.every(([,p])=>p===1)?(f=s.map(([p],m)=>F.jsxs(G.Fragment,{children:[!!m&&"/",F.jsx(Ou,{value:p,className:t})]},p)),u=` (${s.length})`):(f=F.jsx("ul",{children:s.map(([p,m])=>F.jsxs("li",{children:[F.jsx(Ou,{value:p,className:t}),m>1&&`(${m})`]},p))}),u=""):(f=F.jsx(Ou,{value:s[0][0],className:t}),u=` (${s[0][1]})`),F.jsxs("li",{children:[n,u," ",F.jsxs("code",{className:t,children:[i,"="]}),f]},t+i)}),He1=({diff:e,fetchCache:t})=>{const[n,i]=G.useState(),[r,s]=G.useState();return G.useEffect(()=>{We1(e,t).then(s).catch(i)},[e,t]),n?F.jsx(F.Fragment,{children:"Failed to calculate tag changes"}):r?Object.values(r).every(f=>!Object.keys(f).length)?F.jsx("div",{className:nM(nt.alert,nt.error),children:"No tags changed!"}):F.jsxs("ul",{className:nt.tagChanges,children:[p8(r.added,nt.added,"Added"),p8(r.changed,nt.changedOld,"Changed"),p8(r.removed,nt.removed,"Removed"),p8(r.featureDeleted,nt.deleted,"Deleted")]}):F.jsx(F.Fragment,{children:"Loading tag changes..."})},Ze1=({diff:e})=>F.jsxs("div",{style:{padding:4,color:"#fff"},children:[F.jsxs("span",{style:{background:"#4caf50",padding:4},children:["+",e.create.length]}),F.jsx("span",{style:{background:"#ff9800",padding:4},children:e.modify.length}),F.jsxs("span",{style:{background:"#f44336",padding:4},children:["-",e.delete.length]})]}),I7={n:"node",w:"way",r:"relation"};window.structuredClone||(window.structuredClone=e=>JSON.parse(JSON.stringify(e)));const Ud={changeset:-1,timestamp:"",uid:-1,user:"",version:0},Ge1={source_ref:{"http://www.nzopengps.org/":!0,"http://www.linz.govt.nz/topography/topo-maps/":!0,"http://www.linz.govt.nz/topography/topo-maps/index.aspx":!0,"http://www.linz.govt.nz/about-linz/linz-data-service/dataset-information":!0},attribution:{"http://wiki.osm.org/wiki/Attribution#LINZ":!0,"http://wiki.openstreetmap.org/wiki/Attribution#LINZ":!0,"http://www.aucklandcouncil.govt.nz/EN/ratesbuildingproperty/propertyinformation/GIS_maps/Pages/opendata.aspx":!0},"linz2osm:objectid":!0,"LINZ2OSM:dataset":!0,"LINZ2OSM:layer":!0,"LINZ:layer":!0,"LINZ2OSM:source_version":!0,"LINZ:source_version":!0,"LINZ:dataset":!0,"brand:wikipedia":!0,"operator:wikipedia":!0,"network:wikipedia":!0},Wn={node:-1,way:-1,relation:-1},Lu=e=>({...Ud,type:"node",id:Wn.node--,lat:e[1],lon:e[0]});function qe1(e,t,n){switch(e.type){case"Point":return[{...t,type:"node",id:Wn.node--,lat:e.coordinates[1],lon:e.coordinates[0]}];case"MultiPoint":{const i=e.coordinates.map(Lu);return[{...t,tags:{...t.tags,type:"site"},type:"relation",id:Wn.relation--,members:i.map(r=>({role:"",type:r.type,ref:r.id}))},...i]}case"LineString":{const i=e.coordinates.map(Lu);return[{...t,type:"way",id:Wn.way--,nodes:i.map(r=>r.id)},...i]}case"MultiLineString":{const i=[],r=[];for(const u of e.coordinates){const f=u.map(Lu);i.push({...Ud,type:"way",id:Wn.way--,nodes:f.map(d=>d.id)}),r.push(...f)}return[{...t,tags:{...t.tags,type:"multilinestring"},type:"relation",id:Wn.relation--,members:i.map(u=>({role:"",type:u.type,ref:u.id}))},...i,...r]}case"GeometryCollection":return[{...t,type:"relation",id:Wn.relation--,members:n}];case"Polygon":case"MultiPolygon":return;default:return}}function p_(e,t){const n=structuredClone(e);n.tags||(n.tags={});for(const[r,s]of Object.entries(t))s==="🗑️"?delete n.tags[r]:n.tags[r]=s;const i=Object.keys(n.tags).some(r=>r.startsWith("ref:linz:"));for(const[r,s]of Object.entries(n.tags)){const u=Ge1[r];(u===!0||u!=null&&u[s])&&(delete n.tags[r],r==="source_ref"&&!n.tags.source&&!i&&!n.tags.building&&(n.tags.source="LINZ"))}return n}function Ve1(e,t){let n=structuredClone(e.members);for(const i of t){const r=n.findIndex(s=>s.type===i.type&&s.ref===i.ref);n=n.filter(s=>!(s.type===i.type&&s.ref===i.ref)),i.role==="🗑️"||(r===-1?n.push(i):n.splice(r,0,i))}return n}async function Ye1(e){const t={create:[],delete:[],modify:[]},n={node:[],way:[],relation:[]};for(const s of e.features)if(s.properties.__action){const u=I7[s.id[0]],f=+s.id.slice(1);n[u].push(f)}const i=await Rd(n);for(const s of e.features){const{__action:u,__members:f,...d}=s.properties;switch(u){case"edit":{const p=p_(i[s.id],d);p.type==="relation"&&f&&(p.members=Ve1(p,f)),t.modify.push(p);break}case"move":{const p=p_(i[s.id],d);if(p.type!=="node"||s.geometry.type!=="LineString")throw new Error("trying to move a non-node");const[m,h]=s.geometry.coordinates[1];p.lat=h,p.lon=m,t.modify.push(p);break}case"delete":{t.delete.push(i[s.id]);break}default:{const p=qe1(s.geometry,{...Ud,tags:d},f);p?t.create.push(...p):console.warn(`Can't create a ${s.geometry.type}`)}}}const r=Pe1(e);return{osmChange:t,fetched:i,bbox:r}}function cn(){}cn.prototype={diff:function(t,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=i.callback;typeof i=="function"&&(r=i,i={}),this.options=i;var s=this;function u(k){return r?(setTimeout(function(){r(void 0,k)},0),!0):k}t=this.castInput(t),n=this.castInput(n),t=this.removeEmpty(this.tokenize(t)),n=this.removeEmpty(this.tokenize(n));var f=n.length,d=t.length,p=1,m=f+d;i.maxEditLength&&(m=Math.min(m,i.maxEditLength));var h=[{newPos:-1,components:[]}],_=this.extractCommon(h[0],n,t,0);if(h[0].newPos+1>=f&&_+1>=d)return u([{value:this.join(n),count:n.length}]);function S(){for(var k=-1*p;k<=p;k+=2){var O=void 0,x=h[k-1],w=h[k+1],b=(w?w.newPos:0)-k;x&&(h[k-1]=void 0);var N=x&&x.newPos+1=f&&b+1>=d)return u(Xe1(s,O.components,n,t,s.useLongestToken));h[k]=O}p++}if(r)(function k(){setTimeout(function(){if(p>m)return r();S()||k()},0)})();else for(;p<=m;){var E=S();if(E)return E}},pushComponent:function(t,n,i){var r=t[t.length-1];r&&r.added===n&&r.removed===i?t[t.length-1]={count:r.count+1,added:n,removed:i}:t.push({count:1,added:n,removed:i})},extractCommon:function(t,n,i,r){for(var s=n.length,u=i.length,f=t.newPos,d=f-r,p=0;f+1S.length?k:S}),p.value=e.join(m)}else p.value=e.join(n.slice(f,f+p.count));f+=p.count,p.added||(d+=p.count)}}var _=t[u-1];return u>1&&typeof _.value=="string"&&(_.added||_.removed)&&e.equals("",_.value)&&(t[u-2].value+=_.value,t.pop()),t}function Ke1(e){return{newPos:e.newPos,components:e.components.slice(0)}}var g_=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,m_=/\S/,sM=new cn;sM.equals=function(e,t){return this.options.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e===t||this.options.ignoreWhitespace&&!m_.test(e)&&!m_.test(t)};sM.tokenize=function(e){for(var t=e.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),n=0;n"u"?n:u}:i;return typeof e=="string"?e:JSON.stringify(xc(e,null,null,r),r," ")};g9.equals=function(e,t){return cn.prototype.equals.call(g9,e.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"))};function xc(e,t,n,i,r){t=t||[],n=n||[],i&&(e=i(r,e));var s;for(s=0;se.role?`${e.type[0]}${e.ref} as “${e.role}”`:`${e.type[0]}${e.ref}`;async function it1(e,t){var s,u;const n=e.modify.reduce((f,d)=>({...f,[d.type]:[...f[d.type],d.id]}),{node:[],way:[],relation:[]}),i=await Rd(n,t),r={};for(const f of[...e.modify,...e.create]){const d=f.type[0]+f.id,p=i[d];if(f.type==="relation"&&((s=f.tags)==null?void 0:s.type)!=="multipolygon"){const m=((u=p==null?void 0:p.members)==null?void 0:u.map(y_).join(` +`))||"",h=f.members.map(y_).join(` +`);r[d]=Je1(`${m} +`,`${h} +`)}}return r}const rt1=({diff:e,fetchCache:t})=>{var p;const[n,i]=G.useState(),[r,s]=G.useState(0);G.useEffect(()=>{it1(e,t).catch(()=>{}).then(i)},[e,t]);const u=Object.keys(n||{});if(n&&u.length===0)return null;const f=u[r],d=((p=t==null?void 0:t[f])==null?void 0:p.tags)||{};return F.jsxs(F.Fragment,{children:[F.jsx("br",{}),F.jsx("br",{}),F.jsx("strong",{children:"Changed Relation Members:"}),F.jsx("br",{}),n?F.jsxs(F.Fragment,{children:[F.jsx("button",{type:"button",onClick:()=>s(m=>m-1),disabled:!r,children:"⬅️"}),r+1,"/",u.length,F.jsx("button",{type:"button",onClick:()=>s(m=>m+1),disabled:r===u.length-1,children:"➡️"}),F.jsx("br",{}),F.jsx("strong",{children:d.name||d.ref||"No Name"}),F.jsx("br",{}),F.jsx("pre",{children:n[f].map((m,h)=>{const _=h+m.value;return m.added?F.jsx("span",{className:"diff-add",children:m.value},_):m.removed?F.jsx("span",{className:"diff-remove",children:m.value},_):m.value})})]}):"Loading…"]})},ot1=({type:e,id:t})=>F.jsxs("span",{children:[F.jsx("a",{href:`https://osm.org/${e}/${t}`,target:"_blank",rel:"noreferrer",children:"OSM"})," ","|"," ",F.jsx("a",{href:`https://osm.org/edit?${e}=${t}`,target:"_blank",rel:"noreferrer",children:"iD"})," ","|"," ",F.jsx("a",{href:`https://osmlab.github.io/osm-deep-history/#/${e}/${t}`,target:"_blank",rel:"noreferrer",children:"Deep History"})," ","|"," ",F.jsx("a",{href:`https://pewu.github.io/osm-history/#/${e}/${t}`,target:"_blank",rel:"noreferrer",children:"PeWu"})," "]}),g8=F.jsx("td",{children:" "}),st1=({feature:e,original:t})=>{const{user:n}=G.useContext(ds),i=I7[`${e.id}`[0]],r=+`${e.id}`.slice(1),s=G.useMemo(()=>{const{__action:u,__members:f,...d}=e.properties;return[...new Set([...Object.keys((t==null?void 0:t.tags)||{}),...Object.keys(d)])].sort((m,h)=>m.localeCompare(h))},[e,t]);return F.jsxs(F.Fragment,{children:[F.jsxs("header",{style:{textTransform:"capitalize"},children:[i," ",r," – ",F.jsx(ot1,{type:i,id:r})]}),F.jsxs("table",{className:nt.diffTable,children:[F.jsx("thead",{children:F.jsxs("tr",{children:[F.jsx("th",{}),F.jsx("th",{children:"Before"}),F.jsx("th",{children:"After"})]})}),F.jsxs("tbody",{children:[F.jsxs("tr",{children:[F.jsx("td",{children:"version"}),F.jsx("td",{children:(t==null?void 0:t.version)||""}),F.jsx("td",{children:((t==null?void 0:t.version)??0)+1})]}),F.jsxs("tr",{children:[F.jsx("td",{children:"timestamp"}),t?F.jsx("td",{children:F.jsx("abbr",{title:(t==null?void 0:t.timestamp)||"",children:F.jsx(vf,{date:t==null?void 0:t.timestamp})})}):g8,F.jsx("td",{children:F.jsx("em",{children:"Now"})})]}),F.jsxs("tr",{children:[F.jsx("td",{children:"changeset"}),t?F.jsx("td",{children:F.jsx("a",{href:`https://osm.org/changeset/${t.changeset}`,target:"_blank",rel:"noreferrer",children:t.changeset})}):g8,g8]}),F.jsxs("tr",{children:[F.jsx("td",{children:"user"}),t?F.jsx("td",{children:F.jsx("a",{href:`https://osm.org/user/${t.user}`,target:"_blank",rel:"noreferrer",children:t.user})}):g8,F.jsx("td",{children:F.jsx("a",{href:`https://osm.org/user/${n.display_name}`,target:"_blank",rel:"noreferrer",children:n.display_name})})]}),F.jsx("tr",{children:F.jsx("th",{colSpan:3,children:"Tags"})}),s.map(u=>{var m;const f=((m=t==null?void 0:t.tags)==null?void 0:m[u])||"";let d=e.properties.__action==="delete"?"":e.properties[u]||f;if(d==="🗑️"&&(d=""),!f&&!d)return null;const p=f?d?f===d?"":nt.changedNew:nt.removed:nt.added;return F.jsxs("tr",{children:[F.jsx("td",{children:u}),F.jsx("td",{className:p===nt.changedNew?nt.changedOld:"",children:f}),F.jsx("td",{className:p,children:d})]},u)})]})]}),i==="relation"&&F.jsx(F.Fragment,{children:F.jsx("header",{children:"Members"})})]})},__={attribution:"https://wiki.openstreetmap.org/wiki/Contributors#LINZ",created_by:"LINZ Data Import 2.0.0",locale:navigator.language,source:"https://wiki.osm.org/LINZ",comment:""};function v_(e){try{return Object.fromEntries(e.split(` +`).map(t=>{if(!t)return[];const[n,i]=t.split("=");return[n.trim(),i]}).filter(([t,n])=>t&&n))}catch{return}}const m8=e=>Object.entries(e).map(t=>t.join("=")).join(` +`),at1=()=>{const{user:e,logout:t}=G.useContext(ds),[n,i]=G.useState(!1),[r,s]=G.useState(),[u,f]=G.useState(),[d,p]=G.useState(m8(__)),[m,h]=G.useState(),[_,S]=G.useState(),[E,k]=G.useState(),[O,x]=G.useState([]),[w,b]=G.useState(),[N,B]=G.useState(),[R,j]=G.useState(),$=G.useRef(null),K=v_(d);async function H(X){if(!(X!=null&&X.length))return x([]),h(void 0);try{if(k(X[0].name),[...X].some(k1=>k1.name.endsWith(".osc"))){if(X.length>1)throw new Error("Only 1 osmChange file can be uploaded at a time. Multiple osmPatch files are allowed");const k1=await X[0].text(),U1=j4.parseOsmChangeXml(k1);return h(U1)}const n1=[];for(const k1 of X)n1.push(Ae1(await k1.text()));const l1=n1.length===1?n1[0]:{...n1[0],features:n1.flatMap(k1=>k1.features)},r1={};for(const k1 of n1)if(k1.changesetTags)for(const[U1,O1]of Object.entries(k1.changesetTags))if(r1[U1]){const v1=new Set(r1[U1].split(";"));v1.add(O1),r1[U1]=[...v1].join(";")}else r1[U1]=O1;Object.keys(r1).length&&(r1.created_by||(r1.created_by=__.created_by),p(m8(r1)));const Y=new Set(n1.map(k1=>k1.instructions||""));Y.delete(""),x([...Y]);const{osmChange:g1,fetched:f1,bbox:w1}=await Ye1(l1);return S(f1),B(w1),b(l1),h(g1)}catch(o1){return console.error(o1),s(o1 instanceof Error?o1:new Error(`${o1}`))}}async function Q(){f(void 0),s(void 0),i(!0);try{f(await j4.uploadChangeset(K,m)),h(void 0),console.log("Uploaded!")}catch(X){console.error(X),s(X instanceof Error?X:new Error(`${X}`))}i(!1)}function e1(){const X=j4.createOsmChangeXml(-1,m),o1=new Blob([X],{type:"application/xml"});Le1(o1,`${E==null?void 0:E.split(".")[0]}.osc`)}return n?F.jsx("h2",{className:nt.uploadRoot,children:"Uploading..."}):F.jsxs("div",{className:nt.uploadRoot,children:[r&&F.jsx("div",{className:nM(nt.alert,nt.error),children:r.message}),u&&F.jsxs("div",{className:nt.alert,children:["Uploaded!"," ",F.jsx("a",{href:`https://osm.org/changeset/${u}`,target:"_blank",rel:"noreferrer",children:u})]}),(r||u)&&F.jsxs(F.Fragment,{children:[F.jsx("br",{}),F.jsx("br",{})]}),"Logged in as ",F.jsx("code",{children:e.display_name}),"."," ",F.jsx("button",{type:"button",onClick:t,children:"Logout"}),F.jsx("br",{}),F.jsx("br",{}),F.jsx("strong",{children:"Upload osmChange or osmPatch file:"}),F.jsx("br",{}),F.jsx("input",{type:"file",accept:".osc,.osmPatch.geo.json",multiple:!0,onChange:X=>H(X.target.files),ref:$}),m&&F.jsx("button",{type:"button",onClick:()=>{$.current.value="",h(void 0)},children:"Clear"}),F.jsx("br",{}),F.jsx("br",{}),F.jsx("strong",{children:"Changeset Tags:"}),F.jsx("br",{}),F.jsx("input",{value:(K==null?void 0:K.comment)||"",onChange:X=>{p(m8({...K,comment:X.target.value}))},placeholder:"Changeset Comment",style:{width:500}}),F.jsx("br",{}),F.jsx("textarea",{value:d,onChange:X=>p(X.target.value),onBlur:X=>{const o1=v_(X.target.value);o1&&p(m8(o1))},style:{width:500,height:200,color:K?"black":"red"}}),F.jsx("br",{}),F.jsx("br",{}),m?F.jsxs(F.Fragment,{children:[F.jsx(Ze1,{diff:m}),F.jsx("br",{}),F.jsxs("div",{style:{display:"flex",gap:16},children:[F.jsx("div",{children:F.jsx(Ne1,{diff:m,fetchCache:_,osmPatch:w,bboxFromOsmPatch:N,setFocusedFeature:j})}),F.jsx("div",{children:R?F.jsx(st1,{feature:R,original:_==null?void 0:_[`${R.id}`]}):F.jsx("em",{children:"Select a feature to view more details"})})]}),F.jsx("br",{}),F.jsx("br",{}),F.jsx("strong",{children:"All Tag Changes:"}),F.jsx("br",{}),F.jsx(He1,{diff:m,fetchCache:_}),F.jsx(rt1,{diff:m,fetchCache:_}),F.jsx("br",{}),F.jsx("br",{}),!!O.length&&F.jsxs(F.Fragment,{children:[O.map(X=>F.jsxs("div",{children:["⚠️ ",X]},X)),F.jsx("br",{}),F.jsx("br",{})]}),F.jsx("button",{type:"button",onClick:Q,disabled:!(K!=null&&K.comment),style:{fontSize:32},children:"Upload"}),F.jsx("button",{type:"button",onClick:e1,style:{fontSize:32},children:"Download as .osc"}),F.jsx("br",{}),"“",(K==null?void 0:K.comment)||"(no comment)","” as"," ",F.jsx("code",{children:e.display_name})]}):F.jsxs(F.Fragment,{children:["Upload an ",F.jsx("code",{children:".osc"})," or ",F.jsx("code",{children:".osmPatch.geo.json"})," file to see the remaining options"]})]})},ut1=()=>F.jsx(iM,{children:F.jsx(at1,{})}),lt1=()=>F.jsx(F.Fragment,{children:"Hello!"}),ct1=window.location.origin+window.location.pathname+window.location.hash;async function ft1(e){return j4.uploadChangeset({comment:"Restore deleted features",created_by:"HistoryRestorer",host:ct1},{create:[],modify:e.map(t=>({...t.newFeature,id:t.oldId,version:t.oldVersion})),delete:e.map(t=>t.newFeature)})}const dt1=fetch("https://cdn.jsdelivr.net/gh/openstreetmap/id-tagging-schema@main/dist/presets.min.json").then(e=>e.json()),ht1=fetch("https://cdn.jsdelivr.net/gh/openstreetmap/id-tagging-schema@main/dist/translations/en.min.json").then(e=>e.json());async function w_(e){var s,u;if(!e)return"No Tags";const[t,n]=[await dt1,await ht1],i=[];for(const f in t){const{matchScore:d,tags:p}=t[f];!!Object.keys(p).length&&Object.entries(p).every(([h,_])=>h in e&&(_==="*"||_===e[h]))&&i.push({presetId:f,matchScore:(d??1)+Object.values(p).filter(h=>h!=="*").length/10})}i.sort((f,d)=>d.matchScore-f.matchScore);const r=(s=i[0])==null?void 0:s.presetId;return((u=n.en.presets.presets[r])==null?void 0:u.name)||"Unknown"}const x_=e=>(e==null?void 0:e.name)||(e==null?void 0:e.ref)||(e==null?void 0:e.official_name)||(e==null?void 0:e.alt_name)||(e==null?void 0:e.loc_name)||(e==null?void 0:e["addr:housename"])||(e==null?void 0:e["seamark:name"]);async function pt1(e){if(!e.length)throw new Error("No data entered");if(e.some(r=>!r.fromId||!r.toId))throw new Error("Some fields are blank");const t={node:e.filter(r=>r.type==="n").map(r=>r.toId),way:e.filter(r=>r.type==="w").map(r=>r.toId),relation:e.filter(r=>r.type==="r").map(r=>r.toId)};for(const r of e){const s=I7[r.type],u=await j4.getFeatureHistory(s,r.fromId),f=u.at(-1),d=u.at(-2);if(f.visible!==!1)throw new Error(`${s} ${r.fromId} is not deleted`);t[s].push(`${r.fromId}v${d.version}`)}const n=[];for(const r in t){const s=t[r];s.length&&n.push(...await j4.getFeatures(r,s))}const i={};return Promise.all(e.map(async r=>{let s=!1;i[r.type+r.fromId]&&(s="Duplicate deleted feature"),i[r.type+r.toId]&&(s="Duplicate new feature");const u=n.find(d=>d.type===I7[r.type]&&d.id===r.fromId);u||(s="Invalid old feature");const f=n.find(d=>d.type===I7[r.type]&&d.id===r.toId);return f||(s="Invalid new feature"),{oldPreset:await w_(u==null?void 0:u.tags),oldName:x_(u==null?void 0:u.tags),newPreset:await w_(f==null?void 0:f.tags),newName:x_(f==null?void 0:f.tags),newFeature:f,oldId:u==null?void 0:u.id,oldVersion:((u==null?void 0:u.version)??-2)+1,error:s}}))}const gt1="_main_gt6g9_1",mt1="_list_gt6g9_7",yt1="_item_gt6g9_11",_t1="_error_gt6g9_21",vt1="_btn_gt6g9_25",wt1="_smallInput_gt6g9_34",xt1="_saveBtn_gt6g9_41",Dt={main:gt1,list:mt1,item:yt1,error:_t1,btn:vt1,smallInput:wt1,saveBtn:xt1},Fu=()=>({type:"n"}),b_=({value:e,onChange:t})=>F.jsxs("select",{className:Dt.smallInput,value:e,onChange:n=>t(n.target.value),children:[F.jsx("option",{value:"n",children:"Node"}),F.jsx("option",{value:"w",children:"Way"}),F.jsx("option",{value:"r",children:"Relation"})]}),bt1=()=>{const{user:e,logout:t}=G.useContext(ds),[n,i]=G.useState([Fu()]),[r,s]=G.useState(0),[u,f]=G.useState(),[d,p]=G.useState(!1),[m,h]=G.useState();function _(E,k,O){i(x=>x.map((w,b)=>E===b?{...w,[k]:O}:w)),f(void 0)}async function S(){p(!0);try{u?h(await ft1(u)):f(await pt1(n))}catch(E){console.error(E),alert(`${E}`)}p(!1)}return m?F.jsxs("div",{className:Dt.main,children:[F.jsx("a",{href:`${j4.getConfig().apiUrl}/changeset/${m}`,target:"_blank",rel:"noopener noreferrer",children:"Done!"}),F.jsx("br",{}),F.jsx("br",{}),F.jsx("button",{type:"button",className:Dt.btn,onClick:()=>{i([Fu()]),f(void 0),h(void 0),s(E=>E+1)},children:"Back"})]}):F.jsxs("div",{className:Dt.main,children:[F.jsx("h2",{children:"Restore OSM History"}),F.jsxs("p",{children:["If an OSM Feature was deleted and redrawn, you can restore the history of the original feature using this tool.",F.jsx("br",{}),F.jsx("br",{}),F.jsx("a",{href:"https://wiki.osm.org/HistoryRestorer",target:"_blank",rel:"noopener noreferrer",children:"Wiki"})," ","|"," ",F.jsx("a",{href:"https://github.com/osm-nz/osm-nz.github.io/tree/main/src/pages/HistoryRestorer",target:"_blank",rel:"noopener noreferrer",children:"Source Code"}),F.jsx("br",{}),F.jsx("br",{})]}),F.jsxs("div",{className:Dt.list,children:[F.jsxs("div",{className:Dt.item,children:[F.jsx("strong",{children:"Deleted Feature"}),F.jsx("strong",{children:"New Feature"})]},0),n.map((E,k)=>{const O=u==null?void 0:u[k];return F.jsxs("div",{className:Dt.item,children:[F.jsxs("div",{children:[F.jsx(b_,{value:E.type,onChange:x=>_(k,"type",x)}),F.jsx("input",{className:Dt.smallInput,type:"tel",value:E.fromId||"",onChange:x=>_(k,"fromId",+x.target.value)}),O&&F.jsxs("small",{children:[F.jsx("br",{}),F.jsx("strong",{children:O.oldPreset}),"   ",O.oldName,O.error&&F.jsxs("span",{className:Dt.error,children:[F.jsx("br",{}),O.error]})]})]}),F.jsx("div",{children:"➡️"}),F.jsxs("div",{children:[F.jsx(b_,{value:E.type,onChange:x=>_(k,"type",x)}),F.jsx("input",{className:Dt.smallInput,type:"tel",value:E.toId||"",onChange:x=>_(k,"toId",+x.target.value)}),O&&F.jsxs("small",{children:[F.jsx("br",{}),F.jsx("strong",{children:O.newPreset}),"   ",O.newName]})]}),F.jsx("div",{children:F.jsx("button",{type:"button",disabled:n.length===1,className:`${Dt.btn} ${Dt.smallInput}`,onClick:()=>{s(x=>x+1),f(void 0),i(x=>{const w=[...x];return w.splice(k,1),w})},children:"🗑️"})})]},r+k)})]}),F.jsx("br",{}),F.jsx("button",{type:"button",className:Dt.btn,onClick:()=>{i(E=>[...E,Fu()]),f(void 0)},children:"Add Another feature"}),F.jsx("br",{}),F.jsx("br",{}),d&&F.jsx(F.Fragment,{children:"Loading..."}),F.jsx("button",{type:"submit",disabled:d,onClick:S,className:`${Dt.btn} ${u?Dt.saveBtn:""}`,children:u?"Save":"Next"}),F.jsx("br",{}),F.jsx("br",{}),"Logged in as ",F.jsx("code",{children:e.display_name}),"."," ",F.jsx("a",{onClick:t,children:"Logout"})]})},St1=()=>F.jsx(iM,{children:F.jsx(bt1,{})});const S_=()=>window.location.hash.slice(1),Et1=()=>{const[e,t]=G.useState(S_());return G.useEffect(()=>{const n=()=>t(S_());return window.addEventListener("popstate",n),()=>window.removeEventListener("popstate",n)},[]),e==="/whatsup"?F.jsx(lt1,{}):e==="/upload"?F.jsx(ut1,{}):e==="/map"?F.jsx(be1,{}):e==="/restore-history"?F.jsx(St1,{}):e==="/address-import"?F.jsx(C11,{}):F.jsx(N11,{})};Uw(document.querySelector("main")).render(F.jsx(G.StrictMode,{children:F.jsx(Et1,{})})); diff --git a/assets/index-36f54e15.css b/assets/index-a024f02c.css similarity index 84% rename from assets/index-36f54e15.css rename to assets/index-a024f02c.css index cb6381f..ed58453 100644 --- a/assets/index-36f54e15.css +++ b/assets/index-a024f02c.css @@ -1 +1 @@ -.leaflet-pane,.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile-container,.leaflet-pane>svg,.leaflet-pane>canvas,.leaflet-zoom-box,.leaflet-image-layer,.leaflet-layer{position:absolute;left:0;top:0}.leaflet-container{overflow:hidden}.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow{-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-tile::selection{background:transparent}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{width:1600px;height:1600px;-webkit-transform-origin:0 0}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-overlay-pane svg{max-width:none!important;max-height:none!important}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer,.leaflet-container .leaflet-tile{max-width:none!important;max-height:none!important;width:auto;padding:0}.leaflet-container img.leaflet-tile{mix-blend-mode:plus-lighter}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:rgba(51,181,229,.4)}.leaflet-tile{filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{width:0;height:0;-moz-box-sizing:border-box;box-sizing:border-box;z-index:800}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{position:relative;z-index:800;pointer-events:visiblePainted;pointer-events:auto}.leaflet-top,.leaflet-bottom{position:absolute;z-index:1000;pointer-events:none}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-popup{opacity:0;-webkit-transition:opacity .2s linear;-moz-transition:opacity .2s linear;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}svg.leaflet-zoom-animated{will-change:transform}.leaflet-zoom-anim .leaflet-zoom-animated{-webkit-transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);-moz-transition:-moz-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1)}.leaflet-zoom-anim .leaflet-tile,.leaflet-pan-anim .leaflet-tile{-webkit-transition:none;-moz-transition:none;transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab;cursor:grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-popup-pane,.leaflet-control{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:grabbing}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-image-layer,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-marker-icon.leaflet-interactive,.leaflet-image-layer.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive,svg.leaflet-image-layer.leaflet-interactive path{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{background:#ddd;outline-offset:1px}.leaflet-container a{color:#0078a8}.leaflet-zoom-box{border:2px dotted #38f;background:rgba(255,255,255,.5)}.leaflet-container{font-family:Helvetica Neue,Arial,Helvetica,sans-serif;font-size:12px;font-size:.75rem;line-height:1.5}.leaflet-bar{box-shadow:0 1px 5px #000000a6;border-radius:4px}.leaflet-bar a{background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;display:block;text-align:center;text-decoration:none;color:#000}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50% 50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover,.leaflet-bar a:focus{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:none}.leaflet-bar a.leaflet-disabled{cursor:default;background-color:#f4f4f4;color:#bbb}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-left-radius:2px;border-bottom-right-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{font:700 18px Lucida Console,Monaco,monospace;text-indent:1px}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{box-shadow:0 1px 5px #0006;background:#fff;border-radius:5px}.leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers .leaflet-control-layers-list,.leaflet-control-layers-expanded .leaflet-control-layers-toggle{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{padding:6px 10px 6px 6px;color:#333;background:#fff}.leaflet-control-layers-scrollbar{overflow-y:scroll;overflow-x:hidden;padding-right:5px}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{display:block;font-size:13px;font-size:1.08333em}.leaflet-control-layers-separator{height:0;border-top:1px solid #ddd;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(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=)}.leaflet-container .leaflet-control-attribution{background:#fff;background:rgba(255,255,255,.8);margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{padding:0 5px;color:#333;line-height:1.4}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover,.leaflet-control-attribution a:focus{text-decoration:underline}.leaflet-attribution-flag{display:inline!important;vertical-align:baseline!important;width:1em;height:.6669em}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{border:2px solid #777;border-top:none;line-height:1.1;padding:2px 5px 1px;white-space:nowrap;-moz-box-sizing:border-box;box-sizing:border-box;background:rgba(255,255,255,.8);text-shadow:1px 1px #fff}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{box-shadow:none}.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{border:2px solid rgba(0,0,0,.2);background-clip:padding-box}.leaflet-popup{position:absolute;text-align:center;margin-bottom:20px}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:12px}.leaflet-popup-content{margin:13px 24px 13px 20px;line-height:1.3;font-size:13px;font-size:1.08333em;min-height:1px}.leaflet-popup-content p{margin:1.3em 0}.leaflet-popup-tip-container{width:40px;height:20px;position:absolute;left:50%;margin-top:-1px;margin-left:-20px;overflow:hidden;pointer-events:none}.leaflet-popup-tip{width:17px;height:17px;padding:1px;margin:-10px auto 0;pointer-events:auto;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:white;color:#333;box-shadow:0 3px 14px #0006}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;border:none;text-align:center;width:24px;height:24px;font:16px/24px Tahoma,Verdana,sans-serif;color:#757575;text-decoration:none;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover,.leaflet-container a.leaflet-popup-close-button:focus{color:#585858}.leaflet-popup-scrolled{overflow:auto}.leaflet-oldie .leaflet-popup-content-wrapper{-ms-zoom:1}.leaflet-oldie .leaflet-popup-tip{width:24px;margin:0 auto;-ms-filter:"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";filter:progid:DXImageTransform.Microsoft.Matrix(M11=.70710678,M12=.70710678,M21=-.70710678,M22=.70710678)}.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{position:absolute;padding:6px;background-color:#fff;border:1px solid #fff;border-radius:3px;color:#222;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;box-shadow:0 1px 3px #0006}.leaflet-tooltip.leaflet-interactive{cursor:pointer;pointer-events:auto}.leaflet-tooltip-top:before,.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{position:absolute;pointer-events:none;border:6px solid transparent;background:transparent;content:""}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{left:50%;margin-left:-6px}.leaflet-tooltip-top:before{bottom:0;margin-bottom:-12px;border-top-color:#fff}.leaflet-tooltip-bottom:before{top:0;margin-top:-12px;margin-left:-6px;border-bottom-color:#fff}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{top:50%;margin-top:-6px}.leaflet-tooltip-left:before{right:0;margin-right:-12px;border-left-color:#fff}.leaflet-tooltip-right:before{left:0;margin-left:-12px;border-right-color:#fff}@media print{.leaflet-control{-webkit-print-color-adjust:exact;print-color-adjust:exact}}.upload-root{margin:32px;text-align:center}.tagChanges{overflow-wrap:break-word;text-align:left}.tagChanges .Added code{color:green}.tagChanges .Changed code{color:orange}.tagChanges .Removed code{color:red}.tagChanges .Deleted code{color:maroon}.alert{background:#ddf4ff;border-color:#54aeff66;border-radius:6px;border-style:solid;border-width:1px;padding:20px;display:inline-block;min-width:400px}.alert.error{background:#ffebe9;border-color:#ff818266}._main_gt6g9_1{max-width:600px;margin:16px auto;text-align:center}._list_gt6g9_7{text-align:center}._item_gt6g9_11{display:flex;justify-content:space-around;background:#f2f2f2;padding:8px;margin:8px;border-radius:4px}._error_gt6g9_21{color:#f36}._btn_gt6g9_25{padding:8px;border:1px solid #999;border-radius:4px}._btn_gt6g9_25:hover{opacity:.8;cursor:pointer}._smallInput_gt6g9_34{padding:4px;border:1px solid #999;border-radius:4px;margin-left:2px}._saveBtn_gt6g9_41{background-color:#f36}*{margin:0;padding:0}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}h1,h2,h3,h4{margin-top:24px}code{font-family:source-code-pro,Menlo,Monaco,Consolas,Courier New,monospace}kbd{margin-left:4px;padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;box-shadow:inset 0 -1px #00000040}table{border-collapse:collapse}table:not(.busy) tr{border-bottom:1px solid #666}table.busy thead tr{border-bottom:1px solid #000}table.busy tbody tr:nth-child(2n){background:#ccc}.grey{color:#999}.red{color:#f44336}a{text-decoration:none;color:#1e90ff}a:not(.start):hover{color:#1e40ff;cursor:pointer}a:not(.start):visited{color:#1e20ff}.start{display:block}.start{background-color:#1e90ff;color:#fff;padding:1em 1.5em;text-decoration:none;text-transform:uppercase;width:fit-content;margin:10px auto}.start:hover{background-color:#1e20ff}.start:active{background-color:#000}li{margin-left:30px}button.inactive-layer{background:#eee;border:0;padding:4px}button.active-layer{background:#1e9!important;border:0;padding:4px}button.preview-layer{background:#fdd6df}button.inactive-layer:hover{background:#1e9}.legend{line-height:18px;color:#555}.legend i{width:18px;height:18px;display:inline-block;margin-right:8px;opacity:.7}.diff-add{color:green}.diff-remove{color:red} +.leaflet-pane,.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile-container,.leaflet-pane>svg,.leaflet-pane>canvas,.leaflet-zoom-box,.leaflet-image-layer,.leaflet-layer{position:absolute;left:0;top:0}.leaflet-container{overflow:hidden}.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow{-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-tile::selection{background:transparent}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{width:1600px;height:1600px;-webkit-transform-origin:0 0}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-overlay-pane svg{max-width:none!important;max-height:none!important}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer,.leaflet-container .leaflet-tile{max-width:none!important;max-height:none!important;width:auto;padding:0}.leaflet-container img.leaflet-tile{mix-blend-mode:plus-lighter}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:rgba(51,181,229,.4)}.leaflet-tile{filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{width:0;height:0;-moz-box-sizing:border-box;box-sizing:border-box;z-index:800}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{position:relative;z-index:800;pointer-events:visiblePainted;pointer-events:auto}.leaflet-top,.leaflet-bottom{position:absolute;z-index:1000;pointer-events:none}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-popup{opacity:0;-webkit-transition:opacity .2s linear;-moz-transition:opacity .2s linear;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}svg.leaflet-zoom-animated{will-change:transform}.leaflet-zoom-anim .leaflet-zoom-animated{-webkit-transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);-moz-transition:-moz-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1)}.leaflet-zoom-anim .leaflet-tile,.leaflet-pan-anim .leaflet-tile{-webkit-transition:none;-moz-transition:none;transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab;cursor:grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-popup-pane,.leaflet-control{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:grabbing}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-image-layer,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-marker-icon.leaflet-interactive,.leaflet-image-layer.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive,svg.leaflet-image-layer.leaflet-interactive path{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{background:#ddd;outline-offset:1px}.leaflet-container a{color:#0078a8}.leaflet-zoom-box{border:2px dotted #38f;background:rgba(255,255,255,.5)}.leaflet-container{font-family:Helvetica Neue,Arial,Helvetica,sans-serif;font-size:12px;font-size:.75rem;line-height:1.5}.leaflet-bar{box-shadow:0 1px 5px #000000a6;border-radius:4px}.leaflet-bar a{background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;display:block;text-align:center;text-decoration:none;color:#000}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50% 50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover,.leaflet-bar a:focus{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:none}.leaflet-bar a.leaflet-disabled{cursor:default;background-color:#f4f4f4;color:#bbb}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-left-radius:2px;border-bottom-right-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{font:700 18px Lucida Console,Monaco,monospace;text-indent:1px}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{box-shadow:0 1px 5px #0006;background:#fff;border-radius:5px}.leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers .leaflet-control-layers-list,.leaflet-control-layers-expanded .leaflet-control-layers-toggle{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{padding:6px 10px 6px 6px;color:#333;background:#fff}.leaflet-control-layers-scrollbar{overflow-y:scroll;overflow-x:hidden;padding-right:5px}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{display:block;font-size:13px;font-size:1.08333em}.leaflet-control-layers-separator{height:0;border-top:1px solid #ddd;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(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=)}.leaflet-container .leaflet-control-attribution{background:#fff;background:rgba(255,255,255,.8);margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{padding:0 5px;color:#333;line-height:1.4}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover,.leaflet-control-attribution a:focus{text-decoration:underline}.leaflet-attribution-flag{display:inline!important;vertical-align:baseline!important;width:1em;height:.6669em}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{border:2px solid #777;border-top:none;line-height:1.1;padding:2px 5px 1px;white-space:nowrap;-moz-box-sizing:border-box;box-sizing:border-box;background:rgba(255,255,255,.8);text-shadow:1px 1px #fff}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{box-shadow:none}.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{border:2px solid rgba(0,0,0,.2);background-clip:padding-box}.leaflet-popup{position:absolute;text-align:center;margin-bottom:20px}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:12px}.leaflet-popup-content{margin:13px 24px 13px 20px;line-height:1.3;font-size:13px;font-size:1.08333em;min-height:1px}.leaflet-popup-content p{margin:1.3em 0}.leaflet-popup-tip-container{width:40px;height:20px;position:absolute;left:50%;margin-top:-1px;margin-left:-20px;overflow:hidden;pointer-events:none}.leaflet-popup-tip{width:17px;height:17px;padding:1px;margin:-10px auto 0;pointer-events:auto;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:white;color:#333;box-shadow:0 3px 14px #0006}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;border:none;text-align:center;width:24px;height:24px;font:16px/24px Tahoma,Verdana,sans-serif;color:#757575;text-decoration:none;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover,.leaflet-container a.leaflet-popup-close-button:focus{color:#585858}.leaflet-popup-scrolled{overflow:auto}.leaflet-oldie .leaflet-popup-content-wrapper{-ms-zoom:1}.leaflet-oldie .leaflet-popup-tip{width:24px;margin:0 auto;-ms-filter:"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";filter:progid:DXImageTransform.Microsoft.Matrix(M11=.70710678,M12=.70710678,M21=-.70710678,M22=.70710678)}.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{position:absolute;padding:6px;background-color:#fff;border:1px solid #fff;border-radius:3px;color:#222;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;box-shadow:0 1px 3px #0006}.leaflet-tooltip.leaflet-interactive{cursor:pointer;pointer-events:auto}.leaflet-tooltip-top:before,.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{position:absolute;pointer-events:none;border:6px solid transparent;background:transparent;content:""}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{left:50%;margin-left:-6px}.leaflet-tooltip-top:before{bottom:0;margin-bottom:-12px;border-top-color:#fff}.leaflet-tooltip-bottom:before{top:0;margin-top:-12px;margin-left:-6px;border-bottom-color:#fff}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{top:50%;margin-top:-6px}.leaflet-tooltip-left:before{right:0;margin-right:-12px;border-left-color:#fff}.leaflet-tooltip-right:before{left:0;margin-left:-12px;border-right-color:#fff}@media print{.leaflet-control{-webkit-print-color-adjust:exact;print-color-adjust:exact}}:root{--added: #b7e8e0;--removed: #e4b3bb;--changedOld: #efdab0;--changedNew: #f3f3c2}._added_fvc69_9{background:var(--added)}._removed_fvc69_12,._deleted_fvc69_15{background:var(--removed)}._changedOld_fvc69_18{background:var(--changedOld)}._changedNew_fvc69_21{background:var(--changedNew)}._uploadRoot_fvc69_25{margin:32px;text-align:center}._tagChanges_fvc69_30{overflow-wrap:break-word;text-align:left}._alert_fvc69_35{background:#ddf4ff;border-color:#54aeff66;border-radius:6px;border-style:solid;border-width:1px;padding:20px;display:inline-block;min-width:400px}._alert_fvc69_35._error_fvc69_45{background:#ffebe9;border-color:#ff818266}._diffTable_fvc69_50{width:100%}._diffTable_fvc69_50 tr:nth-of-type(odd){background:#f8f8f8}._diffTable_fvc69_50 tr>td:first-child{font-weight:600}._diffTable_fvc69_50 td{text-align:left}._diffTable_fvc69_50 td,._diffTable_fvc69_50 th{border:1px solid #dadada;padding:6px;color:#666}._main_gt6g9_1{max-width:600px;margin:16px auto;text-align:center}._list_gt6g9_7{text-align:center}._item_gt6g9_11{display:flex;justify-content:space-around;background:#f2f2f2;padding:8px;margin:8px;border-radius:4px}._error_gt6g9_21{color:#f36}._btn_gt6g9_25{padding:8px;border:1px solid #999;border-radius:4px}._btn_gt6g9_25:hover{opacity:.8;cursor:pointer}._smallInput_gt6g9_34{padding:4px;border:1px solid #999;border-radius:4px;margin-left:2px}._saveBtn_gt6g9_41{background-color:#f36}*{margin:0;padding:0}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}h1,h2,h3,h4{margin-top:24px}code{font-family:source-code-pro,Menlo,Monaco,Consolas,Courier New,monospace}kbd{margin-left:4px;padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;box-shadow:inset 0 -1px #00000040}table{border-collapse:collapse}table:not(.busy) tr{border-bottom:1px solid #666}table.busy thead tr{border-bottom:1px solid #000}table.busy tbody tr:nth-child(2n){background:#ccc}.grey{color:#999}.red{color:#f44336}a{text-decoration:none;color:#1e90ff}a:not(.start):hover{color:#1e40ff;cursor:pointer}a:not(.start):visited{color:#1e20ff}.start{display:block}.start{background-color:#1e90ff;color:#fff;padding:1em 1.5em;text-decoration:none;text-transform:uppercase;width:fit-content;margin:10px auto}.start:hover{background-color:#1e20ff}.start:active{background-color:#000}li{margin-left:30px}button.inactive-layer{background:#eee;border:0;padding:4px}button.active-layer{background:#1e9!important;border:0;padding:4px}button.preview-layer{background:#fdd6df}button.inactive-layer:hover{background:#1e9}.legend{line-height:18px;color:#555}.legend i{width:18px;height:18px;display:inline-block;margin-right:8px;opacity:.7}.diff-add{color:green}.diff-remove{color:red} diff --git a/assets/index-df5d216c.js b/assets/index-df5d216c.js deleted file mode 100644 index 2abf676..0000000 --- a/assets/index-df5d216c.js +++ /dev/null @@ -1,117 +0,0 @@ -(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))i(r);new MutationObserver(r=>{for(const a of r)if(a.type==="childList")for(const u of a.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&i(u)}).observe(document,{childList:!0,subtree:!0});function n(r){const a={};return r.integrity&&(a.integrity=r.integrity),r.referrerPolicy&&(a.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?a.credentials="include":r.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function i(r){if(r.ep)return;r.ep=!0;const a=n(r);fetch(r.href,a)}})();var o2=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ot(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var gv={exports:{}},Lr={},mv={exports:{}},ye={};/** - * @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 d9=Symbol.for("react.element"),$C=Symbol.for("react.portal"),BC=Symbol.for("react.fragment"),zC=Symbol.for("react.strict_mode"),jC=Symbol.for("react.profiler"),DC=Symbol.for("react.provider"),QC=Symbol.for("react.context"),WC=Symbol.for("react.forward_ref"),HC=Symbol.for("react.suspense"),ZC=Symbol.for("react.memo"),GC=Symbol.for("react.lazy"),dp=Symbol.iterator;function qC(e){return e===null||typeof e!="object"?null:(e=dp&&e[dp]||e["@@iterator"],typeof e=="function"?e:null)}var yv={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},vv=Object.assign,_v={};function K6(e,t,n){this.props=e,this.context=t,this.refs=_v,this.updater=n||yv}K6.prototype.isReactComponent={};K6.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")};K6.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function wv(){}wv.prototype=K6.prototype;function yc(e,t,n){this.props=e,this.context=t,this.refs=_v,this.updater=n||yv}var vc=yc.prototype=new wv;vc.constructor=yc;vv(vc,K6.prototype);vc.isPureReactComponent=!0;var hp=Array.isArray,xv=Object.prototype.hasOwnProperty,_c={current:null},bv={key:!0,ref:!0,__self:!0,__source:!0};function Sv(e,t,n){var i,r={},a=null,u=null;if(t!=null)for(i in t.ref!==void 0&&(u=t.ref),t.key!==void 0&&(a=""+t.key),t)xv.call(t,i)&&!bv.hasOwnProperty(i)&&(r[i]=t[i]);var f=arguments.length-2;if(f===1)r.children=n;else if(1>>1,T1=V[w1];if(0>>1;w1r(_1,f1))d1r(I1,_1)?(V[w1]=I1,V[d1]=f1,w1=d1):(V[w1]=_1,V[F1]=f1,w1=F1);else if(d1r(I1,f1))V[w1]=I1,V[d1]=f1,w1=d1;else break e}}return p1}function r(V,p1){var f1=V.sortIndex-p1.sortIndex;return f1!==0?f1:V.id-p1.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var u=Date,f=u.now();e.unstable_now=function(){return u.now()-f}}var d=[],p=[],m=1,h=null,v=3,S=!1,E=!1,k=!1,O=typeof setTimeout=="function"?setTimeout:null,x=typeof clearTimeout=="function"?clearTimeout:null,w=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function b(V){for(var p1=n(p);p1!==null;){if(p1.callback===null)i(p);else if(p1.startTime<=V)i(p),p1.sortIndex=p1.expirationTime,t(d,p1);else break;p1=n(p)}}function N(V){if(k=!1,b(V),!E)if(n(d)!==null)E=!0,l1($);else{var p1=n(p);p1!==null&&r1(N,p1.startTime-V)}}function $(V,p1){E=!1,k&&(k=!1,x(B),B=-1),S=!0;var f1=v;try{for(b(p1),h=n(d);h!==null&&(!(h.expirationTime>p1)||V&&!D());){var w1=h.callback;if(typeof w1=="function"){h.callback=null,v=h.priorityLevel;var T1=w1(h.expirationTime<=p1);p1=e.unstable_now(),typeof T1=="function"?h.callback=T1:h===n(d)&&i(d),b(p1)}else i(d);h=n(d)}if(h!==null)var j1=!0;else{var F1=n(p);F1!==null&&r1(N,F1.startTime-p1),j1=!1}return j1}finally{h=null,v=f1,S=!1}}var I=!1,j=null,B=-1,Y=5,H=-1;function D(){return!(e.unstable_now()-HV||125w1?(V.sortIndex=f1,t(p,V),n(d)===null&&V===n(p)&&(k?(x(B),B=-1):k=!0,r1(N,f1-w1))):(V.sortIndex=T1,t(d,V),E||S||(E=!0,l1($))),V},e.unstable_shouldYield=D,e.unstable_wrapCallback=function(V){var p1=v;return function(){var f1=v;v=p1;try{return V.apply(this,arguments)}finally{v=f1}}}})(kv);Av.exports=kv;var oN=Av.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 Tv=G,v4=oN;function A1(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"),Pu=Object.prototype.hasOwnProperty,aN=/^[: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]*$/,gp={},mp={};function sN(e){return Pu.call(mp,e)?!0:Pu.call(gp,e)?!1:aN.test(e)?mp[e]=!0:(gp[e]=!0,!1)}function uN(e,t,n,i){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return i?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function lN(e,t,n,i){if(t===null||typeof t>"u"||uN(e,t,n,i))return!0;if(i)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 Gt(e,t,n,i,r,a,u){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=i,this.attributeNamespace=r,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=u}var wt={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){wt[e]=new Gt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];wt[t]=new Gt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){wt[e]=new Gt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){wt[e]=new Gt(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){wt[e]=new Gt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){wt[e]=new Gt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){wt[e]=new Gt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){wt[e]=new Gt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){wt[e]=new Gt(e,5,!1,e.toLowerCase(),null,!1,!1)});var xc=/[\-:]([a-z])/g;function bc(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(xc,bc);wt[t]=new Gt(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(xc,bc);wt[t]=new Gt(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(xc,bc);wt[t]=new Gt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){wt[e]=new Gt(e,1,!1,e.toLowerCase(),null,!1,!1)});wt.xlinkHref=new Gt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){wt[e]=new Gt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Sc(e,t,n,i){var r=wt.hasOwnProperty(t)?wt[t]:null;(r!==null?r.type!==0:i||!(2f||r[u]!==a[f]){var d=` -`+r[u].replace(" at new "," at ");return e.displayName&&d.includes("")&&(d=d.replace("",e.displayName)),d}while(1<=u&&0<=f);break}}}finally{Ts=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?d7(e):""}function cN(e){switch(e.tag){case 5:return d7(e.type);case 16:return d7("Lazy");case 13:return d7("Suspense");case 19:return d7("SuspenseList");case 0:case 2:case 15:return e=Ps(e.type,!1),e;case 11:return e=Ps(e.type.render,!1),e;case 1:return e=Ps(e.type,!0),e;default:return""}}function Lu(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 d6:return"Fragment";case f6:return"Portal";case Cu:return"Profiler";case Ec:return"StrictMode";case Nu:return"Suspense";case Ou:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Nv:return(e.displayName||"Context")+".Consumer";case Cv:return(e._context.displayName||"Context")+".Provider";case Mc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Ac:return t=e.displayName||null,t!==null?t:Lu(e.type)||"Memo";case R3:t=e._payload,e=e._init;try{return Lu(e(t))}catch{}}return null}function fN(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 Lu(t);case 8:return t===Ec?"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 J3(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Lv(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function dN(e){var t=Lv(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),i=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var r=n.get,a=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return r.call(this)},set:function(u){i=""+u,a.call(this,u)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(u){i=""+u},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Ni(e){e._valueTracker||(e._valueTracker=dN(e))}function Fv(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=Lv(e)?e.checked?"true":"false":e.value),e=i,e!==n?(t.setValue(e),!0):!1}function O8(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 Fu(e,t){var n=t.checked;return qe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function vp(e,t){var n=t.defaultValue==null?"":t.defaultValue,i=t.checked!=null?t.checked:t.defaultChecked;n=J3(t.value!=null?t.value:n),e._wrapperState={initialChecked:i,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Iv(e,t){t=t.checked,t!=null&&Sc(e,"checked",t,!1)}function Iu(e,t){Iv(e,t);var n=J3(t.value),i=t.type;if(n!=null)i==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(i==="submit"||i==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Ru(e,t.type,n):t.hasOwnProperty("defaultValue")&&Ru(e,t.type,J3(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function _p(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var i=t.type;if(!(i!=="submit"&&i!=="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 Ru(e,t,n){(t!=="number"||O8(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var h7=Array.isArray;function T6(e,t,n,i){if(e=e.options,t){t={};for(var r=0;r"+t.valueOf().toString()+"",t=Oi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function L7(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var _7={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},hN=["Webkit","ms","Moz","O"];Object.keys(_7).forEach(function(e){hN.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),_7[t]=_7[e]})});function Bv(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||_7.hasOwnProperty(e)&&_7[e]?(""+t).trim():t+"px"}function zv(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var i=n.indexOf("--")===0,r=Bv(n,t[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,r):e[n]=r}}var pN=qe({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 Bu(e,t){if(t){if(pN[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(A1(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(A1(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(A1(61))}if(t.style!=null&&typeof t.style!="object")throw Error(A1(62))}}function zu(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 ju=null;function kc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Du=null,P6=null,C6=null;function bp(e){if(e=g9(e)){if(typeof Du!="function")throw Error(A1(280));var t=e.stateNode;t&&(t=$r(t),Du(e.stateNode,e.type,t))}}function jv(e){P6?C6?C6.push(e):C6=[e]:P6=e}function Dv(){if(P6){var e=P6,t=C6;if(C6=P6=null,bp(e),t)for(e=0;e>>=0,e===0?32:31-(MN(e)/AN|0)|0}var Li=64,Fi=4194304;function p7(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 R8(e,t){var n=e.pendingLanes;if(n===0)return 0;var i=0,r=e.suspendedLanes,a=e.pingedLanes,u=n&268435455;if(u!==0){var f=u&~r;f!==0?i=p7(f):(a&=u,a!==0&&(i=p7(a)))}else u=n&~r,u!==0?i=p7(u):a!==0&&(i=p7(a));if(i===0)return 0;if(t!==0&&t!==i&&!(t&r)&&(r=i&-i,a=t&-t,r>=a||r===16&&(a&4194240)!==0))return t;if(i&4&&(i|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=i;0n;n++)t.push(e);return t}function h9(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-u2(t),e[t]=n}function CN(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 i=e.eventTimes;for(e=e.expirationTimes;0=x7),Np=String.fromCharCode(32),Op=!1;function u_(e,t){switch(e){case"keyup":return rO.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function l_(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var h6=!1;function aO(e,t){switch(e){case"compositionend":return l_(t);case"keypress":return t.which!==32?null:(Op=!0,Np);case"textInput":return e=t.data,e===Np&&Op?null:e;default:return null}}function sO(e,t){if(h6)return e==="compositionend"||!Ic&&u_(e,t)?(e=a_(),p8=Oc=z3=null,h6=!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=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Rp(n)}}function h_(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?h_(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function p_(){for(var e=window,t=O8();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=O8(e.document)}return t}function Rc(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 mO(e){var t=p_(),n=e.focusedElem,i=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&h_(n.ownerDocument.documentElement,n)){if(i!==null&&Rc(n)){if(t=i.start,e=i.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 r=n.textContent.length,a=Math.min(i.start,r);i=i.end===void 0?a:Math.min(i.end,r),!e.extend&&a>i&&(r=i,i=a,a=r),r=Up(n,a);var u=Up(n,i);r&&u&&(e.rangeCount!==1||e.anchorNode!==r.node||e.anchorOffset!==r.offset||e.focusNode!==u.node||e.focusOffset!==u.offset)&&(t=t.createRange(),t.setStart(r.node,r.offset),e.removeAllRanges(),a>i?(e.addRange(t),e.extend(u.node,u.offset)):(t.setEnd(u.node,u.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,p6=null,qu=null,S7=null,Vu=!1;function $p(e,t,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Vu||p6==null||p6!==O8(i)||(i=p6,"selectionStart"in i&&Rc(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),S7&&B7(S7,i)||(S7=i,i=B8(qu,"onSelect"),0y6||(e.current=tl[y6],tl[y6]=null,y6--)}function Ie(e,t){y6++,tl[y6]=e.current,e.current=t}var en={},Nt=on(en),r4=on(!1),o5=en;function z6(e,t){var n=e.type.contextTypes;if(!n)return en;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===t)return i.__reactInternalMemoizedMaskedChildContext;var r={},a;for(a in n)r[a]=t[a];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=r),r}function o4(e){return e=e.childContextTypes,e!=null}function j8(){Be(r4),Be(Nt)}function Hp(e,t,n){if(Nt.current!==en)throw Error(A1(168));Ie(Nt,t),Ie(r4,n)}function S_(e,t,n){var i=e.stateNode;if(t=t.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var r in i)if(!(r in t))throw Error(A1(108,fN(e)||"Unknown",r));return qe({},n,i)}function D8(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||en,o5=Nt.current,Ie(Nt,e),Ie(r4,r4.current),!0}function Zp(e,t,n){var i=e.stateNode;if(!i)throw Error(A1(169));n?(e=S_(e,t,o5),i.__reactInternalMemoizedMergedChildContext=e,Be(r4),Be(Nt),Ie(Nt,e)):Be(r4),Ie(r4,n)}var r3=null,Br=!1,Qs=!1;function E_(e){r3===null?r3=[e]:r3.push(e)}function TO(e){Br=!0,E_(e)}function an(){if(!Qs&&r3!==null){Qs=!0;var e=0,t=Te;try{var n=r3;for(Te=1;e>=u,r-=u,o3=1<<32-u2(t)+r|n<B?(Y=j,j=null):Y=j.sibling;var H=v(x,j,b[B],N);if(H===null){j===null&&(j=Y);break}e&&j&&H.alternate===null&&t(x,j),w=a(H,w,B),I===null?$=H:I.sibling=H,I=H,j=Y}if(B===b.length)return n(x,j),De&&$n(x,B),$;if(j===null){for(;BB?(Y=j,j=null):Y=j.sibling;var D=v(x,j,H.value,N);if(D===null){j===null&&(j=Y);break}e&&j&&D.alternate===null&&t(x,j),w=a(D,w,B),I===null?$=D:I.sibling=D,I=D,j=Y}if(H.done)return n(x,j),De&&$n(x,B),$;if(j===null){for(;!H.done;B++,H=b.next())H=h(x,H.value,N),H!==null&&(w=a(H,w,B),I===null?$=H:I.sibling=H,I=H);return De&&$n(x,B),$}for(j=i(x,j);!H.done;B++,H=b.next())H=S(j,x,B,H.value,N),H!==null&&(e&&H.alternate!==null&&j.delete(H.key===null?B:H.key),w=a(H,w,B),I===null?$=H:I.sibling=H,I=H);return e&&j.forEach(function(J){return t(x,J)}),De&&$n(x,B),$}function O(x,w,b,N){if(typeof b=="object"&&b!==null&&b.type===d6&&b.key===null&&(b=b.props.children),typeof b=="object"&&b!==null){switch(b.$$typeof){case Ci:e:{for(var $=b.key,I=w;I!==null;){if(I.key===$){if($=b.type,$===d6){if(I.tag===7){n(x,I.sibling),w=r(I,b.props.children),w.return=x,x=w;break e}}else if(I.elementType===$||typeof $=="object"&&$!==null&&$.$$typeof===R3&&Jp($)===I.type){n(x,I.sibling),w=r(I,b.props),w.ref=e7(x,I,b),w.return=x,x=w;break e}n(x,I);break}else t(x,I);I=I.sibling}b.type===d6?(w=e5(b.props.children,x.mode,N,b.key),w.return=x,x=w):(N=b8(b.type,b.key,b.props,null,x.mode,N),N.ref=e7(x,w,b),N.return=x,x=N)}return u(x);case f6:e:{for(I=b.key;w!==null;){if(w.key===I)if(w.tag===4&&w.stateNode.containerInfo===b.containerInfo&&w.stateNode.implementation===b.implementation){n(x,w.sibling),w=r(w,b.children||[]),w.return=x,x=w;break e}else{n(x,w);break}else t(x,w);w=w.sibling}w=Xs(b,x.mode,N),w.return=x,x=w}return u(x);case R3:return I=b._init,O(x,w,I(b._payload),N)}if(h7(b))return E(x,w,b,N);if(V0(b))return k(x,w,b,N);ji(x,b)}return typeof b=="string"&&b!==""||typeof b=="number"?(b=""+b,w!==null&&w.tag===6?(n(x,w.sibling),w=r(w,b),w.return=x,x=w):(n(x,w),w=Ys(b,x.mode,N),w.return=x,x=w),u(x)):n(x,w)}return O}var D6=O_(!0),L_=O_(!1),m9={},C2=on(m9),Q7=on(m9),W7=on(m9);function Zn(e){if(e===m9)throw Error(A1(174));return e}function Hc(e,t){switch(Ie(W7,t),Ie(Q7,e),Ie(C2,m9),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:$u(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=$u(t,e)}Be(C2),Ie(C2,t)}function Q6(){Be(C2),Be(Q7),Be(W7)}function F_(e){Zn(W7.current);var t=Zn(C2.current),n=$u(t,e.type);t!==n&&(Ie(Q7,e),Ie(C2,n))}function Zc(e){Q7.current===e&&(Be(C2),Be(Q7))}var Ze=on(0);function q8(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Ws=[];function Gc(){for(var e=0;en?n:4,e(!0);var i=Hs.transition;Hs.transition={};try{e(!1),t()}finally{Te=n,Hs.transition=i}}function Y_(){return D4().memoizedState}function OO(e,t,n){var i=Y3(e);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},X_(e))K_(t,n);else if(n=T_(e,t,n,i),n!==null){var r=Ht();l2(n,e,i,r),J_(n,t,i)}}function LO(e,t,n){var i=Y3(e),r={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(X_(e))K_(t,r);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var u=t.lastRenderedState,f=a(u,n);if(r.hasEagerState=!0,r.eagerState=f,c2(f,u)){var d=t.interleaved;d===null?(r.next=r,Qc(t)):(r.next=d.next,d.next=r),t.interleaved=r;return}}catch{}finally{}n=T_(e,t,r,i),n!==null&&(r=Ht(),l2(n,e,i,r),J_(n,t,i))}}function X_(e){var t=e.alternate;return e===Ge||t!==null&&t===Ge}function K_(e,t){E7=V8=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function J_(e,t,n){if(n&4194240){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Pc(e,n)}}var Y8={readContext:j4,useCallback:At,useContext:At,useEffect:At,useImperativeHandle:At,useInsertionEffect:At,useLayoutEffect:At,useMemo:At,useReducer:At,useRef:At,useState:At,useDebugValue:At,useDeferredValue:At,useTransition:At,useMutableSource:At,useSyncExternalStore:At,useId:At,unstable_isNewReconciler:!1},FO={readContext:j4,useCallback:function(e,t){return M2().memoizedState=[e,t===void 0?null:t],e},useContext:j4,useEffect:tg,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,v8(4194308,4,H_.bind(null,t,e),n)},useLayoutEffect:function(e,t){return v8(4194308,4,e,t)},useInsertionEffect:function(e,t){return v8(4,2,e,t)},useMemo:function(e,t){var n=M2();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var i=M2();return t=n!==void 0?n(t):t,i.memoizedState=i.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},i.queue=e,e=e.dispatch=OO.bind(null,Ge,e),[i.memoizedState,e]},useRef:function(e){var t=M2();return e={current:e},t.memoizedState=e},useState:eg,useDebugValue:Kc,useDeferredValue:function(e){return M2().memoizedState=e},useTransition:function(){var e=eg(!1),t=e[0];return e=NO.bind(null,e[1]),M2().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var i=Ge,r=M2();if(De){if(n===void 0)throw Error(A1(407));n=n()}else{if(n=t(),ft===null)throw Error(A1(349));s5&30||U_(i,t,n)}r.memoizedState=n;var a={value:n,getSnapshot:t};return r.queue=a,tg(B_.bind(null,i,a,e),[e]),i.flags|=2048,G7(9,$_.bind(null,i,a,n,t),void 0,null),n},useId:function(){var e=M2(),t=ft.identifierPrefix;if(De){var n=a3,i=o3;n=(i&~(1<<32-u2(i)-1)).toString(32)+n,t=":"+t+"R"+n,n=H7++,0<\/script>",e=e.removeChild(e.firstChild)):typeof i.is=="string"?e=u.createElement(n,{is:i.is}):(e=u.createElement(n),n==="select"&&(u=e,i.multiple?u.multiple=!0:i.size&&(u.size=i.size))):e=u.createElementNS(e,n),e[k2]=t,e[D7]=i,uw(e,t,!1,!1),t.stateNode=e;e:{switch(u=zu(n,i),n){case"dialog":Ue("cancel",e),Ue("close",e),r=i;break;case"iframe":case"object":case"embed":Ue("load",e),r=i;break;case"video":case"audio":for(r=0;rH6&&(t.flags|=128,i=!0,t7(a,!1),t.lanes=4194304)}else{if(!i)if(e=q8(u),e!==null){if(t.flags|=128,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),t7(a,!0),a.tail===null&&a.tailMode==="hidden"&&!u.alternate&&!De)return kt(t),null}else 2*tt()-a.renderingStartTime>H6&&n!==1073741824&&(t.flags|=128,i=!0,t7(a,!1),t.lanes=4194304);a.isBackwards?(u.sibling=t.child,t.child=u):(n=a.last,n!==null?n.sibling=u:t.child=u,a.last=u)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=tt(),t.sibling=null,n=Ze.current,Ie(Ze,i?n&1|2:n&1),t):(kt(t),null);case 22:case 23:return of(),i=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(t.flags|=8192),i&&t.mode&1?g4&1073741824&&(kt(t),t.subtreeFlags&6&&(t.flags|=8192)):kt(t),null;case 24:return null;case 25:return null}throw Error(A1(156,t.tag))}function DO(e,t){switch($c(t),t.tag){case 1:return o4(t.type)&&j8(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Q6(),Be(r4),Be(Nt),Gc(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Zc(t),null;case 13:if(Be(Ze),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(A1(340));j6()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Be(Ze),null;case 4:return Q6(),null;case 10:return Dc(t.type._context),null;case 22:case 23:return of(),null;case 24:return null;default:return null}}var Qi=!1,Pt=!1,QO=typeof WeakSet=="function"?WeakSet:Set,L1=null;function x6(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Xe(e,t,i)}else n.current=null}function hl(e,t,n){try{n()}catch(i){Xe(e,t,i)}}var cg=!1;function WO(e,t){if(Yu=U8,e=p_(),Rc(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var r=i.anchorOffset,a=i.focusNode;i=i.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break e}var u=0,f=-1,d=-1,p=0,m=0,h=e,v=null;t:for(;;){for(var S;h!==n||r!==0&&h.nodeType!==3||(f=u+r),h!==a||i!==0&&h.nodeType!==3||(d=u+i),h.nodeType===3&&(u+=h.nodeValue.length),(S=h.firstChild)!==null;)v=h,h=S;for(;;){if(h===e)break t;if(v===n&&++p===r&&(f=u),v===a&&++m===i&&(d=u),(S=h.nextSibling)!==null)break;h=v,v=h.parentNode}h=S}n=f===-1||d===-1?null:{start:f,end:d}}else n=null}n=n||{start:0,end:0}}else n=null;for(Xu={focusedElem:e,selectionRange:n},U8=!1,L1=t;L1!==null;)if(t=L1,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,L1=e;else for(;L1!==null;){t=L1;try{var E=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(E!==null){var k=E.memoizedProps,O=E.memoizedState,x=t.stateNode,w=x.getSnapshotBeforeUpdate(t.elementType===t.type?k:t2(t.type,k),O);x.__reactInternalSnapshotBeforeUpdate=w}break;case 3:var b=t.stateNode.containerInfo;b.nodeType===1?b.textContent="":b.nodeType===9&&b.documentElement&&b.removeChild(b.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(A1(163))}}catch(N){Xe(t,t.return,N)}if(e=t.sibling,e!==null){e.return=t.return,L1=e;break}L1=t.return}return E=cg,cg=!1,E}function M7(e,t,n){var i=t.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var r=i=i.next;do{if((r.tag&e)===e){var a=r.destroy;r.destroy=void 0,a!==void 0&&hl(t,n,a)}r=r.next}while(r!==i)}}function Dr(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 i=n.create;n.destroy=i()}n=n.next}while(n!==t)}}function pl(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 fw(e){var t=e.alternate;t!==null&&(e.alternate=null,fw(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[k2],delete t[D7],delete t[el],delete t[AO],delete t[kO])),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 dw(e){return e.tag===5||e.tag===3||e.tag===4}function fg(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||dw(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 gl(e,t,n){var i=e.tag;if(i===5||i===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=z8));else if(i!==4&&(e=e.child,e!==null))for(gl(e,t,n),e=e.sibling;e!==null;)gl(e,t,n),e=e.sibling}function ml(e,t,n){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(i!==4&&(e=e.child,e!==null))for(ml(e,t,n),e=e.sibling;e!==null;)ml(e,t,n),e=e.sibling}var vt=null,n2=!1;function F3(e,t,n){for(n=n.child;n!==null;)hw(e,t,n),n=n.sibling}function hw(e,t,n){if(P2&&typeof P2.onCommitFiberUnmount=="function")try{P2.onCommitFiberUnmount(Fr,n)}catch{}switch(n.tag){case 5:Pt||x6(n,t);case 6:var i=vt,r=n2;vt=null,F3(e,t,n),vt=i,n2=r,vt!==null&&(n2?(e=vt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):vt.removeChild(n.stateNode));break;case 18:vt!==null&&(n2?(e=vt,n=n.stateNode,e.nodeType===8?Ds(e.parentNode,n):e.nodeType===1&&Ds(e,n),U7(e)):Ds(vt,n.stateNode));break;case 4:i=vt,r=n2,vt=n.stateNode.containerInfo,n2=!0,F3(e,t,n),vt=i,n2=r;break;case 0:case 11:case 14:case 15:if(!Pt&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){r=i=i.next;do{var a=r,u=a.destroy;a=a.tag,u!==void 0&&(a&2||a&4)&&hl(n,t,u),r=r.next}while(r!==i)}F3(e,t,n);break;case 1:if(!Pt&&(x6(n,t),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(f){Xe(n,t,f)}F3(e,t,n);break;case 21:F3(e,t,n);break;case 22:n.mode&1?(Pt=(i=Pt)||n.memoizedState!==null,F3(e,t,n),Pt=i):F3(e,t,n);break;default:F3(e,t,n)}}function dg(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new QO),t.forEach(function(i){var r=JO.bind(null,e,i);n.has(i)||(n.add(i),i.then(r,r))})}}function e2(e,t){var n=t.deletions;if(n!==null)for(var i=0;ir&&(r=u),i&=~a}if(i=r,i=tt()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*ZO(i/1960))-i,10e?16:e,j3===null)var i=!1;else{if(e=j3,j3=null,J8=0,Ee&6)throw Error(A1(331));var r=Ee;for(Ee|=4,L1=e.current;L1!==null;){var a=L1,u=a.child;if(L1.flags&16){var f=a.deletions;if(f!==null){for(var d=0;dtt()-nf?Jn(e,0):tf|=n),a4(e,t)}function xw(e,t){t===0&&(e.mode&1?(t=Fi,Fi<<=1,!(Fi&130023424)&&(Fi=4194304)):t=1);var n=Ht();e=d3(e,t),e!==null&&(h9(e,t,n),a4(e,n))}function KO(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),xw(e,n)}function JO(e,t){var n=0;switch(e.tag){case 13:var i=e.stateNode,r=e.memoizedState;r!==null&&(n=r.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(A1(314))}i!==null&&i.delete(t),xw(e,n)}var bw;bw=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||r4.current)n4=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return n4=!1,zO(e,t,n);n4=!!(e.flags&131072)}else n4=!1,De&&t.flags&1048576&&M_(t,W8,t.index);switch(t.lanes=0,t.tag){case 2:var i=t.type;_8(e,t),e=t.pendingProps;var r=z6(t,Nt.current);O6(t,n),r=Vc(null,t,i,e,r,n);var a=Yc();return t.flags|=1,typeof r=="object"&&r!==null&&typeof r.render=="function"&&r.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,o4(i)?(a=!0,D8(t)):a=!1,t.memoizedState=r.state!==null&&r.state!==void 0?r.state:null,Wc(t),r.updater=zr,t.stateNode=r,r._reactInternals=t,al(t,i,e,n),t=ll(null,t,i,!0,a,n)):(t.tag=0,De&&a&&Uc(t),Dt(null,t,r,n),t=t.child),t;case 16:i=t.elementType;e:{switch(_8(e,t),e=t.pendingProps,r=i._init,i=r(i._payload),t.type=i,r=t.tag=tL(i),e=t2(i,e),r){case 0:t=ul(null,t,i,e,n);break e;case 1:t=sg(null,t,i,e,n);break e;case 11:t=og(null,t,i,e,n);break e;case 14:t=ag(null,t,i,t2(i.type,e),n);break e}throw Error(A1(306,i,""))}return t;case 0:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:t2(i,r),ul(e,t,i,r,n);case 1:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:t2(i,r),sg(e,t,i,r,n);case 3:e:{if(ow(t),e===null)throw Error(A1(387));i=t.pendingProps,a=t.memoizedState,r=a.element,P_(e,t),G8(t,i,null,n);var u=t.memoizedState;if(i=u.element,a.isDehydrated)if(a={element:i,isDehydrated:!1,cache:u.cache,pendingSuspenseBoundaries:u.pendingSuspenseBoundaries,transitions:u.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){r=W6(Error(A1(423)),t),t=ug(e,t,i,n,r);break e}else if(i!==r){r=W6(Error(A1(424)),t),t=ug(e,t,i,n,r);break e}else for(m4=G3(t.stateNode.containerInfo.firstChild),y4=t,De=!0,i2=null,n=L_(t,null,i,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(j6(),i===r){t=h3(e,t,n);break e}Dt(e,t,i,n)}t=t.child}return t;case 5:return F_(t),e===null&&il(t),i=t.type,r=t.pendingProps,a=e!==null?e.memoizedProps:null,u=r.children,Ku(i,r)?u=null:a!==null&&Ku(i,a)&&(t.flags|=32),rw(e,t),Dt(e,t,u,n),t.child;case 6:return e===null&&il(t),null;case 13:return aw(e,t,n);case 4:return Hc(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=D6(t,null,i,n):Dt(e,t,i,n),t.child;case 11:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:t2(i,r),og(e,t,i,r,n);case 7:return Dt(e,t,t.pendingProps,n),t.child;case 8:return Dt(e,t,t.pendingProps.children,n),t.child;case 12:return Dt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(i=t.type._context,r=t.pendingProps,a=t.memoizedProps,u=r.value,Ie(H8,i._currentValue),i._currentValue=u,a!==null)if(c2(a.value,u)){if(a.children===r.children&&!r4.current){t=h3(e,t,n);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var f=a.dependencies;if(f!==null){u=a.child;for(var d=f.firstContext;d!==null;){if(d.context===i){if(a.tag===1){d=l3(-1,n&-n),d.tag=2;var p=a.updateQueue;if(p!==null){p=p.shared;var m=p.pending;m===null?d.next=d:(d.next=m.next,m.next=d),p.pending=d}}a.lanes|=n,d=a.alternate,d!==null&&(d.lanes|=n),rl(a.return,n,t),f.lanes|=n;break}d=d.next}}else if(a.tag===10)u=a.type===t.type?null:a.child;else if(a.tag===18){if(u=a.return,u===null)throw Error(A1(341));u.lanes|=n,f=u.alternate,f!==null&&(f.lanes|=n),rl(u,n,t),u=a.sibling}else u=a.child;if(u!==null)u.return=a;else for(u=a;u!==null;){if(u===t){u=null;break}if(a=u.sibling,a!==null){a.return=u.return,u=a;break}u=u.return}a=u}Dt(e,t,r.children,n),t=t.child}return t;case 9:return r=t.type,i=t.pendingProps.children,O6(t,n),r=j4(r),i=i(r),t.flags|=1,Dt(e,t,i,n),t.child;case 14:return i=t.type,r=t2(i,t.pendingProps),r=t2(i.type,r),ag(e,t,i,r,n);case 15:return nw(e,t,t.type,t.pendingProps,n);case 17:return i=t.type,r=t.pendingProps,r=t.elementType===i?r:t2(i,r),_8(e,t),t.tag=1,o4(i)?(e=!0,D8(t)):e=!1,O6(t,n),N_(t,i,r),al(t,i,r,n),ll(null,t,i,!0,e,n);case 19:return sw(e,t,n);case 22:return iw(e,t,n)}throw Error(A1(156,t.tag))};function Sw(e,t){return Vv(e,t)}function eL(e,t,n,i){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=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function U4(e,t,n,i){return new eL(e,t,n,i)}function sf(e){return e=e.prototype,!(!e||!e.isReactComponent)}function tL(e){if(typeof e=="function")return sf(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Mc)return 11;if(e===Ac)return 14}return 2}function X3(e,t){var n=e.alternate;return n===null?(n=U4(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 b8(e,t,n,i,r,a){var u=2;if(i=e,typeof e=="function")sf(e)&&(u=1);else if(typeof e=="string")u=5;else e:switch(e){case d6:return e5(n.children,r,a,t);case Ec:u=8,r|=8;break;case Cu:return e=U4(12,n,t,r|2),e.elementType=Cu,e.lanes=a,e;case Nu:return e=U4(13,n,t,r),e.elementType=Nu,e.lanes=a,e;case Ou:return e=U4(19,n,t,r),e.elementType=Ou,e.lanes=a,e;case Ov:return Wr(n,r,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Cv:u=10;break e;case Nv:u=9;break e;case Mc:u=11;break e;case Ac:u=14;break e;case R3:u=16,i=null;break e}throw Error(A1(130,e==null?e:typeof e,""))}return t=U4(u,n,t,r),t.elementType=e,t.type=i,t.lanes=a,t}function e5(e,t,n,i){return e=U4(7,e,i,t),e.lanes=n,e}function Wr(e,t,n,i){return e=U4(22,e,i,t),e.elementType=Ov,e.lanes=n,e.stateNode={isHidden:!1},e}function Ys(e,t,n){return e=U4(6,e,null,t),e.lanes=n,e}function Xs(e,t,n){return t=U4(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function nL(e,t,n,i,r){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=Ns(0),this.expirationTimes=Ns(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ns(0),this.identifierPrefix=i,this.onRecoverableError=r,this.mutableSourceEagerHydrationData=null}function uf(e,t,n,i,r,a,u,f,d){return e=new nL(e,t,n,f,d),t===1?(t=1,a===!0&&(t|=8)):t=0,a=U4(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Wc(a),e}function iL(e,t,n){var i=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(kw)}catch(e){console.error(e)}}kw(),Mv.exports=_4;var df=Mv.exports,Tw,wg=df;Tw=wg.createRoot,wg.hydrateRoot;const Pw={years:31536e6,months:2592e6,days:864e5,hours:36e5,minutes:6e4,seconds:1e3};function uL(e,t="floor"){var n,i,r=Date.now()-+e;for([n,i]of Object.entries(Pw)){var a=n,u=Math[t](r/i);if(1<=u)return[u,a]}return[0,"seconds"]}const Cw=G.memo(({date:e,locale:t=navigator.language,formatOptions:n,hideSeconds:i,roundStrategy:r})=>{const[a,u]=G.useState(""),[f,d]=G.useState(),p=G.useMemo(()=>new Intl.RelativeTimeFormat(t,{localeMatcher:"best fit",numeric:"always",style:"long",...n}),[t,n]),m=G.useCallback(()=>{var[h,v]=uL(e instanceof Date?e:new Date(e),r);u(v==="seconds"&&i?p.format(-1,"minute"):p.format(-h,v)),d(v)},[e,p,i,r]);return G.useEffect(m,[m]),G.useEffect(()=>{if(f){var h=Pw[f];const v=setInterval(m,h);return()=>clearInterval(v)}},[f,m]),a});Cw.displayName="TimeAgo";const Nw={PERFECT:[1,"Data is already perfect","No action required","#76d9a1"],EXISTS_BUT_WRONG_DATA:[2,"Address exists but the data is wrong","Select a suburb in the tool","#fada5e","data-wrong.txt"],EXISTS_BUT_NO_LINZ_REF:[3,"Address exists but no linz ref","Select a suburb in the tool","#fada5e","needs-linz-ref.txt"],MULTIPLE_EXIST_BUT_NO_LINZ_REF:[4,"Multiple addresses exists, none have linz ref","manual action required","#fada5e","needs-linz-ref-but-multiple.txt"],MULTIPLE_EXIST:[5,"Multiple addresses exists with same linz ref","manual action required","#ff7272","duplicate-linz-ref.txt"],EXISTS_BUT_LOCATION_WRONG:[6,"Addresses exist but location is very wrong",'Select the suburb called "ZZ Special Location Wrong".',"#fada5e","location-wrong.txt"],TOTALLY_MISSING:[7,"Addresses totally missing from OSM","Select a suburb in the tool","#fada5e"],NEEDS_DELETE:[8,"Addresses in OSM that have been deleted by LINZ","Select a suburb in the tool","#fada5e","needs-delete.txt"],NEEDS_DELETE_NON_TRIVIAL:[9,"Addresses in OSM that have been deleted by LINZ, but are on a OSM business/POI","manual action required","#ff7272","needs-delete-non-trivial.txt"],CORRUPT:[10,"There are multiple LINZ refs on the same OSM node","manual action required","#fada5e","corrupt.txt"],LINZ_REF_CHANGED:[11,"LINZ has changed their ID for an address, but not the data","Select the suburb called 'ZZ Special Linz Ref Changed'","#fada5e","linz-ref-changed.txt"],COULD_BE_STACKED:[13,"Addresses in OSM that are perfect, but the flats/units could be stacked if this is desired.","N/A. Just for statistics","#76d9a1","could-be-stacked.txt"],NEEDS_DELETE_ON_BUILDING:[14,"Addresses in OSM that have been deleted by LINZ, but are on a OSM building","Select a suburb in the tool","#fada5e","needs-delete-on-building.txt"],REPLACED_BY_BUILDING:[15,"Addresses in OSM that exist twice - once on a building and once on an imported node","Select a suburb in the tool","#fada5e","replaced-by-building.txt"]};var Ow={exports:{}},lL="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",cL=lL,fL=cL;function Lw(){}function Fw(){}Fw.resetWarningCache=Lw;var dL=function(){function e(i,r,a,u,f,d){if(d!==fL){var p=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 p.name="Invariant Violation",p}}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:Fw,resetWarningCache:Lw};return n.PropTypes=n,n};Ow.exports=dL();var hL=Ow.exports;const C=Ot(hL);var pL=Object.defineProperty,gL=(e,t)=>{for(var n in t)pL(e,n,{get:t[n],enumerable:!0})},f2={};gL(f2,{assign:()=>vL,colors:()=>K3,createStringInterpolator:()=>_f,skipAnimation:()=>jw,to:()=>zw,willAdvance:()=>wf});var hf=v9(),ie=e=>y9(e,hf),pf=v9();ie.write=e=>y9(e,pf);var Vr=v9();ie.onStart=e=>y9(e,Vr);var gf=v9();ie.onFrame=e=>y9(e,gf);var mf=v9();ie.onFinish=e=>y9(e,mf);var F6=[];ie.setTimeout=(e,t)=>{const n=ie.now()+t,i=()=>{const a=F6.findIndex(u=>u.cancel==i);~a&&F6.splice(a,1),Q3-=~a?1:0},r={time:n,handler:e,cancel:i};return F6.splice(Iw(n),0,r),Q3+=1,Rw(),r};var Iw=e=>~(~F6.findIndex(t=>t.time>e)||~F6.length);ie.cancel=e=>{Vr.delete(e),gf.delete(e),mf.delete(e),hf.delete(e),pf.delete(e)};ie.sync=e=>{xl=!0,ie.batchedUpdates(e),xl=!1};ie.throttle=e=>{let t;function n(){try{e(...t)}finally{t=null}}function i(...r){t=r,ie.onStart(n)}return i.handler=e,i.cancel=()=>{Vr.delete(n),t=null},i};var yf=typeof window<"u"?window.requestAnimationFrame:()=>{};ie.use=e=>yf=e;ie.now=typeof performance<"u"?()=>performance.now():Date.now;ie.batchedUpdates=e=>e();ie.catch=console.error;ie.frameLoop="always";ie.advance=()=>{ie.frameLoop!=="demand"?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):$w()};var D3=-1,Q3=0,xl=!1;function y9(e,t){xl?(t.delete(e),e(0)):(t.add(e),Rw())}function Rw(){D3<0&&(D3=0,ie.frameLoop!=="demand"&&yf(Uw))}function mL(){D3=-1}function Uw(){~D3&&(yf(Uw),ie.batchedUpdates($w))}function $w(){const e=D3;D3=ie.now();const t=Iw(D3);if(t&&(Bw(F6.splice(0,t),n=>n.handler()),Q3-=t),!Q3){mL();return}Vr.flush(),hf.flush(e?Math.min(64,D3-e):16.667),gf.flush(),pf.flush(),mf.flush()}function v9(){let e=new Set,t=e;return{add(n){Q3+=t==e&&!e.has(n)?1:0,e.add(n)},delete(n){return Q3-=t==e&&e.has(n)?1:0,e.delete(n)},flush(n){t.size&&(e=new Set,Q3-=t.size,Bw(t,i=>i(n)&&e.add(i)),Q3+=e.size,t=e)}}}function Bw(e,t){e.forEach(n=>{try{t(n)}catch(i){ie.catch(i)}})}function bl(){}var yL=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),M1={arr:Array.isArray,obj:e=>!!e&&e.constructor.name==="Object",fun:e=>typeof e=="function",str:e=>typeof e=="string",num:e=>typeof e=="number",und:e=>e===void 0};function i3(e,t){if(M1.arr(e)){if(!M1.arr(t)||e.length!==t.length)return!1;for(let n=0;ne.forEach(t);function L2(e,t,n){if(M1.arr(e)){for(let i=0;iM1.und(e)?[]:M1.arr(e)?e:[e];function T7(e,t){if(e.size){const n=Array.from(e);e.clear(),Y1(n,t)}}var m7=(e,...t)=>T7(e,n=>n(...t)),vf=()=>typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),_f,zw,K3=null,jw=!1,wf=bl,vL=e=>{e.to&&(zw=e.to),e.now&&(ie.now=e.now),e.colors!==void 0&&(K3=e.colors),e.skipAnimation!=null&&(jw=e.skipAnimation),e.createStringInterpolator&&(_f=e.createStringInterpolator),e.requestAnimationFrame&&ie.use(e.requestAnimationFrame),e.batchedUpdates&&(ie.batchedUpdates=e.batchedUpdates),e.willAdvance&&(wf=e.willAdvance),e.frameLoop&&(ie.frameLoop=e.frameLoop)},P7=new Set,R4=[],Ks=[],nr=0,Yr={get idle(){return!P7.size&&!R4.length},start(e){nr>e.priority?(P7.add(e),ie.onStart(_L)):(Dw(e),ie(Sl))},advance:Sl,sort(e){if(nr)ie.onFrame(()=>Yr.sort(e));else{const t=R4.indexOf(e);~t&&(R4.splice(t,1),Qw(e))}},clear(){R4=[],P7.clear()}};function _L(){P7.forEach(Dw),P7.clear(),ie(Sl)}function Dw(e){R4.includes(e)||Qw(e)}function Qw(e){R4.splice(wL(R4,t=>t.priority>e.priority),0,e)}function Sl(e){const t=Ks;for(let n=0;n0}function wL(e,t){const n=e.findIndex(t);return n<0?e.length:n}var xL=(e,t,n)=>Math.min(Math.max(n,e),t),bL={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},s2="[-+]?\\d*\\.?\\d+",ir=s2+"%";function Xr(...e){return"\\(\\s*("+e.join(")\\s*,\\s*(")+")\\s*\\)"}var SL=new RegExp("rgb"+Xr(s2,s2,s2)),EL=new RegExp("rgba"+Xr(s2,s2,s2,s2)),ML=new RegExp("hsl"+Xr(s2,ir,ir)),AL=new RegExp("hsla"+Xr(s2,ir,ir,s2)),kL=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,TL=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,PL=/^#([0-9a-fA-F]{6})$/,CL=/^#([0-9a-fA-F]{8})$/;function NL(e){let t;return typeof e=="number"?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=PL.exec(e))?parseInt(t[1]+"ff",16)>>>0:K3&&K3[e]!==void 0?K3[e]:(t=SL.exec(e))?(i6(t[1])<<24|i6(t[2])<<16|i6(t[3])<<8|255)>>>0:(t=EL.exec(e))?(i6(t[1])<<24|i6(t[2])<<16|i6(t[3])<<8|Sg(t[4]))>>>0:(t=kL.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=CL.exec(e))?parseInt(t[1],16)>>>0:(t=TL.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=ML.exec(e))?(xg(bg(t[1]),Zi(t[2]),Zi(t[3]))|255)>>>0:(t=AL.exec(e))?(xg(bg(t[1]),Zi(t[2]),Zi(t[3]))|Sg(t[4]))>>>0:null}function Js(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function xg(e,t,n){const i=n<.5?n*(1+t):n+t-n*t,r=2*n-i,a=Js(r,i,e+1/3),u=Js(r,i,e),f=Js(r,i,e-1/3);return Math.round(a*255)<<24|Math.round(u*255)<<16|Math.round(f*255)<<8}function i6(e){const t=parseInt(e,10);return t<0?0:t>255?255:t}function bg(e){return(parseFloat(e)%360+360)%360/360}function Sg(e){const t=parseFloat(e);return t<0?0:t>1?255:Math.round(t*255)}function Zi(e){const t=parseFloat(e);return t<0?0:t>100?1:t/100}function Eg(e){let t=NL(e);if(t===null)return e;t=t||0;const n=(t&4278190080)>>>24,i=(t&16711680)>>>16,r=(t&65280)>>>8,a=(t&255)/255;return`rgba(${n}, ${i}, ${r}, ${a})`}var V7=(e,t,n)=>{if(M1.fun(e))return e;if(M1.arr(e))return V7({range:e,output:t,extrapolate:n});if(M1.str(e.output[0]))return _f(e);const i=e,r=i.output,a=i.range||[0,1],u=i.extrapolateLeft||i.extrapolate||"extend",f=i.extrapolateRight||i.extrapolate||"extend",d=i.easing||(p=>p);return p=>{const m=LL(p,a);return OL(p,a[m],a[m+1],r[m],r[m+1],d,u,f,i.map)}};function OL(e,t,n,i,r,a,u,f,d){let p=d?d(e):e;if(pn){if(f==="identity")return p;f==="clamp"&&(p=n)}return i===r?i:t===n?e<=t?i:r:(t===-1/0?p=-p:n===1/0?p=p-t:p=(p-t)/(n-t),p=a(p),i===-1/0?p=-p:r===1/0?p=p+i:p=p*(r-i)+i,p)}function LL(e,t){for(var n=1;n=e);++n);return n-1}var FL=(e,t="end")=>n=>{n=t==="end"?Math.min(n,.999):Math.max(n,.001);const i=n*e,r=t==="end"?Math.floor(i):Math.ceil(i);return xL(0,1,r/e)},rr=1.70158,Gi=rr*1.525,Mg=rr+1,Ag=2*Math.PI/3,kg=2*Math.PI/4.5,qi=e=>e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375,IL={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>1-(1-e)*(1-e),easeInOutQuad:e=>e<.5?2*e*e:1-Math.pow(-2*e+2,2)/2,easeInCubic:e=>e*e*e,easeOutCubic:e=>1-Math.pow(1-e,3),easeInOutCubic:e=>e<.5?4*e*e*e:1-Math.pow(-2*e+2,3)/2,easeInQuart:e=>e*e*e*e,easeOutQuart:e=>1-Math.pow(1-e,4),easeInOutQuart:e=>e<.5?8*e*e*e*e:1-Math.pow(-2*e+2,4)/2,easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>1-Math.pow(1-e,5),easeInOutQuint:e=>e<.5?16*e*e*e*e*e:1-Math.pow(-2*e+2,5)/2,easeInSine:e=>1-Math.cos(e*Math.PI/2),easeOutSine:e=>Math.sin(e*Math.PI/2),easeInOutSine:e=>-(Math.cos(Math.PI*e)-1)/2,easeInExpo:e=>e===0?0:Math.pow(2,10*e-10),easeOutExpo:e=>e===1?1:1-Math.pow(2,-10*e),easeInOutExpo:e=>e===0?0:e===1?1:e<.5?Math.pow(2,20*e-10)/2:(2-Math.pow(2,-20*e+10))/2,easeInCirc:e=>1-Math.sqrt(1-Math.pow(e,2)),easeOutCirc:e=>Math.sqrt(1-Math.pow(e-1,2)),easeInOutCirc:e=>e<.5?(1-Math.sqrt(1-Math.pow(2*e,2)))/2:(Math.sqrt(1-Math.pow(-2*e+2,2))+1)/2,easeInBack:e=>Mg*e*e*e-rr*e*e,easeOutBack:e=>1+Mg*Math.pow(e-1,3)+rr*Math.pow(e-1,2),easeInOutBack:e=>e<.5?Math.pow(2*e,2)*((Gi+1)*2*e-Gi)/2:(Math.pow(2*e-2,2)*((Gi+1)*(e*2-2)+Gi)+2)/2,easeInElastic:e=>e===0?0:e===1?1:-Math.pow(2,10*e-10)*Math.sin((e*10-10.75)*Ag),easeOutElastic:e=>e===0?0:e===1?1:Math.pow(2,-10*e)*Math.sin((e*10-.75)*Ag)+1,easeInOutElastic:e=>e===0?0:e===1?1:e<.5?-(Math.pow(2,20*e-10)*Math.sin((20*e-11.125)*kg))/2:Math.pow(2,-20*e+10)*Math.sin((20*e-11.125)*kg)/2+1,easeInBounce:e=>1-qi(1-e),easeOutBounce:qi,easeInOutBounce:e=>e<.5?(1-qi(1-2*e))/2:(1+qi(2*e-1))/2,steps:FL},Y7=Symbol.for("FluidValue.get"),Z6=Symbol.for("FluidValue.observers"),I4=e=>!!(e&&e[Y7]),Jt=e=>e&&e[Y7]?e[Y7]():e,Tg=e=>e[Z6]||null;function RL(e,t){e.eventObserved?e.eventObserved(t):e(t)}function X7(e,t){const n=e[Z6];n&&n.forEach(i=>{RL(i,t)})}var Ww=class{constructor(e){if(!e&&!(e=this.get))throw Error("Unknown getter");UL(this,e)}},UL=(e,t)=>Hw(e,Y7,t);function t0(e,t){if(e[Y7]){let n=e[Z6];n||Hw(e,Z6,n=new Set),n.has(t)||(n.add(t),e.observerAdded&&e.observerAdded(n.size,t))}return t}function K7(e,t){const n=e[Z6];if(n&&n.has(t)){const i=n.size-1;i?n.delete(t):e[Z6]=null,e.observerRemoved&&e.observerRemoved(i,t)}}var Hw=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),S8=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,$L=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Pg=new RegExp(`(${S8.source})(%|[a-z]+)`,"i"),BL=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,Kr=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,Zw=e=>{const[t,n]=zL(e);if(!t||vf())return e;const i=window.getComputedStyle(document.documentElement).getPropertyValue(t);if(i)return i.trim();if(n&&n.startsWith("--")){const r=window.getComputedStyle(document.documentElement).getPropertyValue(n);return r||e}else{if(n&&Kr.test(n))return Zw(n);if(n)return n}return e},zL=e=>{const t=Kr.exec(e);if(!t)return[,];const[,n,i]=t;return[n,i]},eu,jL=(e,t,n,i,r)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(i)}, ${r})`,Gw=e=>{eu||(eu=K3?new RegExp(`(${Object.keys(K3).join("|")})(?!\\w)`,"g"):/^\b$/);const t=e.output.map(a=>Jt(a).replace(Kr,Zw).replace($L,Eg).replace(eu,Eg)),n=t.map(a=>a.match(S8).map(Number)),r=n[0].map((a,u)=>n.map(f=>{if(!(u in f))throw Error('The arity of each "output" value must be equal');return f[u]})).map(a=>V7({...e,output:a}));return a=>{var d;const u=!Pg.test(t[0])&&((d=t.find(p=>Pg.test(p)))==null?void 0:d.replace(S8,""));let f=0;return t[0].replace(S8,()=>`${r[f++](a)}${u||""}`).replace(BL,jL)}},xf="react-spring: ",qw=e=>{const t=e;let n=!1;if(typeof t!="function")throw new TypeError(`${xf}once requires a function parameter`);return(...i)=>{n||(t(...i),n=!0)}},DL=qw(console.warn);function QL(){DL(`${xf}The "interpolate" function is deprecated in v9 (use "to" instead)`)}var WL=qw(console.warn);function HL(){WL(`${xf}Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions`)}function Jr(e){return M1.str(e)&&(e[0]=="#"||/\d/.test(e)||!vf()&&Kr.test(e)||e in(K3||{}))}var Gn=vf()?G.useEffect:G.useLayoutEffect,ZL=()=>{const e=G.useRef(!1);return Gn(()=>(e.current=!0,()=>{e.current=!1}),[]),e};function bf(){const e=G.useState()[1],t=ZL();return()=>{t.current&&e(Math.random())}}function GL(e,t){const[n]=G.useState(()=>({inputs:t,result:e()})),i=G.useRef(),r=i.current;let a=r;return a?t&&a.inputs&&qL(t,a.inputs)||(a={inputs:t,result:e()}):a=n,G.useEffect(()=>{i.current=a,r==n&&(n.inputs=n.result=void 0)},[a]),a.result}function qL(e,t){if(e.length!==t.length)return!1;for(let n=0;nG.useEffect(e,VL),VL=[];function El(e){const t=G.useRef();return G.useEffect(()=>{t.current=e}),t.current}var J7=Symbol.for("Animated:node"),YL=e=>!!e&&e[J7]===e,A2=e=>e&&e[J7],Ef=(e,t)=>yL(e,J7,t),eo=e=>e&&e[J7]&&e[J7].getPayload(),Vw=class{constructor(){Ef(this,this)}getPayload(){return this.payload||[]}},_9=class extends Vw{constructor(e){super(),this._value=e,this.done=!0,this.durationProgress=0,M1.num(this._value)&&(this.lastPosition=this._value)}static create(e){return new _9(e)}getPayload(){return[this]}getValue(){return this._value}setValue(e,t){return M1.num(e)&&(this.lastPosition=e,t&&(e=Math.round(e/t)*t,this.done&&(this.lastPosition=e))),this._value===e?!1:(this._value=e,!0)}reset(){const{done:e}=this;this.done=!1,M1.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,e&&(this.lastVelocity=null),this.v0=null)}},e9=class extends _9{constructor(e){super(0),this._string=null,this._toString=V7({output:[e,e]})}static create(e){return new e9(e)}getValue(){const e=this._string;return e??(this._string=this._toString(this._value))}setValue(e){if(M1.str(e)){if(e==this._string)return!1;this._string=e,this._value=1}else if(super.setValue(e))this._string=null;else return!1;return!0}reset(e){e&&(this._toString=V7({output:[this.getValue(),e]})),this._value=0,super.reset()}},or={dependencies:null},to=class extends Vw{constructor(e){super(),this.source=e,this.setValue(e)}getValue(e){const t={};return L2(this.source,(n,i)=>{YL(n)?t[i]=n.getValue(e):I4(n)?t[i]=Jt(n):e||(t[i]=n)}),t}setValue(e){this.source=e,this.payload=this._makePayload(e)}reset(){this.payload&&Y1(this.payload,e=>e.reset())}_makePayload(e){if(e){const t=new Set;return L2(e,this._addToPayload,t),Array.from(t)}}_addToPayload(e){or.dependencies&&I4(e)&&or.dependencies.add(e);const t=eo(e);t&&Y1(t,n=>this.add(n))}},Yw=class extends to{constructor(e){super(e)}static create(e){return new Yw(e)}getValue(){return this.source.map(e=>e.getValue())}setValue(e){const t=this.getPayload();return e.length==t.length?t.map((n,i)=>n.setValue(e[i])).some(Boolean):(super.setValue(e.map(XL)),!0)}};function XL(e){return(Jr(e)?e9:_9).create(e)}function Ml(e){const t=A2(e);return t?t.constructor:M1.arr(e)?Yw:Jr(e)?e9:_9}var Cg=(e,t)=>{const n=!M1.fun(e)||e.prototype&&e.prototype.isReactComponent;return G.forwardRef((i,r)=>{const a=G.useRef(null),u=n&&G.useCallback(E=>{a.current=eF(r,E)},[r]),[f,d]=JL(i,t),p=bf(),m=()=>{const E=a.current;if(n&&!E)return;(E?t.applyAnimatedValues(E,f.getValue(!0)):!1)===!1&&p()},h=new KL(m,d),v=G.useRef();Gn(()=>(v.current=h,Y1(d,E=>t0(E,h)),()=>{v.current&&(Y1(v.current.deps,E=>K7(E,v.current)),ie.cancel(v.current.update))})),G.useEffect(m,[]),Sf(()=>()=>{const E=v.current;Y1(E.deps,k=>K7(k,E))});const S=t.getComponentProps(f.getValue());return G.createElement(e,{...S,ref:u})})},KL=class{constructor(e,t){this.update=e,this.deps=t}eventObserved(e){e.type=="change"&&ie.write(this.update)}};function JL(e,t){const n=new Set;return or.dependencies=n,e.style&&(e={...e,style:t.createAnimatedStyle(e.style)}),e=new to(e),or.dependencies=null,[e,n]}function eF(e,t){return e&&(M1.fun(e)?e(t):e.current=t),t}var Ng=Symbol.for("AnimatedComponent"),tF=(e,{applyAnimatedValues:t=()=>!1,createAnimatedStyle:n=r=>new to(r),getComponentProps:i=r=>r}={})=>{const r={applyAnimatedValues:t,createAnimatedStyle:n,getComponentProps:i},a=u=>{const f=Og(u)||"Anonymous";return M1.str(u)?u=a[u]||(a[u]=Cg(u,r)):u=u[Ng]||(u[Ng]=Cg(u,r)),u.displayName=`Animated(${f})`,u};return L2(e,(u,f)=>{M1.arr(e)&&(f=Og(u)),a[f]=a(u)}),{animated:a}},Og=e=>M1.str(e)?e:e&&M1.str(e.displayName)?e.displayName:M1.fun(e)&&e.name||null;function e4(e,...t){return M1.fun(e)?e(...t):e}var C7=(e,t)=>e===!0||!!(t&&e&&(M1.fun(e)?e(t):Qt(e).includes(t))),Xw=(e,t)=>M1.obj(e)?t&&e[t]:e,Kw=(e,t)=>e.default===!0?e[t]:e.default?e.default[t]:void 0,nF=e=>e,no=(e,t=nF)=>{let n=iF;e.default&&e.default!==!0&&(e=e.default,n=Object.keys(e));const i={};for(const r of n){const a=t(e[r],r);M1.und(a)||(i[r]=a)}return i},iF=["config","onProps","onStart","onChange","onPause","onResume","onRest"],rF={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function oF(e){const t={};let n=0;if(L2(e,(i,r)=>{rF[r]||(t[r]=i,n++)}),n)return t}function Mf(e){const t=oF(e);if(t){const n={to:t};return L2(e,(i,r)=>r in t||(n[r]=i)),n}return{...e}}function t9(e){return e=Jt(e),M1.arr(e)?e.map(t9):Jr(e)?f2.createStringInterpolator({range:[0,1],output:[e,e]})(1):e}function Jw(e){for(const t in e)return!0;return!1}function Al(e){return M1.fun(e)||M1.arr(e)&&M1.obj(e[0])}function kl(e,t){var n;(n=e.ref)==null||n.delete(e),t==null||t.delete(e)}function ex(e,t){var n;t&&e.ref!==t&&((n=e.ref)==null||n.delete(e),t.add(e),e.ref=t)}var Af={default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}},Tl={...Af.default,mass:1,damping:1,easing:IL.linear,clamp:!1},aF=class{constructor(){this.velocity=0,Object.assign(this,Tl)}};function sF(e,t,n){n&&(n={...n},Lg(n,t),t={...n,...t}),Lg(e,t),Object.assign(e,t);for(const u in Tl)e[u]==null&&(e[u]=Tl[u]);let{frequency:i,damping:r}=e;const{mass:a}=e;return M1.und(i)||(i<.01&&(i=.01),r<0&&(r=0),e.tension=Math.pow(2*Math.PI/i,2)*a,e.friction=4*Math.PI*r*a/i),e}function Lg(e,t){if(!M1.und(t.decay))e.duration=void 0;else{const n=!M1.und(t.tension)||!M1.und(t.friction);(n||!M1.und(t.frequency)||!M1.und(t.damping)||!M1.und(t.mass))&&(e.duration=void 0,e.decay=void 0),n&&(e.frequency=void 0)}}var Fg=[],uF=class{constructor(){this.changed=!1,this.values=Fg,this.toValues=null,this.fromValues=Fg,this.config=new aF,this.immediate=!1}};function tx(e,{key:t,props:n,defaultProps:i,state:r,actions:a}){return new Promise((u,f)=>{let d,p,m=C7(n.cancel??(i==null?void 0:i.cancel),t);if(m)S();else{M1.und(n.pause)||(r.paused=C7(n.pause,t));let E=i==null?void 0:i.pause;E!==!0&&(E=r.paused||C7(E,t)),d=e4(n.delay||0,t),E?(r.resumeQueue.add(v),a.pause()):(a.resume(),v())}function h(){r.resumeQueue.add(v),r.timeouts.delete(p),p.cancel(),d=p.time-ie.now()}function v(){d>0&&!f2.skipAnimation?(r.delayed=!0,p=ie.setTimeout(S,d),r.pauseQueue.add(h),r.timeouts.add(p)):S()}function S(){r.delayed&&(r.delayed=!1),r.pauseQueue.delete(h),r.timeouts.delete(p),e<=(r.cancelId||0)&&(m=!0);try{a.start({...n,callId:e,cancel:m},u)}catch(E){f(E)}}})}var kf=(e,t)=>t.length==1?t[0]:t.some(n=>n.cancelled)?I6(e.get()):t.every(n=>n.noop)?nx(e.get()):r2(e.get(),t.every(n=>n.finished)),nx=e=>({value:e,noop:!0,finished:!0,cancelled:!1}),r2=(e,t,n=!1)=>({value:e,finished:t,cancelled:n}),I6=e=>({value:e,cancelled:!0,finished:!1});function ix(e,t,n,i){const{callId:r,parentId:a,onRest:u}=t,{asyncTo:f,promise:d}=n;return!a&&e===f&&!t.reset?d:n.promise=(async()=>{n.asyncId=r,n.asyncTo=e;const p=no(t,(O,x)=>x==="onRest"?void 0:O);let m,h;const v=new Promise((O,x)=>(m=O,h=x)),S=O=>{const x=r<=(n.cancelId||0)&&I6(i)||r!==n.asyncId&&r2(i,!1);if(x)throw O.result=x,h(O),O},E=(O,x)=>{const w=new Ig,b=new Rg;return(async()=>{if(f2.skipAnimation)throw n9(n),b.result=r2(i,!1),h(b),b;S(w);const N=M1.obj(O)?{...O}:{...x,to:O};N.parentId=r,L2(p,(I,j)=>{M1.und(N[j])&&(N[j]=I)});const $=await i.start(N);return S(w),n.paused&&await new Promise(I=>{n.resumeQueue.add(I)}),$})()};let k;if(f2.skipAnimation)return n9(n),r2(i,!1);try{let O;M1.arr(e)?O=(async x=>{for(const w of x)await E(w)})(e):O=Promise.resolve(e(E,i.stop.bind(i))),await Promise.all([O.then(m),v]),k=r2(i.get(),!0,!1)}catch(O){if(O instanceof Ig)k=O.result;else if(O instanceof Rg)k=O.result;else throw O}finally{r==n.asyncId&&(n.asyncId=a,n.asyncTo=a?f:void 0,n.promise=a?d:void 0)}return M1.fun(u)&&ie.batchedUpdates(()=>{u(k,i,i.item)}),k})()}function n9(e,t){T7(e.timeouts,n=>n.cancel()),e.pauseQueue.clear(),e.resumeQueue.clear(),e.asyncId=e.asyncTo=e.promise=void 0,t&&(e.cancelId=t)}var Ig=class extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise.")}},Rg=class extends Error{constructor(){super("SkipAnimationSignal")}},Pl=e=>e instanceof Tf,lF=1,Tf=class extends Ww{constructor(){super(...arguments),this.id=lF++,this._priority=0}get priority(){return this._priority}set priority(e){this._priority!=e&&(this._priority=e,this._onPriorityChange(e))}get(){const e=A2(this);return e&&e.getValue()}to(...e){return f2.to(this,e)}interpolate(...e){return QL(),f2.to(this,e)}toJSON(){return this.get()}observerAdded(e){e==1&&this._attach()}observerRemoved(e){e==0&&this._detach()}_attach(){}_detach(){}_onChange(e,t=!1){X7(this,{type:"change",parent:this,value:e,idle:t})}_onPriorityChange(e){this.idle||Yr.sort(this),X7(this,{type:"priority",parent:this,priority:e})}},c5=Symbol.for("SpringPhase"),rx=1,Cl=2,Nl=4,tu=e=>(e[c5]&rx)>0,I3=e=>(e[c5]&Cl)>0,i7=e=>(e[c5]&Nl)>0,Ug=(e,t)=>t?e[c5]|=Cl|rx:e[c5]&=~Cl,$g=(e,t)=>t?e[c5]|=Nl:e[c5]&=~Nl,cF=class extends Tf{constructor(e,t){if(super(),this.animation=new uF,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!M1.und(e)||!M1.und(t)){const n=M1.obj(e)?{...e}:{...t,from:e};M1.und(n.default)&&(n.default=!0),this.start(n)}}get idle(){return!(I3(this)||this._state.asyncTo)||i7(this)}get goal(){return Jt(this.animation.to)}get velocity(){const e=A2(this);return e instanceof _9?e.lastVelocity||0:e.getPayload().map(t=>t.lastVelocity||0)}get hasAnimated(){return tu(this)}get isAnimating(){return I3(this)}get isPaused(){return i7(this)}get isDelayed(){return this._state.delayed}advance(e){let t=!0,n=!1;const i=this.animation;let{toValues:r}=i;const{config:a}=i,u=eo(i.to);!u&&I4(i.to)&&(r=Qt(Jt(i.to))),i.values.forEach((p,m)=>{if(p.done)return;const h=p.constructor==e9?1:u?u[m].lastPosition:r[m];let v=i.immediate,S=h;if(!v){if(S=p.lastPosition,a.tension<=0){p.done=!0;return}let E=p.elapsedTime+=e;const k=i.fromValues[m],O=p.v0!=null?p.v0:p.v0=M1.arr(a.velocity)?a.velocity[m]:a.velocity;let x;const w=a.precision||(k==h?.005:Math.min(1,Math.abs(h-k)*.001));if(M1.und(a.duration))if(a.decay){const b=a.decay===!0?.998:a.decay,N=Math.exp(-(1-b)*E);S=k+O/(1-b)*(1-N),v=Math.abs(p.lastPosition-S)<=w,x=O*N}else{x=p.lastVelocity==null?O:p.lastVelocity;const b=a.restVelocity||w/10,N=a.clamp?0:a.bounce,$=!M1.und(N),I=k==h?p.v0>0:kb,!(!j&&(v=Math.abs(h-S)<=w,v)));++D){$&&(B=S==h||S>h==I,B&&(x=-x*N,S=h));const J=-a.tension*1e-6*(S-h),e1=-a.friction*.001*x,o1=(J+e1)/a.mass;x=x+o1*Y,S=S+x*Y}}else{let b=1;a.duration>0&&(this._memoizedDuration!==a.duration&&(this._memoizedDuration=a.duration,p.durationProgress>0&&(p.elapsedTime=a.duration*p.durationProgress,E=p.elapsedTime+=e)),b=(a.progress||0)+E/this._memoizedDuration,b=b>1?1:b<0?0:b,p.durationProgress=b),S=k+a.easing(b)*(h-k),x=(S-p.lastPosition)/e,v=b==1}p.lastVelocity=x,Number.isNaN(S)&&(console.warn("Got NaN while animating:",this),v=!0)}u&&!u[m].done&&(v=!1),v?p.done=!0:t=!1,p.setValue(S,a.round)&&(n=!0)});const f=A2(this),d=f.getValue();if(t){const p=Jt(i.to);(d!==p||n)&&!a.decay?(f.setValue(p),this._onChange(p)):n&&a.decay&&this._onChange(d),this._stop()}else n&&this._onChange(d)}set(e){return ie.batchedUpdates(()=>{this._stop(),this._focus(e),this._set(e)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(I3(this)){const{to:e,config:t}=this.animation;ie.batchedUpdates(()=>{this._onStart(),t.decay||this._set(e,!1),this._stop()})}return this}update(e){return(this.queue||(this.queue=[])).push(e),this}start(e,t){let n;return M1.und(e)?(n=this.queue||[],this.queue=[]):n=[M1.obj(e)?e:{...t,to:e}],Promise.all(n.map(i=>this._update(i))).then(i=>kf(this,i))}stop(e){const{to:t}=this.animation;return this._focus(this.get()),n9(this._state,e&&this._lastCallId),ie.batchedUpdates(()=>this._stop(t,e)),this}reset(){this._update({reset:!0})}eventObserved(e){e.type=="change"?this._start():e.type=="priority"&&(this.priority=e.priority+1)}_prepareNode(e){const t=this.key||"";let{to:n,from:i}=e;n=M1.obj(n)?n[t]:n,(n==null||Al(n))&&(n=void 0),i=M1.obj(i)?i[t]:i,i==null&&(i=void 0);const r={to:n,from:i};return tu(this)||(e.reverse&&([n,i]=[i,n]),i=Jt(i),M1.und(i)?A2(this)||this._set(n):this._set(i)),r}_update({...e},t){const{key:n,defaultProps:i}=this;e.default&&Object.assign(i,no(e,(u,f)=>/^on/.test(f)?Xw(u,n):u)),zg(this,e,"onProps"),o7(this,"onProps",e,this);const r=this._prepareNode(e);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");const a=this._state;return tx(++this._lastCallId,{key:n,props:e,defaultProps:i,state:a,actions:{pause:()=>{i7(this)||($g(this,!0),m7(a.pauseQueue),o7(this,"onPause",r2(this,r7(this,this.animation.to)),this))},resume:()=>{i7(this)&&($g(this,!1),I3(this)&&this._resume(),m7(a.resumeQueue),o7(this,"onResume",r2(this,r7(this,this.animation.to)),this))},start:this._merge.bind(this,r)}}).then(u=>{if(e.loop&&u.finished&&!(t&&u.noop)){const f=ox(e);if(f)return this._update(f,!0)}return u})}_merge(e,t,n){if(t.cancel)return this.stop(!0),n(I6(this));const i=!M1.und(e.to),r=!M1.und(e.from);if(i||r)if(t.callId>this._lastToId)this._lastToId=t.callId;else return n(I6(this));const{key:a,defaultProps:u,animation:f}=this,{to:d,from:p}=f;let{to:m=d,from:h=p}=e;r&&!i&&(!t.default||M1.und(m))&&(m=h),t.reverse&&([m,h]=[h,m]);const v=!i3(h,p);v&&(f.from=h),h=Jt(h);const S=!i3(m,d);S&&this._focus(m);const E=Al(t.to),{config:k}=f,{decay:O,velocity:x}=k;(i||r)&&(k.velocity=0),t.config&&!E&&sF(k,e4(t.config,a),t.config!==u.config?e4(u.config,a):void 0);let w=A2(this);if(!w||M1.und(m))return n(r2(this,!0));const b=M1.und(t.reset)?r&&!t.default:!M1.und(h)&&C7(t.reset,a),N=b?h:this.get(),$=t9(m),I=M1.num($)||M1.arr($)||Jr($),j=!E&&(!I||C7(u.immediate||t.immediate,a));if(S){const D=Ml(m);if(D!==w.constructor)if(j)w=this._set($);else throw Error(`Cannot animate between ${w.constructor.name} and ${D.name}, as the "to" prop suggests`)}const B=w.constructor;let Y=I4(m),H=!1;if(!Y){const D=b||!tu(this)&&v;(S||D)&&(H=i3(t9(N),$),Y=!H),(!i3(f.immediate,j)&&!j||!i3(k.decay,O)||!i3(k.velocity,x))&&(Y=!0)}if(H&&I3(this)&&(f.changed&&!b?Y=!0:Y||this._stop(d)),!E&&((Y||I4(d))&&(f.values=w.getPayload(),f.toValues=I4(m)?null:B==e9?[1]:Qt($)),f.immediate!=j&&(f.immediate=j,!j&&!b&&this._set(d)),Y)){const{onRest:D}=f;Y1(dF,e1=>zg(this,t,e1));const J=r2(this,r7(this,d));m7(this._pendingCalls,J),this._pendingCalls.add(n),f.changed&&ie.batchedUpdates(()=>{var e1;f.changed=!b,D==null||D(J,this),b?e4(u.onRest,J):(e1=f.onStart)==null||e1.call(f,J,this)})}b&&this._set(N),E?n(ix(t.to,t,this._state,this)):Y?this._start():I3(this)&&!S?this._pendingCalls.add(n):n(nx(N))}_focus(e){const t=this.animation;e!==t.to&&(Tg(this)&&this._detach(),t.to=e,Tg(this)&&this._attach())}_attach(){let e=0;const{to:t}=this.animation;I4(t)&&(t0(t,this),Pl(t)&&(e=t.priority+1)),this.priority=e}_detach(){const{to:e}=this.animation;I4(e)&&K7(e,this)}_set(e,t=!0){const n=Jt(e);if(!M1.und(n)){const i=A2(this);if(!i||!i3(n,i.getValue())){const r=Ml(n);!i||i.constructor!=r?Ef(this,r.create(n)):i.setValue(n),i&&ie.batchedUpdates(()=>{this._onChange(n,t)})}}return A2(this)}_onStart(){const e=this.animation;e.changed||(e.changed=!0,o7(this,"onStart",r2(this,r7(this,e.to)),this))}_onChange(e,t){t||(this._onStart(),e4(this.animation.onChange,e,this)),e4(this.defaultProps.onChange,e,this),super._onChange(e,t)}_start(){const e=this.animation;A2(this).reset(Jt(e.to)),e.immediate||(e.fromValues=e.values.map(t=>t.lastPosition)),I3(this)||(Ug(this,!0),i7(this)||this._resume())}_resume(){f2.skipAnimation?this.finish():Yr.start(this)}_stop(e,t){if(I3(this)){Ug(this,!1);const n=this.animation;Y1(n.values,r=>{r.done=!0}),n.toValues&&(n.onChange=n.onPause=n.onResume=void 0),X7(this,{type:"idle",parent:this});const i=t?I6(this.get()):r2(this.get(),r7(this,e??n.to));m7(this._pendingCalls,i),n.changed&&(n.changed=!1,o7(this,"onRest",i,this))}}};function r7(e,t){const n=t9(t),i=t9(e.get());return i3(i,n)}function ox(e,t=e.loop,n=e.to){const i=e4(t);if(i){const r=i!==!0&&Mf(i),a=(r||e).reverse,u=!r||r.reset;return i9({...e,loop:t,default:!1,pause:void 0,to:!a||Al(n)?n:void 0,from:u?e.from:void 0,reset:u,...r})}}function i9(e){const{to:t,from:n}=e=Mf(e),i=new Set;return M1.obj(t)&&Bg(t,i),M1.obj(n)&&Bg(n,i),e.keys=i.size?Array.from(i):null,e}function fF(e){const t=i9(e);return M1.und(t.default)&&(t.default=no(t)),t}function Bg(e,t){L2(e,(n,i)=>n!=null&&t.add(i))}var dF=["onStart","onRest","onChange","onPause","onResume"];function zg(e,t,n){e.animation[n]=t[n]!==Kw(t,n)?Xw(t[n],e.key):void 0}function o7(e,t,...n){var i,r,a,u;(r=(i=e.animation)[t])==null||r.call(i,...n),(u=(a=e.defaultProps)[t])==null||u.call(a,...n)}var hF=["onStart","onChange","onRest"],pF=1,ax=class{constructor(e,t){this.id=pF++,this.springs={},this.queue=[],this._lastAsyncId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),t&&(this._flush=t),e&&this.start({default:!0,...e})}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(e=>e.idle&&!e.isDelayed&&!e.isPaused)}get item(){return this._item}set item(e){this._item=e}get(){const e={};return this.each((t,n)=>e[n]=t.get()),e}set(e){for(const t in e){const n=e[t];M1.und(n)||this.springs[t].set(n)}}update(e){return e&&this.queue.push(i9(e)),this}start(e){let{queue:t}=this;return e?t=Qt(e).map(i9):this.queue=[],this._flush?this._flush(this,t):(fx(this,t),Ol(this,t))}stop(e,t){if(e!==!!e&&(t=e),t){const n=this.springs;Y1(Qt(t),i=>n[i].stop(!!e))}else n9(this._state,this._lastAsyncId),this.each(n=>n.stop(!!e));return this}pause(e){if(M1.und(e))this.start({pause:!0});else{const t=this.springs;Y1(Qt(e),n=>t[n].pause())}return this}resume(e){if(M1.und(e))this.start({pause:!1});else{const t=this.springs;Y1(Qt(e),n=>t[n].resume())}return this}each(e){L2(this.springs,e)}_onFrame(){const{onStart:e,onChange:t,onRest:n}=this._events,i=this._active.size>0,r=this._changed.size>0;(i&&!this._started||r&&!this._started)&&(this._started=!0,T7(e,([f,d])=>{d.value=this.get(),f(d,this,this._item)}));const a=!i&&this._started,u=r||a&&n.size?this.get():null;r&&t.size&&T7(t,([f,d])=>{d.value=u,f(d,this,this._item)}),a&&(this._started=!1,T7(n,([f,d])=>{d.value=u,f(d,this,this._item)}))}eventObserved(e){if(e.type=="change")this._changed.add(e.parent),e.idle||this._active.add(e.parent);else if(e.type=="idle")this._active.delete(e.parent);else return;ie.onFrame(this._onFrame)}};function Ol(e,t){return Promise.all(t.map(n=>sx(e,n))).then(n=>kf(e,n))}async function sx(e,t,n){const{keys:i,to:r,from:a,loop:u,onRest:f,onResolve:d}=t,p=M1.obj(t.default)&&t.default;u&&(t.loop=!1),r===!1&&(t.to=null),a===!1&&(t.from=null);const m=M1.arr(r)||M1.fun(r)?r:void 0;m?(t.to=void 0,t.onRest=void 0,p&&(p.onRest=void 0)):Y1(hF,k=>{const O=t[k];if(M1.fun(O)){const x=e._events[k];t[k]=({finished:w,cancelled:b})=>{const N=x.get(O);N?(w||(N.finished=!1),b&&(N.cancelled=!0)):x.set(O,{value:null,finished:w||!1,cancelled:b||!1})},p&&(p[k]=t[k])}});const h=e._state;t.pause===!h.paused?(h.paused=t.pause,m7(t.pause?h.pauseQueue:h.resumeQueue)):h.paused&&(t.pause=!0);const v=(i||Object.keys(e.springs)).map(k=>e.springs[k].start(t)),S=t.cancel===!0||Kw(t,"cancel")===!0;(m||S&&h.asyncId)&&v.push(tx(++e._lastAsyncId,{props:t,state:h,actions:{pause:bl,resume:bl,start(k,O){S?(n9(h,e._lastAsyncId),O(I6(e))):(k.onRest=f,O(ix(m,k,h,e)))}}})),h.paused&&await new Promise(k=>{h.resumeQueue.add(k)});const E=kf(e,await Promise.all(v));if(u&&E.finished&&!(n&&E.noop)){const k=ox(t,u,r);if(k)return fx(e,[k]),sx(e,k,!0)}return d&&ie.batchedUpdates(()=>d(E,e,e.item)),E}function Ll(e,t){const n={...e.springs};return t&&Y1(Qt(t),i=>{M1.und(i.keys)&&(i=i9(i)),M1.obj(i.to)||(i={...i,to:void 0}),cx(n,i,r=>lx(r))}),ux(e,n),n}function ux(e,t){L2(t,(n,i)=>{e.springs[i]||(e.springs[i]=n,t0(n,e))})}function lx(e,t){const n=new cF;return n.key=e,t&&t0(n,t),n}function cx(e,t,n){t.keys&&Y1(t.keys,i=>{(e[i]||(e[i]=n(i)))._prepareNode(t)})}function fx(e,t){Y1(t,n=>{cx(e.springs,n,i=>lx(i,e))})}var w9=({children:e,...t})=>{const n=G.useContext(ar),i=t.pause||!!n.pause,r=t.immediate||!!n.immediate;t=GL(()=>({pause:i,immediate:r}),[i,r]);const{Provider:a}=ar;return G.createElement(a,{value:t},e)},ar=gF(w9,{});w9.Provider=ar.Provider;w9.Consumer=ar.Consumer;function gF(e,t){return Object.assign(e,G.createContext(t)),e.Provider._context=e,e.Consumer._context=e,e}var dx=()=>{const e=[],t=function(i){HL();const r=[];return Y1(e,(a,u)=>{if(M1.und(i))r.push(a.start());else{const f=n(i,a,u);f&&r.push(a.start(f))}}),r};t.current=e,t.add=function(i){e.includes(i)||e.push(i)},t.delete=function(i){const r=e.indexOf(i);~r&&e.splice(r,1)},t.pause=function(){return Y1(e,i=>i.pause(...arguments)),this},t.resume=function(){return Y1(e,i=>i.resume(...arguments)),this},t.set=function(i){Y1(e,(r,a)=>{const u=M1.fun(i)?i(a,r):i;u&&r.set(u)})},t.start=function(i){const r=[];return Y1(e,(a,u)=>{if(M1.und(i))r.push(a.start());else{const f=this._getProps(i,a,u);f&&r.push(a.start(f))}}),r},t.stop=function(){return Y1(e,i=>i.stop(...arguments)),this},t.update=function(i){return Y1(e,(r,a)=>r.update(this._getProps(i,r,a))),this};const n=function(i,r,a){return M1.fun(i)?i(a,r):i};return t._getProps=n,t};function mF(e,t,n){const i=M1.fun(t)&&t;i&&!n&&(n=[]);const r=G.useMemo(()=>i||arguments.length==3?dx():void 0,[]),a=G.useRef(0),u=bf(),f=G.useMemo(()=>({ctrls:[],queue:[],flush(x,w){const b=Ll(x,w);return a.current>0&&!f.queue.length&&!Object.keys(b).some($=>!x.springs[$])?Ol(x,w):new Promise($=>{ux(x,b),f.queue.push(()=>{$(Ol(x,w))}),u()})}}),[]),d=G.useRef([...f.ctrls]),p=[],m=El(e)||0;G.useMemo(()=>{Y1(d.current.slice(e,m),x=>{kl(x,r),x.stop(!0)}),d.current.length=e,h(m,e)},[e]),G.useMemo(()=>{h(0,Math.min(m,e))},n);function h(x,w){for(let b=x;bLl(x,p[w])),S=G.useContext(w9),E=El(S),k=S!==E&&Jw(S);Gn(()=>{a.current++,f.ctrls=d.current;const{queue:x}=f;x.length&&(f.queue=[],Y1(x,w=>w())),Y1(d.current,(w,b)=>{r==null||r.add(w),k&&w.start({default:S});const N=p[b];N&&(ex(w,N.ref),w.ref?w.queue.push(N):w.start(N))})}),Sf(()=>()=>{Y1(f.ctrls,x=>x.stop(!0))});const O=v.map(x=>({...x}));return r?[O,r]:O}function n0(e,t){const n=M1.fun(e),[[i],r]=mF(1,n?e:[e],n?t||[]:t);return n||arguments.length==2?[i,r]:i}function hx(e,t,n){const i=M1.fun(t)&&t,{reset:r,sort:a,trail:u=0,expires:f=!0,exitBeforeEnter:d=!1,onDestroyed:p,ref:m,config:h}=i?i():t,v=G.useMemo(()=>i||arguments.length==3?dx():void 0,[]),S=Qt(e),E=[],k=G.useRef(null),O=r?null:k.current;Gn(()=>{k.current=E}),Sf(()=>(Y1(E,o1=>{v==null||v.add(o1.ctrl),o1.ctrl.ref=v}),()=>{Y1(k.current,o1=>{o1.expired&&clearTimeout(o1.expirationId),kl(o1.ctrl,v),o1.ctrl.stop(!0)})}));const x=vF(S,i?i():t,O),w=r&&k.current||[];Gn(()=>Y1(w,({ctrl:o1,item:i1,key:l1})=>{kl(o1,v),e4(p,i1,l1)}));const b=[];if(O&&Y1(O,(o1,i1)=>{o1.expired?(clearTimeout(o1.expirationId),w.push(o1)):(i1=b[i1]=x.indexOf(o1.key),~i1&&(E[i1]=o1))}),Y1(S,(o1,i1)=>{E[i1]||(E[i1]={key:x[i1],item:o1,phase:"mount",ctrl:new ax},E[i1].ctrl.item=o1)}),b.length){let o1=-1;const{leave:i1}=i?i():t;Y1(b,(l1,r1)=>{const V=O[r1];~l1?(o1=E.indexOf(V),E[o1]={...V,item:S[l1]}):i1&&E.splice(++o1,0,V)})}M1.fun(a)&&E.sort((o1,i1)=>a(o1.item,i1.item));let N=-u;const $=bf(),I=no(t),j=new Map,B=G.useRef(new Map),Y=G.useRef(!1);Y1(E,(o1,i1)=>{const l1=o1.key,r1=o1.phase,V=i?i():t;let p1,f1;const w1=e4(V.delay||0,l1);if(r1=="mount")p1=V.enter,f1="enter";else{const _1=x.indexOf(l1)<0;if(r1!="leave")if(_1)p1=V.leave,f1="leave";else if(p1=V.update)f1="update";else return;else if(!_1)p1=V.enter,f1="enter";else return}if(p1=e4(p1,o1.item,i1),p1=M1.obj(p1)?Mf(p1):{to:p1},!p1.config){const _1=h||I.config;p1.config=e4(_1,o1.item,i1,f1)}N+=u;const T1={...I,delay:w1+N,ref:m,immediate:V.immediate,reset:!1,...p1};if(f1=="enter"&&M1.und(T1.from)){const _1=i?i():t,d1=M1.und(_1.initial)||O?_1.from:_1.initial;T1.from=e4(d1,o1.item,i1)}const{onResolve:j1}=T1;T1.onResolve=_1=>{e4(j1,_1);const d1=k.current,I1=d1.find(W1=>W1.key===l1);if(I1&&!(_1.cancelled&&I1.phase!="update")&&I1.ctrl.idle){const W1=d1.every(E1=>E1.ctrl.idle);if(I1.phase=="leave"){const E1=e4(f,I1.item);if(E1!==!1){const O1=E1===!0?0:E1;if(I1.expired=!0,!W1&&O1>0){O1<=2147483647&&(I1.expirationId=setTimeout($,O1));return}}}W1&&d1.some(E1=>E1.expired)&&(B.current.delete(I1),d&&(Y.current=!0),$())}};const F1=Ll(o1.ctrl,T1);f1==="leave"&&d?B.current.set(o1,{phase:f1,springs:F1,payload:T1}):j.set(o1,{phase:f1,springs:F1,payload:T1})});const H=G.useContext(w9),D=El(H),J=H!==D&&Jw(H);Gn(()=>{J&&Y1(E,o1=>{o1.ctrl.start({default:H})})},[H]),Y1(j,(o1,i1)=>{if(B.current.size){const l1=E.findIndex(r1=>r1.key===i1.key);E.splice(l1,1)}}),Gn(()=>{Y1(B.current.size?B.current:j,({phase:o1,payload:i1},l1)=>{const{ctrl:r1}=l1;l1.phase=o1,v==null||v.add(r1),J&&o1=="enter"&&r1.start({default:H}),i1&&(ex(r1,i1.ref),(r1.ref||v)&&!Y.current?r1.update(i1):(r1.start(i1),Y.current&&(Y.current=!1)))})},r?void 0:n);const e1=o1=>G.createElement(G.Fragment,null,E.map((i1,l1)=>{const{springs:r1}=j.get(i1)||i1.ctrl,V=o1({...r1},i1.item,i1,l1);return V&&V.type?G.createElement(V.type,{...V.props,key:M1.str(i1.key)||M1.num(i1.key)?i1.key:i1.ctrl.id,ref:V.ref}):V}));return v?[e1,v]:e1}var yF=1;function vF(e,{key:t,keys:n=t},i){if(n===null){const r=new Set;return e.map(a=>{const u=i&&i.find(f=>f.item===a&&f.phase!=="leave"&&!r.has(f));return u?(r.add(u),u.key):yF++})}return M1.und(n)?e:M1.fun(n)?e.map(n):Qt(n)}var px=class extends Tf{constructor(e,t){super(),this.source=e,this.idle=!0,this._active=new Set,this.calc=V7(...t);const n=this._get(),i=Ml(n);Ef(this,i.create(n))}advance(e){const t=this._get(),n=this.get();i3(t,n)||(A2(this).setValue(t),this._onChange(t,this.idle)),!this.idle&&jg(this._active)&&nu(this)}_get(){const e=M1.arr(this.source)?this.source.map(Jt):Qt(Jt(this.source));return this.calc(...e)}_start(){this.idle&&!jg(this._active)&&(this.idle=!1,Y1(eo(this),e=>{e.done=!1}),f2.skipAnimation?(ie.batchedUpdates(()=>this.advance()),nu(this)):Yr.start(this))}_attach(){let e=1;Y1(Qt(this.source),t=>{I4(t)&&t0(t,this),Pl(t)&&(t.idle||this._active.add(t),e=Math.max(e,t.priority+1))}),this.priority=e,this._start()}_detach(){Y1(Qt(this.source),e=>{I4(e)&&K7(e,this)}),this._active.clear(),nu(this)}eventObserved(e){e.type=="change"?e.idle?this.advance():(this._active.add(e.parent),this._start()):e.type=="idle"?this._active.delete(e.parent):e.type=="priority"&&(this.priority=Qt(this.source).reduce((t,n)=>Math.max(t,(Pl(n)?n.priority:0)+1),0))}};function _F(e){return e.idle!==!1}function jg(e){return!e.size||Array.from(e).every(_F)}function nu(e){e.idle||(e.idle=!0,Y1(eo(e),t=>{t.done=!0}),X7(e,{type:"idle",parent:e}))}var wF=(e,...t)=>new px(e,t);f2.assign({createStringInterpolator:Gw,to:(e,t)=>new px(e,t)});var gx=/^--/;function xF(e,t){return t==null||typeof t=="boolean"||t===""?"":typeof t=="number"&&t!==0&&!gx.test(e)&&!(N7.hasOwnProperty(e)&&N7[e])?t+"px":(""+t).trim()}var Dg={};function bF(e,t){if(!e.nodeType||!e.setAttribute)return!1;const n=e.nodeName==="filter"||e.parentNode&&e.parentNode.nodeName==="filter",{style:i,children:r,scrollTop:a,scrollLeft:u,viewBox:f,...d}=t,p=Object.values(d),m=Object.keys(d).map(h=>n||e.hasAttribute(h)?h:Dg[h]||(Dg[h]=h.replace(/([A-Z])/g,v=>"-"+v.toLowerCase())));r!==void 0&&(e.textContent=r);for(const h in i)if(i.hasOwnProperty(h)){const v=xF(h,i[h]);gx.test(h)?e.style.setProperty(h,v):e.style[h]=v}m.forEach((h,v)=>{e.setAttribute(h,p[v])}),a!==void 0&&(e.scrollTop=a),u!==void 0&&(e.scrollLeft=u),f!==void 0&&e.setAttribute("viewBox",f)}var N7={animationIterationCount:!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,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},SF=(e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1),EF=["Webkit","Ms","Moz","O"];N7=Object.keys(N7).reduce((e,t)=>(EF.forEach(n=>e[SF(n,t)]=e[t]),e),N7);var MF=/^(matrix|translate|scale|rotate|skew)/,AF=/^(translate)/,kF=/^(rotate|skew)/,iu=(e,t)=>M1.num(e)&&e!==0?e+t:e,E8=(e,t)=>M1.arr(e)?e.every(n=>E8(n,t)):M1.num(e)?e===t:parseFloat(e)===t,TF=class extends to{constructor({x:e,y:t,z:n,...i}){const r=[],a=[];(e||t||n)&&(r.push([e||0,t||0,n||0]),a.push(u=>[`translate3d(${u.map(f=>iu(f,"px")).join(",")})`,E8(u,0)])),L2(i,(u,f)=>{if(f==="transform")r.push([u||""]),a.push(d=>[d,d===""]);else if(MF.test(f)){if(delete i[f],M1.und(u))return;const d=AF.test(f)?"px":kF.test(f)?"deg":"";r.push(Qt(u)),a.push(f==="rotate3d"?([p,m,h,v])=>[`rotate3d(${p},${m},${h},${iu(v,d)})`,E8(v,0)]:p=>[`${f}(${p.map(m=>iu(m,d)).join(",")})`,E8(p,f.startsWith("scale")?1:0)])}}),r.length&&(i.transform=new PF(r,a)),super(i)}},PF=class extends Ww{constructor(e,t){super(),this.inputs=e,this.transforms=t,this._value=null}get(){return this._value||(this._value=this._get())}_get(){let e="",t=!0;return Y1(this.inputs,(n,i)=>{const r=Jt(n[0]),[a,u]=this.transforms[i](M1.arr(r)?r:n.map(Jt));e+=" "+a,t=t&&u}),t?"none":e}observerAdded(e){e==1&&Y1(this.inputs,t=>Y1(t,n=>I4(n)&&t0(n,this)))}observerRemoved(e){e==0&&Y1(this.inputs,t=>Y1(t,n=>I4(n)&&K7(n,this)))}eventObserved(e){e.type=="change"&&(this._value=null),X7(this,e)}},CF=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"];f2.assign({batchedUpdates:df.unstable_batchedUpdates,createStringInterpolator:Gw,colors:bL});var NF=tF(CF,{applyAnimatedValues:bF,createAnimatedStyle:e=>new TF(e),getComponentProps:({scrollTop:e,scrollLeft:t,...n})=>n}),F2=NF.animated;function f5(){return f5=Object.assign?Object.assign.bind():function(e){for(var t=1;t0&&h.height>0,O=Math.round(n[0]),x=Math.round(n[1]);k&&(i==="top"?(O-=h.width/2,x-=h.height+14):i==="right"?(O+=14,x-=h.height/2):i==="bottom"?(O-=h.width/2,x+=14):i==="left"?(O-=h.width+14,x-=h.height/2):i==="center"&&(O-=h.width/2,x-=h.height/2),S={transform:Qg(O,x)},v.current||(E=!0),v.current=[O,x]);var w=n0({to:S,config:d,immediate:!f||E}),b=f5({},OF,a.tooltip,{transform:(t=w.transform)!=null?t:Qg(O,x)});return R.jsx(F2.div,{ref:m,style:b,children:r})});mx.displayName="TooltipWrapper";var yx=G.memo(function(e){var t=e.size,n=t===void 0?12:t,i=e.color,r=e.style;return R.jsx("span",{style:f5({display:"block",width:n,height:n,background:i},r===void 0?{}:r)})}),LF=G.memo(function(e){var t,n=e.id,i=e.value,r=e.format,a=e.enableChip,u=a!==void 0&&a,f=e.color,d=e.renderContent,p=Lt(),m=ic(r);if(typeof d=="function")t=d();else{var h=i;m!==void 0&&h!==void 0&&(h=m(h)),t=R.jsxs("div",{style:p.tooltip.basic,children:[u&&R.jsx(yx,{color:f,style:p.tooltip.chip}),h!==void 0?R.jsxs("span",{children:[n,": ",R.jsx("strong",{children:""+h})]}):n]})}return R.jsx("div",{style:p.tooltip.container,children:t})}),FF={width:"100%",borderCollapse:"collapse"},vx=G.memo(function(e){var t,n=e.title,i=e.rows,r=i===void 0?[]:i,a=e.renderContent,u=Lt();return r.length?(t=typeof a=="function"?a():R.jsxs("div",{children:[n&&n,R.jsx("table",{style:f5({},FF,u.tooltip.table),children:R.jsx("tbody",{children:r.map(function(f,d){return R.jsx("tr",{children:f.map(function(p,m){return R.jsx("td",{style:u.tooltip.tableCell,children:p},m)})},d)})})})]}),R.jsx("div",{style:u.tooltip.container,children:t})):null});vx.displayName="TableTooltip";var Fl=G.memo(function(e){var t=e.x0,n=e.x1,i=e.y0,r=e.y1,a=Lt(),u=S5(),f=u.animate,d=u.config,p=G.useMemo(function(){return f5({},a.crosshair.line,{pointerEvents:"none"})},[a.crosshair.line]),m=n0({x1:t,x2:n,y1:i,y2:r,config:d,immediate:!f});return R.jsx(F2.line,f5({},m,{fill:"none",style:p}))});Fl.displayName="CrosshairLine";var Il=G.memo(function(e){var t,n,i=e.width,r=e.height,a=e.type,u=e.x,f=e.y;return a==="cross"?(t={x0:u,x1:u,y0:0,y1:r},n={x0:0,x1:i,y0:f,y1:f}):a==="top-left"?(t={x0:u,x1:u,y0:0,y1:f},n={x0:0,x1:u,y0:f,y1:f}):a==="top"?t={x0:u,x1:u,y0:0,y1:f}:a==="top-right"?(t={x0:u,x1:u,y0:0,y1:f},n={x0:u,x1:i,y0:f,y1:f}):a==="right"?n={x0:u,x1:i,y0:f,y1:f}:a==="bottom-right"?(t={x0:u,x1:u,y0:f,y1:r},n={x0:u,x1:i,y0:f,y1:f}):a==="bottom"?t={x0:u,x1:u,y0:f,y1:r}:a==="bottom-left"?(t={x0:u,x1:u,y0:f,y1:r},n={x0:0,x1:u,y0:f,y1:f}):a==="left"?n={x0:0,x1:u,y0:f,y1:f}:a==="x"?t={x0:u,x1:u,y0:0,y1:r}:a==="y"&&(n={x0:0,x1:i,y0:f,y1:f}),R.jsxs(R.Fragment,{children:[t&&R.jsx(Fl,{x0:t.x0,x1:t.x1,y0:t.y0,y1:t.y1}),n&&R.jsx(Fl,{x0:n.x0,x1:n.x1,y0:n.y0,y1:n.y1})]})});Il.displayName="Crosshair";var _x=G.createContext({showTooltipAt:function(){},showTooltipFromEvent:function(){},hideTooltip:function(){}}),Rl={isVisible:!1,position:[null,null],content:null,anchor:null},wx=G.createContext(Rl),IF=function(e){var t=G.useState(Rl),n=t[0],i=t[1],r=G.useCallback(function(f,d,p){var m=d[0],h=d[1];p===void 0&&(p="top"),i({isVisible:!0,position:[m,h],anchor:p,content:f})},[i]),a=G.useCallback(function(f,d,p){p===void 0&&(p="top");var m=e.current.getBoundingClientRect(),h=e.current.offsetWidth,v=h===m.width?1:h/m.width,S=(d.clientX-m.left)*v,E=(d.clientY-m.top)*v;p!=="left"&&p!=="right"||(p=S-1}var tI=eI,nI=io;function iI(e,t){var n=this.__data__,i=nI(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}var rI=iI,oI=jF,aI=VF,sI=KF,uI=tI,lI=rI;function i0(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1&&e%1==0&&e<=x$}var If=b$,S$=oo,E$=If;function M$(e){return e!=null&&E$(e.length)&&!S$(e)}var s0=M$,A$=s0,k$=sn;function T$(e){return k$(e)&&A$(e)}var Nx=T$,ur={exports:{}};function P$(){return!1}var C$=P$;ur.exports;(function(e,t){var n=R2,i=C$,r=t&&!t.nodeType&&t,a=r&&!0&&e&&!e.nodeType&&e,u=a&&a.exports===r,f=u?n.Buffer:void 0,d=f?f.isBuffer:void 0,p=d||i;e.exports=p})(ur,ur.exports);var Rf=ur.exports,N$=v5,O$=Px,L$=sn,F$="[object Object]",I$=Function.prototype,R$=Object.prototype,Ox=I$.toString,U$=R$.hasOwnProperty,$$=Ox.call(Object);function B$(e){if(!L$(e)||N$(e)!=F$)return!1;var t=O$(e);if(t===null)return!0;var n=U$.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&Ox.call(n)==$$}var Lx=B$;const z$=Ot(Lx);var j$=v5,D$=If,Q$=sn,W$="[object Arguments]",H$="[object Array]",Z$="[object Boolean]",G$="[object Date]",q$="[object Error]",V$="[object Function]",Y$="[object Map]",X$="[object Number]",K$="[object Object]",J$="[object RegExp]",eB="[object Set]",tB="[object String]",nB="[object WeakMap]",iB="[object ArrayBuffer]",rB="[object DataView]",oB="[object Float32Array]",aB="[object Float64Array]",sB="[object Int8Array]",uB="[object Int16Array]",lB="[object Int32Array]",cB="[object Uint8Array]",fB="[object Uint8ClampedArray]",dB="[object Uint16Array]",hB="[object Uint32Array]",$e={};$e[oB]=$e[aB]=$e[sB]=$e[uB]=$e[lB]=$e[cB]=$e[fB]=$e[dB]=$e[hB]=!0;$e[W$]=$e[H$]=$e[iB]=$e[Z$]=$e[rB]=$e[G$]=$e[q$]=$e[V$]=$e[Y$]=$e[X$]=$e[K$]=$e[J$]=$e[eB]=$e[tB]=$e[nB]=!1;function pB(e){return Q$(e)&&D$(e.length)&&!!$e[j$(e)]}var gB=pB;function mB(e){return function(t){return e(t)}}var lo=mB,lr={exports:{}};lr.exports;(function(e,t){var n=xx,i=t&&!t.nodeType&&t,r=i&&!0&&e&&!e.nodeType&&e,a=r&&r.exports===i,u=a&&n.process,f=function(){try{var d=r&&r.require&&r.require("util").types;return d||u&&u.binding&&u.binding("util")}catch{}}();e.exports=f})(lr,lr.exports);var Fx=lr.exports,yB=gB,vB=lo,em=Fx,tm=em&&em.isTypedArray,_B=tm?vB(tm):yB,Uf=_B;function wB(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var Ix=wB,xB=Lf,bB=x9,SB=Object.prototype,EB=SB.hasOwnProperty;function MB(e,t,n){var i=e[t];(!(EB.call(e,t)&&bB(i,n))||n===void 0&&!(t in e))&&xB(e,t,n)}var Rx=MB,AB=Rx,kB=Lf;function TB(e,t,n,i){var r=!n;n||(n={});for(var a=-1,u=t.length;++a-1&&e%1==0&&e0){if(++t>=Bz)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Qz=Dz,Wz=$z,Hz=Qz,Zz=Hz(Wz),jx=Zz,Gz=fo,qz=zx,Vz=jx;function Yz(e,t){return Vz(qz(e,t,Gz),e+"")}var $f=Yz,Xz=x9,Kz=s0,Jz=co,ej=g3;function tj(e,t,n){if(!ej(n))return!1;var i=typeof t;return(i=="number"?Kz(n)&&Jz(t,n.length):i=="string"&&t in n)?Xz(n[t],e):!1}var Dx=tj,nj=$f,ij=Dx;function rj(e){return nj(function(t,n){var i=-1,r=n.length,a=r>1?n[r-1]:void 0,u=r>2?n[2]:void 0;for(a=e.length>3&&typeof a=="function"?(r--,a):void 0,u&&ij(n[0],n[1],u)&&(a=r<3?void 0:a,r=1),t=Object(t);++i>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Vi(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Vi(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=uD.exec(e))?new Wt(t[1],t[2],t[3],1):(t=lD.exec(e))?new Wt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=cD.exec(e))?Vi(t[1],t[2],t[3],t[4]):(t=fD.exec(e))?Vi(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=dD.exec(e))?vm(t[1],t[2]/100,t[3]/100,1):(t=hD.exec(e))?vm(t[1],t[2]/100,t[3]/100,t[4]):dm.hasOwnProperty(e)?gm(dm[e]):e==="transparent"?new Wt(NaN,NaN,NaN,0):null}function gm(e){return new Wt(e>>16&255,e>>8&255,e&255,1)}function Vi(e,t,n,i){return i<=0&&(e=t=n=NaN),new Wt(e,t,n,i)}function Gx(e){return e instanceof u0||(e=o9(e)),e?(e=e.rgb(),new Wt(e.r,e.g,e.b,e.opacity)):new Wt}function a9(e,t,n,i){return arguments.length===1?Gx(e):new Wt(e,t,n,i??1)}function Wt(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}mo(Wt,a9,Df(u0,{brighter:function(e){return e=e==null?G6:Math.pow(G6,e),new Wt(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=e==null?d5:Math.pow(d5,e),new Wt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){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:mm,formatHex:mm,formatRgb:ym,toString:ym}));function mm(){return"#"+ou(this.r)+ou(this.g)+ou(this.b)}function ym(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(e===1?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(e===1?")":", "+e+")")}function ou(e){return e=Math.max(0,Math.min(255,Math.round(e)||0)),(e<16?"0":"")+e.toString(16)}function vm(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new T2(e,t,n,i)}function qx(e){if(e instanceof T2)return new T2(e.h,e.s,e.l,e.opacity);if(e instanceof u0||(e=o9(e)),!e)return new T2;if(e instanceof T2)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,r=Math.min(t,n,i),a=Math.max(t,n,i),u=NaN,f=a-r,d=(a+r)/2;return f?(t===a?u=(n-i)/f+(n0&&d<1?0:u,new T2(u,f,d,e.opacity)}function gD(e,t,n,i){return arguments.length===1?qx(e):new T2(e,t,n,i??1)}function T2(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}mo(T2,gD,Df(u0,{brighter:function(e){return e=e==null?G6:Math.pow(G6,e),new T2(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=e==null?d5:Math.pow(d5,e),new T2(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*t,r=2*n-i;return new Wt(au(e>=240?e-240:e+120,r,i),au(e,r,i),au(e<120?e+240:e-120,r,i),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return e=isNaN(e)?1:Math.max(0,Math.min(1,e)),(e===1?"hsl(":"hsla(")+(this.h||0)+", "+(this.s||0)*100+"%, "+(this.l||0)*100+"%"+(e===1?")":", "+e+")")}}));function au(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 mD=Math.PI/180,yD=180/Math.PI;var Vx=-.14861,Qf=1.78277,Wf=-.29227,yo=-.90649,s9=1.97294,_m=s9*yo,wm=s9*Qf,xm=Qf*Wf-yo*Vx;function vD(e){if(e instanceof n5)return new n5(e.h,e.s,e.l,e.opacity);e instanceof Wt||(e=Gx(e));var t=e.r/255,n=e.g/255,i=e.b/255,r=(xm*i+_m*t-wm*n)/(xm+_m-wm),a=i-r,u=(s9*(n-r)-Wf*a)/yo,f=Math.sqrt(u*u+a*a)/(s9*r*(1-r)),d=f?Math.atan2(u,a)*yD-120:NaN;return new n5(d<0?d+360:d,f,r,e.opacity)}function I2(e,t,n,i){return arguments.length===1?vD(e):new n5(e,t,n,i??1)}function n5(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}mo(n5,I2,Df(u0,{brighter:function(e){return e=e==null?G6:Math.pow(G6,e),new n5(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=e==null?d5:Math.pow(d5,e),new n5(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*mD,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),i=Math.cos(e),r=Math.sin(e);return new Wt(255*(t+n*(Vx*i+Qf*r)),255*(t+n*(Wf*i+yo*r)),255*(t+n*(s9*i)),this.opacity)}}));function _D(e,t,n,i,r){var a=e*e,u=a*e;return((1-3*e+3*a-u)*t+(4-6*a+3*u)*n+(1+3*e+3*a-3*u)*i+u*r)/6}function wD(e){var t=e.length-1;return function(n){var i=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),r=e[i],a=e[i+1],u=i>0?e[i-1]:2*r-a,f=i()=>e;function Yx(e,t){return function(n){return e+n*t}}function xD(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(i){return Math.pow(e+i*t,n)}}function bD(e,t){var n=t-e;return n?Yx(e,n>180||n<-180?n-360*Math.round(n/360):n):vo(isNaN(e)?t:e)}function SD(e){return(e=+e)==1?U6:function(t,n){return n-t?xD(t,n,e):vo(isNaN(t)?n:t)}}function U6(e,t){var n=t-e;return n?Yx(e,n):vo(isNaN(e)?t:e)}const bm=function e(t){var n=SD(t);function i(r,a){var u=n((r=a9(r)).r,(a=a9(a)).r),f=n(r.g,a.g),d=n(r.b,a.b),p=U6(r.opacity,a.opacity);return function(m){return r.r=u(m),r.g=f(m),r.b=d(m),r.opacity=p(m),r+""}}return i.gamma=e,i}(1);function ED(e){return function(t){var n=t.length,i=new Array(n),r=new Array(n),a=new Array(n),u,f;for(u=0;un&&(a=t.slice(n,a),f[u]?f[u]+=a:f[++u]=a),(i=i[0])===(r=r[0])?f[u]?f[u]+=r:f[++u]=r:(f[++u]=null,d.push({i:u,x:cr(i,r)})),n=su.lastIndex;return n - * Copyright OpenJS Foundation and other contributors - * Released under MIT license - * Based on Underscore.js 1.8.3 - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */fr.exports;(function(e,t){(function(){var n,i="4.17.21",r=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",u="Expected a function",f="Invalid `variable` option passed into `_.template`",d="__lodash_hash_undefined__",p=500,m="__lodash_placeholder__",h=1,v=2,S=4,E=1,k=2,O=1,x=2,w=4,b=8,N=16,$=32,I=64,j=128,B=256,Y=512,H=30,D="...",J=800,e1=16,o1=1,i1=2,l1=3,r1=1/0,V=9007199254740991,p1=17976931348623157e292,f1=0/0,w1=4294967295,T1=w1-1,j1=w1>>>1,F1=[["ary",j],["bind",O],["bindKey",x],["curry",b],["curryRight",N],["flip",Y],["partial",$],["partialRight",I],["rearg",B]],_1="[object Arguments]",d1="[object Array]",I1="[object AsyncFunction]",W1="[object Boolean]",E1="[object Date]",O1="[object DOMException]",R1="[object Error]",g1="[object Function]",J1="[object GeneratorFunction]",D1="[object Map]",ae="[object Number]",we="[object Null]",pe="[object Object]",ge="[object Promise]",Qe="[object Proxy]",W="[object RegExp]",T="[object Set]",P="[object String]",Z="[object Symbol]",s1="[object Undefined]",v1="[object WeakMap]",b1="[object WeakSet]",G1="[object ArrayBuffer]",X1="[object DataView]",k1="[object Float32Array]",q1="[object Float64Array]",fe="[object Int8Array]",de="[object Int16Array]",gt="[object Int32Array]",x4="[object Uint8Array]",U2="[object Uint8ClampedArray]",Q4="[object Uint16Array]",b4="[object Uint32Array]",k5=/\b__p \+= '';/g,$2=/\b(__p \+=) '' \+/g,ln=/(__e\(.*?\)|\b__t\)) \+\n'';/g,s4=/&(?:amp|lt|gt|quot|#39);/g,cn=/[&<>"']/g,W4=RegExp(s4.source),fn=RegExp(cn.source),ua=/<%-([\s\S]+?)%>/g,la=/<%([\s\S]+?)%>/g,k9=/<%=([\s\S]+?)%>/g,ca=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,c0=/^\w*$/,fa=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,f0=/[\\^$.*+?()[\]{}|]/g,da=RegExp(f0.source),d0=/^\s+/,S4=/\s/,$1=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,T9=/\{\n\/\* \[wrapped with (.+)\] \*/,P9=/,? & /,C9=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,N9=/[()=,{}\[\]\/\s]/,h0=/\\(\\)?/g,O9=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,B2=/\w*$/,L9=/^[-+]0x[0-9a-f]+$/i,ha=/^0b[01]+$/i,pa=/^\[object .+?Constructor\]$/,ga=/^0o[0-7]+$/i,ma=/^(?:0|[1-9]\d*)$/,F9=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,T5=/($^)/,P5=/['\n\r\u2028\u2029\\]/g,C5="\\ud800-\\udfff",ya="\\u0300-\\u036f",va="\\ufe20-\\ufe2f",_a="\\u20d0-\\u20ff",I9=ya+va+_a,N5="\\u2700-\\u27bf",m3="a-z\\xdf-\\xf6\\xf8-\\xff",R9="\\xac\\xb1\\xd7\\xf7",U9="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",dn="\\u2000-\\u206f",xe=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Oe="A-Z\\xc0-\\xd6\\xd8-\\xde",hn="\\ufe0e\\ufe0f",z2=R9+U9+dn+xe,p2="['’]",p0="["+C5+"]",ee="["+z2+"]",Le="["+I9+"]",O5="\\d+",L5="["+N5+"]",Ft="["+m3+"]",$9="[^"+C5+z2+O5+N5+m3+Oe+"]",y3="\\ud83c[\\udffb-\\udfff]",j2="(?:"+Le+"|"+y3+")",We="[^"+C5+"]",H4="(?:\\ud83c[\\udde6-\\uddff]){2}",D2="[\\ud800-\\udbff][\\udc00-\\udfff]",E4="["+Oe+"]",F5="\\u200d",v3="(?:"+Ft+"|"+$9+")",g0="(?:"+E4+"|"+$9+")",I5="(?:"+p2+"(?:d|ll|m|re|s|t|ve))?",pn="(?:"+p2+"(?:D|LL|M|RE|S|T|VE))?",R5=j2+"?",U5="["+hn+"]?",$5="(?:"+F5+"(?:"+[We,H4,D2].join("|")+")"+U5+R5+")*",B9="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",m0="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",z9=U5+R5+$5,K1="(?:"+[L5,H4,D2].join("|")+")"+z9,M4="(?:"+[We+Le+"?",Le,H4,D2,p0].join("|")+")",Pe=RegExp(p2,"g"),j9=RegExp(Le,"g"),gn=RegExp(y3+"(?="+y3+")|"+M4+z9,"g"),y0=RegExp([E4+"?"+Ft+"+"+I5+"(?="+[ee,E4,"$"].join("|")+")",g0+"+"+pn+"(?="+[ee,E4+v3,"$"].join("|")+")",E4+"?"+v3+"+"+I5,E4+"+"+pn,m0,B9,O5,K1].join("|"),"g"),v0=RegExp("["+F5+C5+I9+hn+"]"),Q2=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,_0=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],mn=-1,te={};te[k1]=te[q1]=te[fe]=te[de]=te[gt]=te[x4]=te[U2]=te[Q4]=te[b4]=!0,te[_1]=te[d1]=te[G1]=te[W1]=te[X1]=te[E1]=te[R1]=te[g1]=te[D1]=te[ae]=te[pe]=te[W]=te[T]=te[P]=te[v1]=!1;var be={};be[_1]=be[d1]=be[G1]=be[X1]=be[W1]=be[E1]=be[k1]=be[q1]=be[fe]=be[de]=be[gt]=be[D1]=be[ae]=be[pe]=be[W]=be[T]=be[P]=be[Z]=be[x4]=be[U2]=be[Q4]=be[b4]=!0,be[R1]=be[g1]=be[v1]=!1;var D9={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Q9={"&":"&","<":"<",">":">",'"':""","'":"'"},wa={"&":"&","<":"<",">":">",""":'"',"'":"'"},W9={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},w0=parseFloat,xa=parseInt,x0=typeof o2=="object"&&o2&&o2.Object===Object&&o2,me=typeof self=="object"&&self&&self.Object===Object&&self,it=x0||me||Function("return this")(),It=t&&!t.nodeType&&t,u4=It&&!0&&e&&!e.nodeType&&e,b0=u4&&u4.exports===It,S0=b0&&x0.process,xt=function(){try{var t1=u4&&u4.require&&u4.require("util").types;return t1||S0&&S0.binding&&S0.binding("util")}catch{}}(),H9=xt&&xt.isArrayBuffer,E0=xt&&xt.isDate,Z9=xt&&xt.isMap,G9=xt&&xt.isRegExp,B5=xt&&xt.isSet,q9=xt&&xt.isTypedArray;function ze(t1,h1,c1){switch(c1.length){case 0:return t1.call(h1);case 1:return t1.call(h1,c1[0]);case 2:return t1.call(h1,c1[0],c1[1]);case 3:return t1.call(h1,c1[0],c1[1],c1[2])}return t1.apply(h1,c1)}function ba(t1,h1,c1,N1){for(var V1=-1,Se=t1==null?0:t1.length;++V1-1}function A0(t1,h1,c1){for(var N1=-1,V1=t1==null?0:t1.length;++N1-1;);return c1}function J9(t1,h1){for(var c1=t1.length;c1--&&w3(h1,t1[c1],0)>-1;);return c1}function x3(t1,h1){for(var c1=t1.length,N1=0;c1--;)t1[c1]===h1&&++N1;return N1}var Ma=P0(D9),xn=P0(Q9);function ei(t1){return"\\"+W9[t1]}function D5(t1,h1){return t1==null?n:t1[h1]}function b3(t1){return v0.test(t1)}function y2(t1){return Q2.test(t1)}function Q5(t1){for(var h1,c1=[];!(h1=t1.next()).done;)c1.push(h1.value);return c1}function L0(t1){var h1=-1,c1=Array(t1.size);return t1.forEach(function(N1,V1){c1[++h1]=[V1,N1]}),c1}function W5(t1,h1){return function(c1){return t1(h1(c1))}}function v2(t1,h1){for(var c1=-1,N1=t1.length,V1=0,Se=[];++c1-1}function lM(s,c){var y=this.__data__,M=si(y,s);return M<0?(++this.size,y.push([s,c])):y[M][1]=c,this}Z2.prototype.clear=oM,Z2.prototype.delete=aM,Z2.prototype.get=sM,Z2.prototype.has=uM,Z2.prototype.set=lM;function G2(s){var c=-1,y=s==null?0:s.length;for(this.clear();++c=c?s:c)),s}function P4(s,c,y,M,F,Q){var q,K=c&h,n1=c&v,m1=c&S;if(y&&(q=F?y(s,M,F,Q):y(s)),q!==n)return q;if(!He(s))return s;var y1=ne(s);if(y1){if(q=hA(s),!K)return Vt(s,q)}else{var S1=Mt(s),P1=S1==g1||S1==J1;if(L3(s))return ih(s,K);if(S1==pe||S1==_1||P1&&!F){if(q=n1||P1?{}:bh(s),!K)return n1?nA(s,MM(q,s)):tA(s,Ld(q,s))}else{if(!be[S1])return F?s:{};q=pA(s,S1,K)}}Q||(Q=new X4);var U1=Q.get(s);if(U1)return U1;Q.set(s,q),Xh(s)?s.forEach(function(Z1){q.add(P4(Z1,c,y,Z1,s,Q))}):Vh(s)&&s.forEach(function(Z1,he){q.set(he,P4(Z1,c,y,he,s,Q))});var H1=m1?n1?is:ns:n1?Xt:lt,se=y1?n:H1(s);return Rt(se||s,function(Z1,he){se&&(he=Z1,Z1=s[he]),z0(q,he,P4(Z1,c,y,he,s,Q))}),q}function AM(s){var c=lt(s);return function(y){return Fd(y,s,c)}}function Fd(s,c,y){var M=y.length;if(s==null)return!M;for(s=Ae(s);M--;){var F=y[M],Q=c[F],q=s[F];if(q===n&&!(F in s)||!Q(q))return!1}return!0}function Id(s,c,y){if(typeof s!="function")throw new mt(u);return G0(function(){s.apply(n,y)},c)}function j0(s,c,y,M){var F=-1,Q=_3,q=!0,K=s.length,n1=[],m1=c.length;if(!K)return n1;y&&(c=Ce(c,Re(y))),M?(Q=A0,q=!1):c.length>=r&&(Q=wn,q=!1,c=new On(c));e:for(;++FF?0:F+y),M=M===n||M>F?F:oe(M),M<0&&(M+=F),M=y>M?0:Jh(M);y0&&y(K)?c>1?yt(K,c-1,y,M,F):G4(F,K):M||(F[F.length]=K)}return F}var $a=lh(),$d=lh(!0);function x2(s,c){return s&&$a(s,c,lt)}function Ba(s,c){return s&&$d(s,c,lt)}function li(s,c){return Z4(c,function(y){return K2(s[y])})}function Fn(s,c){c=N3(c,s);for(var y=0,M=c.length;s!=null&&yc}function PM(s,c){return s!=null&&ve.call(s,c)}function CM(s,c){return s!=null&&c in Ae(s)}function NM(s,c,y){return s>=U(c,y)&&s=120&&y1.length>=120)?new On(q&&y1):n}y1=s[0];var S1=-1,P1=K[0];e:for(;++S1-1;)K!==s&&Mn.call(K,n1,1),Mn.call(s,n1,1);return s}function Vd(s,c){for(var y=s?c.length:0,M=y-1;y--;){var F=c[y];if(y==M||F!==Q){var Q=F;X2(F)?Mn.call(s,F,1):Va(s,F)}}return s}function Za(s,c){return s+Tn(u1()*(c-s+1))}function WM(s,c,y,M){for(var F=-1,Q=A(kn((c-s)/(y||1)),0),q=c1(Q);Q--;)q[M?Q:++F]=s,s+=y;return q}function Ga(s,c){var y="";if(!s||c<1||c>V)return y;do c%2&&(y+=s),c=Tn(c/2),c&&(s+=s);while(c);return y}function ce(s,c){return cs(Mh(s,c,Kt),s+"")}function HM(s){return Od(t6(s))}function ZM(s,c){var y=t6(s);return wi(y,Ln(c,0,y.length))}function W0(s,c,y,M){if(!He(s))return s;c=N3(c,s);for(var F=-1,Q=c.length,q=Q-1,K=s;K!=null&&++FF?0:F+c),y=y>F?F:y,y<0&&(y+=F),F=c>y?0:y-c>>>0,c>>>=0;for(var Q=c1(F);++M>>1,q=s[Q];q!==null&&!f4(q)&&(y?q<=c:q=r){var m1=c?null:aA(s);if(m1)return qt(m1);q=!1,F=wn,n1=new On}else n1=c?[]:K;e:for(;++M=M?s:C4(s,c,y)}var nh=ri||function(s){return it.clearTimeout(s)};function ih(s,c){if(c)return s.slice();var y=s.length,M=ni?ni(y):new s.constructor(y);return s.copy(M),M}function Ja(s){var c=new s.constructor(s.byteLength);return new _2(c).set(new _2(s)),c}function XM(s,c){var y=c?Ja(s.buffer):s.buffer;return new s.constructor(y,s.byteOffset,s.byteLength)}function KM(s){var c=new s.constructor(s.source,B2.exec(s));return c.lastIndex=s.lastIndex,c}function JM(s){return Fe?Ae(Fe.call(s)):{}}function rh(s,c){var y=c?Ja(s.buffer):s.buffer;return new s.constructor(y,s.byteOffset,s.length)}function oh(s,c){if(s!==c){var y=s!==n,M=s===null,F=s===s,Q=f4(s),q=c!==n,K=c===null,n1=c===c,m1=f4(c);if(!K&&!m1&&!Q&&s>c||Q&&q&&n1&&!K&&!m1||M&&q&&n1||!y&&n1||!F)return 1;if(!M&&!Q&&!m1&&s=K)return n1;var m1=y[M];return n1*(m1=="desc"?-1:1)}}return s.index-c.index}function ah(s,c,y,M){for(var F=-1,Q=s.length,q=y.length,K=-1,n1=c.length,m1=A(Q-q,0),y1=c1(n1+m1),S1=!M;++K1?y[F-1]:n,q=F>2?y[2]:n;for(Q=s.length>3&&typeof Q=="function"?(F--,Q):n,q&&Bt(y[0],y[1],q)&&(Q=F<3?n:Q,F=1),c=Ae(c);++M-1?F[Q?c[q]:q]:n}}function dh(s){return Y2(function(c){var y=c.length,M=y,F=Et.prototype.thru;for(s&&c.reverse();M--;){var Q=c[M];if(typeof Q!="function")throw new mt(u);if(F&&!q&&vi(Q)=="wrapper")var q=new Et([],!0)}for(M=q?M:y;++M1&&_e.reverse(),y1&&n1K))return!1;var m1=Q.get(s),y1=Q.get(c);if(m1&&y1)return m1==c&&y1==s;var S1=-1,P1=!0,U1=y&k?new On:n;for(Q.set(s,c),Q.set(c,s);++S11?"& ":"")+c[M],c=c.join(y>2?", ":" "),s.replace($1,`{ -/* [wrapped with `+c+`] */ -`)}function mA(s){return ne(s)||Un(s)||!!(ii&&s&&s[ii])}function X2(s,c){var y=typeof s;return c=c??V,!!c&&(y=="number"||y!="symbol"&&ma.test(s))&&s>-1&&s%1==0&&s0){if(++c>=J)return arguments[0]}else c=0;return s.apply(n,arguments)}}function wi(s,c){var y=-1,M=s.length,F=M-1;for(c=c===n?M:c;++y1?s[c-1]:n;return y=typeof y=="function"?(s.pop(),y):n,Uh(s,y)});function $h(s){var c=z(s);return c.__chain__=!0,c}function kk(s,c){return c(s),s}function xi(s,c){return c(s)}var Tk=Y2(function(s){var c=s.length,y=c?s[0]:0,M=this.__wrapped__,F=function(Q){return Ua(Q,s)};return c>1||this.__actions__.length||!(M instanceof le)||!X2(y)?this.thru(F):(M=M.slice(y,+y+(c?1:0)),M.__actions__.push({func:xi,args:[F],thisArg:n}),new Et(M,this.__chain__).thru(function(Q){return c&&!Q.length&&Q.push(n),Q}))});function Pk(){return $h(this)}function Ck(){return new Et(this.value(),this.__chain__)}function Nk(){this.__values__===n&&(this.__values__=Kh(this.value()));var s=this.__index__>=this.__values__.length,c=s?n:this.__values__[this.__index__++];return{done:s,value:c}}function Ok(){return this}function Lk(s){for(var c,y=this;y instanceof Y5;){var M=Nh(y);M.__index__=0,M.__values__=n,c?F.__wrapped__=M:c=M;var F=M;y=y.__wrapped__}return F.__wrapped__=s,c}function Fk(){var s=this.__wrapped__;if(s instanceof le){var c=s;return this.__actions__.length&&(c=new le(this)),c=c.reverse(),c.__actions__.push({func:xi,args:[fs],thisArg:n}),new Et(c,this.__chain__)}return this.thru(fs)}function Ik(){return eh(this.__wrapped__,this.__actions__)}var Rk=hi(function(s,c,y){ve.call(s,y)?++s[y]:q2(s,y,1)});function Uk(s,c,y){var M=ne(s)?M0:kM;return y&&Bt(s,c,y)&&(c=n),M(s,Q1(c,3))}function $k(s,c){var y=ne(s)?Z4:Ud;return y(s,Q1(c,3))}var Bk=fh(Oh),zk=fh(Lh);function jk(s,c){return yt(bi(s,c),1)}function Dk(s,c){return yt(bi(s,c),r1)}function Qk(s,c,y){return y=y===n?1:oe(y),yt(bi(s,c),y)}function Bh(s,c){var y=ne(s)?Rt:P3;return y(s,Q1(c,3))}function zh(s,c){var y=ne(s)?g2:Rd;return y(s,Q1(c,3))}var Wk=hi(function(s,c,y){ve.call(s,y)?s[y].push(c):q2(s,y,[c])});function Hk(s,c,y,M){s=Yt(s)?s:t6(s),y=y&&!M?oe(y):0;var F=s.length;return y<0&&(y=A(F+y,0)),ki(s)?y<=F&&s.indexOf(c,y)>-1:!!F&&w3(s,c,y)>-1}var Zk=ce(function(s,c,y){var M=-1,F=typeof c=="function",Q=Yt(s)?c1(s.length):[];return P3(s,function(q){Q[++M]=F?ze(c,q,y):D0(q,c,y)}),Q}),Gk=hi(function(s,c,y){q2(s,y,c)});function bi(s,c){var y=ne(s)?Ce:Qd;return y(s,Q1(c,3))}function qk(s,c,y,M){return s==null?[]:(ne(c)||(c=c==null?[]:[c]),y=M?n:y,ne(y)||(y=y==null?[]:[y]),Gd(s,c,y))}var Vk=hi(function(s,c,y){s[y?0:1].push(c)},function(){return[[],[]]});function Yk(s,c,y){var M=ne(s)?k0:j5,F=arguments.length<3;return M(s,Q1(c,4),y,F,P3)}function Xk(s,c,y){var M=ne(s)?Sa:j5,F=arguments.length<3;return M(s,Q1(c,4),y,F,Rd)}function Kk(s,c){var y=ne(s)?Z4:Ud;return y(s,Mi(Q1(c,3)))}function Jk(s){var c=ne(s)?Od:HM;return c(s)}function eT(s,c,y){(y?Bt(s,c,y):c===n)?c=1:c=oe(c);var M=ne(s)?bM:ZM;return M(s,c)}function tT(s){var c=ne(s)?SM:qM;return c(s)}function nT(s){if(s==null)return 0;if(Yt(s))return ki(s)?bt(s):s.length;var c=Mt(s);return c==D1||c==T?s.size:Qa(s).length}function iT(s,c,y){var M=ne(s)?yn:VM;return y&&Bt(s,c,y)&&(c=n),M(s,Q1(c,3))}var rT=ce(function(s,c){if(s==null)return[];var y=c.length;return y>1&&Bt(s,c[0],c[1])?c=[]:y>2&&Bt(c[0],c[1],c[2])&&(c=[c[0]]),Gd(s,yt(c,1),[])}),Si=oi||function(){return it.Date.now()};function oT(s,c){if(typeof c!="function")throw new mt(u);return s=oe(s),function(){if(--s<1)return c.apply(this,arguments)}}function jh(s,c,y){return c=y?n:c,c=s&&c==null?s.length:c,V2(s,j,n,n,n,n,c)}function Dh(s,c){var y;if(typeof c!="function")throw new mt(u);return s=oe(s),function(){return--s>0&&(y=c.apply(this,arguments)),s<=1&&(c=n),y}}var hs=ce(function(s,c,y){var M=O;if(y.length){var F=v2(y,J5(hs));M|=$}return V2(s,M,c,y,F)}),Qh=ce(function(s,c,y){var M=O|x;if(y.length){var F=v2(y,J5(Qh));M|=$}return V2(c,M,s,y,F)});function Wh(s,c,y){c=y?n:c;var M=V2(s,b,n,n,n,n,n,c);return M.placeholder=Wh.placeholder,M}function Hh(s,c,y){c=y?n:c;var M=V2(s,N,n,n,n,n,n,c);return M.placeholder=Hh.placeholder,M}function Zh(s,c,y){var M,F,Q,q,K,n1,m1=0,y1=!1,S1=!1,P1=!0;if(typeof s!="function")throw new mt(u);c=O4(c)||0,He(y)&&(y1=!!y.leading,S1="maxWait"in y,Q=S1?A(O4(y.maxWait)||0,c):Q,P1="trailing"in y?!!y.trailing:P1);function U1(et){var J4=M,e3=F;return M=F=n,m1=et,q=s.apply(e3,J4),q}function H1(et){return m1=et,K=G0(he,c),y1?U1(et):q}function se(et){var J4=et-n1,e3=et-m1,fp=c-J4;return S1?U(fp,Q-e3):fp}function Z1(et){var J4=et-n1,e3=et-m1;return n1===n||J4>=c||J4<0||S1&&e3>=Q}function he(){var et=Si();if(Z1(et))return _e(et);K=G0(he,se(et))}function _e(et){return K=n,P1&&M?U1(et):(M=F=n,q)}function d4(){K!==n&&nh(K),m1=0,M=n1=F=K=n}function zt(){return K===n?q:_e(Si())}function h4(){var et=Si(),J4=Z1(et);if(M=arguments,F=this,n1=et,J4){if(K===n)return H1(n1);if(S1)return nh(K),K=G0(he,c),U1(n1)}return K===n&&(K=G0(he,c)),q}return h4.cancel=d4,h4.flush=zt,h4}var aT=ce(function(s,c){return Id(s,1,c)}),sT=ce(function(s,c,y){return Id(s,O4(c)||0,y)});function uT(s){return V2(s,Y)}function Ei(s,c){if(typeof s!="function"||c!=null&&typeof c!="function")throw new mt(u);var y=function(){var M=arguments,F=c?c.apply(this,M):M[0],Q=y.cache;if(Q.has(F))return Q.get(F);var q=s.apply(this,M);return y.cache=Q.set(F,q)||Q,q};return y.cache=new(Ei.Cache||G2),y}Ei.Cache=G2;function Mi(s){if(typeof s!="function")throw new mt(u);return function(){var c=arguments;switch(c.length){case 0:return!s.call(this);case 1:return!s.call(this,c[0]);case 2:return!s.call(this,c[0],c[1]);case 3:return!s.call(this,c[0],c[1],c[2])}return!s.apply(this,c)}}function lT(s){return Dh(2,s)}var cT=YM(function(s,c){c=c.length==1&&ne(c[0])?Ce(c[0],Re(Q1())):Ce(yt(c,1),Re(Q1()));var y=c.length;return ce(function(M){for(var F=-1,Q=U(M.length,y);++F=c}),Un=zd(function(){return arguments}())?zd:function(s){return Ye(s)&&ve.call(s,"callee")&&!$0.call(s,"callee")},ne=c1.isArray,MT=H9?Re(H9):LM;function Yt(s){return s!=null&&Ai(s.length)&&!K2(s)}function Je(s){return Ye(s)&&Yt(s)}function AT(s){return s===!0||s===!1||Ye(s)&&$t(s)==W1}var L3=o||Ms,kT=E0?Re(E0):FM;function TT(s){return Ye(s)&&s.nodeType===1&&!q0(s)}function PT(s){if(s==null)return!0;if(Yt(s)&&(ne(s)||typeof s=="string"||typeof s.splice=="function"||L3(s)||e6(s)||Un(s)))return!s.length;var c=Mt(s);if(c==D1||c==T)return!s.size;if(Z0(s))return!Qa(s).length;for(var y in s)if(ve.call(s,y))return!1;return!0}function CT(s,c){return Q0(s,c)}function NT(s,c,y){y=typeof y=="function"?y:n;var M=y?y(s,c):n;return M===n?Q0(s,c,n,y):!!M}function gs(s){if(!Ye(s))return!1;var c=$t(s);return c==R1||c==O1||typeof s.message=="string"&&typeof s.name=="string"&&!q0(s)}function OT(s){return typeof s=="number"&&l(s)}function K2(s){if(!He(s))return!1;var c=$t(s);return c==g1||c==J1||c==I1||c==Qe}function qh(s){return typeof s=="number"&&s==oe(s)}function Ai(s){return typeof s=="number"&&s>-1&&s%1==0&&s<=V}function He(s){var c=typeof s;return s!=null&&(c=="object"||c=="function")}function Ye(s){return s!=null&&typeof s=="object"}var Vh=Z9?Re(Z9):RM;function LT(s,c){return s===c||Da(s,c,os(c))}function FT(s,c,y){return y=typeof y=="function"?y:n,Da(s,c,os(c),y)}function IT(s){return Yh(s)&&s!=+s}function RT(s){if(_A(s))throw new V1(a);return jd(s)}function UT(s){return s===null}function $T(s){return s==null}function Yh(s){return typeof s=="number"||Ye(s)&&$t(s)==ae}function q0(s){if(!Ye(s)||$t(s)!=pe)return!1;var c=H2(s);if(c===null)return!0;var y=ve.call(c,"constructor")&&c.constructor;return typeof y=="function"&&y instanceof y&&V5.call(y)==ti}var ms=G9?Re(G9):UM;function BT(s){return qh(s)&&s>=-V&&s<=V}var Xh=B5?Re(B5):$M;function ki(s){return typeof s=="string"||!ne(s)&&Ye(s)&&$t(s)==P}function f4(s){return typeof s=="symbol"||Ye(s)&&$t(s)==Z}var e6=q9?Re(q9):BM;function zT(s){return s===n}function jT(s){return Ye(s)&&Mt(s)==v1}function DT(s){return Ye(s)&&$t(s)==b1}var QT=yi(Wa),WT=yi(function(s,c){return s<=c});function Kh(s){if(!s)return[];if(Yt(s))return ki(s)?St(s):Vt(s);if(k3&&s[k3])return Q5(s[k3]());var c=Mt(s),y=c==D1?L0:c==T?qt:t6;return y(s)}function J2(s){if(!s)return s===0?s:0;if(s=O4(s),s===r1||s===-r1){var c=s<0?-1:1;return c*p1}return s===s?s:0}function oe(s){var c=J2(s),y=c%1;return c===c?y?c-y:c:0}function Jh(s){return s?Ln(oe(s),0,w1):0}function O4(s){if(typeof s=="number")return s;if(f4(s))return f1;if(He(s)){var c=typeof s.valueOf=="function"?s.valueOf():s;s=He(c)?c+"":c}if(typeof s!="string")return s===0?s:+s;s=K9(s);var y=ha.test(s);return y||ga.test(s)?xa(s.slice(2),y?2:8):L9.test(s)?f1:+s}function ep(s){return b2(s,Xt(s))}function HT(s){return s?Ln(oe(s),-V,V):s===0?s:0}function ke(s){return s==null?"":c4(s)}var ZT=X5(function(s,c){if(Z0(c)||Yt(c)){b2(c,lt(c),s);return}for(var y in c)ve.call(c,y)&&z0(s,y,c[y])}),tp=X5(function(s,c){b2(c,Xt(c),s)}),Ti=X5(function(s,c,y,M){b2(c,Xt(c),s,M)}),GT=X5(function(s,c,y,M){b2(c,lt(c),s,M)}),qT=Y2(Ua);function VT(s,c){var y=T3(s);return c==null?y:Ld(y,c)}var YT=ce(function(s,c){s=Ae(s);var y=-1,M=c.length,F=M>2?c[2]:n;for(F&&Bt(c[0],c[1],F)&&(M=1);++y1),Q}),b2(s,is(s),y),M&&(y=P4(y,h|v|S,sA));for(var F=c.length;F--;)Va(y,c[F]);return y});function pP(s,c){return ip(s,Mi(Q1(c)))}var gP=Y2(function(s,c){return s==null?{}:DM(s,c)});function ip(s,c){if(s==null)return{};var y=Ce(is(s),function(M){return[M]});return c=Q1(c),qd(s,y,function(M,F){return c(M,F[0])})}function mP(s,c,y){c=N3(c,s);var M=-1,F=c.length;for(F||(F=1,s=n);++Mc){var M=s;s=c,c=M}if(y||s%1||c%1){var F=u1();return U(s+F*(c-s+w0("1e-"+((F+"").length-1))),c)}return Za(s,c)}var kP=K5(function(s,c,y){return c=c.toLowerCase(),s+(y?ap(c):c)});function ap(s){return _s(ke(s).toLowerCase())}function sp(s){return s=ke(s),s&&s.replace(F9,Ma).replace(j9,"")}function TP(s,c,y){s=ke(s),c=c4(c);var M=s.length;y=y===n?M:Ln(oe(y),0,M);var F=y;return y-=c.length,y>=0&&s.slice(y,F)==c}function PP(s){return s=ke(s),s&&fn.test(s)?s.replace(cn,xn):s}function CP(s){return s=ke(s),s&&da.test(s)?s.replace(f0,"\\$&"):s}var NP=K5(function(s,c,y){return s+(y?"-":"")+c.toLowerCase()}),OP=K5(function(s,c,y){return s+(y?" ":"")+c.toLowerCase()}),LP=ch("toLowerCase");function FP(s,c,y){s=ke(s),c=oe(c);var M=c?bt(s):0;if(!c||M>=c)return s;var F=(c-M)/2;return mi(Tn(F),y)+s+mi(kn(F),y)}function IP(s,c,y){s=ke(s),c=oe(c);var M=c?bt(s):0;return c&&M>>0,y?(s=ke(s),s&&(typeof c=="string"||c!=null&&!ms(c))&&(c=c4(c),!c&&b3(s))?O3(St(s),0,y):s.split(c,y)):[]}var DP=K5(function(s,c,y){return s+(y?" ":"")+_s(c)});function QP(s,c,y){return s=ke(s),y=y==null?0:Ln(oe(y),0,s.length),c=c4(c),s.slice(y,y+c.length)==c}function WP(s,c,y){var M=z.templateSettings;y&&Bt(s,c,y)&&(c=n),s=ke(s),c=Ti({},c,M,yh);var F=Ti({},c.imports,M.imports,yh),Q=lt(F),q=m2(F,Q),K,n1,m1=0,y1=c.interpolate||T5,S1="__p += '",P1=U0((c.escape||T5).source+"|"+y1.source+"|"+(y1===k9?O9:T5).source+"|"+(c.evaluate||T5).source+"|$","g"),U1="//# sourceURL="+(ve.call(c,"sourceURL")?(c.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++mn+"]")+` -`;s.replace(P1,function(Z1,he,_e,d4,zt,h4){return _e||(_e=d4),S1+=s.slice(m1,h4).replace(P5,ei),he&&(K=!0,S1+=`' + -__e(`+he+`) + -'`),zt&&(n1=!0,S1+=`'; -`+zt+`; -__p += '`),_e&&(S1+=`' + -((__t = (`+_e+`)) == null ? '' : __t) + -'`),m1=h4+Z1.length,Z1}),S1+=`'; -`;var H1=ve.call(c,"variable")&&c.variable;if(!H1)S1=`with (obj) { -`+S1+` -} -`;else if(N9.test(H1))throw new V1(f);S1=(n1?S1.replace(k5,""):S1).replace($2,"$1").replace(ln,"$1;"),S1="function("+(H1||"obj")+`) { -`+(H1?"":`obj || (obj = {}); -`)+"var __t, __p = ''"+(K?", __e = _.escape":"")+(n1?`, __j = Array.prototype.join; -function print() { __p += __j.call(arguments, '') } -`:`; -`)+S1+`return __p -}`;var se=lp(function(){return Se(Q,U1+"return "+S1).apply(n,q)});if(se.source=S1,gs(se))throw se;return se}function HP(s){return ke(s).toLowerCase()}function ZP(s){return ke(s).toUpperCase()}function GP(s,c,y){if(s=ke(s),s&&(y||c===n))return K9(s);if(!s||!(c=c4(c)))return s;var M=St(s),F=St(c),Q=k4(M,F),q=J9(M,F)+1;return O3(M,Q,q).join("")}function qP(s,c,y){if(s=ke(s),s&&(y||c===n))return s.slice(0,F0(s)+1);if(!s||!(c=c4(c)))return s;var M=St(s),F=J9(M,St(c))+1;return O3(M,0,F).join("")}function VP(s,c,y){if(s=ke(s),s&&(y||c===n))return s.replace(d0,"");if(!s||!(c=c4(c)))return s;var M=St(s),F=k4(M,St(c));return O3(M,F).join("")}function YP(s,c){var y=H,M=D;if(He(c)){var F="separator"in c?c.separator:F;y="length"in c?oe(c.length):y,M="omission"in c?c4(c.omission):M}s=ke(s);var Q=s.length;if(b3(s)){var q=St(s);Q=q.length}if(y>=Q)return s;var K=y-bt(M);if(K<1)return M;var n1=q?O3(q,0,K).join(""):s.slice(0,K);if(F===n)return n1+M;if(q&&(K+=n1.length-K),ms(F)){if(s.slice(K).search(F)){var m1,y1=n1;for(F.global||(F=U0(F.source,ke(B2.exec(F))+"g")),F.lastIndex=0;m1=F.exec(y1);)var S1=m1.index;n1=n1.slice(0,S1===n?K:S1)}}else if(s.indexOf(c4(F),K)!=K){var P1=n1.lastIndexOf(F);P1>-1&&(n1=n1.slice(0,P1))}return n1+M}function XP(s){return s=ke(s),s&&W4.test(s)?s.replace(s4,I0):s}var KP=K5(function(s,c,y){return s+(y?" ":"")+c.toUpperCase()}),_s=ch("toUpperCase");function up(s,c,y){return s=ke(s),c=y?n:c,c===n?y2(s)?Z5(s):Y9(s):s.match(c)||[]}var lp=ce(function(s,c){try{return ze(s,n,c)}catch(y){return gs(y)?y:new V1(y)}}),JP=Y2(function(s,c){return Rt(c,function(y){y=S2(y),q2(s,y,hs(s[y],s))}),s});function eC(s){var c=s==null?0:s.length,y=Q1();return s=c?Ce(s,function(M){if(typeof M[1]!="function")throw new mt(u);return[y(M[0]),M[1]]}):[],ce(function(M){for(var F=-1;++FV)return[];var y=w1,M=U(s,w1);c=Q1(c),s-=w1;for(var F=O0(M,c);++y0||c<0)?new le(y):(s<0?y=y.takeRight(-s):s&&(y=y.drop(s)),c!==n&&(c=oe(c),y=c<0?y.dropRight(-c):y.take(c-s)),y)},le.prototype.takeRightWhile=function(s){return this.reverse().takeWhile(s).reverse()},le.prototype.toArray=function(){return this.take(w1)},x2(le.prototype,function(s,c){var y=/^(?:filter|find|map|reject)|While$/.test(c),M=/^(?:head|last)$/.test(c),F=z[M?"take"+(c=="last"?"Right":""):c],Q=M||/^find/.test(c);F&&(z.prototype[c]=function(){var q=this.__wrapped__,K=M?[1]:arguments,n1=q instanceof le,m1=K[0],y1=n1||ne(q),S1=function(he){var _e=F.apply(z,G4([he],K));return M&&P1?_e[0]:_e};y1&&y&&typeof m1=="function"&&m1.length!=1&&(n1=y1=!1);var P1=this.__chain__,U1=!!this.__actions__.length,H1=Q&&!P1,se=n1&&!U1;if(!Q&&y1){q=se?q:new le(this);var Z1=s.apply(q,K);return Z1.__actions__.push({func:xi,args:[S1],thisArg:n}),new Et(Z1,P1)}return H1&&se?s.apply(this,K):(Z1=this.thru(S1),H1?M?Z1.value()[0]:Z1.value():Z1)})}),Rt(["pop","push","shift","sort","splice","unshift"],function(s){var c=G5[s],y=/^(?:push|sort|unshift)$/.test(s)?"tap":"thru",M=/^(?:pop|shift)$/.test(s);z.prototype[s]=function(){var F=arguments;if(M&&!this.__chain__){var Q=this.value();return c.apply(ne(Q)?Q:[],F)}return this[y](function(q){return c.apply(ne(q)?q:[],F)})}}),x2(le.prototype,function(s,c){var y=z[c];if(y){var M=y.name+"";ve.call(l4,M)||(l4[M]=[]),l4[M].push({name:c,func:y})}}),l4[pi(n,x).name]=[{name:"wrapper",func:n}],le.prototype.clone=Ia,le.prototype.reverse=KE,le.prototype.value=JE,z.prototype.at=Tk,z.prototype.chain=Pk,z.prototype.commit=Ck,z.prototype.next=Nk,z.prototype.plant=Lk,z.prototype.reverse=Fk,z.prototype.toJSON=z.prototype.valueOf=z.prototype.value=Ik,z.prototype.first=z.prototype.head,k3&&(z.prototype[k3]=Ok),z},q4=E3();u4?((u4.exports=q4)._=q4,It._=q4):it._=q4}).call(o2)})(fr,fr.exports);var i5=fr.exports;function FD(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var ID=FD;const B1=Ot(ID);function Jx(e,t){return et?1:e>=t?0:NaN}function Gf(e){let t=e,n=e;e.length===1&&(t=(u,f)=>e(u)-f,n=RD(e));function i(u,f,d,p){for(d==null&&(d=0),p==null&&(p=u.length);d>>1;n(u[m],f)<0?d=m+1:p=m}return d}function r(u,f,d,p){for(d==null&&(d=0),p==null&&(p=u.length);d>>1;n(u[m],f)>0?p=m:d=m+1}return d}function a(u,f,d,p){d==null&&(d=0),p==null&&(p=u.length);const m=i(u,f,d,p-1);return m>d&&t(u[m-1],f)>-t(u[m],f)?m-1:m}return{left:i,center:a,right:r}}function RD(e){return(t,n)=>Jx(e(t),n)}function UD(e){return e===null?NaN:+e}const $D=Gf(Jx),BD=$D.right;Gf(UD).center;const zD=BD;var Bl=Math.sqrt(50),zl=Math.sqrt(10),jl=Math.sqrt(2);function Dl(e,t,n){var i,r=-1,a,u,f;if(t=+t,e=+e,n=+n,e===t&&n>0)return[e];if((i=t0){let d=Math.round(e/f),p=Math.round(t/f);for(d*ft&&--p,u=new Array(a=p-d+1);++rt&&--p,u=new Array(a=p-d+1);++r=0?(a>=Bl?10:a>=zl?5:a>=jl?2:1)*Math.pow(10,r):-Math.pow(10,-r)/(a>=Bl?10:a>=zl?5:a>=jl?2:1)}function Ql(e,t,n){var i=Math.abs(t-e)/Math.max(0,n),r=Math.pow(10,Math.floor(Math.log(i)/Math.LN10)),a=i/r;return a>=Bl?r*=10:a>=zl?r*=5:a>=jl&&(r*=2),tt&&(n=e,e=t,t=n),function(i){return Math.max(e,Math.min(t,i))}}function ZD(e,t,n){var i=e[0],r=e[1],a=t[0],u=t[1];return r2?GD:ZD,d=p=null,h}function h(v){return v==null||isNaN(v=+v)?a:(d||(d=f(e.map(i),t,n)))(i(u(v)))}return h.invert=function(v){return u(r((p||(p=f(t,e.map(i),cr)))(v)))},h.domain=function(v){return arguments.length?(e=Array.from(v,WD),m()):e.slice()},h.range=function(v){return arguments.length?(t=Array.from(v),m()):t.slice()},h.rangeRound=function(v){return t=Array.from(v),n=LD,m()},h.clamp=function(v){return arguments.length?(u=v?!0:S6,m()):u!==S6},h.interpolate=function(v){return arguments.length?(n=v,m()):n},h.unknown=function(v){return arguments.length?(a=v,h):a},function(v,S){return i=v,r=S,m()}}function nb(){return Vf()(S6,S6)}function qD(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function dr(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,i=e.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function q6(e){return e=dr(Math.abs(e)),e?e[1]:NaN}function VD(e,t){return function(n,i){for(var r=n.length,a=[],u=0,f=e[0],d=0;r>0&&f>0&&(d+f+1>i&&(f=Math.max(1,i-d)),a.push(n.substring(r-=f,r+f)),!((d+=f+1)>i));)f=e[u=(u+1)%e.length];return a.reverse().join(t)}}function YD(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var XD=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function hr(e){if(!(t=XD.exec(e)))throw new Error("invalid format: "+e);var t;return new Yf({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]})}hr.prototype=Yf.prototype;function Yf(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+""}Yf.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 KD(e){e:for(var t=e.length,n=1,i=-1,r;n0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(r+1):e}var ib;function JD(e,t){var n=dr(e,t);if(!n)return e+"";var i=n[0],r=n[1],a=r-(ib=Math.max(-8,Math.min(8,Math.floor(r/3)))*3)+1,u=i.length;return a===u?i:a>u?i+new Array(a-u+1).join("0"):a>0?i.slice(0,a)+"."+i.slice(a):"0."+new Array(1-a).join("0")+dr(e,Math.max(0,t+a-1))[0]}function Mm(e,t){var n=dr(e,t);if(!n)return e+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")}const Am={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:qD,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)=>Mm(e*100,t),r:Mm,s:JD,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function km(e){return e}var Tm=Array.prototype.map,Pm=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function eQ(e){var t=e.grouping===void 0||e.thousands===void 0?km:VD(Tm.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",r=e.decimal===void 0?".":e.decimal+"",a=e.numerals===void 0?km:YD(Tm.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",f=e.minus===void 0?"−":e.minus+"",d=e.nan===void 0?"NaN":e.nan+"";function p(h){h=hr(h);var v=h.fill,S=h.align,E=h.sign,k=h.symbol,O=h.zero,x=h.width,w=h.comma,b=h.precision,N=h.trim,$=h.type;$==="n"?(w=!0,$="g"):Am[$]||(b===void 0&&(b=12),N=!0,$="g"),(O||v==="0"&&S==="=")&&(O=!0,v="0",S="=");var I=k==="$"?n:k==="#"&&/[boxX]/.test($)?"0"+$.toLowerCase():"",j=k==="$"?i:/[%p]/.test($)?u:"",B=Am[$],Y=/[defgprs%]/.test($);b=b===void 0?6:/[gprs]/.test($)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function H(D){var J=I,e1=j,o1,i1,l1;if($==="c")e1=B(D)+e1,D="";else{D=+D;var r1=D<0||1/D<0;if(D=isNaN(D)?d:B(Math.abs(D),b),N&&(D=KD(D)),r1&&+D==0&&E!=="+"&&(r1=!1),J=(r1?E==="("?E:f:E==="-"||E==="("?"":E)+J,e1=($==="s"?Pm[8+ib/3]:"")+e1+(r1&&E==="("?")":""),Y){for(o1=-1,i1=D.length;++o1l1||l1>57){e1=(l1===46?r+D.slice(o1+1):D.slice(o1))+e1,D=D.slice(0,o1);break}}}w&&!O&&(D=t(D,1/0));var V=J.length+D.length+e1.length,p1=V>1)+J+D+e1+p1.slice(V);break;default:D=p1+J+D+e1;break}return a(D)}return H.toString=function(){return h+""},H}function m(h,v){var S=p((h=hr(h),h.type="f",h)),E=Math.max(-8,Math.min(8,Math.floor(q6(v)/3)))*3,k=Math.pow(10,-E),O=Pm[8+E/3];return function(x){return S(k*x)+O}}return{format:p,formatPrefix:m}}var Yi,Xf,rb;tQ({thousands:",",grouping:[3],currency:["$",""]});function tQ(e){return Yi=eQ(e),Xf=Yi.format,rb=Yi.formatPrefix,Yi}function nQ(e){return Math.max(0,-q6(Math.abs(e)))}function iQ(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(q6(t)/3)))*3-q6(Math.abs(e)))}function rQ(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,q6(t)-q6(e))+1}function oQ(e,t,n,i){var r=Ql(e,t,n),a;switch(i=hr(i??",f"),i.type){case"s":{var u=Math.max(Math.abs(e),Math.abs(t));return i.precision==null&&!isNaN(a=iQ(r,u))&&(i.precision=a),rb(i,u)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(a=rQ(r,Math.max(Math.abs(e),Math.abs(t))))&&(i.precision=a-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(a=nQ(r))&&(i.precision=a-(i.type==="%")*2);break}}return Xf(i)}function ob(e){var t=e.domain;return e.ticks=function(n){var i=t();return Dl(i[0],i[i.length-1],n??10)},e.tickFormat=function(n,i){var r=t();return oQ(r[0],r[r.length-1],n??10,i)},e.nice=function(n){n==null&&(n=10);var i=t(),r=0,a=i.length-1,u=i[r],f=i[a],d,p,m=10;for(f0;){if(p=eb(u,f,n),p===d)return i[r]=u,i[a]=f,t(i);if(p>0)u=Math.floor(u/p)*p,f=Math.ceil(f/p)*p;else if(p<0)u=Math.ceil(u*p)/p,f=Math.floor(f*p)/p;else break;d=p}return e},e}function ab(){var e=nb();return e.copy=function(){return _o(e,ab())},w5.apply(e,arguments),ob(e)}function sb(e,t){e=e.slice();var n=0,i=e.length-1,r=e[n],a=e[i],u;return a0){for(;v<=S;++v)for(k=1,E=a(v);km)break;w.push(O)}}else for(;v<=S;++v)for(k=i-1,E=a(v);k>=1;--k)if(O=E*k,!(Om)break;w.push(O)}w.length*20))return d;do d.push(p=new Date(+a)),t(a,f),e(a);while(p=u)for(;e(u),!a(u);)u.setTime(u-1)},function(u,f){if(u>=u)if(f<0)for(;++f<=0;)for(;t(u,-1),!a(u););else for(;--f>=0;)for(;t(u,1),!a(u););})},n&&(r.count=function(a,u){return uu.setTime(+a),lu.setTime(+u),e(uu),e(lu),Math.floor(n(uu,lu))},r.every=function(a){return a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?r.filter(i?function(u){return i(u)%a===0}:function(u){return r.count(0,u)%a===0}):r}),r}var pr=ht(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});pr.every=function(e){return e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?ht(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):pr};const hQ=pr;pr.range;const s3=1e3,$4=s3*60,u3=$4*60,h5=u3*24,Kf=h5*7,Im=h5*30,cu=h5*365;var cb=ht(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+t*s3)},function(e,t){return(t-e)/s3},function(e){return e.getUTCSeconds()});const E6=cb;cb.range;var fb=ht(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*s3)},function(e,t){e.setTime(+e+t*$4)},function(e,t){return(t-e)/$4},function(e){return e.getMinutes()});const db=fb;fb.range;var hb=ht(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*s3-e.getMinutes()*$4)},function(e,t){e.setTime(+e+t*u3)},function(e,t){return(t-e)/u3},function(e){return e.getHours()});const pb=hb;hb.range;var gb=ht(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*$4)/h5,e=>e.getDate()-1);const wo=gb;gb.range;function x5(e){return ht(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(t,n){t.setDate(t.getDate()+n*7)},function(t,n){return(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*$4)/Kf})}var xo=x5(0),gr=x5(1),pQ=x5(2),gQ=x5(3),V6=x5(4),mQ=x5(5),yQ=x5(6);xo.range;gr.range;pQ.range;gQ.range;V6.range;mQ.range;yQ.range;var mb=ht(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12},function(e){return e.getMonth()});const yb=mb;mb.range;var Jf=ht(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()});Jf.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:ht(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)})};const p5=Jf;Jf.range;var vb=ht(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*$4)},function(e,t){return(t-e)/$4},function(e){return e.getUTCMinutes()});const _b=vb;vb.range;var wb=ht(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+t*u3)},function(e,t){return(t-e)/u3},function(e){return e.getUTCHours()});const xb=wb;wb.range;var bb=ht(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/h5},function(e){return e.getUTCDate()-1});const bo=bb;bb.range;function b5(e){return ht(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCDate(t.getUTCDate()+n*7)},function(t,n){return(n-t)/Kf})}var So=b5(0),mr=b5(1),vQ=b5(2),_Q=b5(3),Y6=b5(4),wQ=b5(5),xQ=b5(6);So.range;mr.range;vQ.range;_Q.range;Y6.range;wQ.range;xQ.range;var Sb=ht(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12},function(e){return e.getUTCMonth()});const Eb=Sb;Sb.range;var ed=ht(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()});ed.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:ht(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})};const g5=ed;ed.range;function Mb(e,t,n,i,r,a){const u=[[E6,1,s3],[E6,5,5*s3],[E6,15,15*s3],[E6,30,30*s3],[a,1,$4],[a,5,5*$4],[a,15,15*$4],[a,30,30*$4],[r,1,u3],[r,3,3*u3],[r,6,6*u3],[r,12,12*u3],[i,1,h5],[i,2,2*h5],[n,1,Kf],[t,1,Im],[t,3,3*Im],[e,1,cu]];function f(p,m,h){const v=mO).right(u,v);if(S===u.length)return e.every(Ql(p/cu,m/cu,h));if(S===0)return hQ.every(Math.max(Ql(p,m,h),1));const[E,k]=u[v/u[S-1][2]53)return null;"w"in g1||(g1.w=1),"Z"in g1?(D1=du(s7(g1.y,0,1)),ae=D1.getUTCDay(),D1=ae>4||ae===0?mr.ceil(D1):mr(D1),D1=bo.offset(D1,(g1.V-1)*7),g1.y=D1.getUTCFullYear(),g1.m=D1.getUTCMonth(),g1.d=D1.getUTCDate()+(g1.w+6)%7):(D1=fu(s7(g1.y,0,1)),ae=D1.getDay(),D1=ae>4||ae===0?gr.ceil(D1):gr(D1),D1=wo.offset(D1,(g1.V-1)*7),g1.y=D1.getFullYear(),g1.m=D1.getMonth(),g1.d=D1.getDate()+(g1.w+6)%7)}else("W"in g1||"U"in g1)&&("w"in g1||(g1.w="u"in g1?g1.u%7:"W"in g1?1:0),ae="Z"in g1?du(s7(g1.y,0,1)).getUTCDay():fu(s7(g1.y,0,1)).getDay(),g1.m=0,g1.d="W"in g1?(g1.w+6)%7+g1.W*7-(ae+5)%7:g1.w+g1.U*7-(ae+6)%7);return"Z"in g1?(g1.H+=g1.Z/100|0,g1.M+=g1.Z%100,du(g1)):fu(g1)}}function B(E1,O1,R1,g1){for(var J1=0,D1=O1.length,ae=R1.length,we,pe;J1=ae)return-1;if(we=O1.charCodeAt(J1++),we===37){if(we=O1.charAt(J1++),pe=$[we in Rm?O1.charAt(J1++):we],!pe||(g1=pe(E1,R1,g1))<0)return-1}else if(we!=R1.charCodeAt(g1++))return-1}return g1}function Y(E1,O1,R1){var g1=p.exec(O1.slice(R1));return g1?(E1.p=m.get(g1[0].toLowerCase()),R1+g1[0].length):-1}function H(E1,O1,R1){var g1=S.exec(O1.slice(R1));return g1?(E1.w=E.get(g1[0].toLowerCase()),R1+g1[0].length):-1}function D(E1,O1,R1){var g1=h.exec(O1.slice(R1));return g1?(E1.w=v.get(g1[0].toLowerCase()),R1+g1[0].length):-1}function J(E1,O1,R1){var g1=x.exec(O1.slice(R1));return g1?(E1.m=w.get(g1[0].toLowerCase()),R1+g1[0].length):-1}function e1(E1,O1,R1){var g1=k.exec(O1.slice(R1));return g1?(E1.m=O.get(g1[0].toLowerCase()),R1+g1[0].length):-1}function o1(E1,O1,R1){return B(E1,t,O1,R1)}function i1(E1,O1,R1){return B(E1,n,O1,R1)}function l1(E1,O1,R1){return B(E1,i,O1,R1)}function r1(E1){return u[E1.getDay()]}function V(E1){return a[E1.getDay()]}function p1(E1){return d[E1.getMonth()]}function f1(E1){return f[E1.getMonth()]}function w1(E1){return r[+(E1.getHours()>=12)]}function T1(E1){return 1+~~(E1.getMonth()/3)}function j1(E1){return u[E1.getUTCDay()]}function F1(E1){return a[E1.getUTCDay()]}function _1(E1){return d[E1.getUTCMonth()]}function d1(E1){return f[E1.getUTCMonth()]}function I1(E1){return r[+(E1.getUTCHours()>=12)]}function W1(E1){return 1+~~(E1.getUTCMonth()/3)}return{format:function(E1){var O1=I(E1+="",b);return O1.toString=function(){return E1},O1},parse:function(E1){var O1=j(E1+="",!1);return O1.toString=function(){return E1},O1},utcFormat:function(E1){var O1=I(E1+="",N);return O1.toString=function(){return E1},O1},utcParse:function(E1){var O1=j(E1+="",!0);return O1.toString=function(){return E1},O1}}}var Rm={"-":"",_:" ",0:"0"},pt=/^\s*\d+/,kQ=/^%/,TQ=/[\\^$*+?|[\]().{}]/g;function Me(e,t,n){var i=e<0?"-":"",r=(i?-e:e)+"",a=r.length;return i+(a[t.toLowerCase(),n]))}function CQ(e,t,n){var i=pt.exec(t.slice(n,n+1));return i?(e.w=+i[0],n+i[0].length):-1}function NQ(e,t,n){var i=pt.exec(t.slice(n,n+1));return i?(e.u=+i[0],n+i[0].length):-1}function OQ(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.U=+i[0],n+i[0].length):-1}function LQ(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.V=+i[0],n+i[0].length):-1}function FQ(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.W=+i[0],n+i[0].length):-1}function Um(e,t,n){var i=pt.exec(t.slice(n,n+4));return i?(e.y=+i[0],n+i[0].length):-1}function $m(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function IQ(e,t,n){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return i?(e.Z=i[1]?0:-(i[2]+(i[3]||"00")),n+i[0].length):-1}function RQ(e,t,n){var i=pt.exec(t.slice(n,n+1));return i?(e.q=i[0]*3-3,n+i[0].length):-1}function UQ(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.m=i[0]-1,n+i[0].length):-1}function Bm(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.d=+i[0],n+i[0].length):-1}function $Q(e,t,n){var i=pt.exec(t.slice(n,n+3));return i?(e.m=0,e.d=+i[0],n+i[0].length):-1}function zm(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.H=+i[0],n+i[0].length):-1}function BQ(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.M=+i[0],n+i[0].length):-1}function zQ(e,t,n){var i=pt.exec(t.slice(n,n+2));return i?(e.S=+i[0],n+i[0].length):-1}function jQ(e,t,n){var i=pt.exec(t.slice(n,n+3));return i?(e.L=+i[0],n+i[0].length):-1}function DQ(e,t,n){var i=pt.exec(t.slice(n,n+6));return i?(e.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function QQ(e,t,n){var i=kQ.exec(t.slice(n,n+1));return i?n+i[0].length:-1}function WQ(e,t,n){var i=pt.exec(t.slice(n));return i?(e.Q=+i[0],n+i[0].length):-1}function HQ(e,t,n){var i=pt.exec(t.slice(n));return i?(e.s=+i[0],n+i[0].length):-1}function jm(e,t){return Me(e.getDate(),t,2)}function ZQ(e,t){return Me(e.getHours(),t,2)}function GQ(e,t){return Me(e.getHours()%12||12,t,2)}function qQ(e,t){return Me(1+wo.count(p5(e),e),t,3)}function Ab(e,t){return Me(e.getMilliseconds(),t,3)}function VQ(e,t){return Ab(e,t)+"000"}function YQ(e,t){return Me(e.getMonth()+1,t,2)}function XQ(e,t){return Me(e.getMinutes(),t,2)}function KQ(e,t){return Me(e.getSeconds(),t,2)}function JQ(e){var t=e.getDay();return t===0?7:t}function eW(e,t){return Me(xo.count(p5(e)-1,e),t,2)}function kb(e){var t=e.getDay();return t>=4||t===0?V6(e):V6.ceil(e)}function tW(e,t){return e=kb(e),Me(V6.count(p5(e),e)+(p5(e).getDay()===4),t,2)}function nW(e){return e.getDay()}function iW(e,t){return Me(gr.count(p5(e)-1,e),t,2)}function rW(e,t){return Me(e.getFullYear()%100,t,2)}function oW(e,t){return e=kb(e),Me(e.getFullYear()%100,t,2)}function aW(e,t){return Me(e.getFullYear()%1e4,t,4)}function sW(e,t){var n=e.getDay();return e=n>=4||n===0?V6(e):V6.ceil(e),Me(e.getFullYear()%1e4,t,4)}function uW(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Me(t/60|0,"0",2)+Me(t%60,"0",2)}function Dm(e,t){return Me(e.getUTCDate(),t,2)}function lW(e,t){return Me(e.getUTCHours(),t,2)}function cW(e,t){return Me(e.getUTCHours()%12||12,t,2)}function fW(e,t){return Me(1+bo.count(g5(e),e),t,3)}function Tb(e,t){return Me(e.getUTCMilliseconds(),t,3)}function dW(e,t){return Tb(e,t)+"000"}function hW(e,t){return Me(e.getUTCMonth()+1,t,2)}function pW(e,t){return Me(e.getUTCMinutes(),t,2)}function gW(e,t){return Me(e.getUTCSeconds(),t,2)}function mW(e){var t=e.getUTCDay();return t===0?7:t}function yW(e,t){return Me(So.count(g5(e)-1,e),t,2)}function Pb(e){var t=e.getUTCDay();return t>=4||t===0?Y6(e):Y6.ceil(e)}function vW(e,t){return e=Pb(e),Me(Y6.count(g5(e),e)+(g5(e).getUTCDay()===4),t,2)}function _W(e){return e.getUTCDay()}function wW(e,t){return Me(mr.count(g5(e)-1,e),t,2)}function xW(e,t){return Me(e.getUTCFullYear()%100,t,2)}function bW(e,t){return e=Pb(e),Me(e.getUTCFullYear()%100,t,2)}function SW(e,t){return Me(e.getUTCFullYear()%1e4,t,4)}function EW(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Y6(e):Y6.ceil(e),Me(e.getUTCFullYear()%1e4,t,4)}function MW(){return"+0000"}function Qm(){return"%"}function Wm(e){return+e}function Hm(e){return Math.floor(+e/1e3)}var r6,Eo,Cb,Nb,Ob;AW({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 AW(e){return r6=AQ(e),Eo=r6.format,Cb=r6.parse,Nb=r6.utcFormat,Ob=r6.utcParse,r6}function kW(e){return new Date(e)}function TW(e){return e instanceof Date?+e:+new Date(+e)}function td(e,t,n,i,r,a,u,f,d,p){var m=nb(),h=m.invert,v=m.domain,S=p(".%L"),E=p(":%S"),k=p("%I:%M"),O=p("%I %p"),x=p("%a %d"),w=p("%b %d"),b=p("%B"),N=p("%Y");function $(I){return(d(I)MD(e[e.length-1]);var Mo=new Array(3).concat("d8b365f5f5f55ab4ac","a6611adfc27d80cdc1018571","a6611adfc27df5f5f580cdc1018571","8c510ad8b365f6e8c3c7eae55ab4ac01665e","8c510ad8b365f6e8c3f5f5f5c7eae55ab4ac01665e","8c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e","8c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e","5430058c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e003c30","5430058c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e003c30").map(ue);const NW=Ne(Mo);var Ao=new Array(3).concat("af8dc3f7f7f77fbf7b","7b3294c2a5cfa6dba0008837","7b3294c2a5cff7f7f7a6dba0008837","762a83af8dc3e7d4e8d9f0d37fbf7b1b7837","762a83af8dc3e7d4e8f7f7f7d9f0d37fbf7b1b7837","762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b7837","762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b7837","40004b762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b783700441b","40004b762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b783700441b").map(ue);const OW=Ne(Ao);var ko=new Array(3).concat("e9a3c9f7f7f7a1d76a","d01c8bf1b6dab8e1864dac26","d01c8bf1b6daf7f7f7b8e1864dac26","c51b7de9a3c9fde0efe6f5d0a1d76a4d9221","c51b7de9a3c9fde0eff7f7f7e6f5d0a1d76a4d9221","c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221","c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221","8e0152c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221276419","8e0152c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221276419").map(ue);const LW=Ne(ko);var To=new Array(3).concat("998ec3f7f7f7f1a340","5e3c99b2abd2fdb863e66101","5e3c99b2abd2f7f7f7fdb863e66101","542788998ec3d8daebfee0b6f1a340b35806","542788998ec3d8daebf7f7f7fee0b6f1a340b35806","5427888073acb2abd2d8daebfee0b6fdb863e08214b35806","5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b35806","2d004b5427888073acb2abd2d8daebfee0b6fdb863e08214b358067f3b08","2d004b5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b358067f3b08").map(ue);const FW=Ne(To);var Po=new Array(3).concat("ef8a62f7f7f767a9cf","ca0020f4a58292c5de0571b0","ca0020f4a582f7f7f792c5de0571b0","b2182bef8a62fddbc7d1e5f067a9cf2166ac","b2182bef8a62fddbc7f7f7f7d1e5f067a9cf2166ac","b2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac","b2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac","67001fb2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac053061","67001fb2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac053061").map(ue);const IW=Ne(Po);var Co=new Array(3).concat("ef8a62ffffff999999","ca0020f4a582bababa404040","ca0020f4a582ffffffbababa404040","b2182bef8a62fddbc7e0e0e09999994d4d4d","b2182bef8a62fddbc7ffffffe0e0e09999994d4d4d","b2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d","b2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d","67001fb2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d1a1a1a","67001fb2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d1a1a1a").map(ue);const RW=Ne(Co);var No=new Array(3).concat("fc8d59ffffbf91bfdb","d7191cfdae61abd9e92c7bb6","d7191cfdae61ffffbfabd9e92c7bb6","d73027fc8d59fee090e0f3f891bfdb4575b4","d73027fc8d59fee090ffffbfe0f3f891bfdb4575b4","d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4","d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4","a50026d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4313695","a50026d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4313695").map(ue);const UW=Ne(No);var Oo=new Array(3).concat("fc8d59ffffbf91cf60","d7191cfdae61a6d96a1a9641","d7191cfdae61ffffbfa6d96a1a9641","d73027fc8d59fee08bd9ef8b91cf601a9850","d73027fc8d59fee08bffffbfd9ef8b91cf601a9850","d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850","d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850","a50026d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850006837","a50026d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850006837").map(ue);const $W=Ne(Oo);var Lo=new Array(3).concat("fc8d59ffffbf99d594","d7191cfdae61abdda42b83ba","d7191cfdae61ffffbfabdda42b83ba","d53e4ffc8d59fee08be6f59899d5943288bd","d53e4ffc8d59fee08bffffbfe6f59899d5943288bd","d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd","d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd","9e0142d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd5e4fa2","9e0142d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd5e4fa2").map(ue);const BW=Ne(Lo);var Fo=new Array(3).concat("e5f5f999d8c92ca25f","edf8fbb2e2e266c2a4238b45","edf8fbb2e2e266c2a42ca25f006d2c","edf8fbccece699d8c966c2a42ca25f006d2c","edf8fbccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45006d2c00441b").map(ue);const zW=Ne(Fo);var Io=new Array(3).concat("e0ecf49ebcda8856a7","edf8fbb3cde38c96c688419d","edf8fbb3cde38c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d810f7c4d004b").map(ue);const jW=Ne(Io);var Ro=new Array(3).concat("e0f3dba8ddb543a2ca","f0f9e8bae4bc7bccc42b8cbe","f0f9e8bae4bc7bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe0868ac084081").map(ue);const DW=Ne(Ro);var Uo=new Array(3).concat("fee8c8fdbb84e34a33","fef0d9fdcc8afc8d59d7301f","fef0d9fdcc8afc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301fb300007f0000").map(ue);const QW=Ne(Uo);var $o=new Array(3).concat("ece2f0a6bddb1c9099","f6eff7bdc9e167a9cf02818a","f6eff7bdc9e167a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016c59014636").map(ue);const WW=Ne($o);var Bo=new Array(3).concat("ece7f2a6bddb2b8cbe","f1eef6bdc9e174a9cf0570b0","f1eef6bdc9e174a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0045a8d023858").map(ue);const HW=Ne(Bo);var zo=new Array(3).concat("e7e1efc994c7dd1c77","f1eef6d7b5d8df65b0ce1256","f1eef6d7b5d8df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125698004367001f").map(ue);const ZW=Ne(zo);var jo=new Array(3).concat("fde0ddfa9fb5c51b8a","feebe2fbb4b9f768a1ae017e","feebe2fbb4b9f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a017749006a").map(ue);const GW=Ne(jo);var Do=new Array(3).concat("edf8b17fcdbb2c7fb8","ffffcca1dab441b6c4225ea8","ffffcca1dab441b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea8253494081d58").map(ue);const qW=Ne(Do);var Qo=new Array(3).concat("f7fcb9addd8e31a354","ffffccc2e69978c679238443","ffffccc2e69978c67931a354006837","ffffccd9f0a3addd8e78c67931a354006837","ffffccd9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443006837004529").map(ue);const VW=Ne(Qo);var Wo=new Array(3).concat("fff7bcfec44fd95f0e","ffffd4fed98efe9929cc4c02","ffffd4fed98efe9929d95f0e993404","ffffd4fee391fec44ffe9929d95f0e993404","ffffd4fee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c02993404662506").map(ue);const YW=Ne(Wo);var Ho=new Array(3).concat("ffeda0feb24cf03b20","ffffb2fecc5cfd8d3ce31a1c","ffffb2fecc5cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cbd0026800026").map(ue);const XW=Ne(Ho);var Zo=new Array(3).concat("deebf79ecae13182bd","eff3ffbdd7e76baed62171b5","eff3ffbdd7e76baed63182bd08519c","eff3ffc6dbef9ecae16baed63182bd08519c","eff3ffc6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b508519c08306b").map(ue);const KW=Ne(Zo);var Go=new Array(3).concat("e5f5e0a1d99b31a354","edf8e9bae4b374c476238b45","edf8e9bae4b374c47631a354006d2c","edf8e9c7e9c0a1d99b74c47631a354006d2c","edf8e9c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45006d2c00441b").map(ue);const JW=Ne(Go);var qo=new Array(3).concat("f0f0f0bdbdbd636363","f7f7f7cccccc969696525252","f7f7f7cccccc969696636363252525","f7f7f7d9d9d9bdbdbd969696636363252525","f7f7f7d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525000000").map(ue);const eH=Ne(qo);var Vo=new Array(3).concat("efedf5bcbddc756bb1","f2f0f7cbc9e29e9ac86a51a3","f2f0f7cbc9e29e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a354278f3f007d").map(ue);const tH=Ne(Vo);var Yo=new Array(3).concat("fee0d2fc9272de2d26","fee5d9fcae91fb6a4acb181d","fee5d9fcae91fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181da50f1567000d").map(ue);const nH=Ne(Yo);var Xo=new Array(3).concat("fee6cefdae6be6550d","feeddefdbe85fd8d3cd94701","feeddefdbe85fd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d94801a636037f2704").map(ue);const iH=Ne(Xo);function rH(e){return e=Math.max(0,Math.min(1,e)),"rgb("+Math.max(0,Math.min(255,Math.round(-4.54-e*(35.34-e*(2381.73-e*(6402.7-e*(7024.72-e*2710.57)))))))+", "+Math.max(0,Math.min(255,Math.round(32.49+e*(170.73+e*(52.82-e*(131.46-e*(176.58-e*67.37)))))))+", "+Math.max(0,Math.min(255,Math.round(81.24+e*(442.36-e*(2482.43-e*(6167.24-e*(6614.94-e*2475.67)))))))+")"}const oH=Zf(I2(300,.5,0),I2(-240,.5,1));var aH=Zf(I2(-100,.75,.35),I2(80,1.5,.8)),sH=Zf(I2(260,.75,.35),I2(80,1.5,.8)),Xi=I2();function uH(e){(e<0||e>1)&&(e-=Math.floor(e));var t=Math.abs(e-.5);return Xi.h=360*e-100,Xi.s=1.5-1.5*t,Xi.l=.8-.9*t,Xi+""}var Ki=a9(),lH=Math.PI/3,cH=Math.PI*2/3;function fH(e){var t;return e=(.5-e)*Math.PI,Ki.r=255*(t=Math.sin(e))*t,Ki.g=255*(t=Math.sin(e+lH))*t,Ki.b=255*(t=Math.sin(e+cH))*t,Ki+""}function dH(e){return e=Math.max(0,Math.min(1,e)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+e*(1172.33-e*(10793.56-e*(33300.12-e*(38394.49-e*14825.05)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+e*(557.33+e*(1225.33-e*(3574.96-e*(1073.77+e*707.56)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+e*(3211.1-e*(15327.97-e*(27814-e*(22569.18-e*6838.66)))))))+")"}function Ko(e){var t=e.length;return function(n){return e[Math.max(0,Math.min(t-1,Math.floor(n*t)))]}}const hH=Ko(ue("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725"));var pH=Ko(ue("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),gH=Ko(ue("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),mH=Ko(ue("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921")),yH="__lodash_hash_undefined__";function vH(e){return this.__data__.set(e,yH),this}var _H=vH;function wH(e){return this.__data__.has(e)}var xH=wH,bH=Nf,SH=_H,EH=xH;function yr(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new bH;++t-1}var jb=UH;function $H(e,t,n){for(var i=-1,r=e==null?0:e.length;++i=ZH&&(a=HH,u=!1,t=new zH(t));e:for(;++rzn)if(!(Math.abs(m*f-d*p)>zn)||!r)this._+="L"+(this._x1=e)+","+(this._y1=t);else{var v=n-a,S=i-u,E=f*f+d*d,k=v*v+S*S,O=Math.sqrt(E),x=Math.sqrt(h),w=r*Math.tan((Hl-Math.acos((E+h-k)/(2*O*x)))/2),b=w/x,N=w/O;Math.abs(b-1)>zn&&(this._+="L"+(e+b*p)+","+(t+b*m)),this._+="A"+r+","+r+",0,0,"+ +(m*v>p*S)+","+(this._x1=e+N*f)+","+(this._y1=t+N*d)}},arc:function(e,t,n,i,r,a){e=+e,t=+t,n=+n,a=!!a;var u=n*Math.cos(i),f=n*Math.sin(i),d=e+u,p=t+f,m=1^a,h=a?i-r:r-i;if(n<0)throw new Error("negative radius: "+n);this._x1===null?this._+="M"+d+","+p:(Math.abs(this._x1-d)>zn||Math.abs(this._y1-p)>zn)&&(this._+="L"+d+","+p),n&&(h<0&&(h=h%Zl+Zl),h>eZ?this._+="A"+n+","+n+",0,1,"+m+","+(e-u)+","+(t-f)+"A"+n+","+n+",0,1,"+m+","+(this._x1=d)+","+(this._y1=p):h>zn&&(this._+="A"+n+","+n+",0,"+ +(h>=Hl)+","+m+","+(this._x1=e+n*Math.cos(r))+","+(this._y1=t+n*Math.sin(r))))},rect:function(e,t,n,i){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +i+"h"+-n+"Z"},toString:function(){return this._}};function p4(e){return function(){return e}}var Zm=1e-12;function Wb(e){this._context=e}Wb.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 ad(e){return new Wb(e)}function Hb(e){return e[0]}function Zb(e){return e[1]}function Gb(){var e=Hb,t=Zb,n=p4(!0),i=null,r=ad,a=null;function u(f){var d,p=f.length,m,h=!1,v;for(i==null&&(a=r(v=od())),d=0;d<=p;++d)!(d=v;--S)f.point(w[S],b[S]);f.lineEnd(),f.areaEnd()}O&&(w[h]=+e(k,h,m),b[h]=+n(k,h,m),f.point(t?+t(k,h,m):w[h],i?+i(k,h,m):b[h]))}if(x)return f=null,x+""||null}function p(){return Gb().defined(r).curve(u).context(a)}return d.x=function(m){return arguments.length?(e=typeof m=="function"?m:p4(+m),t=null,d):e},d.x0=function(m){return arguments.length?(e=typeof m=="function"?m:p4(+m),d):e},d.x1=function(m){return arguments.length?(t=m==null?null:typeof m=="function"?m:p4(+m),d):t},d.y=function(m){return arguments.length?(n=typeof m=="function"?m:p4(+m),i=null,d):n},d.y0=function(m){return arguments.length?(n=typeof m=="function"?m:p4(+m),d):n},d.y1=function(m){return arguments.length?(i=m==null?null:typeof m=="function"?m:p4(+m),d):i},d.lineX0=d.lineY0=function(){return p().x(e).y(n)},d.lineY1=function(){return p().x(e).y(i)},d.lineX1=function(){return p().x(t).y(n)},d.defined=function(m){return arguments.length?(r=typeof m=="function"?m:p4(!!m),d):r},d.curve=function(m){return arguments.length?(u=m,a!=null&&(f=u(a)),d):u},d.context=function(m){return arguments.length?(m==null?a=f=null:f=u(a=m),d):a},d}function tn(){}function vr(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 Jo(e){this._context=e}Jo.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:vr(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:vr(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function nZ(e){return new Jo(e)}function qb(e){this._context=e}qb.prototype={areaStart:tn,areaEnd:tn,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:vr(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function iZ(e){return new qb(e)}function Vb(e){this._context=e}Vb.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,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,i):this._context.moveTo(n,i);break;case 3:this._point=4;default:vr(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rZ(e){return new Vb(e)}function Yb(e,t){this._basis=new Jo(e),this._beta=t}Yb.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var i=e[0],r=t[0],a=e[n]-i,u=t[n]-r,f=-1,d;++f<=n;)d=f/n,this._basis.point(this._beta*e[f]+(1-this._beta)*(i+d*a),this._beta*t[f]+(1-this._beta)*(r+d*u));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const oZ=function e(t){function n(i){return t===1?new Jo(i):new Yb(i,t)}return n.beta=function(i){return e(+i)},n}(.85);function _r(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function sd(e,t){this._context=e,this._k=(1-t)/6}sd.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:_r(this,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,this._x1=e,this._y1=t;break;case 2:this._point=3;default:_r(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const aZ=function e(t){function n(i){return new sd(i,t)}return n.tension=function(i){return e(+i)},n}(0);function ud(e,t){this._context=e,this._k=(1-t)/6}ud.prototype={areaStart:tn,areaEnd:tn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:_r(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const sZ=function e(t){function n(i){return new ud(i,t)}return n.tension=function(i){return e(+i)},n}(0);function ld(e,t){this._context=e,this._k=(1-t)/6}ld.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=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,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:_r(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const uZ=function e(t){function n(i){return new ld(i,t)}return n.tension=function(i){return e(+i)},n}(0);function cd(e,t,n){var i=e._x1,r=e._y1,a=e._x2,u=e._y2;if(e._l01_a>Zm){var f=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,d=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*f-e._x0*e._l12_2a+e._x2*e._l01_2a)/d,r=(r*f-e._y0*e._l12_2a+e._y2*e._l01_2a)/d}if(e._l23_a>Zm){var p=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,m=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*p+e._x1*e._l23_2a-t*e._l12_2a)/m,u=(u*p+e._y1*e._l23_2a-n*e._l12_2a)/m}e._context.bezierCurveTo(i,r,a,u,e._x2,e._y2)}function Xb(e,t){this._context=e,this._alpha=t}Xb.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}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;default:cd(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const lZ=function e(t){function n(i){return t?new Xb(i,t):new sd(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Kb(e,t){this._context=e,this._alpha=t}Kb.prototype={areaStart:tn,areaEnd:tn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:cd(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const cZ=function e(t){function n(i){return t?new Kb(i,t):new ud(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Jb(e,t){this._context=e,this._alpha=t}Jb.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=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){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:cd(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const fZ=function e(t){function n(i){return t?new Jb(i,t):new ld(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function eS(e){this._context=e}eS.prototype={areaStart:tn,areaEnd:tn,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 dZ(e){return new eS(e)}function Gm(e){return e<0?-1:1}function qm(e,t,n){var i=e._x1-e._x0,r=t-e._x1,a=(e._y1-e._y0)/(i||r<0&&-0),u=(n-e._y1)/(r||i<0&&-0),f=(a*r+u*i)/(i+r);return(Gm(a)+Gm(u))*Math.min(Math.abs(a),Math.abs(u),.5*Math.abs(f))||0}function Vm(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function hu(e,t,n){var i=e._x0,r=e._y0,a=e._x1,u=e._y1,f=(a-i)/3;e._context.bezierCurveTo(i+f,r+f*t,a-f,u-f*n,a,u)}function wr(e){this._context=e}wr.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:hu(this,this._t0,Vm(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,hu(this,Vm(this,n=qm(this,e,t)),n);break;default:hu(this,this._t0,n=qm(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function tS(e){this._context=new nS(e)}(tS.prototype=Object.create(wr.prototype)).point=function(e,t){wr.prototype.point.call(this,t,e)};function nS(e){this._context=e}nS.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,i,r,a){this._context.bezierCurveTo(t,e,i,n,a,r)}};function hZ(e){return new wr(e)}function pZ(e){return new tS(e)}function iS(e){this._context=e}iS.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 i=Ym(e),r=Ym(t),a=0,u=1;u=0;--t)r[t]=(u[t]-r[t+1])/a[t];for(a[n-1]=(e[n]+r[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 mZ(e){return new ea(e,.5)}function yZ(e){return new ea(e,0)}function vZ(e){return new ea(e,1)}function ta(e,t){if((u=e.length)>1)for(var n=1,i,r,a=e[t[0]],u,f=a.length;n=0;)n[t]=t;return n}function _Z(e,t){if((i=e.length)>0){for(var n,i,r=0,a=e[0].length,u;r0)for(var n,i=0,r,a,u,f,d,p=e[t[0]].length;i0?(r[0]=u,r[1]=u+=a):a<0?(r[1]=f,r[0]=f+=a):(r[0]=0,r[1]=a)}function xZ(e,t){if((r=e.length)>0){for(var n=0,i=e[t[0]],r,a=i.length;n0)||!((a=(r=e[t[0]]).length)>0))){for(var n=0,i=1,r,a,u;ia&&(a=r,n=t);return n}function rS(e){var t=e.map(oS);return na(e).sort(function(n,i){return t[n]-t[i]})}function oS(e){for(var t=0,n=-1,i=e.length,r;++n=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function xr(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,i=e.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function PZ(e){return e=xr(Math.abs(e)),e?e[1]:NaN}function CZ(e,t){return function(n,i){for(var r=n.length,a=[],u=0,f=e[0],d=0;r>0&&f>0&&(d+f+1>i&&(f=Math.max(1,i-d)),a.push(n.substring(r-=f,r+f)),!((d+=f+1)>i));)f=e[u=(u+1)%e.length];return a.reverse().join(t)}}function NZ(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var OZ=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ql(e){if(!(t=OZ.exec(e)))throw new Error("invalid format: "+e);var t;return new fd({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]})}ql.prototype=fd.prototype;function fd(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+""}fd.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 LZ(e){e:for(var t=e.length,n=1,i=-1,r;n0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(r+1):e}var aS;function FZ(e,t){var n=xr(e,t);if(!n)return e+"";var i=n[0],r=n[1],a=r-(aS=Math.max(-8,Math.min(8,Math.floor(r/3)))*3)+1,u=i.length;return a===u?i:a>u?i+new Array(a-u+1).join("0"):a>0?i.slice(0,a)+"."+i.slice(a):"0."+new Array(1-a).join("0")+xr(e,Math.max(0,t+a-1))[0]}function Xm(e,t){var n=xr(e,t);if(!n)return e+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")}const Km={"%":function(e,t){return(e*100).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:TZ,e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return Xm(e*100,t)},r:Xm,s:FZ,X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}};function Jm(e){return e}var ey=Array.prototype.map,ty=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function IZ(e){var t=e.grouping===void 0||e.thousands===void 0?Jm:CZ(ey.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",r=e.decimal===void 0?".":e.decimal+"",a=e.numerals===void 0?Jm:NZ(ey.call(e.numerals,String)),u=e.percent===void 0?"%":e.percent+"",f=e.minus===void 0?"-":e.minus+"",d=e.nan===void 0?"NaN":e.nan+"";function p(h){h=ql(h);var v=h.fill,S=h.align,E=h.sign,k=h.symbol,O=h.zero,x=h.width,w=h.comma,b=h.precision,N=h.trim,$=h.type;$==="n"?(w=!0,$="g"):Km[$]||(b===void 0&&(b=12),N=!0,$="g"),(O||v==="0"&&S==="=")&&(O=!0,v="0",S="=");var I=k==="$"?n:k==="#"&&/[boxX]/.test($)?"0"+$.toLowerCase():"",j=k==="$"?i:/[%p]/.test($)?u:"",B=Km[$],Y=/[defgprs%]/.test($);b=b===void 0?6:/[gprs]/.test($)?Math.max(1,Math.min(21,b)):Math.max(0,Math.min(20,b));function H(D){var J=I,e1=j,o1,i1,l1;if($==="c")e1=B(D)+e1,D="";else{D=+D;var r1=D<0||1/D<0;if(D=isNaN(D)?d:B(Math.abs(D),b),N&&(D=LZ(D)),r1&&+D==0&&E!=="+"&&(r1=!1),J=(r1?E==="("?E:f:E==="-"||E==="("?"":E)+J,e1=($==="s"?ty[8+aS/3]:"")+e1+(r1&&E==="("?")":""),Y){for(o1=-1,i1=D.length;++o1l1||l1>57){e1=(l1===46?r+D.slice(o1+1):D.slice(o1))+e1,D=D.slice(0,o1);break}}}w&&!O&&(D=t(D,1/0));var V=J.length+D.length+e1.length,p1=V>1)+J+D+e1+p1.slice(V);break;default:D=p1+J+D+e1;break}return a(D)}return H.toString=function(){return h+""},H}function m(h,v){var S=p((h=ql(h),h.type="f",h)),E=Math.max(-8,Math.min(8,Math.floor(PZ(v)/3)))*3,k=Math.pow(10,-E),O=ty[8+E/3];return function(x){return S(k*x)+O}}return{format:p,formatPrefix:m}}var Ji,ia;RZ({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"});function RZ(e){return Ji=IZ(e),ia=Ji.format,Ji.formatPrefix,Ji}var UZ=go,$Z=Zx,BZ=po;function zZ(e,t,n){for(var i=-1,r=t.length,a={};++i0&&n(f)?t>1?lS(f,t-1,n,i,r):cG(r,f):i||(r[r.length]=f)}return r}var cS=lS,dG=cS;function hG(e){var t=e==null?0:e.length;return t?dG(e,1):[]}var pG=hG,gG=pG,mG=zx,yG=jx;function vG(e){return yG(mG(e,void 0,gG),e+"")}var _G=vG,wG=rG,xG=_G,bG=xG(function(e,t){return e==null?{}:wG(e,t)}),SG=bG;const EG=Ot(SG);function MG(e,t){for(var n=-1,i=e==null?0:e.length;++nf))return!1;var p=a.get(e),m=a.get(t);if(p&&m)return p==t&&m==e;var h=-1,v=!0,S=n&NG?new kG:void 0;for(a.set(e,t),a.set(t,e);++h=0||(r[n]=e[n]);return r}var nn={fill:C.string,fontSize:C.number,fontFamily:C.string},_V=C.shape({domain:C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired}).isRequired,ticks:C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired,text:C.shape(st({},nn)).isRequired}).isRequired,legend:C.shape({text:C.shape(st({},nn)).isRequired}).isRequired}),wV=C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired}),xV=C.shape({hidden:C.shape({symbol:C.shape({fill:C.string.isRequired,opacity:C.number}).isRequired,text:C.shape(st({},nn,{opacity:C.number})).isRequired}).isRequired,text:C.shape(st({},nn)).isRequired}),bV=C.shape({text:C.shape(st({},nn)).isRequired}),SV=C.shape({text:C.shape(st({},nn)).isRequired}),EV=C.shape({text:C.shape(st({},nn)).isRequired}),MV=C.shape({line:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,strokeDasharray:C.string}).isRequired}),AV=C.shape({text:C.shape(st({},nn,{outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired})).isRequired,link:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired}).isRequired,outline:C.shape({stroke:C.string.isRequired,strokeWidth:C.number.isRequired,outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired}).isRequired,symbol:C.shape({fill:C.string.isRequired,outlineWidth:C.number.isRequired,outlineColor:C.string.isRequired}).isRequired});C.shape({background:C.string.isRequired,fontFamily:C.string.isRequired,fontSize:C.number.isRequired,textColor:C.string.isRequired,axis:_V.isRequired,grid:wV.isRequired,legends:xV.isRequired,labels:bV.isRequired,dots:SV.isRequired,markers:EV,crosshair:MV.isRequired,annotations:AV.isRequired});var kV={background:"transparent",fontFamily:"sans-serif",fontSize:11,textColor:"#333333",axis:{domain:{line:{stroke:"transparent",strokeWidth:1}},ticks:{line:{stroke:"#777777",strokeWidth:1},text:{}},legend:{text:{fontSize:12}}},grid:{line:{stroke:"#dddddd",strokeWidth:1}},legends:{hidden:{symbol:{fill:"#333333",opacity:.6},text:{fill:"#333333",opacity:.6}},text:{},ticks:{line:{stroke:"#777777",strokeWidth:1},text:{fontSize:10}},title:{text:{}}},labels:{text:{}},markers:{lineColor:"#000000",lineStrokeWidth:1,text:{}},dots:{text:{}},tooltip:{container:{background:"white",color:"inherit",fontSize:"inherit",borderRadius:"2px",boxShadow:"0 1px 2px rgba(0, 0, 0, 0.25)",padding:"5px 9px"},basic:{whiteSpace:"pre",display:"flex",alignItems:"center"},chip:{marginRight:7},table:{},tableCell:{padding:"3px 5px"},tableCellValue:{fontWeight:"bold"}},crosshair:{line:{stroke:"#000000",strokeWidth:1,strokeOpacity:.75,strokeDasharray:"6 6"}},annotations:{text:{fontSize:13,outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1},link:{stroke:"#000000",strokeWidth:1,outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1},outline:{fill:"none",stroke:"#000000",strokeWidth:2,outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1},symbol:{fill:"#000000",outlineWidth:2,outlineColor:"#ffffff",outlineOpacity:1}}},TV=["axis.ticks.text","axis.legend.text","legends.title.text","legends.text","legends.ticks.text","legends.title.text","labels.text","dots.text","markers.text","annotations.text"],PV=function(e,t){var n=cj({},e,t);return TV.forEach(function(i){t5(n,i+".fontFamily")===void 0&&qn(n,i+".fontFamily",n.fontFamily),t5(n,i+".fontSize")===void 0&&qn(n,i+".fontSize",n.fontSize),t5(n,i+".fill")===void 0&&qn(n,i+".fill",n.textColor)}),n},gS=G.createContext(),md=function(e){var t=e.children,n=e.animate,i=e.config,r=G.useMemo(function(){var a=i5.isString(i)?Af[i]:i;return{animate:n,config:a}},[n,i]);return R.jsx(gS.Provider,{value:r,children:t})},tc={animate:C.bool,motionConfig:C.oneOfType([C.oneOf(Object.keys(Af)),C.shape({mass:C.number,tension:C.number,friction:C.number,clamp:C.bool,precision:C.number,velocity:C.number,duration:C.number,easing:C.func})])};md.propTypes={children:C.node.isRequired,animate:tc.animate,config:tc.motionConfig};var CV={animate:!0,config:"default"};md.defaultProps=CV;var S5=function(){return G.useContext(gS)},mS=function(e){var t=S5(),n=t.animate,i=t.config,r=function(f){var d=G.useRef();return G.useEffect(function(){d.current=f},[f]),d.current}(e),a=G.useMemo(function(){return Xx(r,e)},[r,e]),u=n0({from:{value:0},to:{value:1},reset:!0,config:i,immediate:!n}).value;return wF(u,a)},NV={nivo:["#d76445","#f47560","#e8c1a0","#97e3d5","#61cdbb","#00b0a7"],BrBG:B1(Mo),PRGn:B1(Ao),PiYG:B1(ko),PuOr:B1(To),RdBu:B1(Po),RdGy:B1(Co),RdYlBu:B1(No),RdYlGn:B1(Oo),spectral:B1(Lo),blues:B1(Zo),greens:B1(Go),greys:B1(qo),oranges:B1(Xo),purples:B1(Vo),reds:B1(Yo),BuGn:B1(Fo),BuPu:B1(Io),GnBu:B1(Ro),OrRd:B1(Uo),PuBuGn:B1($o),PuBu:B1(Bo),PuRd:B1(zo),RdPu:B1(jo),YlGnBu:B1(Do),YlGn:B1(Qo),YlOrBr:B1(Wo),YlOrRd:B1(Ho)},OV=Object.keys(NV);B1(Mo),B1(Ao),B1(ko),B1(To),B1(Po),B1(Co),B1(No),B1(Oo),B1(Lo),B1(Zo),B1(Go),B1(qo),B1(Xo),B1(Vo),B1(Yo),B1(Fo),B1(Io),B1(Ro),B1(Uo),B1($o),B1(Bo),B1(zo),B1(jo),B1(Do),B1(Qo),B1(Wo),B1(Ho);C.oneOfType([C.oneOf(OV),C.func,C.arrayOf(C.string)]);var nc={basis:nZ,basisClosed:iZ,basisOpen:rZ,bundle:oZ,cardinal:aZ,cardinalClosed:sZ,cardinalOpen:uZ,catmullRom:lZ,catmullRomClosed:cZ,catmullRomOpen:fZ,linear:ad,linearClosed:dZ,monotoneX:hZ,monotoneY:pZ,natural:gZ,step:mZ,stepAfter:vZ,stepBefore:yZ},ra=Object.keys(nc);C.oneOf(ra);ra.filter(function(e){return e.endsWith("Closed")});Qb(ra,"bundle","basisClosed","basisOpen","cardinalClosed","cardinalOpen","catmullRomClosed","catmullRomOpen","linearClosed");var LV=Qb(ra,"bundle","basisClosed","basisOpen","cardinalClosed","cardinalOpen","catmullRomClosed","catmullRomOpen","linearClosed"),FV=C.oneOf(LV),yS=function(e){if(!nc[e])throw new TypeError("'"+e+"', is not a valid curve interpolator identifier.");return nc[e]},IV={defs:C.arrayOf(C.shape({id:C.string.isRequired})).isRequired,fill:C.arrayOf(C.shape({id:C.string.isRequired,match:C.oneOfType([C.oneOf(["*"]),C.object,C.func]).isRequired})).isRequired},RV={ascending:rS,descending:MZ,insideOut:AZ,none:na,reverse:kZ},UV=Object.keys(RV);C.oneOf(UV);var $V={expand:_Z,diverging:wZ,none:ta,silhouette:xZ,wiggle:bZ},BV=Object.keys($V);C.oneOf(BV);C.shape({top:C.number,right:C.number,bottom:C.number,left:C.number}).isRequired;var zV=["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],yd=C.oneOf(zV);Vn(nd);var jV={top:0,right:0,bottom:0,left:0},vS=function(e,t,n){return n===void 0&&(n={}),G.useMemo(function(){var i=st({},jV,n);return{margin:i,innerWidth:e-i.left-i.right,innerHeight:t-i.top-i.bottom,outerWidth:e,outerHeight:t}},[e,t,n.top,n.right,n.bottom,n.left])},_S=function(){var e=G.useRef(null),t=G.useState({left:0,top:0,width:0,height:0}),n=t[0],i=t[1],r=G.useState(function(){return typeof ResizeObserver>"u"?null:new ResizeObserver(function(a){var u=a[0];return i(u.contentRect)})})[0];return G.useEffect(function(){return e.current&&r!==null&&r.observe(e.current),function(){r!==null&&r.disconnect()}},[]),[e,n]},DV=function(e){return G.useMemo(function(){return PV(kV,e)},[e])},QV=function(e){return typeof e=="function"?e:typeof e=="string"?e.indexOf("time:")===0?Eo(e.slice("5")):ia(e):function(t){return""+t}},ic=function(e){return G.useMemo(function(){return QV(e)},[e])},wS=G.createContext(),WV={},xS=function(e){var t=e.theme,n=t===void 0?WV:t,i=e.children,r=DV(n);return R.jsx(wS.Provider,{value:r,children:i})};xS.propTypes={children:C.node.isRequired,theme:C.object};var Lt=function(){return G.useContext(wS)},bS=function(e){var t=e.children,n=e.condition,i=e.wrapper;return n?G.cloneElement(i,{},t):t};bS.propTypes={children:C.node.isRequired,condition:C.bool.isRequired,wrapper:C.element.isRequired};var HV={position:"relative"},SS=function(e){var t=e.children,n=e.theme,i=e.renderWrapper,r=i===void 0||i,a=e.isInteractive,u=a===void 0||a,f=e.animate,d=e.motionConfig,p=G.useRef(null);return R.jsx(xS,{theme:n,children:R.jsx(md,{animate:f,config:d,children:R.jsx(BF,{container:p,children:R.jsxs(bS,{condition:r,wrapper:R.jsx("div",{style:HV,ref:p}),children:[t,u&&R.jsx($F,{})]})})})})};SS.propTypes={children:C.element.isRequired,isInteractive:C.bool,renderWrapper:C.bool,theme:C.object,animate:C.bool,motionConfig:C.string};C.func.isRequired,C.bool,C.bool,C.object.isRequired,C.bool.isRequired,C.string;var ES=function(e){var t=e.children,n=_S(),i=n[0],r=n[1],a=r.width>0&&r.height>0;return R.jsx("div",{ref:i,style:{width:"100%",height:"100%"},children:a&&t({width:r.width,height:r.height})})};ES.propTypes={children:C.func.isRequired};var ZV=["id","colors"],MS=function(e){var t=e.id,n=e.colors,i=gd(e,ZV);return R.jsx("linearGradient",st({id:t,x1:0,x2:0,y1:0,y2:1},i,{children:n.map(function(r){var a=r.offset,u=r.color,f=r.opacity;return R.jsx("stop",{offset:a+"%",stopColor:u,stopOpacity:f!==void 0?f:1},a)})}))};MS.propTypes={id:C.string.isRequired,colors:C.arrayOf(C.shape({offset:C.number.isRequired,color:C.string.isRequired,opacity:C.number})).isRequired,gradientTransform:C.string};var AS={linearGradient:MS},M8=G.memo(function(e){var t=e.id,n=e.background,i=e.color,r=e.size,a=e.padding,u=e.stagger,f=r+a,d=r/2,p=a/2;return u===!0&&(f=2*r+2*a),R.jsxs("pattern",{id:t,width:f,height:f,patternUnits:"userSpaceOnUse",children:[R.jsx("rect",{width:f,height:f,fill:n}),R.jsx("circle",{cx:p+d,cy:p+d,r:d,fill:i}),u&&R.jsx("circle",{cx:1.5*a+r+d,cy:1.5*a+r+d,r:d,fill:i})]})});M8.displayName="PatternDots",M8.propTypes={id:C.string.isRequired,color:C.string.isRequired,background:C.string.isRequired,size:C.number.isRequired,padding:C.number.isRequired,stagger:C.bool.isRequired},M8.defaultProps={color:"#000000",background:"#ffffff",size:4,padding:4,stagger:!1};var br=function(e){return e*Math.PI/180},GV={svg:{align:{left:"start",center:"middle",right:"end",start:"start",middle:"middle",end:"end"},baseline:{top:"text-before-edge",center:"central",bottom:"alphabetic"}},canvas:{align:{left:"left",center:"center",right:"right",start:"left",middle:"center",end:"right"},baseline:{top:"top",center:"middle",bottom:"bottom"}}},A8=G.memo(function(e){var t=e.id,n=e.spacing,i=e.rotation,r=e.background,a=e.color,u=e.lineWidth,f=Math.round(i)%360,d=Math.abs(n);f>180?f-=360:f>90?f-=180:f<-180?f+=360:f<-90&&(f+=180);var p,m=d,h=d;return f===0?p=` - M 0 0 L `+m+` 0 - M 0 `+h+" L "+m+" "+h+` - `:f===90?p=` - M 0 0 L 0 `+h+` - M `+m+" 0 L "+m+" "+h+` - `:(m=Math.abs(d/Math.sin(br(f))),h=d/Math.sin(br(90-f)),p=f>0?` - M 0 `+-h+" L "+2*m+" "+h+` - M `+-m+" "+-h+" L "+m+" "+h+` - M `+-m+" 0 L "+m+" "+2*h+` - `:` - M `+-m+" "+h+" L "+m+" "+-h+` - M `+-m+" "+2*h+" L "+2*m+" "+-h+` - M 0 `+2*h+" L "+2*m+` 0 - `),R.jsxs("pattern",{id:t,width:m,height:h,patternUnits:"userSpaceOnUse",children:[R.jsx("rect",{width:m,height:h,fill:r,stroke:"rgba(255, 0, 0, 0.1)",strokeWidth:0}),R.jsx("path",{d:p,strokeWidth:u,stroke:a,strokeLinecap:"square"})]})});A8.displayName="PatternLines",A8.propTypes={id:C.string.isRequired,spacing:C.number.isRequired,rotation:C.number.isRequired,background:C.string.isRequired,color:C.string.isRequired,lineWidth:C.number.isRequired},A8.defaultProps={spacing:5,rotation:0,color:"#000000",background:"#ffffff",lineWidth:2};var k8=G.memo(function(e){var t=e.id,n=e.background,i=e.color,r=e.size,a=e.padding,u=e.stagger,f=r+a,d=a/2;return u===!0&&(f=2*r+2*a),R.jsxs("pattern",{id:t,width:f,height:f,patternUnits:"userSpaceOnUse",children:[R.jsx("rect",{width:f,height:f,fill:n}),R.jsx("rect",{x:d,y:d,width:r,height:r,fill:i}),u&&R.jsx("rect",{x:1.5*a+r,y:1.5*a+r,width:r,height:r,fill:i})]})});k8.displayName="PatternSquares",k8.propTypes={id:C.string.isRequired,color:C.string.isRequired,background:C.string.isRequired,size:C.number.isRequired,padding:C.number.isRequired,stagger:C.bool.isRequired},k8.defaultProps={color:"#000000",background:"#ffffff",size:4,padding:4,stagger:!1};var kS={patternDots:M8,patternLines:A8,patternSquares:k8},qV=["type"],rc=st({},AS,kS),TS=function(e){var t=e.defs;return!t||t.length<1?null:R.jsx("defs",{"aria-hidden":!0,children:t.map(function(n){var i=n.type,r=gd(n,qV);return rc[i]?G.createElement(rc[i],st({key:r.id},r)):null})})};TS.propTypes={defs:C.arrayOf(C.shape({type:C.oneOf(Object.keys(rc)).isRequired,id:C.string.isRequired}))};var VV=G.memo(TS),PS=function(e){var t=e.width,n=e.height,i=e.margin,r=e.defs,a=e.children,u=e.role,f=e.ariaLabel,d=e.ariaLabelledBy,p=e.ariaDescribedBy,m=e.isFocusable,h=Lt();return R.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:t,height:n,role:u,"aria-label":f,"aria-labelledby":d,"aria-describedby":p,focusable:m,tabIndex:m?0:void 0,children:[R.jsx(VV,{defs:r}),R.jsx("rect",{width:t,height:n,fill:h.background}),R.jsx("g",{transform:"translate("+i.left+","+i.top+")",children:a})]})};PS.propTypes={width:C.number.isRequired,height:C.number.isRequired,margin:C.shape({top:C.number.isRequired,left:C.number.isRequired}).isRequired,defs:C.array,children:C.oneOfType([C.arrayOf(C.node),C.node]).isRequired,role:C.string,isFocusable:C.bool,ariaLabel:C.string,ariaLabelledBy:C.string,ariaDescribedBy:C.string};var CS=function(e){var t=e.size,n=e.color,i=e.borderWidth,r=e.borderColor;return R.jsx("circle",{r:t/2,fill:n,stroke:r,strokeWidth:i,style:{pointerEvents:"none"}})};CS.propTypes={size:C.number.isRequired,color:C.string.isRequired,borderWidth:C.number.isRequired,borderColor:C.string.isRequired};var YV=G.memo(CS),NS=function(e){var t=e.x,n=e.y,i=e.symbol,r=i===void 0?YV:i,a=e.size,u=e.datum,f=e.color,d=e.borderWidth,p=e.borderColor,m=e.label,h=e.labelTextAnchor,v=h===void 0?"middle":h,S=e.labelYOffset,E=S===void 0?-12:S,k=Lt(),O=S5(),x=O.animate,w=O.config,b=n0({transform:"translate("+t+", "+n+")",config:w,immediate:!x});return R.jsxs(F2.g,{transform:b.transform,style:{pointerEvents:"none"},children:[G.createElement(r,{size:a,color:f,datum:u,borderWidth:d,borderColor:p}),m&&R.jsx("text",{textAnchor:v,y:E,style:k.dots.text,children:m})]})};NS.propTypes={x:C.number.isRequired,y:C.number.isRequired,datum:C.object.isRequired,size:C.number.isRequired,color:C.string.isRequired,borderWidth:C.number.isRequired,borderColor:C.string.isRequired,symbol:C.oneOfType([C.func,C.object]),label:C.oneOfType([C.string,C.number]),labelTextAnchor:C.oneOf(["start","middle","end"]),labelYOffset:C.number};var XV=G.memo(NS),oc=function(e){var t=e.width,n=e.height,i=e.axis,r=e.scale,a=e.value,u=e.lineStyle,f=e.textStyle,d=e.legend,p=e.legendPosition,m=e.legendOffsetX,h=e.legendOffsetY,v=e.legendOrientation,S=Lt(),E=0,k=0,O=0,x=0;i==="y"?(O=r(a),k=t):(E=r(a),x=n);var w=null;if(d){var b=function(N){var $=N.axis,I=N.width,j=N.height,B=N.position,Y=N.offsetX,H=N.offsetY,D=N.orientation,J=0,e1=0,o1=D==="vertical"?-90:0,i1="start";if($==="x")switch(B){case"top-left":J=-Y,e1=H,i1="end";break;case"top":e1=-H,i1=D==="horizontal"?"middle":"start";break;case"top-right":J=Y,e1=H,i1=D==="horizontal"?"start":"end";break;case"right":J=Y,e1=j/2,i1=D==="horizontal"?"start":"middle";break;case"bottom-right":J=Y,e1=j-H,i1="start";break;case"bottom":e1=j+H,i1=D==="horizontal"?"middle":"end";break;case"bottom-left":e1=j-H,J=-Y,i1=D==="horizontal"?"end":"start";break;case"left":J=-Y,e1=j/2,i1=D==="horizontal"?"end":"middle"}else switch(B){case"top-left":J=Y,e1=-H,i1="start";break;case"top":J=I/2,e1=-H,i1=D==="horizontal"?"middle":"start";break;case"top-right":J=I-Y,e1=-H,i1=D==="horizontal"?"end":"start";break;case"right":J=I+Y,i1=D==="horizontal"?"start":"middle";break;case"bottom-right":J=I-Y,e1=H,i1="end";break;case"bottom":J=I/2,e1=H,i1=D==="horizontal"?"middle":"end";break;case"bottom-left":J=Y,e1=H,i1=D==="horizontal"?"start":"end";break;case"left":J=-Y,i1=D==="horizontal"?"end":"middle"}return{x:J,y:e1,rotation:o1,textAnchor:i1}}({axis:i,width:t,height:n,position:p,offsetX:m,offsetY:h,orientation:v});w=R.jsx("text",{transform:"translate("+b.x+", "+b.y+") rotate("+b.rotation+")",textAnchor:b.textAnchor,dominantBaseline:"central",style:f,children:d})}return R.jsxs("g",{transform:"translate("+E+", "+O+")",children:[R.jsx("line",{x1:0,x2:k,y1:0,y2:x,stroke:S.markers.lineColor,strokeWidth:S.markers.lineStrokeWidth,style:u}),w]})};oc.propTypes={width:C.number.isRequired,height:C.number.isRequired,axis:C.oneOf(["x","y"]).isRequired,scale:C.func.isRequired,value:C.oneOfType([C.number,C.string,C.instanceOf(Date)]).isRequired,lineStyle:C.object,textStyle:C.object,legend:C.string,legendPosition:C.oneOf(["top-left","top","top-right","right","bottom-right","bottom","bottom-left","left"]),legendOffsetX:C.number.isRequired,legendOffsetY:C.number.isRequired,legendOrientation:C.oneOf(["horizontal","vertical"]).isRequired},oc.defaultProps={legendPosition:"top-right",legendOffsetX:14,legendOffsetY:14,legendOrientation:"horizontal"};var KV=G.memo(oc),OS=function(e){var t=e.markers,n=e.width,i=e.height,r=e.xScale,a=e.yScale;return t&&t.length!==0?t.map(function(u,f){return R.jsx(KV,st({},u,{width:n,height:i,scale:u.axis==="y"?a:r}),f)}):null};OS.propTypes={width:C.number.isRequired,height:C.number.isRequired,xScale:C.func.isRequired,yScale:C.func.isRequired,markers:C.arrayOf(C.shape({axis:C.oneOf(["x","y"]).isRequired,value:C.oneOfType([C.number,C.string,C.instanceOf(Date)]).isRequired,lineStyle:C.object,textStyle:C.object}))};var JV=G.memo(OS),eY=["theme","renderWrapper","animate","motionConfig"],LS=function(e){return function(t){var n,i;function r(){return t.apply(this,arguments)||this}return i=t,(n=r).prototype=Object.create(i.prototype),n.prototype.constructor=n,ec(n,i),r.prototype.render=function(){var a=this.props,u=a.theme,f=a.renderWrapper,d=a.animate,p=a.motionConfig,m=gd(a,eY);return R.jsx(SS,{theme:u,renderWrapper:f,isInteractive:m.isInteractive,animate:d,motionConfig:p,children:R.jsx(e,st({},m))})},r}(G.Component)},tY=function(e,t){var n,i=Ul(e)?e:function(r){return t5(r,e)};return t&&(n=Ul(t)?t:ia(t)),n?function(r){return n(i(r))}:i},nY=function(e,t,n,i,r,a){return e<=r&&r<=e+n&&t<=a&&a<=t+i},FS=function(e,t){var n,i=t.clientX,r=t.clientY,a=e.getBoundingClientRect(),u=(n=e.getBBox!==void 0?e.getBBox():{width:e.offsetWidth,height:e.offsetHeight}).width===a.width?1:n.width/a.width;return[(i-a.left)*u,(r-a.top)*u]},iY=Object.keys(AS),rY=Object.keys(kS),oY=function(e,t,n){if(e==="*")return!0;if(Ul(e))return e(t);if(z$(e)){var i=n?t5(t,n):t;return vV(EG(i,Object.keys(e)),e)}return!1},aY=function(e,t,n,i){var r=i===void 0?{}:i,a=r.dataKey,u=r.colorKey,f=u===void 0?"color":u,d=r.targetKey,p=d===void 0?"fill":d,m=[],h={};return e.length&&t.length&&(m=[].concat(e),t.forEach(function(v){for(var S=function(){var k=n[E],O=k.id,x=k.match;if(oY(x,v,a)){var w=e.find(function(H){return H.id===O});if(w){if(rY.includes(w.type))if(w.background==="inherit"||w.color==="inherit"){var b=t5(v,f),N=w.background,$=w.color,I=O;w.background==="inherit"&&(I=I+".bg."+b,N=b),w.color==="inherit"&&(I=I+".fg."+b,$=b),qn(v,p,"url(#"+I+")"),h[I]||(m.push(st({},w,{id:I,background:N,color:$})),h[I]=1)}else qn(v,p,"url(#"+O+")");else if(iY.includes(w.type))if(w.colors.map(function(H){return H.color}).includes("inherit")){var j=t5(v,f),B=O,Y=st({},w,{colors:w.colors.map(function(H,D){return H.color!=="inherit"?H:(B=B+"."+D+"."+j,st({},H,{color:H.color==="inherit"?j:H.color}))})});Y.id=B,qn(v,p,"url(#"+B+")"),h[B]||(m.push(Y),h[B]=1)}else qn(v,p,"url(#"+O+")")}return"break"}},E=0;E>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?t8(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?t8(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=uY.exec(e))?new i4(t[1],t[2],t[3],1):(t=lY.exec(e))?new i4(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=cY.exec(e))?t8(t[1],t[2],t[3],t[4]):(t=fY.exec(e))?t8(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=dY.exec(e))?ky(t[1],t[2]/100,t[3]/100,1):(t=hY.exec(e))?ky(t[1],t[2]/100,t[3]/100,t[4]):xy.hasOwnProperty(e)?Ey(xy[e]):e==="transparent"?new i4(NaN,NaN,NaN,0):null}function Ey(e){return new i4(e>>16&255,e>>8&255,e&255,1)}function t8(e,t,n,i){return i<=0&&(e=t=n=NaN),new i4(e,t,n,i)}function mY(e){return e instanceof E9||(e=_d(e)),e?(e=e.rgb(),new i4(e.r,e.g,e.b,e.opacity)):new i4}function RS(e,t,n,i){return arguments.length===1?mY(e):new i4(e,t,n,i??1)}function i4(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}vd(i4,RS,IS(E9,{brighter(e){return e=e==null?Sr:Math.pow(Sr,e),new i4(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?u9:Math.pow(u9,e),new i4(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new i4(r5(this.r),r5(this.g),r5(this.b),Er(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:My,formatHex:My,formatHex8:yY,formatRgb:Ay,toString:Ay}));function My(){return`#${Yn(this.r)}${Yn(this.g)}${Yn(this.b)}`}function yY(){return`#${Yn(this.r)}${Yn(this.g)}${Yn(this.b)}${Yn((isNaN(this.opacity)?1:this.opacity)*255)}`}function Ay(){const e=Er(this.opacity);return`${e===1?"rgb(":"rgba("}${r5(this.r)}, ${r5(this.g)}, ${r5(this.b)}${e===1?")":`, ${e})`}`}function Er(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function r5(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Yn(e){return e=r5(e),(e<16?"0":"")+e.toString(16)}function ky(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new a2(e,t,n,i)}function US(e){if(e instanceof a2)return new a2(e.h,e.s,e.l,e.opacity);if(e instanceof E9||(e=_d(e)),!e)return new a2;if(e instanceof a2)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,r=Math.min(t,n,i),a=Math.max(t,n,i),u=NaN,f=a-r,d=(a+r)/2;return f?(t===a?u=(n-i)/f+(n0&&d<1?0:u,new a2(u,f,d,e.opacity)}function vY(e,t,n,i){return arguments.length===1?US(e):new a2(e,t,n,i??1)}function a2(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}vd(a2,vY,IS(E9,{brighter(e){return e=e==null?Sr:Math.pow(Sr,e),new a2(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?u9:Math.pow(u9,e),new a2(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,i=n+(n<.5?n:1-n)*t,r=2*n-i;return new i4(mu(e>=240?e-240:e+120,r,i),mu(e,r,i),mu(e<120?e+240:e-120,r,i),this.opacity)},clamp(){return new a2(Ty(this.h),n8(this.s),n8(this.l),Er(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=Er(this.opacity);return`${e===1?"hsl(":"hsla("}${Ty(this.h)}, ${n8(this.s)*100}%, ${n8(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ty(e){return e=(e||0)%360,e<0?e+360:e}function n8(e){return Math.max(0,Math.min(1,e||0))}function mu(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}function Mr(){return Mr=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,i=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var $S={nivo:["#e8c1a0","#f47560","#f1e15b","#e8a838","#61cdbb","#97e3d5"],category10:Lb,accent:Fb,dark2:Ib,paired:Rb,pastel1:Ub,pastel2:$b,set1:Bb,set2:zb,set3:nd},wY=Object.keys($S),BS={brown_blueGreen:Mo,purpleRed_green:Ao,pink_yellowGreen:ko,purple_orange:To,red_blue:Po,red_grey:Co,red_yellow_blue:No,red_yellow_green:Oo,spectral:Lo},xY=Object.keys(BS),bY={brown_blueGreen:NW,purpleRed_green:OW,pink_yellowGreen:LW,purple_orange:FW,red_blue:IW,red_grey:RW,red_yellow_blue:UW,red_yellow_green:$W,spectral:BW},zS={blues:Zo,greens:Go,greys:qo,oranges:Xo,purples:Vo,reds:Yo,blue_green:Fo,blue_purple:Io,green_blue:Ro,orange_red:Uo,purple_blue_green:$o,purple_blue:Bo,purple_red:zo,red_purple:jo,yellow_green_blue:Do,yellow_green:Qo,yellow_orange_brown:Wo,yellow_orange_red:Ho},SY=Object.keys(zS),EY={blues:KW,greens:JW,greys:eH,oranges:iH,purples:tH,reds:nH,turbo:dH,viridis:hH,inferno:gH,magma:pH,plasma:mH,cividis:rH,warm:aH,cool:sH,cubehelixDefault:oH,blue_green:zW,blue_purple:jW,green_blue:DW,orange_red:QW,purple_blue_green:WW,purple_blue:HW,purple_red:ZW,red_purple:GW,yellow_green_blue:qW,yellow_green:VW,yellow_orange_brown:YW,yellow_orange_red:XW},T8=Mr({},$S,BS,zS),MY=Object.keys(T8),AY=function(e){return wY.includes(e)},kY=function(e){return xY.includes(e)},TY=function(e){return SY.includes(e)},PY={rainbow:uH,sinebow:fH};Mr({},bY,EY,PY);var CY=function(e,t){if(typeof e=="function")return e;if(i5.isPlainObject(e)){if(function(d){return d.theme!==void 0}(e)){if(t===void 0)throw new Error("Unable to use color from theme as no theme was provided");var n=i5.get(t,e.theme);if(n===void 0)throw new Error("Color from theme is undefined at path: '"+e.theme+"'");return function(){return n}}if(function(d){return d.from!==void 0}(e)){var i=function(d){return i5.get(d,e.from)};if(Array.isArray(e.modifiers)){for(var r,a=[],u=function(){var d=r.value,p=d[0],m=d[1];if(p==="brighter")a.push(function(h){return h.brighter(m)});else if(p==="darker")a.push(function(h){return h.darker(m)});else{if(p!=="opacity")throw new Error("Invalid color modifier: '"+p+"', must be one of: 'brighter', 'darker', 'opacity'");a.push(function(h){return h.opacity=m,h})}},f=_Y(e.modifiers);!(r=f()).done;)u();return a.length===0?i:function(d){return a.reduce(function(p,m){return m(p)},RS(i(d))).toString()}}return i}throw new Error("Invalid color spec, you should either specify 'theme' or 'from' when using a config object")}return function(){return e}},Ar=function(e,t){return G.useMemo(function(){return CY(e,t)},[e,t])},NY=C.oneOfType([C.func,C.arrayOf(C.string),C.shape({scheme:C.oneOf(MY).isRequired,size:C.number}),C.shape({datum:C.string.isRequired}),C.string]);C.oneOfType([C.string,C.func,C.shape({theme:C.string.isRequired}),C.shape({from:C.string.isRequired,modifiers:C.arrayOf(C.array)})]);var OY=function(e,t){if(typeof e=="function")return e;var n=typeof t=="function"?t:function(h){return i5.get(h,t)};if(Array.isArray(e)){var i=Vn(e),r=function(h){return i(n(h))};return r.scale=i,r}if(i5.isPlainObject(e)){if(function(h){return h.datum!==void 0}(e))return function(h){return i5.get(h,e.datum)};if(function(h){return h.scheme!==void 0}(e)){if(AY(e.scheme)){var a=Vn(T8[e.scheme]),u=function(h){return a(n(h))};return u.scale=a,u}if(kY(e.scheme)){if(e.size!==void 0&&(e.size<3||e.size>11))throw new Error("Invalid size '"+e.size+"' for diverging color scheme '"+e.scheme+"', must be between 3~11");var f=Vn(T8[e.scheme][e.size||11]),d=function(h){return f(n(h))};return d.scale=f,d}if(TY(e.scheme)){if(e.size!==void 0&&(e.size<3||e.size>9))throw new Error("Invalid size '"+e.size+"' for sequential color scheme '"+e.scheme+"', must be between 3~9");var p=Vn(T8[e.scheme][e.size||9]),m=function(h){return p(n(h))};return m.scale=p,m}}throw new Error("Invalid colors, when using an object, you should either pass a 'datum' or a 'scheme' property")}return function(){return e}},LY=function(e,t){return G.useMemo(function(){return OY(e,t)},[e,t])};function FY(){}var IY=FY,yu=dS,RY=IY,UY=dd,$Y=1/0,BY=yu&&1/UY(new yu([,-0]))[1]==$Y?function(e){return new yu(e)}:RY,zY=BY,jY=id,DY=jb,QY=Db,WY=rd,HY=zY,ZY=dd,GY=200;function qY(e,t,n){var i=-1,r=DY,a=e.length,u=!0,f=[],d=f;if(n)u=!1,r=QY;else if(a>=GY){var p=t?null:HY(e);if(p)return ZY(p);u=!1,r=WY,d=new jY}else d=t?[]:f;e:for(;++it||a&&u&&d&&!f&&!p||i&&u&&d||!n&&d||!r)return 1;if(!i&&!a&&!p&&e=f)return d;var p=n[i];return d*(p=="desc"?-1:1)}}return e.index-t.index}var mK=gK,vu=jf,yK=go,vK=WS,_K=lK,wK=fK,xK=lo,bK=mK,SK=fo,EK=h2;function MK(e,t,n){t.length?t=vu(t,function(a){return EK(a)?function(u){return yK(u,a.length===1?a[0]:a)}:a}):t=[SK];var i=-1;t=vu(t,xK(vK));var r=_K(e,function(a,u,f){var d=vu(t,function(p){return p(a)});return{criteria:d,index:++i,value:a}});return wK(r,function(a,u){return bK(a,u,n)})}var AK=MK,kK=cS,TK=AK,PK=$f,Oy=Dx,CK=PK(function(e,t){if(e==null)return[];var n=t.length;return n>1&&Oy(e,t[0],t[1])?t=[]:n>2&&Oy(t[0],t[1],t[2])&&(t=[t[0]]),TK(e,kK(t,1),[])}),NK=CK;const OK=Ot(NK);var LK=v5,FK=sn,IK="[object Date]";function RK(e){return FK(e)&&LK(e)==IK}var UK=RK,$K=UK,BK=lo,Ly=Fx,Fy=Ly&&Ly.isDate,zK=Fy?BK(Fy):$K,jK=zK;const DK=Ot(jK);var _u=new Date,wu=new Date;function dt(e,t,n,i){function r(a){return e(a=arguments.length===0?new Date:new Date(+a)),a}return r.floor=function(a){return e(a=new Date(+a)),a},r.ceil=function(a){return e(a=new Date(a-1)),t(a,1),e(a),a},r.round=function(a){var u=r(a),f=r.ceil(a);return a-u0))return d;do d.push(p=new Date(+a)),t(a,f),e(a);while(p=u)for(;e(u),!a(u);)u.setTime(u-1)},function(u,f){if(u>=u)if(f<0)for(;++f<=0;)for(;t(u,-1),!a(u););else for(;--f>=0;)for(;t(u,1),!a(u););})},n&&(r.count=function(a,u){return _u.setTime(+a),wu.setTime(+u),e(_u),e(wu),Math.floor(n(_u,wu))},r.every=function(a){return a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?r.filter(i?function(u){return i(u)%a===0}:function(u){return r.count(0,u)%a===0}):r}),r}var kr=dt(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});kr.every=function(e){return e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?dt(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):kr};const Iy=kr;kr.range;var Tr=1e3,X6=6e4,Pr=36e5,HS=6048e5,ZS=dt(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+t*Tr)},function(e,t){return(t-e)/Tr},function(e){return e.getUTCSeconds()});const Ry=ZS;ZS.range;var GS=dt(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*Tr)},function(e,t){e.setTime(+e+t*X6)},function(e,t){return(t-e)/X6},function(e){return e.getMinutes()});const QK=GS;GS.range;var qS=dt(function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*Tr-e.getMinutes()*X6)},function(e,t){e.setTime(+e+t*Pr)},function(e,t){return(t-e)/Pr},function(e){return e.getHours()});const WK=qS;qS.range;function E5(e){return dt(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(t,n){t.setDate(t.getDate()+n*7)},function(t,n){return(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*X6)/HS})}var ac=E5(0),VS=E5(1),YS=E5(2),XS=E5(3),KS=E5(4),JS=E5(5),eE=E5(6);ac.range;VS.range;YS.range;XS.range;KS.range;JS.range;eE.range;var tE=dt(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12},function(e){return e.getMonth()});const HK=tE;tE.range;var wd=dt(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()});wd.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:dt(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)})};const ZK=wd;wd.range;var nE=dt(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*X6)},function(e,t){return(t-e)/X6},function(e){return e.getUTCMinutes()});const GK=nE;nE.range;var iE=dt(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+t*Pr)},function(e,t){return(t-e)/Pr},function(e){return e.getUTCHours()});const qK=iE;iE.range;function M5(e){return dt(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCDate(t.getUTCDate()+n*7)},function(t,n){return(n-t)/HS})}var sc=M5(0),rE=M5(1),oE=M5(2),aE=M5(3),sE=M5(4),uE=M5(5),lE=M5(6);sc.range;rE.range;oE.range;aE.range;sE.range;uE.range;lE.range;var cE=dt(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12},function(e){return e.getUTCMonth()});const VK=cE;cE.range;var xd=dt(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()});xd.every=function(e){return!isFinite(e=Math.floor(e))||!(e>0)?null:dt(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})};const YK=xd;xd.range;function Qn(){return Qn=Object.assign?Object.assign.bind():function(e){for(var t=1;t0?(x=v.align[O?"left":"right"],w=v.baseline.center):(r==="after"&&d>0||r==="before"&&d<0)&&(x=v.align[O?"right":"left"],w=v.baseline.center)):(t=function(b){var N;return{x:0,y:(N=S(b))!=null?N:0}},E.lineX=u*(r==="after"?1:-1),k.textX=(u+f)*(r==="after"?1:-1),x=r==="after"?v.align.left:v.align.right),{ticks:h.map(function(b){return d2({key:b instanceof Date?""+b.valueOf():""+b,value:b},t(b),E,k)}),textAlign:x,textBaseline:w}},yE=function(e,t){if(e===void 0||typeof e=="function")return e;if(t.type==="time"){var n=Eo(e);return function(i){return n(i instanceof Date?i:new Date(i))}}return ia(e)},uc=function(e){var t,n=e.width,i=e.height,r=e.scale,a=e.axis,u=e.values,f=(t=u,(Array.isArray(t)?u:void 0)||gE(r,u)),d="bandwidth"in r?hE(r):r,p=a==="x"?f.map(function(m){var h,v;return{key:m instanceof Date?""+m.valueOf():""+m,x1:(h=d(m))!=null?h:0,x2:(v=d(m))!=null?v:0,y1:0,y2:i}}):f.map(function(m){var h,v;return{key:m instanceof Date?""+m.valueOf():""+m,x1:0,x2:n,y1:(h=d(m))!=null?h:0,y2:(v=d(m))!=null?v:0}});return p},mJ=G.memo(function(e){var t,n=e.value,i=e.format,r=e.lineX,a=e.lineY,u=e.onClick,f=e.textBaseline,d=e.textAnchor,p=e.animatedProps,m=Lt(),h=(t=i==null?void 0:i(n))!=null?t:n,v=G.useMemo(function(){var S={opacity:p.opacity};return u?{style:d2({},S,{cursor:"pointer"}),onClick:function(E){return u(E,h)}}:{style:S}},[p.opacity,u,h]);return R.jsxs(F2.g,d2({transform:p.transform},v,{children:[R.jsx("line",{x1:0,x2:r,y1:0,y2:a,style:m.axis.ticks.line}),R.jsx(F2.text,{dominantBaseline:f,textAnchor:d,transform:p.textTransform,style:m.axis.ticks.text,children:""+h})]}))}),yJ=G.memo(function(e){var t=e.axis,n=e.scale,i=e.x,r=i===void 0?0:i,a=e.y,u=a===void 0?0:a,f=e.length,d=e.ticksPosition,p=e.tickValues,m=e.tickSize,h=m===void 0?5:m,v=e.tickPadding,S=v===void 0?5:v,E=e.tickRotation,k=E===void 0?0:E,O=e.format,x=e.renderTick,w=x===void 0?mJ:x,b=e.legend,N=e.legendPosition,$=N===void 0?"end":N,I=e.legendOffset,j=I===void 0?0:I,B=e.onClick,Y=e.ariaHidden,H=Lt(),D=G.useMemo(function(){return yE(O,n)},[O,n]),J=mE({axis:t,scale:n,ticksPosition:d,tickValues:p,tickSize:h,tickPadding:S,tickRotation:k}),e1=J.ticks,o1=J.textAlign,i1=J.textBaseline,l1=null;if(b!==void 0){var r1,V=0,p1=0,f1=0;t==="y"?(f1=-90,V=j,$==="start"?(r1="start",p1=f):$==="middle"?(r1="middle",p1=f/2):$==="end"&&(r1="end")):(p1=j,$==="start"?r1="start":$==="middle"?(r1="middle",V=f/2):$==="end"&&(r1="end",V=f)),l1=R.jsx("text",{transform:"translate("+V+", "+p1+") rotate("+f1+")",textAnchor:r1,style:d2({dominantBaseline:"central"},H.axis.legend.text),children:b})}var w1=S5(),T1=w1.animate,j1=w1.config,F1=n0({transform:"translate("+r+","+u+")",lineX2:t==="x"?f:0,lineY2:t==="x"?0:f,config:j1,immediate:!T1}),_1=hx(e1,{keys:function(d1){return d1.key},initial:function(d1){return{opacity:1,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},from:function(d1){return{opacity:0,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},enter:function(d1){return{opacity:1,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},update:function(d1){return{opacity:1,transform:"translate("+d1.x+","+d1.y+")",textTransform:"translate("+d1.textX+","+d1.textY+") rotate("+k+")"}},leave:{opacity:0},config:j1,immediate:!T1});return R.jsxs(F2.g,{transform:F1.transform,"aria-hidden":Y,children:[_1(function(d1,I1,W1,E1){return G.createElement(w,d2({tickIndex:E1,format:D,rotate:k,textBaseline:i1,textAnchor:o1,animatedProps:d1},I1,B?{onClick:B}:{}))}),R.jsx(F2.line,{style:H.axis.domain.line,x1:0,x2:F1.lineX2,y1:0,y2:F1.lineY2}),l1]})}),vJ={ticksPosition:C.oneOf(["before","after"]),tickValues:C.oneOfType([C.number,C.arrayOf(C.oneOfType([C.number,C.string,C.instanceOf(Date)])),C.string]),tickSize:C.number,tickPadding:C.number,tickRotation:C.number,format:C.oneOfType([C.func,C.string]),renderTick:C.func,legend:C.node,legendPosition:C.oneOf(["start","middle","end"]),legendOffset:C.number,ariaHidden:C.bool},i8=C.shape(vJ),vE=["top","right","bottom","left"],_J=G.memo(function(e){var t=e.xScale,n=e.yScale,i=e.width,r=e.height,a={top:e.top,right:e.right,bottom:e.bottom,left:e.left};return R.jsx(R.Fragment,{children:vE.map(function(u){var f=a[u];if(!f)return null;var d=u==="top"||u==="bottom";return R.jsx(yJ,d2({},f,{axis:d?"x":"y",x:u==="right"?i:0,y:u==="bottom"?r:0,scale:d?t:n,length:d?i:r,ticksPosition:u==="top"||u==="left"?"before":"after"}),u)})})}),wJ=G.memo(function(e){var t=e.animatedProps,n=Lt();return R.jsx(F2.line,d2({},t,n.grid.line))}),zy=G.memo(function(e){var t=e.lines,n=S5(),i=n.animate,r=n.config,a=hx(t,{keys:function(u){return u.key},initial:function(u){return{opacity:1,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},from:function(u){return{opacity:0,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},enter:function(u){return{opacity:1,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},update:function(u){return{opacity:1,x1:u.x1,x2:u.x2,y1:u.y1,y2:u.y2}},leave:{opacity:0},config:r,immediate:!i});return R.jsx("g",{children:a(function(u,f){return G.createElement(wJ,d2({},f,{key:f.key,animatedProps:u}))})})}),xJ=G.memo(function(e){var t=e.width,n=e.height,i=e.xScale,r=e.yScale,a=e.xValues,u=e.yValues,f=G.useMemo(function(){return!!i&&uc({width:t,height:n,scale:i,axis:"x",values:a})},[i,a,t,n]),d=G.useMemo(function(){return!!r&&uc({width:t,height:n,scale:r,axis:"y",values:u})},[n,t,r,u]);return R.jsxs(R.Fragment,{children:[f&&R.jsx(zy,{lines:f}),d&&R.jsx(zy,{lines:d})]})}),bJ=function(e,t){var n,i=t.axis,r=t.scale,a=t.x,u=a===void 0?0:a,f=t.y,d=f===void 0?0:f,p=t.length,m=t.ticksPosition,h=t.tickValues,v=t.tickSize,S=v===void 0?5:v,E=t.tickPadding,k=E===void 0?5:E,O=t.tickRotation,x=O===void 0?0:O,w=t.format,b=t.legend,N=t.legendPosition,$=N===void 0?"end":N,I=t.legendOffset,j=I===void 0?0:I,B=t.theme,Y=mE({axis:i,scale:r,ticksPosition:m,tickValues:h,tickSize:S,tickPadding:k,tickRotation:x,engine:"canvas"}),H=Y.ticks,D=Y.textAlign,J=Y.textBaseline;e.save(),e.translate(u,d),e.textAlign=D,e.textBaseline=J,e.font=(B.axis.ticks.text.fontWeight?B.axis.ticks.text.fontWeight+" ":"")+B.axis.ticks.text.fontSize+"px "+B.axis.ticks.text.fontFamily,((n=B.axis.domain.line.strokeWidth)!=null?n:0)>0&&(e.lineWidth=Number(B.axis.domain.line.strokeWidth),e.lineCap="square",B.axis.domain.line.stroke&&(e.strokeStyle=B.axis.domain.line.stroke),e.beginPath(),e.moveTo(0,0),e.lineTo(i==="x"?p:0,i==="x"?0:p),e.stroke());var e1=typeof w=="function"?w:function(V){return""+V};if(H.forEach(function(V){var p1;((p1=B.axis.ticks.line.strokeWidth)!=null?p1:0)>0&&(e.lineWidth=Number(B.axis.ticks.line.strokeWidth),e.lineCap="square",B.axis.ticks.line.stroke&&(e.strokeStyle=B.axis.ticks.line.stroke),e.beginPath(),e.moveTo(V.x,V.y),e.lineTo(V.x+V.lineX,V.y+V.lineY),e.stroke());var f1=e1(V.value);e.save(),e.translate(V.x+V.textX,V.y+V.textY),e.rotate(br(x)),B.axis.ticks.text.fill&&(e.fillStyle=B.axis.ticks.text.fill),e.fillText(String(f1),0,0),e.restore()}),b!==void 0){var o1=0,i1=0,l1=0,r1="center";i==="y"?(l1=-90,o1=j,$==="start"?(r1="start",i1=p):$==="middle"?(r1="center",i1=p/2):$==="end"&&(r1="end")):(i1=j,$==="start"?r1="start":$==="middle"?(r1="center",o1=p/2):$==="end"&&(r1="end",o1=p)),e.translate(o1,i1),e.rotate(br(l1)),e.font=(B.axis.legend.text.fontWeight?B.axis.legend.text.fontWeight+" ":"")+B.axis.legend.text.fontSize+"px "+B.axis.legend.text.fontFamily,B.axis.legend.text.fill&&(e.fillStyle=B.axis.legend.text.fill),e.textAlign=r1,e.textBaseline="middle",e.fillText(b,0,0)}e.restore()},SJ=function(e,t){var n=t.xScale,i=t.yScale,r=t.width,a=t.height,u=t.top,f=t.right,d=t.bottom,p=t.left,m=t.theme,h={top:u,right:f,bottom:d,left:p};vE.forEach(function(v){var S=h[v];if(!S)return null;var E=v==="top"||v==="bottom",k=v==="top"||v==="left"?"before":"after",O=E?n:i,x=yE(S.format,O);bJ(e,d2({},S,{axis:E?"x":"y",x:v==="right"?r:0,y:v==="bottom"?a:0,scale:O,format:x,length:E?r:a,ticksPosition:k,theme:m}))})},jy=function(e,t){var n=t.width,i=t.height,r=t.scale,a=t.axis,u=t.values;uc({width:n,height:i,scale:r,axis:a,values:u}).forEach(function(f){e.beginPath(),e.moveTo(f.x1,f.y1),e.lineTo(f.x2,f.y2),e.stroke()})},EJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,a=e.opacity,u=a===void 0?1:a,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return R.jsx("circle",{r:i/2,cx:t+i/2,cy:n+i/2,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,style:{pointerEvents:"none"}})},MJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,a=e.opacity,u=a===void 0?1:a,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return R.jsx("g",{transform:"translate("+t+","+n+")",children:R.jsx("path",{d:` - M`+i/2+` 0 - L`+.8*i+" "+i/2+` - L`+i/2+" "+i+` - L`+.2*i+" "+i/2+` - L`+i/2+` 0 - `,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,style:{pointerEvents:"none"}})})},AJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,a=e.opacity,u=a===void 0?1:a,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return R.jsx("rect",{x:t,y:n,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,width:i,height:i,style:{pointerEvents:"none"}})},kJ=function(e){var t=e.x,n=e.y,i=e.size,r=e.fill,a=e.opacity,u=a===void 0?1:a,f=e.borderWidth,d=f===void 0?0:f,p=e.borderColor;return R.jsx("g",{transform:"translate("+t+","+n+")",children:R.jsx("path",{d:` - M`+i/2+` 0 - L`+i+" "+i+` - L0 `+i+` - L`+i/2+` 0 - `,fill:r,opacity:u,strokeWidth:d,stroke:p===void 0?"transparent":p,style:{pointerEvents:"none"}})})};function Xn(){return Xn=Object.assign?Object.assign.bind():function(e){for(var t=1;t>1;if(n>0&&typeof t[0]!="number")throw new Error("Expected coords to contain numbers.");this.coords=t;const i=Math.max(2*n-5,0);this._triangles=new Uint32Array(i*3),this._halfedges=new Int32Array(i*3),this._hashSize=Math.ceil(Math.sqrt(n)),this._hullPrev=new Uint32Array(n),this._hullNext=new Uint32Array(n),this._hullTri=new Uint32Array(n),this._hullHash=new Int32Array(this._hashSize).fill(-1),this._ids=new Uint32Array(n),this._dists=new Float64Array(n),this.update()}update(){const{coords:t,_hullPrev:n,_hullNext:i,_hullTri:r,_hullHash:a}=this,u=t.length>>1;let f=1/0,d=1/0,p=-1/0,m=-1/0;for(let H=0;Hp&&(p=D),J>m&&(m=J),this._ids[H]=H}const h=(f+p)/2,v=(d+m)/2;let S=1/0,E,k,O;for(let H=0;H0&&(k=H,S=D)}let b=t[2*k],N=t[2*k+1],$=1/0;for(let H=0;He1&&(H[D++]=o1,e1=this._dists[o1])}this.hull=H.subarray(0,D),this.triangles=new Uint32Array(0),this.halfedges=new Uint32Array(0);return}if(o8(x,w,b,N,I,j)){const H=k,D=b,J=N;k=O,b=I,N=j,O=H,I=D,j=J}const B=BJ(x,w,b,N,I,j);this._cx=B.x,this._cy=B.y;for(let H=0;H0&&Math.abs(o1-D)<=Dy&&Math.abs(i1-J)<=Dy||(D=o1,J=i1,e1===E||e1===k||e1===O))continue;let l1=0;for(let w1=0,T1=this._hashKey(o1,i1);w10?3-n:1+n)/4}function xu(e,t,n,i){const r=e-n,a=t-i;return r*r+a*a}function bu(e,t,n,i,r,a){const u=(i-t)*(r-e),f=(n-e)*(a-t);return Math.abs(u-f)>=33306690738754716e-32*Math.abs(u+f)?u-f:0}function o8(e,t,n,i,r,a){return(bu(r,a,e,t,n,i)||bu(e,t,n,i,r,a)||bu(n,i,r,a,e,t))<0}function UJ(e,t,n,i,r,a,u,f){const d=e-u,p=t-f,m=n-u,h=i-f,v=r-u,S=a-f,E=d*d+p*p,k=m*m+h*h,O=v*v+S*S;return d*(h*O-k*S)-p*(m*O-k*v)+E*(m*S-h*v)<0}function $J(e,t,n,i,r,a){const u=n-e,f=i-t,d=r-e,p=a-t,m=u*u+f*f,h=d*d+p*p,v=.5/(u*p-f*d),S=(p*m-f*h)*v,E=(u*h-d*m)*v;return S*S+E*E}function BJ(e,t,n,i,r,a){const u=n-e,f=i-t,d=r-e,p=a-t,m=u*u+f*f,h=d*d+p*p,v=.5/(u*p-f*d),S=e+(p*m-f*h)*v,E=t+(u*h-d*m)*v;return{x:S,y:E}}function M6(e,t,n,i){if(i-n<=20)for(let r=n+1;r<=i;r++){const a=e[r],u=t[a];let f=r-1;for(;f>=n&&t[e[f]]>u;)e[f+1]=e[f--];e[f+1]=a}else{const r=n+i>>1;let a=n+1,u=i;c7(e,r,a),t[e[n]]>t[e[i]]&&c7(e,n,i),t[e[a]]>t[e[i]]&&c7(e,a,i),t[e[n]]>t[e[a]]&&c7(e,n,a);const f=e[a],d=t[f];for(;;){do a++;while(t[e[a]]d);if(u=u-n?(M6(e,t,a,i),M6(e,t,n,u-1)):(M6(e,t,n,u-1),M6(e,t,a,i))}}function c7(e,t,n){const i=e[t];e[t]=e[n],e[n]=i}function zJ(e){return e[0]}function jJ(e){return e[1]}const Qy=1e-6;class Kn{constructor(){this._x0=this._y0=this._x1=this._y1=null,this._=""}moveTo(t,n){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")}lineTo(t,n){this._+=`L${this._x1=+t},${this._y1=+n}`}arc(t,n,i){t=+t,n=+n,i=+i;const r=t+i,a=n;if(i<0)throw new Error("negative radius");this._x1===null?this._+=`M${r},${a}`:(Math.abs(this._x1-r)>Qy||Math.abs(this._y1-a)>Qy)&&(this._+="L"+r+","+a),i&&(this._+=`A${i},${i},0,1,1,${t-i},${n}A${i},${i},0,1,1,${this._x1=r},${this._y1=a}`)}rect(t,n,i,r){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${+i}v${+r}h${-i}Z`}value(){return this._||null}}let lc=class{constructor(){this._=[]}moveTo(t,n){this._.push([t,n])}closePath(){this._.push(this._[0].slice())}lineTo(t,n){this._.push([t,n])}value(){return this._.length?this._:null}};class DJ{constructor(t,[n,i,r,a]=[0,0,960,500]){if(!((r=+r)>=(n=+n))||!((a=+a)>=(i=+i)))throw new Error("invalid bounds");this.delaunay=t,this._circumcenters=new Float64Array(t.points.length*2),this.vectors=new Float64Array(t.points.length*2),this.xmax=r,this.xmin=n,this.ymax=a,this.ymin=i,this._init()}update(){return this.delaunay.update(),this._init(),this}_init(){const{delaunay:{points:t,hull:n,triangles:i},vectors:r}=this,a=this.circumcenters=this._circumcenters.subarray(0,i.length/3*2);for(let S=0,E=0,k=i.length,O,x;S1;)a-=2;for(let u=2;u4)for(let u=0;u0){if(n>=this.ymax)return null;(u=(this.ymax-n)/r)0){if(t>=this.xmax)return null;(u=(this.xmax-t)/i)this.xmax?2:0)|(nthis.ymax?8:0)}}const QJ=2*Math.PI,a6=Math.pow;function WJ(e){return e[0]}function HJ(e){return e[1]}function ZJ(e){const{triangles:t,coords:n}=e;for(let i=0;i1e-10)return!1}return!0}function GJ(e,t,n){return[e+Math.sin(e+t)*n,t+Math.cos(e-t)*n]}class Sd{static from(t,n=WJ,i=HJ,r){return new Sd("length"in t?qJ(t,n,i,r):Float64Array.from(VJ(t,n,i,r)))}constructor(t){this._delaunator=new Cr(t),this.inedges=new Int32Array(t.length/2),this._hullIndex=new Int32Array(t.length/2),this.points=this._delaunator.coords,this._init()}update(){return this._delaunator.update(),this._init(),this}_init(){const t=this._delaunator,n=this.points;if(t.hull&&t.hull.length>2&&ZJ(t)){this.collinear=Int32Array.from({length:n.length/2},(v,S)=>S).sort((v,S)=>n[2*v]-n[2*S]||n[2*v+1]-n[2*S+1]);const d=this.collinear[0],p=this.collinear[this.collinear.length-1],m=[n[2*d],n[2*d+1],n[2*p],n[2*p+1]],h=1e-8*Math.hypot(m[3]-m[1],m[2]-m[0]);for(let v=0,S=n.length/2;v0&&(this.triangles=new Int32Array(3).fill(-1),this.halfedges=new Int32Array(3).fill(-1),this.triangles[0]=r[0],this.triangles[1]=r[1],this.triangles[2]=r[1],u[r[0]]=1,r.length===2&&(u[r[1]]=0))}voronoi(t){return new DJ(this,t)}*neighbors(t){const{inedges:n,hull:i,_hullIndex:r,halfedges:a,triangles:u,collinear:f}=this;if(f){const h=f.indexOf(t);h>0&&(yield f[h-1]),h=0&&a!==i&&a!==r;)i=a;return a}_step(t,n,i){const{inedges:r,hull:a,_hullIndex:u,halfedges:f,triangles:d,points:p}=this;if(r[t]===-1||!p.length)return(t+1)%(p.length>>1);let m=t,h=a6(n-p[t*2],2)+a6(i-p[t*2+1],2);const v=r[t];let S=v;do{let E=d[S];const k=a6(n-p[E*2],2)+a6(i-p[E*2+1],2);if(k-1?d1.filter(function(I1){return I1!==_1}):[].concat(d1,[_1])})},[]),j1=function(_1){var d1=_1.series,I1=_1.getPointColor,W1=_1.getPointBorderColor,E1=_1.formatX,O1=_1.formatY;return G.useMemo(function(){return d1.reduce(function(R1,g1){return[].concat(R1,g1.data.filter(function(J1){return J1.position.x!==null&&J1.position.y!==null}).map(function(J1,D1){var ae={id:g1.id+"."+D1,index:R1.length+D1,serieId:g1.id,serieColor:g1.color,x:J1.position.x,y:J1.position.y};return ae.color=I1(g1),ae.borderColor=W1(ae),ae.data=Ct({},J1.data,{xFormatted:E1(J1.data.x),yFormatted:O1(J1.data.y)}),ae}))},[])},[d1,I1,W1,E1,O1])}({series:w1,getPointColor:H,getPointBorderColor:D,formatX:I,formatY:j}),F1=u11({enableSlices:$,points:j1,width:d,height:p});return{legendData:f1,toggleSerie:T1,lineGenerator:a11({curve:S}),areaGenerator:s11({curve:S,yScale:r1,areaBaselineValue:k}),getColor:B,series:w1,xScale:l1,yScale:r1,slices:F1,points:j1}},kE=function(e){var t=e.areaBlendMode,n=e.areaOpacity,i=e.color,r=e.fill,a=e.path,u=S5(),f=u.animate,d=u.config,p=mS(a),m=n0({color:i,config:d,immediate:!f});return R.jsx(F2.path,{d:p,fill:r||m.color,fillOpacity:n,strokeWidth:0,style:{mixBlendMode:t}})};kE.propTypes={areaBlendMode:yd.isRequired,areaOpacity:C.number.isRequired,color:C.string,fill:C.string,path:C.string.isRequired};var TE=function(e){var t=e.areaGenerator,n=e.areaOpacity,i=e.areaBlendMode,r=e.lines.slice(0).reverse();return R.jsx("g",{children:r.map(function(a){return R.jsx(kE,Ct({path:t(a.data.map(function(u){return u.position}))},Ct({areaOpacity:n,areaBlendMode:i},a)),a.id)})})};TE.propTypes={areaGenerator:C.func.isRequired,areaOpacity:C.number.isRequired,areaBlendMode:yd.isRequired,lines:C.arrayOf(C.object).isRequired};var l11=G.memo(TE),PE=function(e){var t=e.lineGenerator,n=e.points,i=e.color,r=e.thickness,a=G.useMemo(function(){return t(n)},[t,n]),u=mS(a);return R.jsx(F2.path,{d:u,fill:"none",strokeWidth:r,stroke:i})};PE.propTypes={points:C.arrayOf(C.shape({x:C.oneOfType([C.string,C.number]),y:C.oneOfType([C.string,C.number])})),lineGenerator:C.func.isRequired,color:C.string.isRequired,thickness:C.number.isRequired};var c11=G.memo(PE),CE=function(e){var t=e.lines,n=e.lineGenerator,i=e.lineWidth;return t.slice(0).reverse().map(function(r){var a=r.id,u=r.data,f=r.color;return R.jsx(c11,{id:a,points:u.map(function(d){return d.position}),lineGenerator:n,color:f,thickness:i},a)})};CE.propTypes={lines:C.arrayOf(C.shape({id:C.oneOfType([C.string,C.number]).isRequired,color:C.string.isRequired,data:C.arrayOf(C.shape({data:C.shape({x:C.oneOfType([C.string,C.number,C.instanceOf(Date)]),y:C.oneOfType([C.string,C.number,C.instanceOf(Date)])}).isRequired,position:C.shape({x:C.number,y:C.number}).isRequired})).isRequired})).isRequired,lineWidth:C.number.isRequired,lineGenerator:C.func.isRequired};var f11=G.memo(CE),NE=function(e){var t=e.slice,n=e.axis,i=e.debug,r=e.tooltip,a=e.isCurrent,u=e.setCurrent,f=e.onMouseEnter,d=e.onMouseMove,p=e.onMouseLeave,m=e.onClick,h=Pf(),v=h.showTooltipFromEvent,S=h.hideTooltip,E=G.useCallback(function(w){v(G.createElement(r,{slice:t,axis:n}),w,"right"),u(t),f&&f(t,w)},[v,r,t,f]),k=G.useCallback(function(w){v(G.createElement(r,{slice:t,axis:n}),w,"right"),d&&d(t,w)},[v,r,t,d]),O=G.useCallback(function(w){S(),u(null),p&&p(t,w)},[S,t,p]),x=G.useCallback(function(w){m&&m(t,w)},[t,m]);return R.jsx("rect",{x:t.x0,y:t.y0,width:t.width,height:t.height,stroke:"red",strokeWidth:i?1:0,strokeOpacity:.75,fill:"red",fillOpacity:a&&i?.35:0,onMouseEnter:E,onMouseMove:k,onMouseLeave:O,onClick:x,"data-testid":"slice-"+t.id})};NE.propTypes={slice:C.object.isRequired,axis:C.oneOf(["x","y"]).isRequired,debug:C.bool.isRequired,height:C.number.isRequired,tooltip:C.oneOfType([C.func,C.object]),isCurrent:C.bool.isRequired,setCurrent:C.func.isRequired,onMouseEnter:C.func,onMouseMove:C.func,onMouseLeave:C.func,onClick:C.func};var d11=G.memo(NE),OE=function(e){var t=e.slices,n=e.axis,i=e.debug,r=e.height,a=e.tooltip,u=e.current,f=e.setCurrent,d=e.onMouseEnter,p=e.onMouseMove,m=e.onMouseLeave,h=e.onClick;return t.map(function(v){return R.jsx(d11,{slice:v,axis:n,debug:i,height:r,tooltip:a,setCurrent:f,isCurrent:u!==null&&u.id===v.id,onMouseEnter:d,onMouseMove:p,onMouseLeave:m,onClick:h},v.id)})};OE.propTypes={slices:C.arrayOf(C.shape({id:C.oneOfType([C.number,C.string,C.instanceOf(Date)]).isRequired,x:C.number.isRequired,y:C.number.isRequired,points:C.arrayOf(C.object).isRequired})).isRequired,axis:C.oneOf(["x","y"]).isRequired,debug:C.bool.isRequired,height:C.number.isRequired,tooltip:C.oneOfType([C.func,C.object]).isRequired,current:C.object,setCurrent:C.func.isRequired,onMouseEnter:C.func,onMouseMove:C.func,onMouseLeave:C.func,onClick:C.func};var h11=G.memo(OE),LE=function(e){var t=e.points,n=e.symbol,i=e.size,r=e.borderWidth,a=e.enableLabel,u=e.label,f=e.labelYOffset,d=Lt(),p=tY(u),m=t.slice(0).reverse().map(function(h){return{id:h.id,x:h.x,y:h.y,datum:h.data,fill:h.color,stroke:h.borderColor,label:a?p(h.data):null}});return R.jsx("g",{children:m.map(function(h){return R.jsx(XV,{x:h.x,y:h.y,datum:h.datum,symbol:n,size:i,color:h.fill,borderWidth:r,borderColor:h.stroke,label:h.label,labelYOffset:f,theme:d},h.id)})})};LE.propTypes={points:C.arrayOf(C.object),symbol:C.func,size:C.number.isRequired,color:C.func.isRequired,borderWidth:C.number.isRequired,borderColor:C.func.isRequired,enableLabel:C.bool.isRequired,label:C.oneOfType([C.string,C.func]).isRequired,labelYOffset:C.number};var p11=G.memo(LE),FE=function(e){var t=e.points,n=e.width,i=e.height,r=e.margin,a=e.setCurrent,u=e.onMouseEnter,f=e.onMouseMove,d=e.onMouseLeave,p=e.onClick,m=e.tooltip,h=e.debug,v=Pf(),S=v.showTooltipAt,E=v.hideTooltip,k=G.useCallback(function(b,N){S(G.createElement(m,{point:b}),[b.x+r.left,b.y+r.top],"top"),a(b),u&&u(b,N)},[a,S,m,u,r]),O=G.useCallback(function(b,N){S(G.createElement(m,{point:b}),[b.x+r.left,b.y+r.top],"top"),a(b),f&&f(b,N)},[a,S,m,f]),x=G.useCallback(function(b,N){E(),a(null),d&&d(b,N)},[E,a,d]),w=G.useCallback(function(b,N){p&&p(b,N)},[p]);return R.jsx(KJ,{nodes:t,width:n,height:i,onMouseEnter:k,onMouseMove:O,onMouseLeave:x,onClick:w,debug:h})};FE.propTypes={points:C.arrayOf(C.object).isRequired,width:C.number.isRequired,height:C.number.isRequired,margin:C.object.isRequired,setCurrent:C.func.isRequired,onMouseEnter:C.func,onMouseMove:C.func,onMouseLeave:C.func,onClick:C.func,tooltip:C.oneOfType([C.func,C.object]).isRequired,debug:C.bool.isRequired};var g11=G.memo(FE),cc=function(e){var t=e.data,n=e.xScale,i=e.xFormat,r=e.yScale,a=e.yFormat,u=e.layers,f=e.curve,d=e.areaBaselineValue,p=e.colors,m=e.margin,h=e.width,v=e.height,S=e.axisTop,E=e.axisRight,k=e.axisBottom,O=e.axisLeft,x=e.enableGridX,w=e.enableGridY,b=e.gridXValues,N=e.gridYValues,$=e.lineWidth,I=e.enableArea,j=e.areaOpacity,B=e.areaBlendMode,Y=e.enablePoints,H=e.pointSymbol,D=e.pointSize,J=e.pointColor,e1=e.pointBorderWidth,o1=e.pointBorderColor,i1=e.enablePointLabel,l1=e.pointLabel,r1=e.pointLabelYOffset,V=e.defs,p1=e.fill,f1=e.markers,w1=e.legends,T1=e.isInteractive,j1=e.useMesh,F1=e.debugMesh,_1=e.onMouseEnter,d1=e.onMouseMove,I1=e.onMouseLeave,W1=e.onClick,E1=e.tooltip,O1=e.enableSlices,R1=e.debugSlices,g1=e.sliceTooltip,J1=e.enableCrosshair,D1=e.crosshairType,ae=e.role,we=vS(h,v,m),pe=we.margin,ge=we.innerWidth,Qe=we.innerHeight,W=we.outerWidth,T=we.outerHeight,P=AE({data:t,xScale:n,xFormat:i,yScale:r,yFormat:a,width:ge,height:Qe,colors:p,curve:f,areaBaselineValue:d,pointColor:J,pointBorderColor:o1,enableSlices:O1}),Z=P.legendData,s1=P.toggleSerie,v1=P.lineGenerator,b1=P.areaGenerator,G1=P.series,X1=P.xScale,k1=P.yScale,q1=P.slices,fe=P.points,de=Lt(),gt=Ar(J,de),x4=Ar(o1,de),U2=G.useState(null),Q4=U2[0],b4=U2[1],k5=G.useState(null),$2=k5[0],ln=k5[1],s4={grid:R.jsx(xJ,{theme:de,width:ge,height:Qe,xScale:x?X1:null,yScale:w?k1:null,xValues:b,yValues:N},"grid"),markers:R.jsx(JV,{markers:f1,width:ge,height:Qe,xScale:X1,yScale:k1,theme:de},"markers"),axes:R.jsx(_J,{xScale:X1,yScale:k1,width:ge,height:Qe,theme:de,top:S,right:E,bottom:k,left:O},"axes"),areas:null,lines:R.jsx(f11,{lines:G1,lineGenerator:v1,lineWidth:$},"lines"),slices:null,points:null,crosshair:null,mesh:null,legends:w1.map(function(W4,fn){return R.jsx(OJ,Ct({},W4,{containerWidth:ge,containerHeight:Qe,data:W4.data||Z,theme:de,toggleSerie:W4.toggleSerie?s1:void 0}),"legend."+fn)})},cn=aY(V,G1,p1);return I&&(s4.areas=R.jsx(l11,{areaGenerator:b1,areaOpacity:j,areaBlendMode:B,lines:G1},"areas")),T1&&O1!==!1&&(s4.slices=R.jsx(h11,{slices:q1,axis:O1,debug:R1,height:Qe,tooltip:g1,current:$2,setCurrent:ln,onMouseEnter:_1,onMouseMove:d1,onMouseLeave:I1,onClick:W1},"slices")),Y&&(s4.points=R.jsx(p11,{points:fe,symbol:H,size:D,color:gt,borderWidth:e1,borderColor:x4,enableLabel:i1,label:l1,labelYOffset:r1},"points")),T1&&J1&&(Q4!==null&&(s4.crosshair=R.jsx(Il,{width:ge,height:Qe,x:Q4.x,y:Q4.y,type:D1},"crosshair")),$2!==null&&(s4.crosshair=R.jsx(Il,{width:ge,height:Qe,x:$2.x,y:$2.y,type:O1},"crosshair"))),T1&&j1&&O1===!1&&(s4.mesh=R.jsx(g11,{points:fe,width:ge,height:Qe,margin:pe,current:Q4,setCurrent:b4,onMouseEnter:_1,onMouseMove:d1,onMouseLeave:I1,onClick:W1,tooltip:E1,debug:F1},"mesh")),R.jsx(PS,{defs:cn,width:W,height:T,margin:pe,role:ae,children:u.map(function(W4,fn){return typeof W4=="function"?R.jsx(G.Fragment,{children:W4(Ct({},e,{innerWidth:ge,innerHeight:Qe,series:G1,slices:q1,points:fe,xScale:X1,yScale:k1,lineGenerator:v1,areaGenerator:b1,currentPoint:Q4,setCurrentPoint:b4,currentSlice:$2,setCurrentSlice:ln}))},fn):s4[W4]})})};cc.propTypes=i11,cc.defaultProps=t3;var m11=LS(cc),fc=function(e){var t=e.width,n=e.height,i=e.margin,r=e.pixelRatio,a=e.data,u=e.xScale,f=e.xFormat,d=e.yScale,p=e.yFormat,m=e.curve,h=e.layers,v=e.colors,S=e.lineWidth,E=e.enableArea,k=e.areaBaselineValue,O=e.areaOpacity,x=e.enablePoints,w=e.pointSize,b=e.pointColor,N=e.pointBorderWidth,$=e.pointBorderColor,I=e.enableGridX,j=e.gridXValues,B=e.enableGridY,Y=e.gridYValues,H=e.axisTop,D=e.axisRight,J=e.axisBottom,e1=e.axisLeft,o1=e.legends,i1=e.isInteractive,l1=e.debugMesh,r1=e.onMouseLeave,V=e.onClick,p1=e.tooltip,f1=e.canvasRef,w1=G.useRef(null),T1=vS(t,n,i),j1=T1.margin,F1=T1.innerWidth,_1=T1.innerHeight,d1=T1.outerWidth,I1=T1.outerHeight,W1=Lt(),E1=G.useState(null),O1=E1[0],R1=E1[1],g1=AE({data:a,xScale:u,xFormat:f,yScale:d,yFormat:p,width:F1,height:_1,colors:v,curve:m,areaBaselineValue:k,pointColor:b,pointBorderColor:$}),J1=g1.lineGenerator,D1=g1.areaGenerator,ae=g1.series,we=g1.xScale,pe=g1.yScale,ge=g1.points,Qe=xE({points:ge,width:F1,height:_1,debug:l1}),W=Qe.delaunay,T=Qe.voronoi;G.useEffect(function(){f1&&(f1.current=w1.current),w1.current.width=d1*r,w1.current.height=I1*r;var k1=w1.current.getContext("2d");k1.scale(r,r),k1.fillStyle=W1.background,k1.fillRect(0,0,d1,I1),k1.translate(j1.left,j1.top),h.forEach(function(q1){if(typeof q1=="function"&&q1({ctx:k1,innerWidth:F1,innerHeight:_1,series:ae,points:ge,xScale:we,yScale:pe,lineWidth:S,lineGenerator:J1,areaGenerator:D1,currentPoint:O1,setCurrentPoint:R1}),q1==="grid"&&W1.grid.line.strokeWidth>0&&(k1.lineWidth=W1.grid.line.strokeWidth,k1.strokeStyle=W1.grid.line.stroke,I&&jy(k1,{width:F1,height:_1,scale:we,axis:"x",values:j}),B&&jy(k1,{width:F1,height:_1,scale:pe,axis:"y",values:Y})),q1==="axes"&&SJ(k1,{xScale:we,yScale:pe,width:F1,height:_1,top:H,right:D,bottom:J,left:e1,theme:W1}),q1==="areas"&&E===!0&&(k1.save(),k1.globalAlpha=O,D1.context(k1),ae.forEach(function(de){k1.fillStyle=de.color,k1.beginPath(),D1(de.data.map(function(gt){return gt.position})),k1.fill()}),k1.restore()),q1==="lines"&&(J1.context(k1),ae.forEach(function(de){k1.strokeStyle=de.color,k1.lineWidth=S,k1.beginPath(),J1(de.data.map(function(gt){return gt.position})),k1.stroke()})),q1==="points"&&x===!0&&w>0&&ge.forEach(function(de){k1.fillStyle=de.color,k1.beginPath(),k1.arc(de.x,de.y,w/2,0,2*Math.PI),k1.fill(),N>0&&(k1.strokeStyle=de.borderColor,k1.lineWidth=N,k1.stroke())}),q1==="mesh"&&l1===!0&&(JJ(k1,T),O1&&e11(k1,T,O1.index)),q1==="legends"){var fe=ae.map(function(de){return{id:de.id,label:de.id,color:de.color}}).reverse();o1.forEach(function(de){FJ(k1,Ct({},de,{data:de.data||fe,containerWidth:F1,containerHeight:_1,theme:W1}))})}})},[w1,d1,I1,h,W1,J1,ae,we,pe,I,j,B,Y,H,D,J,e1,o1,ge,x,w,O1]);var P=G.useCallback(function(k1){var q1=FS(w1.current,k1),fe=q1[0],de=q1[1];if(!nY(j1.left,j1.top,F1,_1,fe,de))return null;var gt=W.find(fe-j1.left,de-j1.top);return ge[gt]},[w1,j1,F1,_1,W]),Z=Pf(),s1=Z.showTooltipFromEvent,v1=Z.hideTooltip,b1=G.useCallback(function(k1){var q1=P(k1);R1(q1),q1?s1(G.createElement(p1,{point:q1}),k1):v1()},[P,R1,s1,v1,p1]),G1=G.useCallback(function(k1){v1(),R1(null),O1&&r1&&r1(O1,k1)},[v1,R1,r1]),X1=G.useCallback(function(k1){if(V){var q1=P(k1);q1&&V(q1,k1)}},[P,V]);return R.jsx("canvas",{ref:w1,width:d1*r,height:I1*r,style:{width:d1,height:I1,cursor:i1?"auto":"normal"},onMouseEnter:i1?b1:void 0,onMouseMove:i1?b1:void 0,onMouseLeave:i1?G1:void 0,onClick:i1?X1:void 0})};fc.propTypes=r11,fc.defaultProps=o11;var y11=LS(fc),v11=G.forwardRef(function(e,t){return R.jsx(y11,Ct({},e,{canvasRef:t}))});G.forwardRef(function(e,t){return R.jsx(ES,{children:function(n){var i=n.width,r=n.height;return R.jsx(v11,Ct({width:i,height:r},e,{ref:t}))}})});function _11(e){const t=e.replaceAll("\r","").split("---")[1].trim().split(` -`),n=t[0].split("|").map(r=>r.replaceAll(" ","_"));return t.slice(2).map(r=>Object.fromEntries(r.split("|").map((a,u)=>[n[u],a])))}const w11=()=>{const[e,t]=G.useState(),[n,i]=G.useState(90);G.useEffect(()=>{fetch("https://api.github.com/repos/osm-nz/linz-address-import/issues/1").then(a=>a.json()).then(a=>t(a.body))},[]);const r=G.useMemo(()=>{if(!e)return[];const a=_11(e);return Object.entries(Nw).map(([f,d])=>{const p=f,[,,,m]=d;return{id:p,color:m,data:a.filter((h,v)=>{var S;return h.Sync_Date!==((S=a[v-1])==null?void 0:S.Sync_Date)}).map(h=>{const v=+(100*(+h[p]/+h.Total)).toFixed(2);return{x:h.Sync_Date,y:Number.isNaN(v)?0:v}})}})},[e]);return r.length?(console.log({chartData:r}),R.jsxs("div",{children:[R.jsx(m11,{width:window.innerWidth,height:500,data:r,margin:{top:50,right:110,bottom:50,left:60},xScale:{type:"time",format:"%Y-%m-%d",useUTC:!1},xFormat:"time:%Y-%m-%d",yScale:{type:"linear",min:n,max:"auto",stacked:!0},axisBottom:null,axisRight:null,axisTop:{legend:"Time",legendOffset:36,legendPosition:"middle",format:"%Y-%m",tickValues:"every 2 months"},axisLeft:{legend:"Percentage",legendOffset:-40,legendPosition:"middle"},pointSize:0,colors:a=>a.color,enableArea:!0,areaOpacity:1}),R.jsx("button",{type:"button",onClick:()=>i(a=>Math.max(0,a-2)),children:"➖"}),R.jsx("button",{type:"button",onClick:()=>i(a=>Math.min(99,a+2)),children:"➕"})]})):R.jsx(R.Fragment,{children:"Loading…"})},Hy="https://linz-addr-cdn.kyle.kiwi",x11=()=>{const[e,t]=G.useState(),[n,i]=G.useState();if(G.useEffect(()=>{fetch(`${Hy}/stats.json`).then(a=>a.json()).then(i).catch(t)},[]),e)return R.jsx(R.Fragment,{children:"Error."});if(!n)return R.jsx(R.Fragment,{children:"Loading..."});const r=new Date(n.date);return R.jsxs("div",{style:{margin:15},children:[R.jsx("a",{href:"./RapiD/",className:"start",children:"✨ Click to start mapping!"}),R.jsxs("table",{className:"busy",children:[R.jsx("thead",{children:R.jsxs("tr",{style:{fontWeight:600},children:[R.jsx("td",{children:"Code"}),R.jsx("td",{children:"Data Category"}),R.jsx("td",{children:"No. of addresses"}),R.jsx("td",{children:"Percentage of total"}),R.jsx("td",{children:"How to action"}),R.jsx("td",{children:"Raw data"})]})}),R.jsx("tbody",{children:Object.entries(n.count).map(([a,u])=>{const[f,d,p,m,h]=Nw[a];return R.jsxs("tr",{children:[R.jsx("td",{style:{backgroundColor:m},children:f}),R.jsx("td",{children:d}),R.jsx("td",{children:u.toLocaleString("en-nz")}),R.jsxs("td",{children:[(u/n.total*100).toFixed(2),"%"]}),R.jsx("td",{children:p}),h&&R.jsx("td",{children:R.jsx("a",{href:`${Hy}/${h}`,children:"download"})})]},a)})})]}),R.jsx(w11,{}),R.jsxs("p",{style:{margin:12},children:["Statistics last updated"," ",R.jsx("strong",{children:R.jsx(Cw,{date:r})})]}),R.jsxs("footer",{children:["For more infomation, see:",R.jsxs("ul",{children:[R.jsx("li",{children:R.jsx("a",{href:"https://wiki.openstreetmap.org/wiki/Import/New_Zealand_Street_Addresses_(2021)",children:"the wiki page"})}),R.jsx("li",{children:R.jsx("a",{href:"https://github.com/osm-nz/linz-address-import",children:"the repository containing the source code"})}),R.jsx("li",{children:R.jsx("a",{href:"https://osmcha.org/?aoi=5a4d6cbe-37f9-4b5b-a6d6-0c69dd488a07",children:"All changesets uploaded so far"})}),R.jsx("li",{children:R.jsx("a",{href:"#/map",children:"A map of all the sectors requiring attention"})})]})]})]})},b11=()=>R.jsxs("div",{style:{margin:16},children:[R.jsx("h1",{children:"OpenStreetMap NZ"}),R.jsxs("ul",{children:[R.jsx("li",{children:R.jsx("a",{href:"#/address-import",children:"LINZ Address Import"})}),R.jsx("li",{children:R.jsx("a",{href:"/missing-streets",children:"Missing Streets"})})]})]});function IE(e,t){const n=G.useRef(t);G.useEffect(function(){t!==n.current&&e.attributionControl!=null&&(n.current!=null&&e.attributionControl.removeAttribution(n.current),t!=null&&e.attributionControl.addAttribution(t)),n.current=t},[e,t])}const S11=1;function E11(e){return Object.freeze({__version:S11,map:e})}function oa(e,t){return Object.freeze({...e,...t})}const RE=G.createContext(null),Ed=RE.Provider;function M9(){const e=G.useContext(RE);if(e==null)throw new Error("No context provided: useLeafletContext() can only be used in a descendant of ");return e}function UE(e){function t(n,i){const{instance:r,context:a}=e(n).current;return G.useImperativeHandle(i,()=>r),n.children==null?null:N8.createElement(Ed,{value:a},n.children)}return G.forwardRef(t)}function M11(e){function t(n,i){const[r,a]=G.useState(!1),{instance:u}=e(n,a).current;G.useImperativeHandle(i,()=>u),G.useEffect(function(){r&&u.update()},[u,r,n.children]);const f=u._contentNode;return f?df.createPortal(n.children,f):null}return G.forwardRef(t)}function A11(e){function t(n,i){const{instance:r}=e(n).current;return G.useImperativeHandle(i,()=>r),null}return G.forwardRef(t)}function k11(e){return function(n){const i=M9(),r=e(n,i),{instance:a}=r.current,u=G.useRef(n.position),{position:f}=n;return G.useEffect(function(){return a.addTo(i.map),function(){a.remove()}},[i.map,a]),G.useEffect(function(){f!=null&&f!==u.current&&(a.setPosition(f),u.current=f)},[a,f]),r}}function Md(e,t){const n=G.useRef();G.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 aa(e,t){const n=e.pane??t.pane;return n?{...e,pane:n}:e}function T11(e,t){return function(i,r){const a=M9(),u=e(aa(i,a),a);return IE(a.map,i.attribution),Md(u.current,i.eventHandlers),t(u.current,a,i,r),u}}var dc={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,i){i(t)})(o2,function(n){var i="1.9.4";function r(o){var l,g,_,A;for(g=1,_=arguments.length;g<_;g++){A=arguments[g];for(l in A)o[l]=A[l]}return o}var a=Object.create||function(){function o(){}return function(l){return o.prototype=l,new o}}();function u(o,l){var g=Array.prototype.slice;if(o.bind)return o.bind.apply(o,g.call(arguments,1));var _=g.call(arguments,2);return function(){return o.apply(l,_.length?_.concat(g.call(arguments)):arguments)}}var f=0;function d(o){return"_leaflet_id"in o||(o._leaflet_id=++f),o._leaflet_id}function p(o,l,g){var _,A,U,X;return X=function(){_=!1,A&&(U.apply(g,A),A=!1)},U=function(){_?A=arguments:(o.apply(g,arguments),setTimeout(X,l),_=!0)},U}function m(o,l,g){var _=l[1],A=l[0],U=_-A;return o===_&&g?o:((o-A)%U+U)%U+A}function h(){return!1}function v(o,l){if(l===!1)return o;var g=Math.pow(10,l===void 0?6:l);return Math.round(o*g)/g}function S(o){return o.trim?o.trim():o.replace(/^\s+|\s+$/g,"")}function E(o){return S(o).split(/\s+/)}function k(o,l){Object.prototype.hasOwnProperty.call(o,"options")||(o.options=o.options?a(o.options):{});for(var g in l)o.options[g]=l[g];return o.options}function O(o,l,g){var _=[];for(var A in o)_.push(encodeURIComponent(g?A.toUpperCase():A)+"="+encodeURIComponent(o[A]));return(!l||l.indexOf("?")===-1?"?":"&")+_.join("&")}var x=/\{ *([\w_ -]+) *\}/g;function w(o,l){return o.replace(x,function(g,_){var A=l[_];if(A===void 0)throw new Error("No value provided for variable "+g);return typeof A=="function"&&(A=A(l)),A})}var b=Array.isArray||function(o){return Object.prototype.toString.call(o)==="[object Array]"};function N(o,l){for(var g=0;g"u"||!L||!L.Mixin)){o=b(o)?o:[o];for(var l=0;l0?Math.floor(o):Math.ceil(o)};V.prototype={clone:function(){return new V(this.x,this.y)},add:function(o){return this.clone()._add(f1(o))},_add:function(o){return this.x+=o.x,this.y+=o.y,this},subtract:function(o){return this.clone()._subtract(f1(o))},_subtract:function(o){return this.x-=o.x,this.y-=o.y,this},divideBy:function(o){return this.clone()._divideBy(o)},_divideBy:function(o){return this.x/=o,this.y/=o,this},multiplyBy:function(o){return this.clone()._multiplyBy(o)},_multiplyBy:function(o){return this.x*=o,this.y*=o,this},scaleBy:function(o){return new V(this.x*o.x,this.y*o.y)},unscaleBy:function(o){return new V(this.x/o.x,this.y/o.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=p1(this.x),this.y=p1(this.y),this},distanceTo:function(o){o=f1(o);var l=o.x-this.x,g=o.y-this.y;return Math.sqrt(l*l+g*g)},equals:function(o){return o=f1(o),o.x===this.x&&o.y===this.y},contains:function(o){return o=f1(o),Math.abs(o.x)<=Math.abs(this.x)&&Math.abs(o.y)<=Math.abs(this.y)},toString:function(){return"Point("+v(this.x)+", "+v(this.y)+")"}};function f1(o,l,g){return o instanceof V?o:b(o)?new V(o[0],o[1]):o==null?o:typeof o=="object"&&"x"in o&&"y"in o?new V(o.x,o.y):new V(o,l,g)}function w1(o,l){if(o)for(var g=l?[o,l]:o,_=0,A=g.length;_=this.min.x&&g.x<=this.max.x&&l.y>=this.min.y&&g.y<=this.max.y},intersects:function(o){o=T1(o);var l=this.min,g=this.max,_=o.min,A=o.max,U=A.x>=l.x&&_.x<=g.x,X=A.y>=l.y&&_.y<=g.y;return U&&X},overlaps:function(o){o=T1(o);var l=this.min,g=this.max,_=o.min,A=o.max,U=A.x>l.x&&_.xl.y&&_.y=l.lat&&A.lat<=g.lat&&_.lng>=l.lng&&A.lng<=g.lng},intersects:function(o){o=F1(o);var l=this._southWest,g=this._northEast,_=o.getSouthWest(),A=o.getNorthEast(),U=A.lat>=l.lat&&_.lat<=g.lat,X=A.lng>=l.lng&&_.lng<=g.lng;return U&&X},overlaps:function(o){o=F1(o);var l=this._southWest,g=this._northEast,_=o.getSouthWest(),A=o.getNorthEast(),U=A.lat>l.lat&&_.latl.lng&&_.lng1,k9=function(){var o=!1;try{var l=Object.defineProperty({},"passive",{get:function(){o=!0}});window.addEventListener("testPassiveEventSupport",h,l),window.removeEventListener("testPassiveEventSupport",h,l)}catch{}return o}(),ca=function(){return!!document.createElement("canvas").getContext}(),c0=!!(document.createElementNS&&ae("svg").createSVGRect),fa=!!c0&&function(){var o=document.createElement("div");return o.innerHTML="",(o.firstChild&&o.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"}(),f0=!c0&&function(){try{var o=document.createElement("div");o.innerHTML='';var l=o.firstChild;return l.style.behavior="url(#default#VML)",l&&typeof l.adj=="object"}catch{return!1}}(),da=navigator.platform.indexOf("Mac")===0,d0=navigator.platform.indexOf("Linux")===0;function S4(o){return navigator.userAgent.toLowerCase().indexOf(o)>=0}var $1={ie:ge,ielt9:Qe,edge:W,webkit:T,android:P,android23:Z,androidStock:v1,opera:b1,chrome:G1,gecko:X1,safari:k1,phantom:q1,opera12:fe,win:de,ie3d:gt,webkit3d:x4,gecko3d:U2,any3d:Q4,mobile:b4,mobileWebkit:k5,mobileWebkit3d:$2,msPointer:ln,pointer:s4,touch:W4,touchNative:cn,mobileOpera:fn,mobileGecko:ua,retina:la,passiveEvents:k9,canvas:ca,svg:c0,vml:f0,inlineSvg:fa,mac:da,linux:d0},T9=$1.msPointer?"MSPointerDown":"pointerdown",P9=$1.msPointer?"MSPointerMove":"pointermove",C9=$1.msPointer?"MSPointerUp":"pointerup",N9=$1.msPointer?"MSPointerCancel":"pointercancel",h0={touchstart:T9,touchmove:P9,touchend:C9,touchcancel:N9},O9={touchstart:C5,touchmove:P5,touchend:P5,touchcancel:P5},B2={},L9=!1;function ha(o,l,g){return l==="touchstart"&&T5(),O9[l]?(g=O9[l].bind(this,g),o.addEventListener(h0[l],g,!1),g):(console.warn("wrong event specified:",l),h)}function pa(o,l,g){if(!h0[l]){console.warn("wrong event specified:",l);return}o.removeEventListener(h0[l],g,!1)}function ga(o){B2[o.pointerId]=o}function ma(o){B2[o.pointerId]&&(B2[o.pointerId]=o)}function F9(o){delete B2[o.pointerId]}function T5(){L9||(document.addEventListener(T9,ga,!0),document.addEventListener(P9,ma,!0),document.addEventListener(C9,F9,!0),document.addEventListener(N9,F9,!0),L9=!0)}function P5(o,l){if(l.pointerType!==(l.MSPOINTER_TYPE_MOUSE||"mouse")){l.touches=[];for(var g in B2)l.touches.push(B2[g]);l.changedTouches=[l],o(l)}}function C5(o,l){l.MSPOINTER_TYPE_TOUCH&&l.pointerType===l.MSPOINTER_TYPE_TOUCH&&te(l),P5(o,l)}function ya(o){var l={},g,_;for(_ in o)g=o[_],l[_]=g&&g.bind?g.bind(o):g;return o=l,l.type="dblclick",l.detail=2,l.isTrusted=!1,l._simulated=!0,l}var va=200;function _a(o,l){o.addEventListener("dblclick",l);var g=0,_;function A(U){if(U.detail!==1){_=U.detail;return}if(!(U.pointerType==="mouse"||U.sourceCapabilities&&!U.sourceCapabilities.firesTouchEvents)){var X=D9(U);if(!(X.some(function(u1){return u1 instanceof HTMLLabelElement&&u1.attributes.for})&&!X.some(function(u1){return u1 instanceof HTMLInputElement||u1 instanceof HTMLSelectElement}))){var a1=Date.now();a1-g<=va?(_++,_===2&&l(ya(U))):_=1,g=a1}}}return o.addEventListener("click",A),{dblclick:l,simDblclick:A}}function I9(o,l){o.removeEventListener("dblclick",l.dblclick),o.removeEventListener("click",l.simDblclick)}var N5=y3(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),m3=y3(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),R9=m3==="webkitTransition"||m3==="OTransition"?m3+"End":"transitionend";function U9(o){return typeof o=="string"?document.getElementById(o):o}function dn(o,l){var g=o.style[l]||o.currentStyle&&o.currentStyle[l];if((!g||g==="auto")&&document.defaultView){var _=document.defaultView.getComputedStyle(o,null);g=_?_[l]:null}return g==="auto"?null:g}function xe(o,l,g){var _=document.createElement(o);return _.className=l||"",g&&g.appendChild(_),_}function Oe(o){var l=o.parentNode;l&&l.removeChild(o)}function hn(o){for(;o.firstChild;)o.removeChild(o.firstChild)}function z2(o){var l=o.parentNode;l&&l.lastChild!==o&&l.appendChild(o)}function p2(o){var l=o.parentNode;l&&l.firstChild!==o&&l.insertBefore(o,l.firstChild)}function p0(o,l){if(o.classList!==void 0)return o.classList.contains(l);var g=L5(o);return g.length>0&&new RegExp("(^|\\s)"+l+"(\\s|$)").test(g)}function ee(o,l){if(o.classList!==void 0)for(var g=E(l),_=0,A=g.length;_0?2*window.devicePixelRatio:1;function W9(o){return $1.edge?o.wheelDeltaY/2:o.deltaY&&o.deltaMode===0?-o.deltaY/wa:o.deltaY&&o.deltaMode===1?-o.deltaY*20:o.deltaY&&o.deltaMode===2?-o.deltaY*60:o.deltaX||o.deltaZ?0:o.wheelDelta?(o.wheelDeltaY||o.wheelDelta)/2:o.detail&&Math.abs(o.detail)<32765?-o.detail*20:o.detail?o.detail/-32765*60:0}function w0(o,l){var g=l.relatedTarget;if(!g)return!0;try{for(;g&&g!==o;)g=g.parentNode}catch{return!1}return g!==o}var xa={__proto__:null,on:K1,off:Pe,stopPropagation:Q2,disableScrollPropagation:_0,disableClickPropagation:mn,preventDefault:te,stop:be,getPropagationPath:D9,getMousePosition:Q9,getWheelDelta:W9,isExternalTarget:w0,addListener:K1,removeListener:Pe},x0=r1.extend({run:function(o,l,g,_){this.stop(),this._el=o,this._inProgress=!0,this._duration=g||.25,this._easeOutPower=1/Math.max(_||.5,.2),this._startPos=H4(o),this._offset=l.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=D(this._animate,this),this._step()},_step:function(o){var l=+new Date-this._startTime,g=this._duration*1e3;lthis.options.maxZoom)?this.setZoom(o):this},panInsideBounds:function(o,l){this._enforcingBounds=!0;var g=this.getCenter(),_=this._limitCenter(g,this._zoom,F1(o));return g.equals(_)||this.panTo(_,l),this._enforcingBounds=!1,this},panInside:function(o,l){l=l||{};var g=f1(l.paddingTopLeft||l.padding||[0,0]),_=f1(l.paddingBottomRight||l.padding||[0,0]),A=this.project(this.getCenter()),U=this.project(o),X=this.getPixelBounds(),a1=T1([X.min.add(g),X.max.subtract(_)]),u1=a1.getSize();if(!a1.contains(U)){this._enforcingBounds=!0;var x1=U.subtract(a1.getCenter()),C1=a1.extend(U).getSize().subtract(u1);A.x+=x1.x<0?-C1.x:C1.x,A.y+=x1.y<0?-C1.y:C1.y,this.panTo(this.unproject(A),l),this._enforcingBounds=!1}return this},invalidateSize:function(o){if(!this._loaded)return this;o=r({animate:!1,pan:!0},o===!0?{animate:!0}:o);var l=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var g=this.getSize(),_=l.divideBy(2).round(),A=g.divideBy(2).round(),U=_.subtract(A);return!U.x&&!U.y?this:(o.animate&&o.pan?this.panBy(U):(o.pan&&this._rawPanBy(U),this.fire("move"),o.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(u(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:l,newSize:g}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(o){if(o=this._locateOptions=r({timeout:1e4,watch:!1},o),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var l=u(this._handleGeolocationResponse,this),g=u(this._handleGeolocationError,this);return o.watch?this._locationWatchId=navigator.geolocation.watchPosition(l,g,o):navigator.geolocation.getCurrentPosition(l,g,o),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(o){if(this._container._leaflet_id){var l=o.code,g=o.message||(l===1?"permission denied":l===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:l,message:"Geolocation error: "+g+"."})}},_handleGeolocationResponse:function(o){if(this._container._leaflet_id){var l=o.coords.latitude,g=o.coords.longitude,_=new _1(l,g),A=_.toBounds(o.coords.accuracy*2),U=this._locateOptions;if(U.setView){var X=this.getBoundsZoom(A);this.setView(_,U.maxZoom?Math.min(X,U.maxZoom):X)}var a1={latlng:_,bounds:A,timestamp:o.timestamp};for(var u1 in o.coords)typeof o.coords[u1]=="number"&&(a1[u1]=o.coords[u1]);this.fire("locationfound",a1)}},addHandler:function(o,l){if(!l)return this;var g=this[o]=new l(this);return this._handlers.push(g),this.options[o]&&g.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(),Oe(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(J(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var o;for(o in this._layers)this._layers[o].remove();for(o in this._panes)Oe(this._panes[o]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(o,l){var g="leaflet-pane"+(o?" leaflet-"+o.replace("Pane","")+"-pane":""),_=xe("div",g,l||this._mapPane);return o&&(this._panes[o]=_),_},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var o=this.getPixelBounds(),l=this.unproject(o.getBottomLeft()),g=this.unproject(o.getTopRight());return new j1(l,g)},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(o,l,g){o=F1(o),g=f1(g||[0,0]);var _=this.getZoom()||0,A=this.getMinZoom(),U=this.getMaxZoom(),X=o.getNorthWest(),a1=o.getSouthEast(),u1=this.getSize().subtract(g),x1=T1(this.project(a1,_),this.project(X,_)).getSize(),C1=$1.any3d?this.options.zoomSnap:1,z1=u1.x/x1.x,re=u1.y/x1.y,Ve=l?Math.max(z1,re):Math.min(z1,re);return _=this.getScaleZoom(Ve,_),C1&&(_=Math.round(_/(C1/100))*(C1/100),_=l?Math.ceil(_/C1)*C1:Math.floor(_/C1)*C1),Math.max(A,Math.min(U,_))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new V(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(o,l){var g=this._getTopLeftPoint(o,l);return new w1(g,g.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(o){return this.options.crs.getProjectedBounds(o===void 0?this.getZoom():o)},getPane:function(o){return typeof o=="string"?this._panes[o]:o},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(o,l){var g=this.options.crs;return l=l===void 0?this._zoom:l,g.scale(o)/g.scale(l)},getScaleZoom:function(o,l){var g=this.options.crs;l=l===void 0?this._zoom:l;var _=g.zoom(o*g.scale(l));return isNaN(_)?1/0:_},project:function(o,l){return l=l===void 0?this._zoom:l,this.options.crs.latLngToPoint(d1(o),l)},unproject:function(o,l){return l=l===void 0?this._zoom:l,this.options.crs.pointToLatLng(f1(o),l)},layerPointToLatLng:function(o){var l=f1(o).add(this.getPixelOrigin());return this.unproject(l)},latLngToLayerPoint:function(o){var l=this.project(d1(o))._round();return l._subtract(this.getPixelOrigin())},wrapLatLng:function(o){return this.options.crs.wrapLatLng(d1(o))},wrapLatLngBounds:function(o){return this.options.crs.wrapLatLngBounds(F1(o))},distance:function(o,l){return this.options.crs.distance(d1(o),d1(l))},containerPointToLayerPoint:function(o){return f1(o).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(o){return f1(o).add(this._getMapPanePos())},containerPointToLatLng:function(o){var l=this.containerPointToLayerPoint(f1(o));return this.layerPointToLatLng(l)},latLngToContainerPoint:function(o){return this.layerPointToContainerPoint(this.latLngToLayerPoint(d1(o)))},mouseEventToContainerPoint:function(o){return Q9(o,this._container)},mouseEventToLayerPoint:function(o){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(o))},mouseEventToLatLng:function(o){return this.layerPointToLatLng(this.mouseEventToLayerPoint(o))},_initContainer:function(o){var l=this._container=U9(o);if(l){if(l._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");K1(l,"scroll",this._onScroll,this),this._containerId=d(l)},_initLayout:function(){var o=this._container;this._fadeAnimated=this.options.fadeAnimation&&$1.any3d,ee(o,"leaflet-container"+($1.touch?" leaflet-touch":"")+($1.retina?" leaflet-retina":"")+($1.ielt9?" leaflet-oldie":"")+($1.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var l=dn(o,"position");l!=="absolute"&&l!=="relative"&&l!=="fixed"&&l!=="sticky"&&(o.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var o=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),We(this._mapPane,new V(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(ee(o.markerPane,"leaflet-zoom-hide"),ee(o.shadowPane,"leaflet-zoom-hide"))},_resetView:function(o,l,g){We(this._mapPane,new V(0,0));var _=!this._loaded;this._loaded=!0,l=this._limitZoom(l),this.fire("viewprereset");var A=this._zoom!==l;this._moveStart(A,g)._move(o,l)._moveEnd(A),this.fire("viewreset"),_&&this.fire("load")},_moveStart:function(o,l){return o&&this.fire("zoomstart"),l||this.fire("movestart"),this},_move:function(o,l,g,_){l===void 0&&(l=this._zoom);var A=this._zoom!==l;return this._zoom=l,this._lastCenter=o,this._pixelOrigin=this._getNewPixelOrigin(o),_?g&&g.pinch&&this.fire("zoom",g):((A||g&&g.pinch)&&this.fire("zoom",g),this.fire("move",g)),this},_moveEnd:function(o){return o&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return J(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(o){We(this._mapPane,this._getMapPanePos().subtract(o))},_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(o){this._targets={},this._targets[d(this._container)]=this;var l=o?Pe:K1;l(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&l(window,"resize",this._onResize,this),$1.any3d&&this.options.transform3DLimit&&(o?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){J(this._resizeRequest),this._resizeRequest=D(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var o=this._getMapPanePos();Math.max(Math.abs(o.x),Math.abs(o.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(o,l){for(var g=[],_,A=l==="mouseout"||l==="mouseover",U=o.target||o.srcElement,X=!1;U;){if(_=this._targets[d(U)],_&&(l==="click"||l==="preclick")&&this._draggableMoved(_)){X=!0;break}if(_&&_.listens(l,!0)&&(A&&!w0(U,o)||(g.push(_),A))||U===this._container)break;U=U.parentNode}return!g.length&&!X&&!A&&this.listens(l,!0)&&(g=[this]),g},_isClickDisabled:function(o){for(;o&&o!==this._container;){if(o._leaflet_disable_click)return!0;o=o.parentNode}},_handleDOMEvent:function(o){var l=o.target||o.srcElement;if(!(!this._loaded||l._leaflet_disable_events||o.type==="click"&&this._isClickDisabled(l))){var g=o.type;g==="mousedown"&&U5(l),this._fireDOMEvent(o,g)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(o,l,g){if(o.type==="click"){var _=r({},o);_.type="preclick",this._fireDOMEvent(_,_.type,g)}var A=this._findEventTargets(o,l);if(g){for(var U=[],X=0;X0?Math.round(o-l)/2:Math.max(0,Math.ceil(o))-Math.max(0,Math.floor(l))},_limitZoom:function(o){var l=this.getMinZoom(),g=this.getMaxZoom(),_=$1.any3d?this.options.zoomSnap:1;return _&&(o=Math.round(o/_)*_),Math.max(l,Math.min(g,o))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){Le(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(o,l){var g=this._getCenterOffset(o)._trunc();return(l&&l.animate)!==!0&&!this.getSize().contains(g)?!1:(this.panBy(g,l),!0)},_createAnimProxy:function(){var o=this._proxy=xe("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(o),this.on("zoomanim",function(l){var g=N5,_=this._proxy.style[g];j2(this._proxy,this.project(l.center,l.zoom),this.getZoomScale(l.zoom,1)),_===this._proxy.style[g]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){Oe(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var o=this.getCenter(),l=this.getZoom();j2(this._proxy,this.project(o,l),this.getZoomScale(l,1))},_catchTransitionEnd:function(o){this._animatingZoom&&o.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(o,l,g){if(this._animatingZoom)return!0;if(g=g||{},!this._zoomAnimated||g.animate===!1||this._nothingToAnimate()||Math.abs(l-this._zoom)>this.options.zoomAnimationThreshold)return!1;var _=this.getZoomScale(l),A=this._getCenterOffset(o)._divideBy(1-1/_);return g.animate!==!0&&!this.getSize().contains(A)?!1:(D(function(){this._moveStart(!0,g.noMoveStart||!1)._animateZoom(o,l,!0)},this),!0)},_animateZoom:function(o,l,g,_){this._mapPane&&(g&&(this._animatingZoom=!0,this._animateToCenter=o,this._animateToZoom=l,ee(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:o,zoom:l,noUpdate:_}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(u(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&Le(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 it(o,l){return new me(o,l)}var It=o1.extend({options:{position:"topright"},initialize:function(o){k(this,o)},getPosition:function(){return this.options.position},setPosition:function(o){var l=this._map;return l&&l.removeControl(this),this.options.position=o,l&&l.addControl(this),this},getContainer:function(){return this._container},addTo:function(o){this.remove(),this._map=o;var l=this._container=this.onAdd(o),g=this.getPosition(),_=o._controlCorners[g];return ee(l,"leaflet-control"),g.indexOf("bottom")!==-1?_.insertBefore(l,_.firstChild):_.appendChild(l),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(Oe(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(o){this._map&&o&&o.screenX>0&&o.screenY>0&&this._map.getContainer().focus()}}),u4=function(o){return new It(o)};me.include({addControl:function(o){return o.addTo(this),this},removeControl:function(o){return o.remove(),this},_initControlPos:function(){var o=this._controlCorners={},l="leaflet-",g=this._controlContainer=xe("div",l+"control-container",this._container);function _(A,U){var X=l+A+" "+l+U;o[A+U]=xe("div",X,g)}_("top","left"),_("top","right"),_("bottom","left"),_("bottom","right")},_clearControlPos:function(){for(var o in this._controlCorners)Oe(this._controlCorners[o]);Oe(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var b0=It.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(o,l,g,_){return g<_?-1:_1,this._baseLayersList.style.display=o?"":"none"),this._separator.style.display=l&&o?"":"none",this},_onLayerChange:function(o){this._handlingClick||this._update();var l=this._getLayer(d(o.target)),g=l.overlay?o.type==="add"?"overlayadd":"overlayremove":o.type==="add"?"baselayerchange":null;g&&this._map.fire(g,l)},_createRadioElement:function(o,l){var g='",_=document.createElement("div");return _.innerHTML=g,_.firstChild},_addItem:function(o){var l=document.createElement("label"),g=this._map.hasLayer(o.layer),_;o.overlay?(_=document.createElement("input"),_.type="checkbox",_.className="leaflet-control-layers-selector",_.defaultChecked=g):_=this._createRadioElement("leaflet-base-layers_"+d(this),g),this._layerControlInputs.push(_),_.layerId=d(o.layer),K1(_,"click",this._onInputClick,this);var A=document.createElement("span");A.innerHTML=" "+o.name;var U=document.createElement("span");l.appendChild(U),U.appendChild(_),U.appendChild(A);var X=o.overlay?this._overlaysList:this._baseLayersList;return X.appendChild(l),this._checkDisabledLayers(),l},_onInputClick:function(){if(!this._preventClick){var o=this._layerControlInputs,l,g,_=[],A=[];this._handlingClick=!0;for(var U=o.length-1;U>=0;U--)l=o[U],g=this._getLayer(l.layerId).layer,l.checked?_.push(g):l.checked||A.push(g);for(U=0;U=0;A--)l=o[A],g=this._getLayer(l.layerId).layer,l.disabled=g.options.minZoom!==void 0&&_g.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var o=this._section;this._preventClick=!0,K1(o,"click",te),this.expand();var l=this;setTimeout(function(){Pe(o,"click",te),l._preventClick=!1})}}),S0=function(o,l,g){return new b0(o,l,g)},xt=It.extend({options:{position:"topleft",zoomInText:'',zoomInTitle:"Zoom in",zoomOutText:'',zoomOutTitle:"Zoom out"},onAdd:function(o){var l="leaflet-control-zoom",g=xe("div",l+" leaflet-bar"),_=this.options;return this._zoomInButton=this._createButton(_.zoomInText,_.zoomInTitle,l+"-in",g,this._zoomIn),this._zoomOutButton=this._createButton(_.zoomOutText,_.zoomOutTitle,l+"-out",g,this._zoomOut),this._updateDisabled(),o.on("zoomend zoomlevelschange",this._updateDisabled,this),g},onRemove:function(o){o.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(o){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(o.shiftKey?3:1))},_createButton:function(o,l,g,_,A){var U=xe("a",g,_);return U.innerHTML=o,U.href="#",U.title=l,U.setAttribute("role","button"),U.setAttribute("aria-label",l),mn(U),K1(U,"click",be),K1(U,"click",A,this),K1(U,"click",this._refocusOnMap,this),U},_updateDisabled:function(){var o=this._map,l="leaflet-disabled";Le(this._zoomInButton,l),Le(this._zoomOutButton,l),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||o._zoom===o.getMinZoom())&&(ee(this._zoomOutButton,l),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||o._zoom===o.getMaxZoom())&&(ee(this._zoomInButton,l),this._zoomInButton.setAttribute("aria-disabled","true"))}});me.mergeOptions({zoomControl:!0}),me.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new xt,this.addControl(this.zoomControl))});var H9=function(o){return new xt(o)},E0=It.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(o){var l="leaflet-control-scale",g=xe("div",l),_=this.options;return this._addScales(_,l+"-line",g),o.on(_.updateWhenIdle?"moveend":"move",this._update,this),o.whenReady(this._update,this),g},onRemove:function(o){o.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(o,l,g){o.metric&&(this._mScale=xe("div",l,g)),o.imperial&&(this._iScale=xe("div",l,g))},_update:function(){var o=this._map,l=o.getSize().y/2,g=o.distance(o.containerPointToLatLng([0,l]),o.containerPointToLatLng([this.options.maxWidth,l]));this._updateScales(g)},_updateScales:function(o){this.options.metric&&o&&this._updateMetric(o),this.options.imperial&&o&&this._updateImperial(o)},_updateMetric:function(o){var l=this._getRoundNum(o),g=l<1e3?l+" m":l/1e3+" km";this._updateScale(this._mScale,g,l/o)},_updateImperial:function(o){var l=o*3.2808399,g,_,A;l>5280?(g=l/5280,_=this._getRoundNum(g),this._updateScale(this._iScale,_+" mi",_/g)):(A=this._getRoundNum(l),this._updateScale(this._iScale,A+" ft",A/l))},_updateScale:function(o,l,g){o.style.width=Math.round(this.options.maxWidth*g)+"px",o.innerHTML=l},_getRoundNum:function(o){var l=Math.pow(10,(Math.floor(o)+"").length-1),g=o/l;return g=g>=10?10:g>=5?5:g>=3?3:g>=2?2:1,l*g}}),Z9=function(o){return new E0(o)},G9='',B5=It.extend({options:{position:"bottomright",prefix:''+($1.inlineSvg?G9+" ":"")+"Leaflet"},initialize:function(o){k(this,o),this._attributions={}},onAdd:function(o){o.attributionControl=this,this._container=xe("div","leaflet-control-attribution"),mn(this._container);for(var l in o._layers)o._layers[l].getAttribution&&this.addAttribution(o._layers[l].getAttribution());return this._update(),o.on("layeradd",this._addAttribution,this),this._container},onRemove:function(o){o.off("layeradd",this._addAttribution,this)},_addAttribution:function(o){o.layer.getAttribution&&(this.addAttribution(o.layer.getAttribution()),o.layer.once("remove",function(){this.removeAttribution(o.layer.getAttribution())},this))},setPrefix:function(o){return this.options.prefix=o,this._update(),this},addAttribution:function(o){return o?(this._attributions[o]||(this._attributions[o]=0),this._attributions[o]++,this._update(),this):this},removeAttribution:function(o){return o?(this._attributions[o]&&(this._attributions[o]--,this._update()),this):this},_update:function(){if(this._map){var o=[];for(var l in this._attributions)this._attributions[l]&&o.push(l);var g=[];this.options.prefix&&g.push(this.options.prefix),o.length&&g.push(o.join(", ")),this._container.innerHTML=g.join(' ')}}});me.mergeOptions({attributionControl:!0}),me.addInitHook(function(){this.options.attributionControl&&new B5().addTo(this)});var q9=function(o){return new B5(o)};It.Layers=b0,It.Zoom=xt,It.Scale=E0,It.Attribution=B5,u4.layers=S0,u4.zoom=H9,u4.scale=Z9,u4.attribution=q9;var ze=o1.extend({initialize:function(o){this._map=o},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}});ze.addTo=function(o,l){return o.addHandler(l,this),this};var ba={Events:l1},Rt=$1.touch?"touchstart mousedown":"mousedown",g2=r1.extend({options:{clickTolerance:3},initialize:function(o,l,g,_){k(this,_),this._element=o,this._dragStartTarget=l||o,this._preventOutline=g},enable:function(){this._enabled||(K1(this._dragStartTarget,Rt,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(g2._dragging===this&&this.finishDrag(!0),Pe(this._dragStartTarget,Rt,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(o){if(this._enabled&&(this._moved=!1,!p0(this._element,"leaflet-zoom-anim"))){if(o.touches&&o.touches.length!==1){g2._dragging===this&&this.finishDrag();return}if(!(g2._dragging||o.shiftKey||o.which!==1&&o.button!==1&&!o.touches)&&(g2._dragging=this,this._preventOutline&&U5(this._element),g0(),D2(),!this._moving)){this.fire("down");var l=o.touches?o.touches[0]:o,g=B9(this._element);this._startPoint=new V(l.clientX,l.clientY),this._startPos=H4(this._element),this._parentScale=m0(g);var _=o.type==="mousedown";K1(document,_?"mousemove":"touchmove",this._onMove,this),K1(document,_?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(o){if(this._enabled){if(o.touches&&o.touches.length>1){this._moved=!0;return}var l=o.touches&&o.touches.length===1?o.touches[0]:o,g=new V(l.clientX,l.clientY)._subtract(this._startPoint);!g.x&&!g.y||Math.abs(g.x)+Math.abs(g.y)U&&(X=a1,U=u1);U>g&&(l[X]=1,yn(o,l,g,_,X),yn(o,l,g,X,A))}function Ea(o,l){for(var g=[o[0]],_=1,A=0,U=o.length;_l&&(g.push(o[_]),A=_);return Al.max.x&&(g|=2),o.yl.max.y&&(g|=8),g}function w3(o,l){var g=l.x-o.x,_=l.y-o.y;return g*g+_*_}function _n(o,l,g,_){var A=l.x,U=l.y,X=g.x-A,a1=g.y-U,u1=X*X+a1*a1,x1;return u1>0&&(x1=((o.x-A)*X+(o.y-U)*a1)/u1,x1>1?(A=g.x,U=g.y):x1>0&&(A+=X*x1,U+=a1*x1)),X=o.x-A,a1=o.y-U,_?X*X+a1*a1:new V(A,U)}function Ut(o){return!b(o[0])||typeof o[0][0]!="object"&&typeof o[0][0]<"u"}function T0(o){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),Ut(o)}function z5(o,l){var g,_,A,U,X,a1,u1,x1;if(!o||o.length===0)throw new Error("latlngs not passed");Ut(o)||(console.warn("latlngs are not flat! Only the first ring will be used"),o=o[0]);var C1=d1([0,0]),z1=F1(o),re=z1.getNorthWest().distanceTo(z1.getSouthWest())*z1.getNorthEast().distanceTo(z1.getNorthWest());re<1700&&(C1=_3(o));var Ve=o.length,je=[];for(g=0;g_){u1=(U-_)/A,x1=[a1.x-u1*(a1.x-X.x),a1.y-u1*(a1.y-X.y)];break}var rt=l.unproject(f1(x1));return d1([rt.lat+C1.lat,rt.lng+C1.lng])}var P0={__proto__:null,simplify:Ce,pointToSegmentDistance:G4,closestPointOnSegment:k0,clipSegment:Y9,_getEdgeIntersection:vn,_getBitCode:A4,_sqClosestPointOnSegment:_n,isFlat:Ut,_flat:T0,polylineCenter:z5},j5={project:function(o){return new V(o.lng,o.lat)},unproject:function(o){return new _1(o.y,o.x)},bounds:new w1([-180,-90],[180,90])},C0={R:6378137,R_MINOR:6356752314245179e-9,bounds:new w1([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(o){var l=Math.PI/180,g=this.R,_=o.lat*l,A=this.R_MINOR/g,U=Math.sqrt(1-A*A),X=U*Math.sin(_),a1=Math.tan(Math.PI/4-_/2)/Math.pow((1-X)/(1+X),U/2);return _=-g*Math.log(Math.max(a1,1e-10)),new V(o.lng*l*g,_)},unproject:function(o){for(var l=180/Math.PI,g=this.R,_=this.R_MINOR/g,A=Math.sqrt(1-_*_),U=Math.exp(-o.y/g),X=Math.PI/2-2*Math.atan(U),a1=0,u1=.1,x1;a1<15&&Math.abs(u1)>1e-7;a1++)x1=A*Math.sin(X),x1=Math.pow((1-x1)/(1+x1),A/2),u1=Math.PI/2-2*Math.atan(U*x1)-X,X+=u1;return new _1(X*l,o.x*l/g)}},N0={__proto__:null,LonLat:j5,Mercator:C0,SphericalMercator:O1},O0=r({},W1,{code:"EPSG:3395",projection:C0,transformation:function(){var o=.5/(Math.PI*C0.R);return g1(o,.5,-o,.5)}()}),X9=r({},W1,{code:"EPSG:4326",projection:j5,transformation:g1(1/180,1,-1/180,.5)}),K9=r({},I1,{projection:j5,transformation:g1(1,0,-1,0),scale:function(o){return Math.pow(2,o)},zoom:function(o){return Math.log(o)/Math.LN2},distance:function(o,l){var g=l.lng-o.lng,_=l.lat-o.lat;return Math.sqrt(g*g+_*_)},infinite:!0});I1.Earth=W1,I1.EPSG3395=O0,I1.EPSG3857=J1,I1.EPSG900913=D1,I1.EPSG4326=X9,I1.Simple=K9;var Re=r1.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(o){return o.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(o){return o&&o.removeLayer(this),this},getPane:function(o){return this._map.getPane(o?this.options[o]||o:this.options.pane)},addInteractiveTarget:function(o){return this._map._targets[d(o)]=this,this},removeInteractiveTarget:function(o){return delete this._map._targets[d(o)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(o){var l=o.target;if(l.hasLayer(this)){if(this._map=l,this._zoomAnimated=l._zoomAnimated,this.getEvents){var g=this.getEvents();l.on(g,this),this.once("remove",function(){l.off(g,this)},this)}this.onAdd(l),this.fire("add"),l.fire("layeradd",{layer:this})}}});me.include({addLayer:function(o){if(!o._layerAdd)throw new Error("The provided object is not a Layer.");var l=d(o);return this._layers[l]?this:(this._layers[l]=o,o._mapToAdd=this,o.beforeAdd&&o.beforeAdd(this),this.whenReady(o._layerAdd,o),this)},removeLayer:function(o){var l=d(o);return this._layers[l]?(this._loaded&&o.onRemove(this),delete this._layers[l],this._loaded&&(this.fire("layerremove",{layer:o}),o.fire("remove")),o._map=o._mapToAdd=null,this):this},hasLayer:function(o){return d(o)in this._layers},eachLayer:function(o,l){for(var g in this._layers)o.call(l,this._layers[g]);return this},_addLayers:function(o){o=o?b(o)?o:[o]:[];for(var l=0,g=o.length;lthis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()=2&&l[0]instanceof _1&&l[0].equals(l[g-1])&&l.pop(),l},_setLatLngs:function(o){qt.prototype._setLatLngs.call(this,o),Ut(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return Ut(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var o=this._renderer._bounds,l=this.options.weight,g=new V(l,l);if(o=new w1(o.min.subtract(g),o.max.add(g)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(o))){if(this.options.noClip){this._parts=this._rings;return}for(var _=0,A=this._rings.length,U;_o.y!=A.y>o.y&&o.x<(A.x-_.x)*(o.y-_.y)/(A.y-_.y)+_.x&&(l=!l);return l||qt.prototype._containsPoint.call(this,o,!0)}});function ka(o,l){return new S3(o,l)}var bt=k4.extend({initialize:function(o,l){k(this,l),this._layers={},o&&this.addData(o)},addData:function(o){var l=b(o)?o:o.features,g,_,A;if(l){for(g=0,_=l.length;g<_;g++)A=l[g],(A.geometries||A.geometry||A.features||A.coordinates)&&this.addData(A);return this}var U=this.options;if(U.filter&&!U.filter(o))return this;var X=St(o,U);return X?(X.feature=q4(o),X.defaultOptions=X.options,this.resetStyle(X),U.onEachFeature&&U.onEachFeature(o,X),this.addLayer(X)):this},resetStyle:function(o){return o===void 0?this.eachLayer(this.resetStyle,this):(o.options=r({},o.defaultOptions),this._setLayerStyle(o,this.options.style),this)},setStyle:function(o){return this.eachLayer(function(l){this._setLayerStyle(l,o)},this)},_setLayerStyle:function(o,l){o.setStyle&&(typeof l=="function"&&(l=l(o.feature)),o.setStyle(l))}});function St(o,l){var g=o.type==="Feature"?o.geometry:o,_=g?g.coordinates:null,A=[],U=l&&l.pointToLayer,X=l&&l.coordsToLatLng||I0,a1,u1,x1,C1;if(!_&&!g)return null;switch(g.type){case"Point":return a1=X(_),F0(U,o,a1,l);case"MultiPoint":for(x1=0,C1=_.length;x10&&A.push(A[0].slice()),A}function E3(o,l){return o.feature?r({},o.feature,{geometry:l}):q4(l)}function q4(o){return o.type==="Feature"||o.type==="FeatureCollection"?o:{type:"Feature",properties:{},geometry:o}}var t1={toGeoJSON:function(o){return E3(this,{type:"Point",coordinates:R0(this.getLatLng(),o)})}};D5.include(t1),W5.include(t1),Q5.include(t1),qt.include({toGeoJSON:function(o){var l=!Ut(this._latlngs),g=Z5(this._latlngs,l?1:0,!1,o);return E3(this,{type:(l?"Multi":"")+"LineString",coordinates:g})}}),S3.include({toGeoJSON:function(o){var l=!Ut(this._latlngs),g=l&&!Ut(this._latlngs[0]),_=Z5(this._latlngs,g?2:l?1:0,!0,o);return l||(_=[_]),E3(this,{type:(g?"Multi":"")+"Polygon",coordinates:_})}}),m2.include({toMultiPoint:function(o){var l=[];return this.eachLayer(function(g){l.push(g.toGeoJSON(o).geometry.coordinates)}),E3(this,{type:"MultiPoint",coordinates:l})},toGeoJSON:function(o){var l=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(l==="MultiPoint")return this.toMultiPoint(o);var g=l==="GeometryCollection",_=[];return this.eachLayer(function(A){if(A.toGeoJSON){var U=A.toGeoJSON(o);if(g)_.push(U.geometry);else{var X=q4(U);X.type==="FeatureCollection"?_.push.apply(_,X.features):_.push(X)}}}),g?E3(this,{geometries:_,type:"GeometryCollection"}):{type:"FeatureCollection",features:_}}});function h1(o,l){return new bt(o,l)}var c1=h1,N1=Re.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(o,l,g){this._url=o,this._bounds=F1(l),k(this,g)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(ee(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){Oe(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(o){return this.options.opacity=o,this._image&&this._updateOpacity(),this},setStyle:function(o){return o.opacity&&this.setOpacity(o.opacity),this},bringToFront:function(){return this._map&&z2(this._image),this},bringToBack:function(){return this._map&&p2(this._image),this},setUrl:function(o){return this._url=o,this._image&&(this._image.src=o),this},setBounds:function(o){return this._bounds=F1(o),this._map&&this._reset(),this},getEvents:function(){var o={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(o.zoomanim=this._animateZoom),o},setZIndex:function(o){return this.options.zIndex=o,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var o=this._url.tagName==="IMG",l=this._image=o?this._url:xe("img");if(ee(l,"leaflet-image-layer"),this._zoomAnimated&&ee(l,"leaflet-zoom-animated"),this.options.className&&ee(l,this.options.className),l.onselectstart=h,l.onmousemove=h,l.onload=u(this.fire,this,"load"),l.onerror=u(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(l.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),o){this._url=l.src;return}l.src=this._url,l.alt=this.options.alt},_animateZoom:function(o){var l=this._map.getZoomScale(o.zoom),g=this._map._latLngBoundsToNewLayerBounds(this._bounds,o.zoom,o.center).min;j2(this._image,g,l)},_reset:function(){var o=this._image,l=new w1(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),g=l.getSize();We(o,l.min),o.style.width=g.x+"px",o.style.height=g.y+"px"},_updateOpacity:function(){Ft(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 o=this.options.errorOverlayUrl;o&&this._url!==o&&(this._url=o,this._image.src=o)},getCenter:function(){return this._bounds.getCenter()}}),V1=function(o,l,g){return new N1(o,l,g)},Se=N1.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var o=this._url.tagName==="VIDEO",l=this._image=o?this._url:xe("video");if(ee(l,"leaflet-image-layer"),this._zoomAnimated&&ee(l,"leaflet-zoom-animated"),this.options.className&&ee(l,this.options.className),l.onselectstart=h,l.onmousemove=h,l.onloadeddata=u(this.fire,this,"load"),o){for(var g=l.getElementsByTagName("source"),_=[],A=0;A0?_:[l.src];return}b(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(l.style,"objectFit")&&(l.style.objectFit="fill"),l.autoplay=!!this.options.autoplay,l.loop=!!this.options.loop,l.muted=!!this.options.muted,l.playsInline=!!this.options.playsInline;for(var U=0;UA?(l.height=A+"px",ee(o,U)):Le(o,U),this._containerWidth=this._container.offsetWidth},_animateZoom:function(o){var l=this._map._latLngToNewLayerPoint(this._latlng,o.zoom,o.center),g=this._getAnchor();We(this._container,l.add(g))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var o=this._map,l=parseInt(dn(this._container,"marginBottom"),10)||0,g=this._container.offsetHeight+l,_=this._containerWidth,A=new V(this._containerLeft,-g-this._containerBottom);A._add(H4(this._container));var U=o.layerPointToContainerPoint(A),X=f1(this.options.autoPanPadding),a1=f1(this.options.autoPanPaddingTopLeft||X),u1=f1(this.options.autoPanPaddingBottomRight||X),x1=o.getSize(),C1=0,z1=0;U.x+_+u1.x>x1.x&&(C1=U.x+_-x1.x+u1.x),U.x-C1-a1.x<0&&(C1=U.x-a1.x),U.y+g+u1.y>x1.y&&(z1=U.y+g-x1.y+u1.y),U.y-z1-a1.y<0&&(z1=U.y-a1.y),(C1||z1)&&(this.options.keepInView&&(this._autopanning=!0),o.fire("autopanstart").panBy([C1,z1]))}},_getAnchor:function(){return f1(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),G5=function(o,l){return new mt(o,l)};me.mergeOptions({closePopupOnClick:!0}),me.include({openPopup:function(o,l,g){return this._initOverlay(mt,o,l,g).openOn(this),this},closePopup:function(o){return o=arguments.length?o:this._popup,o&&o.close(),this}}),Re.include({bindPopup:function(o,l){return this._popup=this._initOverlay(mt,this._popup,o,l),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(o){return this._popup&&(this instanceof k4||(this._popup._source=this),this._popup._prepareOpen(o||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(o){return this._popup&&this._popup.setContent(o),this},getPopup:function(){return this._popup},_openPopup:function(o){if(!(!this._popup||!this._map)){be(o);var l=o.layer||o.target;if(this._popup._source===l&&!(l instanceof y2)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(o.latlng);return}this._popup._source=l,this.openPopup(o.latlng)}},_movePopup:function(o){this._popup.setLatLng(o.latlng)},_onKeyPress:function(o){o.originalEvent.keyCode===13&&this._openPopup(o)}});var q5=T4.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(o){T4.prototype.onAdd.call(this,o),this.setOpacity(this.options.opacity),o.fire("tooltipopen",{tooltip:this}),this._source&&(this.addEventParent(this._source),this._source.fire("tooltipopen",{tooltip:this},!0))},onRemove:function(o){T4.prototype.onRemove.call(this,o),o.fire("tooltipclose",{tooltip:this}),this._source&&(this.removeEventParent(this._source),this._source.fire("tooltipclose",{tooltip:this},!0))},getEvents:function(){var o=T4.prototype.getEvents.call(this);return this.options.permanent||(o.preclick=this.close),o},_initLayout:function(){var o="leaflet-tooltip",l=o+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=xe("div",l),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+d(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(o){var l,g,_=this._map,A=this._container,U=_.latLngToContainerPoint(_.getCenter()),X=_.layerPointToContainerPoint(o),a1=this.options.direction,u1=A.offsetWidth,x1=A.offsetHeight,C1=f1(this.options.offset),z1=this._getAnchor();a1==="top"?(l=u1/2,g=x1):a1==="bottom"?(l=u1/2,g=0):a1==="center"?(l=u1/2,g=x1/2):a1==="right"?(l=0,g=x1/2):a1==="left"?(l=u1,g=x1/2):X.xthis.options.maxZoom||g_?this._retainParent(A,U,X,_):!1)},_retainChildren:function(o,l,g,_){for(var A=2*o;A<2*o+2;A++)for(var U=2*l;U<2*l+2;U++){var X=new V(A,U);X.z=g+1;var a1=this._tileCoordsToKey(X),u1=this._tiles[a1];if(u1&&u1.active){u1.retain=!0;continue}else u1&&u1.loaded&&(u1.retain=!0);g+1<_&&this._retainChildren(A,U,g+1,_)}},_resetView:function(o){var l=o&&(o.pinch||o.flyTo);this._setView(this._map.getCenter(),this._map.getZoom(),l,l)},_animateZoom:function(o){this._setView(o.center,o.zoom,!0,o.noUpdate)},_clampZoom:function(o){var l=this.options;return l.minNativeZoom!==void 0&&othis.options.maxZoom||this.options.minZoom!==void 0&&A1){this._setView(o,g);return}for(var z1=A.min.y;z1<=A.max.y;z1++)for(var re=A.min.x;re<=A.max.x;re++){var Ve=new V(re,z1);if(Ve.z=this._tileZoom,!!this._isValidTile(Ve)){var je=this._tiles[this._tileCoordsToKey(Ve)];je?je.current=!0:X.push(Ve)}}if(X.sort(function(rt,l4){return rt.distanceTo(U)-l4.distanceTo(U)}),X.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var ut=document.createDocumentFragment();for(re=0;reg.max.x)||!l.wrapLat&&(o.yg.max.y))return!1}if(!this.options.bounds)return!0;var _=this._tileCoordsToBounds(o);return F1(this.options.bounds).overlaps(_)},_keyToBounds:function(o){return this._tileCoordsToBounds(this._keyToTileCoords(o))},_tileCoordsToNwSe:function(o){var l=this._map,g=this.getTileSize(),_=o.scaleBy(g),A=_.add(g),U=l.unproject(_,o.z),X=l.unproject(A,o.z);return[U,X]},_tileCoordsToBounds:function(o){var l=this._tileCoordsToNwSe(o),g=new j1(l[0],l[1]);return this.options.noWrap||(g=this._map.wrapLatLngBounds(g)),g},_tileCoordsToKey:function(o){return o.x+":"+o.y+":"+o.z},_keyToTileCoords:function(o){var l=o.split(":"),g=new V(+l[0],+l[1]);return g.z=+l[2],g},_removeTile:function(o){var l=this._tiles[o];l&&(Oe(l.el),delete this._tiles[o],this.fire("tileunload",{tile:l.el,coords:this._keyToTileCoords(o)}))},_initTile:function(o){ee(o,"leaflet-tile");var l=this.getTileSize();o.style.width=l.x+"px",o.style.height=l.y+"px",o.onselectstart=h,o.onmousemove=h,$1.ielt9&&this.options.opacity<1&&Ft(o,this.options.opacity)},_addTile:function(o,l){var g=this._getTilePos(o),_=this._tileCoordsToKey(o),A=this.createTile(this._wrapCoords(o),u(this._tileReady,this,o));this._initTile(A),this.createTile.length<2&&D(u(this._tileReady,this,o,null,A)),We(A,g),this._tiles[_]={el:A,coords:o,current:!0},l.appendChild(A),this.fire("tileloadstart",{tile:A,coords:o})},_tileReady:function(o,l,g){l&&this.fire("tileerror",{error:l,tile:g,coords:o});var _=this._tileCoordsToKey(o);g=this._tiles[_],g&&(g.loaded=+new Date,this._map._fadeAnimated?(Ft(g.el,0),J(this._fadeFrame),this._fadeFrame=D(this._updateOpacity,this)):(g.active=!0,this._pruneTiles()),l||(ee(g.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:g.el,coords:o})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),$1.ielt9||!this._map._fadeAnimated?D(this._pruneTiles,this):setTimeout(u(this._pruneTiles,this),250)))},_getTilePos:function(o){return o.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(o){var l=new V(this._wrapX?m(o.x,this._wrapX):o.x,this._wrapY?m(o.y,this._wrapY):o.y);return l.z=o.z,l},_pxBoundsToTileRange:function(o){var l=this.getTileSize();return new w1(o.min.unscaleBy(l).floor(),o.max.unscaleBy(l).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var o in this._tiles)if(!this._tiles[o].loaded)return!1;return!0}});function Ta(o){return new ve(o)}var W2=ve.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1,referrerPolicy:!1},initialize:function(o,l){this._url=o,l=k(this,l),l.detectRetina&&$1.retina&&l.maxZoom>0?(l.tileSize=Math.floor(l.tileSize/2),l.zoomReverse?(l.zoomOffset--,l.minZoom=Math.min(l.maxZoom,l.minZoom+1)):(l.zoomOffset++,l.maxZoom=Math.max(l.minZoom,l.maxZoom-1)),l.minZoom=Math.max(0,l.minZoom)):l.zoomReverse?l.minZoom=Math.min(l.maxZoom,l.minZoom):l.maxZoom=Math.max(l.minZoom,l.maxZoom),typeof l.subdomains=="string"&&(l.subdomains=l.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(o,l){return this._url===o&&l===void 0&&(l=!0),this._url=o,l||this.redraw(),this},createTile:function(o,l){var g=document.createElement("img");return K1(g,"load",u(this._tileOnLoad,this,l,g)),K1(g,"error",u(this._tileOnError,this,l,g)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(g.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(g.referrerPolicy=this.options.referrerPolicy),g.alt="",g.src=this.getTileUrl(o),g},getTileUrl:function(o){var l={r:$1.retina?"@2x":"",s:this._getSubdomain(o),x:o.x,y:o.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var g=this._globalTileRange.max.y-o.y;this.options.tms&&(l.y=g),l["-y"]=g}return w(this._url,r(l,this.options))},_tileOnLoad:function(o,l){$1.ielt9?setTimeout(u(o,this,null,l),0):o(null,l)},_tileOnError:function(o,l,g){var _=this.options.errorTileUrl;_&&l.getAttribute("src")!==_&&(l.src=_),o(g,l)},_onTileRemove:function(o){o.tile.onload=null},_getZoomForUrl:function(){var o=this._tileZoom,l=this.options.maxZoom,g=this.options.zoomReverse,_=this.options.zoomOffset;return g&&(o=l-o),o+_},_getSubdomain:function(o){var l=Math.abs(o.x+o.y)%this.options.subdomains.length;return this.options.subdomains[l]},_abortLoading:function(){var o,l;for(o in this._tiles)if(this._tiles[o].coords.z!==this._tileZoom&&(l=this._tiles[o].el,l.onload=h,l.onerror=h,!l.complete)){l.src=$;var g=this._tiles[o].coords;Oe(l),delete this._tiles[o],this.fire("tileabort",{tile:l,coords:g})}},_removeTile:function(o){var l=this._tiles[o];if(l)return l.el.setAttribute("src",$),ve.prototype._removeTile.call(this,o)},_tileReady:function(o,l,g){if(!(!this._map||g&&g.getAttribute("src")===$))return ve.prototype._tileReady.call(this,o,l,g)}});function Sn(o,l){return new W2(o,l)}var ti=W2.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(o,l){this._url=o;var g=r({},this.defaultWmsParams);for(var _ in l)_ in this.options||(g[_]=l[_]);l=k(this,l);var A=l.detectRetina&&$1.retina?2:1,U=this.getTileSize();g.width=U.x*A,g.height=U.y*A,this.wmsParams=g},onAdd:function(o){this._crs=this.options.crs||o.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var l=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[l]=this._crs.code,W2.prototype.onAdd.call(this,o)},getTileUrl:function(o){var l=this._tileCoordsToNwSe(o),g=this._crs,_=T1(g.project(l[0]),g.project(l[1])),A=_.min,U=_.max,X=(this._wmsVersion>=1.3&&this._crs===X9?[A.y,A.x,U.y,U.x]:[A.x,A.y,U.x,U.y]).join(","),a1=W2.prototype.getTileUrl.call(this,o);return a1+O(this.wmsParams,a1,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+X},setParams:function(o,l){return r(this.wmsParams,o),l||this.redraw(),this}});function Pa(o,l){return new ti(o,l)}W2.WMS=ti,Sn.wms=Pa;var V4=Re.extend({options:{padding:.1},initialize:function(o){k(this,o),d(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),ee(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 o={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(o.zoomanim=this._onAnimZoom),o},_onAnimZoom:function(o){this._updateTransform(o.center,o.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(o,l){var g=this._map.getZoomScale(l,this._zoom),_=this._map.getSize().multiplyBy(.5+this.options.padding),A=this._map.project(this._center,l),U=_.multiplyBy(-g).add(A).subtract(this._map._getNewPixelOrigin(o,l));$1.any3d?j2(this._container,U,g):We(this._container,U)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var o in this._layers)this._layers[o]._reset()},_onZoomEnd:function(){for(var o in this._layers)this._layers[o]._project()},_updatePaths:function(){for(var o in this._layers)this._layers[o]._update()},_update:function(){var o=this.options.padding,l=this._map.getSize(),g=this._map.containerPointToLayerPoint(l.multiplyBy(-o)).round();this._bounds=new w1(g,g.add(l.multiplyBy(1+o*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),En=V4.extend({options:{tolerance:0},getEvents:function(){var o=V4.prototype.getEvents.call(this);return o.viewprereset=this._onViewPreReset,o},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){V4.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var o=this._container=document.createElement("canvas");K1(o,"mousemove",this._onMouseMove,this),K1(o,"click dblclick mousedown mouseup contextmenu",this._onClick,this),K1(o,"mouseout",this._handleMouseOut,this),o._leaflet_disable_events=!0,this._ctx=o.getContext("2d")},_destroyContainer:function(){J(this._redrawRequest),delete this._ctx,Oe(this._container),Pe(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var o;this._redrawBounds=null;for(var l in this._layers)o=this._layers[l],o._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){V4.prototype._update.call(this);var o=this._bounds,l=this._container,g=o.getSize(),_=$1.retina?2:1;We(l,o.min),l.width=_*g.x,l.height=_*g.y,l.style.width=g.x+"px",l.style.height=g.y+"px",$1.retina&&this._ctx.scale(2,2),this._ctx.translate(-o.min.x,-o.min.y),this.fire("update")}},_reset:function(){V4.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(o){this._updateDashArray(o),this._layers[d(o)]=o;var l=o._order={layer:o,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=l),this._drawLast=l,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(o){this._requestRedraw(o)},_removePath:function(o){var l=o._order,g=l.next,_=l.prev;g?g.prev=_:this._drawLast=_,_?_.next=g:this._drawFirst=g,delete o._order,delete this._layers[d(o)],this._requestRedraw(o)},_updatePath:function(o){this._extendRedrawBounds(o),o._project(),o._update(),this._requestRedraw(o)},_updateStyle:function(o){this._updateDashArray(o),this._requestRedraw(o)},_updateDashArray:function(o){if(typeof o.options.dashArray=="string"){var l=o.options.dashArray.split(/[, ]+/),g=[],_,A;for(A=0;A')}}catch{}return function(o){return document.createElement("<"+o+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),ni={_initContainer:function(){this._container=xe("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(V4.prototype._update.call(this),this.fire("update"))},_initPath:function(o){var l=o._container=_2("shape");ee(l,"leaflet-vml-shape "+(this.options.className||"")),l.coordsize="1 1",o._path=_2("path"),l.appendChild(o._path),this._updateStyle(o),this._layers[d(o)]=o},_addPath:function(o){var l=o._container;this._container.appendChild(l),o.options.interactive&&o.addInteractiveTarget(l)},_removePath:function(o){var l=o._container;Oe(l),o.removeInteractiveTarget(l),delete this._layers[d(o)]},_updateStyle:function(o){var l=o._stroke,g=o._fill,_=o.options,A=o._container;A.stroked=!!_.stroke,A.filled=!!_.fill,_.stroke?(l||(l=o._stroke=_2("stroke")),A.appendChild(l),l.weight=_.weight+"px",l.color=_.color,l.opacity=_.opacity,_.dashArray?l.dashStyle=b(_.dashArray)?_.dashArray.join(" "):_.dashArray.replace(/( *, *)/g," "):l.dashStyle="",l.endcap=_.lineCap.replace("butt","flat"),l.joinstyle=_.lineJoin):l&&(A.removeChild(l),o._stroke=null),_.fill?(g||(g=o._fill=_2("fill")),A.appendChild(g),g.color=_.fillColor||_.color,g.opacity=_.fillOpacity):g&&(A.removeChild(g),o._fill=null)},_updateCircle:function(o){var l=o._point.round(),g=Math.round(o._radius),_=Math.round(o._radiusY||g);this._setPath(o,o._empty()?"M0 0":"AL "+l.x+","+l.y+" "+g+","+_+" 0,"+65535*360)},_setPath:function(o,l){o._path.v=l},_bringToFront:function(o){z2(o._container)},_bringToBack:function(o){p2(o._container)}},H2=$1.vml?_2:ae,A3=V4.extend({_initContainer:function(){this._container=H2("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=H2("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){Oe(this._container),Pe(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){V4.prototype._update.call(this);var o=this._bounds,l=o.getSize(),g=this._container;(!this._svgSize||!this._svgSize.equals(l))&&(this._svgSize=l,g.setAttribute("width",l.x),g.setAttribute("height",l.y)),We(g,o.min),g.setAttribute("viewBox",[o.min.x,o.min.y,l.x,l.y].join(" ")),this.fire("update")}},_initPath:function(o){var l=o._path=H2("path");o.options.className&&ee(l,o.options.className),o.options.interactive&&ee(l,"leaflet-interactive"),this._updateStyle(o),this._layers[d(o)]=o},_addPath:function(o){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(o._path),o.addInteractiveTarget(o._path)},_removePath:function(o){Oe(o._path),o.removeInteractiveTarget(o._path),delete this._layers[d(o)]},_updatePath:function(o){o._project(),o._update()},_updateStyle:function(o){var l=o._path,g=o.options;l&&(g.stroke?(l.setAttribute("stroke",g.color),l.setAttribute("stroke-opacity",g.opacity),l.setAttribute("stroke-width",g.weight),l.setAttribute("stroke-linecap",g.lineCap),l.setAttribute("stroke-linejoin",g.lineJoin),g.dashArray?l.setAttribute("stroke-dasharray",g.dashArray):l.removeAttribute("stroke-dasharray"),g.dashOffset?l.setAttribute("stroke-dashoffset",g.dashOffset):l.removeAttribute("stroke-dashoffset")):l.setAttribute("stroke","none"),g.fill?(l.setAttribute("fill",g.fillColor||g.color),l.setAttribute("fill-opacity",g.fillOpacity),l.setAttribute("fill-rule",g.fillRule||"evenodd")):l.setAttribute("fill","none"))},_updatePoly:function(o,l){this._setPath(o,we(o._parts,l))},_updateCircle:function(o){var l=o._point,g=Math.max(Math.round(o._radius),1),_=Math.max(Math.round(o._radiusY),1)||g,A="a"+g+","+_+" 0 1,0 ",U=o._empty()?"M0 0":"M"+(l.x-g)+","+l.y+A+g*2+",0 "+A+-g*2+",0 ";this._setPath(o,U)},_setPath:function(o,l){o._path.setAttribute("d",l)},_bringToFront:function(o){z2(o._path)},_bringToBack:function(o){p2(o._path)}});$1.vml&&A3.include(ni);function $0(o){return $1.svg||$1.vml?new A3(o):null}me.include({getRenderer:function(o){var l=o.options.renderer||this._getPaneRenderer(o.options.pane)||this.options.renderer||this._renderer;return l||(l=this._renderer=this._createRenderer()),this.hasLayer(l)||this.addLayer(l),l},_getPaneRenderer:function(o){if(o==="overlayPane"||o===void 0)return!1;var l=this._paneRenderers[o];return l===void 0&&(l=this._createRenderer({pane:o}),this._paneRenderers[o]=l),l},_createRenderer:function(o){return this.options.preferCanvas&&Y4(o)||$0(o)}});var Mn=S3.extend({initialize:function(o,l){S3.prototype.initialize.call(this,this._boundsToLatLngs(o),l)},setBounds:function(o){return this.setLatLngs(this._boundsToLatLngs(o))},_boundsToLatLngs:function(o){return o=F1(o),[o.getSouthWest(),o.getNorthWest(),o.getNorthEast(),o.getSouthEast()]}});function ii(o,l){return new Mn(o,l)}A3.create=H2,A3.pointsToPath=we,bt.geometryToLayer=St,bt.coordsToLatLng=I0,bt.coordsToLatLngs=H5,bt.latLngToCoords=R0,bt.latLngsToCoords=Z5,bt.getFeature=E3,bt.asFeature=q4,me.mergeOptions({boxZoom:!0});var k3=ze.extend({initialize:function(o){this._map=o,this._container=o._container,this._pane=o._panes.overlayPane,this._resetStateTimeout=0,o.on("unload",this._destroy,this)},addHooks:function(){K1(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){Pe(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){Oe(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(o){if(!o.shiftKey||o.which!==1&&o.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),D2(),g0(),this._startPoint=this._map.mouseEventToContainerPoint(o),K1(document,{contextmenu:be,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(o){this._moved||(this._moved=!0,this._box=xe("div","leaflet-zoom-box",this._container),ee(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(o);var l=new w1(this._point,this._startPoint),g=l.getSize();We(this._box,l.min),this._box.style.width=g.x+"px",this._box.style.height=g.y+"px"},_finish:function(){this._moved&&(Oe(this._box),Le(this._container,"leaflet-crosshair")),E4(),I5(),Pe(document,{contextmenu:be,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(o){if(!(o.which!==1&&o.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(u(this._resetState,this),0);var l=new j1(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(l).fire("boxzoomend",{boxZoomBounds:l})}},_onKeyDown:function(o){o.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});me.addInitHook("addHandler","boxZoom",k3),me.mergeOptions({doubleClickZoom:!0});var w2=ze.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(o){var l=this._map,g=l.getZoom(),_=l.options.zoomDelta,A=o.originalEvent.shiftKey?g-_:g+_;l.options.doubleClickZoom==="center"?l.setZoom(A):l.setZoomAround(o.containerPoint,A)}});me.addInitHook("addHandler","doubleClickZoom",w2),me.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var An=ze.extend({addHooks:function(){if(!this._draggable){var o=this._map;this._draggable=new g2(o._mapPane,o._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),o.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),o.on("zoomend",this._onZoomEnd,this),o.whenReady(this._onZoomEnd,this))}ee(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){Le(this._map._container,"leaflet-grab"),Le(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 o=this._map;if(o._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var l=F1(this._map.options.maxBounds);this._offsetLimit=T1(this._map.latLngToContainerPoint(l.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(l.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;o.fire("movestart").fire("dragstart"),o.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(o){if(this._map.options.inertia){var l=this._lastTime=+new Date,g=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(g),this._times.push(l),this._prunePositions(l)}this._map.fire("move",o).fire("drag",o)},_prunePositions:function(o){for(;this._positions.length>1&&o-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var o=this._map.getSize().divideBy(2),l=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=l.subtract(o).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(o,l){return o-(o-l)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var o=this._draggable._newPos.subtract(this._draggable._startPos),l=this._offsetLimit;o.xl.max.x&&(o.x=this._viscousLimit(o.x,l.max.x)),o.y>l.max.y&&(o.y=this._viscousLimit(o.y,l.max.y)),this._draggable._newPos=this._draggable._startPos.add(o)}},_onPreDragWrap:function(){var o=this._worldWidth,l=Math.round(o/2),g=this._initialWorldOffset,_=this._draggable._newPos.x,A=(_-l+g)%o+l-g,U=(_+l+g)%o-l-g,X=Math.abs(A+g)0?U:-U))-l;this._delta=0,this._startTime=null,X&&(o.options.scrollWheelZoom==="center"?o.setZoom(l+X):o.setZoomAround(this._lastMousePos,l+X))}});me.addInitHook("addHandler","scrollWheelZoom",oi);var Ca=600;me.mergeOptions({tapHold:$1.touchNative&&$1.safari&&$1.mobile,tapTolerance:15});var kn=ze.extend({addHooks:function(){K1(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){Pe(this._map._container,"touchstart",this._onDown,this)},_onDown:function(o){if(clearTimeout(this._holdTimeout),o.touches.length===1){var l=o.touches[0];this._startPos=this._newPos=new V(l.clientX,l.clientY),this._holdTimeout=setTimeout(u(function(){this._cancel(),this._isTapValid()&&(K1(document,"touchend",te),K1(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",l))},this),Ca),K1(document,"touchend touchcancel contextmenu",this._cancel,this),K1(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function o(){Pe(document,"touchend",te),Pe(document,"touchend touchcancel",o)},_cancel:function(){clearTimeout(this._holdTimeout),Pe(document,"touchend touchcancel contextmenu",this._cancel,this),Pe(document,"touchmove",this._onMove,this)},_onMove:function(o){var l=o.touches[0];this._newPos=new V(l.clientX,l.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(o,l){var g=new MouseEvent(o,{bubbles:!0,cancelable:!0,view:window,screenX:l.screenX,screenY:l.screenY,clientX:l.clientX,clientY:l.clientY});g._simulated=!0,l.target.dispatchEvent(g)}});me.addInitHook("addHandler","tapHold",kn),me.mergeOptions({touchZoom:$1.touch,bounceAtZoomLimits:!0});var Tn=ze.extend({addHooks:function(){ee(this._map._container,"leaflet-touch-zoom"),K1(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){Le(this._map._container,"leaflet-touch-zoom"),Pe(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(o){var l=this._map;if(!(!o.touches||o.touches.length!==2||l._animatingZoom||this._zooming)){var g=l.mouseEventToContainerPoint(o.touches[0]),_=l.mouseEventToContainerPoint(o.touches[1]);this._centerPoint=l.getSize()._divideBy(2),this._startLatLng=l.containerPointToLatLng(this._centerPoint),l.options.touchZoom!=="center"&&(this._pinchStartLatLng=l.containerPointToLatLng(g.add(_)._divideBy(2))),this._startDist=g.distanceTo(_),this._startZoom=l.getZoom(),this._moved=!1,this._zooming=!0,l._stop(),K1(document,"touchmove",this._onTouchMove,this),K1(document,"touchend touchcancel",this._onTouchEnd,this),te(o)}},_onTouchMove:function(o){if(!(!o.touches||o.touches.length!==2||!this._zooming)){var l=this._map,g=l.mouseEventToContainerPoint(o.touches[0]),_=l.mouseEventToContainerPoint(o.touches[1]),A=g.distanceTo(_)/this._startDist;if(this._zoom=l.getScaleZoom(A,this._startZoom),!l.options.bounceAtZoomLimits&&(this._zooml.getMaxZoom()&&A>1)&&(this._zoom=l._limitZoom(this._zoom)),l.options.touchZoom==="center"){if(this._center=this._startLatLng,A===1)return}else{var U=g._add(_)._divideBy(2)._subtract(this._centerPoint);if(A===1&&U.x===0&&U.y===0)return;this._center=l.unproject(l.project(this._pinchStartLatLng,this._zoom).subtract(U),this._zoom)}this._moved||(l._moveStart(!0,!1),this._moved=!0),J(this._animRequest);var X=u(l._move,l,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=D(X,this,!0),te(o)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,J(this._animRequest),Pe(document,"touchmove",this._onTouchMove,this),Pe(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))}});me.addInitHook("addHandler","touchZoom",Tn),me.BoxZoom=k3,me.DoubleClickZoom=w2,me.Drag=An,me.Keyboard=ri,me.ScrollWheelZoom=oi,me.TapHold=kn,me.TouchZoom=Tn,n.Bounds=w1,n.Browser=$1,n.CRS=I1,n.Canvas=En,n.Circle=W5,n.CircleMarker=Q5,n.Class=o1,n.Control=It,n.DivIcon=bn,n.DivOverlay=T4,n.DomEvent=xa,n.DomUtil=z9,n.Draggable=g2,n.Evented=r1,n.FeatureGroup=k4,n.GeoJSON=bt,n.GridLayer=ve,n.Handler=ze,n.Icon=x3,n.ImageOverlay=N1,n.LatLng=_1,n.LatLngBounds=j1,n.Layer=Re,n.LayerGroup=m2,n.LineUtil=P0,n.Map=me,n.Marker=D5,n.Mixin=ba,n.Path=y2,n.Point=V,n.PolyUtil=A0,n.Polygon=S3,n.Polyline=qt,n.Popup=mt,n.PosAnimation=x0,n.Projection=N0,n.Rectangle=Mn,n.Renderer=V4,n.SVG=A3,n.SVGOverlay=Ae,n.TileLayer=W2,n.Tooltip=q5,n.Transformation=R1,n.Util=e1,n.VideoOverlay=Se,n.bind=u,n.bounds=T1,n.canvas=Y4,n.circle=v2,n.circleMarker=L0,n.control=u4,n.divIcon=V5,n.extend=r,n.featureGroup=J9,n.geoJSON=h1,n.geoJson=c1,n.gridLayer=Ta,n.icon=Ma,n.imageOverlay=V1,n.latLng=d1,n.latLngBounds=F1,n.layerGroup=wn,n.map=it,n.marker=b3,n.point=f1,n.polygon=ka,n.polyline=Aa,n.popup=G5,n.rectangle=ii,n.setOptions=k,n.stamp=d,n.svg=$0,n.svgOverlay=U0,n.tileLayer=Sn,n.tooltip=M3,n.transformation=g1,n.version=i,n.videoOverlay=Ke;var B0=window.L;n.noConflict=function(){return window.L=B0,this},window.L=n})})(dc,dc.exports);var A5=dc.exports;function A9(e,t,n){return Object.freeze({instance:e,context:t,container:n})}function sa(e,t){return t==null?function(i,r){const a=G.useRef();return a.current||(a.current=e(i,r)),a}:function(i,r){const a=G.useRef();a.current||(a.current=e(i,r));const u=G.useRef(i),{instance:f}=a.current;return G.useEffect(function(){u.current!==i&&(t(f,i,u.current),u.current=i)},[f,i,r]),a}}function $E(e,t){G.useEffect(function(){return(t.layerContainer??t.map).addLayer(e.instance),function(){var a;(a=t.layerContainer)==null||a.removeLayer(e.instance),t.map.removeLayer(e.instance)}},[t,e])}function P11(e){return function(n){const i=M9(),r=e(aa(n,i),i);return IE(i.map,n.attribution),Md(r.current,n.eventHandlers),$E(r.current,i),r}}function C11(e,t){const n=G.useRef();G.useEffect(function(){if(t.pathOptions!==n.current){const r=t.pathOptions??{};e.instance.setStyle(r),n.current=r}},[e,t])}function N11(e){return function(n){const i=M9(),r=e(aa(n,i),i);return Md(r.current,n.eventHandlers),$E(r.current,i),C11(r.current,n),r}}function O11(e,t){const n=sa(e),i=T11(n,t);return M11(i)}function BE(e,t){const n=sa(e,t),i=N11(n);return UE(i)}function L11(e,t){const n=sa(e,t),i=P11(n);return A11(i)}function F11(e,t,n){const{opacity:i,zIndex:r}=t;i!=null&&i!==n.opacity&&e.setOpacity(i),r!=null&&r!==n.zIndex&&e.setZIndex(r)}const I11=BE(function({children:t,...n},i){const r=new A5.FeatureGroup([],n);return A9(r,oa(i,{layerContainer:r,overlayContainer:r}))}),R11=sa(function({children:t,...n},i){const r=new A5.Control.Layers(void 0,void 0,n);return A9(r,oa(i,{layersControl:r}))},function(t,n,i){n.collapsed!==i.collapsed&&(n.collapsed===!0?t.collapse():t.expand())}),U11=k11(R11),A6=UE(U11);function zE(e){return function(n){const i=M9(),r=G.useRef(n),[a,u]=G.useState(null),{layersControl:f,map:d}=i,p=G.useCallback(v=>{f!=null&&(r.current.checked&&d.addLayer(v),e(f,v,r.current.name),u(v))},[f,d]),m=G.useCallback(v=>{f==null||f.removeLayer(v),u(null)},[f]),h=G.useMemo(()=>oa(i,{layerContainer:{addLayer:p,removeLayer:m}}),[i,p,m]);return G.useEffect(()=>{a!==null&&r.current!==n&&(n.checked===!0&&(r.current.checked==null||r.current.checked===!1)?d.addLayer(a):r.current.checked===!0&&(n.checked==null||n.checked===!1)&&d.removeLayer(a),r.current=n)}),n.children?N8.createElement(Ed,{value:h},n.children):null}}A6.BaseLayer=zE(function(t,n,i){t.addBaseLayer(n,i)});A6.Overlay=zE(function(t,n,i){t.addOverlay(n,i)});function hc(){return hc=Object.assign||function(e){for(var t=1;t(S==null?void 0:S.map)??null,[S]);const k=G.useCallback(x=>{if(x!==null&&S===null){const w=new A5.Map(x,m);n!=null&&p!=null?w.setView(n,p):e!=null&&w.fitBounds(e,t),d!=null&&w.whenReady(d),E(E11(w))}},[]);G.useEffect(()=>()=>{S==null||S.map.remove()},[S]);const O=S?N8.createElement(Ed,{value:S},i):u??null;return N8.createElement("div",hc({},v,{ref:k}),O)}const jE=G.forwardRef($11),DE=BE(function({positions:t,...n},i){const r=new A5.Polygon(t,n);return A9(r,oa(i,{overlayContainer:r}))},function(t,n,i){n.positions!==i.positions&&t.setLatLngs(n.positions)}),Su=L11(function({url:t,...n},i){const r=new A5.TileLayer(t,aa(n,i));return A9(r,i)},function(t,n,i){F11(t,n,i);const{url:r}=n;r!=null&&r!==i.url&&t.setUrl(r)}),B11=O11(function(t,n){const i=new A5.Tooltip(t,n.overlayContainer);return A9(i,n)},function(t,n,{position:i},r){G.useEffect(function(){const u=n.overlayContainer;if(u==null)return;const{instance:f}=t,d=m=>{m.tooltip===f&&(i!=null&&f.setLatLng(i),f.update(),r(!0))},p=m=>{m.tooltip===f&&r(!1)};return u.on({tooltipopen:d,tooltipclose:p}),u.bindTooltip(f),function(){u.off({tooltipopen:d,tooltipclose:p}),u._map!=null&&u.unbindTooltip()}},[t,n,r,i])}),z11=(e,t)=>[...new Map(t.map(n=>[n[e],n])).values()],j11=e=>!!e;var Ad={exports:{}},QE={exports:{}};(function(e,t){(function(n,i){e.exports=i()})(o2,function(){function n(u,f,d,p,m){i(u,f,d||0,p||u.length-1,m||a)}function i(u,f,d,p,m){for(;p>d;){if(p-d>600){var h=p-d+1,v=f-d+1,S=Math.log(h),E=.5*Math.exp(2*S/3),k=.5*Math.sqrt(S*E*(h-E)/h)*(v-h/2<0?-1:1),O=Math.max(d,Math.floor(f-v*E/h+k)),x=Math.min(p,Math.floor(f+(h-v)*E/h+k));i(u,f,O,x,m)}var w=u[f],b=d,N=p;for(r(u,d,f),m(u[p],w)>0&&r(u,d,p);b0;)N--}m(u[d],w)===0?r(u,d,N):(N++,r(u,N,p)),N<=f&&(d=N+1),f<=N&&(p=N-1)}}function r(u,f,d){var p=u[f];u[f]=u[d],u[d]=p}function a(u,f){return uf?1:0}return n})})(QE);var D11=QE.exports;Ad.exports=c9;Ad.exports.default=c9;var Q11=D11;function c9(e,t){if(!(this instanceof c9))return new c9(e,t);this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4)),t&&this._initFormat(t),this.clear()}c9.prototype={all:function(){return this._all(this.data,[])},search:function(e){var t=this.data,n=[],i=this.toBBox;if(!s8(e,t))return n;for(var r=[],a,u,f,d;t;){for(a=0,u=t.children.length;a=0&&a[t].children.length>this._maxEntries;)this._split(a,t),t--;this._adjustParentBBoxes(r,a,t)},_split:function(e,t){var n=e[t],i=n.children.length,r=this._minEntries;this._chooseSplitAxis(n,r,i);var a=this._chooseSplitIndex(n,r,i),u=c6(n.children.splice(a,n.children.length-a));u.height=n.height,u.leaf=n.leaf,s6(n,this.toBBox),s6(u,this.toBBox),t?e[t-1].children.push(u):this._splitRoot(n,u)},_splitRoot:function(e,t){this.data=c6([e,t]),this.data.height=e.height+1,this.data.leaf=!1,s6(this.data,this.toBBox)},_chooseSplitIndex:function(e,t,n){var i,r,a,u,f,d,p,m;for(d=p=1/0,i=t;i<=n-t;i++)r=y7(e,0,i,this.toBBox),a=y7(e,i,n,this.toBBox),u=Z11(r,a),f=Eu(r)+Eu(a),u=t;d--)p=e.children[d],v7(u,e.leaf?r(p):p),f+=a8(u);return f},_adjustParentBBoxes:function(e,t,n){for(var i=n;i>=0;i--)v7(t[i],e)},_condense:function(e){for(var t=e.length-1,n;t>=0;t--)e[t].children.length===0?t>0?(n=e[t-1].children,n.splice(n.indexOf(e[t]),1)):this.clear():s6(e[t],this.toBBox)},_initFormat:function(e){var t=["return a"," - b",";"];this.compareMinX=new Function("a","b",t.join(e[0])),this.compareMinY=new Function("a","b",t.join(e[1])),this.toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}};function W11(e,t,n){if(!n)return t.indexOf(e);for(var i=0;i=e.minX&&t.maxY>=e.minY}function c6(e){return{children:e,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function qy(e,t,n,i,r){for(var a=[t,n],u;a.length;)n=a.pop(),t=a.pop(),!(n-t<=i)&&(u=t+Math.ceil((n-t)/i/2)*i,Q11(e,u,t,n,r),a.push(t,u,u,n))}var G11=Ad.exports,q11=Nr;Nr.polyline=Nr;Nr.polygon=V11;function Nr(e,t,n){var i=e.length,r=k6(e[0],t),a=[],u,f,d,p,m;for(n||(n=[]),u=1;ut[2]&&(n|=2),e[1]t[3]&&(n|=8),n}var Y11=G11,X11=q11,K11=J11;function J11(e){for(var t=[],n=0;n0)return!0;return!1}function WE(e,t){for(var n=!1,i=0,r=e.length;ie[1]!=n[1]>e[1]&&e[0]<(n[0]-t[0])*(e[1]-t[1])/(n[1]-t[1])+t[0]}function Vy(e,t){for(var n={minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0,coords:e,props:t},i=0;iTt[w].properties.id),k(x);for(const x of e.features)m(x),h(x),v(x),S(x),p(x);for(const x of e.features)x.properties.groups.sort((w,b)=>u6.indexOf(Tt[w].properties.level)-u6.indexOf(Tt[b].properties.level)),x.properties.members&&x.properties.members.sort((w,b)=>{const N=u6.indexOf(Tt[w].properties.level)-u6.indexOf(Tt[b].properties.level);return N===0?e.features.indexOf(Tt[w])-e.features.indexOf(Tt[b]):N});ne1({type:"FeatureCollection",features:n});function r(x){const w=x.properties;w.groups||(w.groups=[]),x.geometry&&w.country&&w.groups.push(w.country),w.m49!=="001"&&w.groups.push("001")}function a(x){const w=x.properties;!w.m49&&w.iso1N3&&(w.m49=w.iso1N3)}function u(x){const w=x.properties;w.level!=="unitedNations"&&!w.ccTLD&&w.iso1A2&&(w.ccTLD="."+w.iso1A2.toLowerCase())}function f(x){const w=x.properties;!w.isoStatus&&w.iso1A2&&(w.isoStatus="official")}function d(x){const w=x.properties;w.level||(w.country?!w.iso1A2||w.isoStatus==="official"?w.level="territory":w.level="subterritory":w.level="country")}function p(x){const w=x.properties;if(x.geometry||!w.members)return;const b=u6.indexOf(w.level);let N=[];w.members.forEach(($,I)=>{const B=Tt[$].properties.groups.filter(Y=>Y!==x.properties.id&&bB.indexOf(Y)!==-1)}),w.groups=w.groups.concat(N.filter($=>w.groups.indexOf($)===-1));for(const $ of N){const I=Tt[$];I.properties.members.indexOf(w.id)===-1&&I.properties.members.push(w.id)}}function m(x){const w=x.properties;if(x.geometry)w.roadSpeedUnit||(w.roadSpeedUnit="km/h");else if(w.members){const b=Array.from(new Set(w.members.map(N=>{const $=Tt[N];if($.geometry)return $.properties.roadSpeedUnit||"km/h"}).filter(Boolean)));b.length===1&&(w.roadSpeedUnit=b[0])}}function h(x){const w=x.properties;if(x.geometry)w.roadHeightUnit||(w.roadHeightUnit="m");else if(w.members){const b=Array.from(new Set(w.members.map(N=>{const $=Tt[N];if($.geometry)return $.properties.roadHeightUnit||"m"}).filter(Boolean)));b.length===1&&(w.roadHeightUnit=b[0])}}function v(x){const w=x.properties;if(x.geometry)w.driveSide||(w.driveSide="right");else if(w.members){const b=Array.from(new Set(w.members.map(N=>{const $=Tt[N];if($.geometry)return $.properties.driveSide||"right"}).filter(Boolean)));b.length===1&&(w.driveSide=b[0])}}function S(x){const w=x.properties;!x.geometry&&w.members&&(w.callingCodes=Array.from(new Set(w.members.reduce((b,N)=>{const $=Tt[N];return $.geometry&&$.properties.callingCodes?b.concat($.properties.callingCodes):b},[]))))}function E(x){if(!x.properties.iso1A2)return;const w=x.properties.iso1A2.replace(/./g,function(b){return String.fromCodePoint(b.charCodeAt(0)+127397)});x.properties.emojiFlag=w}function k(x){for(const w of x.properties.groups){const b=Tt[w];b.properties.members||(b.properties.members=[]),b.properties.members.push(x.properties.id)}}function O(x){let w=[];for(const b of t){const N=x.properties[b];N&&w.push(N)}for(const b of x.properties.aliases||[])w.push(b);for(const b of w){const N=ae1(b);Tt[N]=x}}}const HE=()=>R.jsxs(A6,{position:"topright",children:[R.jsx(A6.BaseLayer,{checked:!0,name:"OpenStreetMap",children:R.jsx(Su,{attribution:'© OpenStreetMap contributors',url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"})}),R.jsx(A6.BaseLayer,{name:"LINZ Aerial Imagery",children:R.jsx(Su,{attribution:'Sourced from LINZ CC-BY 4.0',url:"https://basemaps.linz.govt.nz/v1/tiles/aerial/EPSG:3857/{z}/{x}/{y}.jpg?api=d01egend5f8dv4zcbfj6z2t7rs3"})}),R.jsx(A6.BaseLayer,{name:"LINZ Topo50",children:R.jsx(Su,{attribution:'Sourced from LINZ CC-BY 4.0',url:"https://map.cazzaserver.com/linz_topo/{z}/{x}/{y}.png"})})]});class ue1 extends G.Component{static getDerivedStateFromError(t){return{error:t}}render(){var t;return(t=this.state)!=null&&t.error?R.jsx("div",{style:{margin:32},children:"Map preview unavailable. This layer probably uses complex geometry."}):this.props.children}}const Yy="https://linz-addr-cdn.kyle.kiwi",Xy=!!window.opener;function le1(e,t){if(t){const[n,i]=t,r=`Check back in a day. - -If you continue, you might override or duplicate their work!`,a=i==="done"?`This dataset may already have been uploaded by someone else! ${r}`:`Someone else (${n}) started editing this dataset ${i} minutes ago. ${r}`;if(!confirm(a))return}window.opener.postMessage(`ADD_SECTOR=${e}`),window.close()}function ZE(e){return e>1e3?"#3a0000":e>500?"#67001f":e>200?"#980043":e>100?"#ce1256":e>60?"#e7298a":e>40?"#df65b0":e>20?"#c994c7":"#d4b9da"}function ce1(e,t){return{color:t?"#aaaaaa":ZE(e.totalCount),fillOpacity:.3,opacity:1,stroke:!0,weight:2}}let Ky="orange";function Jy(e,t){t?(Ky=e.target.options.color,e.target.setStyle({color:"yellow"})):e.target.setStyle({color:Ky})}function fe1([[e,t],[n,i]]){return[[i,e],[i,n],[t,n],[t,e]]}const ev={Expires:"Tue, 01 Jan 1980 1:00:00 GMT","Cache-Control":"no-cache, no-store, max-age=0",Pragma:"no-cache"},de1=()=>{const[e,t]=G.useState(!1),[n,i]=G.useState(),[r,a]=G.useState(),[u,f]=G.useState(),[d,p]=G.useState([]);if(G.useEffect(()=>{Promise.all([fetch(`${Yy}/index.json?nocache=${Math.random()}`,{headers:ev}).then(v=>v.json()),fetch(`${Yy}/__locked?nocache=${Math.random()}`,{headers:ev}).then(v=>v.json()).catch(()=>({}))]).then(f).catch(a)},[]),r)return R.jsx(R.Fragment,{children:"Error"});if(!u)return R.jsx(R.Fragment,{children:"Loading..."});const m=z11("name",u[0].results.map(v=>({name:v.name.split(" - ").slice(0,-1).join(" - "),isPreview:v.groupCategories[0]==="/Categories/Preview"})).filter(v=>e||!v.isPreview)),h=v=>u[1][v.id]?`Someone else ${u[1][v.id][1]==="done"?"may have already uploaded":"is working on"} this dataset! Check back in one day.`:"";return R.jsxs(R.Fragment,{children:[R.jsxs("div",{style:{height:200},children:[Xy&&R.jsxs("div",{style:{textAlign:"center"},children:[R.jsx("h3",{style:{margin:0},children:"Please select a suburb to edit"}),"You can close this page and use the list if you prefer"]}),R.jsx("input",{type:"checkbox",checked:e,onChange:v=>t(v.target.checked)}),"Show Preview Layers",R.jsx("br",{}),R.jsx("br",{}),R.jsx("div",{style:{display:"flex",flexWrap:"wrap"},children:m.map(v=>R.jsx("button",{type:"button",className:[n===v.name?"active-layer":"inactive-layer",v.isPreview?"preview-layer":""].join(" "),onClick:()=>i(v.name),children:v.name},v.name))})]}),R.jsx(ue1,{children:R.jsxs(jE,{style:{width:"100vw",height:"calc(100vh - 200px)"},center:[-40.98,166.9],zoom:6,scrollWheelZoom:!0,children:[R.jsx(HE,{}),n&&u[0].results.filter(v=>v.name.startsWith(n)).filter(v=>!d.includes(v.id)).map(v=>R.jsx(DE,{pathOptions:ce1(v,u[1][v.id]),positions:fe1(v.extent),eventHandlers:{click:()=>{Xy&&le1(v.id,u[1][v.id])},contextmenu:()=>p(S=>[...S,v.id]),mouseover:S=>Jy(S,!0),mouseout:S=>Jy(S,!1)},children:R.jsxs(B11,{direction:"bottom",sticky:!0,children:[R.jsx("strong",{children:v.name}),R.jsx("br",{}),v.snippet,R.jsx("br",{}),h(v)]})},v.id)),R.jsxs("div",{className:"legend leaflet-bottom leaflet-left",style:{margin:20},children:[R.jsx("strong",{children:"# of changes"}),R.jsx("br",{}),[0,20,40,60,100,200,500,1e3].map((v,S,E)=>R.jsxs(G.Fragment,{children:[R.jsx("i",{style:{background:ZE(E[S]+1)}}),E[S],E[S+1]?R.jsxs(R.Fragment,{children:["–",E[S+1],R.jsx("br",{})]}):"+"]},v))]})]})},n)]})};function u8(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var GE={exports:{}};(function(e,t){(function(n){e.exports=n()})(function(){return function(){function n(i,r,a){function u(p,m){if(!r[p]){if(!i[p]){var h=typeof u8=="function"&&u8;if(!m&&h)return h(p,!0);if(f)return f(p,!0);var v=new Error("Cannot find module '"+p+"'");throw v.code="MODULE_NOT_FOUND",v}var S=r[p]={exports:{}};i[p][0].call(S.exports,function(E){var k=i[p][1][E];return u(k||E)},S,S.exports,n,i,r,a)}return r[p].exports}for(var f=typeof u8=="function"&&u8,d=0;d0)throw new Error("Invalid string. Length must be a multiple of 4");var N=w.indexOf("=");N===-1&&(N=b);var $=N===b?0:4-N%4;return[N,$]}function v(w){var b=h(w),N=b[0],$=b[1];return(N+$)*3/4-$}function S(w,b,N){return(b+N)*3/4-N}function E(w){var b,N=h(w),$=N[0],I=N[1],j=new f(S(w,$,I)),B=0,Y=I>0?$-4:$,H;for(H=0;H>16&255,j[B++]=b>>8&255,j[B++]=b&255;return I===2&&(b=u[w.charCodeAt(H)]<<2|u[w.charCodeAt(H+1)]>>4,j[B++]=b&255),I===1&&(b=u[w.charCodeAt(H)]<<10|u[w.charCodeAt(H+1)]<<4|u[w.charCodeAt(H+2)]>>2,j[B++]=b>>8&255,j[B++]=b&255),j}function k(w){return a[w>>18&63]+a[w>>12&63]+a[w>>6&63]+a[w&63]}function O(w,b,N){for(var $,I=[],j=b;jY?Y:B+j));return $===1?(b=w[N-1],I.push(a[b>>2]+a[b<<4&63]+"==")):$===2&&(b=(w[N-2]<<8)+w[N-1],I.push(a[b>>10]+a[b>>4&63]+a[b<<2&63]+"=")),I.join("")}},{}],2:[function(n,i,r){(function(a){(function(){var u=n("base64-js"),f=n("ieee754");r.Buffer=h,r.SlowBuffer=$,r.INSPECT_MAX_BYTES=50;var d=2147483647;r.kMaxLength=d,h.TYPED_ARRAY_SUPPORT=p(),!h.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function p(){try{var W=new Uint8Array(1);return W.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},W.foo()===42}catch{return!1}}Object.defineProperty(h.prototype,"parent",{enumerable:!0,get:function(){if(h.isBuffer(this))return this.buffer}}),Object.defineProperty(h.prototype,"offset",{enumerable:!0,get:function(){if(h.isBuffer(this))return this.byteOffset}});function m(W){if(W>d)throw new RangeError('The value "'+W+'" is invalid for option "size"');var T=new Uint8Array(W);return T.__proto__=h.prototype,T}function h(W,T,P){if(typeof W=="number"){if(typeof T=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return k(W)}return v(W,T,P)}typeof Symbol<"u"&&Symbol.species!=null&&h[Symbol.species]===h&&Object.defineProperty(h,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),h.poolSize=8192;function v(W,T,P){if(typeof W=="string")return O(W,T);if(ArrayBuffer.isView(W))return x(W);if(W==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof W);if(ge(W,ArrayBuffer)||W&&ge(W.buffer,ArrayBuffer))return w(W,T,P);if(typeof W=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var Z=W.valueOf&&W.valueOf();if(Z!=null&&Z!==W)return h.from(Z,T,P);var s1=b(W);if(s1)return s1;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof W[Symbol.toPrimitive]=="function")return h.from(W[Symbol.toPrimitive]("string"),T,P);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof W)}h.from=function(W,T,P){return v(W,T,P)},h.prototype.__proto__=Uint8Array.prototype,h.__proto__=Uint8Array;function S(W){if(typeof W!="number")throw new TypeError('"size" argument must be of type number');if(W<0)throw new RangeError('The value "'+W+'" is invalid for option "size"')}function E(W,T,P){return S(W),W<=0?m(W):T!==void 0?typeof P=="string"?m(W).fill(T,P):m(W).fill(T):m(W)}h.alloc=function(W,T,P){return E(W,T,P)};function k(W){return S(W),m(W<0?0:N(W)|0)}h.allocUnsafe=function(W){return k(W)},h.allocUnsafeSlow=function(W){return k(W)};function O(W,T){if((typeof T!="string"||T==="")&&(T="utf8"),!h.isEncoding(T))throw new TypeError("Unknown encoding: "+T);var P=I(W,T)|0,Z=m(P),s1=Z.write(W,T);return s1!==P&&(Z=Z.slice(0,s1)),Z}function x(W){for(var T=W.length<0?0:N(W.length)|0,P=m(T),Z=0;Z=d)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+d.toString(16)+" bytes");return W|0}function $(W){return+W!=W&&(W=0),h.alloc(+W)}h.isBuffer=function(T){return T!=null&&T._isBuffer===!0&&T!==h.prototype},h.compare=function(T,P){if(ge(T,Uint8Array)&&(T=h.from(T,T.offset,T.byteLength)),ge(P,Uint8Array)&&(P=h.from(P,P.offset,P.byteLength)),!h.isBuffer(T)||!h.isBuffer(P))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(T===P)return 0;for(var Z=T.length,s1=P.length,v1=0,b1=Math.min(Z,s1);v12&&arguments[2]===!0;if(!Z&&P===0)return 0;for(var s1=!1;;)switch(T){case"ascii":case"latin1":case"binary":return P;case"utf8":case"utf-8":return J1(W).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P*2;case"hex":return P>>>1;case"base64":return we(W).length;default:if(s1)return Z?-1:J1(W).length;T=(""+T).toLowerCase(),s1=!0}}h.byteLength=I;function j(W,T,P){var Z=!1;if((T===void 0||T<0)&&(T=0),T>this.length||((P===void 0||P>this.length)&&(P=this.length),P<=0)||(P>>>=0,T>>>=0,P<=T))return"";for(W||(W="utf8");;)switch(W){case"hex":return j1(this,T,P);case"utf8":case"utf-8":return V(this,T,P);case"ascii":return w1(this,T,P);case"latin1":case"binary":return T1(this,T,P);case"base64":return r1(this,T,P);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F1(this,T,P);default:if(Z)throw new TypeError("Unknown encoding: "+W);W=(W+"").toLowerCase(),Z=!0}}h.prototype._isBuffer=!0;function B(W,T,P){var Z=W[T];W[T]=W[P],W[P]=Z}h.prototype.swap16=function(){var T=this.length;if(T%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var P=0;PP&&(T+=" ... "),""},h.prototype.compare=function(T,P,Z,s1,v1){if(ge(T,Uint8Array)&&(T=h.from(T,T.offset,T.byteLength)),!h.isBuffer(T))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof T);if(P===void 0&&(P=0),Z===void 0&&(Z=T?T.length:0),s1===void 0&&(s1=0),v1===void 0&&(v1=this.length),P<0||Z>T.length||s1<0||v1>this.length)throw new RangeError("out of range index");if(s1>=v1&&P>=Z)return 0;if(s1>=v1)return-1;if(P>=Z)return 1;if(P>>>=0,Z>>>=0,s1>>>=0,v1>>>=0,this===T)return 0;for(var b1=v1-s1,G1=Z-P,X1=Math.min(b1,G1),k1=this.slice(s1,v1),q1=T.slice(P,Z),fe=0;fe2147483647?P=2147483647:P<-2147483648&&(P=-2147483648),P=+P,Qe(P)&&(P=s1?0:W.length-1),P<0&&(P=W.length+P),P>=W.length){if(s1)return-1;P=W.length-1}else if(P<0)if(s1)P=0;else return-1;if(typeof T=="string"&&(T=h.from(T,Z)),h.isBuffer(T))return T.length===0?-1:H(W,T,P,Z,s1);if(typeof T=="number")return T=T&255,typeof Uint8Array.prototype.indexOf=="function"?s1?Uint8Array.prototype.indexOf.call(W,T,P):Uint8Array.prototype.lastIndexOf.call(W,T,P):H(W,[T],P,Z,s1);throw new TypeError("val must be string, number or Buffer")}function H(W,T,P,Z,s1){var v1=1,b1=W.length,G1=T.length;if(Z!==void 0&&(Z=String(Z).toLowerCase(),Z==="ucs2"||Z==="ucs-2"||Z==="utf16le"||Z==="utf-16le")){if(W.length<2||T.length<2)return-1;v1=2,b1/=2,G1/=2,P/=2}function X1(gt,x4){return v1===1?gt[x4]:gt.readUInt16BE(x4*v1)}var k1;if(s1){var q1=-1;for(k1=P;k1b1&&(P=b1-G1),k1=P;k1>=0;k1--){for(var fe=!0,de=0;des1&&(Z=s1)):Z=s1;var v1=T.length;Z>v1/2&&(Z=v1/2);for(var b1=0;b1>>0,isFinite(Z)?(Z=Z>>>0,s1===void 0&&(s1="utf8")):(s1=Z,Z=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var v1=this.length-P;if((Z===void 0||Z>v1)&&(Z=v1),T.length>0&&(Z<0||P<0)||P>this.length)throw new RangeError("Attempt to write outside buffer bounds");s1||(s1="utf8");for(var b1=!1;;)switch(s1){case"hex":return D(this,T,P,Z);case"utf8":case"utf-8":return J(this,T,P,Z);case"ascii":return e1(this,T,P,Z);case"latin1":case"binary":return o1(this,T,P,Z);case"base64":return i1(this,T,P,Z);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return l1(this,T,P,Z);default:if(b1)throw new TypeError("Unknown encoding: "+s1);s1=(""+s1).toLowerCase(),b1=!0}},h.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function r1(W,T,P){return T===0&&P===W.length?u.fromByteArray(W):u.fromByteArray(W.slice(T,P))}function V(W,T,P){P=Math.min(W.length,P);for(var Z=[],s1=T;s1239?4:v1>223?3:v1>191?2:1;if(s1+G1<=P){var X1,k1,q1,fe;switch(G1){case 1:v1<128&&(b1=v1);break;case 2:X1=W[s1+1],(X1&192)===128&&(fe=(v1&31)<<6|X1&63,fe>127&&(b1=fe));break;case 3:X1=W[s1+1],k1=W[s1+2],(X1&192)===128&&(k1&192)===128&&(fe=(v1&15)<<12|(X1&63)<<6|k1&63,fe>2047&&(fe<55296||fe>57343)&&(b1=fe));break;case 4:X1=W[s1+1],k1=W[s1+2],q1=W[s1+3],(X1&192)===128&&(k1&192)===128&&(q1&192)===128&&(fe=(v1&15)<<18|(X1&63)<<12|(k1&63)<<6|q1&63,fe>65535&&fe<1114112&&(b1=fe))}}b1===null?(b1=65533,G1=1):b1>65535&&(b1-=65536,Z.push(b1>>>10&1023|55296),b1=56320|b1&1023),Z.push(b1),s1+=G1}return f1(Z)}var p1=4096;function f1(W){var T=W.length;if(T<=p1)return String.fromCharCode.apply(String,W);for(var P="",Z=0;ZZ)&&(P=Z);for(var s1="",v1=T;v1Z&&(T=Z),P<0?(P+=Z,P<0&&(P=0)):P>Z&&(P=Z),PP)throw new RangeError("Trying to access beyond buffer length")}h.prototype.readUIntLE=function(T,P,Z){T=T>>>0,P=P>>>0,Z||_1(T,P,this.length);for(var s1=this[T],v1=1,b1=0;++b1>>0,P=P>>>0,Z||_1(T,P,this.length);for(var s1=this[T+--P],v1=1;P>0&&(v1*=256);)s1+=this[T+--P]*v1;return s1},h.prototype.readUInt8=function(T,P){return T=T>>>0,P||_1(T,1,this.length),this[T]},h.prototype.readUInt16LE=function(T,P){return T=T>>>0,P||_1(T,2,this.length),this[T]|this[T+1]<<8},h.prototype.readUInt16BE=function(T,P){return T=T>>>0,P||_1(T,2,this.length),this[T]<<8|this[T+1]},h.prototype.readUInt32LE=function(T,P){return T=T>>>0,P||_1(T,4,this.length),(this[T]|this[T+1]<<8|this[T+2]<<16)+this[T+3]*16777216},h.prototype.readUInt32BE=function(T,P){return T=T>>>0,P||_1(T,4,this.length),this[T]*16777216+(this[T+1]<<16|this[T+2]<<8|this[T+3])},h.prototype.readIntLE=function(T,P,Z){T=T>>>0,P=P>>>0,Z||_1(T,P,this.length);for(var s1=this[T],v1=1,b1=0;++b1=v1&&(s1-=Math.pow(2,8*P)),s1},h.prototype.readIntBE=function(T,P,Z){T=T>>>0,P=P>>>0,Z||_1(T,P,this.length);for(var s1=P,v1=1,b1=this[T+--s1];s1>0&&(v1*=256);)b1+=this[T+--s1]*v1;return v1*=128,b1>=v1&&(b1-=Math.pow(2,8*P)),b1},h.prototype.readInt8=function(T,P){return T=T>>>0,P||_1(T,1,this.length),this[T]&128?(255-this[T]+1)*-1:this[T]},h.prototype.readInt16LE=function(T,P){T=T>>>0,P||_1(T,2,this.length);var Z=this[T]|this[T+1]<<8;return Z&32768?Z|4294901760:Z},h.prototype.readInt16BE=function(T,P){T=T>>>0,P||_1(T,2,this.length);var Z=this[T+1]|this[T]<<8;return Z&32768?Z|4294901760:Z},h.prototype.readInt32LE=function(T,P){return T=T>>>0,P||_1(T,4,this.length),this[T]|this[T+1]<<8|this[T+2]<<16|this[T+3]<<24},h.prototype.readInt32BE=function(T,P){return T=T>>>0,P||_1(T,4,this.length),this[T]<<24|this[T+1]<<16|this[T+2]<<8|this[T+3]},h.prototype.readFloatLE=function(T,P){return T=T>>>0,P||_1(T,4,this.length),f.read(this,T,!0,23,4)},h.prototype.readFloatBE=function(T,P){return T=T>>>0,P||_1(T,4,this.length),f.read(this,T,!1,23,4)},h.prototype.readDoubleLE=function(T,P){return T=T>>>0,P||_1(T,8,this.length),f.read(this,T,!0,52,8)},h.prototype.readDoubleBE=function(T,P){return T=T>>>0,P||_1(T,8,this.length),f.read(this,T,!1,52,8)};function d1(W,T,P,Z,s1,v1){if(!h.isBuffer(W))throw new TypeError('"buffer" argument must be a Buffer instance');if(T>s1||TW.length)throw new RangeError("Index out of range")}h.prototype.writeUIntLE=function(T,P,Z,s1){if(T=+T,P=P>>>0,Z=Z>>>0,!s1){var v1=Math.pow(2,8*Z)-1;d1(this,T,P,Z,v1,0)}var b1=1,G1=0;for(this[P]=T&255;++G1>>0,Z=Z>>>0,!s1){var v1=Math.pow(2,8*Z)-1;d1(this,T,P,Z,v1,0)}var b1=Z-1,G1=1;for(this[P+b1]=T&255;--b1>=0&&(G1*=256);)this[P+b1]=T/G1&255;return P+Z},h.prototype.writeUInt8=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,1,255,0),this[P]=T&255,P+1},h.prototype.writeUInt16LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,65535,0),this[P]=T&255,this[P+1]=T>>>8,P+2},h.prototype.writeUInt16BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,65535,0),this[P]=T>>>8,this[P+1]=T&255,P+2},h.prototype.writeUInt32LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,4294967295,0),this[P+3]=T>>>24,this[P+2]=T>>>16,this[P+1]=T>>>8,this[P]=T&255,P+4},h.prototype.writeUInt32BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,4294967295,0),this[P]=T>>>24,this[P+1]=T>>>16,this[P+2]=T>>>8,this[P+3]=T&255,P+4},h.prototype.writeIntLE=function(T,P,Z,s1){if(T=+T,P=P>>>0,!s1){var v1=Math.pow(2,8*Z-1);d1(this,T,P,Z,v1-1,-v1)}var b1=0,G1=1,X1=0;for(this[P]=T&255;++b1>0)-X1&255;return P+Z},h.prototype.writeIntBE=function(T,P,Z,s1){if(T=+T,P=P>>>0,!s1){var v1=Math.pow(2,8*Z-1);d1(this,T,P,Z,v1-1,-v1)}var b1=Z-1,G1=1,X1=0;for(this[P+b1]=T&255;--b1>=0&&(G1*=256);)T<0&&X1===0&&this[P+b1+1]!==0&&(X1=1),this[P+b1]=(T/G1>>0)-X1&255;return P+Z},h.prototype.writeInt8=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,1,127,-128),T<0&&(T=255+T+1),this[P]=T&255,P+1},h.prototype.writeInt16LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,32767,-32768),this[P]=T&255,this[P+1]=T>>>8,P+2},h.prototype.writeInt16BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,2,32767,-32768),this[P]=T>>>8,this[P+1]=T&255,P+2},h.prototype.writeInt32LE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,2147483647,-2147483648),this[P]=T&255,this[P+1]=T>>>8,this[P+2]=T>>>16,this[P+3]=T>>>24,P+4},h.prototype.writeInt32BE=function(T,P,Z){return T=+T,P=P>>>0,Z||d1(this,T,P,4,2147483647,-2147483648),T<0&&(T=4294967295+T+1),this[P]=T>>>24,this[P+1]=T>>>16,this[P+2]=T>>>8,this[P+3]=T&255,P+4};function I1(W,T,P,Z,s1,v1){if(P+Z>W.length)throw new RangeError("Index out of range");if(P<0)throw new RangeError("Index out of range")}function W1(W,T,P,Z,s1){return T=+T,P=P>>>0,s1||I1(W,T,P,4),f.write(W,T,P,Z,23,4),P+4}h.prototype.writeFloatLE=function(T,P,Z){return W1(this,T,P,!0,Z)},h.prototype.writeFloatBE=function(T,P,Z){return W1(this,T,P,!1,Z)};function E1(W,T,P,Z,s1){return T=+T,P=P>>>0,s1||I1(W,T,P,8),f.write(W,T,P,Z,52,8),P+8}h.prototype.writeDoubleLE=function(T,P,Z){return E1(this,T,P,!0,Z)},h.prototype.writeDoubleBE=function(T,P,Z){return E1(this,T,P,!1,Z)},h.prototype.copy=function(T,P,Z,s1){if(!h.isBuffer(T))throw new TypeError("argument should be a Buffer");if(Z||(Z=0),!s1&&s1!==0&&(s1=this.length),P>=T.length&&(P=T.length),P||(P=0),s1>0&&s1=this.length)throw new RangeError("Index out of range");if(s1<0)throw new RangeError("sourceEnd out of bounds");s1>this.length&&(s1=this.length),T.length-P=0;--b1)T[b1+P]=this[b1+Z];else Uint8Array.prototype.set.call(T,this.subarray(Z,s1),P);return v1},h.prototype.fill=function(T,P,Z,s1){if(typeof T=="string"){if(typeof P=="string"?(s1=P,P=0,Z=this.length):typeof Z=="string"&&(s1=Z,Z=this.length),s1!==void 0&&typeof s1!="string")throw new TypeError("encoding must be a string");if(typeof s1=="string"&&!h.isEncoding(s1))throw new TypeError("Unknown encoding: "+s1);if(T.length===1){var v1=T.charCodeAt(0);(s1==="utf8"&&v1<128||s1==="latin1")&&(T=v1)}}else typeof T=="number"&&(T=T&255);if(P<0||this.length>>0,Z=Z===void 0?this.length:Z>>>0,T||(T=0);var b1;if(typeof T=="number")for(b1=P;b155295&&P<57344){if(!s1){if(P>56319){(T-=3)>-1&&v1.push(239,191,189);continue}else if(b1+1===Z){(T-=3)>-1&&v1.push(239,191,189);continue}s1=P;continue}if(P<56320){(T-=3)>-1&&v1.push(239,191,189),s1=P;continue}P=(s1-55296<<10|P-56320)+65536}else s1&&(T-=3)>-1&&v1.push(239,191,189);if(s1=null,P<128){if((T-=1)<0)break;v1.push(P)}else if(P<2048){if((T-=2)<0)break;v1.push(P>>6|192,P&63|128)}else if(P<65536){if((T-=3)<0)break;v1.push(P>>12|224,P>>6&63|128,P&63|128)}else if(P<1114112){if((T-=4)<0)break;v1.push(P>>18|240,P>>12&63|128,P>>6&63|128,P&63|128)}else throw new Error("Invalid code point")}return v1}function D1(W){for(var T=[],P=0;P>8,s1=P%256,v1.push(s1),v1.push(Z);return v1}function we(W){return u.toByteArray(R1(W))}function pe(W,T,P,Z){for(var s1=0;s1=T.length||s1>=W.length);++s1)T[s1+P]=W[s1];return s1}function ge(W,T){return W instanceof T||W!=null&&W.constructor!=null&&W.constructor.name!=null&&W.constructor.name===T.name}function Qe(W){return W!==W}}).call(this)}).call(this,n("buffer").Buffer)},{"base64-js":1,buffer:2,ieee754:14}],3:[function(n,i,r){const a=n("./validator"),u=n("./xmlparser/XMLParser"),f=n("./xmlbuilder/json2xml");i.exports={XMLParser:u,XMLValidator:a,XMLBuilder:f}},{"./validator":5,"./xmlbuilder/json2xml":6,"./xmlparser/XMLParser":11}],4:[function(n,i,r){const a=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",u=a+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",f="["+a+"]["+u+"]*",d=new RegExp("^"+f+"$"),p=function(h,v){const S=[];let E=v.exec(h);for(;E;){const k=[];k.startIndex=v.lastIndex-E[0].length;const O=E.length;for(let x=0;x"u")};r.isExist=function(h){return typeof h<"u"},r.isEmptyObject=function(h){return Object.keys(h).length===0},r.merge=function(h,v,S){if(v){const E=Object.keys(v),k=E.length;for(let O=0;O"&&I[D]!==" "&&I[D]!==" "&&I[D]!==` -`&&I[D]!=="\r";D++)o1+=I[D];if(o1=o1.trim(),o1[o1.length-1]==="/"&&(o1=o1.substring(0,o1.length-1),D--),!b(o1)){let r1;return o1.trim().length===0?r1="Invalid space after '<'.":r1="Tag '"+o1+"' is an invalid name.",x("InvalidTag",r1,N(I,D))}const i1=v(I,D);if(i1===!1)return x("InvalidAttr","Attributes for '"+o1+"' have open quote.",N(I,D));let l1=i1.value;if(D=i1.index,l1[l1.length-1]==="/"){const r1=D-l1.length;l1=l1.substring(0,l1.length-1);const V=E(l1,j);if(V===!0)Y=!0;else return x(V.err.code,V.err.msg,N(I,r1+V.err.line))}else if(e1)if(i1.tagClosed){if(l1.trim().length>0)return x("InvalidTag","Closing tag '"+o1+"' can't have attributes or invalid starting.",N(I,J));{const r1=B.pop();if(o1!==r1.tagName){let V=N(I,r1.tagStartPos);return x("InvalidTag","Expected closing tag '"+r1.tagName+"' (opened in line "+V.line+", col "+V.col+") instead of closing tag '"+o1+"'.",N(I,J))}B.length==0&&(H=!0)}}else return x("InvalidTag","Closing tag '"+o1+"' doesn't have proper closing.",N(I,D));else{const r1=E(l1,j);if(r1!==!0)return x(r1.err.code,r1.err.msg,N(I,D-l1.length+r1.err.line));if(H===!0)return x("InvalidXml","Multiple possible root nodes found.",N(I,D));j.unpairedTags.indexOf(o1)!==-1||B.push({tagName:o1,tagStartPos:J}),Y=!0}for(D++;D0)return x("InvalidXml","Invalid '"+JSON.stringify(B.map(D=>D.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return x("InvalidXml","Start tag expected.",1);return!0};function f(I){return I===" "||I===" "||I===` -`||I==="\r"}function d(I,j){const B=j;for(;j5&&Y==="xml")return x("InvalidXml","XML declaration allowed only at the start of the document.",N(I,j));if(I[j]=="?"&&I[j+1]==">"){j++;break}else continue}return j}function p(I,j){if(I.length>j+5&&I[j+1]==="-"&&I[j+2]==="-"){for(j+=3;j"){j+=2;break}}else if(I.length>j+8&&I[j+1]==="D"&&I[j+2]==="O"&&I[j+3]==="C"&&I[j+4]==="T"&&I[j+5]==="Y"&&I[j+6]==="P"&&I[j+7]==="E"){let B=1;for(j+=8;j"&&(B--,B===0))break}else if(I.length>j+9&&I[j+1]==="["&&I[j+2]==="C"&&I[j+3]==="D"&&I[j+4]==="A"&&I[j+5]==="T"&&I[j+6]==="A"&&I[j+7]==="["){for(j+=8;j"){j+=2;break}}return j}const m='"',h="'";function v(I,j){let B="",Y="",H=!1;for(;j"&&Y===""){H=!0;break}B+=I[j]}return Y!==""?!1:{value:B,index:j,tagClosed:H}}const S=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function E(I,j){const B=a.getAllMatches(I,S),Y={};for(let H=0;H","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[]};function f(x){this.options=Object.assign({},u,x),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=O),this.processTextOrObjNode=p,this.options.format?(this.indentate=k,this.tagEndChar=`> -`,this.newLine=` -`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine=""),this.options.suppressEmptyNode?(this.buildTextNode=E,this.buildObjNode=h):(this.buildTextNode=v,this.buildObjNode=m),this.buildTextValNode=v,this.buildObjectNode=m,this.replaceEntitiesValue=S,this.buildAttrPairStr=d}f.prototype.build=function(x){return this.options.preserveOrder?a(x,this.options):(Array.isArray(x)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(x={[this.options.arrayNodeName]:x}),this.j2x(x,0).val)},f.prototype.j2x=function(x,w){let b="",N="";for(let $ in x)if(!(typeof x[$]>"u"))if(x[$]===null)$[0]==="?"?N+=this.indentate(w)+"<"+$+"?"+this.tagEndChar:N+=this.indentate(w)+"<"+$+"/"+this.tagEndChar;else if(x[$]instanceof Date)N+=this.buildTextNode(x[$],$,"",w);else if(typeof x[$]!="object"){const I=this.isAttribute($);if(I)b+=this.buildAttrPairStr(I,""+x[$]);else if($===this.options.textNodeName){let j=this.options.tagValueProcessor($,""+x[$]);N+=this.replaceEntitiesValue(j)}else N+=this.buildTextNode(x[$],$,"",w)}else if(Array.isArray(x[$])){const I=x[$].length;for(let j=0;j"u"||(B===null?$[0]==="?"?N+=this.indentate(w)+"<"+$+"?"+this.tagEndChar:N+=this.indentate(w)+"<"+$+"/"+this.tagEndChar:typeof B=="object"?N+=this.processTextOrObjNode(B,$,w):N+=this.buildTextNode(B,$,"",w))}}else if(this.options.attributesGroupName&&$===this.options.attributesGroupName){const I=Object.keys(x[$]),j=I.length;for(let B=0;B"+x+$:this.options.commentPropName!==!1&&w===this.options.commentPropName&&I.length===0?this.indentate(N)+``+this.newLine:this.indentate(N)+"<"+w+b+I+this.tagEndChar+x+this.indentate(N)+$}function h(x,w,b,N){return x!==""?this.buildObjectNode(x,w,b,N):w[0]==="?"?this.indentate(N)+"<"+w+b+"?"+this.tagEndChar:this.indentate(N)+"<"+w+b+"/"+this.tagEndChar}function v(x,w,b,N){if(this.options.cdataPropName!==!1&&w===this.options.cdataPropName)return this.indentate(N)+``+this.newLine;if(this.options.commentPropName!==!1&&w===this.options.commentPropName)return this.indentate(N)+``+this.newLine;{let $=this.options.tagValueProcessor(w,x);return $=this.replaceEntitiesValue($),$===""&&this.options.unpairedTags.indexOf(w)!==-1?this.options.suppressUnpairedNode?this.indentate(N)+"<"+w+this.tagEndChar:this.indentate(N)+"<"+w+"/"+this.tagEndChar:this.indentate(N)+"<"+w+b+">"+$+"0&&this.options.processEntities)for(let w=0;w0&&(x=a+""+S.indentBy.repeat(k));for(let w=0;w`;continue}else if(N===S.commentPropName){O+=x+``;continue}else if(N[0]==="?"){const Y=p(b[":@"],S),H=N==="?xml"?"":x;let D=b[N][0][S.textNodeName];D=D.length!==0?" "+D:"",O+=H+`<${N}${D}${Y}?>`;continue}const I=p(b[":@"],S);let j=x+`<${N}${I}`,B=f(b[N],S,$,k+1);S.unpairedTags.indexOf(N)!==-1?S.suppressUnpairedNode?O+=j+">":O+=j+"/>":(!B||B.length===0)&&S.suppressEmptyNode?O+=j+"/>":O+=j+`>${B}${x}`}return O}function d(v){const S=Object.keys(v);for(let E=0;E0&&S.processEntities)for(let E=0;E"){if(E)if(d[p-1]==="-"&&d[p-2]==="-")E=!1;else throw new Error("Invalid XML comment in DOCTYPE");else S&&(f(k,m),S=!1);if(h--,h===0)break}else d[p]==="["?v=!0:k+=d[p];if(h!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:m,i:p}}const u=RegExp(`^\\s([a-zA-z0-0]+)[ ](['"])([^&]+)\\2`);function f(d,p){const m=u.exec(d);m&&(p[m[1]]={regx:RegExp(`&${m[1]};`,"g"),val:m[3]})}i.exports=a},{}],9:[function(n,i,r){const a={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0},tagValueProcessor:function(f,d){return d},attributeValueProcessor:function(f,d){return d},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1},u=function(f){return Object.assign({},a,f)};r.buildOptions=u,r.defaultOptions=a},{}],10:[function(n,i,r){const a=n("../util"),u=n("./xmlNode"),f=n("./DocTypeReader"),d=n("strnum");"<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,a.nameRegexp);class p{constructor(Y){this.options=Y,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={amp:{regex:/&(amp|#38|#x26);/g,val:"&"},apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"}},this.addExternalEntities=m,this.parseXml=k,this.parseTextData=h,this.resolveNameSpace=v,this.buildAttributesMap=E,this.isItStopNode=w,this.replaceEntitiesValue=O,this.readStopNodeData=I,this.saveTextToParentTag=x}}function m(B){const Y=Object.keys(B);for(let H=0;H0)){o1||(B=this.replaceEntitiesValue(B));const i1=this.options.tagValueProcessor(Y,B,H,J,e1);return i1==null?B:typeof i1!=typeof B||i1!==B?i1:this.options.trimValues?j(B,this.options.parseTagValue,this.options.numberParseOptions):B.trim()===B?j(B,this.options.parseTagValue,this.options.numberParseOptions):B}}function v(B){if(this.options.removeNSPrefix){const Y=B.split(":"),H=B.charAt(0)==="/"?"/":"";if(Y[0]==="xmlns")return"";Y.length===2&&(B=H+Y[1])}return B}const S=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function E(B,Y){if(!this.options.ignoreAttributes&&typeof B=="string"){const H=a.getAllMatches(B,S),D=H.length,J={};for(let e1=0;e1",e1,"Closing Tag is not closed.");let l1=B.substring(e1+2,i1).trim();if(this.options.removeNSPrefix){const r1=l1.indexOf(":");r1!==-1&&(l1=l1.substr(r1+1))}H&&(D=this.saveTextToParentTag(D,H,J)),J=J.substr(0,J.lastIndexOf(".")),H=this.tagsNodeStack.pop(),D="",e1=i1}else if(B[e1+1]==="?"){let i1=$(B,e1,!1,"?>");if(!i1)throw new Error("Pi Tag is not closed.");if(D=this.saveTextToParentTag(D,H,J),!(this.options.ignoreDeclaration&&i1.tagName==="?xml"||this.options.ignorePiTags)){const l1=new u(i1.tagName);l1.add(this.options.textNodeName,""),i1.tagName!==i1.tagExp&&i1.attrExpPresent&&(l1[":@"]=this.buildAttributesMap(i1.tagExp,J)),H.addChild(l1)}e1=i1.closeIndex+1}else if(B.substr(e1+1,3)==="!--"){const i1=N(B,"-->",e1+4,"Comment is not closed.");if(this.options.commentPropName){const l1=B.substring(e1+4,i1-2);D=this.saveTextToParentTag(D,H,J),H.add(this.options.commentPropName,[{[this.options.textNodeName]:l1}])}e1=i1}else if(B.substr(e1+1,2)==="!D"){const i1=f(B,e1);this.docTypeEntities=i1.entities,e1=i1.i}else if(B.substr(e1+1,2)==="!["){const i1=N(B,"]]>",e1,"CDATA is not closed.")-2,l1=B.substring(e1+9,i1);if(D=this.saveTextToParentTag(D,H,J),this.options.cdataPropName)H.add(this.options.cdataPropName,[{[this.options.textNodeName]:l1}]);else{let r1=this.parseTextData(l1,H.tagname,J,!0,!1,!0);r1||(r1=""),H.add(this.options.textNodeName,r1)}e1=i1+2}else{let i1=$(B,e1,this.options.removeNSPrefix),l1=i1.tagName,r1=i1.tagExp,V=i1.attrExpPresent,p1=i1.closeIndex;H&&D&&H.tagname!=="!xml"&&(D=this.saveTextToParentTag(D,H,J,!1)),l1!==Y.tagname&&(J+=J?"."+l1:l1);const f1=H;if(f1&&this.options.unpairedTags.indexOf(f1.tagname)!==-1&&(H=this.tagsNodeStack.pop()),this.isItStopNode(this.options.stopNodes,J,l1)){let w1="";if(r1.length>0&&r1.lastIndexOf("/")===r1.length-1)e1=i1.closeIndex;else if(this.options.unpairedTags.indexOf(l1)!==-1)e1=i1.closeIndex;else{const j1=this.readStopNodeData(B,l1,p1+1);if(!j1)throw new Error(`Unexpected end of ${l1}`);e1=j1.i,w1=j1.tagContent}const T1=new u(l1);l1!==r1&&V&&(T1[":@"]=this.buildAttributesMap(r1,J)),w1&&(w1=this.parseTextData(w1,l1,J,!0,V,!0,!0)),J=J.substr(0,J.lastIndexOf(".")),T1.add(this.options.textNodeName,w1),H.addChild(T1)}else{if(r1.length>0&&r1.lastIndexOf("/")===r1.length-1){l1[l1.length-1]==="/"?(l1=l1.substr(0,l1.length-1),r1=l1):r1=r1.substr(0,r1.length-1);const w1=new u(l1);l1!==r1&&V&&(w1[":@"]=this.buildAttributesMap(r1,J)),J=J.substr(0,J.lastIndexOf(".")),H.addChild(w1)}else{const w1=new u(l1);this.tagsNodeStack.push(H),l1!==r1&&V&&(w1[":@"]=this.buildAttributesMap(r1,J)),H.addChild(w1),H=w1}D="",e1=p1}}else D+=B[e1];return Y.child},O=function(B){if(this.options.processEntities){for(let Y in this.docTypeEntities){const H=this.docTypeEntities[Y];B=B.replace(H.regx,H.val)}for(let Y in this.lastEntities){const H=this.lastEntities[Y];B=B.replace(H.regex,H.val)}if(this.options.htmlEntities)for(let Y in this.htmlEntities){const H=this.htmlEntities[Y];B=B.replace(H.regex,H.val)}}return B};function x(B,Y,H,D){return B&&(D===void 0&&(D=Object.keys(Y.child).length===0),B=this.parseTextData(B,Y.tagname,H,!1,Y[":@"]?Object.keys(Y[":@"]).length!==0:!1,D),B!==void 0&&B!==""&&Y.add(this.options.textNodeName,B),B=""),B}function w(B,Y,H){const D="*."+H;for(const J in B){const e1=B[J];if(D===e1||Y===e1)return!0}return!1}function b(B,Y,H=">"){let D,J="";for(let e1=Y;e1",H,`${Y} is not closed`);if(B.substring(H+2,J).trim()===Y)return{tagContent:B.substring(D,H),i:J};H=J}}function j(B,Y,H){if(Y&&typeof B=="string"){const D=B.trim();return D==="true"?!0:D==="false"?!1:d(B,H)}else return a.isExist(B)?B:""}i.exports=p},{"../util":4,"./DocTypeReader":8,"./xmlNode":13,strnum:15}],11:[function(n,i,r){const{buildOptions:a}=n("./OptionsBuilder"),u=n("./OrderedObjParser"),{prettify:f}=n("./node2json"),d=n("../validator");class p{constructor(h){this.externalEntities={},this.options=a(h)}parse(h,v){if(typeof h!="string")if(h.toString)h=h.toString();else throw new Error("XML data is accepted in String or Bytes[] form.");if(v){v===!0&&(v={});const k=d.validate(h,v);if(k!==!0)throw Error(`${k.err.msg}:${k.err.line}:${k.err.col}`)}const S=new u(this.options);S.addExternalEntities(this.externalEntities);const E=S.parseXml(h);return this.options.preserveOrder||E===void 0?E:f(E,this.options)}addEntity(h,v){if(v.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(h.indexOf("&")!==-1||h.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for ' '");this.externalEntities[h]=v}}i.exports=p},{"../validator":5,"./OptionsBuilder":9,"./OrderedObjParser":10,"./node2json":12}],12:[function(n,i,r){function a(m,h){return u(m,h)}function u(m,h,v){let S;const E={};for(let k=0;k0&&(E[h.textNodeName]=S):S!==void 0&&(E[h.textNodeName]=S),E}function f(m){const h=Object.keys(m);for(let v=0;v0?this.child.push({[f.tagname]:f.child,":@":f[":@"]}):this.child.push({[f.tagname]:f.child})}}i.exports=a},{}],14:[function(n,i,r){/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */r.read=function(a,u,f,d,p){var m,h,v=p*8-d-1,S=(1<>1,k=-7,O=f?p-1:0,x=f?-1:1,w=a[u+O];for(O+=x,m=w&(1<<-k)-1,w>>=-k,k+=v;k>0;m=m*256+a[u+O],O+=x,k-=8);for(h=m&(1<<-k)-1,m>>=-k,k+=d;k>0;h=h*256+a[u+O],O+=x,k-=8);if(m===0)m=1-E;else{if(m===S)return h?NaN:(w?-1:1)*(1/0);h=h+Math.pow(2,d),m=m-E}return(w?-1:1)*h*Math.pow(2,m-d)},r.write=function(a,u,f,d,p,m){var h,v,S,E=m*8-p-1,k=(1<>1,x=p===23?Math.pow(2,-24)-Math.pow(2,-77):0,w=d?0:m-1,b=d?1:-1,N=u<0||u===0&&1/u<0?1:0;for(u=Math.abs(u),isNaN(u)||u===1/0?(v=isNaN(u)?1:0,h=k):(h=Math.floor(Math.log(u)/Math.LN2),u*(S=Math.pow(2,-h))<1&&(h--,S*=2),h+O>=1?u+=x/S:u+=x*Math.pow(2,1-O),u*S>=2&&(h++,S/=2),h+O>=k?(v=0,h=k):h+O>=1?(v=(u*S-1)*Math.pow(2,p),h=h+O):(v=u*Math.pow(2,O-1)*Math.pow(2,p),h=0));p>=8;a[f+w]=v&255,w+=b,v/=256,p-=8);for(h=h<0;a[f+w]=h&255,w+=b,h/=256,E-=8);a[f+w-b]|=N*128}},{}],15:[function(n,i,r){const a=/^[-+]?0x[a-fA-F0-9]+$/,u=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);const f={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function d(m,h={}){if(h=Object.assign({},f,h),!m||typeof m!="string")return m;let v=m.trim();if(h.skipLike!==void 0&&h.skipLike.test(v))return m;if(h.hex&&a.test(v))return Number.parseInt(v,16);{const S=u.exec(v);if(S){const E=S[1],k=S[2];let O=p(S[3]);const x=S[4]||S[6];if(!h.leadingZeros&&k.length>0&&E&&v[2]!==".")return m;if(!h.leadingZeros&&k.length>0&&!E&&v[1]!==".")return m;{const w=Number(v),b=""+w;return b.search(/[eE]/)!==-1||x?h.eNotation?w:m:v.indexOf(".")!==-1?b==="0"&&O===""||b===O||E&&b==="-"+O?w:m:k?O===b||E+O===b?w:m:v===b||v===E+b?w:m}}else return m}}function p(m){return m&&m.indexOf(".")!==-1&&(m=m.replace(/0+$/,""),m==="."?m="0":m[0]==="."?m="0"+m:m[m.length-1]==="."&&(m=m.substr(0,m.length-1))),m}i.exports=d},{}],16:[function(n,i,r){(function(a){(function(){var u=this&&this.__awaiter||function(v,S,E,k){function O(x){return x instanceof E?x:new E(function(w){w(x)})}return new(E||(E=Promise))(function(x,w){function b(I){try{$(k.next(I))}catch(j){w(j)}}function N(I){try{$(k.throw(I))}catch(j){w(j)}}function $(I){I.done?x(I.value):O(I.value).then(b,N)}$((k=k.apply(v,S||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.osmFetch=void 0;const f=n("../auth"),d=n("../config"),p=n("./_xml"),m=v=>typeof btoa>"u"?a.from(v,"binary").toString("base64"):btoa(v);function h(v,S,E){return u(this,void 0,void 0,function*(){const{apiUrl:k,authHeader:O,basicAuth:x,userAgent:w}=(0,d.getConfig)(),b=x&&`Basic ${m(`${x.username}:${x.password}`)}`,N=(0,f.getAuthToken)()&&`Bearer ${(0,f.getAuthToken)()}`;let $=new URLSearchParams(S).toString();$&&($=`?${$}`);const I=yield fetch(`${k}/api${v}${$}`,Object.assign(Object.assign({},E),{headers:Object.assign({Authorization:O||b||N||"","User-Agent":w},E==null?void 0:E.headers)})),j=I.headers.get("Content-Type");if(j!=null&&j.startsWith("application/xml")){const B=yield I.text();return yield p.xmlParser.parse(B)}if(j!=null&&j.startsWith("application/json"))return I.json();if(I.ok)return yield I.text();throw new Error(`OSM API: ${yield I.text()}`)})}r.osmFetch=h}).call(this)}).call(this,n("buffer").Buffer)},{"../auth":37,"../config":39,"./_xml":17,buffer:2}],17:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.xmlParser=void 0;const a=n("fast-xml-parser");r.xmlParser=new a.XMLParser({ignoreAttributes:!1,attributesGroupName:"$",attributeNamePrefix:"",isArray:u=>u!=="$"})},{"fast-xml-parser":3}],18:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.createOsmChangeXml=r.createChangesetMetaXml=void 0;const a=n("fast-xml-parser"),u=new a.XMLBuilder({ignoreAttributes:!1,attributeNamePrefix:"$",format:!0,suppressEmptyNode:!0,suppressBooleanAttributes:!1});function f(m){return u.build({osm:{changeset:{tag:Object.entries(m).map(([h,v])=>({$k:h,$v:v}))}}})}r.createChangesetMetaXml=f;const d=(m,h,v)=>h.reduce((S,E)=>{const k={$id:E.id,$version:v?0:E.version,$changeset:m,tag:Object.entries(E.tags||{}).map(([O,x])=>({$k:O,$v:x}))};switch(E.type){case"node":{const O=Object.assign(Object.assign({},k),{$lat:E.lat,$lon:E.lon});return Object.assign(Object.assign({},S),{node:[...S.node,O]})}case"way":{if(!E.nodes)throw new Error("Way has no nodes");const O=Object.assign(Object.assign({},k),{nd:E.nodes.map(x=>({$ref:x}))});return Object.assign(Object.assign({},S),{way:[...S.way,O]})}case"relation":{if(!E.members)throw new Error("Relation has no members");const O=Object.assign(Object.assign({},k),{member:E.members.map(x=>({$type:x.type,$ref:x.ref,$role:x.role}))});return Object.assign(Object.assign({},S),{relation:[...S.relation,O]})}default:return S}},{node:[],way:[],relation:[]});function p(m,h,v){return u.build({osmChange:Object.assign(Object.assign({$version:"0.6",$generator:"osm-api-js"},v),{create:[d(m,h.create,!0)],modify:[d(m,h.modify)],delete:[Object.assign({"$if-unused":!0},d(m,h.delete))]})})}r.createOsmChangeXml=p},{"fast-xml-parser":3}],19:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.parseOsmChangeXml=r.parseOsmChangeJson=void 0;const a=n("../_xml");function u(m){return{changeset:+m.$.changeset,id:+m.$.id,timestamp:m.$.timestamp,uid:+m.$.uid,user:m.$.user,version:+m.$.version,tags:m.tag?Object.fromEntries(m.tag.map(h=>[h.$.k,h.$.v])):void 0}}const f=m=>{const h=[];if(m.node){const v=m.node.map(S=>Object.assign(Object.assign({type:"node"},u(S)),{lat:+S.$.lat,lon:+S.$.lon}));h.push(...v)}if(m.way){const v=m.way.map(S=>{var E;return Object.assign(Object.assign({type:"way"},u(S)),{nodes:((E=S.nd)===null||E===void 0?void 0:E.map(k=>+k.$.ref))||[]})});h.push(...v)}if(m.relation){const v=m.relation.map(S=>{var E;return Object.assign(Object.assign({type:"relation"},u(S)),{members:((E=S.member)===null||E===void 0?void 0:E.map(k=>({ref:+k.$.ref,role:k.$.role,type:k.$.type})))||[]})});h.push(...v)}return h};function d(m){var h,v,S;return{create:((h=m.osmChange[0].create)===null||h===void 0?void 0:h.flatMap(f))||[],modify:((v=m.osmChange[0].modify)===null||v===void 0?void 0:v.flatMap(f))||[],delete:((S=m.osmChange[0].delete)===null||S===void 0?void 0:S.flatMap(f))||[]}}r.parseOsmChangeJson=d;function p(m){const h=a.xmlParser.parse(m);return d(h)}r.parseOsmChangeXml=p},{"../_xml":17}],20:[function(n,i,r){var a=this&&this.__awaiter||function(d,p,m,h){function v(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):v(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.createChangesetComment=void 0;const u=n("../_osmFetch");function f(d,p){return a(this,void 0,void 0,function*(){yield(0,u.osmFetch)(`/0.6/changeset/${d}/comment`,void 0,{method:"POST",body:`text=${encodeURIComponent(p)}`,headers:{"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"}})})}r.createChangesetComment=f},{"../_osmFetch":16}],21:[function(n,i,r){var a=this&&this.__awaiter||function(p,m,h,v){function S(E){return E instanceof h?E:new h(function(k){k(E)})}return new(h||(h=Promise))(function(E,k){function O(b){try{w(v.next(b))}catch(N){k(N)}}function x(b){try{w(v.throw(b))}catch(N){k(N)}}function w(b){b.done?E(b.value):S(b.value).then(O,x)}w((v=v.apply(p,m||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getChangesetDiff=void 0;const u=n("../_osmFetch"),f=n("./_parseOsmChangeXml");function d(p){return a(this,void 0,void 0,function*(){const m=yield(0,u.osmFetch)(`/0.6/changeset/${p}/download`);return(0,f.parseOsmChangeJson)(m)})}r.getChangesetDiff=d},{"../_osmFetch":16,"./_parseOsmChangeXml":19}],22:[function(n,i,r){var a=this&&this.__awaiter||function(h,v,S,E){function k(O){return O instanceof S?O:new S(function(x){x(O)})}return new(S||(S=Promise))(function(O,x){function w($){try{N(E.next($))}catch(I){x(I)}}function b($){try{N(E.throw($))}catch(I){x(I)}}function N($){$.done?O($.value):k($.value).then(w,b)}N((E=E.apply(h,v||[])).next())})},u=this&&this.__rest||function(h,v){var S={};for(var E in h)Object.prototype.hasOwnProperty.call(h,E)&&v.indexOf(E)<0&&(S[E]=h[E]);if(h!=null&&typeof Object.getOwnPropertySymbols=="function")for(var k=0,E=Object.getOwnPropertySymbols(h);k{var v;return{id:+h.$.id,created_at:new Date(h.$.created_at),closed_at:new Date(h.$.closed_at),open:h.$.open==="true",comments_count:+h.$.comments_count,changes_count:+h.$.changes_count,min_lat:+h.$.min_lat,min_lon:+h.$.min_lon,max_lat:+h.$.max_lat,max_lon:+h.$.max_lon,uid:+h.$.uid,user:h.$.user,tags:Object.fromEntries(h.tag.map(S=>[S.$.k,S.$.v])),discussion:(v=h.discussion)===null||v===void 0?void 0:v[0].comment.map(S=>({date:new Date(S.$.date),user:S.$.user,uid:S.$.uid,text:S.text[0]}))}};function p(h){var v;return a(this,void 0,void 0,function*(){const{only:S}=h,E=u(h,["only"]);return((v=(yield(0,f.osmFetch)("/0.6/changesets",Object.assign(Object.assign({},S&&{[S]:!0}),E))).osm[0].changeset)===null||v===void 0?void 0:v.map(d))||[]})}r.listChangesets=p;function m(h,v=!0){return a(this,void 0,void 0,function*(){return(yield(0,f.osmFetch)(`/0.6/changeset/${h}`,{include_discussion:v})).osm[0].changeset.map(d)[0]})}r.getChangeset=m},{"../_osmFetch":16}],23:[function(n,i,r){var a=this&&this.__createBinding||(Object.create?function(p,m,h,v){v===void 0&&(v=h);var S=Object.getOwnPropertyDescriptor(m,h);(!S||("get"in S?!m.__esModule:S.writable||S.configurable))&&(S={enumerable:!0,get:function(){return m[h]}}),Object.defineProperty(p,v,S)}:function(p,m,h,v){v===void 0&&(v=h),p[v]=m[h]}),u=this&&this.__exportStar||function(p,m){for(var h in p)h!=="default"&&!Object.prototype.hasOwnProperty.call(m,h)&&a(m,p,h)};Object.defineProperty(r,"__esModule",{value:!0}),r.createOsmChangeXml=r.parseOsmChangeXml=void 0,u(n("./createChangesetComment"),r),u(n("./getChangesetDiff"),r),u(n("./getChangesets"),r),u(n("./uploadChangeset"),r);var f=n("./_parseOsmChangeXml");Object.defineProperty(r,"parseOsmChangeXml",{enumerable:!0,get:function(){return f.parseOsmChangeXml}});var d=n("./_createOsmChangeXml");Object.defineProperty(r,"createOsmChangeXml",{enumerable:!0,get:function(){return d.createOsmChangeXml}})},{"./_createOsmChangeXml":18,"./_parseOsmChangeXml":19,"./createChangesetComment":20,"./getChangesetDiff":21,"./getChangesets":22,"./uploadChangeset":24}],24:[function(n,i,r){var a=this&&this.__awaiter||function(p,m,h,v){function S(E){return E instanceof h?E:new h(function(k){k(E)})}return new(h||(h=Promise))(function(E,k){function O(b){try{w(v.next(b))}catch(N){k(N)}}function x(b){try{w(v.throw(b))}catch(N){k(N)}}function w(b){b.done?E(b.value):S(b.value).then(O,x)}w((v=v.apply(p,m||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.uploadChangeset=void 0;const u=n("../_osmFetch"),f=n("./_createOsmChangeXml");function d(p,m){return a(this,void 0,void 0,function*(){const h=(0,f.createChangesetMetaXml)(p),v=+(yield(0,u.osmFetch)("/0.6/changeset/create",void 0,{method:"PUT",body:h,headers:{"content-type":"application/xml; charset=utf-8"}})),S=(0,f.createOsmChangeXml)(v,m);return yield(0,u.osmFetch)(`/0.6/changeset/${v}/upload`,void 0,{method:"POST",body:S,headers:{"content-type":"application/xml; charset=utf-8"}}),yield(0,u.osmFetch)(`/0.6/changeset/${v}/close`,void 0,{method:"PUT"}),+v})}r.uploadChangeset=d},{"../_osmFetch":16,"./_createOsmChangeXml":18}],25:[function(n,i,r){var a=this&&this.__awaiter||function(d,p,m,h){function v(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):v(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getCapabilities=void 0;const u=n("./_osmFetch");function f(){return a(this,void 0,void 0,function*(){const d=yield(0,u.osmFetch)("/capabilities");return{limits:{maxArea:+d.osm[0].api[0].area[0].$.maximum,maxNoteArea:+d.osm[0].api[0].note_area[0].$.maximum,maxTracepointPerPage:+d.osm[0].api[0].tracepoints[0].$.per_page,maxWayNodes:+d.osm[0].api[0].waynodes[0].$.maximum,maxChangesetElements:+d.osm[0].api[0].changesets[0].$.maximum_elements,maxTimeout:+d.osm[0].api[0].timeout[0].$.seconds},policy:{imageryBlacklist:d.osm[0].policy[0].imagery[0].blacklist.map(m=>m.$.regex)}}})}r.getCapabilities=f},{"./_osmFetch":16}],26:[function(n,i,r){var a=this&&this.__awaiter||function(S,E,k,O){function x(w){return w instanceof k?w:new k(function(b){b(w)})}return new(k||(k=Promise))(function(w,b){function N(j){try{I(O.next(j))}catch(B){b(B)}}function $(j){try{I(O.throw(j))}catch(B){b(B)}}function I(j){j.done?w(j.value):x(j.value).then(N,$)}I((O=O.apply(S,E||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getRelationsForElement=r.getWaysForNode=r.getFeatureHistory=r.getFeatureAtVersion=r.getFeatures=r.getFeature=void 0;const u=n("./_osmFetch");function f(S,E,k){return a(this,void 0,void 0,function*(){const O=k&&S!=="node"?"/full":"";return(yield(0,u.osmFetch)(`/0.6/${S}/${E}${O}.json`)).elements})}r.getFeature=f;function d(S,E){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}s.json?${S}s=${E.join(",")}`)).elements})}r.getFeatures=d;function p(S,E,k){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}/${E}/${k}.json`)).elements[0]})}r.getFeatureAtVersion=p;function m(S,E){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}/${E}/history.json`)).elements})}r.getFeatureHistory=m;function h(S){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/node/${S}/ways.json`)).elements})}r.getWaysForNode=h;function v(S,E){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/${S}/${E}/relations.json`)).elements})}r.getRelationsForElement=v},{"./_osmFetch":16}],27:[function(n,i,r){var a=this&&this.__awaiter||function(d,p,m,h){function v(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):v(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getMapData=void 0;const u=n("./_osmFetch");function f(d){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)("/0.6/map.json",{bbox:d})).elements})}r.getMapData=f},{"./_osmFetch":16}],28:[function(n,i,r){var a=this&&this.__awaiter||function(d,p,m,h){function v(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):v(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getUIdFromDisplayName=void 0;const u=n("./changesets");function f(d){return a(this,void 0,void 0,function*(){const p=yield(0,u.listChangesets)({display_name:d});if(!p.length)throw new Error("Could not get uid because the user has never edited the map");return p[0].uid})}r.getUIdFromDisplayName=f},{"./changesets":23}],29:[function(n,i,r){var a=this&&this.__awaiter||function(p,m,h,v){function S(E){return E instanceof h?E:new h(function(k){k(E)})}return new(h||(h=Promise))(function(E,k){function O(b){try{w(v.next(b))}catch(N){k(N)}}function x(b){try{w(v.throw(b))}catch(N){k(N)}}function w(b){b.done?E(b.value):S(b.value).then(O,x)}w((v=v.apply(p,m||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getUsers=r.getUser=void 0;const u=n("./_osmFetch");function f(p){return a(this,void 0,void 0,function*(){const m=yield(0,u.osmFetch)(`/0.6/user/${p==="me"?"details":p}.json`);return Object.assign(Object.assign({},m.user),{account_created:new Date(m.user.account_created)})})}r.getUser=f;function d(p){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)("/0.6/users",{users:p})).users.map(h=>Object.assign(Object.assign({},h),{account_created:new Date(h.account_created)}))})}r.getUsers=d},{"./_osmFetch":16}],30:[function(n,i,r){var a=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&a(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./changesets"),r),u(n("./notes"),r),u(n("./getCapabilities"),r),u(n("./getFeature"),r),u(n("./getMapData"),r),u(n("./getUIdFromDisplayName"),r),u(n("./getUser"),r)},{"./changesets":23,"./getCapabilities":25,"./getFeature":26,"./getMapData":27,"./getUIdFromDisplayName":28,"./getUser":29,"./notes":32}],31:[function(n,i,r){var a=this&&this.__awaiter||function(v,S,E,k){function O(x){return x instanceof E?x:new E(function(w){w(x)})}return new(E||(E=Promise))(function(x,w){function b(I){try{$(k.next(I))}catch(j){w(j)}}function N(I){try{$(k.throw(I))}catch(j){w(j)}}function $(I){I.done?x(I.value):O(I.value).then(b,N)}$((k=k.apply(v,S||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getNote=r.getNotesForArea=r.getNotesForQuery=void 0;const u=n("../_osmFetch"),f=v=>{const[S,E]=v.geometry.coordinates;return Object.assign(Object.assign({},v.properties),{location:{lat:E,lng:S}})};function d(v,S){return a(this,void 0,void 0,function*(){return(yield(0,u.osmFetch)(`/0.6/notes${S?"/search":""}.json`,v)).features.map(f)})}function p(v){return d(v,!0)}r.getNotesForQuery=p;function m(v){return d({bbox:v},!1)}r.getNotesForArea=m;function h(v){return a(this,void 0,void 0,function*(){const S=yield(0,u.osmFetch)(`/0.6/notes/${v}.json`);return f(S)})}r.getNote=h},{"../_osmFetch":16}],32:[function(n,i,r){var a=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&a(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./getNotes"),r),u(n("./noteActions"),r)},{"./getNotes":31,"./noteActions":33}],33:[function(n,i,r){var a=this&&this.__awaiter||function(m,h,v,S){function E(k){return k instanceof v?k:new v(function(O){O(k)})}return new(v||(v=Promise))(function(k,O){function x(N){try{b(S.next(N))}catch($){O($)}}function w(N){try{b(S.throw(N))}catch($){O($)}}function b(N){N.done?k(N.value):E(N.value).then(x,w)}b((S=S.apply(m,h||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.reopenNote=r.commentOnNote=r.createNote=void 0;const u=n("../_osmFetch");function f(m,h,v){return a(this,void 0,void 0,function*(){yield(0,u.osmFetch)("/0.6/notes",{lat:m,lon:h,text:v})})}r.createNote=f;function d(m,h){return a(this,void 0,void 0,function*(){yield(0,u.osmFetch)(`/0.6/notes/${m}/comment`,{text:h})})}r.commentOnNote=d;function p(m,h){return a(this,void 0,void 0,function*(){yield(0,u.osmFetch)(`/0.6/notes/${m}/reopen`,{text:h})})}r.reopenNote=p},{"../_osmFetch":16}],34:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.createPopup=void 0;function a(u){let f=!1;return new Promise((d,p)=>{const[m,h]=[600,550],v=Object.entries({width:m,height:h,left:window.screen.width/2-m/2,top:window.screen.height/2-h/2}).map(([k,O])=>`${k}=${O}`).join(","),S=window.open("about:blank","oauth_window",v);if(!S)throw new Error("Popup was blocked");S.location=u,window.authComplete=k=>{d(k),f=!0};const E=setInterval(()=>{S.closed&&(f||p(new Error("Cancelled")),clearInterval(E))},500)})}r.createPopup=a},{}],35:[function(n,i,r){var a=this&&this.__awaiter||function(d,p,m,h){function v(S){return S instanceof m?S:new m(function(E){E(S)})}return new(m||(m=Promise))(function(S,E){function k(w){try{x(h.next(w))}catch(b){E(b)}}function O(w){try{x(h.throw(w))}catch(b){E(b)}}function x(w){w.done?S(w.value):v(w.value).then(k,O)}x((h=h.apply(d,p||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.exchangeCode=void 0;const u=n("./helpers");function f(d,{options:p,pkceVerifier:m,state:h}){return a(this,void 0,void 0,function*(){const v=new URL(d).searchParams,S=v.get("error_description"),E=v.get("code"),k=v.get("state");if(S)throw new Error(S);if(!E)throw new Error("No code in OAuth response");if(!m||!h)throw new Error("No login in progress");if(h!==k)throw new Error("State Mismatch");const O={grant_type:"authorization_code",code:E,redirect_uri:p.redirectUrl,client_id:p.clientId,code_verifier:m},x=`${(0,u.getOAuthBaseUrl)()}/oauth2/token?${new URLSearchParams(O).toString()}`,b=yield(yield fetch(x,{method:"POST",body:"",headers:{"Content-Type":"application/x-www-form-urlencoded"}})).json();if("error_description"in b)throw new Error(b.error_description);const N={issuedAt:new Date(b.created_at*1e3).toISOString(),accessToken:b.access_token,scopes:b.scope.split(" ")};return localStorage.setItem("__osmAuth",JSON.stringify(N)),delete window.authComplete,N})}r.exchangeCode=f},{"./helpers":36}],36:[function(n,i,r){var a=this&&this.__awaiter||function(m,h,v,S){function E(k){return k instanceof v?k:new v(function(O){O(k)})}return new(v||(v=Promise))(function(k,O){function x(N){try{b(S.next(N))}catch($){O($)}}function w(N){try{b(S.throw(N))}catch($){O($)}}function b(N){N.done?k(N.value):E(N.value).then(x,w)}b((S=S.apply(m,h||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.getOAuthBaseUrl=r.getRandomString=r.sha256=void 0;const u=n("../config");function f(m){return a(this,void 0,void 0,function*(){const h=new TextEncoder().encode(m),v=yield window.crypto.subtle.digest("SHA-256",h);return btoa(String.fromCharCode(...new Uint8Array(v))).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")})}r.sha256=f;function d(){return[...window.crypto.getRandomValues(new Uint32Array(32))].map(m=>`0${m.toString(16)}`.slice(-2)).join("")}r.getRandomString=d;function p(){let m=(0,u.getConfig)().apiUrl;return m==="https://api.openstreetmap.org"&&(m="https://www.openstreetmap.org"),m}r.getOAuthBaseUrl=p},{"../config":39}],37:[function(n,i,r){var a=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&a(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./oauth2"),r)},{"./oauth2":38}],38:[function(n,i,r){var a=this&&this.__awaiter||function(S,E,k,O){function x(w){return w instanceof k?w:new k(function(b){b(w)})}return new(k||(k=Promise))(function(w,b){function N(j){try{I(O.next(j))}catch(B){b(B)}}function $(j){try{I(O.throw(j))}catch(B){b(B)}}function I(j){j.done?w(j.value):x(j.value).then(N,$)}I((O=O.apply(S,E||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.logout=r.isLoggedIn=r.getAuthToken=r.authReady=r.login=void 0;const u=n("./createPopup"),f=n("./exchangeCode"),d=n("./helpers");function p(S){return a(this,void 0,void 0,function*(){if(!S.redirectUrl)throw new Error("You must include the 'redirectUrl' option");if(!S.clientId)throw new Error("You must include the 'clientId' option");if(!S.scopes)throw new Error("You must include the 'scopes' option");const E=(0,d.getRandomString)(),k=(0,d.getRandomString)(),O=yield(0,d.sha256)(k),x={scope:S.scopes.join(" "),include_granted_scopes:"true",response_type:"code",state:E,redirect_uri:S.redirectUrl,client_id:S.clientId,code_challenge_method:"S256",code_challenge:O},w=`${(0,d.getOAuthBaseUrl)()}/oauth2/authorize?${new URLSearchParams(x).toString()}`,b={state:E,pkceVerifier:k,options:S};if(S.mode==="popup"){const N=yield(0,u.createPopup)(w);return(0,f.exchangeCode)(N,b)}if(S.mode==="redirect"){localStorage.set("__osmAuthTemp",JSON.stringify(b)),window.location.replace(w);return}throw new Error("options.mode must be 'popup' or 'redirect'")})}r.login=p,r.authReady=(()=>a(void 0,void 0,void 0,function*(){var S;if(typeof window>"u")return;const E=window.location.href,k=localStorage.getItem("__osmAuthTemp");if(new URL(E).searchParams.get("code")){if(!((S=window.opener)===null||S===void 0)&&S.authComplete)window.opener.authComplete(E),window.close();else if(k)try{const O=JSON.parse(k);yield(0,f.exchangeCode)(E,O),localStorage.removeItem("__osmAuthTemp")}catch(O){console.error("OSM Auth Error",O)}}}))();const m=()=>{try{const S=localStorage.getItem("__osmAuth");return S?JSON.parse(S).accessToken:void 0}catch{return}};r.getAuthToken=m;const h=()=>!!(0,r.getAuthToken)();r.isLoggedIn=h;function v(){localStorage.removeItem("__osmAuth")}r.logout=v},{"./createPopup":34,"./exchangeCode":35,"./helpers":36}],39:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0}),r.configure=r.getConfig=void 0;const a={apiUrl:"https://api.openstreetmap.org",userAgent:"https://github.com/k-yle/osm-api-js"},u=()=>a;r.getConfig=u;function f(d){Object.assign(a,d)}r.configure=f},{}],40:[function(n,i,r){var a=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&a(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),n("./polyfill"),u(n("./api"),r),u(n("./auth"),r),u(n("./config"),r),u(n("./types"),r)},{"./api":30,"./auth":37,"./config":39,"./polyfill":41,"./types":45}],41:[function(n,i,r){if(typeof fetch>"u")try{n("isomorphic-fetch")}catch{console.error([` -========== -`,"(!) The `fetch` API is not available, and the polyfill (`isomorphic-fetch`) is also not available.","Run `npm install isomorphic-fetch`, or make sure that the global variable `fetch` exists",` -========== -`].join(` -`))}},{"isomorphic-fetch":"isomorphic-fetch"}],42:[function(n,i,r){Object.defineProperty(r,"__esModule",{value:!0})},{}],43:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}],44:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}],45:[function(n,i,r){var a=this&&this.__createBinding||(Object.create?function(f,d,p,m){m===void 0&&(m=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return d[p]}}),Object.defineProperty(f,m,h)}:function(f,d,p,m){m===void 0&&(m=p),f[m]=d[p]}),u=this&&this.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&a(d,f,p)};Object.defineProperty(r,"__esModule",{value:!0}),u(n("./changesets"),r),u(n("./features"),r),u(n("./general"),r),u(n("./notes"),r),u(n("./user"),r)},{"./changesets":42,"./features":43,"./general":44,"./notes":46,"./user":47}],46:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}],47:[function(n,i,r){arguments[4][42][0].apply(r,arguments)},{dup:42}]},{},[40])(40)})})(GE);var B4=GE.exports;function he1(e,t=!1){const n=e.length;let i=0,r="",a=0,u=16,f=0,d=0,p=0,m=0,h=0;function v(b,N){let $=0,I=0;for(;$=48&&j<=57)I=I*16+j-48;else if(j>=65&&j<=70)I=I*16+j-65+10;else if(j>=97&&j<=102)I=I*16+j-97+10;else break;i++,$++}return $=n){b+=e.substring(N,i),h=2;break}const $=e.charCodeAt(i);if($===34){b+=e.substring(N,i),i++;break}if($===92){if(b+=e.substring(N,i),i++,i>=n){h=2;break}switch(e.charCodeAt(i++)){case 34:b+='"';break;case 92:b+="\\";break;case 47:b+="/";break;case 98:b+="\b";break;case 102:b+="\f";break;case 110:b+=` -`;break;case 114:b+="\r";break;case 116:b+=" ";break;case 117:const j=v(4,!0);j>=0?b+=String.fromCharCode(j):h=4;break;default:h=5}N=i;continue}if($>=0&&$<=31)if(f7($)){b+=e.substring(N,i),h=2;break}else h=6;i++}return b}function O(){if(r="",h=0,a=i,d=f,m=p,i>=n)return a=n,u=17;let b=e.charCodeAt(i);if(Au(b)){do i++,r+=String.fromCharCode(b),b=e.charCodeAt(i);while(Au(b));return u=15}if(f7(b))return i++,r+=String.fromCharCode(b),b===13&&e.charCodeAt(i)===10&&(i++,r+=` -`),f++,p=i,u=14;switch(b){case 123:return i++,u=1;case 125:return i++,u=2;case 91:return i++,u=3;case 93:return i++,u=4;case 58:return i++,u=6;case 44:return i++,u=5;case 34:return i++,r=k(),u=10;case 47:const N=i-1;if(e.charCodeAt(i+1)===47){for(i+=2;i=12&&b<=15);return b}return{setPosition:S,getPosition:()=>i,scan:t?w:O,getToken:()=>u,getTokenValue:()=>r,getTokenOffset:()=>a,getTokenLength:()=>i-a,getTokenStartLine:()=>d,getTokenStartCharacter:()=>a-m,getTokenError:()=>h}}function Au(e){return e===32||e===9}function f7(e){return e===10||e===13}function l6(e){return e>=48&&e<=57}var tv;(function(e){e[e.lineFeed=10]="lineFeed",e[e.carriageReturn=13]="carriageReturn",e[e.space=32]="space",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e.asterisk=42]="asterisk",e[e.backslash=92]="backslash",e[e.closeBrace=125]="closeBrace",e[e.closeBracket=93]="closeBracket",e[e.colon=58]="colon",e[e.comma=44]="comma",e[e.dot=46]="dot",e[e.doubleQuote=34]="doubleQuote",e[e.minus=45]="minus",e[e.openBrace=123]="openBrace",e[e.openBracket=91]="openBracket",e[e.plus=43]="plus",e[e.slash=47]="slash",e[e.formFeed=12]="formFeed",e[e.tab=9]="tab"})(tv||(tv={}));var Or;(function(e){e.DEFAULT={allowTrailingComma:!1}})(Or||(Or={}));function pe1(e,t=[],n=Or.DEFAULT){let i=null,r=[];const a=[];function u(d){Array.isArray(r)?r.push(d):i!==null&&(r[i]=d)}return ge1(e,{onObjectBegin:()=>{const d={};u(d),a.push(r),r=d,i=null},onObjectProperty:d=>{i=d},onObjectEnd:()=>{r=a.pop()},onArrayBegin:()=>{const d=[];u(d),a.push(r),r=d,i=null},onArrayEnd:()=>{r=a.pop()},onLiteralValue:u,onError:(d,p,m)=>{t.push({error:d,offset:p,length:m})}},n),r[0]}function ge1(e,t,n=Or.DEFAULT){const i=he1(e,!1),r=[];function a(J){return J?()=>J(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter()):()=>!0}function u(J){return J?()=>J(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter(),()=>r.slice()):()=>!0}function f(J){return J?e1=>J(e1,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter()):()=>!0}function d(J){return J?e1=>J(e1,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter(),()=>r.slice()):()=>!0}const p=u(t.onObjectBegin),m=d(t.onObjectProperty),h=a(t.onObjectEnd),v=u(t.onArrayBegin),S=a(t.onArrayEnd),E=d(t.onLiteralValue),k=f(t.onSeparator),O=a(t.onComment),x=f(t.onError),w=n&&n.disallowComments,b=n&&n.allowTrailingComma;function N(){for(;;){const J=i.scan();switch(i.getTokenError()){case 4:$(14);break;case 5:$(15);break;case 3:$(13);break;case 1:w||$(11);break;case 2:$(12);break;case 6:$(16);break}switch(J){case 12:case 13:w?$(10):O();break;case 16:$(1);break;case 15:case 14:break;default:return J}}}function $(J,e1=[],o1=[]){if(x(J),e1.length+o1.length>0){let i1=i.getToken();for(;i1!==17;){if(e1.indexOf(i1)!==-1){N();break}else if(o1.indexOf(i1)!==-1)break;i1=N()}}}function I(J){const e1=i.getTokenValue();return J?E(e1):(m(e1),r.push(e1)),N(),!0}function j(){switch(i.getToken()){case 11:const J=i.getTokenValue();let e1=Number(J);isNaN(e1)&&($(2),e1=0),E(e1);break;case 7:E(null);break;case 8:E(!0);break;case 9:E(!1);break;default:return!1}return N(),!0}function B(){return i.getToken()!==10?($(3,[],[2,5]),!1):(I(!1),i.getToken()===6?(k(":"),N(),D()||$(4,[],[2,5])):$(5,[],[2,5]),r.pop(),!0)}function Y(){p(),N();let J=!1;for(;i.getToken()!==2&&i.getToken()!==17;){if(i.getToken()===5){if(J||$(4,[],[]),k(","),N(),i.getToken()===2&&b)break}else J&&$(6,[],[]);B()||$(4,[],[2,5]),J=!0}return h(),i.getToken()!==2?$(7,[2],[]):N(),!0}function H(){v(),N();let J=!0,e1=!1;for(;i.getToken()!==4&&i.getToken()!==17;){if(i.getToken()===5){if(e1||$(4,[],[]),k(","),N(),i.getToken()===4&&b)break}else e1&&$(6,[],[]);J?(r.push(0),J=!1):r[r.length-1]++,D()||$(4,[],[4,5]),e1=!0}return S(),J||r.pop(),i.getToken()!==4?$(8,[4],[]):N(),!0}function D(){switch(i.getToken()){case 3:return H();case 1:return Y();case 10:return I(!0);default:return j()}}return N(),i.getToken()===17?n.allowEmptyContent?!0:($(4,[],[]),!1):D()?(i.getToken()!==17&&$(9,[],[]),!0):($(4,[],[]),!1)}var nv;(function(e){e[e.None=0]="None",e[e.UnexpectedEndOfComment=1]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=2]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=3]="UnexpectedEndOfNumber",e[e.InvalidUnicode=4]="InvalidUnicode",e[e.InvalidEscapeCharacter=5]="InvalidEscapeCharacter",e[e.InvalidCharacter=6]="InvalidCharacter"})(nv||(nv={}));var iv;(function(e){e[e.OpenBraceToken=1]="OpenBraceToken",e[e.CloseBraceToken=2]="CloseBraceToken",e[e.OpenBracketToken=3]="OpenBracketToken",e[e.CloseBracketToken=4]="CloseBracketToken",e[e.CommaToken=5]="CommaToken",e[e.ColonToken=6]="ColonToken",e[e.NullKeyword=7]="NullKeyword",e[e.TrueKeyword=8]="TrueKeyword",e[e.FalseKeyword=9]="FalseKeyword",e[e.StringLiteral=10]="StringLiteral",e[e.NumericLiteral=11]="NumericLiteral",e[e.LineCommentTrivia=12]="LineCommentTrivia",e[e.BlockCommentTrivia=13]="BlockCommentTrivia",e[e.LineBreakTrivia=14]="LineBreakTrivia",e[e.Trivia=15]="Trivia",e[e.Unknown=16]="Unknown",e[e.EOF=17]="EOF"})(iv||(iv={}));const me1=pe1;var rv;(function(e){e[e.InvalidSymbol=1]="InvalidSymbol",e[e.InvalidNumberFormat=2]="InvalidNumberFormat",e[e.PropertyNameExpected=3]="PropertyNameExpected",e[e.ValueExpected=4]="ValueExpected",e[e.ColonExpected=5]="ColonExpected",e[e.CommaExpected=6]="CommaExpected",e[e.CloseBraceExpected=7]="CloseBraceExpected",e[e.CloseBracketExpected=8]="CloseBracketExpected",e[e.EndOfFileExpected=9]="EndOfFileExpected",e[e.InvalidCommentToken=10]="InvalidCommentToken",e[e.UnexpectedEndOfComment=11]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=12]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=13]="UnexpectedEndOfNumber",e[e.InvalidUnicode=14]="InvalidUnicode",e[e.InvalidEscapeCharacter=15]="InvalidEscapeCharacter",e[e.InvalidCharacter=16]="InvalidCharacter"})(rv||(rv={}));const kd=G.createContext({}),qE=({children:e})=>{const[t,n]=G.useState(),[i,r]=G.useState(!1),[a,u]=G.useState(B4.isLoggedIn()),[f,d]=G.useState();G.useEffect(()=>{a&&B4.getUser("me").then(d).catch(n)},[a]);const p=G.useCallback(async()=>{try{r(!0),await B4.login({clientId:window.location.hostname==="127.0.0.1"?"oPbyNuXQIEh8ZI3zbjVWVmVyIaNB2guU6uLP2gQ3sfs":"ZkRBVnOoBeMgwSajgG7E2bhgP5bR61knGYxsh9KKaHc",mode:"popup",redirectUrl:window.location.hostname==="127.0.0.1"?"http://127.0.0.1:3000/land.html":"https://osm-nz.github.io/land.html",scopes:["read_prefs","write_api","write_notes"]}),u(!0),r(!1),n(void 0)}catch(v){n(v),r(!1)}},[]),m=G.useCallback(()=>{B4.logout(),u(!1),d(void 0),n(void 0)},[]),h=G.useMemo(()=>({user:f,logout:m}),[f,m]);return t?R.jsxs(R.Fragment,{children:["Failed to login!",R.jsx("br",{}),`${t}`,R.jsx("br",{}),R.jsx("button",{type:"button",onClick:p,children:"Try Again"}),R.jsx("button",{type:"button",onClick:m,children:"Logout"})]}):i?R.jsx(R.Fragment,{children:"Login in progress... (use the popup window)"}):a?f?R.jsx(kd.Provider,{value:h,children:e}):R.jsx(R.Fragment,{children:"Loading..."}):R.jsxs(R.Fragment,{children:["You need to login to use this feature",R.jsx("br",{}),R.jsx("button",{type:"button",onClick:p,children:"Login"})]})};function VE(e,t){switch(e.type){case"node":return[e];case"way":return e.nodes.map(n=>t==null?void 0:t[`n${n}`]).filter(j11);case"relation":return e.members.flatMap(({type:n,ref:i})=>{const r=t==null?void 0:t[`${n[0]}${i}`];return r?VE(r,t):[]});default:return[]}}const YE=()=>({minLat:1/0,minLng:1/0,maxLat:-1/0,maxLng:-1/0});function ye1(e,t,n){const i=n||YE(),r=Object.values(e).flat().flatMap(a=>VE(a,t));for(const a of r)a.lati.maxLat&&(i.maxLat=a.lat),a.lon>i.maxLng&&(i.maxLng=a.lon);return i}function ve1(e){const t=[];for(const i of e.features)if("coordinates"in i.geometry){const r=i.geometry.coordinates.flat(3);t.push(...r)}const n=YE();for(let i=0;in.maxLat&&(n.maxLat=r)}else{const r=t[i];rn.maxLng&&(n.maxLng=r)}return n}const _e1=({diff:e,fetchCache:t,bboxFromOsmPatch:n})=>{const i=G.useRef(null),r=G.useMemo(()=>ye1(e,t,n),[e,t,n]);return Object.values(r).some(a=>!Number.isFinite(a))?R.jsx(R.Fragment,{children:"No preview available"}):R.jsxs(jE,{style:{width:500,height:500,margin:"auto"},scrollWheelZoom:!0,ref:a=>a==null?void 0:a.fitBounds(new A5.LatLngBounds([r.minLat,r.minLng],[r.maxLat,r.maxLng])),children:[R.jsx(HE,{}),R.jsx(I11,{ref:i,children:R.jsx(DE,{positions:[[r.maxLat,r.minLng],[r.maxLat,r.maxLng],[r.minLat,r.maxLng],[r.minLat,r.minLng]]})})]})};function*we1(e,t){for(let n=0;n!(t!=null&&t[a[0]+f]));for(const f of we1(u,100)){console.log(`Fetching ${f.length} ${a}s...`);const d=await B4.getFeatures(a,f);for(const p of d){const m=p.type[0]+p.id;n[m]=p}}}return{...t,...n}}function xe1(e,t){const n=window.URL.createObjectURL(e),i=document.createElement("a");i.href=n,i.download=t,document.body.append(i),i.click(),window.URL.revokeObjectURL(n),setTimeout(()=>i.remove(),0)}async function be1(e,t){var a,u,f,d,p,m,h,v,S,E;const n={added:{},removed:{},featureDeleted:{},changed:{}};for(const k of e.create)if(k.tags)for(const O in k.tags){const x=k.tags[O];(a=n.added)[O]||(a[O]={}),(u=n.added[O])[x]||(u[x]=0),n.added[O][x]+=1}for(const k of e.delete)if(k.tags)for(const O in k.tags){const x=k.tags[O];(f=n.featureDeleted)[O]||(f[O]={}),(d=n.featureDeleted[O])[x]||(d[x]=0),n.featureDeleted[O][x]+=1}const i=e.modify.reduce((k,O)=>({...k,[O.type]:[...k[O.type],O.id]}),{node:[],way:[],relation:[]}),r=await Td(i,t);for(const k of e.modify){const O=r[k.type[0]+k.id].tags||{},x=k.tags||{},w=Object.keys({...O,...x});for(const b of w)if(x[b]&&!O[b]){const N=x[b];(p=n.added)[b]||(p[b]={}),(m=n.added[b])[N]||(m[N]=0),n.added[b][N]+=1}else if(!x[b]&&O[b]){const N=O[b];(h=n.removed)[b]||(h[b]={}),(v=n.removed[b])[N]||(v[N]=0),n.removed[b][N]+=1}else if(x[b]!==O[b]){const N=`${O[b]} ~~> ${x[b]}`;(S=n.changed)[b]||(S[b]={}),(E=n.changed[b])[N]||(E[N]=0),n.changed[b][N]+=1}}return n}const l8=(e,t)=>Object.entries(e).map(([n,i])=>{const r=Object.entries(i);let a,u;return r.length>1?r.every(([,d])=>d===1)?(u=r.map(([d],p)=>R.jsxs(G.Fragment,{children:[!!p&&"/",R.jsx("code",{children:d})]},d)),a=` (${r.length})`):(u=R.jsx("ul",{children:r.map(([d,p])=>R.jsxs("li",{children:[R.jsx("code",{children:d})," ",p>1&&`(${p})`]},d))}),a=""):(u=R.jsx("code",{children:r[0][0]}),a=` (${r[0][1]})`),R.jsxs("li",{className:t,children:[t,a," ",R.jsxs("code",{children:[n,"="]}),u]},t+n)}),Se1=({diff:e,fetchCache:t})=>{const[n,i]=G.useState(),[r,a]=G.useState();return G.useEffect(()=>{be1(e,t).then(a).catch(i)},[e,t]),n?R.jsx(R.Fragment,{children:"Failed to calculate tag changes"}):r?Object.values(r).every(f=>!Object.keys(f).length)?R.jsx("div",{className:"alert error",children:"No tags changed!"}):R.jsxs("ul",{className:"tagChanges",children:[l8(r.added,"Added"),l8(r.changed,"Changed"),l8(r.removed,"Removed"),l8(r.featureDeleted,"Deleted")]}):R.jsx(R.Fragment,{children:"Loading tag changes..."})},Ee1=({diff:e})=>R.jsxs("div",{style:{padding:4,color:"#fff"},children:[R.jsxs("span",{style:{background:"#4caf50",padding:4},children:["+",e.create.length]}),R.jsx("span",{style:{background:"#ff9800",padding:4},children:e.modify.length}),R.jsxs("span",{style:{background:"#f44336",padding:4},children:["-",e.delete.length]})]}),P8={n:"node",w:"way",r:"relation"};window.structuredClone||(window.structuredClone=e=>JSON.parse(JSON.stringify(e)));const Pd={changeset:-1,timestamp:"",uid:-1,user:"",version:0},Me1={source_ref:{"http://www.nzopengps.org/":!0,"http://www.linz.govt.nz/topography/topo-maps/":!0,"http://www.linz.govt.nz/topography/topo-maps/index.aspx":!0,"http://www.linz.govt.nz/about-linz/linz-data-service/dataset-information":!0},attribution:{"http://wiki.osm.org/wiki/Attribution#LINZ":!0,"http://wiki.openstreetmap.org/wiki/Attribution#LINZ":!0,"http://www.aucklandcouncil.govt.nz/EN/ratesbuildingproperty/propertyinformation/GIS_maps/Pages/opendata.aspx":!0},"linz2osm:objectid":!0,"LINZ2OSM:dataset":!0,"LINZ2OSM:layer":!0,"LINZ:layer":!0,"LINZ2OSM:source_version":!0,"LINZ:source_version":!0,"LINZ:dataset":!0,"brand:wikipedia":!0,"operator:wikipedia":!0,"network:wikipedia":!0},Dn={node:-1,way:-1,relation:-1},ku=e=>({...Pd,type:"node",id:Dn.node--,lat:e[1],lon:e[0]});function Ae1(e,t,n){switch(e.type){case"Point":return[{...t,type:"node",id:Dn.node--,lat:e.coordinates[1],lon:e.coordinates[0]}];case"MultiPoint":{const i=e.coordinates.map(ku);return[{...t,tags:{...t.tags,type:"site"},type:"relation",id:Dn.relation--,members:i.map(r=>({role:"",type:r.type,ref:r.id}))},...i]}case"LineString":{const i=e.coordinates.map(ku);return[{...t,type:"way",id:Dn.way--,nodes:i.map(r=>r.id)},...i]}case"MultiLineString":{const i=[],r=[];for(const u of e.coordinates){const f=u.map(ku);i.push({...Pd,type:"way",id:Dn.way--,nodes:f.map(d=>d.id)}),r.push(...f)}return[{...t,tags:{...t.tags,type:"multilinestring"},type:"relation",id:Dn.relation--,members:i.map(u=>({role:"",type:u.type,ref:u.id}))},...i,...r]}case"GeometryCollection":return[{...t,type:"relation",id:Dn.relation--,members:n}];case"Polygon":case"MultiPolygon":return;default:return}}function ov(e,t){const n=structuredClone(e);n.tags||(n.tags={});for(const[r,a]of Object.entries(t))a==="🗑️"?delete n.tags[r]:n.tags[r]=a;const i=Object.keys(n.tags).some(r=>r.startsWith("ref:linz:"));for(const[r,a]of Object.entries(n.tags)){const u=Me1[r];(u===!0||u!=null&&u[a])&&(delete n.tags[r],r==="source_ref"&&!n.tags.source&&!i&&!n.tags.building&&(n.tags.source="LINZ"))}return n}function ke1(e,t){let n=structuredClone(e.members);for(const i of t){const r=n.findIndex(a=>a.type===i.type&&a.ref===i.ref);n=n.filter(a=>!(a.type===i.type&&a.ref===i.ref)),i.role==="🗑️"||(r===-1?n.push(i):n.splice(r,0,i))}return n}async function Te1(e){const t={create:[],delete:[],modify:[]},n={node:[],way:[],relation:[]};for(const a of e.features)if(a.properties.__action){const u=P8[a.id[0]],f=+a.id.slice(1);n[u].push(f)}const i=await Td(n);for(const a of e.features){const{__action:u,__members:f,...d}=a.properties;switch(u){case"edit":{const p=ov(i[a.id],d);p.type==="relation"&&f&&(p.members=ke1(p,f)),t.modify.push(p);break}case"move":{const p=ov(i[a.id],d);if(p.type!=="node"||a.geometry.type!=="LineString")throw new Error("trying to move a non-node");const[m,h]=a.geometry.coordinates[1];p.lat=h,p.lon=m,t.modify.push(p);break}case"delete":{t.delete.push(i[a.id]);break}default:{const p=Ae1(a.geometry,{...Pd,tags:d},f);p?t.create.push(...p):console.warn(`Can't create a ${a.geometry.type}`)}}}const r=ve1(e);return{osmChange:t,fetched:i,bbox:r}}function un(){}un.prototype={diff:function(t,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=i.callback;typeof i=="function"&&(r=i,i={}),this.options=i;var a=this;function u(k){return r?(setTimeout(function(){r(void 0,k)},0),!0):k}t=this.castInput(t),n=this.castInput(n),t=this.removeEmpty(this.tokenize(t)),n=this.removeEmpty(this.tokenize(n));var f=n.length,d=t.length,p=1,m=f+d;i.maxEditLength&&(m=Math.min(m,i.maxEditLength));var h=[{newPos:-1,components:[]}],v=this.extractCommon(h[0],n,t,0);if(h[0].newPos+1>=f&&v+1>=d)return u([{value:this.join(n),count:n.length}]);function S(){for(var k=-1*p;k<=p;k+=2){var O=void 0,x=h[k-1],w=h[k+1],b=(w?w.newPos:0)-k;x&&(h[k-1]=void 0);var N=x&&x.newPos+1=f&&b+1>=d)return u(Pe1(a,O.components,n,t,a.useLongestToken));h[k]=O}p++}if(r)(function k(){setTimeout(function(){if(p>m)return r();S()||k()},0)})();else for(;p<=m;){var E=S();if(E)return E}},pushComponent:function(t,n,i){var r=t[t.length-1];r&&r.added===n&&r.removed===i?t[t.length-1]={count:r.count+1,added:n,removed:i}:t.push({count:1,added:n,removed:i})},extractCommon:function(t,n,i,r){for(var a=n.length,u=i.length,f=t.newPos,d=f-r,p=0;f+1S.length?k:S}),p.value=e.join(m)}else p.value=e.join(n.slice(f,f+p.count));f+=p.count,p.added||(d+=p.count)}}var v=t[u-1];return u>1&&typeof v.value=="string"&&(v.added||v.removed)&&e.equals("",v.value)&&(t[u-2].value+=v.value,t.pop()),t}function Ce1(e){return{newPos:e.newPos,components:e.components.slice(0)}}var av=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,sv=/\S/,XE=new un;XE.equals=function(e,t){return this.options.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e===t||this.options.ignoreWhitespace&&!sv.test(e)&&!sv.test(t)};XE.tokenize=function(e){for(var t=e.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),n=0;n"u"?n:u}:i;return typeof e=="string"?e:JSON.stringify(gc(e,null,null,r),r," ")};f9.equals=function(e,t){return un.prototype.equals.call(f9,e.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"))};function gc(e,t,n,i,r){t=t||[],n=n||[],i&&(e=i(r,e));var a;for(a=0;ae.role?`${e.type[0]}${e.ref} as “${e.role}”`:`${e.type[0]}${e.ref}`;async function Ie1(e,t){var a,u;const n=e.modify.reduce((f,d)=>({...f,[d.type]:[...f[d.type],d.id]}),{node:[],way:[],relation:[]}),i=await Td(n,t),r={};for(const f of[...e.modify,...e.create]){const d=f.type[0]+f.id,p=i[d];if(f.type==="relation"&&((a=f.tags)==null?void 0:a.type)!=="multipolygon"){const m=((u=p==null?void 0:p.members)==null?void 0:u.map(uv).join(` -`))||"",h=f.members.map(uv).join(` -`);r[d]=Ne1(`${m} -`,`${h} -`)}}return r}const Re1=({diff:e,fetchCache:t})=>{var p;const[n,i]=G.useState(),[r,a]=G.useState(0);G.useEffect(()=>{Ie1(e,t).catch(()=>{}).then(i)},[e,t]);const u=Object.keys(n||{});if(n&&u.length===0)return null;const f=u[r],d=((p=t==null?void 0:t[f])==null?void 0:p.tags)||{};return R.jsxs(R.Fragment,{children:[R.jsx("br",{}),R.jsx("br",{}),R.jsx("strong",{children:"Changed Relation Members:"}),R.jsx("br",{}),n?R.jsxs(R.Fragment,{children:[R.jsx("button",{type:"button",onClick:()=>a(m=>m-1),disabled:!r,children:"⬅️"}),r+1,"/",u.length,R.jsx("button",{type:"button",onClick:()=>a(m=>m+1),disabled:r===u.length-1,children:"➡️"}),R.jsx("br",{}),R.jsx("strong",{children:d.name||d.ref||"No Name"}),R.jsx("br",{}),R.jsx("pre",{children:n[f].map((m,h)=>{const v=h+m.value;return m.added?R.jsx("span",{className:"diff-add",children:m.value},v):m.removed?R.jsx("span",{className:"diff-remove",children:m.value},v):m.value})})]}):"Loading…"]})},lv={attribution:"https://wiki.openstreetmap.org/wiki/Contributors#LINZ",created_by:"LINZ Data Import 2.0.0",locale:navigator.language,source:"https://wiki.osm.org/LINZ",comment:""};function cv(e){try{return Object.fromEntries(e.split(` -`).map(t=>{if(!t)return[];const[n,i]=t.split("=");return[n.trim(),i]}).filter(([t,n])=>t&&n))}catch{return}}const c8=e=>Object.entries(e).map(t=>t.join("=")).join(` -`),Ue1=()=>{const{user:e,logout:t}=G.useContext(kd),[n,i]=G.useState(!1),[r,a]=G.useState(),[u,f]=G.useState(),[d,p]=G.useState(c8(lv)),[m,h]=G.useState(),[v,S]=G.useState(),[E,k]=G.useState(),[O,x]=G.useState([]),[w,b]=G.useState(),N=G.useRef(null),$=cv(d);async function I(Y){if(!(Y!=null&&Y.length))return x([]),h(void 0);try{if(k(Y[0].name),[...Y].some(V=>V.name.endsWith(".osc"))){if(Y.length>1)throw new Error("Only 1 osmChange file can be uploaded at a time. Multiple osmPatch files are allowed");const V=await Y[0].text(),p1=B4.parseOsmChangeXml(V);return h(p1)}const D=[];for(const V of Y)D.push(me1(await V.text()));const J=D.length===1?D[0]:{...D[0],features:D.flatMap(V=>V.features)},e1={};for(const V of D)if(V.changesetTags)for(const[p1,f1]of Object.entries(V.changesetTags))if(e1[p1]){const w1=new Set(e1[p1].split(";"));w1.add(f1),e1[p1]=[...w1].join(";")}else e1[p1]=f1;Object.keys(e1).length&&(e1.created_by||(e1.created_by=lv.created_by),p(c8(e1)));const o1=new Set(D.map(V=>V.instructions||""));o1.delete(""),x([...o1]);const{osmChange:i1,fetched:l1,bbox:r1}=await Te1(J);return S(l1),b(r1),h(i1)}catch(H){return console.error(H),a(H instanceof Error?H:new Error(`${H}`))}}async function j(){f(void 0),a(void 0),i(!0);try{f(await B4.uploadChangeset($,m)),h(void 0),console.log("Uploaded!")}catch(Y){console.error(Y),a(Y instanceof Error?Y:new Error(`${Y}`))}i(!1)}function B(){const Y=B4.createOsmChangeXml(-1,m),H=new Blob([Y],{type:"application/xml"});xe1(H,`${E==null?void 0:E.split(".")[0]}.osc`)}return n?R.jsx("h2",{className:"upload-root",children:"Uploading..."}):R.jsxs("div",{className:"upload-root",children:[r&&R.jsx("div",{className:"alert error",children:r.message}),u&&R.jsxs("div",{className:"alert",children:["Uploaded! ",R.jsx("a",{href:`https://osm.org/changeset/${u}`,children:u})]}),(r||u)&&R.jsxs(R.Fragment,{children:[R.jsx("br",{}),R.jsx("br",{})]}),"Logged in as ",R.jsx("code",{children:e.display_name}),"."," ",R.jsx("button",{type:"button",onClick:t,children:"Logout"}),R.jsx("br",{}),R.jsx("br",{}),R.jsx("strong",{children:"Upload osmChange or osmPatch file:"}),R.jsx("br",{}),R.jsx("input",{type:"file",accept:".osc,.osmPatch.geo.json,.geo.json",multiple:!0,onChange:Y=>I(Y.target.files),ref:N}),m&&R.jsx("button",{type:"button",onClick:()=>{N.current.value="",h(void 0)},children:"Clear"}),R.jsx("br",{}),R.jsx("br",{}),R.jsx("strong",{children:"Changeset Tags:"}),R.jsx("br",{}),R.jsx("input",{value:($==null?void 0:$.comment)||"",onChange:Y=>{p(c8({...$,comment:Y.target.value}))},placeholder:"Changeset Comment",style:{width:500}}),R.jsx("br",{}),R.jsx("textarea",{value:d,onChange:Y=>p(Y.target.value),onBlur:Y=>{const H=cv(Y.target.value);H&&p(c8(H))},style:{width:500,height:200,color:$?"black":"red"}}),R.jsx("br",{}),R.jsx("br",{}),m?R.jsxs(R.Fragment,{children:[R.jsx(Ee1,{diff:m}),R.jsx("strong",{children:"Approximate Extent of nodes:"}),R.jsx("br",{}),R.jsx(_e1,{diff:m,fetchCache:v,bboxFromOsmPatch:w}),R.jsx("br",{}),R.jsx("br",{}),R.jsx("strong",{children:"Tag Changes:"}),R.jsx("br",{}),R.jsx(Se1,{diff:m,fetchCache:v}),R.jsx(Re1,{diff:m,fetchCache:v}),R.jsx("br",{}),R.jsx("br",{}),!!O.length&&R.jsxs(R.Fragment,{children:[O.map(Y=>R.jsxs("div",{children:["⚠️ ",Y]},Y)),R.jsx("br",{}),R.jsx("br",{})]}),R.jsx("button",{type:"button",onClick:j,disabled:!($!=null&&$.comment),style:{fontSize:32},children:"Upload"}),R.jsx("button",{type:"button",onClick:B,style:{fontSize:32},children:"Download as .osc"})]}):R.jsxs(R.Fragment,{children:["Upload a ",R.jsx("code",{children:".osc"})," or ",R.jsx("code",{children:".osmPatch.geo.json"})," file to see the remaining options"]})]})},$e1=()=>R.jsx(qE,{children:R.jsx(Ue1,{})}),Be1=()=>R.jsx(R.Fragment,{children:"Hello!"}),ze1=window.location.origin+window.location.pathname+window.location.hash;async function je1(e){return B4.uploadChangeset({comment:"Restore deleted features",created_by:"HistoryRestorer",host:ze1},{create:[],modify:e.map(t=>({...t.newFeature,id:t.oldId,version:t.oldVersion})),delete:e.map(t=>t.newFeature)})}const De1=fetch("https://cdn.jsdelivr.net/gh/openstreetmap/id-tagging-schema@main/dist/presets.min.json").then(e=>e.json()),Qe1=fetch("https://cdn.jsdelivr.net/gh/openstreetmap/id-tagging-schema@main/dist/translations/en.min.json").then(e=>e.json());async function fv(e){var a,u;if(!e)return"No Tags";const[t,n]=[await De1,await Qe1],i=[];for(const f in t){const{matchScore:d,tags:p}=t[f];!!Object.keys(p).length&&Object.entries(p).every(([h,v])=>h in e&&(v==="*"||v===e[h]))&&i.push({presetId:f,matchScore:(d??1)+Object.values(p).filter(h=>h!=="*").length/10})}i.sort((f,d)=>d.matchScore-f.matchScore);const r=(a=i[0])==null?void 0:a.presetId;return((u=n.en.presets.presets[r])==null?void 0:u.name)||"Unknown"}const dv=e=>(e==null?void 0:e.name)||(e==null?void 0:e.ref)||(e==null?void 0:e.official_name)||(e==null?void 0:e.alt_name)||(e==null?void 0:e.loc_name)||(e==null?void 0:e["addr:housename"])||(e==null?void 0:e["seamark:name"]);async function We1(e){if(!e.length)throw new Error("No data entered");if(e.some(r=>!r.fromId||!r.toId))throw new Error("Some fields are blank");const t={node:e.filter(r=>r.type==="n").map(r=>r.toId),way:e.filter(r=>r.type==="w").map(r=>r.toId),relation:e.filter(r=>r.type==="r").map(r=>r.toId)};for(const r of e){const a=P8[r.type],u=await B4.getFeatureHistory(a,r.fromId),f=u.at(-1),d=u.at(-2);if(f.visible!==!1)throw new Error(`${a} ${r.fromId} is not deleted`);t[a].push(`${r.fromId}v${d.version}`)}const n=[];for(const r in t){const a=t[r];a.length&&n.push(...await B4.getFeatures(r,a))}const i={};return Promise.all(e.map(async r=>{let a=!1;i[r.type+r.fromId]&&(a="Duplicate deleted feature"),i[r.type+r.toId]&&(a="Duplicate new feature");const u=n.find(d=>d.type===P8[r.type]&&d.id===r.fromId);u||(a="Invalid old feature");const f=n.find(d=>d.type===P8[r.type]&&d.id===r.toId);return f||(a="Invalid new feature"),{oldPreset:await fv(u==null?void 0:u.tags),oldName:dv(u==null?void 0:u.tags),newPreset:await fv(f==null?void 0:f.tags),newName:dv(f==null?void 0:f.tags),newFeature:f,oldId:u==null?void 0:u.id,oldVersion:((u==null?void 0:u.version)??-2)+1,error:a}}))}const He1="_main_gt6g9_1",Ze1="_list_gt6g9_7",Ge1="_item_gt6g9_11",qe1="_error_gt6g9_21",Ve1="_btn_gt6g9_25",Ye1="_smallInput_gt6g9_34",Xe1="_saveBtn_gt6g9_41",jt={main:He1,list:Ze1,item:Ge1,error:qe1,btn:Ve1,smallInput:Ye1,saveBtn:Xe1},Tu=()=>({type:"n"}),hv=({value:e,onChange:t})=>R.jsxs("select",{className:jt.smallInput,value:e,onChange:n=>t(n.target.value),children:[R.jsx("option",{value:"n",children:"Node"}),R.jsx("option",{value:"w",children:"Way"}),R.jsx("option",{value:"r",children:"Relation"})]}),Ke1=()=>{const{user:e,logout:t}=G.useContext(kd),[n,i]=G.useState([Tu()]),[r,a]=G.useState(0),[u,f]=G.useState(),[d,p]=G.useState(!1),[m,h]=G.useState();function v(E,k,O){i(x=>x.map((w,b)=>E===b?{...w,[k]:O}:w)),f(void 0)}async function S(){p(!0);try{u?h(await je1(u)):f(await We1(n))}catch(E){console.error(E),alert(`${E}`)}p(!1)}return m?R.jsxs("div",{className:jt.main,children:[R.jsx("a",{href:`${B4.getConfig().apiUrl}/changeset/${m}`,target:"_blank",rel:"noopener noreferrer",children:"Done!"}),R.jsx("br",{}),R.jsx("br",{}),R.jsx("button",{type:"button",className:jt.btn,onClick:()=>{i([Tu()]),f(void 0),h(void 0),a(E=>E+1)},children:"Back"})]}):R.jsxs("div",{className:jt.main,children:[R.jsx("h2",{children:"Restore OSM History"}),R.jsxs("p",{children:["If an OSM Feature was deleted and redrawn, you can restore the history of the original feature using this tool.",R.jsx("br",{}),R.jsx("br",{}),R.jsx("a",{href:"https://wiki.osm.org/HistoryRestorer",target:"_blank",rel:"noopener noreferrer",children:"Wiki"})," ","|"," ",R.jsx("a",{href:"https://github.com/osm-nz/osm-nz.github.io/tree/main/src/pages/HistoryRestorer",target:"_blank",rel:"noopener noreferrer",children:"Source Code"}),R.jsx("br",{}),R.jsx("br",{})]}),R.jsxs("div",{className:jt.list,children:[R.jsxs("div",{className:jt.item,children:[R.jsx("strong",{children:"Deleted Feature"}),R.jsx("strong",{children:"New Feature"})]},0),n.map((E,k)=>{const O=u==null?void 0:u[k];return R.jsxs("div",{className:jt.item,children:[R.jsxs("div",{children:[R.jsx(hv,{value:E.type,onChange:x=>v(k,"type",x)}),R.jsx("input",{className:jt.smallInput,type:"tel",value:E.fromId||"",onChange:x=>v(k,"fromId",+x.target.value)}),O&&R.jsxs("small",{children:[R.jsx("br",{}),R.jsx("strong",{children:O.oldPreset}),"   ",O.oldName,O.error&&R.jsxs("span",{className:jt.error,children:[R.jsx("br",{}),O.error]})]})]}),R.jsx("div",{children:"➡️"}),R.jsxs("div",{children:[R.jsx(hv,{value:E.type,onChange:x=>v(k,"type",x)}),R.jsx("input",{className:jt.smallInput,type:"tel",value:E.toId||"",onChange:x=>v(k,"toId",+x.target.value)}),O&&R.jsxs("small",{children:[R.jsx("br",{}),R.jsx("strong",{children:O.newPreset}),"   ",O.newName]})]}),R.jsx("div",{children:R.jsx("button",{type:"button",disabled:n.length===1,className:`${jt.btn} ${jt.smallInput}`,onClick:()=>{a(x=>x+1),f(void 0),i(x=>{const w=[...x];return w.splice(k,1),w})},children:"🗑️"})})]},r+k)})]}),R.jsx("br",{}),R.jsx("button",{type:"button",className:jt.btn,onClick:()=>{i(E=>[...E,Tu()]),f(void 0)},children:"Add Another feature"}),R.jsx("br",{}),R.jsx("br",{}),d&&R.jsx(R.Fragment,{children:"Loading..."}),R.jsx("button",{type:"submit",disabled:d,onClick:S,className:`${jt.btn} ${u?jt.saveBtn:""}`,children:u?"Save":"Next"}),R.jsx("br",{}),R.jsx("br",{}),"Logged in as ",R.jsx("code",{children:e.display_name}),"."," ",R.jsx("a",{onClick:t,children:"Logout"})]})},Je1=()=>R.jsx(qE,{children:R.jsx(Ke1,{})});const pv=()=>window.location.hash.slice(1),et1=()=>{const[e,t]=G.useState(pv());return G.useEffect(()=>{const n=()=>t(pv());return window.addEventListener("popstate",n),()=>window.removeEventListener("popstate",n)},[]),e==="/whatsup"?R.jsx(Be1,{}):e==="/upload"?R.jsx($e1,{}):e==="/map"?R.jsx(de1,{}):e==="/restore-history"?R.jsx(Je1,{}):e==="/address-import"?R.jsx(x11,{}):R.jsx(b11,{})};Tw(document.querySelector("main")).render(R.jsx(G.StrictMode,{children:R.jsx(et1,{})})); diff --git a/index.html b/index.html index 2b43741..9ca6c35 100644 --- a/index.html +++ b/index.html @@ -5,8 +5,8 @@ - - + +