From 99e1f4b9468546b0f66b3d342e712b83d99a219d Mon Sep 17 00:00:00 2001 From: keksobot Date: Sat, 30 Nov 2024 09:49:32 +0000 Subject: [PATCH] =?UTF-8?q?=E2=9C=94=EF=B8=8F=20=D0=A1=D0=B1=D0=BE=D1=80?= =?UTF-8?q?=D0=BA=D0=B0=20#11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../{index-075ca663.js => index-90f60a76.js} | 40 +++++++++---------- 11/index.html | 2 +- 2 files changed, 21 insertions(+), 21 deletions(-) rename 11/assets/{index-075ca663.js => index-90f60a76.js} (70%) diff --git a/11/assets/index-075ca663.js b/11/assets/index-90f60a76.js similarity index 70% rename from 11/assets/index-075ca663.js rename to 11/assets/index-90f60a76.js index ed935fe..378c56e 100644 --- a/11/assets/index-075ca663.js +++ b/11/assets/index-90f60a76.js @@ -1,4 +1,4 @@ -function h0(e,t){for(var n=0;ni[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const a of s)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(s){const a={};return s.integrity&&(a.integrity=s.integrity),s.referrerPolicy&&(a.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?a.credentials="include":s.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function i(s){if(s.ep)return;s.ep=!0;const a=n(s);fetch(s.href,a)}})();var p0=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function $o(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Am={exports:{}},Ia={},jm={exports:{}},Y={};/** +function p0(e,t){for(var n=0;ni[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const a of s)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(s){const a={};return s.integrity&&(a.integrity=s.integrity),s.referrerPolicy&&(a.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?a.credentials="include":s.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function i(s){if(s.ep)return;s.ep=!0;const a=n(s);fetch(s.href,a)}})();var m0=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Uo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var jm={exports:{}},Ia={},bm={exports:{}},Y={};/** * @license React * react.production.min.js * @@ -6,7 +6,7 @@ function h0(e,t){for(var n=0;n>>1,ae=z[K];if(0>>1;Ks(se,D))les(Xe,se)?(z[K]=Xe,z[le]=D,K=le):(z[K]=se,z[de]=D,K=de);else if(les(Xe,D))z[K]=Xe,z[le]=D,K=le;else break e}}return q}function s(z,q){var D=z.sortIndex-q.sortIndex;return D!==0?D:z.id-q.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,g=null,y=3,C=!1,x=!1,P=!1,R=typeof setTimeout=="function"?setTimeout:null,S=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 T(z){for(var q=n(p);q!==null;){if(q.callback===null)i(p);else if(q.startTime<=z)i(p),q.sortIndex=q.expirationTime,t(d,q);else break;q=n(p)}}function N(z){if(P=!1,T(z),!x)if(n(d)!==null)x=!0,Fe(I);else{var q=n(p);q!==null&&nn(N,q.startTime-z)}}function I(z,q){x=!1,P&&(P=!1,S(Z),Z=-1),C=!0;var D=y;try{for(T(q),g=n(d);g!==null&&(!(g.expirationTime>q)||z&&!X());){var K=g.callback;if(typeof K=="function"){g.callback=null,y=g.priorityLevel;var ae=K(g.expirationTime<=q);q=e.unstable_now(),typeof ae=="function"?g.callback=ae:g===n(d)&&i(d),T(q)}else i(d);g=n(d)}if(g!==null)var ze=!0;else{var de=n(p);de!==null&&nn(N,de.startTime-q),ze=!1}return ze}finally{g=null,y=D,C=!1}}var U=!1,F=null,Z=-1,re=5,W=-1;function X(){return!(e.unstable_now()-Wz||125K?(z.sortIndex=D,t(p,z),n(d)===null&&z===n(p)&&(P?(S(Z),Z=-1):P=!0,nn(N,D-K))):(z.sortIndex=ae,t(d,z),x||C||(x=!0,Fe(I))),z},e.unstable_shouldYield=X,e.unstable_wrapCallback=function(z){var q=y;return function(){var D=y;y=q;try{return z.apply(this,arguments)}finally{y=D}}}})(Vm);Wm.exports=Vm;var I0=Wm.exports;/** + */(function(e){function t(z,q){var D=z.length;z.push(q);e:for(;0>>1,ae=z[K];if(0>>1;Ks(se,D))les(Xe,se)?(z[K]=Xe,z[le]=D,K=le):(z[K]=se,z[de]=D,K=de);else if(les(Xe,D))z[K]=Xe,z[le]=D,K=le;else break e}}return q}function s(z,q){var D=z.sortIndex-q.sortIndex;return D!==0?D:z.id-q.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,g=null,y=3,C=!1,x=!1,P=!1,R=typeof setTimeout=="function"?setTimeout:null,S=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 T(z){for(var q=n(p);q!==null;){if(q.callback===null)i(p);else if(q.startTime<=z)i(p),q.sortIndex=q.expirationTime,t(d,q);else break;q=n(p)}}function N(z){if(P=!1,T(z),!x)if(n(d)!==null)x=!0,Fe(I);else{var q=n(p);q!==null&&nn(N,q.startTime-z)}}function I(z,q){x=!1,P&&(P=!1,S(Z),Z=-1),C=!0;var D=y;try{for(T(q),g=n(d);g!==null&&(!(g.expirationTime>q)||z&&!X());){var K=g.callback;if(typeof K=="function"){g.callback=null,y=g.priorityLevel;var ae=K(g.expirationTime<=q);q=e.unstable_now(),typeof ae=="function"?g.callback=ae:g===n(d)&&i(d),T(q)}else i(d);g=n(d)}if(g!==null)var ze=!0;else{var de=n(p);de!==null&&nn(N,de.startTime-q),ze=!1}return ze}finally{g=null,y=D,C=!1}}var U=!1,F=null,Z=-1,re=5,W=-1;function X(){return!(e.unstable_now()-Wz||125K?(z.sortIndex=D,t(p,z),n(d)===null&&z===n(p)&&(P?(S(Z),Z=-1):P=!0,nn(N,D-K))):(z.sortIndex=ae,t(d,z),x||C||(x=!0,Fe(I))),z},e.unstable_shouldYield=X,e.unstable_wrapCallback=function(z){var q=y;return function(){var D=y;y=q;try{return z.apply(this,arguments)}finally{y=D}}}})(Km);Vm.exports=Km;var D0=Vm.exports;/** * @license React * react-dom.production.min.js * @@ -30,14 +30,14 @@ function h0(e,t){for(var n=0;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ac=Object.prototype.hasOwnProperty,D0=/^[: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]*$/,Ih={},Dh={};function B0(e){return ac.call(Dh,e)?!0:ac.call(Ih,e)?!1:D0.test(e)?Dh[e]=!0:(Ih[e]=!0,!1)}function F0(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 $0(e,t,n,i){if(t===null||typeof t>"u"||F0(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 Je(e,t,n,i,s,a,u){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=i,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=u}var Ze={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ze[e]=new Je(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ze[t]=new Je(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ze[e]=new Je(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ze[e]=new Je(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){Ze[e]=new Je(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ze[e]=new Je(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ze[e]=new Je(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ze[e]=new Je(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ze[e]=new Je(e,5,!1,e.toLowerCase(),null,!1,!1)});var wf=/[\-:]([a-z])/g;function xf(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(wf,xf);Ze[t]=new Je(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(wf,xf);Ze[t]=new Je(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(wf,xf);Ze[t]=new Je(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ze[e]=new Je(e,1,!1,e.toLowerCase(),null,!1,!1)});Ze.xlinkHref=new Je("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ze[e]=new Je(e,1,!1,e.toLowerCase(),null,!0,!0)});function Sf(e,t,n,i){var s=Ze.hasOwnProperty(t)?Ze[t]:null;(s!==null?s.type!==0:i||!(2"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ac=Object.prototype.hasOwnProperty,B0=/^[: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]*$/,Dh={},Bh={};function F0(e){return ac.call(Bh,e)?!0:ac.call(Dh,e)?!1:B0.test(e)?Bh[e]=!0:(Dh[e]=!0,!1)}function $0(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 U0(e,t,n,i){if(t===null||typeof t>"u"||$0(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 Je(e,t,n,i,s,a,u){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=i,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=u}var Ze={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ze[e]=new Je(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ze[t]=new Je(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ze[e]=new Je(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ze[e]=new Je(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){Ze[e]=new Je(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ze[e]=new Je(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ze[e]=new Je(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ze[e]=new Je(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ze[e]=new Je(e,5,!1,e.toLowerCase(),null,!1,!1)});var wf=/[\-:]([a-z])/g;function xf(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(wf,xf);Ze[t]=new Je(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(wf,xf);Ze[t]=new Je(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(wf,xf);Ze[t]=new Je(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ze[e]=new Je(e,1,!1,e.toLowerCase(),null,!1,!1)});Ze.xlinkHref=new Je("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ze[e]=new Je(e,1,!1,e.toLowerCase(),null,!0,!0)});function Sf(e,t,n,i){var s=Ze.hasOwnProperty(t)?Ze[t]:null;(s!==null?s.type!==0:i||!(2f||s[u]!==a[f]){var d=` -`+s[u].replace(" at new "," at ");return e.displayName&&d.includes("")&&(d=d.replace("",e.displayName)),d}while(1<=u&&0<=f);break}}}finally{yu=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?io(e):""}function U0(e){switch(e.tag){case 5:return io(e.type);case 16:return io("Lazy");case 13:return io("Suspense");case 19:return io("SuspenseList");case 0:case 2:case 15:return e=wu(e.type,!1),e;case 11:return e=wu(e.type.render,!1),e;case 1:return e=wu(e.type,!0),e;default:return""}}function fc(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 Wr:return"Fragment";case Hr:return"Portal";case lc:return"Profiler";case Pf:return"StrictMode";case uc:return"Suspense";case cc:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Qm:return(e.displayName||"Context")+".Consumer";case Gm:return(e._context.displayName||"Context")+".Provider";case Ef:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Tf:return t=e.displayName||null,t!==null?t:fc(e.type)||"Memo";case Mn:t=e._payload,e=e._init;try{return fc(e(t))}catch{}}return null}function Z0(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 fc(t);case 8:return t===Pf?"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 Gn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Jm(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function H0(e){var t=Jm(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 s=n.get,a=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.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 Ps(e){e._valueTracker||(e._valueTracker=H0(e))}function Xm(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=Jm(e)?e.checked?"true":"false":e.value),e=i,e!==n?(t.setValue(e),!0):!1}function na(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 dc(e,t){var n=t.checked;return xe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Fh(e,t){var n=t.defaultValue==null?"":t.defaultValue,i=t.checked!=null?t.checked:t.defaultChecked;n=Gn(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 e_(e,t){t=t.checked,t!=null&&Sf(e,"checked",t,!1)}function hc(e,t){e_(e,t);var n=Gn(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")?pc(e,t.type,n):t.hasOwnProperty("defaultValue")&&pc(e,t.type,Gn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function $h(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 pc(e,t,n){(t!=="number"||na(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var oo=Array.isArray;function ri(e,t,n,i){if(e=e.options,t){t={};for(var s=0;s"+t.valueOf().toString()+"",t=Es.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function wo(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var uo={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},W0=["Webkit","ms","Moz","O"];Object.keys(uo).forEach(function(e){W0.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),uo[t]=uo[e]})});function i_(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||uo.hasOwnProperty(e)&&uo[e]?(""+t).trim():t+"px"}function o_(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var i=n.indexOf("--")===0,s=i_(n,t[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,s):e[n]=s}}var V0=xe({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 vc(e,t){if(t){if(V0[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(b(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(b(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(b(61))}if(t.style!=null&&typeof t.style!="object")throw Error(b(62))}}function gc(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 yc=null;function Cf(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var wc=null,ii=null,oi=null;function Hh(e){if(e=Wo(e)){if(typeof wc!="function")throw Error(b(280));var t=e.stateNode;t&&(t=Ua(t),wc(e.stateNode,e.type,t))}}function s_(e){ii?oi?oi.push(e):oi=[e]:ii=e}function a_(){if(ii){var e=ii,t=oi;if(oi=ii=null,Hh(e),t)for(e=0;e>>=0,e===0?32:31-(rw(e)/iw|0)|0}var Ts=64,Cs=4194304;function so(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 sa(e,t){var n=e.pendingLanes;if(n===0)return 0;var i=0,s=e.suspendedLanes,a=e.pingedLanes,u=n&268435455;if(u!==0){var f=u&~s;f!==0?i=so(f):(a&=u,a!==0&&(i=so(a)))}else u=n&~s,u!==0?i=so(u):a!==0&&(i=so(a));if(i===0)return 0;if(t!==0&&t!==i&&!(t&s)&&(s=i&-i,a=t&-t,s>=a||s===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 Zo(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Dt(t),e[t]=n}function lw(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=fo),Xh=String.fromCharCode(32),ep=!1;function k_(e,t){switch(e){case"keyup":return bw.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 Vr=!1;function Dw(e,t){switch(e){case"compositionend":return L_(t);case"keypress":return t.which!==32?null:(ep=!0,Xh);case"textInput":return e=t.data,e===Xh&&ep?null:e;default:return null}}function Bw(e,t){if(Vr)return e==="compositionend"||!Af&&k_(e,t)?(e=T_(),Us=Mf=bn=null,Vr=!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=ip(n)}}function R_(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?R_(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function z_(){for(var e=window,t=na();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=na(e.document)}return t}function jf(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 qw(e){var t=z_(),n=e.focusedElem,i=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&R_(n.ownerDocument.documentElement,n)){if(i!==null&&jf(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 s=n.textContent.length,a=Math.min(i.start,s);i=i.end===void 0?a:Math.min(i.end,s),!e.extend&&a>i&&(s=i,i=a,a=s),s=op(n,a);var u=op(n,i);s&&u&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==u.node||e.focusOffset!==u.offset)&&(t=t.createRange(),t.setStart(s.node,s.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,Kr=null,Cc=null,po=null,kc=!1;function sp(e,t,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;kc||Kr==null||Kr!==na(i)||(i=Kr,"selectionStart"in i&&jf(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}),po&&Co(po,i)||(po=i,i=ua(Cc,"onSelect"),0Qr||(e.current=zc[Qr],zc[Qr]=null,Qr--)}function he(e,t){Qr++,zc[Qr]=e.current,e.current=t}var Qn={},qe=er(Qn),nt=er(!1),gr=Qn;function pi(e,t){var n=e.type.contextTypes;if(!n)return Qn;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===t)return i.__reactInternalMemoizedMaskedChildContext;var s={},a;for(a in n)s[a]=t[a];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function rt(e){return e=e.childContextTypes,e!=null}function fa(){me(nt),me(qe)}function hp(e,t,n){if(qe.current!==Qn)throw Error(b(168));he(qe,t),he(nt,n)}function U_(e,t,n){var i=e.stateNode;if(t=t.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var s in i)if(!(s in t))throw Error(b(108,Z0(e)||"Unknown",s));return xe({},n,i)}function da(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Qn,gr=qe.current,he(qe,e),he(nt,nt.current),!0}function pp(e,t,n){var i=e.stateNode;if(!i)throw Error(b(169));n?(e=U_(e,t,gr),i.__reactInternalMemoizedMergedChildContext=e,me(nt),me(qe),he(qe,e)):me(nt),he(nt,n)}var fn=null,Za=!1,Au=!1;function Z_(e){fn===null?fn=[e]:fn.push(e)}function s1(e){Za=!0,Z_(e)}function tr(){if(!Au&&fn!==null){Au=!0;var e=0,t=ue;try{var n=fn;for(ue=1;e>=u,s-=u,dn=1<<32-Dt(t)+s|n<Z?(re=F,F=null):re=F.sibling;var W=y(S,F,T[Z],N);if(W===null){F===null&&(F=re);break}e&&F&&W.alternate===null&&t(S,F),w=a(W,w,Z),U===null?I=W:U.sibling=W,U=W,F=re}if(Z===T.length)return n(S,F),ve&&cr(S,Z),I;if(F===null){for(;ZZ?(re=F,F=null):re=F.sibling;var X=y(S,F,W.value,N);if(X===null){F===null&&(F=re);break}e&&F&&X.alternate===null&&t(S,F),w=a(X,w,Z),U===null?I=X:U.sibling=X,U=X,F=re}if(W.done)return n(S,F),ve&&cr(S,Z),I;if(F===null){for(;!W.done;Z++,W=T.next())W=g(S,W.value,N),W!==null&&(w=a(W,w,Z),U===null?I=W:U.sibling=W,U=W);return ve&&cr(S,Z),I}for(F=i(S,F);!W.done;Z++,W=T.next())W=C(F,S,Z,W.value,N),W!==null&&(e&&W.alternate!==null&&F.delete(W.key===null?Z:W.key),w=a(W,w,Z),U===null?I=W:U.sibling=W,U=W);return e&&F.forEach(function(Le){return t(S,Le)}),ve&&cr(S,Z),I}function R(S,w,T,N){if(typeof T=="object"&&T!==null&&T.type===Wr&&T.key===null&&(T=T.props.children),typeof T=="object"&&T!==null){switch(T.$$typeof){case Ss:e:{for(var I=T.key,U=w;U!==null;){if(U.key===I){if(I=T.type,I===Wr){if(U.tag===7){n(S,U.sibling),w=s(U,T.props.children),w.return=S,S=w;break e}}else if(U.elementType===I||typeof I=="object"&&I!==null&&I.$$typeof===Mn&&xp(I)===U.type){n(S,U.sibling),w=s(U,T.props),w.ref=Ji(S,U,T),w.return=S,S=w;break e}n(S,U);break}else t(S,U);U=U.sibling}T.type===Wr?(w=vr(T.props.children,S.mode,N,T.key),w.return=S,S=w):(N=Qs(T.type,T.key,T.props,null,S.mode,N),N.ref=Ji(S,w,T),N.return=S,S=N)}return u(S);case Hr:e:{for(U=T.key;w!==null;){if(w.key===U)if(w.tag===4&&w.stateNode.containerInfo===T.containerInfo&&w.stateNode.implementation===T.implementation){n(S,w.sibling),w=s(w,T.children||[]),w.return=S,S=w;break e}else{n(S,w);break}else t(S,w);w=w.sibling}w=Uu(T,S.mode,N),w.return=S,S=w}return u(S);case Mn:return U=T._init,R(S,w,U(T._payload),N)}if(oo(T))return x(S,w,T,N);if(Ki(T))return P(S,w,T,N);zs(S,T)}return typeof T=="string"&&T!==""||typeof T=="number"?(T=""+T,w!==null&&w.tag===6?(n(S,w.sibling),w=s(w,T),w.return=S,S=w):(n(S,w),w=$u(T,S.mode,N),w.return=S,S=w),u(S)):n(S,w)}return R}var _i=Y_(!0),J_=Y_(!1),Vo={},Jt=er(Vo),No=er(Vo),Mo=er(Vo);function mr(e){if(e===Vo)throw Error(b(174));return e}function Hf(e,t){switch(he(Mo,t),he(No,e),he(Jt,Vo),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:_c(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=_c(t,e)}me(Jt),he(Jt,t)}function vi(){me(Jt),me(No),me(Mo)}function X_(e){mr(Mo.current);var t=mr(Jt.current),n=_c(t,e.type);t!==n&&(he(No,e),he(Jt,n))}function Wf(e){No.current===e&&(me(Jt),me(No))}var ye=er(0);function ga(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 ju=[];function Vf(){for(var e=0;en?n:4,e(!0);var i=bu.transition;bu.transition={};try{e(!1),t()}finally{ue=n,bu.transition=i}}function mv(){return Lt().memoizedState}function c1(e,t,n){var i=Wn(e);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},_v(e))vv(t,n);else if(n=K_(e,t,n,i),n!==null){var s=Qe();Bt(n,e,i,s),gv(n,t,i)}}function f1(e,t,n){var i=Wn(e),s={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(_v(e))vv(t,s);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(s.hasEagerState=!0,s.eagerState=f,Ft(f,u)){var d=t.interleaved;d===null?(s.next=s,Uf(t)):(s.next=d.next,d.next=s),t.interleaved=s;return}}catch{}finally{}n=K_(e,t,s,i),n!==null&&(s=Qe(),Bt(n,e,i,s),gv(n,t,i))}}function _v(e){var t=e.alternate;return e===we||t!==null&&t===we}function vv(e,t){mo=ya=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function gv(e,t,n){if(n&4194240){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Lf(e,n)}}var wa={readContext:kt,useCallback:He,useContext:He,useEffect:He,useImperativeHandle:He,useInsertionEffect:He,useLayoutEffect:He,useMemo:He,useReducer:He,useRef:He,useState:He,useDebugValue:He,useDeferredValue:He,useTransition:He,useMutableSource:He,useSyncExternalStore:He,useId:He,unstable_isNewReconciler:!1},d1={readContext:kt,useCallback:function(e,t){return Kt().memoizedState=[e,t===void 0?null:t],e},useContext:kt,useEffect:Pp,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Vs(4194308,4,cv.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Vs(4194308,4,e,t)},useInsertionEffect:function(e,t){return Vs(4,2,e,t)},useMemo:function(e,t){var n=Kt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var i=Kt();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=c1.bind(null,we,e),[i.memoizedState,e]},useRef:function(e){var t=Kt();return e={current:e},t.memoizedState=e},useState:Sp,useDebugValue:Yf,useDeferredValue:function(e){return Kt().memoizedState=e},useTransition:function(){var e=Sp(!1),t=e[0];return e=u1.bind(null,e[1]),Kt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var i=we,s=Kt();if(ve){if(n===void 0)throw Error(b(407));n=n()}else{if(n=t(),De===null)throw Error(b(349));wr&30||nv(i,t,n)}s.memoizedState=n;var a={value:n,getSnapshot:t};return s.queue=a,Pp(iv.bind(null,i,a,e),[e]),i.flags|=2048,Ao(9,rv.bind(null,i,a,n,t),void 0,null),n},useId:function(){var e=Kt(),t=De.identifierPrefix;if(ve){var n=hn,i=dn;n=(i&~(1<<32-Dt(i)-1)).toString(32)+n,t=":"+t+"R"+n,n=Ro++,0")&&(d=d.replace("",e.displayName)),d}while(1<=u&&0<=f);break}}}finally{yu=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?oo(e):""}function Z0(e){switch(e.tag){case 5:return oo(e.type);case 16:return oo("Lazy");case 13:return oo("Suspense");case 19:return oo("SuspenseList");case 0:case 2:case 15:return e=wu(e.type,!1),e;case 11:return e=wu(e.type.render,!1),e;case 1:return e=wu(e.type,!0),e;default:return""}}function fc(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 Wr:return"Fragment";case Hr:return"Portal";case lc:return"Profiler";case Pf:return"StrictMode";case uc:return"Suspense";case cc:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Ym:return(e.displayName||"Context")+".Consumer";case Qm:return(e._context.displayName||"Context")+".Provider";case Ef:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Tf:return t=e.displayName||null,t!==null?t:fc(e.type)||"Memo";case Mn:t=e._payload,e=e._init;try{return fc(e(t))}catch{}}return null}function H0(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 fc(t);case 8:return t===Pf?"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 Gn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Xm(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function W0(e){var t=Xm(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 s=n.get,a=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.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 Ps(e){e._valueTracker||(e._valueTracker=W0(e))}function e_(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),i="";return e&&(i=Xm(e)?e.checked?"true":"false":e.value),e=i,e!==n?(t.setValue(e),!0):!1}function na(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 dc(e,t){var n=t.checked;return xe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function $h(e,t){var n=t.defaultValue==null?"":t.defaultValue,i=t.checked!=null?t.checked:t.defaultChecked;n=Gn(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 t_(e,t){t=t.checked,t!=null&&Sf(e,"checked",t,!1)}function hc(e,t){t_(e,t);var n=Gn(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")?pc(e,t.type,n):t.hasOwnProperty("defaultValue")&&pc(e,t.type,Gn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Uh(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 pc(e,t,n){(t!=="number"||na(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var so=Array.isArray;function ri(e,t,n,i){if(e=e.options,t){t={};for(var s=0;s"+t.valueOf().toString()+"",t=Es.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function xo(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var co={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},V0=["Webkit","ms","Moz","O"];Object.keys(co).forEach(function(e){V0.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),co[t]=co[e]})});function o_(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||co.hasOwnProperty(e)&&co[e]?(""+t).trim():t+"px"}function s_(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var i=n.indexOf("--")===0,s=o_(n,t[n],i);n==="float"&&(n="cssFloat"),i?e.setProperty(n,s):e[n]=s}}var K0=xe({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 vc(e,t){if(t){if(K0[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(b(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(b(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(b(61))}if(t.style!=null&&typeof t.style!="object")throw Error(b(62))}}function gc(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 yc=null;function Cf(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var wc=null,ii=null,oi=null;function Wh(e){if(e=Vo(e)){if(typeof wc!="function")throw Error(b(280));var t=e.stateNode;t&&(t=Ua(t),wc(e.stateNode,e.type,t))}}function a_(e){ii?oi?oi.push(e):oi=[e]:ii=e}function l_(){if(ii){var e=ii,t=oi;if(oi=ii=null,Wh(e),t)for(e=0;e>>=0,e===0?32:31-(iw(e)/ow|0)|0}var Ts=64,Cs=4194304;function ao(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 sa(e,t){var n=e.pendingLanes;if(n===0)return 0;var i=0,s=e.suspendedLanes,a=e.pingedLanes,u=n&268435455;if(u!==0){var f=u&~s;f!==0?i=ao(f):(a&=u,a!==0&&(i=ao(a)))}else u=n&~s,u!==0?i=ao(u):a!==0&&(i=ao(a));if(i===0)return 0;if(t!==0&&t!==i&&!(t&s)&&(s=i&-i,a=t&-t,s>=a||s===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 Ho(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Dt(t),e[t]=n}function uw(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=ho),ep=String.fromCharCode(32),tp=!1;function L_(e,t){switch(e){case"keyup":return Iw.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function O_(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Vr=!1;function Bw(e,t){switch(e){case"compositionend":return O_(t);case"keypress":return t.which!==32?null:(tp=!0,ep);case"textInput":return e=t.data,e===ep&&tp?null:e;default:return null}}function Fw(e,t){if(Vr)return e==="compositionend"||!Af&&L_(e,t)?(e=C_(),Us=Mf=bn=null,Vr=!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=op(n)}}function z_(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?z_(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function A_(){for(var e=window,t=na();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=na(e.document)}return t}function jf(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 Gw(e){var t=A_(),n=e.focusedElem,i=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&z_(n.ownerDocument.documentElement,n)){if(i!==null&&jf(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 s=n.textContent.length,a=Math.min(i.start,s);i=i.end===void 0?a:Math.min(i.end,s),!e.extend&&a>i&&(s=i,i=a,a=s),s=sp(n,a);var u=sp(n,i);s&&u&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==u.node||e.focusOffset!==u.offset)&&(t=t.createRange(),t.setStart(s.node,s.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,Kr=null,Cc=null,mo=null,kc=!1;function ap(e,t,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;kc||Kr==null||Kr!==na(i)||(i=Kr,"selectionStart"in i&&jf(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}),mo&&ko(mo,i)||(mo=i,i=ua(Cc,"onSelect"),0Qr||(e.current=zc[Qr],zc[Qr]=null,Qr--)}function he(e,t){Qr++,zc[Qr]=e.current,e.current=t}var Qn={},qe=er(Qn),rt=er(!1),gr=Qn;function pi(e,t){var n=e.type.contextTypes;if(!n)return Qn;var i=e.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===t)return i.__reactInternalMemoizedMaskedChildContext;var s={},a;for(a in n)s[a]=t[a];return i&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function it(e){return e=e.childContextTypes,e!=null}function fa(){me(rt),me(qe)}function pp(e,t,n){if(qe.current!==Qn)throw Error(b(168));he(qe,t),he(rt,n)}function Z_(e,t,n){var i=e.stateNode;if(t=t.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var s in i)if(!(s in t))throw Error(b(108,H0(e)||"Unknown",s));return xe({},n,i)}function da(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Qn,gr=qe.current,he(qe,e),he(rt,rt.current),!0}function mp(e,t,n){var i=e.stateNode;if(!i)throw Error(b(169));n?(e=Z_(e,t,gr),i.__reactInternalMemoizedMergedChildContext=e,me(rt),me(qe),he(qe,e)):me(rt),he(rt,n)}var fn=null,Za=!1,Au=!1;function H_(e){fn===null?fn=[e]:fn.push(e)}function a1(e){Za=!0,H_(e)}function tr(){if(!Au&&fn!==null){Au=!0;var e=0,t=ue;try{var n=fn;for(ue=1;e>=u,s-=u,dn=1<<32-Dt(t)+s|n<Z?(re=F,F=null):re=F.sibling;var W=y(S,F,T[Z],N);if(W===null){F===null&&(F=re);break}e&&F&&W.alternate===null&&t(S,F),w=a(W,w,Z),U===null?I=W:U.sibling=W,U=W,F=re}if(Z===T.length)return n(S,F),ve&&cr(S,Z),I;if(F===null){for(;ZZ?(re=F,F=null):re=F.sibling;var X=y(S,F,W.value,N);if(X===null){F===null&&(F=re);break}e&&F&&X.alternate===null&&t(S,F),w=a(X,w,Z),U===null?I=X:U.sibling=X,U=X,F=re}if(W.done)return n(S,F),ve&&cr(S,Z),I;if(F===null){for(;!W.done;Z++,W=T.next())W=g(S,W.value,N),W!==null&&(w=a(W,w,Z),U===null?I=W:U.sibling=W,U=W);return ve&&cr(S,Z),I}for(F=i(S,F);!W.done;Z++,W=T.next())W=C(F,S,Z,W.value,N),W!==null&&(e&&W.alternate!==null&&F.delete(W.key===null?Z:W.key),w=a(W,w,Z),U===null?I=W:U.sibling=W,U=W);return e&&F.forEach(function(Le){return t(S,Le)}),ve&&cr(S,Z),I}function R(S,w,T,N){if(typeof T=="object"&&T!==null&&T.type===Wr&&T.key===null&&(T=T.props.children),typeof T=="object"&&T!==null){switch(T.$$typeof){case Ss:e:{for(var I=T.key,U=w;U!==null;){if(U.key===I){if(I=T.type,I===Wr){if(U.tag===7){n(S,U.sibling),w=s(U,T.props.children),w.return=S,S=w;break e}}else if(U.elementType===I||typeof I=="object"&&I!==null&&I.$$typeof===Mn&&Sp(I)===U.type){n(S,U.sibling),w=s(U,T.props),w.ref=Xi(S,U,T),w.return=S,S=w;break e}n(S,U);break}else t(S,U);U=U.sibling}T.type===Wr?(w=vr(T.props.children,S.mode,N,T.key),w.return=S,S=w):(N=Qs(T.type,T.key,T.props,null,S.mode,N),N.ref=Xi(S,w,T),N.return=S,S=N)}return u(S);case Hr:e:{for(U=T.key;w!==null;){if(w.key===U)if(w.tag===4&&w.stateNode.containerInfo===T.containerInfo&&w.stateNode.implementation===T.implementation){n(S,w.sibling),w=s(w,T.children||[]),w.return=S,S=w;break e}else{n(S,w);break}else t(S,w);w=w.sibling}w=Uu(T,S.mode,N),w.return=S,S=w}return u(S);case Mn:return U=T._init,R(S,w,U(T._payload),N)}if(so(T))return x(S,w,T,N);if(qi(T))return P(S,w,T,N);zs(S,T)}return typeof T=="string"&&T!==""||typeof T=="number"?(T=""+T,w!==null&&w.tag===6?(n(S,w.sibling),w=s(w,T),w.return=S,S=w):(n(S,w),w=$u(T,S.mode,N),w.return=S,S=w),u(S)):n(S,w)}return R}var _i=J_(!0),X_=J_(!1),Ko={},Xt=er(Ko),Mo=er(Ko),Ro=er(Ko);function mr(e){if(e===Ko)throw Error(b(174));return e}function Hf(e,t){switch(he(Ro,t),he(Mo,e),he(Xt,Ko),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:_c(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=_c(t,e)}me(Xt),he(Xt,t)}function vi(){me(Xt),me(Mo),me(Ro)}function ev(e){mr(Ro.current);var t=mr(Xt.current),n=_c(t,e.type);t!==n&&(he(Mo,e),he(Xt,n))}function Wf(e){Mo.current===e&&(me(Xt),me(Mo))}var ye=er(0);function ga(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 ju=[];function Vf(){for(var e=0;en?n:4,e(!0);var i=bu.transition;bu.transition={};try{e(!1),t()}finally{ue=n,bu.transition=i}}function _v(){return Lt().memoizedState}function f1(e,t,n){var i=Wn(e);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},vv(e))gv(t,n);else if(n=q_(e,t,n,i),n!==null){var s=Qe();Bt(n,e,i,s),yv(n,t,i)}}function d1(e,t,n){var i=Wn(e),s={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(vv(e))gv(t,s);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(s.hasEagerState=!0,s.eagerState=f,Ft(f,u)){var d=t.interleaved;d===null?(s.next=s,Uf(t)):(s.next=d.next,d.next=s),t.interleaved=s;return}}catch{}finally{}n=q_(e,t,s,i),n!==null&&(s=Qe(),Bt(n,e,i,s),yv(n,t,i))}}function vv(e){var t=e.alternate;return e===we||t!==null&&t===we}function gv(e,t){_o=ya=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function yv(e,t,n){if(n&4194240){var i=t.lanes;i&=e.pendingLanes,n|=i,t.lanes=n,Lf(e,n)}}var wa={readContext:kt,useCallback:He,useContext:He,useEffect:He,useImperativeHandle:He,useInsertionEffect:He,useLayoutEffect:He,useMemo:He,useReducer:He,useRef:He,useState:He,useDebugValue:He,useDeferredValue:He,useTransition:He,useMutableSource:He,useSyncExternalStore:He,useId:He,unstable_isNewReconciler:!1},h1={readContext:kt,useCallback:function(e,t){return qt().memoizedState=[e,t===void 0?null:t],e},useContext:kt,useEffect:Ep,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Vs(4194308,4,fv.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Vs(4194308,4,e,t)},useInsertionEffect:function(e,t){return Vs(4,2,e,t)},useMemo:function(e,t){var n=qt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var i=qt();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=f1.bind(null,we,e),[i.memoizedState,e]},useRef:function(e){var t=qt();return e={current:e},t.memoizedState=e},useState:Pp,useDebugValue:Yf,useDeferredValue:function(e){return qt().memoizedState=e},useTransition:function(){var e=Pp(!1),t=e[0];return e=c1.bind(null,e[1]),qt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var i=we,s=qt();if(ve){if(n===void 0)throw Error(b(407));n=n()}else{if(n=t(),De===null)throw Error(b(349));wr&30||rv(i,t,n)}s.memoizedState=n;var a={value:n,getSnapshot:t};return s.queue=a,Ep(ov.bind(null,i,a,e),[e]),i.flags|=2048,jo(9,iv.bind(null,i,a,n,t),void 0,null),n},useId:function(){var e=qt(),t=De.identifierPrefix;if(ve){var n=hn,i=dn;n=(i&~(1<<32-Dt(i)-1)).toString(32)+n,t=":"+t+"R"+n,n=zo++,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[qt]=t,e[Oo]=i,kv(e,t,!1,!1),t.stateNode=e;e:{switch(u=gc(n,i),n){case"dialog":pe("cancel",e),pe("close",e),s=i;break;case"iframe":case"object":case"embed":pe("load",e),s=i;break;case"video":case"audio":for(s=0;syi&&(t.flags|=128,i=!0,Xi(a,!1),t.lanes=4194304)}else{if(!i)if(e=ga(u),e!==null){if(t.flags|=128,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Xi(a,!0),a.tail===null&&a.tailMode==="hidden"&&!u.alternate&&!ve)return We(t),null}else 2*Ce()-a.renderingStartTime>yi&&n!==1073741824&&(t.flags|=128,i=!0,Xi(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=Ce(),t.sibling=null,n=ye.current,he(ye,i?n&1|2:n&1),t):(We(t),null);case 22:case 23:return rd(),i=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(t.flags|=8192),i&&t.mode&1?ot&1073741824&&(We(t),t.subtreeFlags&6&&(t.flags|=8192)):We(t),null;case 24:return null;case 25:return null}throw Error(b(156,t.tag))}function w1(e,t){switch(If(t),t.tag){case 1:return rt(t.type)&&fa(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return vi(),me(nt),me(qe),Vf(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Wf(t),null;case 13:if(me(ye),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(b(340));mi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return me(ye),null;case 4:return vi(),null;case 10:return $f(t.type._context),null;case 22:case 23:return rd(),null;case 24:return null;default:return null}}var js=!1,Ke=!1,x1=typeof WeakSet=="function"?WeakSet:Set,$=null;function ei(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Pe(e,t,i)}else n.current=null}function Wc(e,t,n){try{n()}catch(i){Pe(e,t,i)}}var Rp=!1;function S1(e,t){if(Lc=aa,e=z_(),jf(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 s=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,g=e,y=null;t:for(;;){for(var C;g!==n||s!==0&&g.nodeType!==3||(f=u+s),g!==a||i!==0&&g.nodeType!==3||(d=u+i),g.nodeType===3&&(u+=g.nodeValue.length),(C=g.firstChild)!==null;)y=g,g=C;for(;;){if(g===e)break t;if(y===n&&++p===s&&(f=u),y===a&&++m===i&&(d=u),(C=g.nextSibling)!==null)break;g=y,y=g.parentNode}g=C}n=f===-1||d===-1?null:{start:f,end:d}}else n=null}n=n||{start:0,end:0}}else n=null;for(Oc={focusedElem:e,selectionRange:n},aa=!1,$=t;$!==null;)if(t=$,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,$=e;else for(;$!==null;){t=$;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var P=x.memoizedProps,R=x.memoizedState,S=t.stateNode,w=S.getSnapshotBeforeUpdate(t.elementType===t.type?P:At(t.type,P),R);S.__reactInternalSnapshotBeforeUpdate=w}break;case 3:var T=t.stateNode.containerInfo;T.nodeType===1?T.textContent="":T.nodeType===9&&T.documentElement&&T.removeChild(T.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(b(163))}}catch(N){Pe(t,t.return,N)}if(e=t.sibling,e!==null){e.return=t.return,$=e;break}$=t.return}return x=Rp,Rp=!1,x}function _o(e,t,n){var i=t.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var s=i=i.next;do{if((s.tag&e)===e){var a=s.destroy;s.destroy=void 0,a!==void 0&&Wc(t,n,a)}s=s.next}while(s!==i)}}function Va(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 Vc(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 Nv(e){var t=e.alternate;t!==null&&(e.alternate=null,Nv(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[qt],delete t[Oo],delete t[Rc],delete t[i1],delete t[o1])),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 Mv(e){return e.tag===5||e.tag===3||e.tag===4}function zp(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Mv(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 Kc(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=ca));else if(i!==4&&(e=e.child,e!==null))for(Kc(e,t,n),e=e.sibling;e!==null;)Kc(e,t,n),e=e.sibling}function qc(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(qc(e,t,n),e=e.sibling;e!==null;)qc(e,t,n),e=e.sibling}var $e=null,jt=!1;function On(e,t,n){for(n=n.child;n!==null;)Rv(e,t,n),n=n.sibling}function Rv(e,t,n){if(Yt&&typeof Yt.onCommitFiberUnmount=="function")try{Yt.onCommitFiberUnmount(Da,n)}catch{}switch(n.tag){case 5:Ke||ei(n,t);case 6:var i=$e,s=jt;$e=null,On(e,t,n),$e=i,jt=s,$e!==null&&(jt?(e=$e,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):$e.removeChild(n.stateNode));break;case 18:$e!==null&&(jt?(e=$e,n=n.stateNode,e.nodeType===8?zu(e.parentNode,n):e.nodeType===1&&zu(e,n),Eo(e)):zu($e,n.stateNode));break;case 4:i=$e,s=jt,$e=n.stateNode.containerInfo,jt=!0,On(e,t,n),$e=i,jt=s;break;case 0:case 11:case 14:case 15:if(!Ke&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){s=i=i.next;do{var a=s,u=a.destroy;a=a.tag,u!==void 0&&(a&2||a&4)&&Wc(n,t,u),s=s.next}while(s!==i)}On(e,t,n);break;case 1:if(!Ke&&(ei(n,t),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(f){Pe(n,t,f)}On(e,t,n);break;case 21:On(e,t,n);break;case 22:n.mode&1?(Ke=(i=Ke)||n.memoizedState!==null,On(e,t,n),Ke=i):On(e,t,n);break;default:On(e,t,n)}}function Ap(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new x1),t.forEach(function(i){var s=M1.bind(null,e,i);n.has(i)||(n.add(i),i.then(s,s))})}}function zt(e,t){var n=t.deletions;if(n!==null)for(var i=0;is&&(s=u),i&=~a}if(i=s,i=Ce()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*E1(i/1960))-i,10e?16:e,In===null)var i=!1;else{if(e=In,In=null,Pa=0,ne&6)throw Error(b(331));var s=ne;for(ne|=4,$=e.current;$!==null;){var a=$,u=a.child;if($.flags&16){var f=a.deletions;if(f!==null){for(var d=0;dCe()-td?_r(e,0):ed|=n),it(e,t)}function Fv(e,t){t===0&&(e.mode&1?(t=Cs,Cs<<=1,!(Cs&130023424)&&(Cs=4194304)):t=1);var n=Qe();e=gn(e,t),e!==null&&(Zo(e,t,n),it(e,n))}function N1(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Fv(e,n)}function M1(e,t){var n=0;switch(e.tag){case 13:var i=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(b(314))}i!==null&&i.delete(t),Fv(e,n)}var $v;$v=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||nt.current)tt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return tt=!1,g1(e,t,n);tt=!!(e.flags&131072)}else tt=!1,ve&&t.flags&1048576&&H_(t,pa,t.index);switch(t.lanes=0,t.tag){case 2:var i=t.type;Ks(e,t),e=t.pendingProps;var s=pi(t,qe.current);ai(t,n),s=qf(null,t,i,e,s,n);var a=Gf();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,rt(i)?(a=!0,da(t)):a=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Zf(t),s.updater=Ha,t.stateNode=s,s._reactInternals=t,Dc(t,i,e,n),t=$c(null,t,i,!0,a,n)):(t.tag=0,ve&&a&&bf(t),Ge(null,t,s,n),t=t.child),t;case 16:i=t.elementType;e:{switch(Ks(e,t),e=t.pendingProps,s=i._init,i=s(i._payload),t.type=i,s=t.tag=z1(i),e=At(i,e),s){case 0:t=Fc(null,t,i,e,n);break e;case 1:t=Op(null,t,i,e,n);break e;case 11:t=kp(null,t,i,e,n);break e;case 14:t=Lp(null,t,i,At(i.type,e),n);break e}throw Error(b(306,i,""))}return t;case 0:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Fc(e,t,i,s,n);case 1:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Op(e,t,i,s,n);case 3:e:{if(Ev(t),e===null)throw Error(b(387));i=t.pendingProps,a=t.memoizedState,s=a.element,q_(e,t),va(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){s=gi(Error(b(423)),t),t=Np(e,t,i,n,s);break e}else if(i!==s){s=gi(Error(b(424)),t),t=Np(e,t,i,n,s);break e}else for(st=Un(t.stateNode.containerInfo.firstChild),ut=t,ve=!0,bt=null,n=J_(t,null,i,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(mi(),i===s){t=yn(e,t,n);break e}Ge(e,t,i,n)}t=t.child}return t;case 5:return X_(t),e===null&&jc(t),i=t.type,s=t.pendingProps,a=e!==null?e.memoizedProps:null,u=s.children,Nc(i,s)?u=null:a!==null&&Nc(i,a)&&(t.flags|=32),Pv(e,t),Ge(e,t,u,n),t.child;case 6:return e===null&&jc(t),null;case 13:return Tv(e,t,n);case 4:return Hf(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=_i(t,null,i,n):Ge(e,t,i,n),t.child;case 11:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),kp(e,t,i,s,n);case 7:return Ge(e,t,t.pendingProps,n),t.child;case 8:return Ge(e,t,t.pendingProps.children,n),t.child;case 12:return Ge(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(i=t.type._context,s=t.pendingProps,a=t.memoizedProps,u=s.value,he(ma,i._currentValue),i._currentValue=u,a!==null)if(Ft(a.value,u)){if(a.children===s.children&&!nt.current){t=yn(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=pn(-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),bc(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(b(341));u.lanes|=n,f=u.alternate,f!==null&&(f.lanes|=n),bc(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}Ge(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,i=t.pendingProps.children,ai(t,n),s=kt(s),i=i(s),t.flags|=1,Ge(e,t,i,n),t.child;case 14:return i=t.type,s=At(i,t.pendingProps),s=At(i.type,s),Lp(e,t,i,s,n);case 15:return xv(e,t,t.type,t.pendingProps,n);case 17:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Ks(e,t),t.tag=1,rt(i)?(e=!0,da(t)):e=!1,ai(t,n),Q_(t,i,s),Dc(t,i,s,n),$c(null,t,i,!0,e,n);case 19:return Cv(e,t,n);case 22:return Sv(e,t,n)}throw Error(b(156,t.tag))};function Uv(e,t){return p_(e,t)}function R1(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 Pt(e,t,n,i){return new R1(e,t,n,i)}function od(e){return e=e.prototype,!(!e||!e.isReactComponent)}function z1(e){if(typeof e=="function")return od(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Ef)return 11;if(e===Tf)return 14}return 2}function Vn(e,t){var n=e.alternate;return n===null?(n=Pt(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 Qs(e,t,n,i,s,a){var u=2;if(i=e,typeof e=="function")od(e)&&(u=1);else if(typeof e=="string")u=5;else e:switch(e){case Wr:return vr(n.children,s,a,t);case Pf:u=8,s|=8;break;case lc:return e=Pt(12,n,t,s|2),e.elementType=lc,e.lanes=a,e;case uc:return e=Pt(13,n,t,s),e.elementType=uc,e.lanes=a,e;case cc:return e=Pt(19,n,t,s),e.elementType=cc,e.lanes=a,e;case Ym:return qa(n,s,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Gm:u=10;break e;case Qm:u=9;break e;case Ef:u=11;break e;case Tf:u=14;break e;case Mn:u=16,i=null;break e}throw Error(b(130,e==null?e:typeof e,""))}return t=Pt(u,n,t,s),t.elementType=e,t.type=i,t.lanes=a,t}function vr(e,t,n,i){return e=Pt(7,e,i,t),e.lanes=n,e}function qa(e,t,n,i){return e=Pt(22,e,i,t),e.elementType=Ym,e.lanes=n,e.stateNode={isHidden:!1},e}function $u(e,t,n){return e=Pt(6,e,null,t),e.lanes=n,e}function Uu(e,t,n){return t=Pt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function A1(e,t,n,i,s){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=Su(0),this.expirationTimes=Su(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Su(0),this.identifierPrefix=i,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function sd(e,t,n,i,s,a,u,f,d){return e=new A1(e,t,n,f,d),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Pt(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Zf(a),e}function j1(e,t,n){var i=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Vv)}catch(e){console.error(e)}}Vv(),Hm.exports=dt;var Kv=Hm.exports,Up=Kv;sc.createRoot=Up.createRoot,sc.hydrateRoot=Up.hydrateRoot;/** +`+a.stack}return{value:e,source:t,stack:s,digest:null}}function Bu(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Bc(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var _1=typeof WeakMap=="function"?WeakMap:Map;function wv(e,t,n){n=pn(-1,n),n.tag=3,n.payload={element:null};var i=t.value;return n.callback=function(){Sa||(Sa=!0,Gc=i),Bc(e,t)},n}function xv(e,t,n){n=pn(-1,n),n.tag=3;var i=e.type.getDerivedStateFromError;if(typeof i=="function"){var s=t.value;n.payload=function(){return i(s)},n.callback=function(){Bc(e,t)}}var a=e.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(n.callback=function(){Bc(e,t),typeof i!="function"&&(Hn===null?Hn=new Set([this]):Hn.add(this));var u=t.stack;this.componentDidCatch(t.value,{componentStack:u!==null?u:""})}),n}function Tp(e,t,n){var i=e.pingCache;if(i===null){i=e.pingCache=new _1;var s=new Set;i.set(t,s)}else s=i.get(t),s===void 0&&(s=new Set,i.set(t,s));s.has(n)||(s.add(n),e=N1.bind(null,e,t,n),t.then(e,e))}function Cp(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function kp(e,t,n,i,s){return e.mode&1?(e.flags|=65536,e.lanes=s,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=pn(-1,1),t.tag=2,Zn(n,t,1))),n.lanes|=1),e)}var v1=xn.ReactCurrentOwner,nt=!1;function Ge(e,t,n,i){t.child=e===null?X_(t,null,n,i):_i(t,e.child,n,i)}function Lp(e,t,n,i,s){n=n.render;var a=t.ref;return ai(t,s),i=qf(e,t,n,i,a,s),n=Gf(),e!==null&&!nt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,yn(e,t,s)):(ve&&n&&bf(t),t.flags|=1,Ge(e,t,i,s),t.child)}function Op(e,t,n,i,s){if(e===null){var a=n.type;return typeof a=="function"&&!od(a)&&a.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=a,Sv(e,t,a,i,s)):(e=Qs(n.type,null,i,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!(e.lanes&s)){var u=a.memoizedProps;if(n=n.compare,n=n!==null?n:ko,n(u,i)&&e.ref===t.ref)return yn(e,t,s)}return t.flags|=1,e=Vn(a,i),e.ref=t.ref,e.return=t,t.child=e}function Sv(e,t,n,i,s){if(e!==null){var a=e.memoizedProps;if(ko(a,i)&&e.ref===t.ref)if(nt=!1,t.pendingProps=i=a,(e.lanes&s)!==0)e.flags&131072&&(nt=!0);else return t.lanes=e.lanes,yn(e,t,s)}return Fc(e,t,n,i,s)}function Pv(e,t,n){var i=t.pendingProps,s=i.children,a=e!==null?e.memoizedState:null;if(i.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},he(ti,st),st|=n;else{if(!(n&1073741824))return e=a!==null?a.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,he(ti,st),st|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},i=a!==null?a.baseLanes:n,he(ti,st),st|=i}else a!==null?(i=a.baseLanes|n,t.memoizedState=null):i=n,he(ti,st),st|=i;return Ge(e,t,s,n),t.child}function Ev(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Fc(e,t,n,i,s){var a=it(n)?gr:qe.current;return a=pi(t,a),ai(t,s),n=qf(e,t,n,i,a,s),i=Gf(),e!==null&&!nt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,yn(e,t,s)):(ve&&i&&bf(t),t.flags|=1,Ge(e,t,n,s),t.child)}function Np(e,t,n,i,s){if(it(n)){var a=!0;da(t)}else a=!1;if(ai(t,s),t.stateNode===null)Ks(e,t),Y_(t,n,i),Dc(t,n,i,s),i=!0;else if(e===null){var u=t.stateNode,f=t.memoizedProps;u.props=f;var d=u.context,p=n.contextType;typeof p=="object"&&p!==null?p=kt(p):(p=it(n)?gr:qe.current,p=pi(t,p));var m=n.getDerivedStateFromProps,g=typeof m=="function"||typeof u.getSnapshotBeforeUpdate=="function";g||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(f!==i||d!==p)&&xp(t,u,i,p),Rn=!1;var y=t.memoizedState;u.state=y,va(t,i,u,s),d=t.memoizedState,f!==i||y!==d||rt.current||Rn?(typeof m=="function"&&(Ic(t,n,m,i),d=t.memoizedState),(f=Rn||wp(t,n,f,i,y,d,p))?(g||typeof u.UNSAFE_componentWillMount!="function"&&typeof u.componentWillMount!="function"||(typeof u.componentWillMount=="function"&&u.componentWillMount(),typeof u.UNSAFE_componentWillMount=="function"&&u.UNSAFE_componentWillMount()),typeof u.componentDidMount=="function"&&(t.flags|=4194308)):(typeof u.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=i,t.memoizedState=d),u.props=i,u.state=d,u.context=p,i=f):(typeof u.componentDidMount=="function"&&(t.flags|=4194308),i=!1)}else{u=t.stateNode,G_(e,t),f=t.memoizedProps,p=t.type===t.elementType?f:At(t.type,f),u.props=p,g=t.pendingProps,y=u.context,d=n.contextType,typeof d=="object"&&d!==null?d=kt(d):(d=it(n)?gr:qe.current,d=pi(t,d));var C=n.getDerivedStateFromProps;(m=typeof C=="function"||typeof u.getSnapshotBeforeUpdate=="function")||typeof u.UNSAFE_componentWillReceiveProps!="function"&&typeof u.componentWillReceiveProps!="function"||(f!==g||y!==d)&&xp(t,u,i,d),Rn=!1,y=t.memoizedState,u.state=y,va(t,i,u,s);var x=t.memoizedState;f!==g||y!==x||rt.current||Rn?(typeof C=="function"&&(Ic(t,n,C,i),x=t.memoizedState),(p=Rn||wp(t,n,p,i,y,x,d)||!1)?(m||typeof u.UNSAFE_componentWillUpdate!="function"&&typeof u.componentWillUpdate!="function"||(typeof u.componentWillUpdate=="function"&&u.componentWillUpdate(i,x,d),typeof u.UNSAFE_componentWillUpdate=="function"&&u.UNSAFE_componentWillUpdate(i,x,d)),typeof u.componentDidUpdate=="function"&&(t.flags|=4),typeof u.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof u.componentDidUpdate!="function"||f===e.memoizedProps&&y===e.memoizedState||(t.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||f===e.memoizedProps&&y===e.memoizedState||(t.flags|=1024),t.memoizedProps=i,t.memoizedState=x),u.props=i,u.state=x,u.context=d,i=p):(typeof u.componentDidUpdate!="function"||f===e.memoizedProps&&y===e.memoizedState||(t.flags|=4),typeof u.getSnapshotBeforeUpdate!="function"||f===e.memoizedProps&&y===e.memoizedState||(t.flags|=1024),i=!1)}return $c(e,t,n,i,a,s)}function $c(e,t,n,i,s,a){Ev(e,t);var u=(t.flags&128)!==0;if(!i&&!u)return s&&mp(t,n,!1),yn(e,t,a);i=t.stateNode,v1.current=t;var f=u&&typeof n.getDerivedStateFromError!="function"?null:i.render();return t.flags|=1,e!==null&&u?(t.child=_i(t,e.child,null,a),t.child=_i(t,null,f,a)):Ge(e,t,f,a),t.memoizedState=i.state,s&&mp(t,n,!0),t.child}function Tv(e){var t=e.stateNode;t.pendingContext?pp(e,t.pendingContext,t.pendingContext!==t.context):t.context&&pp(e,t.context,!1),Hf(e,t.containerInfo)}function Mp(e,t,n,i,s){return mi(),Df(s),t.flags|=256,Ge(e,t,n,i),t.child}var Uc={dehydrated:null,treeContext:null,retryLane:0};function Zc(e){return{baseLanes:e,cachePool:null,transitions:null}}function Cv(e,t,n){var i=t.pendingProps,s=ye.current,a=!1,u=(t.flags&128)!==0,f;if((f=u)||(f=e!==null&&e.memoizedState===null?!1:(s&2)!==0),f?(a=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),he(ye,s&1),e===null)return jc(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(u=i.children,e=i.fallback,a?(i=t.mode,a=t.child,u={mode:"hidden",children:u},!(i&1)&&a!==null?(a.childLanes=0,a.pendingProps=u):a=qa(u,i,0,null),e=vr(e,i,n,null),a.return=t,e.return=t,a.sibling=e,t.child=a,t.child.memoizedState=Zc(n),t.memoizedState=Uc,e):Jf(t,u));if(s=e.memoizedState,s!==null&&(f=s.dehydrated,f!==null))return g1(e,t,u,i,f,s,n);if(a){a=i.fallback,u=t.mode,s=e.child,f=s.sibling;var d={mode:"hidden",children:i.children};return!(u&1)&&t.child!==s?(i=t.child,i.childLanes=0,i.pendingProps=d,t.deletions=null):(i=Vn(s,d),i.subtreeFlags=s.subtreeFlags&14680064),f!==null?a=Vn(f,a):(a=vr(a,u,n,null),a.flags|=2),a.return=t,i.return=t,i.sibling=a,t.child=i,i=a,a=t.child,u=e.child.memoizedState,u=u===null?Zc(n):{baseLanes:u.baseLanes|n,cachePool:null,transitions:u.transitions},a.memoizedState=u,a.childLanes=e.childLanes&~n,t.memoizedState=Uc,i}return a=e.child,e=a.sibling,i=Vn(a,{mode:"visible",children:i.children}),!(t.mode&1)&&(i.lanes=n),i.return=t,i.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=i,t.memoizedState=null,i}function Jf(e,t){return t=qa({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function As(e,t,n,i){return i!==null&&Df(i),_i(t,e.child,null,n),e=Jf(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function g1(e,t,n,i,s,a,u){if(n)return t.flags&256?(t.flags&=-257,i=Bu(Error(b(422))),As(e,t,u,i)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(a=i.fallback,s=t.mode,i=qa({mode:"visible",children:i.children},s,0,null),a=vr(a,s,u,null),a.flags|=2,i.return=t,a.return=t,i.sibling=a,t.child=i,t.mode&1&&_i(t,e.child,null,u),t.child.memoizedState=Zc(u),t.memoizedState=Uc,a);if(!(t.mode&1))return As(e,t,u,null);if(s.data==="$!"){if(i=s.nextSibling&&s.nextSibling.dataset,i)var f=i.dgst;return i=f,a=Error(b(419)),i=Bu(a,i,void 0),As(e,t,u,i)}if(f=(u&e.childLanes)!==0,nt||f){if(i=De,i!==null){switch(u&-u){case 4:s=2;break;case 16:s=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:s=32;break;case 536870912:s=268435456;break;default:s=0}s=s&(i.suspendedLanes|u)?0:s,s!==0&&s!==a.retryLane&&(a.retryLane=s,gn(e,s),Bt(i,e,s,-1))}return id(),i=Bu(Error(b(421))),As(e,t,u,i)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=M1.bind(null,e),s._reactRetry=t,null):(e=a.treeContext,at=Un(s.nextSibling),ut=t,ve=!0,bt=null,e!==null&&(wt[xt++]=dn,wt[xt++]=hn,wt[xt++]=yr,dn=e.id,hn=e.overflow,yr=t),t=Jf(t,i.children),t.flags|=4096,t)}function Rp(e,t,n){e.lanes|=t;var i=e.alternate;i!==null&&(i.lanes|=t),bc(e.return,t,n)}function Fu(e,t,n,i,s){var a=e.memoizedState;a===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:i,tail:n,tailMode:s}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=i,a.tail=n,a.tailMode=s)}function kv(e,t,n){var i=t.pendingProps,s=i.revealOrder,a=i.tail;if(Ge(e,t,i.children,n),i=ye.current,i&2)i=i&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Rp(e,n,t);else if(e.tag===19)Rp(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}i&=1}if(he(ye,i),!(t.mode&1))t.memoizedState=null;else switch(s){case"forwards":for(n=t.child,s=null;n!==null;)e=n.alternate,e!==null&&ga(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),Fu(t,!1,s,n,a);break;case"backwards":for(n=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&ga(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}Fu(t,!0,n,null,a);break;case"together":Fu(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Ks(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function yn(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),xr|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(b(153));if(t.child!==null){for(e=t.child,n=Vn(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Vn(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function y1(e,t,n){switch(t.tag){case 3:Tv(t),mi();break;case 5:ev(t);break;case 1:it(t.type)&&da(t);break;case 4:Hf(t,t.stateNode.containerInfo);break;case 10:var i=t.type._context,s=t.memoizedProps.value;he(ma,i._currentValue),i._currentValue=s;break;case 13:if(i=t.memoizedState,i!==null)return i.dehydrated!==null?(he(ye,ye.current&1),t.flags|=128,null):n&t.child.childLanes?Cv(e,t,n):(he(ye,ye.current&1),e=yn(e,t,n),e!==null?e.sibling:null);he(ye,ye.current&1);break;case 19:if(i=(n&t.childLanes)!==0,e.flags&128){if(i)return kv(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),he(ye,ye.current),i)break;return null;case 22:case 23:return t.lanes=0,Pv(e,t,n)}return yn(e,t,n)}var Lv,Hc,Ov,Nv;Lv=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};Hc=function(){};Ov=function(e,t,n,i){var s=e.memoizedProps;if(s!==i){e=t.stateNode,mr(Xt.current);var a=null;switch(n){case"input":s=dc(e,s),i=dc(e,i),a=[];break;case"select":s=xe({},s,{value:void 0}),i=xe({},i,{value:void 0}),a=[];break;case"textarea":s=mc(e,s),i=mc(e,i),a=[];break;default:typeof s.onClick!="function"&&typeof i.onClick=="function"&&(e.onclick=ca)}vc(n,i);var u;n=null;for(p in s)if(!i.hasOwnProperty(p)&&s.hasOwnProperty(p)&&s[p]!=null)if(p==="style"){var f=s[p];for(u in f)f.hasOwnProperty(u)&&(n||(n={}),n[u]="")}else p!=="dangerouslySetInnerHTML"&&p!=="children"&&p!=="suppressContentEditableWarning"&&p!=="suppressHydrationWarning"&&p!=="autoFocus"&&(wo.hasOwnProperty(p)?a||(a=[]):(a=a||[]).push(p,null));for(p in i){var d=i[p];if(f=s!=null?s[p]:void 0,i.hasOwnProperty(p)&&d!==f&&(d!=null||f!=null))if(p==="style")if(f){for(u in f)!f.hasOwnProperty(u)||d&&d.hasOwnProperty(u)||(n||(n={}),n[u]="");for(u in d)d.hasOwnProperty(u)&&f[u]!==d[u]&&(n||(n={}),n[u]=d[u])}else n||(a||(a=[]),a.push(p,n)),n=d;else p==="dangerouslySetInnerHTML"?(d=d?d.__html:void 0,f=f?f.__html:void 0,d!=null&&f!==d&&(a=a||[]).push(p,d)):p==="children"?typeof d!="string"&&typeof d!="number"||(a=a||[]).push(p,""+d):p!=="suppressContentEditableWarning"&&p!=="suppressHydrationWarning"&&(wo.hasOwnProperty(p)?(d!=null&&p==="onScroll"&&pe("scroll",e),a||f===d||(a=[])):(a=a||[]).push(p,d))}n&&(a=a||[]).push("style",n);var p=a;(t.updateQueue=p)&&(t.flags|=4)}};Nv=function(e,t,n,i){n!==i&&(t.flags|=4)};function eo(e,t){if(!ve)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var i=null;n!==null;)n.alternate!==null&&(i=n),n=n.sibling;i===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:i.sibling=null}}function We(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,i=0;if(t)for(var s=e.child;s!==null;)n|=s.lanes|s.childLanes,i|=s.subtreeFlags&14680064,i|=s.flags&14680064,s.return=e,s=s.sibling;else for(s=e.child;s!==null;)n|=s.lanes|s.childLanes,i|=s.subtreeFlags,i|=s.flags,s.return=e,s=s.sibling;return e.subtreeFlags|=i,e.childLanes=n,t}function w1(e,t,n){var i=t.pendingProps;switch(If(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return We(t),null;case 1:return it(t.type)&&fa(),We(t),null;case 3:return i=t.stateNode,vi(),me(rt),me(qe),Vf(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),(e===null||e.child===null)&&(Rs(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,bt!==null&&(Jc(bt),bt=null))),Hc(e,t),We(t),null;case 5:Wf(t);var s=mr(Ro.current);if(n=t.type,e!==null&&t.stateNode!=null)Ov(e,t,n,i,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!i){if(t.stateNode===null)throw Error(b(166));return We(t),null}if(e=mr(Xt.current),Rs(t)){i=t.stateNode,n=t.type;var a=t.memoizedProps;switch(i[Gt]=t,i[No]=a,e=(t.mode&1)!==0,n){case"dialog":pe("cancel",i),pe("close",i);break;case"iframe":case"object":case"embed":pe("load",i);break;case"video":case"audio":for(s=0;s<\/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[Gt]=t,e[No]=i,Lv(e,t,!1,!1),t.stateNode=e;e:{switch(u=gc(n,i),n){case"dialog":pe("cancel",e),pe("close",e),s=i;break;case"iframe":case"object":case"embed":pe("load",e),s=i;break;case"video":case"audio":for(s=0;syi&&(t.flags|=128,i=!0,eo(a,!1),t.lanes=4194304)}else{if(!i)if(e=ga(u),e!==null){if(t.flags|=128,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),eo(a,!0),a.tail===null&&a.tailMode==="hidden"&&!u.alternate&&!ve)return We(t),null}else 2*Ce()-a.renderingStartTime>yi&&n!==1073741824&&(t.flags|=128,i=!0,eo(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=Ce(),t.sibling=null,n=ye.current,he(ye,i?n&1|2:n&1),t):(We(t),null);case 22:case 23:return rd(),i=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==i&&(t.flags|=8192),i&&t.mode&1?st&1073741824&&(We(t),t.subtreeFlags&6&&(t.flags|=8192)):We(t),null;case 24:return null;case 25:return null}throw Error(b(156,t.tag))}function x1(e,t){switch(If(t),t.tag){case 1:return it(t.type)&&fa(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return vi(),me(rt),me(qe),Vf(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Wf(t),null;case 13:if(me(ye),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(b(340));mi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return me(ye),null;case 4:return vi(),null;case 10:return $f(t.type._context),null;case 22:case 23:return rd(),null;case 24:return null;default:return null}}var js=!1,Ke=!1,S1=typeof WeakSet=="function"?WeakSet:Set,$=null;function ei(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Pe(e,t,i)}else n.current=null}function Wc(e,t,n){try{n()}catch(i){Pe(e,t,i)}}var zp=!1;function P1(e,t){if(Lc=aa,e=A_(),jf(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 s=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,g=e,y=null;t:for(;;){for(var C;g!==n||s!==0&&g.nodeType!==3||(f=u+s),g!==a||i!==0&&g.nodeType!==3||(d=u+i),g.nodeType===3&&(u+=g.nodeValue.length),(C=g.firstChild)!==null;)y=g,g=C;for(;;){if(g===e)break t;if(y===n&&++p===s&&(f=u),y===a&&++m===i&&(d=u),(C=g.nextSibling)!==null)break;g=y,y=g.parentNode}g=C}n=f===-1||d===-1?null:{start:f,end:d}}else n=null}n=n||{start:0,end:0}}else n=null;for(Oc={focusedElem:e,selectionRange:n},aa=!1,$=t;$!==null;)if(t=$,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,$=e;else for(;$!==null;){t=$;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var P=x.memoizedProps,R=x.memoizedState,S=t.stateNode,w=S.getSnapshotBeforeUpdate(t.elementType===t.type?P:At(t.type,P),R);S.__reactInternalSnapshotBeforeUpdate=w}break;case 3:var T=t.stateNode.containerInfo;T.nodeType===1?T.textContent="":T.nodeType===9&&T.documentElement&&T.removeChild(T.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(b(163))}}catch(N){Pe(t,t.return,N)}if(e=t.sibling,e!==null){e.return=t.return,$=e;break}$=t.return}return x=zp,zp=!1,x}function vo(e,t,n){var i=t.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var s=i=i.next;do{if((s.tag&e)===e){var a=s.destroy;s.destroy=void 0,a!==void 0&&Wc(t,n,a)}s=s.next}while(s!==i)}}function Va(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 Vc(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 Mv(e){var t=e.alternate;t!==null&&(e.alternate=null,Mv(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Gt],delete t[No],delete t[Rc],delete t[o1],delete t[s1])),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 Rv(e){return e.tag===5||e.tag===3||e.tag===4}function Ap(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Rv(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 Kc(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=ca));else if(i!==4&&(e=e.child,e!==null))for(Kc(e,t,n),e=e.sibling;e!==null;)Kc(e,t,n),e=e.sibling}function qc(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(qc(e,t,n),e=e.sibling;e!==null;)qc(e,t,n),e=e.sibling}var $e=null,jt=!1;function On(e,t,n){for(n=n.child;n!==null;)zv(e,t,n),n=n.sibling}function zv(e,t,n){if(Jt&&typeof Jt.onCommitFiberUnmount=="function")try{Jt.onCommitFiberUnmount(Da,n)}catch{}switch(n.tag){case 5:Ke||ei(n,t);case 6:var i=$e,s=jt;$e=null,On(e,t,n),$e=i,jt=s,$e!==null&&(jt?(e=$e,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):$e.removeChild(n.stateNode));break;case 18:$e!==null&&(jt?(e=$e,n=n.stateNode,e.nodeType===8?zu(e.parentNode,n):e.nodeType===1&&zu(e,n),To(e)):zu($e,n.stateNode));break;case 4:i=$e,s=jt,$e=n.stateNode.containerInfo,jt=!0,On(e,t,n),$e=i,jt=s;break;case 0:case 11:case 14:case 15:if(!Ke&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){s=i=i.next;do{var a=s,u=a.destroy;a=a.tag,u!==void 0&&(a&2||a&4)&&Wc(n,t,u),s=s.next}while(s!==i)}On(e,t,n);break;case 1:if(!Ke&&(ei(n,t),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(f){Pe(n,t,f)}On(e,t,n);break;case 21:On(e,t,n);break;case 22:n.mode&1?(Ke=(i=Ke)||n.memoizedState!==null,On(e,t,n),Ke=i):On(e,t,n);break;default:On(e,t,n)}}function jp(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new S1),t.forEach(function(i){var s=R1.bind(null,e,i);n.has(i)||(n.add(i),i.then(s,s))})}}function zt(e,t){var n=t.deletions;if(n!==null)for(var i=0;is&&(s=u),i&=~a}if(i=s,i=Ce()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*T1(i/1960))-i,10e?16:e,In===null)var i=!1;else{if(e=In,In=null,Pa=0,ne&6)throw Error(b(331));var s=ne;for(ne|=4,$=e.current;$!==null;){var a=$,u=a.child;if($.flags&16){var f=a.deletions;if(f!==null){for(var d=0;dCe()-td?_r(e,0):ed|=n),ot(e,t)}function $v(e,t){t===0&&(e.mode&1?(t=Cs,Cs<<=1,!(Cs&130023424)&&(Cs=4194304)):t=1);var n=Qe();e=gn(e,t),e!==null&&(Ho(e,t,n),ot(e,n))}function M1(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),$v(e,n)}function R1(e,t){var n=0;switch(e.tag){case 13:var i=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:i=e.stateNode;break;default:throw Error(b(314))}i!==null&&i.delete(t),$v(e,n)}var Uv;Uv=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||rt.current)nt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return nt=!1,y1(e,t,n);nt=!!(e.flags&131072)}else nt=!1,ve&&t.flags&1048576&&W_(t,pa,t.index);switch(t.lanes=0,t.tag){case 2:var i=t.type;Ks(e,t),e=t.pendingProps;var s=pi(t,qe.current);ai(t,n),s=qf(null,t,i,e,s,n);var a=Gf();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,it(i)?(a=!0,da(t)):a=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Zf(t),s.updater=Ha,t.stateNode=s,s._reactInternals=t,Dc(t,i,e,n),t=$c(null,t,i,!0,a,n)):(t.tag=0,ve&&a&&bf(t),Ge(null,t,s,n),t=t.child),t;case 16:i=t.elementType;e:{switch(Ks(e,t),e=t.pendingProps,s=i._init,i=s(i._payload),t.type=i,s=t.tag=A1(i),e=At(i,e),s){case 0:t=Fc(null,t,i,e,n);break e;case 1:t=Np(null,t,i,e,n);break e;case 11:t=Lp(null,t,i,e,n);break e;case 14:t=Op(null,t,i,At(i.type,e),n);break e}throw Error(b(306,i,""))}return t;case 0:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Fc(e,t,i,s,n);case 1:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Np(e,t,i,s,n);case 3:e:{if(Tv(t),e===null)throw Error(b(387));i=t.pendingProps,a=t.memoizedState,s=a.element,G_(e,t),va(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){s=gi(Error(b(423)),t),t=Mp(e,t,i,n,s);break e}else if(i!==s){s=gi(Error(b(424)),t),t=Mp(e,t,i,n,s);break e}else for(at=Un(t.stateNode.containerInfo.firstChild),ut=t,ve=!0,bt=null,n=X_(t,null,i,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(mi(),i===s){t=yn(e,t,n);break e}Ge(e,t,i,n)}t=t.child}return t;case 5:return ev(t),e===null&&jc(t),i=t.type,s=t.pendingProps,a=e!==null?e.memoizedProps:null,u=s.children,Nc(i,s)?u=null:a!==null&&Nc(i,a)&&(t.flags|=32),Ev(e,t),Ge(e,t,u,n),t.child;case 6:return e===null&&jc(t),null;case 13:return Cv(e,t,n);case 4:return Hf(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=_i(t,null,i,n):Ge(e,t,i,n),t.child;case 11:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Lp(e,t,i,s,n);case 7:return Ge(e,t,t.pendingProps,n),t.child;case 8:return Ge(e,t,t.pendingProps.children,n),t.child;case 12:return Ge(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(i=t.type._context,s=t.pendingProps,a=t.memoizedProps,u=s.value,he(ma,i._currentValue),i._currentValue=u,a!==null)if(Ft(a.value,u)){if(a.children===s.children&&!rt.current){t=yn(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=pn(-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),bc(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(b(341));u.lanes|=n,f=u.alternate,f!==null&&(f.lanes|=n),bc(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}Ge(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,i=t.pendingProps.children,ai(t,n),s=kt(s),i=i(s),t.flags|=1,Ge(e,t,i,n),t.child;case 14:return i=t.type,s=At(i,t.pendingProps),s=At(i.type,s),Op(e,t,i,s,n);case 15:return Sv(e,t,t.type,t.pendingProps,n);case 17:return i=t.type,s=t.pendingProps,s=t.elementType===i?s:At(i,s),Ks(e,t),t.tag=1,it(i)?(e=!0,da(t)):e=!1,ai(t,n),Y_(t,i,s),Dc(t,i,s,n),$c(null,t,i,!0,e,n);case 19:return kv(e,t,n);case 22:return Pv(e,t,n)}throw Error(b(156,t.tag))};function Zv(e,t){return m_(e,t)}function z1(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 Pt(e,t,n,i){return new z1(e,t,n,i)}function od(e){return e=e.prototype,!(!e||!e.isReactComponent)}function A1(e){if(typeof e=="function")return od(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Ef)return 11;if(e===Tf)return 14}return 2}function Vn(e,t){var n=e.alternate;return n===null?(n=Pt(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 Qs(e,t,n,i,s,a){var u=2;if(i=e,typeof e=="function")od(e)&&(u=1);else if(typeof e=="string")u=5;else e:switch(e){case Wr:return vr(n.children,s,a,t);case Pf:u=8,s|=8;break;case lc:return e=Pt(12,n,t,s|2),e.elementType=lc,e.lanes=a,e;case uc:return e=Pt(13,n,t,s),e.elementType=uc,e.lanes=a,e;case cc:return e=Pt(19,n,t,s),e.elementType=cc,e.lanes=a,e;case Jm:return qa(n,s,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Qm:u=10;break e;case Ym:u=9;break e;case Ef:u=11;break e;case Tf:u=14;break e;case Mn:u=16,i=null;break e}throw Error(b(130,e==null?e:typeof e,""))}return t=Pt(u,n,t,s),t.elementType=e,t.type=i,t.lanes=a,t}function vr(e,t,n,i){return e=Pt(7,e,i,t),e.lanes=n,e}function qa(e,t,n,i){return e=Pt(22,e,i,t),e.elementType=Jm,e.lanes=n,e.stateNode={isHidden:!1},e}function $u(e,t,n){return e=Pt(6,e,null,t),e.lanes=n,e}function Uu(e,t,n){return t=Pt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function j1(e,t,n,i,s){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=Su(0),this.expirationTimes=Su(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Su(0),this.identifierPrefix=i,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function sd(e,t,n,i,s,a,u,f,d){return e=new j1(e,t,n,f,d),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Pt(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Zf(a),e}function b1(e,t,n){var i=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Kv)}catch(e){console.error(e)}}Kv(),Wm.exports=dt;var qv=Wm.exports,Zp=qv;sc.createRoot=Zp.createRoot,sc.hydrateRoot=Zp.hydrateRoot;/** * @remix-run/router v1.9.0 * * Copyright (c) Remix Software Inc. @@ -46,7 +46,7 @@ Error generating stack: `+a.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function bo(){return bo=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function cd(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function $1(){return Math.random().toString(36).substr(2,8)}function Hp(e,t){return{usr:e.state,key:e.key,idx:t}}function Xc(e,t,n,i){return n===void 0&&(n=null),bo({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?ki(t):t,{state:n,key:t&&t.key||i||$1()})}function Ca(e){let{pathname:t="/",search:n="",hash:i=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),i&&i!=="#"&&(t+=i.charAt(0)==="#"?i:"#"+i),t}function ki(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let i=e.indexOf("?");i>=0&&(t.search=e.substr(i),e=e.substr(0,i)),e&&(t.pathname=e)}return t}function U1(e,t,n,i){i===void 0&&(i={});let{window:s=document.defaultView,v5Compat:a=!1}=i,u=s.history,f=Dn.Pop,d=null,p=m();p==null&&(p=0,u.replaceState(bo({},u.state,{idx:p}),""));function m(){return(u.state||{idx:null}).idx}function g(){f=Dn.Pop;let R=m(),S=R==null?null:R-p;p=R,d&&d({action:f,location:P.location,delta:S})}function y(R,S){f=Dn.Push;let w=Xc(P.location,R,S);n&&n(w,R),p=m()+1;let T=Hp(w,p),N=P.createHref(w);try{u.pushState(T,"",N)}catch(I){if(I instanceof DOMException&&I.name==="DataCloneError")throw I;s.location.assign(N)}a&&d&&d({action:f,location:P.location,delta:1})}function C(R,S){f=Dn.Replace;let w=Xc(P.location,R,S);n&&n(w,R),p=m();let T=Hp(w,p),N=P.createHref(w);u.replaceState(T,"",N),a&&d&&d({action:f,location:P.location,delta:0})}function x(R){let S=s.location.origin!=="null"?s.location.origin:s.location.href,w=typeof R=="string"?R:Ca(R);return ke(S,"No window.location.(origin|href) available to create URL for href: "+w),new URL(w,S)}let P={get action(){return f},get location(){return e(s,u)},listen(R){if(d)throw new Error("A history only accepts one active listener");return s.addEventListener(Zp,g),d=R,()=>{s.removeEventListener(Zp,g),d=null}},createHref(R){return t(s,R)},createURL:x,encodeLocation(R){let S=x(R);return{pathname:S.pathname,search:S.search,hash:S.hash}},push:y,replace:C,go(R){return u.go(R)}};return P}var Wp;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Wp||(Wp={}));function Z1(e,t,n){n===void 0&&(n="/");let i=typeof t=="string"?ki(t):t,s=fd(i.pathname||"/",n);if(s==null)return null;let a=qv(e);H1(a);let u=null;for(let f=0;u==null&&f{let d={relativePath:f===void 0?a.path||"":f,caseSensitive:a.caseSensitive===!0,childrenIndex:u,route:a};d.relativePath.startsWith("/")&&(ke(d.relativePath.startsWith(i),'Absolute route path "'+d.relativePath+'" nested under path '+('"'+i+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),d.relativePath=d.relativePath.slice(i.length));let p=Kn([i,d.relativePath]),m=n.concat(d);a.children&&a.children.length>0&&(ke(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+p+'".')),qv(a.children,t,m,p)),!(a.path==null&&!a.index)&&t.push({path:p,score:Y1(p,a.index),routesMeta:m})};return e.forEach((a,u)=>{var f;if(a.path===""||!((f=a.path)!=null&&f.includes("?")))s(a,u);else for(let d of Gv(a.path))s(a,u,d)}),t}function Gv(e){let t=e.split("/");if(t.length===0)return[];let[n,...i]=t,s=n.endsWith("?"),a=n.replace(/\?$/,"");if(i.length===0)return s?[a,""]:[a];let u=Gv(i.join("/")),f=[];return f.push(...u.map(d=>d===""?a:[a,d].join("/"))),s&&f.push(...u),f.map(d=>e.startsWith("/")&&d===""?"/":d)}function H1(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:J1(t.routesMeta.map(i=>i.childrenIndex),n.routesMeta.map(i=>i.childrenIndex)))}const W1=/^:\w+$/,V1=3,K1=2,q1=1,G1=10,Q1=-2,Vp=e=>e==="*";function Y1(e,t){let n=e.split("/"),i=n.length;return n.some(Vp)&&(i+=Q1),t&&(i+=K1),n.filter(s=>!Vp(s)).reduce((s,a)=>s+(W1.test(a)?V1:a===""?q1:G1),i)}function J1(e,t){return e.length===t.length&&e.slice(0,-1).every((i,s)=>i===t[s])?e[e.length-1]-t[t.length-1]:0}function X1(e,t){let{routesMeta:n}=e,i={},s="/",a=[];for(let u=0;u{if(m==="*"){let y=f[g]||"";u=a.slice(0,a.length-y.length).replace(/(.)\/+$/,"$1")}return p[m]=rx(f[g]||"",m),p},{}),pathname:a,pathnameBase:u,pattern:e}}function tx(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),cd(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let i=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/\/:(\w+)/g,(u,f)=>(i.push(f),"/([^\\/]+)"));return e.endsWith("*")?(i.push("*"),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),i]}function nx(e){try{return decodeURI(e)}catch(t){return cd(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function rx(e,t){try{return decodeURIComponent(e)}catch(n){return cd(!1,'The value for the URL param "'+t+'" will not be decoded because'+(' the string "'+e+'" is a malformed URL segment. This is probably')+(" due to a bad percent encoding ("+n+").")),e}}function fd(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,i=e.charAt(n);return i&&i!=="/"?null:e.slice(n)||"/"}function ix(e,t){t===void 0&&(t="/");let{pathname:n,search:i="",hash:s=""}=typeof e=="string"?ki(e):e;return{pathname:n?n.startsWith("/")?n:ox(n,t):t,search:ax(i),hash:lx(s)}}function ox(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function Zu(e,t,n,i){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(i)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function dd(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function hd(e,t,n,i){i===void 0&&(i=!1);let s;typeof e=="string"?s=ki(e):(s=bo({},e),ke(!s.pathname||!s.pathname.includes("?"),Zu("?","pathname","search",s)),ke(!s.pathname||!s.pathname.includes("#"),Zu("#","pathname","hash",s)),ke(!s.search||!s.search.includes("#"),Zu("#","search","hash",s)));let a=e===""||s.pathname==="",u=a?"/":s.pathname,f;if(i||u==null)f=n;else{let g=t.length-1;if(u.startsWith("..")){let y=u.split("/");for(;y[0]==="..";)y.shift(),g-=1;s.pathname=y.join("/")}f=g>=0?t[g]:"/"}let d=ix(s,f),p=u&&u!=="/"&&u.endsWith("/"),m=(a||u===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(p||m)&&(d.pathname+="/"),d}const Kn=e=>e.join("/").replace(/\/\/+/g,"/"),sx=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),ax=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,lx=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function ux(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Qv=["post","put","patch","delete"];new Set(Qv);const cx=["get",...Qv];new Set(cx);/** + */function Io(){return Io=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function cd(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function U1(){return Math.random().toString(36).substr(2,8)}function Wp(e,t){return{usr:e.state,key:e.key,idx:t}}function Xc(e,t,n,i){return n===void 0&&(n=null),Io({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Li(t):t,{state:n,key:t&&t.key||i||U1()})}function Ca(e){let{pathname:t="/",search:n="",hash:i=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),i&&i!=="#"&&(t+=i.charAt(0)==="#"?i:"#"+i),t}function Li(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let i=e.indexOf("?");i>=0&&(t.search=e.substr(i),e=e.substr(0,i)),e&&(t.pathname=e)}return t}function Z1(e,t,n,i){i===void 0&&(i={});let{window:s=document.defaultView,v5Compat:a=!1}=i,u=s.history,f=Dn.Pop,d=null,p=m();p==null&&(p=0,u.replaceState(Io({},u.state,{idx:p}),""));function m(){return(u.state||{idx:null}).idx}function g(){f=Dn.Pop;let R=m(),S=R==null?null:R-p;p=R,d&&d({action:f,location:P.location,delta:S})}function y(R,S){f=Dn.Push;let w=Xc(P.location,R,S);n&&n(w,R),p=m()+1;let T=Wp(w,p),N=P.createHref(w);try{u.pushState(T,"",N)}catch(I){if(I instanceof DOMException&&I.name==="DataCloneError")throw I;s.location.assign(N)}a&&d&&d({action:f,location:P.location,delta:1})}function C(R,S){f=Dn.Replace;let w=Xc(P.location,R,S);n&&n(w,R),p=m();let T=Wp(w,p),N=P.createHref(w);u.replaceState(T,"",N),a&&d&&d({action:f,location:P.location,delta:0})}function x(R){let S=s.location.origin!=="null"?s.location.origin:s.location.href,w=typeof R=="string"?R:Ca(R);return ke(S,"No window.location.(origin|href) available to create URL for href: "+w),new URL(w,S)}let P={get action(){return f},get location(){return e(s,u)},listen(R){if(d)throw new Error("A history only accepts one active listener");return s.addEventListener(Hp,g),d=R,()=>{s.removeEventListener(Hp,g),d=null}},createHref(R){return t(s,R)},createURL:x,encodeLocation(R){let S=x(R);return{pathname:S.pathname,search:S.search,hash:S.hash}},push:y,replace:C,go(R){return u.go(R)}};return P}var Vp;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Vp||(Vp={}));function H1(e,t,n){n===void 0&&(n="/");let i=typeof t=="string"?Li(t):t,s=fd(i.pathname||"/",n);if(s==null)return null;let a=Gv(e);W1(a);let u=null;for(let f=0;u==null&&f{let d={relativePath:f===void 0?a.path||"":f,caseSensitive:a.caseSensitive===!0,childrenIndex:u,route:a};d.relativePath.startsWith("/")&&(ke(d.relativePath.startsWith(i),'Absolute route path "'+d.relativePath+'" nested under path '+('"'+i+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),d.relativePath=d.relativePath.slice(i.length));let p=Kn([i,d.relativePath]),m=n.concat(d);a.children&&a.children.length>0&&(ke(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+p+'".')),Gv(a.children,t,m,p)),!(a.path==null&&!a.index)&&t.push({path:p,score:J1(p,a.index),routesMeta:m})};return e.forEach((a,u)=>{var f;if(a.path===""||!((f=a.path)!=null&&f.includes("?")))s(a,u);else for(let d of Qv(a.path))s(a,u,d)}),t}function Qv(e){let t=e.split("/");if(t.length===0)return[];let[n,...i]=t,s=n.endsWith("?"),a=n.replace(/\?$/,"");if(i.length===0)return s?[a,""]:[a];let u=Qv(i.join("/")),f=[];return f.push(...u.map(d=>d===""?a:[a,d].join("/"))),s&&f.push(...u),f.map(d=>e.startsWith("/")&&d===""?"/":d)}function W1(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:X1(t.routesMeta.map(i=>i.childrenIndex),n.routesMeta.map(i=>i.childrenIndex)))}const V1=/^:\w+$/,K1=3,q1=2,G1=1,Q1=10,Y1=-2,Kp=e=>e==="*";function J1(e,t){let n=e.split("/"),i=n.length;return n.some(Kp)&&(i+=Y1),t&&(i+=q1),n.filter(s=>!Kp(s)).reduce((s,a)=>s+(V1.test(a)?K1:a===""?G1:Q1),i)}function X1(e,t){return e.length===t.length&&e.slice(0,-1).every((i,s)=>i===t[s])?e[e.length-1]-t[t.length-1]:0}function ex(e,t){let{routesMeta:n}=e,i={},s="/",a=[];for(let u=0;u{if(m==="*"){let y=f[g]||"";u=a.slice(0,a.length-y.length).replace(/(.)\/+$/,"$1")}return p[m]=ix(f[g]||"",m),p},{}),pathname:a,pathnameBase:u,pattern:e}}function nx(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),cd(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let i=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/\/:(\w+)/g,(u,f)=>(i.push(f),"/([^\\/]+)"));return e.endsWith("*")?(i.push("*"),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),i]}function rx(e){try{return decodeURI(e)}catch(t){return cd(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function ix(e,t){try{return decodeURIComponent(e)}catch(n){return cd(!1,'The value for the URL param "'+t+'" will not be decoded because'+(' the string "'+e+'" is a malformed URL segment. This is probably')+(" due to a bad percent encoding ("+n+").")),e}}function fd(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,i=e.charAt(n);return i&&i!=="/"?null:e.slice(n)||"/"}function ox(e,t){t===void 0&&(t="/");let{pathname:n,search:i="",hash:s=""}=typeof e=="string"?Li(e):e;return{pathname:n?n.startsWith("/")?n:sx(n,t):t,search:lx(i),hash:ux(s)}}function sx(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function Zu(e,t,n,i){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(i)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function dd(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function hd(e,t,n,i){i===void 0&&(i=!1);let s;typeof e=="string"?s=Li(e):(s=Io({},e),ke(!s.pathname||!s.pathname.includes("?"),Zu("?","pathname","search",s)),ke(!s.pathname||!s.pathname.includes("#"),Zu("#","pathname","hash",s)),ke(!s.search||!s.search.includes("#"),Zu("#","search","hash",s)));let a=e===""||s.pathname==="",u=a?"/":s.pathname,f;if(i||u==null)f=n;else{let g=t.length-1;if(u.startsWith("..")){let y=u.split("/");for(;y[0]==="..";)y.shift(),g-=1;s.pathname=y.join("/")}f=g>=0?t[g]:"/"}let d=ox(s,f),p=u&&u!=="/"&&u.endsWith("/"),m=(a||u===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(p||m)&&(d.pathname+="/"),d}const Kn=e=>e.join("/").replace(/\/\/+/g,"/"),ax=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),lx=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,ux=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function cx(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Yv=["post","put","patch","delete"];new Set(Yv);const fx=["get",...Yv];new Set(fx);/** * React Router v6.16.0 * * Copyright (c) Remix Software Inc. @@ -55,7 +55,7 @@ Error generating stack: `+a.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function ka(){return ka=Object.assign?Object.assign.bind():function(e){for(var t=1;td.pathnameBase)),u=j.useRef(!1);return Jv(()=>{u.current=!0}),j.useCallback(function(d,p){if(p===void 0&&(p={}),!u.current)return;if(typeof d=="number"){n.go(d);return}let m=hd(d,JSON.parse(a),s,p.relative==="path");e==null&&t!=="/"&&(m.pathname=m.pathname==="/"?t:Kn([t,m.pathname])),(p.replace?n.replace:n.push)(m,p.state,p)},[t,n,a,s,e])}function px(){let{matches:e}=j.useContext(Sn),t=e[e.length-1];return t?t.params:{}}function eg(e,t){let{relative:n}=t===void 0?{}:t,{matches:i}=j.useContext(Sn),{pathname:s}=Ko(),a=JSON.stringify(dd(i).map(u=>u.pathnameBase));return j.useMemo(()=>hd(e,JSON.parse(a),s,n==="path"),[e,a,s,n])}function mx(e,t){return _x(e,t)}function _x(e,t,n){Oi()||ke(!1);let{navigator:i}=j.useContext(Li),{matches:s}=j.useContext(Sn),a=s[s.length-1],u=a?a.params:{};a&&a.pathname;let f=a?a.pathnameBase:"/";a&&a.route;let d=Ko(),p;if(t){var m;let P=typeof t=="string"?ki(t):t;f==="/"||(m=P.pathname)!=null&&m.startsWith(f)||ke(!1),p=P}else p=d;let g=p.pathname||"/",y=f==="/"?g:g.slice(f.length)||"/",C=Z1(e,{pathname:y}),x=xx(C&&C.map(P=>Object.assign({},P,{params:Object.assign({},u,P.params),pathname:Kn([f,i.encodeLocation?i.encodeLocation(P.pathname).pathname:P.pathname]),pathnameBase:P.pathnameBase==="/"?f:Kn([f,i.encodeLocation?i.encodeLocation(P.pathnameBase).pathname:P.pathnameBase])})),s,n);return t&&x?j.createElement(Xa.Provider,{value:{location:ka({pathname:"/",search:"",hash:"",state:null,key:"default"},p),navigationType:Dn.Pop}},x):x}function vx(){let e=Tx(),t=ux(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},a=null;return j.createElement(j.Fragment,null,j.createElement("h2",null,"Unexpected Application Error!"),j.createElement("h3",{style:{fontStyle:"italic"}},t),n?j.createElement("pre",{style:s},n):null,a)}const gx=j.createElement(vx,null);class yx extends j.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error||n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error?j.createElement(Sn.Provider,{value:this.props.routeContext},j.createElement(Yv.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function wx(e){let{routeContext:t,match:n,children:i}=e,s=j.useContext(pd);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),j.createElement(Sn.Provider,{value:t},i)}function xx(e,t,n){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),e==null){var s;if((s=n)!=null&&s.errors)e=n.matches;else return null}let a=e,u=(i=n)==null?void 0:i.errors;if(u!=null){let f=a.findIndex(d=>d.route.id&&(u==null?void 0:u[d.route.id]));f>=0||ke(!1),a=a.slice(0,Math.min(a.length,f+1))}return a.reduceRight((f,d,p)=>{let m=d.route.id?u==null?void 0:u[d.route.id]:null,g=null;n&&(g=d.route.errorElement||gx);let y=t.concat(a.slice(0,p+1)),C=()=>{let x;return m?x=g:d.route.Component?x=j.createElement(d.route.Component,null):d.route.element?x=d.route.element:x=f,j.createElement(wx,{match:d,routeContext:{outlet:f,matches:y,isDataRoute:n!=null},children:x})};return n&&(d.route.ErrorBoundary||d.route.errorElement||p===0)?j.createElement(yx,{location:n.location,revalidation:n.revalidation,component:g,error:m,children:C(),routeContext:{outlet:null,matches:y,isDataRoute:!0}}):C()},null)}var tg=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(tg||{}),La=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(La||{});function Sx(e){let t=j.useContext(pd);return t||ke(!1),t}function Px(e){let t=j.useContext(fx);return t||ke(!1),t}function Ex(e){let t=j.useContext(Sn);return t||ke(!1),t}function ng(e){let t=Ex(),n=t.matches[t.matches.length-1];return n.route.id||ke(!1),n.route.id}function Tx(){var e;let t=j.useContext(Yv),n=Px(La.UseRouteError),i=ng(La.UseRouteError);return t||((e=n.errors)==null?void 0:e[i])}function Cx(){let{router:e}=Sx(tg.UseNavigateStable),t=ng(La.UseNavigateStable),n=j.useRef(!1);return Jv(()=>{n.current=!0}),j.useCallback(function(s,a){a===void 0&&(a={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,ka({fromRouteId:t},a)))},[e,t])}function md(e){let{to:t,replace:n,state:i,relative:s}=e;Oi()||ke(!1);let{matches:a}=j.useContext(Sn),{pathname:u}=Ko(),f=Xv(),d=hd(t,dd(a).map(m=>m.pathnameBase),u,s==="path"),p=JSON.stringify(d);return j.useEffect(()=>f(JSON.parse(p),{replace:n,state:i,relative:s}),[f,p,s,n,i]),null}function Zr(e){ke(!1)}function kx(e){let{basename:t="/",children:n=null,location:i,navigationType:s=Dn.Pop,navigator:a,static:u=!1}=e;Oi()&&ke(!1);let f=t.replace(/^\/*/,"/"),d=j.useMemo(()=>({basename:f,navigator:a,static:u}),[f,a,u]);typeof i=="string"&&(i=ki(i));let{pathname:p="/",search:m="",hash:g="",state:y=null,key:C="default"}=i,x=j.useMemo(()=>{let P=fd(p,f);return P==null?null:{location:{pathname:P,search:m,hash:g,state:y,key:C},navigationType:s}},[f,p,m,g,y,C,s]);return x==null?null:j.createElement(Li.Provider,{value:d},j.createElement(Xa.Provider,{children:n,value:x}))}function Lx(e){let{children:t,location:n}=e;return mx(ef(t),n)}new Promise(()=>{});function ef(e,t){t===void 0&&(t=[]);let n=[];return j.Children.forEach(e,(i,s)=>{if(!j.isValidElement(i))return;let a=[...t,s];if(i.type===j.Fragment){n.push.apply(n,ef(i.props.children,a));return}i.type!==Zr&&ke(!1),!i.props.index||!i.props.children||ke(!1);let u={id:i.props.id||a.join("-"),caseSensitive:i.props.caseSensitive,element:i.props.element,Component:i.props.Component,index:i.props.index,path:i.props.path,loader:i.props.loader,action:i.props.action,errorElement:i.props.errorElement,ErrorBoundary:i.props.ErrorBoundary,hasErrorBoundary:i.props.ErrorBoundary!=null||i.props.errorElement!=null,shouldRevalidate:i.props.shouldRevalidate,handle:i.props.handle,lazy:i.props.lazy};i.props.children&&(u.children=ef(i.props.children,a)),n.push(u)}),n}/** + */function ka(){return ka=Object.assign?Object.assign.bind():function(e){for(var t=1;td.pathnameBase)),u=j.useRef(!1);return Xv(()=>{u.current=!0}),j.useCallback(function(d,p){if(p===void 0&&(p={}),!u.current)return;if(typeof d=="number"){n.go(d);return}let m=hd(d,JSON.parse(a),s,p.relative==="path");e==null&&t!=="/"&&(m.pathname=m.pathname==="/"?t:Kn([t,m.pathname])),(p.replace?n.replace:n.push)(m,p.state,p)},[t,n,a,s,e])}function mx(){let{matches:e}=j.useContext(Sn),t=e[e.length-1];return t?t.params:{}}function tg(e,t){let{relative:n}=t===void 0?{}:t,{matches:i}=j.useContext(Sn),{pathname:s}=qo(),a=JSON.stringify(dd(i).map(u=>u.pathnameBase));return j.useMemo(()=>hd(e,JSON.parse(a),s,n==="path"),[e,a,s,n])}function _x(e,t){return vx(e,t)}function vx(e,t,n){Ni()||ke(!1);let{navigator:i}=j.useContext(Oi),{matches:s}=j.useContext(Sn),a=s[s.length-1],u=a?a.params:{};a&&a.pathname;let f=a?a.pathnameBase:"/";a&&a.route;let d=qo(),p;if(t){var m;let P=typeof t=="string"?Li(t):t;f==="/"||(m=P.pathname)!=null&&m.startsWith(f)||ke(!1),p=P}else p=d;let g=p.pathname||"/",y=f==="/"?g:g.slice(f.length)||"/",C=H1(e,{pathname:y}),x=Sx(C&&C.map(P=>Object.assign({},P,{params:Object.assign({},u,P.params),pathname:Kn([f,i.encodeLocation?i.encodeLocation(P.pathname).pathname:P.pathname]),pathnameBase:P.pathnameBase==="/"?f:Kn([f,i.encodeLocation?i.encodeLocation(P.pathnameBase).pathname:P.pathnameBase])})),s,n);return t&&x?j.createElement(Xa.Provider,{value:{location:ka({pathname:"/",search:"",hash:"",state:null,key:"default"},p),navigationType:Dn.Pop}},x):x}function gx(){let e=Cx(),t=cx(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"},a=null;return j.createElement(j.Fragment,null,j.createElement("h2",null,"Unexpected Application Error!"),j.createElement("h3",{style:{fontStyle:"italic"}},t),n?j.createElement("pre",{style:s},n):null,a)}const yx=j.createElement(gx,null);class wx extends j.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error||n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error?j.createElement(Sn.Provider,{value:this.props.routeContext},j.createElement(Jv.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function xx(e){let{routeContext:t,match:n,children:i}=e,s=j.useContext(pd);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),j.createElement(Sn.Provider,{value:t},i)}function Sx(e,t,n){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),e==null){var s;if((s=n)!=null&&s.errors)e=n.matches;else return null}let a=e,u=(i=n)==null?void 0:i.errors;if(u!=null){let f=a.findIndex(d=>d.route.id&&(u==null?void 0:u[d.route.id]));f>=0||ke(!1),a=a.slice(0,Math.min(a.length,f+1))}return a.reduceRight((f,d,p)=>{let m=d.route.id?u==null?void 0:u[d.route.id]:null,g=null;n&&(g=d.route.errorElement||yx);let y=t.concat(a.slice(0,p+1)),C=()=>{let x;return m?x=g:d.route.Component?x=j.createElement(d.route.Component,null):d.route.element?x=d.route.element:x=f,j.createElement(xx,{match:d,routeContext:{outlet:f,matches:y,isDataRoute:n!=null},children:x})};return n&&(d.route.ErrorBoundary||d.route.errorElement||p===0)?j.createElement(wx,{location:n.location,revalidation:n.revalidation,component:g,error:m,children:C(),routeContext:{outlet:null,matches:y,isDataRoute:!0}}):C()},null)}var ng=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(ng||{}),La=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(La||{});function Px(e){let t=j.useContext(pd);return t||ke(!1),t}function Ex(e){let t=j.useContext(dx);return t||ke(!1),t}function Tx(e){let t=j.useContext(Sn);return t||ke(!1),t}function rg(e){let t=Tx(),n=t.matches[t.matches.length-1];return n.route.id||ke(!1),n.route.id}function Cx(){var e;let t=j.useContext(Jv),n=Ex(La.UseRouteError),i=rg(La.UseRouteError);return t||((e=n.errors)==null?void 0:e[i])}function kx(){let{router:e}=Px(ng.UseNavigateStable),t=rg(La.UseNavigateStable),n=j.useRef(!1);return Xv(()=>{n.current=!0}),j.useCallback(function(s,a){a===void 0&&(a={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,ka({fromRouteId:t},a)))},[e,t])}function md(e){let{to:t,replace:n,state:i,relative:s}=e;Ni()||ke(!1);let{matches:a}=j.useContext(Sn),{pathname:u}=qo(),f=eg(),d=hd(t,dd(a).map(m=>m.pathnameBase),u,s==="path"),p=JSON.stringify(d);return j.useEffect(()=>f(JSON.parse(p),{replace:n,state:i,relative:s}),[f,p,s,n,i]),null}function Zr(e){ke(!1)}function Lx(e){let{basename:t="/",children:n=null,location:i,navigationType:s=Dn.Pop,navigator:a,static:u=!1}=e;Ni()&&ke(!1);let f=t.replace(/^\/*/,"/"),d=j.useMemo(()=>({basename:f,navigator:a,static:u}),[f,a,u]);typeof i=="string"&&(i=Li(i));let{pathname:p="/",search:m="",hash:g="",state:y=null,key:C="default"}=i,x=j.useMemo(()=>{let P=fd(p,f);return P==null?null:{location:{pathname:P,search:m,hash:g,state:y,key:C},navigationType:s}},[f,p,m,g,y,C,s]);return x==null?null:j.createElement(Oi.Provider,{value:d},j.createElement(Xa.Provider,{children:n,value:x}))}function Ox(e){let{children:t,location:n}=e;return _x(ef(t),n)}new Promise(()=>{});function ef(e,t){t===void 0&&(t=[]);let n=[];return j.Children.forEach(e,(i,s)=>{if(!j.isValidElement(i))return;let a=[...t,s];if(i.type===j.Fragment){n.push.apply(n,ef(i.props.children,a));return}i.type!==Zr&&ke(!1),!i.props.index||!i.props.children||ke(!1);let u={id:i.props.id||a.join("-"),caseSensitive:i.props.caseSensitive,element:i.props.element,Component:i.props.Component,index:i.props.index,path:i.props.path,loader:i.props.loader,action:i.props.action,errorElement:i.props.errorElement,ErrorBoundary:i.props.ErrorBoundary,hasErrorBoundary:i.props.ErrorBoundary!=null||i.props.errorElement!=null,shouldRevalidate:i.props.shouldRevalidate,handle:i.props.handle,lazy:i.props.lazy};i.props.children&&(u.children=ef(i.props.children,a)),n.push(u)}),n}/** * React Router DOM v6.16.0 * * Copyright (c) Remix Software Inc. @@ -64,10 +64,10 @@ Error generating stack: `+a.message+` * LICENSE.md file in the root directory of this source tree. * * @license MIT - */function tf(){return tf=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[s]=e[s]);return n}function Nx(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Mx(e,t){return e.button===0&&(!t||t==="_self")&&!Nx(e)}const Rx=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset"],zx="startTransition",Kp=N0[zx];function Ax(e){let{basename:t,children:n,future:i,window:s}=e,a=j.useRef();a.current==null&&(a.current=F1({window:s,v5Compat:!0}));let u=a.current,[f,d]=j.useState({action:u.action,location:u.location}),{v7_startTransition:p}=i||{},m=j.useCallback(g=>{p&&Kp?Kp(()=>d(g)):d(g)},[d,p]);return j.useLayoutEffect(()=>u.listen(m),[u,m]),j.createElement(kx,{basename:t,children:n,location:f.location,navigationType:f.action,navigator:u})}const jx=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",bx=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,at=j.forwardRef(function(t,n){let{onClick:i,relative:s,reloadDocument:a,replace:u,state:f,target:d,to:p,preventScrollReset:m}=t,g=Ox(t,Rx),{basename:y}=j.useContext(Li),C,x=!1;if(typeof p=="string"&&bx.test(p)&&(C=p,jx))try{let w=new URL(window.location.href),T=p.startsWith("//")?new URL(w.protocol+p):new URL(p),N=fd(T.pathname,y);T.origin===w.origin&&N!=null?p=N+T.search+T.hash:x=!0}catch{}let P=dx(p,{relative:s}),R=Ix(p,{replace:u,state:f,target:d,preventScrollReset:m,relative:s});function S(w){i&&i(w),w.defaultPrevented||R(w)}return j.createElement("a",tf({},g,{href:C||P,onClick:x||a?i:S,ref:n,target:d}))});var qp;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher"})(qp||(qp={}));var Gp;(function(e){e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Gp||(Gp={}));function Ix(e,t){let{target:n,replace:i,state:s,preventScrollReset:a,relative:u}=t===void 0?{}:t,f=Xv(),d=Ko(),p=eg(e,{relative:u});return j.useCallback(m=>{if(Mx(m,n)){m.preventDefault();let g=i!==void 0?i:Ca(d)===Ca(p);f(e,{replace:g,state:s,preventScrollReset:a,relative:u})}},[d,f,p,i,s,n,e,a,u])}var rg={exports:{}},Dx="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",Bx=Dx,Fx=Bx;function ig(){}function og(){}og.resetWarningCache=ig;var $x=function(){function e(i,s,a,u,f,d){if(d!==Fx){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:og,resetWarningCache:ig};return n.PropTypes=n,n};rg.exports=$x();var Ux=rg.exports;const J=$o(Ux);var Zx=typeof Element<"u",Hx=typeof Map=="function",Wx=typeof Set=="function",Vx=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function Ys(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,i,s;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(!Ys(e[i],t[i]))return!1;return!0}var a;if(Hx&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(a=e.entries();!(i=a.next()).done;)if(!t.has(i.value[0]))return!1;for(a=e.entries();!(i=a.next()).done;)if(!Ys(i.value[1],t.get(i.value[0])))return!1;return!0}if(Wx&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(a=e.entries();!(i=a.next()).done;)if(!t.has(i.value[0]))return!1;return!0}if(Vx&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(e[i]!==t[i])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,s[i]))return!1;if(Zx&&e instanceof Element)return!1;for(i=n;i--!==0;)if(!((s[i]==="_owner"||s[i]==="__v"||s[i]==="__o")&&e.$$typeof)&&!Ys(e[s[i]],t[s[i]]))return!1;return!0}return e!==e&&t!==t}var Kx=function(t,n){try{return Ys(t,n)}catch(i){if((i.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw i}};const qx=$o(Kx);var Gx=function(e,t,n,i,s,a,u,f){if(!e){var d;if(t===void 0)d=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var p=[n,i,s,a,u,f],m=0;d=new Error(t.replace(/%s/g,function(){return p[m++]})),d.name="Invariant Violation"}throw d.framesToPop=1,d}},Qx=Gx;const Qp=$o(Qx);var Yx=function(t,n,i,s){var a=i?i.call(s,t,n):void 0;if(a!==void 0)return!!a;if(t===n)return!0;if(typeof t!="object"||!t||typeof n!="object"||!n)return!1;var u=Object.keys(t),f=Object.keys(n);if(u.length!==f.length)return!1;for(var d=Object.prototype.hasOwnProperty.bind(n),p=0;p=0||(s[n]=e[n]);return s}var V={BASE:"base",BODY:"body",HEAD:"head",HTML:"html",LINK:"link",META:"meta",NOSCRIPT:"noscript",SCRIPT:"script",STYLE:"style",TITLE:"title",FRAGMENT:"Symbol(react.fragment)"},Xx={rel:["amphtml","canonical","alternate"]},eS={type:["application/ld+json"]},tS={charset:"",name:["robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]},Jp=Object.keys(V).map(function(e){return V[e]}),Oa={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},nS=Object.keys(Oa).reduce(function(e,t){return e[Oa[t]]=t,e},{}),ui=function(e,t){for(var n=e.length-1;n>=0;n-=1){var i=e[n];if(Object.prototype.hasOwnProperty.call(i,t))return i[t]}return null},rS=function(e){var t=ui(e,V.TITLE),n=ui(e,"titleTemplate");if(Array.isArray(t)&&(t=t.join("")),n&&t)return n.replace(/%s/g,function(){return t});var i=ui(e,"defaultTitle");return t||i||void 0},iS=function(e){return ui(e,"onChangeClientState")||function(){}},Hu=function(e,t){return t.filter(function(n){return n[e]!==void 0}).map(function(n){return n[e]}).reduce(function(n,i){return Te({},n,i)},{})},oS=function(e,t){return t.filter(function(n){return n[V.BASE]!==void 0}).map(function(n){return n[V.BASE]}).reverse().reduce(function(n,i){if(!n.length)for(var s=Object.keys(i),a=0;a/g,">").replace(/"/g,""").replace(/'/g,"'")},em=function(e){return Object.keys(e).reduce(function(t,n){var i=e[n]!==void 0?n+'="'+e[n]+'"':""+n;return t?t+" "+i:i},"")},tm=function(e,t){return t===void 0&&(t={}),Object.keys(e).reduce(function(n,i){return n[Oa[i]||i]=e[i],n},t)},Js=function(e,t){return t.map(function(n,i){var s,a=((s={key:i})["data-rh"]=!0,s);return Object.keys(n).forEach(function(u){var f=Oa[u]||u;f==="innerHTML"||f==="cssText"?a.dangerouslySetInnerHTML={__html:n.innerHTML||n.cssText}:a[f]=n[u]}),Gt.createElement(e,a)})},yt=function(e,t,n){switch(e){case V.TITLE:return{toComponent:function(){return s=t.titleAttributes,(a={key:i=t.title})["data-rh"]=!0,u=tm(s,a),[Gt.createElement(V.TITLE,u,i)];var i,s,a,u},toString:function(){return function(i,s,a,u){var f=em(a),d=sg(s);return f?"<"+i+' data-rh="true" '+f+">"+Vu(d,u)+"":"<"+i+' data-rh="true">'+Vu(d,u)+""}(e,t.title,t.titleAttributes,n)}};case"bodyAttributes":case"htmlAttributes":return{toComponent:function(){return tm(t)},toString:function(){return em(t)}};default:return{toComponent:function(){return Js(e,t)},toString:function(){return function(i,s,a){return s.reduce(function(u,f){var d=Object.keys(f).filter(function(g){return!(g==="innerHTML"||g==="cssText")}).reduce(function(g,y){var C=f[y]===void 0?y:y+'="'+Vu(f[y],a)+'"';return g?g+" "+C:C},""),p=f.innerHTML||f.cssText||"",m=aS.indexOf(i)===-1;return u+"<"+i+' data-rh="true" '+d+(m?"/>":">"+p+"")},"")}(e,t,n)}}}},rf=function(e){var t=e.baseTag,n=e.bodyAttributes,i=e.encode,s=e.htmlAttributes,a=e.noscriptTags,u=e.styleTags,f=e.title,d=f===void 0?"":f,p=e.titleAttributes,m=e.linkTags,g=e.metaTags,y=e.scriptTags,C={toComponent:function(){},toString:function(){return""}};if(e.prioritizeSeoTags){var x=function(P){var R=P.linkTags,S=P.scriptTags,w=P.encode,T=Wu(P.metaTags,tS),N=Wu(R,Xx),I=Wu(S,eS);return{priorityMethods:{toComponent:function(){return[].concat(Js(V.META,T.priority),Js(V.LINK,N.priority),Js(V.SCRIPT,I.priority))},toString:function(){return yt(V.META,T.priority,w)+" "+yt(V.LINK,N.priority,w)+" "+yt(V.SCRIPT,I.priority,w)}},metaTags:T.default,linkTags:N.default,scriptTags:I.default}}(e);C=x.priorityMethods,m=x.linkTags,g=x.metaTags,y=x.scriptTags}return{priority:C,base:yt(V.BASE,t,i),bodyAttributes:yt("bodyAttributes",n,i),htmlAttributes:yt("htmlAttributes",s,i),link:yt(V.LINK,m,i),meta:yt(V.META,g,i),noscript:yt(V.NOSCRIPT,a,i),script:yt(V.SCRIPT,y,i),style:yt(V.STYLE,u,i),title:yt(V.TITLE,{title:d,titleAttributes:p},i)}},Ds=[],of=function(e,t){var n=this;t===void 0&&(t=typeof document<"u"),this.instances=[],this.value={setHelmet:function(i){n.context.helmet=i},helmetInstances:{get:function(){return n.canUseDOM?Ds:n.instances},add:function(i){(n.canUseDOM?Ds:n.instances).push(i)},remove:function(i){var s=(n.canUseDOM?Ds:n.instances).indexOf(i);(n.canUseDOM?Ds:n.instances).splice(s,1)}}},this.context=e,this.canUseDOM=t,t||(e.helmet=rf({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))},ag=Gt.createContext({}),lS=J.shape({setHelmet:J.func,helmetInstances:J.shape({get:J.func,add:J.func,remove:J.func})}),uS=typeof document<"u",ni=function(e){function t(n){var i;return(i=e.call(this,n)||this).helmetData=new of(i.props.context,t.canUseDOM),i}return _d(t,e),t.prototype.render=function(){return Gt.createElement(ag.Provider,{value:this.helmetData.value},this.props.children)},t}(j.Component);ni.canUseDOM=uS,ni.propTypes={context:J.shape({helmet:J.shape()}),children:J.node.isRequired},ni.defaultProps={context:{}},ni.displayName="HelmetProvider";var Ur=function(e,t){var n,i=document.head||document.querySelector(V.HEAD),s=i.querySelectorAll(e+"[data-rh]"),a=[].slice.call(s),u=[];return t&&t.length&&t.forEach(function(f){var d=document.createElement(e);for(var p in f)Object.prototype.hasOwnProperty.call(f,p)&&(p==="innerHTML"?d.innerHTML=f.innerHTML:p==="cssText"?d.styleSheet?d.styleSheet.cssText=f.cssText:d.appendChild(document.createTextNode(f.cssText)):d.setAttribute(p,f[p]===void 0?"":f[p]));d.setAttribute("data-rh","true"),a.some(function(m,g){return n=g,d.isEqualNode(m)})?a.splice(n,1):u.push(d)}),a.forEach(function(f){return f.parentNode.removeChild(f)}),u.forEach(function(f){return i.appendChild(f)}),{oldTags:a,newTags:u}},Ku=function(e,t){var n=document.getElementsByTagName(e)[0];if(n){for(var i=n.getAttribute("data-rh"),s=i?i.split(","):[],a=[].concat(s),u=Object.keys(t),f=0;f=0;g-=1)n.removeAttribute(a[g]);s.length===a.length?n.removeAttribute("data-rh"):n.getAttribute("data-rh")!==u.join(",")&&n.setAttribute("data-rh",u.join(","))}},nm=function(e,t){var n=e.baseTag,i=e.htmlAttributes,s=e.linkTags,a=e.metaTags,u=e.noscriptTags,f=e.onChangeClientState,d=e.scriptTags,p=e.styleTags,m=e.title,g=e.titleAttributes;Ku(V.BODY,e.bodyAttributes),Ku(V.HTML,i),function(P,R){P!==void 0&&document.title!==P&&(document.title=sg(P)),Ku(V.TITLE,R)}(m,g);var y={baseTag:Ur(V.BASE,n),linkTags:Ur(V.LINK,s),metaTags:Ur(V.META,a),noscriptTags:Ur(V.NOSCRIPT,u),scriptTags:Ur(V.SCRIPT,d),styleTags:Ur(V.STYLE,p)},C={},x={};Object.keys(y).forEach(function(P){var R=y[P],S=R.newTags,w=R.oldTags;S.length&&(C[P]=S),w.length&&(x[P]=y[P].oldTags)}),t&&t(),f(e,C,x)},no=null,Na=function(e){function t(){for(var i,s=arguments.length,a=new Array(s),u=0;u elements are self-closing and can not contain children. Refer to our API for more information.")}},n.flattenArrayTypeChildren=function(i){var s,a=i.child,u=i.arrayTypeChildren;return Te({},u,((s={})[a.type]=[].concat(u[a.type]||[],[Te({},i.newChildProps,this.mapNestedChildrenToProps(a,i.nestedChildren))]),s))},n.mapObjectTypeChildren=function(i){var s,a,u=i.child,f=i.newProps,d=i.newChildProps,p=i.nestedChildren;switch(u.type){case V.TITLE:return Te({},f,((s={})[u.type]=p,s.titleAttributes=Te({},d),s));case V.BODY:return Te({},f,{bodyAttributes:Te({},d)});case V.HTML:return Te({},f,{htmlAttributes:Te({},d)});default:return Te({},f,((a={})[u.type]=Te({},d),a))}},n.mapArrayTypeChildrenToProps=function(i,s){var a=Te({},s);return Object.keys(i).forEach(function(u){var f;a=Te({},a,((f={})[u]=i[u],f))}),a},n.warnOnInvalidChildren=function(i,s){return Qp(Jp.some(function(a){return i.type===a}),typeof i.type=="function"?"You may be attempting to nest components within each other, which is not allowed. Refer to our API for more information.":"Only elements types "+Jp.join(", ")+" are allowed. Helmet does not support rendering <"+i.type+"> elements. Refer to our API for more information."),Qp(!s||typeof s=="string"||Array.isArray(s)&&!s.some(function(a){return typeof a!="string"}),"Helmet expects a string as a child of <"+i.type+">. Did you forget to wrap your children in braces? ( <"+i.type+">{``} ) Refer to our API for more information."),!0},n.mapChildrenToProps=function(i,s){var a=this,u={};return Gt.Children.forEach(i,function(f){if(f&&f.props){var d=f.props,p=d.children,m=Yp(d,cS),g=Object.keys(m).reduce(function(C,x){return C[nS[x]||x]=m[x],C},{}),y=f.type;switch(typeof y=="symbol"?y=y.toString():a.warnOnInvalidChildren(f,p),y){case V.FRAGMENT:s=a.mapChildrenToProps(p,s);break;case V.LINK:case V.META:case V.NOSCRIPT:case V.SCRIPT:case V.STYLE:u=a.flattenArrayTypeChildren({child:f,arrayTypeChildren:u,newChildProps:g,nestedChildren:p});break;default:s=a.mapObjectTypeChildren({child:f,newProps:s,newChildProps:g,nestedChildren:p})}}}),this.mapArrayTypeChildrenToProps(u,s)},n.render=function(){var i=this.props,s=i.children,a=Yp(i,fS),u=Te({},a),f=a.helmetData;return s&&(u=this.mapChildrenToProps(s,u)),!f||f instanceof of||(f=new of(f.context,f.instances)),f?Gt.createElement(Na,Te({},u,{context:f.value,helmetData:void 0})):Gt.createElement(ag.Consumer,null,function(d){return Gt.createElement(Na,Te({},u,{context:d}))})},t}(j.Component);qn.propTypes={base:J.object,bodyAttributes:J.object,children:J.oneOfType([J.arrayOf(J.node),J.node]),defaultTitle:J.string,defer:J.bool,encodeSpecialCharacters:J.bool,htmlAttributes:J.object,link:J.arrayOf(J.object),meta:J.arrayOf(J.object),noscript:J.arrayOf(J.object),onChangeClientState:J.func,script:J.arrayOf(J.object),style:J.arrayOf(J.object),title:J.string,titleAttributes:J.object,titleTemplate:J.string,prioritizeSeoTags:J.bool,helmetData:J.object},qn.defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1},qn.displayName="Helmet";var sf={exports:{}};/* @preserve + */function tf(){return tf=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0)&&(n[s]=e[s]);return n}function Mx(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function Rx(e,t){return e.button===0&&(!t||t==="_self")&&!Mx(e)}const zx=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset"],Ax="startTransition",qp=M0[Ax];function jx(e){let{basename:t,children:n,future:i,window:s}=e,a=j.useRef();a.current==null&&(a.current=$1({window:s,v5Compat:!0}));let u=a.current,[f,d]=j.useState({action:u.action,location:u.location}),{v7_startTransition:p}=i||{},m=j.useCallback(g=>{p&&qp?qp(()=>d(g)):d(g)},[d,p]);return j.useLayoutEffect(()=>u.listen(m),[u,m]),j.createElement(Lx,{basename:t,children:n,location:f.location,navigationType:f.action,navigator:u})}const bx=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",Ix=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,lt=j.forwardRef(function(t,n){let{onClick:i,relative:s,reloadDocument:a,replace:u,state:f,target:d,to:p,preventScrollReset:m}=t,g=Nx(t,zx),{basename:y}=j.useContext(Oi),C,x=!1;if(typeof p=="string"&&Ix.test(p)&&(C=p,bx))try{let w=new URL(window.location.href),T=p.startsWith("//")?new URL(w.protocol+p):new URL(p),N=fd(T.pathname,y);T.origin===w.origin&&N!=null?p=N+T.search+T.hash:x=!0}catch{}let P=hx(p,{relative:s}),R=Dx(p,{replace:u,state:f,target:d,preventScrollReset:m,relative:s});function S(w){i&&i(w),w.defaultPrevented||R(w)}return j.createElement("a",tf({},g,{href:C||P,onClick:x||a?i:S,ref:n,target:d}))});var Gp;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher"})(Gp||(Gp={}));var Qp;(function(e){e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Qp||(Qp={}));function Dx(e,t){let{target:n,replace:i,state:s,preventScrollReset:a,relative:u}=t===void 0?{}:t,f=eg(),d=qo(),p=tg(e,{relative:u});return j.useCallback(m=>{if(Rx(m,n)){m.preventDefault();let g=i!==void 0?i:Ca(d)===Ca(p);f(e,{replace:g,state:s,preventScrollReset:a,relative:u})}},[d,f,p,i,s,n,e,a,u])}var ig={exports:{}},Bx="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",Fx=Bx,$x=Fx;function og(){}function sg(){}sg.resetWarningCache=og;var Ux=function(){function e(i,s,a,u,f,d){if(d!==$x){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:sg,resetWarningCache:og};return n.PropTypes=n,n};ig.exports=Ux();var Zx=ig.exports;const J=Uo(Zx);var Hx=typeof Element<"u",Wx=typeof Map=="function",Vx=typeof Set=="function",Kx=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function Ys(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,i,s;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(!Ys(e[i],t[i]))return!1;return!0}var a;if(Wx&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(a=e.entries();!(i=a.next()).done;)if(!t.has(i.value[0]))return!1;for(a=e.entries();!(i=a.next()).done;)if(!Ys(i.value[1],t.get(i.value[0])))return!1;return!0}if(Vx&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(a=e.entries();!(i=a.next()).done;)if(!t.has(i.value[0]))return!1;return!0}if(Kx&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(i=n;i--!==0;)if(e[i]!==t[i])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(t,s[i]))return!1;if(Hx&&e instanceof Element)return!1;for(i=n;i--!==0;)if(!((s[i]==="_owner"||s[i]==="__v"||s[i]==="__o")&&e.$$typeof)&&!Ys(e[s[i]],t[s[i]]))return!1;return!0}return e!==e&&t!==t}var qx=function(t,n){try{return Ys(t,n)}catch(i){if((i.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw i}};const Gx=Uo(qx);var Qx=function(e,t,n,i,s,a,u,f){if(!e){var d;if(t===void 0)d=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var p=[n,i,s,a,u,f],m=0;d=new Error(t.replace(/%s/g,function(){return p[m++]})),d.name="Invariant Violation"}throw d.framesToPop=1,d}},Yx=Qx;const Yp=Uo(Yx);var Jx=function(t,n,i,s){var a=i?i.call(s,t,n):void 0;if(a!==void 0)return!!a;if(t===n)return!0;if(typeof t!="object"||!t||typeof n!="object"||!n)return!1;var u=Object.keys(t),f=Object.keys(n);if(u.length!==f.length)return!1;for(var d=Object.prototype.hasOwnProperty.bind(n),p=0;p=0||(s[n]=e[n]);return s}var V={BASE:"base",BODY:"body",HEAD:"head",HTML:"html",LINK:"link",META:"meta",NOSCRIPT:"noscript",SCRIPT:"script",STYLE:"style",TITLE:"title",FRAGMENT:"Symbol(react.fragment)"},eS={rel:["amphtml","canonical","alternate"]},tS={type:["application/ld+json"]},nS={charset:"",name:["robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]},Xp=Object.keys(V).map(function(e){return V[e]}),Oa={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},rS=Object.keys(Oa).reduce(function(e,t){return e[Oa[t]]=t,e},{}),ui=function(e,t){for(var n=e.length-1;n>=0;n-=1){var i=e[n];if(Object.prototype.hasOwnProperty.call(i,t))return i[t]}return null},iS=function(e){var t=ui(e,V.TITLE),n=ui(e,"titleTemplate");if(Array.isArray(t)&&(t=t.join("")),n&&t)return n.replace(/%s/g,function(){return t});var i=ui(e,"defaultTitle");return t||i||void 0},oS=function(e){return ui(e,"onChangeClientState")||function(){}},Hu=function(e,t){return t.filter(function(n){return n[e]!==void 0}).map(function(n){return n[e]}).reduce(function(n,i){return Te({},n,i)},{})},sS=function(e,t){return t.filter(function(n){return n[V.BASE]!==void 0}).map(function(n){return n[V.BASE]}).reverse().reduce(function(n,i){if(!n.length)for(var s=Object.keys(i),a=0;a/g,">").replace(/"/g,""").replace(/'/g,"'")},tm=function(e){return Object.keys(e).reduce(function(t,n){var i=e[n]!==void 0?n+'="'+e[n]+'"':""+n;return t?t+" "+i:i},"")},nm=function(e,t){return t===void 0&&(t={}),Object.keys(e).reduce(function(n,i){return n[Oa[i]||i]=e[i],n},t)},Js=function(e,t){return t.map(function(n,i){var s,a=((s={key:i})["data-rh"]=!0,s);return Object.keys(n).forEach(function(u){var f=Oa[u]||u;f==="innerHTML"||f==="cssText"?a.dangerouslySetInnerHTML={__html:n.innerHTML||n.cssText}:a[f]=n[u]}),Qt.createElement(e,a)})},yt=function(e,t,n){switch(e){case V.TITLE:return{toComponent:function(){return s=t.titleAttributes,(a={key:i=t.title})["data-rh"]=!0,u=nm(s,a),[Qt.createElement(V.TITLE,u,i)];var i,s,a,u},toString:function(){return function(i,s,a,u){var f=tm(a),d=ag(s);return f?"<"+i+' data-rh="true" '+f+">"+Vu(d,u)+"":"<"+i+' data-rh="true">'+Vu(d,u)+""}(e,t.title,t.titleAttributes,n)}};case"bodyAttributes":case"htmlAttributes":return{toComponent:function(){return nm(t)},toString:function(){return tm(t)}};default:return{toComponent:function(){return Js(e,t)},toString:function(){return function(i,s,a){return s.reduce(function(u,f){var d=Object.keys(f).filter(function(g){return!(g==="innerHTML"||g==="cssText")}).reduce(function(g,y){var C=f[y]===void 0?y:y+'="'+Vu(f[y],a)+'"';return g?g+" "+C:C},""),p=f.innerHTML||f.cssText||"",m=lS.indexOf(i)===-1;return u+"<"+i+' data-rh="true" '+d+(m?"/>":">"+p+"")},"")}(e,t,n)}}}},rf=function(e){var t=e.baseTag,n=e.bodyAttributes,i=e.encode,s=e.htmlAttributes,a=e.noscriptTags,u=e.styleTags,f=e.title,d=f===void 0?"":f,p=e.titleAttributes,m=e.linkTags,g=e.metaTags,y=e.scriptTags,C={toComponent:function(){},toString:function(){return""}};if(e.prioritizeSeoTags){var x=function(P){var R=P.linkTags,S=P.scriptTags,w=P.encode,T=Wu(P.metaTags,nS),N=Wu(R,eS),I=Wu(S,tS);return{priorityMethods:{toComponent:function(){return[].concat(Js(V.META,T.priority),Js(V.LINK,N.priority),Js(V.SCRIPT,I.priority))},toString:function(){return yt(V.META,T.priority,w)+" "+yt(V.LINK,N.priority,w)+" "+yt(V.SCRIPT,I.priority,w)}},metaTags:T.default,linkTags:N.default,scriptTags:I.default}}(e);C=x.priorityMethods,m=x.linkTags,g=x.metaTags,y=x.scriptTags}return{priority:C,base:yt(V.BASE,t,i),bodyAttributes:yt("bodyAttributes",n,i),htmlAttributes:yt("htmlAttributes",s,i),link:yt(V.LINK,m,i),meta:yt(V.META,g,i),noscript:yt(V.NOSCRIPT,a,i),script:yt(V.SCRIPT,y,i),style:yt(V.STYLE,u,i),title:yt(V.TITLE,{title:d,titleAttributes:p},i)}},Ds=[],of=function(e,t){var n=this;t===void 0&&(t=typeof document<"u"),this.instances=[],this.value={setHelmet:function(i){n.context.helmet=i},helmetInstances:{get:function(){return n.canUseDOM?Ds:n.instances},add:function(i){(n.canUseDOM?Ds:n.instances).push(i)},remove:function(i){var s=(n.canUseDOM?Ds:n.instances).indexOf(i);(n.canUseDOM?Ds:n.instances).splice(s,1)}}},this.context=e,this.canUseDOM=t,t||(e.helmet=rf({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))},lg=Qt.createContext({}),uS=J.shape({setHelmet:J.func,helmetInstances:J.shape({get:J.func,add:J.func,remove:J.func})}),cS=typeof document<"u",ni=function(e){function t(n){var i;return(i=e.call(this,n)||this).helmetData=new of(i.props.context,t.canUseDOM),i}return _d(t,e),t.prototype.render=function(){return Qt.createElement(lg.Provider,{value:this.helmetData.value},this.props.children)},t}(j.Component);ni.canUseDOM=cS,ni.propTypes={context:J.shape({helmet:J.shape()}),children:J.node.isRequired},ni.defaultProps={context:{}},ni.displayName="HelmetProvider";var Ur=function(e,t){var n,i=document.head||document.querySelector(V.HEAD),s=i.querySelectorAll(e+"[data-rh]"),a=[].slice.call(s),u=[];return t&&t.length&&t.forEach(function(f){var d=document.createElement(e);for(var p in f)Object.prototype.hasOwnProperty.call(f,p)&&(p==="innerHTML"?d.innerHTML=f.innerHTML:p==="cssText"?d.styleSheet?d.styleSheet.cssText=f.cssText:d.appendChild(document.createTextNode(f.cssText)):d.setAttribute(p,f[p]===void 0?"":f[p]));d.setAttribute("data-rh","true"),a.some(function(m,g){return n=g,d.isEqualNode(m)})?a.splice(n,1):u.push(d)}),a.forEach(function(f){return f.parentNode.removeChild(f)}),u.forEach(function(f){return i.appendChild(f)}),{oldTags:a,newTags:u}},Ku=function(e,t){var n=document.getElementsByTagName(e)[0];if(n){for(var i=n.getAttribute("data-rh"),s=i?i.split(","):[],a=[].concat(s),u=Object.keys(t),f=0;f=0;g-=1)n.removeAttribute(a[g]);s.length===a.length?n.removeAttribute("data-rh"):n.getAttribute("data-rh")!==u.join(",")&&n.setAttribute("data-rh",u.join(","))}},rm=function(e,t){var n=e.baseTag,i=e.htmlAttributes,s=e.linkTags,a=e.metaTags,u=e.noscriptTags,f=e.onChangeClientState,d=e.scriptTags,p=e.styleTags,m=e.title,g=e.titleAttributes;Ku(V.BODY,e.bodyAttributes),Ku(V.HTML,i),function(P,R){P!==void 0&&document.title!==P&&(document.title=ag(P)),Ku(V.TITLE,R)}(m,g);var y={baseTag:Ur(V.BASE,n),linkTags:Ur(V.LINK,s),metaTags:Ur(V.META,a),noscriptTags:Ur(V.NOSCRIPT,u),scriptTags:Ur(V.SCRIPT,d),styleTags:Ur(V.STYLE,p)},C={},x={};Object.keys(y).forEach(function(P){var R=y[P],S=R.newTags,w=R.oldTags;S.length&&(C[P]=S),w.length&&(x[P]=y[P].oldTags)}),t&&t(),f(e,C,x)},ro=null,Na=function(e){function t(){for(var i,s=arguments.length,a=new Array(s),u=0;u elements are self-closing and can not contain children. Refer to our API for more information.")}},n.flattenArrayTypeChildren=function(i){var s,a=i.child,u=i.arrayTypeChildren;return Te({},u,((s={})[a.type]=[].concat(u[a.type]||[],[Te({},i.newChildProps,this.mapNestedChildrenToProps(a,i.nestedChildren))]),s))},n.mapObjectTypeChildren=function(i){var s,a,u=i.child,f=i.newProps,d=i.newChildProps,p=i.nestedChildren;switch(u.type){case V.TITLE:return Te({},f,((s={})[u.type]=p,s.titleAttributes=Te({},d),s));case V.BODY:return Te({},f,{bodyAttributes:Te({},d)});case V.HTML:return Te({},f,{htmlAttributes:Te({},d)});default:return Te({},f,((a={})[u.type]=Te({},d),a))}},n.mapArrayTypeChildrenToProps=function(i,s){var a=Te({},s);return Object.keys(i).forEach(function(u){var f;a=Te({},a,((f={})[u]=i[u],f))}),a},n.warnOnInvalidChildren=function(i,s){return Yp(Xp.some(function(a){return i.type===a}),typeof i.type=="function"?"You may be attempting to nest components within each other, which is not allowed. Refer to our API for more information.":"Only elements types "+Xp.join(", ")+" are allowed. Helmet does not support rendering <"+i.type+"> elements. Refer to our API for more information."),Yp(!s||typeof s=="string"||Array.isArray(s)&&!s.some(function(a){return typeof a!="string"}),"Helmet expects a string as a child of <"+i.type+">. Did you forget to wrap your children in braces? ( <"+i.type+">{``} ) Refer to our API for more information."),!0},n.mapChildrenToProps=function(i,s){var a=this,u={};return Qt.Children.forEach(i,function(f){if(f&&f.props){var d=f.props,p=d.children,m=Jp(d,fS),g=Object.keys(m).reduce(function(C,x){return C[rS[x]||x]=m[x],C},{}),y=f.type;switch(typeof y=="symbol"?y=y.toString():a.warnOnInvalidChildren(f,p),y){case V.FRAGMENT:s=a.mapChildrenToProps(p,s);break;case V.LINK:case V.META:case V.NOSCRIPT:case V.SCRIPT:case V.STYLE:u=a.flattenArrayTypeChildren({child:f,arrayTypeChildren:u,newChildProps:g,nestedChildren:p});break;default:s=a.mapObjectTypeChildren({child:f,newProps:s,newChildProps:g,nestedChildren:p})}}}),this.mapArrayTypeChildrenToProps(u,s)},n.render=function(){var i=this.props,s=i.children,a=Jp(i,dS),u=Te({},a),f=a.helmetData;return s&&(u=this.mapChildrenToProps(s,u)),!f||f instanceof of||(f=new of(f.context,f.instances)),f?Qt.createElement(Na,Te({},u,{context:f.value,helmetData:void 0})):Qt.createElement(lg.Consumer,null,function(d){return Qt.createElement(Na,Te({},u,{context:d}))})},t}(j.Component);qn.propTypes={base:J.object,bodyAttributes:J.object,children:J.oneOfType([J.arrayOf(J.node),J.node]),defaultTitle:J.string,defer:J.bool,encodeSpecialCharacters:J.bool,htmlAttributes:J.object,link:J.arrayOf(J.object),meta:J.arrayOf(J.object),noscript:J.arrayOf(J.object),onChangeClientState:J.func,script:J.arrayOf(J.object),style:J.arrayOf(J.object),title:J.string,titleAttributes:J.object,titleTemplate:J.string,prioritizeSeoTags:J.bool,helmetData:J.object},qn.defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1},qn.displayName="Helmet";var sf={exports:{}};/* @preserve * Leaflet 1.7.1, a JS library for interactive maps. http://leafletjs.com * (c) 2010-2019 Vladimir Agafonkin, (c) 2010-2011 CloudMade - */(function(e,t){(function(n,i){i(t)})(p0,function(n){var i="1.7.1";function s(r){var o,l,c,h;for(l=1,c=arguments.length;l"u"||!L||!L.Mixin)){r=T(r)?r:[r];for(var o=0;o0?Math.floor(r):Math.ceil(r)};z.prototype={clone:function(){return new z(this.x,this.y)},add:function(r){return this.clone()._add(D(r))},_add:function(r){return this.x+=r.x,this.y+=r.y,this},subtract:function(r){return this.clone()._subtract(D(r))},_subtract:function(r){return this.x-=r.x,this.y-=r.y,this},divideBy:function(r){return this.clone()._divideBy(r)},_divideBy:function(r){return this.x/=r,this.y/=r,this},multiplyBy:function(r){return this.clone()._multiplyBy(r)},_multiplyBy:function(r){return this.x*=r,this.y*=r,this},scaleBy:function(r){return new z(this.x*r.x,this.y*r.y)},unscaleBy:function(r){return new z(this.x/r.x,this.y/r.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=q(this.x),this.y=q(this.y),this},distanceTo:function(r){r=D(r);var o=r.x-this.x,l=r.y-this.y;return Math.sqrt(o*o+l*l)},equals:function(r){return r=D(r),r.x===this.x&&r.y===this.y},contains:function(r){return r=D(r),Math.abs(r.x)<=Math.abs(this.x)&&Math.abs(r.y)<=Math.abs(this.y)},toString:function(){return"Point("+y(this.x)+", "+y(this.y)+")"}};function D(r,o,l){return r instanceof z?r:T(r)?new z(r[0],r[1]):r==null?r:typeof r=="object"&&"x"in r&&"y"in r?new z(r.x,r.y):new z(r,o,l)}function K(r,o){if(r)for(var l=o?[r,o]:r,c=0,h=l.length;c=this.min.x&&l.x<=this.max.x&&o.y>=this.min.y&&l.y<=this.max.y},intersects:function(r){r=ae(r);var o=this.min,l=this.max,c=r.min,h=r.max,_=h.x>=o.x&&c.x<=l.x,E=h.y>=o.y&&c.y<=l.y;return _&&E},overlaps:function(r){r=ae(r);var o=this.min,l=this.max,c=r.min,h=r.max,_=h.x>o.x&&c.xo.y&&c.y=o.lat&&h.lat<=l.lat&&c.lng>=o.lng&&h.lng<=l.lng},intersects:function(r){r=de(r);var o=this._southWest,l=this._northEast,c=r.getSouthWest(),h=r.getNorthEast(),_=h.lat>=o.lat&&c.lat<=l.lat,E=h.lng>=o.lng&&c.lng<=l.lng;return _&&E},overlaps:function(r){r=de(r);var o=this._southWest,l=this._northEast,c=r.getSouthWest(),h=r.getNorthEast(),_=h.lat>o.lat&&c.lato.lng&&c.lng1,Lr=function(){var r=!1;try{var o=Object.defineProperty({},"passive",{get:function(){r=!0}});window.addEventListener("testPassiveEventSupport",g,o),window.removeEventListener("testPassiveEventSupport",g,o)}catch{}return r}(),Wd=function(){return!!document.createElement("canvas").getContext}(),es=!!(document.createElementNS&&Id("svg").createSVGRect),ts=!es&&function(){try{var r=document.createElement("div");r.innerHTML='';var o=r.firstChild;return o.style.behavior="url(#default#VML)",o&&typeof o.adj=="object"}catch{return!1}}();function Zt(r){return navigator.userAgent.toLowerCase().indexOf(r)>=0}var cy={ie:Yo,ielt9:Cr,edge:Jo,webkit:Rl,android:zi,android23:Ai,androidStock:Bd,opera:zl,chrome:Al,gecko:jl,safari:Xo,phantom:Fd,opera12:$d,win:Ud,ie3d:bl,webkit3d:Il,gecko3d:Zd,any3d:_t,mobile:kr,mobileWebkit:ay,mobileWebkit3d:ly,msPointer:En,pointer:$t,touch:Ut,mobileOpera:Hd,mobileGecko:uy,retina:Tn,passiveEvents:Lr,canvas:Wd,svg:es,vml:ts},Dl=En?"MSPointerDown":"pointerdown",Bl=En?"MSPointerMove":"pointermove",Fl=En?"MSPointerUp":"pointerup",$l=En?"MSPointerCancel":"pointercancel",Or={},Vd=!1;function fy(r,o,l,c){return o==="touchstart"?hy(r,l,c):o==="touchmove"?_y(r,l,c):o==="touchend"&&vy(r,l,c),this}function dy(r,o,l){var c=r["_leaflet_"+o+l];return o==="touchstart"?r.removeEventListener(Dl,c,!1):o==="touchmove"?r.removeEventListener(Bl,c,!1):o==="touchend"&&(r.removeEventListener(Fl,c,!1),r.removeEventListener($l,c,!1)),this}function hy(r,o,l){var c=u(function(h){h.MSPOINTER_TYPE_TOUCH&&h.pointerType===h.MSPOINTER_TYPE_TOUCH&>(h),Ul(h,o)});r["_leaflet_touchstart"+l]=c,r.addEventListener(Dl,c,!1),Vd||(document.addEventListener(Dl,py,!0),document.addEventListener(Bl,my,!0),document.addEventListener(Fl,Kd,!0),document.addEventListener($l,Kd,!0),Vd=!0)}function py(r){Or[r.pointerId]=r}function my(r){Or[r.pointerId]&&(Or[r.pointerId]=r)}function Kd(r){delete Or[r.pointerId]}function Ul(r,o){r.touches=[];for(var l in Or)r.touches.push(Or[l]);r.changedTouches=[r],o(r)}function _y(r,o,l){var c=function(h){h.pointerType===(h.MSPOINTER_TYPE_MOUSE||"mouse")&&h.buttons===0||Ul(h,o)};r["_leaflet_touchmove"+l]=c,r.addEventListener(Bl,c,!1)}function vy(r,o,l){var c=function(h){Ul(h,o)};r["_leaflet_touchend"+l]=c,r.addEventListener(Fl,c,!1),r.addEventListener($l,c,!1)}var ns=En?"MSPointerDown":$t?"pointerdown":"touchstart",rs=En?"MSPointerUp":$t?"pointerup":"touchend",Nr="_leaflet_";function gy(r,o,l){var c,h,_=!1,E=250;function k(A){if($t){if(!A.isPrimary||A.pointerType==="mouse")return}else if(A.touches.length>1)return;var B=Date.now(),H=B-(c||B);h=A.touches?A.touches[0]:A,_=H>0&&H<=E,c=B}function O(A){if(_&&!h.cancelBubble){if($t){if(A.pointerType==="mouse")return;var B={},H,oe;for(oe in h)H=h[oe],B[oe]=H&&H.bind?H.bind(h):H;h=B}h.type="dblclick",h.button=0,o(h),c=null}}return r[Nr+ns+l]=k,r[Nr+rs+l]=O,r[Nr+"dblclick"+l]=o,r.addEventListener(ns,k,Lr?{passive:!1}:!1),r.addEventListener(rs,O,Lr?{passive:!1}:!1),r.addEventListener("dblclick",o,!1),this}function yy(r,o){var l=r[Nr+ns+o],c=r[Nr+rs+o],h=r[Nr+"dblclick"+o];return r.removeEventListener(ns,l,Lr?{passive:!1}:!1),r.removeEventListener(rs,c,Lr?{passive:!1}:!1),r.removeEventListener("dblclick",h,!1),this}var Zl=ss(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),ji=ss(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),qd=ji==="webkitTransition"||ji==="OTransition"?ji+"End":"transitionend";function Gd(r){return typeof r=="string"?document.getElementById(r):r}function bi(r,o){var l=r.style[o]||r.currentStyle&&r.currentStyle[o];if((!l||l==="auto")&&document.defaultView){var c=document.defaultView.getComputedStyle(r,null);l=c?c[o]:null}return l==="auto"?null:l}function ie(r,o,l){var c=document.createElement(r);return c.className=o||"",l&&l.appendChild(c),c}function ge(r){var o=r.parentNode;o&&o.removeChild(r)}function is(r){for(;r.firstChild;)r.removeChild(r.firstChild)}function Mr(r){var o=r.parentNode;o&&o.lastChild!==r&&o.appendChild(r)}function Rr(r){var o=r.parentNode;o&&o.firstChild!==r&&o.insertBefore(r,o.firstChild)}function Hl(r,o){if(r.classList!==void 0)return r.classList.contains(o);var l=os(r);return l.length>0&&new RegExp("(^|\\s)"+o+"(\\s|$)").test(l)}function G(r,o){if(r.classList!==void 0)for(var l=x(o),c=0,h=l.length;cthis.options.maxZoom)?this.setZoom(r):this},panInsideBounds:function(r,o){this._enforcingBounds=!0;var l=this.getCenter(),c=this._limitCenter(l,this._zoom,de(r));return l.equals(c)||this.panTo(c,o),this._enforcingBounds=!1,this},panInside:function(r,o){o=o||{};var l=D(o.paddingTopLeft||o.padding||[0,0]),c=D(o.paddingBottomRight||o.padding||[0,0]),h=this.getCenter(),_=this.project(h),E=this.project(r),k=this.getPixelBounds(),O=k.getSize().divideBy(2),A=ae([k.min.add(l),k.max.subtract(c)]);if(!A.contains(E)){this._enforcingBounds=!0;var B=_.subtract(E),H=D(E.x+B.x,E.y+B.y);(E.xA.max.x)&&(H.x=_.x-B.x,B.x>0?H.x+=O.x-l.x:H.x-=O.x-c.x),(E.yA.max.y)&&(H.y=_.y-B.y,B.y>0?H.y+=O.y-l.y:H.y-=O.y-c.y),this.panTo(this.unproject(H),o),this._enforcingBounds=!1}return this},invalidateSize:function(r){if(!this._loaded)return this;r=s({animate:!1,pan:!0},r===!0?{animate:!0}:r);var o=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var l=this.getSize(),c=o.divideBy(2).round(),h=l.divideBy(2).round(),_=c.subtract(h);return!_.x&&!_.y?this:(r.animate&&r.pan?this.panBy(_):(r.pan&&this._rawPanBy(_),this.fire("move"),r.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(u(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:o,newSize:l}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(r){if(r=this._locateOptions=s({timeout:1e4,watch:!1},r),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var o=u(this._handleGeolocationResponse,this),l=u(this._handleGeolocationError,this);return r.watch?this._locationWatchId=navigator.geolocation.watchPosition(o,l,r):navigator.geolocation.getCurrentPosition(o,l,r),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(r){var o=r.code,l=r.message||(o===1?"permission denied":o===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:o,message:"Geolocation error: "+l+"."})},_handleGeolocationResponse:function(r){var o=r.coords.latitude,l=r.coords.longitude,c=new se(o,l),h=c.toBounds(r.coords.accuracy*2),_=this._locateOptions;if(_.setView){var E=this.getBoundsZoom(h);this.setView(c,_.maxZoom?Math.min(E,_.maxZoom):E)}var k={latlng:c,bounds:h,timestamp:r.timestamp};for(var O in r.coords)typeof r.coords[O]=="number"&&(k[O]=r.coords[O]);this.fire("locationfound",k)},addHandler:function(r,o){if(!o)return this;var l=this[r]=new o(this);return this._handlers.push(l),this.options[r]&&l.enable(),this},remove:function(){if(this._initEvents(!0),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(),ge(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(Le(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var r;for(r in this._layers)this._layers[r].remove();for(r in this._panes)ge(this._panes[r]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(r,o){var l="leaflet-pane"+(r?" leaflet-"+r.replace("Pane","")+"-pane":""),c=ie("div",l,o||this._mapPane);return r&&(this._panes[r]=c),c},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter:this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var r=this.getPixelBounds(),o=this.unproject(r.getBottomLeft()),l=this.unproject(r.getTopRight());return new ze(o,l)},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(r,o,l){r=de(r),l=D(l||[0,0]);var c=this.getZoom()||0,h=this.getMinZoom(),_=this.getMaxZoom(),E=r.getNorthWest(),k=r.getSouthEast(),O=this.getSize().subtract(l),A=ae(this.project(k,c),this.project(E,c)).getSize(),B=_t?this.options.zoomSnap:1,H=O.x/A.x,oe=O.y/A.y,un=o?Math.max(H,oe):Math.min(H,oe);return c=this.getScaleZoom(un,c),B&&(c=Math.round(c/(B/100))*(B/100),c=o?Math.ceil(c/B)*B:Math.floor(c/B)*B),Math.max(h,Math.min(_,c))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new z(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(r,o){var l=this._getTopLeftPoint(r,o);return new K(l,l.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(r){return this.options.crs.getProjectedBounds(r===void 0?this.getZoom():r)},getPane:function(r){return typeof r=="string"?this._panes[r]:r},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(r,o){var l=this.options.crs;return o=o===void 0?this._zoom:o,l.scale(r)/l.scale(o)},getScaleZoom:function(r,o){var l=this.options.crs;o=o===void 0?this._zoom:o;var c=l.zoom(r*l.scale(o));return isNaN(c)?1/0:c},project:function(r,o){return o=o===void 0?this._zoom:o,this.options.crs.latLngToPoint(le(r),o)},unproject:function(r,o){return o=o===void 0?this._zoom:o,this.options.crs.pointToLatLng(D(r),o)},layerPointToLatLng:function(r){var o=D(r).add(this.getPixelOrigin());return this.unproject(o)},latLngToLayerPoint:function(r){var o=this.project(le(r))._round();return o._subtract(this.getPixelOrigin())},wrapLatLng:function(r){return this.options.crs.wrapLatLng(le(r))},wrapLatLngBounds:function(r){return this.options.crs.wrapLatLngBounds(de(r))},distance:function(r,o){return this.options.crs.distance(le(r),le(o))},containerPointToLayerPoint:function(r){return D(r).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(r){return D(r).add(this._getMapPanePos())},containerPointToLatLng:function(r){var o=this.containerPointToLayerPoint(D(r));return this.layerPointToLatLng(o)},latLngToContainerPoint:function(r){return this.layerPointToContainerPoint(this.latLngToLayerPoint(le(r)))},mouseEventToContainerPoint:function(r){return Jd(r,this._container)},mouseEventToLayerPoint:function(r){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(r))},mouseEventToLatLng:function(r){return this.layerPointToLatLng(this.mouseEventToLayerPoint(r))},_initContainer:function(r){var o=this._container=Gd(r);if(o){if(o._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");Q(o,"scroll",this._onScroll,this),this._containerId=d(o)},_initLayout:function(){var r=this._container;this._fadeAnimated=this.options.fadeAnimation&&_t,G(r,"leaflet-container"+(Ut?" leaflet-touch":"")+(Tn?" leaflet-retina":"")+(Cr?" leaflet-oldie":"")+(Xo?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var o=bi(r,"position");o!=="absolute"&&o!=="relative"&&o!=="fixed"&&(r.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var r=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),Oe(this._mapPane,new z(0,0)),this.createPane("tilePane"),this.createPane("shadowPane"),this.createPane("overlayPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(G(r.markerPane,"leaflet-zoom-hide"),G(r.shadowPane,"leaflet-zoom-hide"))},_resetView:function(r,o){Oe(this._mapPane,new z(0,0));var l=!this._loaded;this._loaded=!0,o=this._limitZoom(o),this.fire("viewprereset");var c=this._zoom!==o;this._moveStart(c,!1)._move(r,o)._moveEnd(c),this.fire("viewreset"),l&&this.fire("load")},_moveStart:function(r,o){return r&&this.fire("zoomstart"),o||this.fire("movestart"),this},_move:function(r,o,l){o===void 0&&(o=this._zoom);var c=this._zoom!==o;return this._zoom=o,this._lastCenter=r,this._pixelOrigin=this._getNewPixelOrigin(r),(c||l&&l.pinch)&&this.fire("zoom",l),this.fire("move",l)},_moveEnd:function(r){return r&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return Le(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(r){Oe(this._mapPane,this._getMapPanePos().subtract(r))},_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(r){this._targets={},this._targets[d(this._container)]=this;var o=r?Ee:Q;o(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&o(window,"resize",this._onResize,this),_t&&this.options.transform3DLimit&&(r?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){Le(this._resizeRequest),this._resizeRequest=X(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var r=this._getMapPanePos();Math.max(Math.abs(r.x),Math.abs(r.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(r,o){for(var l=[],c,h=o==="mouseout"||o==="mouseover",_=r.target||r.srcElement,E=!1;_;){if(c=this._targets[d(_)],c&&(o==="click"||o==="preclick")&&!r._simulated&&this._draggableMoved(c)){E=!0;break}if(c&&c.listens(o,!0)&&(h&&!cs(_,r)||(l.push(c),h))||_===this._container)break;_=_.parentNode}return!l.length&&!E&&!h&&cs(_,r)&&(l=[this]),l},_handleDOMEvent:function(r){if(!(!this._loaded||ru(r))){var o=r.type;(o==="mousedown"||o==="keypress"||o==="keyup"||o==="keydown")&&Ql(r.target||r.srcElement),this._fireDOMEvent(r,o)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(r,o,l){if(r.type==="click"){var c=s({},r);c.type="preclick",this._fireDOMEvent(c,c.type,l)}if(!r._stopped&&(l=(l||[]).concat(this._findEventTargets(r,o)),!!l.length)){var h=l[0];o==="contextmenu"&&h.listens(o,!0)&>(r);var _={originalEvent:r};if(r.type!=="keypress"&&r.type!=="keydown"&&r.type!=="keyup"){var E=h.getLatLng&&(!h._radius||h._radius<=10);_.containerPoint=E?this.latLngToContainerPoint(h.getLatLng()):this.mouseEventToContainerPoint(r),_.layerPoint=this.containerPointToLayerPoint(_.containerPoint),_.latlng=E?h.getLatLng():this.layerPointToLatLng(_.layerPoint)}for(var k=0;k0?Math.round(r-o)/2:Math.max(0,Math.ceil(r))-Math.max(0,Math.floor(o))},_limitZoom:function(r){var o=this.getMinZoom(),l=this.getMaxZoom(),c=_t?this.options.zoomSnap:1;return c&&(r=Math.round(r/c)*c),Math.max(o,Math.min(l,r))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){Se(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(r,o){var l=this._getCenterOffset(r)._trunc();return(o&&o.animate)!==!0&&!this.getSize().contains(l)?!1:(this.panBy(l,o),!0)},_createAnimProxy:function(){var r=this._proxy=ie("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(r),this.on("zoomanim",function(o){var l=Zl,c=this._proxy.style[l];or(this._proxy,this.project(o.center,o.zoom),this.getZoomScale(o.zoom,1)),c===this._proxy.style[l]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){ge(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var r=this.getCenter(),o=this.getZoom();or(this._proxy,this.project(r,o),this.getZoomScale(o,1))},_catchTransitionEnd:function(r){this._animatingZoom&&r.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(r,o,l){if(this._animatingZoom)return!0;if(l=l||{},!this._zoomAnimated||l.animate===!1||this._nothingToAnimate()||Math.abs(o-this._zoom)>this.options.zoomAnimationThreshold)return!1;var c=this.getZoomScale(o),h=this._getCenterOffset(r)._divideBy(1-1/c);return l.animate!==!0&&!this.getSize().contains(h)?!1:(X(function(){this._moveStart(!0,!1)._animateZoom(r,o,!0)},this),!0)},_animateZoom:function(r,o,l,c){this._mapPane&&(l&&(this._animatingZoom=!0,this._animateToCenter=r,this._animateToZoom=o,G(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:r,zoom:o,noUpdate:c}),setTimeout(u(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&Se(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom),X(function(){this._moveEnd(!0)},this))}});function Ey(r,o){return new te(r,o)}var Mt=mt.extend({options:{position:"topright"},initialize:function(r){P(this,r)},getPosition:function(){return this.options.position},setPosition:function(r){var o=this._map;return o&&o.removeControl(this),this.options.position=r,o&&o.addControl(this),this},getContainer:function(){return this._container},addTo:function(r){this.remove(),this._map=r;var o=this._container=this.onAdd(r),l=this.getPosition(),c=r._controlCorners[l];return G(o,"leaflet-control"),l.indexOf("bottom")!==-1?c.insertBefore(o,c.firstChild):c.appendChild(o),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(ge(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(r){this._map&&r&&r.screenX>0&&r.screenY>0&&this._map.getContainer().focus()}}),$i=function(r){return new Mt(r)};te.include({addControl:function(r){return r.addTo(this),this},removeControl:function(r){return r.remove(),this},_initControlPos:function(){var r=this._controlCorners={},o="leaflet-",l=this._controlContainer=ie("div",o+"control-container",this._container);function c(h,_){var E=o+h+" "+o+_;r[h+_]=ie("div",E,l)}c("top","left"),c("top","right"),c("bottom","left"),c("bottom","right")},_clearControlPos:function(){for(var r in this._controlCorners)ge(this._controlCorners[r]);ge(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var th=Mt.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(r,o,l,c){return l1,this._baseLayersList.style.display=r?"":"none"),this._separator.style.display=o&&r?"":"none",this},_onLayerChange:function(r){this._handlingClick||this._update();var o=this._getLayer(d(r.target)),l=o.overlay?r.type==="add"?"overlayadd":"overlayremove":r.type==="add"?"baselayerchange":null;l&&this._map.fire(l,o)},_createRadioElement:function(r,o){var l='",c=document.createElement("div");return c.innerHTML=l,c.firstChild},_addItem:function(r){var o=document.createElement("label"),l=this._map.hasLayer(r.layer),c;r.overlay?(c=document.createElement("input"),c.type="checkbox",c.className="leaflet-control-layers-selector",c.defaultChecked=l):c=this._createRadioElement("leaflet-base-layers_"+d(this),l),this._layerControlInputs.push(c),c.layerId=d(r.layer),Q(c,"click",this._onInputClick,this);var h=document.createElement("span");h.innerHTML=" "+r.name;var _=document.createElement("div");o.appendChild(_),_.appendChild(c),_.appendChild(h);var E=r.overlay?this._overlaysList:this._baseLayersList;return E.appendChild(o),this._checkDisabledLayers(),o},_onInputClick:function(){var r=this._layerControlInputs,o,l,c=[],h=[];this._handlingClick=!0;for(var _=r.length-1;_>=0;_--)o=r[_],l=this._getLayer(o.layerId).layer,o.checked?c.push(l):o.checked||h.push(l);for(_=0;_=0;h--)o=r[h],l=this._getLayer(o.layerId).layer,o.disabled=l.options.minZoom!==void 0&&cl.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expand:function(){return this.expand()},_collapse:function(){return this.collapse()}}),Ty=function(r,o,l){return new th(r,o,l)},iu=Mt.extend({options:{position:"topleft",zoomInText:"+",zoomInTitle:"Zoom in",zoomOutText:"−",zoomOutTitle:"Zoom out"},onAdd:function(r){var o="leaflet-control-zoom",l=ie("div",o+" leaflet-bar"),c=this.options;return this._zoomInButton=this._createButton(c.zoomInText,c.zoomInTitle,o+"-in",l,this._zoomIn),this._zoomOutButton=this._createButton(c.zoomOutText,c.zoomOutTitle,o+"-out",l,this._zoomOut),this._updateDisabled(),r.on("zoomend zoomlevelschange",this._updateDisabled,this),l},onRemove:function(r){r.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(r){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(r.shiftKey?3:1))},_createButton:function(r,o,l,c,h){var _=ie("a",l,c);return _.innerHTML=r,_.href="#",_.title=o,_.setAttribute("role","button"),_.setAttribute("aria-label",o),Fi(_),Q(_,"click",rn),Q(_,"click",h,this),Q(_,"click",this._refocusOnMap,this),_},_updateDisabled:function(){var r=this._map,o="leaflet-disabled";Se(this._zoomInButton,o),Se(this._zoomOutButton,o),(this._disabled||r._zoom===r.getMinZoom())&&G(this._zoomOutButton,o),(this._disabled||r._zoom===r.getMaxZoom())&&G(this._zoomInButton,o)}});te.mergeOptions({zoomControl:!0}),te.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new iu,this.addControl(this.zoomControl))});var Cy=function(r){return new iu(r)},nh=Mt.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(r){var o="leaflet-control-scale",l=ie("div",o),c=this.options;return this._addScales(c,o+"-line",l),r.on(c.updateWhenIdle?"moveend":"move",this._update,this),r.whenReady(this._update,this),l},onRemove:function(r){r.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(r,o,l){r.metric&&(this._mScale=ie("div",o,l)),r.imperial&&(this._iScale=ie("div",o,l))},_update:function(){var r=this._map,o=r.getSize().y/2,l=r.distance(r.containerPointToLatLng([0,o]),r.containerPointToLatLng([this.options.maxWidth,o]));this._updateScales(l)},_updateScales:function(r){this.options.metric&&r&&this._updateMetric(r),this.options.imperial&&r&&this._updateImperial(r)},_updateMetric:function(r){var o=this._getRoundNum(r),l=o<1e3?o+" m":o/1e3+" km";this._updateScale(this._mScale,l,o/r)},_updateImperial:function(r){var o=r*3.2808399,l,c,h;o>5280?(l=o/5280,c=this._getRoundNum(l),this._updateScale(this._iScale,c+" mi",c/l)):(h=this._getRoundNum(o),this._updateScale(this._iScale,h+" ft",h/o))},_updateScale:function(r,o,l){r.style.width=Math.round(this.options.maxWidth*l)+"px",r.innerHTML=o},_getRoundNum:function(r){var o=Math.pow(10,(Math.floor(r)+"").length-1),l=r/o;return l=l>=10?10:l>=5?5:l>=3?3:l>=2?2:1,o*l}}),ky=function(r){return new nh(r)},ou=Mt.extend({options:{position:"bottomright",prefix:'Leaflet'},initialize:function(r){P(this,r),this._attributions={}},onAdd:function(r){r.attributionControl=this,this._container=ie("div","leaflet-control-attribution"),Fi(this._container);for(var o in r._layers)r._layers[o].getAttribution&&this.addAttribution(r._layers[o].getAttribution());return this._update(),this._container},setPrefix:function(r){return this.options.prefix=r,this._update(),this},addAttribution:function(r){return r?(this._attributions[r]||(this._attributions[r]=0),this._attributions[r]++,this._update(),this):this},removeAttribution:function(r){return r?(this._attributions[r]&&(this._attributions[r]--,this._update()),this):this},_update:function(){if(this._map){var r=[];for(var o in this._attributions)this._attributions[o]&&r.push(o);var l=[];this.options.prefix&&l.push(this.options.prefix),r.length&&l.push(r.join(", ")),this._container.innerHTML=l.join(" | ")}}});te.mergeOptions({attributionControl:!0}),te.addInitHook(function(){this.options.attributionControl&&new ou().addTo(this)});var Ly=function(r){return new ou(r)};Mt.Layers=th,Mt.Zoom=iu,Mt.Scale=nh,Mt.Attribution=ou,$i.layers=Ty,$i.zoom=Cy,$i.scale=ky,$i.attribution=Ly;var Ht=mt.extend({initialize:function(r){this._map=r},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}});Ht.addTo=function(r,o){return r.addHandler(o,this),this};var Oy={Events:Fe},rh=Ut?"touchstart mousedown":"mousedown",ih={mousedown:"mouseup",touchstart:"touchend",pointerdown:"touchend",MSPointerDown:"touchend"},su={mousedown:"mousemove",touchstart:"touchmove",pointerdown:"touchmove",MSPointerDown:"touchmove"},ar=nn.extend({options:{clickTolerance:3},initialize:function(r,o,l,c){P(this,c),this._element=r,this._dragStartTarget=o||r,this._preventOutline=l},enable:function(){this._enabled||(Q(this._dragStartTarget,rh,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(ar._dragging===this&&this.finishDrag(),Ee(this._dragStartTarget,rh,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(r){if(!(r._simulated||!this._enabled)&&(this._moved=!1,!Hl(this._element,"leaflet-zoom-anim")&&!(ar._dragging||r.shiftKey||r.which!==1&&r.button!==1&&!r.touches)&&(ar._dragging=this,this._preventOutline&&Ql(this._element),Kl(),Ii(),!this._moving))){this.fire("down");var o=r.touches?r.touches[0]:r,l=Qd(this._element);this._startPoint=new z(o.clientX,o.clientY),this._parentScale=Yl(l),Q(document,su[r.type],this._onMove,this),Q(document,ih[r.type],this._onUp,this)}},_onMove:function(r){if(!(r._simulated||!this._enabled)){if(r.touches&&r.touches.length>1){this._moved=!0;return}var o=r.touches&&r.touches.length===1?r.touches[0]:r,l=new z(o.clientX,o.clientY)._subtract(this._startPoint);!l.x&&!l.y||Math.abs(l.x)+Math.abs(l.y)_&&(E=k,_=O);_>l&&(o[E]=1,au(r,o,l,c,E),au(r,o,l,E,h))}function Ry(r,o){for(var l=[r[0]],c=1,h=0,_=r.length;c<_;c++)zy(r[c],r[h])>o&&(l.push(r[c]),h=c);return h<_-1&&l.push(r[_-1]),l}var ah;function lh(r,o,l,c,h){var _=c?ah:lr(r,l),E=lr(o,l),k,O,A;for(ah=E;;){if(!(_|E))return[r,o];if(_&E)return!1;k=_||E,O=fs(r,o,k,l,h),A=lr(O,l),k===_?(r=O,_=A):(o=O,E=A)}}function fs(r,o,l,c,h){var _=o.x-r.x,E=o.y-r.y,k=c.min,O=c.max,A,B;return l&8?(A=r.x+_*(O.y-r.y)/E,B=O.y):l&4?(A=r.x+_*(k.y-r.y)/E,B=k.y):l&2?(A=O.x,B=r.y+E*(O.x-r.x)/_):l&1&&(A=k.x,B=r.y+E*(k.x-r.x)/_),new z(A,B,h)}function lr(r,o){var l=0;return r.xo.max.x&&(l|=2),r.yo.max.y&&(l|=8),l}function zy(r,o){var l=o.x-r.x,c=o.y-r.y;return l*l+c*c}function Ui(r,o,l,c){var h=o.x,_=o.y,E=l.x-h,k=l.y-_,O=E*E+k*k,A;return O>0&&(A=((r.x-h)*E+(r.y-_)*k)/O,A>1?(h=l.x,_=l.y):A>0&&(h+=E*A,_+=k*A)),E=r.x-h,k=r.y-_,c?E*E+k*k:new z(h,_)}function on(r){return!T(r[0])||typeof r[0][0]!="object"&&typeof r[0][0]<"u"}function uh(r){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),on(r)}var Ay={simplify:oh,pointToSegmentDistance:sh,closestPointOnSegment:Ny,clipSegment:lh,_getEdgeIntersection:fs,_getBitCode:lr,_sqClosestPointOnSegment:Ui,isFlat:on,_flat:uh};function ch(r,o,l){var c,h=[1,4,2,8],_,E,k,O,A,B,H,oe;for(_=0,B=r.length;_1e-7;k++)A=h*Math.sin(E),A=Math.pow((1-A)/(1+A),h/2),O=Math.PI/2-2*Math.atan(_*A)-E,E+=O;return new se(E*o,r.x*o/l)}},by={LonLat:lu,Mercator:uu,SphericalMercator:Ll},Iy=s({},Pn,{code:"EPSG:3395",projection:uu,transformation:function(){var r=.5/(Math.PI*uu.R);return Ri(r,.5,-r,.5)}()}),fh=s({},Pn,{code:"EPSG:4326",projection:lu,transformation:Ri(1/180,1,-1/180,.5)}),Dy=s({},Xe,{projection:lu,transformation:Ri(1,0,-1,0),scale:function(r){return Math.pow(2,r)},zoom:function(r){return Math.log(r)/Math.LN2},distance:function(r,o){var l=o.lng-r.lng,c=o.lat-r.lat;return Math.sqrt(l*l+c*c)},infinite:!0});Xe.Earth=Pn,Xe.EPSG3395=Iy,Xe.EPSG3857=Nl,Xe.EPSG900913=oy,Xe.EPSG4326=fh,Xe.Simple=Dy;var Rt=nn.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(r){return r.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(r){return r&&r.removeLayer(this),this},getPane:function(r){return this._map.getPane(r?this.options[r]||r:this.options.pane)},addInteractiveTarget:function(r){return this._map._targets[d(r)]=this,this},removeInteractiveTarget:function(r){return delete this._map._targets[d(r)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(r){var o=r.target;if(o.hasLayer(this)){if(this._map=o,this._zoomAnimated=o._zoomAnimated,this.getEvents){var l=this.getEvents();o.on(l,this),this.once("remove",function(){o.off(l,this)},this)}this.onAdd(o),this.getAttribution&&o.attributionControl&&o.attributionControl.addAttribution(this.getAttribution()),this.fire("add"),o.fire("layeradd",{layer:this})}}});te.include({addLayer:function(r){if(!r._layerAdd)throw new Error("The provided object is not a Layer.");var o=d(r);return this._layers[o]?this:(this._layers[o]=r,r._mapToAdd=this,r.beforeAdd&&r.beforeAdd(this),this.whenReady(r._layerAdd,r),this)},removeLayer:function(r){var o=d(r);return this._layers[o]?(this._loaded&&r.onRemove(this),r.getAttribution&&this.attributionControl&&this.attributionControl.removeAttribution(r.getAttribution()),delete this._layers[o],this._loaded&&(this.fire("layerremove",{layer:r}),r.fire("remove")),r._map=r._mapToAdd=null,this):this},hasLayer:function(r){return!!r&&d(r)in this._layers},eachLayer:function(r,o){for(var l in this._layers)r.call(o,this._layers[l]);return this},_addLayers:function(r){r=r?T(r)?r:[r]:[];for(var o=0,l=r.length;othis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()o)return E=(c-o)/l,this._map.layerPointToLatLng([_.x-E*(_.x-h.x),_.y-E*(_.y-h.y)])},getBounds:function(){return this._bounds},addLatLng:function(r,o){return o=o||this._defaultShape(),r=le(r),o.push(r),this._bounds.extend(r),this.redraw()},_setLatLngs:function(r){this._bounds=new ze,this._latlngs=this._convertLatLngs(r)},_defaultShape:function(){return on(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(r){for(var o=[],l=on(r),c=0,h=r.length;c=2&&o[0]instanceof se&&o[0].equals(o[l-1])&&o.pop(),o},_setLatLngs:function(r){sn.prototype._setLatLngs.call(this,r),on(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return on(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var r=this._renderer._bounds,o=this.options.weight,l=new z(o,o);if(r=new K(r.min.subtract(l),r.max.add(l)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(r))){if(this.options.noClip){this._parts=this._rings;return}for(var c=0,h=this._rings.length,_;cr.y!=h.y>r.y&&r.x<(h.x-c.x)*(r.y-c.y)/(h.y-c.y)+c.x&&(o=!o);return o||sn.prototype._containsPoint.call(this,r,!0)}});function Vy(r,o){return new br(r,o)}var an=Ar.extend({initialize:function(r,o){P(this,o),this._layers={},r&&this.addData(r)},addData:function(r){var o=T(r)?r:r.features,l,c,h;if(o){for(l=0,c=o.length;l0?c:[o.src];return}T(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(o.style,"objectFit")&&(o.style.objectFit="fill"),o.autoplay=!!this.options.autoplay,o.loop=!!this.options.loop,o.muted=!!this.options.muted;for(var _=0;_h?(o.height=h+"px",G(r,_)):Se(r,_),this._containerWidth=this._container.offsetWidth},_animateZoom:function(r){var o=this._map._latLngToNewLayerPoint(this._latlng,r.zoom,r.center),l=this._getAnchor();Oe(this._container,o.add(l))},_adjustPan:function(){if(this.options.autoPan){this._map._panAnim&&this._map._panAnim.stop();var r=this._map,o=parseInt(bi(this._container,"marginBottom"),10)||0,l=this._container.offsetHeight+o,c=this._containerWidth,h=new z(this._containerLeft,-l-this._containerBottom);h._add(Cn(this._container));var _=r.layerPointToContainerPoint(h),E=D(this.options.autoPanPadding),k=D(this.options.autoPanPaddingTopLeft||E),O=D(this.options.autoPanPaddingBottomRight||E),A=r.getSize(),B=0,H=0;_.x+c+O.x>A.x&&(B=_.x+c-A.x+O.x),_.x-B-k.x<0&&(B=_.x-k.x),_.y+l+O.y>A.y&&(H=_.y+l-A.y+O.y),_.y-H-k.y<0&&(H=_.y-k.y),(B||H)&&r.fire("autopanstart").panBy([B,H])}},_onCloseButtonClick:function(r){this._close(),rn(r)},_getAnchor:function(){return D(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),Yy=function(r,o){return new Dr(r,o)};te.mergeOptions({closePopupOnClick:!0}),te.include({openPopup:function(r,o,l){return r instanceof Dr||(r=new Dr(l).setContent(r)),o&&r.setLatLng(o),this.hasLayer(r)?this:(this._popup&&this._popup.options.autoClose&&this.closePopup(),this._popup=r,this.addLayer(r))},closePopup:function(r){return(!r||r===this._popup)&&(r=this._popup,this._popup=null),r&&this.removeLayer(r),this}}),Rt.include({bindPopup:function(r,o){return r instanceof Dr?(P(r,o),this._popup=r,r._source=this):((!this._popup||o)&&(this._popup=new Dr(o,this)),this._popup.setContent(r)),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(r,o){return this._popup&&this._map&&(o=this._popup._prepareOpen(this,r,o),this._map.openPopup(this._popup,o)),this},closePopup:function(){return this._popup&&this._popup._close(),this},togglePopup:function(r){return this._popup&&(this._popup._map?this.closePopup():this.openPopup(r)),this},isPopupOpen:function(){return this._popup?this._popup.isOpen():!1},setPopupContent:function(r){return this._popup&&this._popup.setContent(r),this},getPopup:function(){return this._popup},_openPopup:function(r){var o=r.layer||r.target;if(this._popup&&this._map){if(rn(r),o instanceof kn){this.openPopup(r.layer||r.target,r.latlng);return}this._map.hasLayer(this._popup)&&this._popup._source===o?this.closePopup():this.openPopup(o,r.latlng)}},_movePopup:function(r){this._popup.setLatLng(r.latlng)},_onKeyPress:function(r){r.originalEvent.keyCode===13&&this._openPopup(r)}});var Br=ln.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,interactive:!1,opacity:.9},onAdd:function(r){ln.prototype.onAdd.call(this,r),this.setOpacity(this.options.opacity),r.fire("tooltipopen",{tooltip:this}),this._source&&this._source.fire("tooltipopen",{tooltip:this},!0)},onRemove:function(r){ln.prototype.onRemove.call(this,r),r.fire("tooltipclose",{tooltip:this}),this._source&&this._source.fire("tooltipclose",{tooltip:this},!0)},getEvents:function(){var r=ln.prototype.getEvents.call(this);return Ut&&!this.options.permanent&&(r.preclick=this._close),r},_close:function(){this._map&&this._map.closeTooltip(this)},_initLayout:function(){var r="leaflet-tooltip",o=r+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=ie("div",o)},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(r){var o,l,c=this._map,h=this._container,_=c.latLngToContainerPoint(c.getCenter()),E=c.layerPointToContainerPoint(r),k=this.options.direction,O=h.offsetWidth,A=h.offsetHeight,B=D(this.options.offset),H=this._getAnchor();k==="top"?(o=O/2,l=A):k==="bottom"?(o=O/2,l=0):k==="center"?(o=O/2,l=A/2):k==="right"?(o=0,l=A/2):k==="left"?(o=O,l=A/2):E.x<_.x?(k="right",o=0,l=A/2):(k="left",o=O+(B.x+H.x)*2,l=A/2),r=r.subtract(D(o,l,!0)).add(B).add(H),Se(h,"leaflet-tooltip-right"),Se(h,"leaflet-tooltip-left"),Se(h,"leaflet-tooltip-top"),Se(h,"leaflet-tooltip-bottom"),G(h,"leaflet-tooltip-"+k),Oe(h,r)},_updatePosition:function(){var r=this._map.latLngToLayerPoint(this._latlng);this._setPosition(r)},setOpacity:function(r){this.options.opacity=r,this._container&&vt(this._container,r)},_animateZoom:function(r){var o=this._map._latLngToNewLayerPoint(this._latlng,r.zoom,r.center);this._setPosition(o)},_getAnchor:function(){return D(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),Jy=function(r,o){return new Br(r,o)};te.include({openTooltip:function(r,o,l){return r instanceof Br||(r=new Br(l).setContent(r)),o&&r.setLatLng(o),this.hasLayer(r)?this:this.addLayer(r)},closeTooltip:function(r){return r&&this.removeLayer(r),this}}),Rt.include({bindTooltip:function(r,o){return r instanceof Br?(P(r,o),this._tooltip=r,r._source=this):((!this._tooltip||o)&&(this._tooltip=new Br(o,this)),this._tooltip.setContent(r)),this._initTooltipInteractions(),this._tooltip.options.permanent&&this._map&&this._map.hasLayer(this)&&this.openTooltip(),this},unbindTooltip:function(){return this._tooltip&&(this._initTooltipInteractions(!0),this.closeTooltip(),this._tooltip=null),this},_initTooltipInteractions:function(r){if(!(!r&&this._tooltipHandlersAdded)){var o=r?"off":"on",l={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?l.add=this._openTooltip:(l.mouseover=this._openTooltip,l.mouseout=this.closeTooltip,this._tooltip.options.sticky&&(l.mousemove=this._moveTooltip),Ut&&(l.click=this._openTooltip)),this[o](l),this._tooltipHandlersAdded=!r}},openTooltip:function(r,o){return this._tooltip&&this._map&&(o=this._tooltip._prepareOpen(this,r,o),this._map.openTooltip(this._tooltip,o),this._tooltip.options.interactive&&this._tooltip._container&&(G(this._tooltip._container,"leaflet-clickable"),this.addInteractiveTarget(this._tooltip._container))),this},closeTooltip:function(){return this._tooltip&&(this._tooltip._close(),this._tooltip.options.interactive&&this._tooltip._container&&(Se(this._tooltip._container,"leaflet-clickable"),this.removeInteractiveTarget(this._tooltip._container))),this},toggleTooltip:function(r){return this._tooltip&&(this._tooltip._map?this.closeTooltip():this.openTooltip(r)),this},isTooltipOpen:function(){return this._tooltip.isOpen()},setTooltipContent:function(r){return this._tooltip&&this._tooltip.setContent(r),this},getTooltip:function(){return this._tooltip},_openTooltip:function(r){var o=r.layer||r.target;!this._tooltip||!this._map||this.openTooltip(o,this._tooltip.options.sticky?r.latlng:void 0)},_moveTooltip:function(r){var o=r.latlng,l,c;this._tooltip.options.sticky&&r.originalEvent&&(l=this._map.mouseEventToContainerPoint(r.originalEvent),c=this._map.containerPointToLayerPoint(l),o=this._map.layerPointToLatLng(c)),this._tooltip.setLatLng(o)}});var vh=jr.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(r){var o=r&&r.tagName==="DIV"?r:document.createElement("div"),l=this.options;if(l.html instanceof Element?(is(o),o.appendChild(l.html)):o.innerHTML=l.html!==!1?l.html:"",l.bgPos){var c=D(l.bgPos);o.style.backgroundPosition=-c.x+"px "+-c.y+"px"}return this._setIconStyles(o,"icon"),o},createShadow:function(){return null}});function Xy(r){return new vh(r)}jr.Default=Zi;var Hi=Rt.extend({options:{tileSize:256,opacity:1,updateWhenIdle:kr,updateWhenZooming:!0,updateInterval:200,zIndex:1,bounds:null,minZoom:0,maxZoom:void 0,maxNativeZoom:void 0,minNativeZoom:void 0,noWrap:!1,pane:"tilePane",className:"",keepBuffer:2},initialize:function(r){P(this,r)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView(),this._update()},beforeAdd:function(r){r._addZoomLimit(this)},onRemove:function(r){this._removeAllTiles(),ge(this._container),r._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(Mr(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(Rr(this._container),this._setAutoZIndex(Math.min)),this},getContainer:function(){return this._container},setOpacity:function(r){return this.options.opacity=r,this._updateOpacity(),this},setZIndex:function(r){return this.options.zIndex=r,this._updateZIndex(),this},isLoading:function(){return this._loading},redraw:function(){return this._map&&(this._removeAllTiles(),this._update()),this},getEvents:function(){var r={viewprereset:this._invalidateAll,viewreset:this._resetView,zoom:this._resetView,moveend:this._onMoveEnd};return this.options.updateWhenIdle||(this._onMove||(this._onMove=p(this._onMoveEnd,this.options.updateInterval,this)),r.move=this._onMove),this._zoomAnimated&&(r.zoomanim=this._animateZoom),r},createTile:function(){return document.createElement("div")},getTileSize:function(){var r=this.options.tileSize;return r instanceof z?r:new z(r,r)},_updateZIndex:function(){this._container&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(r){for(var o=this.getPane().children,l=-r(-1/0,1/0),c=0,h=o.length,_;cthis.options.maxZoom||lc?this._retainParent(h,_,E,c):!1)},_retainChildren:function(r,o,l,c){for(var h=2*r;h<2*r+2;h++)for(var _=2*o;_<2*o+2;_++){var E=new z(h,_);E.z=l+1;var k=this._tileCoordsToKey(E),O=this._tiles[k];if(O&&O.active){O.retain=!0;continue}else O&&O.loaded&&(O.retain=!0);l+1this.options.maxZoom||this.options.minZoom!==void 0&&h1){this._setView(r,l);return}for(var H=h.min.y;H<=h.max.y;H++)for(var oe=h.min.x;oe<=h.max.x;oe++){var un=new z(oe,H);if(un.z=this._tileZoom,!!this._isValidTile(un)){var ur=this._tiles[this._tileCoordsToKey(un)];ur?ur.current=!0:E.push(un)}}if(E.sort(function(Ln,mu){return Ln.distanceTo(_)-mu.distanceTo(_)}),E.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var ys=document.createDocumentFragment();for(oe=0;oel.max.x)||!o.wrapLat&&(r.yl.max.y))return!1}if(!this.options.bounds)return!0;var c=this._tileCoordsToBounds(r);return de(this.options.bounds).overlaps(c)},_keyToBounds:function(r){return this._tileCoordsToBounds(this._keyToTileCoords(r))},_tileCoordsToNwSe:function(r){var o=this._map,l=this.getTileSize(),c=r.scaleBy(l),h=c.add(l),_=o.unproject(c,r.z),E=o.unproject(h,r.z);return[_,E]},_tileCoordsToBounds:function(r){var o=this._tileCoordsToNwSe(r),l=new ze(o[0],o[1]);return this.options.noWrap||(l=this._map.wrapLatLngBounds(l)),l},_tileCoordsToKey:function(r){return r.x+":"+r.y+":"+r.z},_keyToTileCoords:function(r){var o=r.split(":"),l=new z(+o[0],+o[1]);return l.z=+o[2],l},_removeTile:function(r){var o=this._tiles[r];o&&(ge(o.el),delete this._tiles[r],this.fire("tileunload",{tile:o.el,coords:this._keyToTileCoords(r)}))},_initTile:function(r){G(r,"leaflet-tile");var o=this.getTileSize();r.style.width=o.x+"px",r.style.height=o.y+"px",r.onselectstart=g,r.onmousemove=g,Cr&&this.options.opacity<1&&vt(r,this.options.opacity),zi&&!Ai&&(r.style.WebkitBackfaceVisibility="hidden")},_addTile:function(r,o){var l=this._getTilePos(r),c=this._tileCoordsToKey(r),h=this.createTile(this._wrapCoords(r),u(this._tileReady,this,r));this._initTile(h),this.createTile.length<2&&X(u(this._tileReady,this,r,null,h)),Oe(h,l),this._tiles[c]={el:h,coords:r,current:!0},o.appendChild(h),this.fire("tileloadstart",{tile:h,coords:r})},_tileReady:function(r,o,l){o&&this.fire("tileerror",{error:o,tile:l,coords:r});var c=this._tileCoordsToKey(r);l=this._tiles[c],l&&(l.loaded=+new Date,this._map._fadeAnimated?(vt(l.el,0),Le(this._fadeFrame),this._fadeFrame=X(this._updateOpacity,this)):(l.active=!0,this._pruneTiles()),o||(G(l.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:l.el,coords:r})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),Cr||!this._map._fadeAnimated?X(this._pruneTiles,this):setTimeout(u(this._pruneTiles,this),250)))},_getTilePos:function(r){return r.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(r){var o=new z(this._wrapX?m(r.x,this._wrapX):r.x,this._wrapY?m(r.y,this._wrapY):r.y);return o.z=r.z,o},_pxBoundsToTileRange:function(r){var o=this.getTileSize();return new K(r.min.unscaleBy(o).floor(),r.max.unscaleBy(o).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var r in this._tiles)if(!this._tiles[r].loaded)return!1;return!0}});function e0(r){return new Hi(r)}var Fr=Hi.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1},initialize:function(r,o){this._url=r,o=P(this,o),o.detectRetina&&Tn&&o.maxZoom>0&&(o.tileSize=Math.floor(o.tileSize/2),o.zoomReverse?(o.zoomOffset--,o.minZoom++):(o.zoomOffset++,o.maxZoom--),o.minZoom=Math.max(0,o.minZoom)),typeof o.subdomains=="string"&&(o.subdomains=o.subdomains.split("")),zi||this.on("tileunload",this._onTileRemove)},setUrl:function(r,o){return this._url===r&&o===void 0&&(o=!0),this._url=r,o||this.redraw(),this},createTile:function(r,o){var l=document.createElement("img");return Q(l,"load",u(this._tileOnLoad,this,o,l)),Q(l,"error",u(this._tileOnError,this,o,l)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(l.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),l.alt="",l.setAttribute("role","presentation"),l.src=this.getTileUrl(r),l},getTileUrl:function(r){var o={r:Tn?"@2x":"",s:this._getSubdomain(r),x:r.x,y:r.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var l=this._globalTileRange.max.y-r.y;this.options.tms&&(o.y=l),o["-y"]=l}return w(this._url,s(o,this.options))},_tileOnLoad:function(r,o){Cr?setTimeout(u(r,this,null,o),0):r(null,o)},_tileOnError:function(r,o,l){var c=this.options.errorTileUrl;c&&o.getAttribute("src")!==c&&(o.src=c),r(l,o)},_onTileRemove:function(r){r.tile.onload=null},_getZoomForUrl:function(){var r=this._tileZoom,o=this.options.maxZoom,l=this.options.zoomReverse,c=this.options.zoomOffset;return l&&(r=o-r),r+c},_getSubdomain:function(r){var o=Math.abs(r.x+r.y)%this.options.subdomains.length;return this.options.subdomains[o]},_abortLoading:function(){var r,o;for(r in this._tiles)this._tiles[r].coords.z!==this._tileZoom&&(o=this._tiles[r].el,o.onload=g,o.onerror=g,o.complete||(o.src=I,ge(o),delete this._tiles[r]))},_removeTile:function(r){var o=this._tiles[r];if(o)return Bd||o.el.setAttribute("src",I),Hi.prototype._removeTile.call(this,r)},_tileReady:function(r,o,l){if(!(!this._map||l&&l.getAttribute("src")===I))return Hi.prototype._tileReady.call(this,r,o,l)}});function gh(r,o){return new Fr(r,o)}var yh=Fr.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(r,o){this._url=r;var l=s({},this.defaultWmsParams);for(var c in o)c in this.options||(l[c]=o[c]);o=P(this,o);var h=o.detectRetina&&Tn?2:1,_=this.getTileSize();l.width=_.x*h,l.height=_.y*h,this.wmsParams=l},onAdd:function(r){this._crs=this.options.crs||r.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var o=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[o]=this._crs.code,Fr.prototype.onAdd.call(this,r)},getTileUrl:function(r){var o=this._tileCoordsToNwSe(r),l=this._crs,c=ae(l.project(o[0]),l.project(o[1])),h=c.min,_=c.max,E=(this._wmsVersion>=1.3&&this._crs===fh?[h.y,h.x,_.y,_.x]:[h.x,h.y,_.x,_.y]).join(","),k=Fr.prototype.getTileUrl.call(this,r);return k+R(this.wmsParams,k,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+E},setParams:function(r,o){return s(this.wmsParams,r),o||this.redraw(),this}});function t0(r,o){return new yh(r,o)}Fr.WMS=yh,gh.wms=t0;var Wt=Rt.extend({options:{padding:.1,tolerance:0},initialize:function(r){P(this,r),d(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),this._zoomAnimated&&G(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 r={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(r.zoomanim=this._onAnimZoom),r},_onAnimZoom:function(r){this._updateTransform(r.center,r.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(r,o){var l=this._map.getZoomScale(o,this._zoom),c=Cn(this._container),h=this._map.getSize().multiplyBy(.5+this.options.padding),_=this._map.project(this._center,o),E=this._map.project(r,o),k=E.subtract(_),O=h.multiplyBy(-l).add(c).add(h).subtract(k);_t?or(this._container,O,l):Oe(this._container,O)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var r in this._layers)this._layers[r]._reset()},_onZoomEnd:function(){for(var r in this._layers)this._layers[r]._project()},_updatePaths:function(){for(var r in this._layers)this._layers[r]._update()},_update:function(){var r=this.options.padding,o=this._map.getSize(),l=this._map.containerPointToLayerPoint(o.multiplyBy(-r)).round();this._bounds=new K(l,l.add(o.multiplyBy(1+r*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),wh=Wt.extend({getEvents:function(){var r=Wt.prototype.getEvents.call(this);return r.viewprereset=this._onViewPreReset,r},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Wt.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var r=this._container=document.createElement("canvas");Q(r,"mousemove",this._onMouseMove,this),Q(r,"click dblclick mousedown mouseup contextmenu",this._onClick,this),Q(r,"mouseout",this._handleMouseOut,this),this._ctx=r.getContext("2d")},_destroyContainer:function(){Le(this._redrawRequest),delete this._ctx,ge(this._container),Ee(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var r;this._redrawBounds=null;for(var o in this._layers)r=this._layers[o],r._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Wt.prototype._update.call(this);var r=this._bounds,o=this._container,l=r.getSize(),c=Tn?2:1;Oe(o,r.min),o.width=c*l.x,o.height=c*l.y,o.style.width=l.x+"px",o.style.height=l.y+"px",Tn&&this._ctx.scale(2,2),this._ctx.translate(-r.min.x,-r.min.y),this.fire("update")}},_reset:function(){Wt.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(r){this._updateDashArray(r),this._layers[d(r)]=r;var o=r._order={layer:r,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=o),this._drawLast=o,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(r){this._requestRedraw(r)},_removePath:function(r){var o=r._order,l=o.next,c=o.prev;l?l.prev=c:this._drawLast=c,c?c.next=l:this._drawFirst=l,delete r._order,delete this._layers[d(r)],this._requestRedraw(r)},_updatePath:function(r){this._extendRedrawBounds(r),r._project(),r._update(),this._requestRedraw(r)},_updateStyle:function(r){this._updateDashArray(r),this._requestRedraw(r)},_updateDashArray:function(r){if(typeof r.options.dashArray=="string"){var o=r.options.dashArray.split(/[, ]+/),l=[],c,h;for(h=0;h')}}catch{return function(o){return document.createElement("<"+o+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}}(),n0={_initContainer:function(){this._container=ie("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Wt.prototype._update.call(this),this.fire("update"))},_initPath:function(r){var o=r._container=Wi("shape");G(o,"leaflet-vml-shape "+(this.options.className||"")),o.coordsize="1 1",r._path=Wi("path"),o.appendChild(r._path),this._updateStyle(r),this._layers[d(r)]=r},_addPath:function(r){var o=r._container;this._container.appendChild(o),r.options.interactive&&r.addInteractiveTarget(o)},_removePath:function(r){var o=r._container;ge(o),r.removeInteractiveTarget(o),delete this._layers[d(r)]},_updateStyle:function(r){var o=r._stroke,l=r._fill,c=r.options,h=r._container;h.stroked=!!c.stroke,h.filled=!!c.fill,c.stroke?(o||(o=r._stroke=Wi("stroke")),h.appendChild(o),o.weight=c.weight+"px",o.color=c.color,o.opacity=c.opacity,c.dashArray?o.dashStyle=T(c.dashArray)?c.dashArray.join(" "):c.dashArray.replace(/( *, *)/g," "):o.dashStyle="",o.endcap=c.lineCap.replace("butt","flat"),o.joinstyle=c.lineJoin):o&&(h.removeChild(o),r._stroke=null),c.fill?(l||(l=r._fill=Wi("fill")),h.appendChild(l),l.color=c.fillColor||c.color,l.opacity=c.fillOpacity):l&&(h.removeChild(l),r._fill=null)},_updateCircle:function(r){var o=r._point.round(),l=Math.round(r._radius),c=Math.round(r._radiusY||l);this._setPath(r,r._empty()?"M0 0":"AL "+o.x+","+o.y+" "+l+","+c+" 0,"+65535*360)},_setPath:function(r,o){r._path.v=o},_bringToFront:function(r){Mr(r._container)},_bringToBack:function(r){Rr(r._container)}},gs=ts?Wi:Id,Vi=Wt.extend({getEvents:function(){var r=Wt.prototype.getEvents.call(this);return r.zoomstart=this._onZoomStart,r},_initContainer:function(){this._container=gs("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=gs("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){ge(this._container),Ee(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_onZoomStart:function(){this._update()},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Wt.prototype._update.call(this);var r=this._bounds,o=r.getSize(),l=this._container;(!this._svgSize||!this._svgSize.equals(o))&&(this._svgSize=o,l.setAttribute("width",o.x),l.setAttribute("height",o.y)),Oe(l,r.min),l.setAttribute("viewBox",[r.min.x,r.min.y,o.x,o.y].join(" ")),this.fire("update")}},_initPath:function(r){var o=r._path=gs("path");r.options.className&&G(o,r.options.className),r.options.interactive&&G(o,"leaflet-interactive"),this._updateStyle(r),this._layers[d(r)]=r},_addPath:function(r){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(r._path),r.addInteractiveTarget(r._path)},_removePath:function(r){ge(r._path),r.removeInteractiveTarget(r._path),delete this._layers[d(r)]},_updatePath:function(r){r._project(),r._update()},_updateStyle:function(r){var o=r._path,l=r.options;o&&(l.stroke?(o.setAttribute("stroke",l.color),o.setAttribute("stroke-opacity",l.opacity),o.setAttribute("stroke-width",l.weight),o.setAttribute("stroke-linecap",l.lineCap),o.setAttribute("stroke-linejoin",l.lineJoin),l.dashArray?o.setAttribute("stroke-dasharray",l.dashArray):o.removeAttribute("stroke-dasharray"),l.dashOffset?o.setAttribute("stroke-dashoffset",l.dashOffset):o.removeAttribute("stroke-dashoffset")):o.setAttribute("stroke","none"),l.fill?(o.setAttribute("fill",l.fillColor||l.color),o.setAttribute("fill-opacity",l.fillOpacity),o.setAttribute("fill-rule",l.fillRule||"evenodd")):o.setAttribute("fill","none"))},_updatePoly:function(r,o){this._setPath(r,Dd(r._parts,o))},_updateCircle:function(r){var o=r._point,l=Math.max(Math.round(r._radius),1),c=Math.max(Math.round(r._radiusY),1)||l,h="a"+l+","+c+" 0 1,0 ",_=r._empty()?"M0 0":"M"+(o.x-l)+","+o.y+h+l*2+",0 "+h+-l*2+",0 ";this._setPath(r,_)},_setPath:function(r,o){r._path.setAttribute("d",o)},_bringToFront:function(r){Mr(r._path)},_bringToBack:function(r){Rr(r._path)}});ts&&Vi.include(n0);function Sh(r){return es||ts?new Vi(r):null}te.include({getRenderer:function(r){var o=r.options.renderer||this._getPaneRenderer(r.options.pane)||this.options.renderer||this._renderer;return o||(o=this._renderer=this._createRenderer()),this.hasLayer(o)||this.addLayer(o),o},_getPaneRenderer:function(r){if(r==="overlayPane"||r===void 0)return!1;var o=this._paneRenderers[r];return o===void 0&&(o=this._createRenderer({pane:r}),this._paneRenderers[r]=o),o},_createRenderer:function(r){return this.options.preferCanvas&&xh(r)||Sh(r)}});var Ph=br.extend({initialize:function(r,o){br.prototype.initialize.call(this,this._boundsToLatLngs(r),o)},setBounds:function(r){return this.setLatLngs(this._boundsToLatLngs(r))},_boundsToLatLngs:function(r){return r=de(r),[r.getSouthWest(),r.getNorthWest(),r.getNorthEast(),r.getSouthEast()]}});function r0(r,o){return new Ph(r,o)}Vi.create=gs,Vi.pointsToPath=Dd,an.geometryToLayer=fu,an.coordsToLatLng=du,an.coordsToLatLngs=ps,an.latLngToCoords=hu,an.latLngsToCoords=ms,an.getFeature=Ir,an.asFeature=_s,te.mergeOptions({boxZoom:!0});var Eh=Ht.extend({initialize:function(r){this._map=r,this._container=r._container,this._pane=r._panes.overlayPane,this._resetStateTimeout=0,r.on("unload",this._destroy,this)},addHooks:function(){Q(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){Ee(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){ge(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(r){if(!r.shiftKey||r.which!==1&&r.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),Ii(),Kl(),this._startPoint=this._map.mouseEventToContainerPoint(r),Q(document,{contextmenu:rn,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(r){this._moved||(this._moved=!0,this._box=ie("div","leaflet-zoom-box",this._container),G(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(r);var o=new K(this._point,this._startPoint),l=o.getSize();Oe(this._box,o.min),this._box.style.width=l.x+"px",this._box.style.height=l.y+"px"},_finish:function(){this._moved&&(ge(this._box),Se(this._container,"leaflet-crosshair")),Di(),ql(),Ee(document,{contextmenu:rn,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(r){if(!(r.which!==1&&r.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(u(this._resetState,this),0);var o=new ze(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(o).fire("boxzoomend",{boxZoomBounds:o})}},_onKeyDown:function(r){r.keyCode===27&&this._finish()}});te.addInitHook("addHandler","boxZoom",Eh),te.mergeOptions({doubleClickZoom:!0});var Th=Ht.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(r){var o=this._map,l=o.getZoom(),c=o.options.zoomDelta,h=r.originalEvent.shiftKey?l-c:l+c;o.options.doubleClickZoom==="center"?o.setZoom(h):o.setZoomAround(r.containerPoint,h)}});te.addInitHook("addHandler","doubleClickZoom",Th),te.mergeOptions({dragging:!0,inertia:!Ai,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var Ch=Ht.extend({addHooks:function(){if(!this._draggable){var r=this._map;this._draggable=new ar(r._mapPane,r._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),r.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),r.on("zoomend",this._onZoomEnd,this),r.whenReady(this._onZoomEnd,this))}G(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){Se(this._map._container,"leaflet-grab"),Se(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 r=this._map;if(r._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var o=de(this._map.options.maxBounds);this._offsetLimit=ae(this._map.latLngToContainerPoint(o.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(o.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;r.fire("movestart").fire("dragstart"),r.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(r){if(this._map.options.inertia){var o=this._lastTime=+new Date,l=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(l),this._times.push(o),this._prunePositions(o)}this._map.fire("move",r).fire("drag",r)},_prunePositions:function(r){for(;this._positions.length>1&&r-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var r=this._map.getSize().divideBy(2),o=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=o.subtract(r).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(r,o){return r-(r-o)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var r=this._draggable._newPos.subtract(this._draggable._startPos),o=this._offsetLimit;r.xo.max.x&&(r.x=this._viscousLimit(r.x,o.max.x)),r.y>o.max.y&&(r.y=this._viscousLimit(r.y,o.max.y)),this._draggable._newPos=this._draggable._startPos.add(r)}},_onPreDragWrap:function(){var r=this._worldWidth,o=Math.round(r/2),l=this._initialWorldOffset,c=this._draggable._newPos.x,h=(c-o+l)%r+o-l,_=(c+o+l)%r-o-l,E=Math.abs(h+l)0?_:-_))-o;this._delta=0,this._startTime=null,E&&(r.options.scrollWheelZoom==="center"?r.setZoom(o+E):r.setZoomAround(this._lastMousePos,o+E))}});te.addInitHook("addHandler","scrollWheelZoom",Lh),te.mergeOptions({tap:!0,tapTolerance:15});var Oh=Ht.extend({addHooks:function(){Q(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){Ee(this._map._container,"touchstart",this._onDown,this)},_onDown:function(r){if(r.touches){if(gt(r),this._fireClick=!0,r.touches.length>1){this._fireClick=!1,clearTimeout(this._holdTimeout);return}var o=r.touches[0],l=o.target;this._startPos=this._newPos=new z(o.clientX,o.clientY),l.tagName&&l.tagName.toLowerCase()==="a"&&G(l,"leaflet-active"),this._holdTimeout=setTimeout(u(function(){this._isTapValid()&&(this._fireClick=!1,this._onUp(),this._simulateEvent("contextmenu",o))},this),1e3),this._simulateEvent("mousedown",o),Q(document,{touchmove:this._onMove,touchend:this._onUp},this)}},_onUp:function(r){if(clearTimeout(this._holdTimeout),Ee(document,{touchmove:this._onMove,touchend:this._onUp},this),this._fireClick&&r&&r.changedTouches){var o=r.changedTouches[0],l=o.target;l&&l.tagName&&l.tagName.toLowerCase()==="a"&&Se(l,"leaflet-active"),this._simulateEvent("mouseup",o),this._isTapValid()&&this._simulateEvent("click",o)}},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_onMove:function(r){var o=r.touches[0];this._newPos=new z(o.clientX,o.clientY),this._simulateEvent("mousemove",o)},_simulateEvent:function(r,o){var l=document.createEvent("MouseEvents");l._simulated=!0,o.target._simulatedClick=!0,l.initMouseEvent(r,!0,!0,window,1,o.screenX,o.screenY,o.clientX,o.clientY,!1,!1,!1,!1,0,null),o.target.dispatchEvent(l)}});Ut&&(!$t||Xo)&&te.addInitHook("addHandler","tap",Oh),te.mergeOptions({touchZoom:Ut&&!Ai,bounceAtZoomLimits:!0});var Nh=Ht.extend({addHooks:function(){G(this._map._container,"leaflet-touch-zoom"),Q(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){Se(this._map._container,"leaflet-touch-zoom"),Ee(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(r){var o=this._map;if(!(!r.touches||r.touches.length!==2||o._animatingZoom||this._zooming)){var l=o.mouseEventToContainerPoint(r.touches[0]),c=o.mouseEventToContainerPoint(r.touches[1]);this._centerPoint=o.getSize()._divideBy(2),this._startLatLng=o.containerPointToLatLng(this._centerPoint),o.options.touchZoom!=="center"&&(this._pinchStartLatLng=o.containerPointToLatLng(l.add(c)._divideBy(2))),this._startDist=l.distanceTo(c),this._startZoom=o.getZoom(),this._moved=!1,this._zooming=!0,o._stop(),Q(document,"touchmove",this._onTouchMove,this),Q(document,"touchend",this._onTouchEnd,this),gt(r)}},_onTouchMove:function(r){if(!(!r.touches||r.touches.length!==2||!this._zooming)){var o=this._map,l=o.mouseEventToContainerPoint(r.touches[0]),c=o.mouseEventToContainerPoint(r.touches[1]),h=l.distanceTo(c)/this._startDist;if(this._zoom=o.getScaleZoom(h,this._startZoom),!o.options.bounceAtZoomLimits&&(this._zoomo.getMaxZoom()&&h>1)&&(this._zoom=o._limitZoom(this._zoom)),o.options.touchZoom==="center"){if(this._center=this._startLatLng,h===1)return}else{var _=l._add(c)._divideBy(2)._subtract(this._centerPoint);if(h===1&&_.x===0&&_.y===0)return;this._center=o.unproject(o.project(this._pinchStartLatLng,this._zoom).subtract(_),this._zoom)}this._moved||(o._moveStart(!0,!1),this._moved=!0),Le(this._animRequest);var E=u(o._move,o,this._center,this._zoom,{pinch:!0,round:!1});this._animRequest=X(E,this,!0),gt(r)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,Le(this._animRequest),Ee(document,"touchmove",this._onTouchMove,this),Ee(document,"touchend",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))}});te.addInitHook("addHandler","touchZoom",Nh),te.BoxZoom=Eh,te.DoubleClickZoom=Th,te.Drag=Ch,te.Keyboard=kh,te.ScrollWheelZoom=Lh,te.Tap=Oh,te.TouchZoom=Nh,n.version=i,n.Control=Mt,n.control=$i,n.Browser=cy,n.Evented=nn,n.Mixin=Oy,n.Util=ir,n.Class=mt,n.Handler=Ht,n.extend=s,n.bind=u,n.stamp=d,n.setOptions=P,n.DomEvent=Py,n.DomUtil=xy,n.PosAnimation=eh,n.Draggable=ar,n.LineUtil=Ay,n.PolyUtil=jy,n.Point=z,n.point=D,n.Bounds=K,n.bounds=ae,n.Transformation=Ol,n.transformation=Ri,n.Projection=by,n.LatLng=se,n.latLng=le,n.LatLngBounds=ze,n.latLngBounds=de,n.CRS=Xe,n.GeoJSON=an,n.geoJSON=ph,n.geoJson=Ky,n.Layer=Rt,n.LayerGroup=zr,n.layerGroup=By,n.FeatureGroup=Ar,n.featureGroup=Fy,n.ImageOverlay=vs,n.imageOverlay=qy,n.VideoOverlay=mh,n.videoOverlay=Gy,n.SVGOverlay=_h,n.svgOverlay=Qy,n.DivOverlay=ln,n.Popup=Dr,n.popup=Yy,n.Tooltip=Br,n.tooltip=Jy,n.Icon=jr,n.icon=$y,n.DivIcon=vh,n.divIcon=Xy,n.Marker=ds,n.marker=Uy,n.TileLayer=Fr,n.tileLayer=gh,n.GridLayer=Hi,n.gridLayer=e0,n.SVG=Vi,n.svg=Sh,n.Renderer=Wt,n.Canvas=wh,n.canvas=xh,n.Path=kn,n.CircleMarker=hs,n.circleMarker=Zy,n.Circle=cu,n.circle=Hy,n.Polyline=sn,n.polyline=Wy,n.Polygon=br,n.polygon=Vy,n.Rectangle=Ph,n.rectangle=r0,n.Map=te,n.map=Ey;var i0=window.L;n.noConflict=function(){return window.L=i0,this},window.L=n})})(sf,sf.exports);var wi=sf.exports,be=(e=>(e.Main="/",e.Login="/login",e.Favorites="/favorites",e.Offer="/offer/:id",e))(be||{}),en=(e=>(e[e.Authorized=0]="Authorized",e[e.Unauthorized=1]="Unauthorized",e[e.Unknown=2]="Unknown",e))(en||{});const dS=new wi.Icon({iconUrl:"public/img/pin.svg",iconSize:[40,40],iconAnchor:[20,40]}),hS=new wi.Icon({iconUrl:"public/img/pin-active.svg",iconSize:[40,40],iconAnchor:[20,40]}),rm=50,pS=300,lg={name:"Paris",location:{latitude:48.864716,longitude:2.349014,zoom:13}},mS={name:"Cologne",location:{latitude:50.935173,longitude:6.953101,zoom:13}},_S={name:"Brussels",location:{latitude:50.85045,longitude:4.34878,zoom:13}},vS={name:"Amsterdam",location:{latitude:52.37454,longitude:4.897976,zoom:12}},gS={name:"Hamburg",location:{latitude:53.551086,longitude:9.993682,zoom:13}},yS={name:"Dusseldorf",location:{latitude:51.233334,longitude:6.783333,zoom:12}},wS=[lg,mS,_S,vS,gS,yS],xS=["Popular","Price: low to high","Price: high to low","Top rated first"],nr={offers:"/offers",favorite:"/favorite",login:"/login",logout:"/logout",reviews:"/comments"};function SS({offer:e,onMouseLeave:t,onMouseEnter:n}){return v.jsxs("article",{className:"cities__card place-card",onMouseEnter:n,onMouseLeave:t,children:[e.isPremium&&v.jsx("div",{className:"place-card__mark",children:v.jsx("span",{children:"Premium"})}),v.jsx("div",{className:"cities__image-wrapper place-card__image-wrapper",children:v.jsx(at,{to:be.Offer.replace(":id",e.id),children:v.jsx("img",{className:"place-card__image",src:e.previewImage,width:"260",height:"200",alt:"Place image"})})}),v.jsxs("div",{className:"place-card__info",children:[v.jsxs("div",{className:"place-card__price-wrapper",children:[v.jsxs("div",{className:"place-card__price",children:[v.jsxs("b",{className:"place-card__price-value",children:["€",e.price," "]}),v.jsx("span",{className:"place-card__price-text",children:"/ night"})]}),v.jsxs("button",{className:`place-card__bookmark-button ${e.isFavorite?"place-card__bookmark-button--active":""} button`,type:"button",children:[v.jsx("svg",{className:"place-card__bookmark-icon",width:"18",height:"19",children:v.jsx("use",{xlinkHref:"#icon-bookmark"})}),v.jsx("span",{className:"visually-hidden",children:e.isFavorite?"In bookmarks":"To bookmarks"})]})]}),v.jsx("div",{className:"place-card__rating rating",children:v.jsxs("div",{className:"place-card__stars rating__stars",children:[v.jsx("span",{style:{width:e.rating}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]})}),v.jsx("h2",{className:"place-card__name",children:v.jsx(at,{to:be.Offer.replace(":id",e.id),children:e.title})}),v.jsx("p",{className:"place-card__type",children:e.type})]})]})}function ug({offers:e,onChange:t}){const[n,i]=j.useState(null);j.useEffect(()=>{t(n)},[n,t]);const s=u=>{i(u)},a=()=>{i(null)};return v.jsx("div",{className:"cities__places-list places__list tabs__content",children:e.map(u=>v.jsx(SS,{offer:u,onMouseEnter:()=>s(u.id),onMouseLeave:a},u.id))})}function PS(e,t){const[n,i]=j.useState(null),s=j.useRef(!1);return j.useEffect(()=>{if(e.current&&!s.current){const a=new wi.Map(e.current,{center:[t.location.latitude,t.location.longitude],zoom:t.location.zoom}),u=new wi.TileLayer("https://{s}.basemaps.cartocdn.com/rastertiles/voyager/{z}/{x}/{y}{r}.png",{attribution:'© OpenStreetMap contributors © CARTO'});a.addLayer(u),i(a),s.current=!0}},[e,t]),j.useEffect(()=>{n&&n.setView([t.location.latitude,t.location.longitude],t.location.zoom)},[n,t]),n}function cg({city:e,offers:t,selectedOffer:n}){const i=j.useRef(null),s=PS(i,e);return j.useEffect(()=>{if(s){const a=wi.layerGroup().addTo(s);return t.forEach(u=>{new wi.Marker([u.location.latitude,u.location.longitude]).setIcon(n&&u.id===n.id?hS:dS).addTo(a)}),()=>{a.clearLayers(),s.removeLayer(a)}}},[s,t,n]),v.jsx("div",{className:"cities__map map",style:{height:"500px"},ref:i})}var fg={exports:{}},dg={};/** + */(function(e,t){(function(n,i){i(t)})(m0,function(n){var i="1.7.1";function s(r){var o,l,c,h;for(l=1,c=arguments.length;l"u"||!L||!L.Mixin)){r=T(r)?r:[r];for(var o=0;o0?Math.floor(r):Math.ceil(r)};z.prototype={clone:function(){return new z(this.x,this.y)},add:function(r){return this.clone()._add(D(r))},_add:function(r){return this.x+=r.x,this.y+=r.y,this},subtract:function(r){return this.clone()._subtract(D(r))},_subtract:function(r){return this.x-=r.x,this.y-=r.y,this},divideBy:function(r){return this.clone()._divideBy(r)},_divideBy:function(r){return this.x/=r,this.y/=r,this},multiplyBy:function(r){return this.clone()._multiplyBy(r)},_multiplyBy:function(r){return this.x*=r,this.y*=r,this},scaleBy:function(r){return new z(this.x*r.x,this.y*r.y)},unscaleBy:function(r){return new z(this.x/r.x,this.y/r.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=q(this.x),this.y=q(this.y),this},distanceTo:function(r){r=D(r);var o=r.x-this.x,l=r.y-this.y;return Math.sqrt(o*o+l*l)},equals:function(r){return r=D(r),r.x===this.x&&r.y===this.y},contains:function(r){return r=D(r),Math.abs(r.x)<=Math.abs(this.x)&&Math.abs(r.y)<=Math.abs(this.y)},toString:function(){return"Point("+y(this.x)+", "+y(this.y)+")"}};function D(r,o,l){return r instanceof z?r:T(r)?new z(r[0],r[1]):r==null?r:typeof r=="object"&&"x"in r&&"y"in r?new z(r.x,r.y):new z(r,o,l)}function K(r,o){if(r)for(var l=o?[r,o]:r,c=0,h=l.length;c=this.min.x&&l.x<=this.max.x&&o.y>=this.min.y&&l.y<=this.max.y},intersects:function(r){r=ae(r);var o=this.min,l=this.max,c=r.min,h=r.max,_=h.x>=o.x&&c.x<=l.x,E=h.y>=o.y&&c.y<=l.y;return _&&E},overlaps:function(r){r=ae(r);var o=this.min,l=this.max,c=r.min,h=r.max,_=h.x>o.x&&c.xo.y&&c.y=o.lat&&h.lat<=l.lat&&c.lng>=o.lng&&h.lng<=l.lng},intersects:function(r){r=de(r);var o=this._southWest,l=this._northEast,c=r.getSouthWest(),h=r.getNorthEast(),_=h.lat>=o.lat&&c.lat<=l.lat,E=h.lng>=o.lng&&c.lng<=l.lng;return _&&E},overlaps:function(r){r=de(r);var o=this._southWest,l=this._northEast,c=r.getSouthWest(),h=r.getNorthEast(),_=h.lat>o.lat&&c.lato.lng&&c.lng1,Lr=function(){var r=!1;try{var o=Object.defineProperty({},"passive",{get:function(){r=!0}});window.addEventListener("testPassiveEventSupport",g,o),window.removeEventListener("testPassiveEventSupport",g,o)}catch{}return r}(),Vd=function(){return!!document.createElement("canvas").getContext}(),es=!!(document.createElementNS&&Dd("svg").createSVGRect),ts=!es&&function(){try{var r=document.createElement("div");r.innerHTML='';var o=r.firstChild;return o.style.behavior="url(#default#VML)",o&&typeof o.adj=="object"}catch{return!1}}();function Ht(r){return navigator.userAgent.toLowerCase().indexOf(r)>=0}var fy={ie:Yo,ielt9:Cr,edge:Jo,webkit:Rl,android:Ai,android23:ji,androidStock:Fd,opera:zl,chrome:Al,gecko:jl,safari:Xo,phantom:$d,opera12:Ud,win:Zd,ie3d:bl,webkit3d:Il,gecko3d:Hd,any3d:_t,mobile:kr,mobileWebkit:ly,mobileWebkit3d:uy,msPointer:En,pointer:Ut,touch:Zt,mobileOpera:Wd,mobileGecko:cy,retina:Tn,passiveEvents:Lr,canvas:Vd,svg:es,vml:ts},Dl=En?"MSPointerDown":"pointerdown",Bl=En?"MSPointerMove":"pointermove",Fl=En?"MSPointerUp":"pointerup",$l=En?"MSPointerCancel":"pointercancel",Or={},Kd=!1;function dy(r,o,l,c){return o==="touchstart"?py(r,l,c):o==="touchmove"?vy(r,l,c):o==="touchend"&&gy(r,l,c),this}function hy(r,o,l){var c=r["_leaflet_"+o+l];return o==="touchstart"?r.removeEventListener(Dl,c,!1):o==="touchmove"?r.removeEventListener(Bl,c,!1):o==="touchend"&&(r.removeEventListener(Fl,c,!1),r.removeEventListener($l,c,!1)),this}function py(r,o,l){var c=u(function(h){h.MSPOINTER_TYPE_TOUCH&&h.pointerType===h.MSPOINTER_TYPE_TOUCH&>(h),Ul(h,o)});r["_leaflet_touchstart"+l]=c,r.addEventListener(Dl,c,!1),Kd||(document.addEventListener(Dl,my,!0),document.addEventListener(Bl,_y,!0),document.addEventListener(Fl,qd,!0),document.addEventListener($l,qd,!0),Kd=!0)}function my(r){Or[r.pointerId]=r}function _y(r){Or[r.pointerId]&&(Or[r.pointerId]=r)}function qd(r){delete Or[r.pointerId]}function Ul(r,o){r.touches=[];for(var l in Or)r.touches.push(Or[l]);r.changedTouches=[r],o(r)}function vy(r,o,l){var c=function(h){h.pointerType===(h.MSPOINTER_TYPE_MOUSE||"mouse")&&h.buttons===0||Ul(h,o)};r["_leaflet_touchmove"+l]=c,r.addEventListener(Bl,c,!1)}function gy(r,o,l){var c=function(h){Ul(h,o)};r["_leaflet_touchend"+l]=c,r.addEventListener(Fl,c,!1),r.addEventListener($l,c,!1)}var ns=En?"MSPointerDown":Ut?"pointerdown":"touchstart",rs=En?"MSPointerUp":Ut?"pointerup":"touchend",Nr="_leaflet_";function yy(r,o,l){var c,h,_=!1,E=250;function k(A){if(Ut){if(!A.isPrimary||A.pointerType==="mouse")return}else if(A.touches.length>1)return;var B=Date.now(),H=B-(c||B);h=A.touches?A.touches[0]:A,_=H>0&&H<=E,c=B}function O(A){if(_&&!h.cancelBubble){if(Ut){if(A.pointerType==="mouse")return;var B={},H,oe;for(oe in h)H=h[oe],B[oe]=H&&H.bind?H.bind(h):H;h=B}h.type="dblclick",h.button=0,o(h),c=null}}return r[Nr+ns+l]=k,r[Nr+rs+l]=O,r[Nr+"dblclick"+l]=o,r.addEventListener(ns,k,Lr?{passive:!1}:!1),r.addEventListener(rs,O,Lr?{passive:!1}:!1),r.addEventListener("dblclick",o,!1),this}function wy(r,o){var l=r[Nr+ns+o],c=r[Nr+rs+o],h=r[Nr+"dblclick"+o];return r.removeEventListener(ns,l,Lr?{passive:!1}:!1),r.removeEventListener(rs,c,Lr?{passive:!1}:!1),r.removeEventListener("dblclick",h,!1),this}var Zl=ss(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),bi=ss(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),Gd=bi==="webkitTransition"||bi==="OTransition"?bi+"End":"transitionend";function Qd(r){return typeof r=="string"?document.getElementById(r):r}function Ii(r,o){var l=r.style[o]||r.currentStyle&&r.currentStyle[o];if((!l||l==="auto")&&document.defaultView){var c=document.defaultView.getComputedStyle(r,null);l=c?c[o]:null}return l==="auto"?null:l}function ie(r,o,l){var c=document.createElement(r);return c.className=o||"",l&&l.appendChild(c),c}function ge(r){var o=r.parentNode;o&&o.removeChild(r)}function is(r){for(;r.firstChild;)r.removeChild(r.firstChild)}function Mr(r){var o=r.parentNode;o&&o.lastChild!==r&&o.appendChild(r)}function Rr(r){var o=r.parentNode;o&&o.firstChild!==r&&o.insertBefore(r,o.firstChild)}function Hl(r,o){if(r.classList!==void 0)return r.classList.contains(o);var l=os(r);return l.length>0&&new RegExp("(^|\\s)"+o+"(\\s|$)").test(l)}function G(r,o){if(r.classList!==void 0)for(var l=x(o),c=0,h=l.length;cthis.options.maxZoom)?this.setZoom(r):this},panInsideBounds:function(r,o){this._enforcingBounds=!0;var l=this.getCenter(),c=this._limitCenter(l,this._zoom,de(r));return l.equals(c)||this.panTo(c,o),this._enforcingBounds=!1,this},panInside:function(r,o){o=o||{};var l=D(o.paddingTopLeft||o.padding||[0,0]),c=D(o.paddingBottomRight||o.padding||[0,0]),h=this.getCenter(),_=this.project(h),E=this.project(r),k=this.getPixelBounds(),O=k.getSize().divideBy(2),A=ae([k.min.add(l),k.max.subtract(c)]);if(!A.contains(E)){this._enforcingBounds=!0;var B=_.subtract(E),H=D(E.x+B.x,E.y+B.y);(E.xA.max.x)&&(H.x=_.x-B.x,B.x>0?H.x+=O.x-l.x:H.x-=O.x-c.x),(E.yA.max.y)&&(H.y=_.y-B.y,B.y>0?H.y+=O.y-l.y:H.y-=O.y-c.y),this.panTo(this.unproject(H),o),this._enforcingBounds=!1}return this},invalidateSize:function(r){if(!this._loaded)return this;r=s({animate:!1,pan:!0},r===!0?{animate:!0}:r);var o=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var l=this.getSize(),c=o.divideBy(2).round(),h=l.divideBy(2).round(),_=c.subtract(h);return!_.x&&!_.y?this:(r.animate&&r.pan?this.panBy(_):(r.pan&&this._rawPanBy(_),this.fire("move"),r.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(u(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:o,newSize:l}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(r){if(r=this._locateOptions=s({timeout:1e4,watch:!1},r),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var o=u(this._handleGeolocationResponse,this),l=u(this._handleGeolocationError,this);return r.watch?this._locationWatchId=navigator.geolocation.watchPosition(o,l,r):navigator.geolocation.getCurrentPosition(o,l,r),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(r){var o=r.code,l=r.message||(o===1?"permission denied":o===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:o,message:"Geolocation error: "+l+"."})},_handleGeolocationResponse:function(r){var o=r.coords.latitude,l=r.coords.longitude,c=new se(o,l),h=c.toBounds(r.coords.accuracy*2),_=this._locateOptions;if(_.setView){var E=this.getBoundsZoom(h);this.setView(c,_.maxZoom?Math.min(E,_.maxZoom):E)}var k={latlng:c,bounds:h,timestamp:r.timestamp};for(var O in r.coords)typeof r.coords[O]=="number"&&(k[O]=r.coords[O]);this.fire("locationfound",k)},addHandler:function(r,o){if(!o)return this;var l=this[r]=new o(this);return this._handlers.push(l),this.options[r]&&l.enable(),this},remove:function(){if(this._initEvents(!0),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(),ge(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(Le(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var r;for(r in this._layers)this._layers[r].remove();for(r in this._panes)ge(this._panes[r]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(r,o){var l="leaflet-pane"+(r?" leaflet-"+r.replace("Pane","")+"-pane":""),c=ie("div",l,o||this._mapPane);return r&&(this._panes[r]=c),c},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter:this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var r=this.getPixelBounds(),o=this.unproject(r.getBottomLeft()),l=this.unproject(r.getTopRight());return new ze(o,l)},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(r,o,l){r=de(r),l=D(l||[0,0]);var c=this.getZoom()||0,h=this.getMinZoom(),_=this.getMaxZoom(),E=r.getNorthWest(),k=r.getSouthEast(),O=this.getSize().subtract(l),A=ae(this.project(k,c),this.project(E,c)).getSize(),B=_t?this.options.zoomSnap:1,H=O.x/A.x,oe=O.y/A.y,un=o?Math.max(H,oe):Math.min(H,oe);return c=this.getScaleZoom(un,c),B&&(c=Math.round(c/(B/100))*(B/100),c=o?Math.ceil(c/B)*B:Math.floor(c/B)*B),Math.max(h,Math.min(_,c))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new z(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(r,o){var l=this._getTopLeftPoint(r,o);return new K(l,l.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(r){return this.options.crs.getProjectedBounds(r===void 0?this.getZoom():r)},getPane:function(r){return typeof r=="string"?this._panes[r]:r},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(r,o){var l=this.options.crs;return o=o===void 0?this._zoom:o,l.scale(r)/l.scale(o)},getScaleZoom:function(r,o){var l=this.options.crs;o=o===void 0?this._zoom:o;var c=l.zoom(r*l.scale(o));return isNaN(c)?1/0:c},project:function(r,o){return o=o===void 0?this._zoom:o,this.options.crs.latLngToPoint(le(r),o)},unproject:function(r,o){return o=o===void 0?this._zoom:o,this.options.crs.pointToLatLng(D(r),o)},layerPointToLatLng:function(r){var o=D(r).add(this.getPixelOrigin());return this.unproject(o)},latLngToLayerPoint:function(r){var o=this.project(le(r))._round();return o._subtract(this.getPixelOrigin())},wrapLatLng:function(r){return this.options.crs.wrapLatLng(le(r))},wrapLatLngBounds:function(r){return this.options.crs.wrapLatLngBounds(de(r))},distance:function(r,o){return this.options.crs.distance(le(r),le(o))},containerPointToLayerPoint:function(r){return D(r).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(r){return D(r).add(this._getMapPanePos())},containerPointToLatLng:function(r){var o=this.containerPointToLayerPoint(D(r));return this.layerPointToLatLng(o)},latLngToContainerPoint:function(r){return this.layerPointToContainerPoint(this.latLngToLayerPoint(le(r)))},mouseEventToContainerPoint:function(r){return Xd(r,this._container)},mouseEventToLayerPoint:function(r){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(r))},mouseEventToLatLng:function(r){return this.layerPointToLatLng(this.mouseEventToLayerPoint(r))},_initContainer:function(r){var o=this._container=Qd(r);if(o){if(o._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");Q(o,"scroll",this._onScroll,this),this._containerId=d(o)},_initLayout:function(){var r=this._container;this._fadeAnimated=this.options.fadeAnimation&&_t,G(r,"leaflet-container"+(Zt?" leaflet-touch":"")+(Tn?" leaflet-retina":"")+(Cr?" leaflet-oldie":"")+(Xo?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var o=Ii(r,"position");o!=="absolute"&&o!=="relative"&&o!=="fixed"&&(r.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var r=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),Oe(this._mapPane,new z(0,0)),this.createPane("tilePane"),this.createPane("shadowPane"),this.createPane("overlayPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(G(r.markerPane,"leaflet-zoom-hide"),G(r.shadowPane,"leaflet-zoom-hide"))},_resetView:function(r,o){Oe(this._mapPane,new z(0,0));var l=!this._loaded;this._loaded=!0,o=this._limitZoom(o),this.fire("viewprereset");var c=this._zoom!==o;this._moveStart(c,!1)._move(r,o)._moveEnd(c),this.fire("viewreset"),l&&this.fire("load")},_moveStart:function(r,o){return r&&this.fire("zoomstart"),o||this.fire("movestart"),this},_move:function(r,o,l){o===void 0&&(o=this._zoom);var c=this._zoom!==o;return this._zoom=o,this._lastCenter=r,this._pixelOrigin=this._getNewPixelOrigin(r),(c||l&&l.pinch)&&this.fire("zoom",l),this.fire("move",l)},_moveEnd:function(r){return r&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return Le(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(r){Oe(this._mapPane,this._getMapPanePos().subtract(r))},_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(r){this._targets={},this._targets[d(this._container)]=this;var o=r?Ee:Q;o(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&o(window,"resize",this._onResize,this),_t&&this.options.transform3DLimit&&(r?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){Le(this._resizeRequest),this._resizeRequest=X(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var r=this._getMapPanePos();Math.max(Math.abs(r.x),Math.abs(r.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(r,o){for(var l=[],c,h=o==="mouseout"||o==="mouseover",_=r.target||r.srcElement,E=!1;_;){if(c=this._targets[d(_)],c&&(o==="click"||o==="preclick")&&!r._simulated&&this._draggableMoved(c)){E=!0;break}if(c&&c.listens(o,!0)&&(h&&!cs(_,r)||(l.push(c),h))||_===this._container)break;_=_.parentNode}return!l.length&&!E&&!h&&cs(_,r)&&(l=[this]),l},_handleDOMEvent:function(r){if(!(!this._loaded||ru(r))){var o=r.type;(o==="mousedown"||o==="keypress"||o==="keyup"||o==="keydown")&&Ql(r.target||r.srcElement),this._fireDOMEvent(r,o)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(r,o,l){if(r.type==="click"){var c=s({},r);c.type="preclick",this._fireDOMEvent(c,c.type,l)}if(!r._stopped&&(l=(l||[]).concat(this._findEventTargets(r,o)),!!l.length)){var h=l[0];o==="contextmenu"&&h.listens(o,!0)&>(r);var _={originalEvent:r};if(r.type!=="keypress"&&r.type!=="keydown"&&r.type!=="keyup"){var E=h.getLatLng&&(!h._radius||h._radius<=10);_.containerPoint=E?this.latLngToContainerPoint(h.getLatLng()):this.mouseEventToContainerPoint(r),_.layerPoint=this.containerPointToLayerPoint(_.containerPoint),_.latlng=E?h.getLatLng():this.layerPointToLatLng(_.layerPoint)}for(var k=0;k0?Math.round(r-o)/2:Math.max(0,Math.ceil(r))-Math.max(0,Math.floor(o))},_limitZoom:function(r){var o=this.getMinZoom(),l=this.getMaxZoom(),c=_t?this.options.zoomSnap:1;return c&&(r=Math.round(r/c)*c),Math.max(o,Math.min(l,r))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){Se(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(r,o){var l=this._getCenterOffset(r)._trunc();return(o&&o.animate)!==!0&&!this.getSize().contains(l)?!1:(this.panBy(l,o),!0)},_createAnimProxy:function(){var r=this._proxy=ie("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(r),this.on("zoomanim",function(o){var l=Zl,c=this._proxy.style[l];or(this._proxy,this.project(o.center,o.zoom),this.getZoomScale(o.zoom,1)),c===this._proxy.style[l]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){ge(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var r=this.getCenter(),o=this.getZoom();or(this._proxy,this.project(r,o),this.getZoomScale(o,1))},_catchTransitionEnd:function(r){this._animatingZoom&&r.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(r,o,l){if(this._animatingZoom)return!0;if(l=l||{},!this._zoomAnimated||l.animate===!1||this._nothingToAnimate()||Math.abs(o-this._zoom)>this.options.zoomAnimationThreshold)return!1;var c=this.getZoomScale(o),h=this._getCenterOffset(r)._divideBy(1-1/c);return l.animate!==!0&&!this.getSize().contains(h)?!1:(X(function(){this._moveStart(!0,!1)._animateZoom(r,o,!0)},this),!0)},_animateZoom:function(r,o,l,c){this._mapPane&&(l&&(this._animatingZoom=!0,this._animateToCenter=r,this._animateToZoom=o,G(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:r,zoom:o,noUpdate:c}),setTimeout(u(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&Se(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom),X(function(){this._moveEnd(!0)},this))}});function Ty(r,o){return new te(r,o)}var Mt=mt.extend({options:{position:"topright"},initialize:function(r){P(this,r)},getPosition:function(){return this.options.position},setPosition:function(r){var o=this._map;return o&&o.removeControl(this),this.options.position=r,o&&o.addControl(this),this},getContainer:function(){return this._container},addTo:function(r){this.remove(),this._map=r;var o=this._container=this.onAdd(r),l=this.getPosition(),c=r._controlCorners[l];return G(o,"leaflet-control"),l.indexOf("bottom")!==-1?c.insertBefore(o,c.firstChild):c.appendChild(o),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(ge(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(r){this._map&&r&&r.screenX>0&&r.screenY>0&&this._map.getContainer().focus()}}),Ui=function(r){return new Mt(r)};te.include({addControl:function(r){return r.addTo(this),this},removeControl:function(r){return r.remove(),this},_initControlPos:function(){var r=this._controlCorners={},o="leaflet-",l=this._controlContainer=ie("div",o+"control-container",this._container);function c(h,_){var E=o+h+" "+o+_;r[h+_]=ie("div",E,l)}c("top","left"),c("top","right"),c("bottom","left"),c("bottom","right")},_clearControlPos:function(){for(var r in this._controlCorners)ge(this._controlCorners[r]);ge(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var nh=Mt.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(r,o,l,c){return l1,this._baseLayersList.style.display=r?"":"none"),this._separator.style.display=o&&r?"":"none",this},_onLayerChange:function(r){this._handlingClick||this._update();var o=this._getLayer(d(r.target)),l=o.overlay?r.type==="add"?"overlayadd":"overlayremove":r.type==="add"?"baselayerchange":null;l&&this._map.fire(l,o)},_createRadioElement:function(r,o){var l='",c=document.createElement("div");return c.innerHTML=l,c.firstChild},_addItem:function(r){var o=document.createElement("label"),l=this._map.hasLayer(r.layer),c;r.overlay?(c=document.createElement("input"),c.type="checkbox",c.className="leaflet-control-layers-selector",c.defaultChecked=l):c=this._createRadioElement("leaflet-base-layers_"+d(this),l),this._layerControlInputs.push(c),c.layerId=d(r.layer),Q(c,"click",this._onInputClick,this);var h=document.createElement("span");h.innerHTML=" "+r.name;var _=document.createElement("div");o.appendChild(_),_.appendChild(c),_.appendChild(h);var E=r.overlay?this._overlaysList:this._baseLayersList;return E.appendChild(o),this._checkDisabledLayers(),o},_onInputClick:function(){var r=this._layerControlInputs,o,l,c=[],h=[];this._handlingClick=!0;for(var _=r.length-1;_>=0;_--)o=r[_],l=this._getLayer(o.layerId).layer,o.checked?c.push(l):o.checked||h.push(l);for(_=0;_=0;h--)o=r[h],l=this._getLayer(o.layerId).layer,o.disabled=l.options.minZoom!==void 0&&cl.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expand:function(){return this.expand()},_collapse:function(){return this.collapse()}}),Cy=function(r,o,l){return new nh(r,o,l)},iu=Mt.extend({options:{position:"topleft",zoomInText:"+",zoomInTitle:"Zoom in",zoomOutText:"−",zoomOutTitle:"Zoom out"},onAdd:function(r){var o="leaflet-control-zoom",l=ie("div",o+" leaflet-bar"),c=this.options;return this._zoomInButton=this._createButton(c.zoomInText,c.zoomInTitle,o+"-in",l,this._zoomIn),this._zoomOutButton=this._createButton(c.zoomOutText,c.zoomOutTitle,o+"-out",l,this._zoomOut),this._updateDisabled(),r.on("zoomend zoomlevelschange",this._updateDisabled,this),l},onRemove:function(r){r.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(r){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(r.shiftKey?3:1))},_createButton:function(r,o,l,c,h){var _=ie("a",l,c);return _.innerHTML=r,_.href="#",_.title=o,_.setAttribute("role","button"),_.setAttribute("aria-label",o),$i(_),Q(_,"click",rn),Q(_,"click",h,this),Q(_,"click",this._refocusOnMap,this),_},_updateDisabled:function(){var r=this._map,o="leaflet-disabled";Se(this._zoomInButton,o),Se(this._zoomOutButton,o),(this._disabled||r._zoom===r.getMinZoom())&&G(this._zoomOutButton,o),(this._disabled||r._zoom===r.getMaxZoom())&&G(this._zoomInButton,o)}});te.mergeOptions({zoomControl:!0}),te.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new iu,this.addControl(this.zoomControl))});var ky=function(r){return new iu(r)},rh=Mt.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(r){var o="leaflet-control-scale",l=ie("div",o),c=this.options;return this._addScales(c,o+"-line",l),r.on(c.updateWhenIdle?"moveend":"move",this._update,this),r.whenReady(this._update,this),l},onRemove:function(r){r.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(r,o,l){r.metric&&(this._mScale=ie("div",o,l)),r.imperial&&(this._iScale=ie("div",o,l))},_update:function(){var r=this._map,o=r.getSize().y/2,l=r.distance(r.containerPointToLatLng([0,o]),r.containerPointToLatLng([this.options.maxWidth,o]));this._updateScales(l)},_updateScales:function(r){this.options.metric&&r&&this._updateMetric(r),this.options.imperial&&r&&this._updateImperial(r)},_updateMetric:function(r){var o=this._getRoundNum(r),l=o<1e3?o+" m":o/1e3+" km";this._updateScale(this._mScale,l,o/r)},_updateImperial:function(r){var o=r*3.2808399,l,c,h;o>5280?(l=o/5280,c=this._getRoundNum(l),this._updateScale(this._iScale,c+" mi",c/l)):(h=this._getRoundNum(o),this._updateScale(this._iScale,h+" ft",h/o))},_updateScale:function(r,o,l){r.style.width=Math.round(this.options.maxWidth*l)+"px",r.innerHTML=o},_getRoundNum:function(r){var o=Math.pow(10,(Math.floor(r)+"").length-1),l=r/o;return l=l>=10?10:l>=5?5:l>=3?3:l>=2?2:1,o*l}}),Ly=function(r){return new rh(r)},ou=Mt.extend({options:{position:"bottomright",prefix:'Leaflet'},initialize:function(r){P(this,r),this._attributions={}},onAdd:function(r){r.attributionControl=this,this._container=ie("div","leaflet-control-attribution"),$i(this._container);for(var o in r._layers)r._layers[o].getAttribution&&this.addAttribution(r._layers[o].getAttribution());return this._update(),this._container},setPrefix:function(r){return this.options.prefix=r,this._update(),this},addAttribution:function(r){return r?(this._attributions[r]||(this._attributions[r]=0),this._attributions[r]++,this._update(),this):this},removeAttribution:function(r){return r?(this._attributions[r]&&(this._attributions[r]--,this._update()),this):this},_update:function(){if(this._map){var r=[];for(var o in this._attributions)this._attributions[o]&&r.push(o);var l=[];this.options.prefix&&l.push(this.options.prefix),r.length&&l.push(r.join(", ")),this._container.innerHTML=l.join(" | ")}}});te.mergeOptions({attributionControl:!0}),te.addInitHook(function(){this.options.attributionControl&&new ou().addTo(this)});var Oy=function(r){return new ou(r)};Mt.Layers=nh,Mt.Zoom=iu,Mt.Scale=rh,Mt.Attribution=ou,Ui.layers=Cy,Ui.zoom=ky,Ui.scale=Ly,Ui.attribution=Oy;var Wt=mt.extend({initialize:function(r){this._map=r},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}});Wt.addTo=function(r,o){return r.addHandler(o,this),this};var Ny={Events:Fe},ih=Zt?"touchstart mousedown":"mousedown",oh={mousedown:"mouseup",touchstart:"touchend",pointerdown:"touchend",MSPointerDown:"touchend"},su={mousedown:"mousemove",touchstart:"touchmove",pointerdown:"touchmove",MSPointerDown:"touchmove"},ar=nn.extend({options:{clickTolerance:3},initialize:function(r,o,l,c){P(this,c),this._element=r,this._dragStartTarget=o||r,this._preventOutline=l},enable:function(){this._enabled||(Q(this._dragStartTarget,ih,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(ar._dragging===this&&this.finishDrag(),Ee(this._dragStartTarget,ih,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(r){if(!(r._simulated||!this._enabled)&&(this._moved=!1,!Hl(this._element,"leaflet-zoom-anim")&&!(ar._dragging||r.shiftKey||r.which!==1&&r.button!==1&&!r.touches)&&(ar._dragging=this,this._preventOutline&&Ql(this._element),Kl(),Di(),!this._moving))){this.fire("down");var o=r.touches?r.touches[0]:r,l=Yd(this._element);this._startPoint=new z(o.clientX,o.clientY),this._parentScale=Yl(l),Q(document,su[r.type],this._onMove,this),Q(document,oh[r.type],this._onUp,this)}},_onMove:function(r){if(!(r._simulated||!this._enabled)){if(r.touches&&r.touches.length>1){this._moved=!0;return}var o=r.touches&&r.touches.length===1?r.touches[0]:r,l=new z(o.clientX,o.clientY)._subtract(this._startPoint);!l.x&&!l.y||Math.abs(l.x)+Math.abs(l.y)_&&(E=k,_=O);_>l&&(o[E]=1,au(r,o,l,c,E),au(r,o,l,E,h))}function zy(r,o){for(var l=[r[0]],c=1,h=0,_=r.length;c<_;c++)Ay(r[c],r[h])>o&&(l.push(r[c]),h=c);return h<_-1&&l.push(r[_-1]),l}var lh;function uh(r,o,l,c,h){var _=c?lh:lr(r,l),E=lr(o,l),k,O,A;for(lh=E;;){if(!(_|E))return[r,o];if(_&E)return!1;k=_||E,O=fs(r,o,k,l,h),A=lr(O,l),k===_?(r=O,_=A):(o=O,E=A)}}function fs(r,o,l,c,h){var _=o.x-r.x,E=o.y-r.y,k=c.min,O=c.max,A,B;return l&8?(A=r.x+_*(O.y-r.y)/E,B=O.y):l&4?(A=r.x+_*(k.y-r.y)/E,B=k.y):l&2?(A=O.x,B=r.y+E*(O.x-r.x)/_):l&1&&(A=k.x,B=r.y+E*(k.x-r.x)/_),new z(A,B,h)}function lr(r,o){var l=0;return r.xo.max.x&&(l|=2),r.yo.max.y&&(l|=8),l}function Ay(r,o){var l=o.x-r.x,c=o.y-r.y;return l*l+c*c}function Zi(r,o,l,c){var h=o.x,_=o.y,E=l.x-h,k=l.y-_,O=E*E+k*k,A;return O>0&&(A=((r.x-h)*E+(r.y-_)*k)/O,A>1?(h=l.x,_=l.y):A>0&&(h+=E*A,_+=k*A)),E=r.x-h,k=r.y-_,c?E*E+k*k:new z(h,_)}function on(r){return!T(r[0])||typeof r[0][0]!="object"&&typeof r[0][0]<"u"}function ch(r){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),on(r)}var jy={simplify:sh,pointToSegmentDistance:ah,closestPointOnSegment:My,clipSegment:uh,_getEdgeIntersection:fs,_getBitCode:lr,_sqClosestPointOnSegment:Zi,isFlat:on,_flat:ch};function fh(r,o,l){var c,h=[1,4,2,8],_,E,k,O,A,B,H,oe;for(_=0,B=r.length;_1e-7;k++)A=h*Math.sin(E),A=Math.pow((1-A)/(1+A),h/2),O=Math.PI/2-2*Math.atan(_*A)-E,E+=O;return new se(E*o,r.x*o/l)}},Iy={LonLat:lu,Mercator:uu,SphericalMercator:Ll},Dy=s({},Pn,{code:"EPSG:3395",projection:uu,transformation:function(){var r=.5/(Math.PI*uu.R);return zi(r,.5,-r,.5)}()}),dh=s({},Pn,{code:"EPSG:4326",projection:lu,transformation:zi(1/180,1,-1/180,.5)}),By=s({},Xe,{projection:lu,transformation:zi(1,0,-1,0),scale:function(r){return Math.pow(2,r)},zoom:function(r){return Math.log(r)/Math.LN2},distance:function(r,o){var l=o.lng-r.lng,c=o.lat-r.lat;return Math.sqrt(l*l+c*c)},infinite:!0});Xe.Earth=Pn,Xe.EPSG3395=Dy,Xe.EPSG3857=Nl,Xe.EPSG900913=sy,Xe.EPSG4326=dh,Xe.Simple=By;var Rt=nn.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(r){return r.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(r){return r&&r.removeLayer(this),this},getPane:function(r){return this._map.getPane(r?this.options[r]||r:this.options.pane)},addInteractiveTarget:function(r){return this._map._targets[d(r)]=this,this},removeInteractiveTarget:function(r){return delete this._map._targets[d(r)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(r){var o=r.target;if(o.hasLayer(this)){if(this._map=o,this._zoomAnimated=o._zoomAnimated,this.getEvents){var l=this.getEvents();o.on(l,this),this.once("remove",function(){o.off(l,this)},this)}this.onAdd(o),this.getAttribution&&o.attributionControl&&o.attributionControl.addAttribution(this.getAttribution()),this.fire("add"),o.fire("layeradd",{layer:this})}}});te.include({addLayer:function(r){if(!r._layerAdd)throw new Error("The provided object is not a Layer.");var o=d(r);return this._layers[o]?this:(this._layers[o]=r,r._mapToAdd=this,r.beforeAdd&&r.beforeAdd(this),this.whenReady(r._layerAdd,r),this)},removeLayer:function(r){var o=d(r);return this._layers[o]?(this._loaded&&r.onRemove(this),r.getAttribution&&this.attributionControl&&this.attributionControl.removeAttribution(r.getAttribution()),delete this._layers[o],this._loaded&&(this.fire("layerremove",{layer:r}),r.fire("remove")),r._map=r._mapToAdd=null,this):this},hasLayer:function(r){return!!r&&d(r)in this._layers},eachLayer:function(r,o){for(var l in this._layers)r.call(o,this._layers[l]);return this},_addLayers:function(r){r=r?T(r)?r:[r]:[];for(var o=0,l=r.length;othis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()o)return E=(c-o)/l,this._map.layerPointToLatLng([_.x-E*(_.x-h.x),_.y-E*(_.y-h.y)])},getBounds:function(){return this._bounds},addLatLng:function(r,o){return o=o||this._defaultShape(),r=le(r),o.push(r),this._bounds.extend(r),this.redraw()},_setLatLngs:function(r){this._bounds=new ze,this._latlngs=this._convertLatLngs(r)},_defaultShape:function(){return on(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(r){for(var o=[],l=on(r),c=0,h=r.length;c=2&&o[0]instanceof se&&o[0].equals(o[l-1])&&o.pop(),o},_setLatLngs:function(r){sn.prototype._setLatLngs.call(this,r),on(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return on(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var r=this._renderer._bounds,o=this.options.weight,l=new z(o,o);if(r=new K(r.min.subtract(l),r.max.add(l)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(r))){if(this.options.noClip){this._parts=this._rings;return}for(var c=0,h=this._rings.length,_;cr.y!=h.y>r.y&&r.x<(h.x-c.x)*(r.y-c.y)/(h.y-c.y)+c.x&&(o=!o);return o||sn.prototype._containsPoint.call(this,r,!0)}});function Ky(r,o){return new br(r,o)}var an=Ar.extend({initialize:function(r,o){P(this,o),this._layers={},r&&this.addData(r)},addData:function(r){var o=T(r)?r:r.features,l,c,h;if(o){for(l=0,c=o.length;l0?c:[o.src];return}T(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(o.style,"objectFit")&&(o.style.objectFit="fill"),o.autoplay=!!this.options.autoplay,o.loop=!!this.options.loop,o.muted=!!this.options.muted;for(var _=0;_h?(o.height=h+"px",G(r,_)):Se(r,_),this._containerWidth=this._container.offsetWidth},_animateZoom:function(r){var o=this._map._latLngToNewLayerPoint(this._latlng,r.zoom,r.center),l=this._getAnchor();Oe(this._container,o.add(l))},_adjustPan:function(){if(this.options.autoPan){this._map._panAnim&&this._map._panAnim.stop();var r=this._map,o=parseInt(Ii(this._container,"marginBottom"),10)||0,l=this._container.offsetHeight+o,c=this._containerWidth,h=new z(this._containerLeft,-l-this._containerBottom);h._add(Cn(this._container));var _=r.layerPointToContainerPoint(h),E=D(this.options.autoPanPadding),k=D(this.options.autoPanPaddingTopLeft||E),O=D(this.options.autoPanPaddingBottomRight||E),A=r.getSize(),B=0,H=0;_.x+c+O.x>A.x&&(B=_.x+c-A.x+O.x),_.x-B-k.x<0&&(B=_.x-k.x),_.y+l+O.y>A.y&&(H=_.y+l-A.y+O.y),_.y-H-k.y<0&&(H=_.y-k.y),(B||H)&&r.fire("autopanstart").panBy([B,H])}},_onCloseButtonClick:function(r){this._close(),rn(r)},_getAnchor:function(){return D(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),Jy=function(r,o){return new Dr(r,o)};te.mergeOptions({closePopupOnClick:!0}),te.include({openPopup:function(r,o,l){return r instanceof Dr||(r=new Dr(l).setContent(r)),o&&r.setLatLng(o),this.hasLayer(r)?this:(this._popup&&this._popup.options.autoClose&&this.closePopup(),this._popup=r,this.addLayer(r))},closePopup:function(r){return(!r||r===this._popup)&&(r=this._popup,this._popup=null),r&&this.removeLayer(r),this}}),Rt.include({bindPopup:function(r,o){return r instanceof Dr?(P(r,o),this._popup=r,r._source=this):((!this._popup||o)&&(this._popup=new Dr(o,this)),this._popup.setContent(r)),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(r,o){return this._popup&&this._map&&(o=this._popup._prepareOpen(this,r,o),this._map.openPopup(this._popup,o)),this},closePopup:function(){return this._popup&&this._popup._close(),this},togglePopup:function(r){return this._popup&&(this._popup._map?this.closePopup():this.openPopup(r)),this},isPopupOpen:function(){return this._popup?this._popup.isOpen():!1},setPopupContent:function(r){return this._popup&&this._popup.setContent(r),this},getPopup:function(){return this._popup},_openPopup:function(r){var o=r.layer||r.target;if(this._popup&&this._map){if(rn(r),o instanceof kn){this.openPopup(r.layer||r.target,r.latlng);return}this._map.hasLayer(this._popup)&&this._popup._source===o?this.closePopup():this.openPopup(o,r.latlng)}},_movePopup:function(r){this._popup.setLatLng(r.latlng)},_onKeyPress:function(r){r.originalEvent.keyCode===13&&this._openPopup(r)}});var Br=ln.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,interactive:!1,opacity:.9},onAdd:function(r){ln.prototype.onAdd.call(this,r),this.setOpacity(this.options.opacity),r.fire("tooltipopen",{tooltip:this}),this._source&&this._source.fire("tooltipopen",{tooltip:this},!0)},onRemove:function(r){ln.prototype.onRemove.call(this,r),r.fire("tooltipclose",{tooltip:this}),this._source&&this._source.fire("tooltipclose",{tooltip:this},!0)},getEvents:function(){var r=ln.prototype.getEvents.call(this);return Zt&&!this.options.permanent&&(r.preclick=this._close),r},_close:function(){this._map&&this._map.closeTooltip(this)},_initLayout:function(){var r="leaflet-tooltip",o=r+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=ie("div",o)},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(r){var o,l,c=this._map,h=this._container,_=c.latLngToContainerPoint(c.getCenter()),E=c.layerPointToContainerPoint(r),k=this.options.direction,O=h.offsetWidth,A=h.offsetHeight,B=D(this.options.offset),H=this._getAnchor();k==="top"?(o=O/2,l=A):k==="bottom"?(o=O/2,l=0):k==="center"?(o=O/2,l=A/2):k==="right"?(o=0,l=A/2):k==="left"?(o=O,l=A/2):E.x<_.x?(k="right",o=0,l=A/2):(k="left",o=O+(B.x+H.x)*2,l=A/2),r=r.subtract(D(o,l,!0)).add(B).add(H),Se(h,"leaflet-tooltip-right"),Se(h,"leaflet-tooltip-left"),Se(h,"leaflet-tooltip-top"),Se(h,"leaflet-tooltip-bottom"),G(h,"leaflet-tooltip-"+k),Oe(h,r)},_updatePosition:function(){var r=this._map.latLngToLayerPoint(this._latlng);this._setPosition(r)},setOpacity:function(r){this.options.opacity=r,this._container&&vt(this._container,r)},_animateZoom:function(r){var o=this._map._latLngToNewLayerPoint(this._latlng,r.zoom,r.center);this._setPosition(o)},_getAnchor:function(){return D(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),Xy=function(r,o){return new Br(r,o)};te.include({openTooltip:function(r,o,l){return r instanceof Br||(r=new Br(l).setContent(r)),o&&r.setLatLng(o),this.hasLayer(r)?this:this.addLayer(r)},closeTooltip:function(r){return r&&this.removeLayer(r),this}}),Rt.include({bindTooltip:function(r,o){return r instanceof Br?(P(r,o),this._tooltip=r,r._source=this):((!this._tooltip||o)&&(this._tooltip=new Br(o,this)),this._tooltip.setContent(r)),this._initTooltipInteractions(),this._tooltip.options.permanent&&this._map&&this._map.hasLayer(this)&&this.openTooltip(),this},unbindTooltip:function(){return this._tooltip&&(this._initTooltipInteractions(!0),this.closeTooltip(),this._tooltip=null),this},_initTooltipInteractions:function(r){if(!(!r&&this._tooltipHandlersAdded)){var o=r?"off":"on",l={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?l.add=this._openTooltip:(l.mouseover=this._openTooltip,l.mouseout=this.closeTooltip,this._tooltip.options.sticky&&(l.mousemove=this._moveTooltip),Zt&&(l.click=this._openTooltip)),this[o](l),this._tooltipHandlersAdded=!r}},openTooltip:function(r,o){return this._tooltip&&this._map&&(o=this._tooltip._prepareOpen(this,r,o),this._map.openTooltip(this._tooltip,o),this._tooltip.options.interactive&&this._tooltip._container&&(G(this._tooltip._container,"leaflet-clickable"),this.addInteractiveTarget(this._tooltip._container))),this},closeTooltip:function(){return this._tooltip&&(this._tooltip._close(),this._tooltip.options.interactive&&this._tooltip._container&&(Se(this._tooltip._container,"leaflet-clickable"),this.removeInteractiveTarget(this._tooltip._container))),this},toggleTooltip:function(r){return this._tooltip&&(this._tooltip._map?this.closeTooltip():this.openTooltip(r)),this},isTooltipOpen:function(){return this._tooltip.isOpen()},setTooltipContent:function(r){return this._tooltip&&this._tooltip.setContent(r),this},getTooltip:function(){return this._tooltip},_openTooltip:function(r){var o=r.layer||r.target;!this._tooltip||!this._map||this.openTooltip(o,this._tooltip.options.sticky?r.latlng:void 0)},_moveTooltip:function(r){var o=r.latlng,l,c;this._tooltip.options.sticky&&r.originalEvent&&(l=this._map.mouseEventToContainerPoint(r.originalEvent),c=this._map.containerPointToLayerPoint(l),o=this._map.layerPointToLatLng(c)),this._tooltip.setLatLng(o)}});var gh=jr.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(r){var o=r&&r.tagName==="DIV"?r:document.createElement("div"),l=this.options;if(l.html instanceof Element?(is(o),o.appendChild(l.html)):o.innerHTML=l.html!==!1?l.html:"",l.bgPos){var c=D(l.bgPos);o.style.backgroundPosition=-c.x+"px "+-c.y+"px"}return this._setIconStyles(o,"icon"),o},createShadow:function(){return null}});function e0(r){return new gh(r)}jr.Default=Hi;var Wi=Rt.extend({options:{tileSize:256,opacity:1,updateWhenIdle:kr,updateWhenZooming:!0,updateInterval:200,zIndex:1,bounds:null,minZoom:0,maxZoom:void 0,maxNativeZoom:void 0,minNativeZoom:void 0,noWrap:!1,pane:"tilePane",className:"",keepBuffer:2},initialize:function(r){P(this,r)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView(),this._update()},beforeAdd:function(r){r._addZoomLimit(this)},onRemove:function(r){this._removeAllTiles(),ge(this._container),r._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(Mr(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(Rr(this._container),this._setAutoZIndex(Math.min)),this},getContainer:function(){return this._container},setOpacity:function(r){return this.options.opacity=r,this._updateOpacity(),this},setZIndex:function(r){return this.options.zIndex=r,this._updateZIndex(),this},isLoading:function(){return this._loading},redraw:function(){return this._map&&(this._removeAllTiles(),this._update()),this},getEvents:function(){var r={viewprereset:this._invalidateAll,viewreset:this._resetView,zoom:this._resetView,moveend:this._onMoveEnd};return this.options.updateWhenIdle||(this._onMove||(this._onMove=p(this._onMoveEnd,this.options.updateInterval,this)),r.move=this._onMove),this._zoomAnimated&&(r.zoomanim=this._animateZoom),r},createTile:function(){return document.createElement("div")},getTileSize:function(){var r=this.options.tileSize;return r instanceof z?r:new z(r,r)},_updateZIndex:function(){this._container&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(r){for(var o=this.getPane().children,l=-r(-1/0,1/0),c=0,h=o.length,_;cthis.options.maxZoom||lc?this._retainParent(h,_,E,c):!1)},_retainChildren:function(r,o,l,c){for(var h=2*r;h<2*r+2;h++)for(var _=2*o;_<2*o+2;_++){var E=new z(h,_);E.z=l+1;var k=this._tileCoordsToKey(E),O=this._tiles[k];if(O&&O.active){O.retain=!0;continue}else O&&O.loaded&&(O.retain=!0);l+1this.options.maxZoom||this.options.minZoom!==void 0&&h1){this._setView(r,l);return}for(var H=h.min.y;H<=h.max.y;H++)for(var oe=h.min.x;oe<=h.max.x;oe++){var un=new z(oe,H);if(un.z=this._tileZoom,!!this._isValidTile(un)){var ur=this._tiles[this._tileCoordsToKey(un)];ur?ur.current=!0:E.push(un)}}if(E.sort(function(Ln,mu){return Ln.distanceTo(_)-mu.distanceTo(_)}),E.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var ys=document.createDocumentFragment();for(oe=0;oel.max.x)||!o.wrapLat&&(r.yl.max.y))return!1}if(!this.options.bounds)return!0;var c=this._tileCoordsToBounds(r);return de(this.options.bounds).overlaps(c)},_keyToBounds:function(r){return this._tileCoordsToBounds(this._keyToTileCoords(r))},_tileCoordsToNwSe:function(r){var o=this._map,l=this.getTileSize(),c=r.scaleBy(l),h=c.add(l),_=o.unproject(c,r.z),E=o.unproject(h,r.z);return[_,E]},_tileCoordsToBounds:function(r){var o=this._tileCoordsToNwSe(r),l=new ze(o[0],o[1]);return this.options.noWrap||(l=this._map.wrapLatLngBounds(l)),l},_tileCoordsToKey:function(r){return r.x+":"+r.y+":"+r.z},_keyToTileCoords:function(r){var o=r.split(":"),l=new z(+o[0],+o[1]);return l.z=+o[2],l},_removeTile:function(r){var o=this._tiles[r];o&&(ge(o.el),delete this._tiles[r],this.fire("tileunload",{tile:o.el,coords:this._keyToTileCoords(r)}))},_initTile:function(r){G(r,"leaflet-tile");var o=this.getTileSize();r.style.width=o.x+"px",r.style.height=o.y+"px",r.onselectstart=g,r.onmousemove=g,Cr&&this.options.opacity<1&&vt(r,this.options.opacity),Ai&&!ji&&(r.style.WebkitBackfaceVisibility="hidden")},_addTile:function(r,o){var l=this._getTilePos(r),c=this._tileCoordsToKey(r),h=this.createTile(this._wrapCoords(r),u(this._tileReady,this,r));this._initTile(h),this.createTile.length<2&&X(u(this._tileReady,this,r,null,h)),Oe(h,l),this._tiles[c]={el:h,coords:r,current:!0},o.appendChild(h),this.fire("tileloadstart",{tile:h,coords:r})},_tileReady:function(r,o,l){o&&this.fire("tileerror",{error:o,tile:l,coords:r});var c=this._tileCoordsToKey(r);l=this._tiles[c],l&&(l.loaded=+new Date,this._map._fadeAnimated?(vt(l.el,0),Le(this._fadeFrame),this._fadeFrame=X(this._updateOpacity,this)):(l.active=!0,this._pruneTiles()),o||(G(l.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:l.el,coords:r})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),Cr||!this._map._fadeAnimated?X(this._pruneTiles,this):setTimeout(u(this._pruneTiles,this),250)))},_getTilePos:function(r){return r.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(r){var o=new z(this._wrapX?m(r.x,this._wrapX):r.x,this._wrapY?m(r.y,this._wrapY):r.y);return o.z=r.z,o},_pxBoundsToTileRange:function(r){var o=this.getTileSize();return new K(r.min.unscaleBy(o).floor(),r.max.unscaleBy(o).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var r in this._tiles)if(!this._tiles[r].loaded)return!1;return!0}});function t0(r){return new Wi(r)}var Fr=Wi.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1},initialize:function(r,o){this._url=r,o=P(this,o),o.detectRetina&&Tn&&o.maxZoom>0&&(o.tileSize=Math.floor(o.tileSize/2),o.zoomReverse?(o.zoomOffset--,o.minZoom++):(o.zoomOffset++,o.maxZoom--),o.minZoom=Math.max(0,o.minZoom)),typeof o.subdomains=="string"&&(o.subdomains=o.subdomains.split("")),Ai||this.on("tileunload",this._onTileRemove)},setUrl:function(r,o){return this._url===r&&o===void 0&&(o=!0),this._url=r,o||this.redraw(),this},createTile:function(r,o){var l=document.createElement("img");return Q(l,"load",u(this._tileOnLoad,this,o,l)),Q(l,"error",u(this._tileOnError,this,o,l)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(l.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),l.alt="",l.setAttribute("role","presentation"),l.src=this.getTileUrl(r),l},getTileUrl:function(r){var o={r:Tn?"@2x":"",s:this._getSubdomain(r),x:r.x,y:r.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var l=this._globalTileRange.max.y-r.y;this.options.tms&&(o.y=l),o["-y"]=l}return w(this._url,s(o,this.options))},_tileOnLoad:function(r,o){Cr?setTimeout(u(r,this,null,o),0):r(null,o)},_tileOnError:function(r,o,l){var c=this.options.errorTileUrl;c&&o.getAttribute("src")!==c&&(o.src=c),r(l,o)},_onTileRemove:function(r){r.tile.onload=null},_getZoomForUrl:function(){var r=this._tileZoom,o=this.options.maxZoom,l=this.options.zoomReverse,c=this.options.zoomOffset;return l&&(r=o-r),r+c},_getSubdomain:function(r){var o=Math.abs(r.x+r.y)%this.options.subdomains.length;return this.options.subdomains[o]},_abortLoading:function(){var r,o;for(r in this._tiles)this._tiles[r].coords.z!==this._tileZoom&&(o=this._tiles[r].el,o.onload=g,o.onerror=g,o.complete||(o.src=I,ge(o),delete this._tiles[r]))},_removeTile:function(r){var o=this._tiles[r];if(o)return Fd||o.el.setAttribute("src",I),Wi.prototype._removeTile.call(this,r)},_tileReady:function(r,o,l){if(!(!this._map||l&&l.getAttribute("src")===I))return Wi.prototype._tileReady.call(this,r,o,l)}});function yh(r,o){return new Fr(r,o)}var wh=Fr.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(r,o){this._url=r;var l=s({},this.defaultWmsParams);for(var c in o)c in this.options||(l[c]=o[c]);o=P(this,o);var h=o.detectRetina&&Tn?2:1,_=this.getTileSize();l.width=_.x*h,l.height=_.y*h,this.wmsParams=l},onAdd:function(r){this._crs=this.options.crs||r.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var o=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[o]=this._crs.code,Fr.prototype.onAdd.call(this,r)},getTileUrl:function(r){var o=this._tileCoordsToNwSe(r),l=this._crs,c=ae(l.project(o[0]),l.project(o[1])),h=c.min,_=c.max,E=(this._wmsVersion>=1.3&&this._crs===dh?[h.y,h.x,_.y,_.x]:[h.x,h.y,_.x,_.y]).join(","),k=Fr.prototype.getTileUrl.call(this,r);return k+R(this.wmsParams,k,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+E},setParams:function(r,o){return s(this.wmsParams,r),o||this.redraw(),this}});function n0(r,o){return new wh(r,o)}Fr.WMS=wh,yh.wms=n0;var Vt=Rt.extend({options:{padding:.1,tolerance:0},initialize:function(r){P(this,r),d(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),this._zoomAnimated&&G(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 r={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(r.zoomanim=this._onAnimZoom),r},_onAnimZoom:function(r){this._updateTransform(r.center,r.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(r,o){var l=this._map.getZoomScale(o,this._zoom),c=Cn(this._container),h=this._map.getSize().multiplyBy(.5+this.options.padding),_=this._map.project(this._center,o),E=this._map.project(r,o),k=E.subtract(_),O=h.multiplyBy(-l).add(c).add(h).subtract(k);_t?or(this._container,O,l):Oe(this._container,O)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var r in this._layers)this._layers[r]._reset()},_onZoomEnd:function(){for(var r in this._layers)this._layers[r]._project()},_updatePaths:function(){for(var r in this._layers)this._layers[r]._update()},_update:function(){var r=this.options.padding,o=this._map.getSize(),l=this._map.containerPointToLayerPoint(o.multiplyBy(-r)).round();this._bounds=new K(l,l.add(o.multiplyBy(1+r*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),xh=Vt.extend({getEvents:function(){var r=Vt.prototype.getEvents.call(this);return r.viewprereset=this._onViewPreReset,r},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Vt.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var r=this._container=document.createElement("canvas");Q(r,"mousemove",this._onMouseMove,this),Q(r,"click dblclick mousedown mouseup contextmenu",this._onClick,this),Q(r,"mouseout",this._handleMouseOut,this),this._ctx=r.getContext("2d")},_destroyContainer:function(){Le(this._redrawRequest),delete this._ctx,ge(this._container),Ee(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var r;this._redrawBounds=null;for(var o in this._layers)r=this._layers[o],r._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Vt.prototype._update.call(this);var r=this._bounds,o=this._container,l=r.getSize(),c=Tn?2:1;Oe(o,r.min),o.width=c*l.x,o.height=c*l.y,o.style.width=l.x+"px",o.style.height=l.y+"px",Tn&&this._ctx.scale(2,2),this._ctx.translate(-r.min.x,-r.min.y),this.fire("update")}},_reset:function(){Vt.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(r){this._updateDashArray(r),this._layers[d(r)]=r;var o=r._order={layer:r,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=o),this._drawLast=o,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(r){this._requestRedraw(r)},_removePath:function(r){var o=r._order,l=o.next,c=o.prev;l?l.prev=c:this._drawLast=c,c?c.next=l:this._drawFirst=l,delete r._order,delete this._layers[d(r)],this._requestRedraw(r)},_updatePath:function(r){this._extendRedrawBounds(r),r._project(),r._update(),this._requestRedraw(r)},_updateStyle:function(r){this._updateDashArray(r),this._requestRedraw(r)},_updateDashArray:function(r){if(typeof r.options.dashArray=="string"){var o=r.options.dashArray.split(/[, ]+/),l=[],c,h;for(h=0;h')}}catch{return function(o){return document.createElement("<"+o+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}}(),r0={_initContainer:function(){this._container=ie("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Vt.prototype._update.call(this),this.fire("update"))},_initPath:function(r){var o=r._container=Vi("shape");G(o,"leaflet-vml-shape "+(this.options.className||"")),o.coordsize="1 1",r._path=Vi("path"),o.appendChild(r._path),this._updateStyle(r),this._layers[d(r)]=r},_addPath:function(r){var o=r._container;this._container.appendChild(o),r.options.interactive&&r.addInteractiveTarget(o)},_removePath:function(r){var o=r._container;ge(o),r.removeInteractiveTarget(o),delete this._layers[d(r)]},_updateStyle:function(r){var o=r._stroke,l=r._fill,c=r.options,h=r._container;h.stroked=!!c.stroke,h.filled=!!c.fill,c.stroke?(o||(o=r._stroke=Vi("stroke")),h.appendChild(o),o.weight=c.weight+"px",o.color=c.color,o.opacity=c.opacity,c.dashArray?o.dashStyle=T(c.dashArray)?c.dashArray.join(" "):c.dashArray.replace(/( *, *)/g," "):o.dashStyle="",o.endcap=c.lineCap.replace("butt","flat"),o.joinstyle=c.lineJoin):o&&(h.removeChild(o),r._stroke=null),c.fill?(l||(l=r._fill=Vi("fill")),h.appendChild(l),l.color=c.fillColor||c.color,l.opacity=c.fillOpacity):l&&(h.removeChild(l),r._fill=null)},_updateCircle:function(r){var o=r._point.round(),l=Math.round(r._radius),c=Math.round(r._radiusY||l);this._setPath(r,r._empty()?"M0 0":"AL "+o.x+","+o.y+" "+l+","+c+" 0,"+65535*360)},_setPath:function(r,o){r._path.v=o},_bringToFront:function(r){Mr(r._container)},_bringToBack:function(r){Rr(r._container)}},gs=ts?Vi:Dd,Ki=Vt.extend({getEvents:function(){var r=Vt.prototype.getEvents.call(this);return r.zoomstart=this._onZoomStart,r},_initContainer:function(){this._container=gs("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=gs("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){ge(this._container),Ee(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_onZoomStart:function(){this._update()},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Vt.prototype._update.call(this);var r=this._bounds,o=r.getSize(),l=this._container;(!this._svgSize||!this._svgSize.equals(o))&&(this._svgSize=o,l.setAttribute("width",o.x),l.setAttribute("height",o.y)),Oe(l,r.min),l.setAttribute("viewBox",[r.min.x,r.min.y,o.x,o.y].join(" ")),this.fire("update")}},_initPath:function(r){var o=r._path=gs("path");r.options.className&&G(o,r.options.className),r.options.interactive&&G(o,"leaflet-interactive"),this._updateStyle(r),this._layers[d(r)]=r},_addPath:function(r){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(r._path),r.addInteractiveTarget(r._path)},_removePath:function(r){ge(r._path),r.removeInteractiveTarget(r._path),delete this._layers[d(r)]},_updatePath:function(r){r._project(),r._update()},_updateStyle:function(r){var o=r._path,l=r.options;o&&(l.stroke?(o.setAttribute("stroke",l.color),o.setAttribute("stroke-opacity",l.opacity),o.setAttribute("stroke-width",l.weight),o.setAttribute("stroke-linecap",l.lineCap),o.setAttribute("stroke-linejoin",l.lineJoin),l.dashArray?o.setAttribute("stroke-dasharray",l.dashArray):o.removeAttribute("stroke-dasharray"),l.dashOffset?o.setAttribute("stroke-dashoffset",l.dashOffset):o.removeAttribute("stroke-dashoffset")):o.setAttribute("stroke","none"),l.fill?(o.setAttribute("fill",l.fillColor||l.color),o.setAttribute("fill-opacity",l.fillOpacity),o.setAttribute("fill-rule",l.fillRule||"evenodd")):o.setAttribute("fill","none"))},_updatePoly:function(r,o){this._setPath(r,Bd(r._parts,o))},_updateCircle:function(r){var o=r._point,l=Math.max(Math.round(r._radius),1),c=Math.max(Math.round(r._radiusY),1)||l,h="a"+l+","+c+" 0 1,0 ",_=r._empty()?"M0 0":"M"+(o.x-l)+","+o.y+h+l*2+",0 "+h+-l*2+",0 ";this._setPath(r,_)},_setPath:function(r,o){r._path.setAttribute("d",o)},_bringToFront:function(r){Mr(r._path)},_bringToBack:function(r){Rr(r._path)}});ts&&Ki.include(r0);function Ph(r){return es||ts?new Ki(r):null}te.include({getRenderer:function(r){var o=r.options.renderer||this._getPaneRenderer(r.options.pane)||this.options.renderer||this._renderer;return o||(o=this._renderer=this._createRenderer()),this.hasLayer(o)||this.addLayer(o),o},_getPaneRenderer:function(r){if(r==="overlayPane"||r===void 0)return!1;var o=this._paneRenderers[r];return o===void 0&&(o=this._createRenderer({pane:r}),this._paneRenderers[r]=o),o},_createRenderer:function(r){return this.options.preferCanvas&&Sh(r)||Ph(r)}});var Eh=br.extend({initialize:function(r,o){br.prototype.initialize.call(this,this._boundsToLatLngs(r),o)},setBounds:function(r){return this.setLatLngs(this._boundsToLatLngs(r))},_boundsToLatLngs:function(r){return r=de(r),[r.getSouthWest(),r.getNorthWest(),r.getNorthEast(),r.getSouthEast()]}});function i0(r,o){return new Eh(r,o)}Ki.create=gs,Ki.pointsToPath=Bd,an.geometryToLayer=fu,an.coordsToLatLng=du,an.coordsToLatLngs=ps,an.latLngToCoords=hu,an.latLngsToCoords=ms,an.getFeature=Ir,an.asFeature=_s,te.mergeOptions({boxZoom:!0});var Th=Wt.extend({initialize:function(r){this._map=r,this._container=r._container,this._pane=r._panes.overlayPane,this._resetStateTimeout=0,r.on("unload",this._destroy,this)},addHooks:function(){Q(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){Ee(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){ge(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(r){if(!r.shiftKey||r.which!==1&&r.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),Di(),Kl(),this._startPoint=this._map.mouseEventToContainerPoint(r),Q(document,{contextmenu:rn,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(r){this._moved||(this._moved=!0,this._box=ie("div","leaflet-zoom-box",this._container),G(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(r);var o=new K(this._point,this._startPoint),l=o.getSize();Oe(this._box,o.min),this._box.style.width=l.x+"px",this._box.style.height=l.y+"px"},_finish:function(){this._moved&&(ge(this._box),Se(this._container,"leaflet-crosshair")),Bi(),ql(),Ee(document,{contextmenu:rn,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(r){if(!(r.which!==1&&r.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(u(this._resetState,this),0);var o=new ze(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(o).fire("boxzoomend",{boxZoomBounds:o})}},_onKeyDown:function(r){r.keyCode===27&&this._finish()}});te.addInitHook("addHandler","boxZoom",Th),te.mergeOptions({doubleClickZoom:!0});var Ch=Wt.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(r){var o=this._map,l=o.getZoom(),c=o.options.zoomDelta,h=r.originalEvent.shiftKey?l-c:l+c;o.options.doubleClickZoom==="center"?o.setZoom(h):o.setZoomAround(r.containerPoint,h)}});te.addInitHook("addHandler","doubleClickZoom",Ch),te.mergeOptions({dragging:!0,inertia:!ji,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var kh=Wt.extend({addHooks:function(){if(!this._draggable){var r=this._map;this._draggable=new ar(r._mapPane,r._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),r.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),r.on("zoomend",this._onZoomEnd,this),r.whenReady(this._onZoomEnd,this))}G(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){Se(this._map._container,"leaflet-grab"),Se(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 r=this._map;if(r._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var o=de(this._map.options.maxBounds);this._offsetLimit=ae(this._map.latLngToContainerPoint(o.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(o.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;r.fire("movestart").fire("dragstart"),r.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(r){if(this._map.options.inertia){var o=this._lastTime=+new Date,l=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(l),this._times.push(o),this._prunePositions(o)}this._map.fire("move",r).fire("drag",r)},_prunePositions:function(r){for(;this._positions.length>1&&r-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var r=this._map.getSize().divideBy(2),o=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=o.subtract(r).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(r,o){return r-(r-o)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var r=this._draggable._newPos.subtract(this._draggable._startPos),o=this._offsetLimit;r.xo.max.x&&(r.x=this._viscousLimit(r.x,o.max.x)),r.y>o.max.y&&(r.y=this._viscousLimit(r.y,o.max.y)),this._draggable._newPos=this._draggable._startPos.add(r)}},_onPreDragWrap:function(){var r=this._worldWidth,o=Math.round(r/2),l=this._initialWorldOffset,c=this._draggable._newPos.x,h=(c-o+l)%r+o-l,_=(c+o+l)%r-o-l,E=Math.abs(h+l)0?_:-_))-o;this._delta=0,this._startTime=null,E&&(r.options.scrollWheelZoom==="center"?r.setZoom(o+E):r.setZoomAround(this._lastMousePos,o+E))}});te.addInitHook("addHandler","scrollWheelZoom",Oh),te.mergeOptions({tap:!0,tapTolerance:15});var Nh=Wt.extend({addHooks:function(){Q(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){Ee(this._map._container,"touchstart",this._onDown,this)},_onDown:function(r){if(r.touches){if(gt(r),this._fireClick=!0,r.touches.length>1){this._fireClick=!1,clearTimeout(this._holdTimeout);return}var o=r.touches[0],l=o.target;this._startPos=this._newPos=new z(o.clientX,o.clientY),l.tagName&&l.tagName.toLowerCase()==="a"&&G(l,"leaflet-active"),this._holdTimeout=setTimeout(u(function(){this._isTapValid()&&(this._fireClick=!1,this._onUp(),this._simulateEvent("contextmenu",o))},this),1e3),this._simulateEvent("mousedown",o),Q(document,{touchmove:this._onMove,touchend:this._onUp},this)}},_onUp:function(r){if(clearTimeout(this._holdTimeout),Ee(document,{touchmove:this._onMove,touchend:this._onUp},this),this._fireClick&&r&&r.changedTouches){var o=r.changedTouches[0],l=o.target;l&&l.tagName&&l.tagName.toLowerCase()==="a"&&Se(l,"leaflet-active"),this._simulateEvent("mouseup",o),this._isTapValid()&&this._simulateEvent("click",o)}},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_onMove:function(r){var o=r.touches[0];this._newPos=new z(o.clientX,o.clientY),this._simulateEvent("mousemove",o)},_simulateEvent:function(r,o){var l=document.createEvent("MouseEvents");l._simulated=!0,o.target._simulatedClick=!0,l.initMouseEvent(r,!0,!0,window,1,o.screenX,o.screenY,o.clientX,o.clientY,!1,!1,!1,!1,0,null),o.target.dispatchEvent(l)}});Zt&&(!Ut||Xo)&&te.addInitHook("addHandler","tap",Nh),te.mergeOptions({touchZoom:Zt&&!ji,bounceAtZoomLimits:!0});var Mh=Wt.extend({addHooks:function(){G(this._map._container,"leaflet-touch-zoom"),Q(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){Se(this._map._container,"leaflet-touch-zoom"),Ee(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(r){var o=this._map;if(!(!r.touches||r.touches.length!==2||o._animatingZoom||this._zooming)){var l=o.mouseEventToContainerPoint(r.touches[0]),c=o.mouseEventToContainerPoint(r.touches[1]);this._centerPoint=o.getSize()._divideBy(2),this._startLatLng=o.containerPointToLatLng(this._centerPoint),o.options.touchZoom!=="center"&&(this._pinchStartLatLng=o.containerPointToLatLng(l.add(c)._divideBy(2))),this._startDist=l.distanceTo(c),this._startZoom=o.getZoom(),this._moved=!1,this._zooming=!0,o._stop(),Q(document,"touchmove",this._onTouchMove,this),Q(document,"touchend",this._onTouchEnd,this),gt(r)}},_onTouchMove:function(r){if(!(!r.touches||r.touches.length!==2||!this._zooming)){var o=this._map,l=o.mouseEventToContainerPoint(r.touches[0]),c=o.mouseEventToContainerPoint(r.touches[1]),h=l.distanceTo(c)/this._startDist;if(this._zoom=o.getScaleZoom(h,this._startZoom),!o.options.bounceAtZoomLimits&&(this._zoomo.getMaxZoom()&&h>1)&&(this._zoom=o._limitZoom(this._zoom)),o.options.touchZoom==="center"){if(this._center=this._startLatLng,h===1)return}else{var _=l._add(c)._divideBy(2)._subtract(this._centerPoint);if(h===1&&_.x===0&&_.y===0)return;this._center=o.unproject(o.project(this._pinchStartLatLng,this._zoom).subtract(_),this._zoom)}this._moved||(o._moveStart(!0,!1),this._moved=!0),Le(this._animRequest);var E=u(o._move,o,this._center,this._zoom,{pinch:!0,round:!1});this._animRequest=X(E,this,!0),gt(r)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,Le(this._animRequest),Ee(document,"touchmove",this._onTouchMove,this),Ee(document,"touchend",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))}});te.addInitHook("addHandler","touchZoom",Mh),te.BoxZoom=Th,te.DoubleClickZoom=Ch,te.Drag=kh,te.Keyboard=Lh,te.ScrollWheelZoom=Oh,te.Tap=Nh,te.TouchZoom=Mh,n.version=i,n.Control=Mt,n.control=Ui,n.Browser=fy,n.Evented=nn,n.Mixin=Ny,n.Util=ir,n.Class=mt,n.Handler=Wt,n.extend=s,n.bind=u,n.stamp=d,n.setOptions=P,n.DomEvent=Ey,n.DomUtil=Sy,n.PosAnimation=th,n.Draggable=ar,n.LineUtil=jy,n.PolyUtil=by,n.Point=z,n.point=D,n.Bounds=K,n.bounds=ae,n.Transformation=Ol,n.transformation=zi,n.Projection=Iy,n.LatLng=se,n.latLng=le,n.LatLngBounds=ze,n.latLngBounds=de,n.CRS=Xe,n.GeoJSON=an,n.geoJSON=mh,n.geoJson=qy,n.Layer=Rt,n.LayerGroup=zr,n.layerGroup=Fy,n.FeatureGroup=Ar,n.featureGroup=$y,n.ImageOverlay=vs,n.imageOverlay=Gy,n.VideoOverlay=_h,n.videoOverlay=Qy,n.SVGOverlay=vh,n.svgOverlay=Yy,n.DivOverlay=ln,n.Popup=Dr,n.popup=Jy,n.Tooltip=Br,n.tooltip=Xy,n.Icon=jr,n.icon=Uy,n.DivIcon=gh,n.divIcon=e0,n.Marker=ds,n.marker=Zy,n.TileLayer=Fr,n.tileLayer=yh,n.GridLayer=Wi,n.gridLayer=t0,n.SVG=Ki,n.svg=Ph,n.Renderer=Vt,n.Canvas=xh,n.canvas=Sh,n.Path=kn,n.CircleMarker=hs,n.circleMarker=Hy,n.Circle=cu,n.circle=Wy,n.Polyline=sn,n.polyline=Vy,n.Polygon=br,n.polygon=Ky,n.Rectangle=Eh,n.rectangle=i0,n.Map=te,n.map=Ty;var o0=window.L;n.noConflict=function(){return window.L=o0,this},window.L=n})})(sf,sf.exports);var wi=sf.exports,be=(e=>(e.Main="/",e.Login="/login",e.Favorites="/favorites",e.Offer="/offer/:id",e))(be||{}),$t=(e=>(e[e.Authorized=0]="Authorized",e[e.Unauthorized=1]="Unauthorized",e[e.Unknown=2]="Unknown",e))($t||{});const hS=new wi.Icon({iconUrl:"public/img/pin.svg",iconSize:[40,40],iconAnchor:[20,40]}),pS=new wi.Icon({iconUrl:"public/img/pin-active.svg",iconSize:[40,40],iconAnchor:[20,40]}),im=50,mS=300,ug={name:"Paris",location:{latitude:48.864716,longitude:2.349014,zoom:13}},_S={name:"Cologne",location:{latitude:50.935173,longitude:6.953101,zoom:13}},vS={name:"Brussels",location:{latitude:50.85045,longitude:4.34878,zoom:13}},gS={name:"Amsterdam",location:{latitude:52.37454,longitude:4.897976,zoom:12}},yS={name:"Hamburg",location:{latitude:53.551086,longitude:9.993682,zoom:13}},wS={name:"Dusseldorf",location:{latitude:51.233334,longitude:6.783333,zoom:12}},xS=[ug,_S,vS,gS,yS,wS],SS=["Popular","Price: low to high","Price: high to low","Top rated first"],nr={offers:"/offers",favorite:"/favorite",login:"/login",logout:"/logout",reviews:"/comments"};function PS({offer:e,onMouseLeave:t,onMouseEnter:n}){return v.jsxs("article",{className:"cities__card place-card",onMouseEnter:n,onMouseLeave:t,children:[e.isPremium&&v.jsx("div",{className:"place-card__mark",children:v.jsx("span",{children:"Premium"})}),v.jsx("div",{className:"cities__image-wrapper place-card__image-wrapper",children:v.jsx(lt,{to:be.Offer.replace(":id",e.id),children:v.jsx("img",{className:"place-card__image",src:e.previewImage,width:"260",height:"200",alt:"Place image"})})}),v.jsxs("div",{className:"place-card__info",children:[v.jsxs("div",{className:"place-card__price-wrapper",children:[v.jsxs("div",{className:"place-card__price",children:[v.jsxs("b",{className:"place-card__price-value",children:["€",e.price," "]}),v.jsx("span",{className:"place-card__price-text",children:"/ night"})]}),v.jsxs("button",{className:`place-card__bookmark-button ${e.isFavorite?"place-card__bookmark-button--active":""} button`,type:"button",children:[v.jsx("svg",{className:"place-card__bookmark-icon",width:"18",height:"19",children:v.jsx("use",{xlinkHref:"#icon-bookmark"})}),v.jsx("span",{className:"visually-hidden",children:e.isFavorite?"In bookmarks":"To bookmarks"})]})]}),v.jsx("div",{className:"place-card__rating rating",children:v.jsxs("div",{className:"place-card__stars rating__stars",children:[v.jsx("span",{style:{width:e.rating}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]})}),v.jsx("h2",{className:"place-card__name",children:v.jsx(lt,{to:be.Offer.replace(":id",e.id),children:e.title})}),v.jsx("p",{className:"place-card__type",children:e.type})]})]})}function cg({offers:e,onChange:t}){const[n,i]=j.useState(null);j.useEffect(()=>{t(n)},[n,t]);const s=u=>{i(u)},a=()=>{i(null)};return v.jsx("div",{className:"cities__places-list places__list tabs__content",children:e.map(u=>v.jsx(PS,{offer:u,onMouseEnter:()=>s(u.id),onMouseLeave:a},u.id))})}function ES(e,t){const[n,i]=j.useState(null),s=j.useRef(!1);return j.useEffect(()=>{if(e.current&&!s.current){const a=new wi.Map(e.current,{center:[t.location.latitude,t.location.longitude],zoom:t.location.zoom}),u=new wi.TileLayer("https://{s}.basemaps.cartocdn.com/rastertiles/voyager/{z}/{x}/{y}{r}.png",{attribution:'© OpenStreetMap contributors © CARTO'});a.addLayer(u),i(a),s.current=!0}},[e,t]),j.useEffect(()=>{n&&n.setView([t.location.latitude,t.location.longitude],t.location.zoom)},[n,t]),n}function fg({city:e,offers:t,selectedOffer:n}){const i=j.useRef(null),s=ES(i,e);return j.useEffect(()=>{if(s){const a=wi.layerGroup().addTo(s);return t.forEach(u=>{new wi.Marker([u.location.latitude,u.location.longitude]).setIcon(n&&u.id===n.id?pS:hS).addTo(a)}),()=>{a.clearLayers(),s.removeLayer(a)}}},[s,t,n]),v.jsx("div",{className:"cities__map map",style:{height:"500px"},ref:i})}var dg={exports:{}},hg={};/** * @license React * use-sync-external-store-shim.production.min.js * @@ -75,7 +75,7 @@ Error generating stack: `+a.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var xi=j;function ES(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var TS=typeof Object.is=="function"?Object.is:ES,CS=xi.useState,kS=xi.useEffect,LS=xi.useLayoutEffect,OS=xi.useDebugValue;function NS(e,t){var n=t(),i=CS({inst:{value:n,getSnapshot:t}}),s=i[0].inst,a=i[1];return LS(function(){s.value=n,s.getSnapshot=t,qu(s)&&a({inst:s})},[e,n,t]),kS(function(){return qu(s)&&a({inst:s}),e(function(){qu(s)&&a({inst:s})})},[e]),OS(n),n}function qu(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!TS(e,n)}catch{return!0}}function MS(e,t){return t()}var RS=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?MS:NS;dg.useSyncExternalStore=xi.useSyncExternalStore!==void 0?xi.useSyncExternalStore:RS;fg.exports=dg;var zS=fg.exports,hg={exports:{}},pg={};/** + */var xi=j;function TS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var CS=typeof Object.is=="function"?Object.is:TS,kS=xi.useState,LS=xi.useEffect,OS=xi.useLayoutEffect,NS=xi.useDebugValue;function MS(e,t){var n=t(),i=kS({inst:{value:n,getSnapshot:t}}),s=i[0].inst,a=i[1];return OS(function(){s.value=n,s.getSnapshot=t,qu(s)&&a({inst:s})},[e,n,t]),LS(function(){return qu(s)&&a({inst:s}),e(function(){qu(s)&&a({inst:s})})},[e]),NS(n),n}function qu(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!CS(e,n)}catch{return!0}}function RS(e,t){return t()}var zS=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?RS:MS;hg.useSyncExternalStore=xi.useSyncExternalStore!==void 0?xi.useSyncExternalStore:zS;dg.exports=hg;var AS=dg.exports,pg={exports:{}},mg={};/** * @license React * use-sync-external-store-shim/with-selector.production.min.js * @@ -83,14 +83,14 @@ Error generating stack: `+a.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var el=j,AS=zS;function jS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var bS=typeof Object.is=="function"?Object.is:jS,IS=AS.useSyncExternalStore,DS=el.useRef,BS=el.useEffect,FS=el.useMemo,$S=el.useDebugValue;pg.useSyncExternalStoreWithSelector=function(e,t,n,i,s){var a=DS(null);if(a.current===null){var u={hasValue:!1,value:null};a.current=u}else u=a.current;a=FS(function(){function d(C){if(!p){if(p=!0,m=C,C=i(C),s!==void 0&&u.hasValue){var x=u.value;if(s(x,C))return g=x}return g=C}if(x=g,bS(m,C))return x;var P=i(C);return s!==void 0&&s(x,P)?x:(m=C,g=P)}var p=!1,m,g,y=n===void 0?null:n;return[function(){return d(t())},y===null?void 0:function(){return d(y())}]},[t,n,i,s]);var f=IS(e,a[0],a[1]);return BS(function(){u.hasValue=!0,u.value=f},[f]),$S(f),f};hg.exports=pg;var US=hg.exports;function ZS(e){e()}let mg=ZS;const HS=e=>mg=e,WS=()=>mg,im=Symbol.for("react-redux-context"),om=typeof globalThis<"u"?globalThis:{};function VS(){var e;if(!j.createContext)return{};const t=(e=om[im])!=null?e:om[im]=new Map;let n=t.get(j.createContext);return n||(n=j.createContext(null),t.set(j.createContext,n)),n}const Yn=VS();function vd(e=Yn){return function(){return j.useContext(e)}}const _g=vd(),KS=()=>{throw new Error("uSES not initialized!")};let vg=KS;const qS=e=>{vg=e},GS=(e,t)=>e===t;function QS(e=Yn){const t=e===Yn?_g:vd(e);return function(i,s={}){const{equalityFn:a=GS,stabilityCheck:u=void 0,noopCheck:f=void 0}=typeof s=="function"?{equalityFn:s}:s,{store:d,subscription:p,getServerState:m,stabilityCheck:g,noopCheck:y}=t();j.useRef(!0);const C=j.useCallback({[i.name](P){return i(P)}}[i.name],[i,g,u]),x=vg(p.addNestedSub,d.getState,m||d.getState,C,a);return j.useDebugValue(x),x}}const YS=QS();var gg={exports:{}},ce={};/** @license React v16.13.1 + */var el=j,jS=AS;function bS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var IS=typeof Object.is=="function"?Object.is:bS,DS=jS.useSyncExternalStore,BS=el.useRef,FS=el.useEffect,$S=el.useMemo,US=el.useDebugValue;mg.useSyncExternalStoreWithSelector=function(e,t,n,i,s){var a=BS(null);if(a.current===null){var u={hasValue:!1,value:null};a.current=u}else u=a.current;a=$S(function(){function d(C){if(!p){if(p=!0,m=C,C=i(C),s!==void 0&&u.hasValue){var x=u.value;if(s(x,C))return g=x}return g=C}if(x=g,IS(m,C))return x;var P=i(C);return s!==void 0&&s(x,P)?x:(m=C,g=P)}var p=!1,m,g,y=n===void 0?null:n;return[function(){return d(t())},y===null?void 0:function(){return d(y())}]},[t,n,i,s]);var f=DS(e,a[0],a[1]);return FS(function(){u.hasValue=!0,u.value=f},[f]),US(f),f};pg.exports=mg;var ZS=pg.exports;function HS(e){e()}let _g=HS;const WS=e=>_g=e,VS=()=>_g,om=Symbol.for("react-redux-context"),sm=typeof globalThis<"u"?globalThis:{};function KS(){var e;if(!j.createContext)return{};const t=(e=sm[om])!=null?e:sm[om]=new Map;let n=t.get(j.createContext);return n||(n=j.createContext(null),t.set(j.createContext,n)),n}const Yn=KS();function vd(e=Yn){return function(){return j.useContext(e)}}const vg=vd(),qS=()=>{throw new Error("uSES not initialized!")};let gg=qS;const GS=e=>{gg=e},QS=(e,t)=>e===t;function YS(e=Yn){const t=e===Yn?vg:vd(e);return function(i,s={}){const{equalityFn:a=QS,stabilityCheck:u=void 0,noopCheck:f=void 0}=typeof s=="function"?{equalityFn:s}:s,{store:d,subscription:p,getServerState:m,stabilityCheck:g,noopCheck:y}=t();j.useRef(!0);const C=j.useCallback({[i.name](P){return i(P)}}[i.name],[i,g,u]),x=gg(p.addNestedSub,d.getState,m||d.getState,C,a);return j.useDebugValue(x),x}}const JS=YS();var yg={exports:{}},ce={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var Be=typeof Symbol=="function"&&Symbol.for,gd=Be?Symbol.for("react.element"):60103,yd=Be?Symbol.for("react.portal"):60106,tl=Be?Symbol.for("react.fragment"):60107,nl=Be?Symbol.for("react.strict_mode"):60108,rl=Be?Symbol.for("react.profiler"):60114,il=Be?Symbol.for("react.provider"):60109,ol=Be?Symbol.for("react.context"):60110,wd=Be?Symbol.for("react.async_mode"):60111,sl=Be?Symbol.for("react.concurrent_mode"):60111,al=Be?Symbol.for("react.forward_ref"):60112,ll=Be?Symbol.for("react.suspense"):60113,JS=Be?Symbol.for("react.suspense_list"):60120,ul=Be?Symbol.for("react.memo"):60115,cl=Be?Symbol.for("react.lazy"):60116,XS=Be?Symbol.for("react.block"):60121,eP=Be?Symbol.for("react.fundamental"):60117,tP=Be?Symbol.for("react.responder"):60118,nP=Be?Symbol.for("react.scope"):60119;function pt(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case gd:switch(e=e.type,e){case wd:case sl:case tl:case rl:case nl:case ll:return e;default:switch(e=e&&e.$$typeof,e){case ol:case al:case cl:case ul:case il:return e;default:return t}}case yd:return t}}}function yg(e){return pt(e)===sl}ce.AsyncMode=wd;ce.ConcurrentMode=sl;ce.ContextConsumer=ol;ce.ContextProvider=il;ce.Element=gd;ce.ForwardRef=al;ce.Fragment=tl;ce.Lazy=cl;ce.Memo=ul;ce.Portal=yd;ce.Profiler=rl;ce.StrictMode=nl;ce.Suspense=ll;ce.isAsyncMode=function(e){return yg(e)||pt(e)===wd};ce.isConcurrentMode=yg;ce.isContextConsumer=function(e){return pt(e)===ol};ce.isContextProvider=function(e){return pt(e)===il};ce.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===gd};ce.isForwardRef=function(e){return pt(e)===al};ce.isFragment=function(e){return pt(e)===tl};ce.isLazy=function(e){return pt(e)===cl};ce.isMemo=function(e){return pt(e)===ul};ce.isPortal=function(e){return pt(e)===yd};ce.isProfiler=function(e){return pt(e)===rl};ce.isStrictMode=function(e){return pt(e)===nl};ce.isSuspense=function(e){return pt(e)===ll};ce.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===tl||e===sl||e===rl||e===nl||e===ll||e===JS||typeof e=="object"&&e!==null&&(e.$$typeof===cl||e.$$typeof===ul||e.$$typeof===il||e.$$typeof===ol||e.$$typeof===al||e.$$typeof===eP||e.$$typeof===tP||e.$$typeof===nP||e.$$typeof===XS)};ce.typeOf=pt;gg.exports=ce;var rP=gg.exports,wg=rP,iP={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},oP={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},xg={};xg[wg.ForwardRef]=iP;xg[wg.Memo]=oP;var fe={};/** + */var Be=typeof Symbol=="function"&&Symbol.for,gd=Be?Symbol.for("react.element"):60103,yd=Be?Symbol.for("react.portal"):60106,tl=Be?Symbol.for("react.fragment"):60107,nl=Be?Symbol.for("react.strict_mode"):60108,rl=Be?Symbol.for("react.profiler"):60114,il=Be?Symbol.for("react.provider"):60109,ol=Be?Symbol.for("react.context"):60110,wd=Be?Symbol.for("react.async_mode"):60111,sl=Be?Symbol.for("react.concurrent_mode"):60111,al=Be?Symbol.for("react.forward_ref"):60112,ll=Be?Symbol.for("react.suspense"):60113,XS=Be?Symbol.for("react.suspense_list"):60120,ul=Be?Symbol.for("react.memo"):60115,cl=Be?Symbol.for("react.lazy"):60116,eP=Be?Symbol.for("react.block"):60121,tP=Be?Symbol.for("react.fundamental"):60117,nP=Be?Symbol.for("react.responder"):60118,rP=Be?Symbol.for("react.scope"):60119;function pt(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case gd:switch(e=e.type,e){case wd:case sl:case tl:case rl:case nl:case ll:return e;default:switch(e=e&&e.$$typeof,e){case ol:case al:case cl:case ul:case il:return e;default:return t}}case yd:return t}}}function wg(e){return pt(e)===sl}ce.AsyncMode=wd;ce.ConcurrentMode=sl;ce.ContextConsumer=ol;ce.ContextProvider=il;ce.Element=gd;ce.ForwardRef=al;ce.Fragment=tl;ce.Lazy=cl;ce.Memo=ul;ce.Portal=yd;ce.Profiler=rl;ce.StrictMode=nl;ce.Suspense=ll;ce.isAsyncMode=function(e){return wg(e)||pt(e)===wd};ce.isConcurrentMode=wg;ce.isContextConsumer=function(e){return pt(e)===ol};ce.isContextProvider=function(e){return pt(e)===il};ce.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===gd};ce.isForwardRef=function(e){return pt(e)===al};ce.isFragment=function(e){return pt(e)===tl};ce.isLazy=function(e){return pt(e)===cl};ce.isMemo=function(e){return pt(e)===ul};ce.isPortal=function(e){return pt(e)===yd};ce.isProfiler=function(e){return pt(e)===rl};ce.isStrictMode=function(e){return pt(e)===nl};ce.isSuspense=function(e){return pt(e)===ll};ce.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===tl||e===sl||e===rl||e===nl||e===ll||e===XS||typeof e=="object"&&e!==null&&(e.$$typeof===cl||e.$$typeof===ul||e.$$typeof===il||e.$$typeof===ol||e.$$typeof===al||e.$$typeof===tP||e.$$typeof===nP||e.$$typeof===rP||e.$$typeof===eP)};ce.typeOf=pt;yg.exports=ce;var iP=yg.exports,xg=iP,oP={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},sP={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Sg={};Sg[xg.ForwardRef]=oP;Sg[xg.Memo]=sP;var fe={};/** * @license React * react-is.production.min.js * @@ -98,8 +98,8 @@ Error generating stack: `+a.message+` * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var xd=Symbol.for("react.element"),Sd=Symbol.for("react.portal"),fl=Symbol.for("react.fragment"),dl=Symbol.for("react.strict_mode"),hl=Symbol.for("react.profiler"),pl=Symbol.for("react.provider"),ml=Symbol.for("react.context"),sP=Symbol.for("react.server_context"),_l=Symbol.for("react.forward_ref"),vl=Symbol.for("react.suspense"),gl=Symbol.for("react.suspense_list"),yl=Symbol.for("react.memo"),wl=Symbol.for("react.lazy"),aP=Symbol.for("react.offscreen"),Sg;Sg=Symbol.for("react.module.reference");function Ot(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case xd:switch(e=e.type,e){case fl:case hl:case dl:case vl:case gl:return e;default:switch(e=e&&e.$$typeof,e){case sP:case ml:case _l:case wl:case yl:case pl:return e;default:return t}}case Sd:return t}}}fe.ContextConsumer=ml;fe.ContextProvider=pl;fe.Element=xd;fe.ForwardRef=_l;fe.Fragment=fl;fe.Lazy=wl;fe.Memo=yl;fe.Portal=Sd;fe.Profiler=hl;fe.StrictMode=dl;fe.Suspense=vl;fe.SuspenseList=gl;fe.isAsyncMode=function(){return!1};fe.isConcurrentMode=function(){return!1};fe.isContextConsumer=function(e){return Ot(e)===ml};fe.isContextProvider=function(e){return Ot(e)===pl};fe.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===xd};fe.isForwardRef=function(e){return Ot(e)===_l};fe.isFragment=function(e){return Ot(e)===fl};fe.isLazy=function(e){return Ot(e)===wl};fe.isMemo=function(e){return Ot(e)===yl};fe.isPortal=function(e){return Ot(e)===Sd};fe.isProfiler=function(e){return Ot(e)===hl};fe.isStrictMode=function(e){return Ot(e)===dl};fe.isSuspense=function(e){return Ot(e)===vl};fe.isSuspenseList=function(e){return Ot(e)===gl};fe.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===fl||e===hl||e===dl||e===vl||e===gl||e===aP||typeof e=="object"&&e!==null&&(e.$$typeof===wl||e.$$typeof===yl||e.$$typeof===pl||e.$$typeof===ml||e.$$typeof===_l||e.$$typeof===Sg||e.getModuleId!==void 0)};fe.typeOf=Ot;function lP(){const e=WS();let t=null,n=null;return{clear(){t=null,n=null},notify(){e(()=>{let i=t;for(;i;)i.callback(),i=i.next})},get(){let i=[],s=t;for(;s;)i.push(s),s=s.next;return i},subscribe(i){let s=!0,a=n={callback:i,next:null,prev:n};return a.prev?a.prev.next=a:t=a,function(){!s||t===null||(s=!1,a.next?a.next.prev=a.prev:n=a.prev,a.prev?a.prev.next=a.next:t=a.next)}}}}const sm={notify(){},get:()=>[]};function uP(e,t){let n,i=sm,s=0,a=!1;function u(P){m();const R=i.subscribe(P);let S=!1;return()=>{S||(S=!0,R(),g())}}function f(){i.notify()}function d(){x.onStateChange&&x.onStateChange()}function p(){return a}function m(){s++,n||(n=t?t.addNestedSub(d):e.subscribe(d),i=lP())}function g(){s--,n&&s===0&&(n(),n=void 0,i.clear(),i=sm)}function y(){a||(a=!0,m())}function C(){a&&(a=!1,g())}const x={addNestedSub:u,notifyNestedSubs:f,handleChangeWrapper:d,isSubscribed:p,trySubscribe:y,tryUnsubscribe:C,getListeners:()=>i};return x}const cP=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",fP=cP?j.useLayoutEffect:j.useEffect;function dP({store:e,context:t,children:n,serverState:i,stabilityCheck:s="once",noopCheck:a="once"}){const u=j.useMemo(()=>{const p=uP(e);return{store:e,subscription:p,getServerState:i?()=>i:void 0,stabilityCheck:s,noopCheck:a}},[e,i,s,a]),f=j.useMemo(()=>e.getState(),[e]);fP(()=>{const{subscription:p}=u;return p.onStateChange=p.notifyNestedSubs,p.trySubscribe(),f!==e.getState()&&p.notifyNestedSubs(),()=>{p.tryUnsubscribe(),p.onStateChange=void 0}},[u,f]);const d=t||Yn;return j.createElement(d.Provider,{value:u},n)}function Pg(e=Yn){const t=e===Yn?_g:vd(e);return function(){const{store:i}=t();return i}}const hP=Pg();function pP(e=Yn){const t=e===Yn?hP:Pg(e);return function(){return t().dispatch}}const mP=pP();qS(US.useSyncExternalStoreWithSelector);HS(Kv.unstable_batchedUpdates);const _P=()=>mP(),St=YS;function It(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i3?t.i-4:t.i:Array.isArray(e)?1:Pd(e)?2:Ed(e)?3:0}function ci(e,t){return Ni(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function vP(e,t){return Ni(e)===2?e.get(t):e[t]}function Eg(e,t,n){var i=Ni(e);i===2?e.set(t,n):i===3?e.add(n):e[t]=n}function Tg(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function Pd(e){return PP&&e instanceof Map}function Ed(e){return EP&&e instanceof Set}function dr(e){return e.o||e.t}function Td(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=kg(e);delete t[_e];for(var n=fi(t),i=0;i1&&(e.set=e.add=e.clear=e.delete=gP),Object.freeze(e),t&&Pr(e,function(n,i){return Cd(i,!0)},!0)),e}function gP(){It(2)}function kd(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function Xt(e){var t=cf[e];return t||It(18,e),t}function yP(e,t){cf[e]||(cf[e]=t)}function af(){return Io}function Gu(e,t){t&&(Xt("Patches"),e.u=[],e.s=[],e.v=t)}function Ma(e){lf(e),e.p.forEach(wP),e.p=null}function lf(e){e===Io&&(Io=e.l)}function am(e){return Io={p:[],l:Io,h:e,m:!0,_:0}}function wP(e){var t=e[_e];t.i===0||t.i===1?t.j():t.g=!0}function Qu(e,t){t._=t.p.length;var n=t.p[0],i=e!==void 0&&e!==n;return t.h.O||Xt("ES5").S(t,e,i),i?(n[_e].P&&(Ma(t),It(4)),wn(e)&&(e=Ra(t,e),t.l||za(t,e)),t.u&&Xt("Patches").M(n[_e].t,e,t.u,t.s)):e=Ra(t,n,[]),Ma(t),t.u&&t.v(t.u,t.s),e!==Cg?e:void 0}function Ra(e,t,n){if(kd(t))return t;var i=t[_e];if(!i)return Pr(t,function(f,d){return lm(e,i,t,f,d,n)},!0),t;if(i.A!==e)return t;if(!i.P)return za(e,i.t,!0),i.t;if(!i.I){i.I=!0,i.A._--;var s=i.i===4||i.i===5?i.o=Td(i.k):i.o,a=s,u=!1;i.i===3&&(a=new Set(s),s.clear(),u=!0),Pr(a,function(f,d){return lm(e,i,s,f,d,n,u)}),za(e,s,!1),n&&e.u&&Xt("Patches").N(i,n,e.u,e.s)}return i.o}function lm(e,t,n,i,s,a,u){if(Jn(s)){var f=Ra(e,s,a&&t&&t.i!==3&&!ci(t.R,i)?a.concat(i):void 0);if(Eg(n,i,f),!Jn(f))return;e.m=!1}else u&&n.add(s);if(wn(s)&&!kd(s)){if(!e.h.D&&e._<1)return;Ra(e,s),t&&t.A.l||za(e,s)}}function za(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&Cd(t,n)}function Yu(e,t){var n=e[_e];return(n?dr(n):e)[t]}function um(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var i=Object.getOwnPropertyDescriptor(n,t);if(i)return i;n=Object.getPrototypeOf(n)}}function jn(e){e.P||(e.P=!0,e.l&&jn(e.l))}function Ju(e){e.o||(e.o=Td(e.t))}function uf(e,t,n){var i=Pd(t)?Xt("MapSet").F(t,n):Ed(t)?Xt("MapSet").T(t,n):e.O?function(s,a){var u=Array.isArray(s),f={i:u?1:0,A:a?a.A:af(),P:!1,I:!1,R:{},l:a,t:s,k:null,o:null,j:null,C:!1},d=f,p=Do;u&&(d=[f],p=lo);var m=Proxy.revocable(d,p),g=m.revoke,y=m.proxy;return f.k=y,f.j=g,y}(t,n):Xt("ES5").J(t,n);return(n?n.A:af()).p.push(i),i}function xP(e){return Jn(e)||It(22,e),function t(n){if(!wn(n))return n;var i,s=n[_e],a=Ni(n);if(s){if(!s.P&&(s.i<4||!Xt("ES5").K(s)))return s.t;s.I=!0,i=cm(n,a),s.I=!1}else i=cm(n,a);return Pr(i,function(u,f){s&&vP(s.t,u)===f||Eg(i,u,t(f))}),a===3?new Set(i):i}(e)}function cm(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return Td(e)}function SP(){function e(a,u){var f=s[a];return f?f.enumerable=u:s[a]=f={configurable:!0,enumerable:u,get:function(){var d=this[_e];return Do.get(d,a)},set:function(d){var p=this[_e];Do.set(p,a,d)}},f}function t(a){for(var u=a.length-1;u>=0;u--){var f=a[u][_e];if(!f.P)switch(f.i){case 5:i(f)&&jn(f);break;case 4:n(f)&&jn(f)}}}function n(a){for(var u=a.t,f=a.k,d=fi(f),p=d.length-1;p>=0;p--){var m=d[p];if(m!==_e){var g=u[m];if(g===void 0&&!ci(u,m))return!0;var y=f[m],C=y&&y[_e];if(C?C.t!==g:!Tg(y,g))return!0}}var x=!!u[_e];return d.length!==fi(u).length+(x?0:1)}function i(a){var u=a.k;if(u.length!==a.t.length)return!0;var f=Object.getOwnPropertyDescriptor(u,u.length-1);if(f&&!f.get)return!0;for(var d=0;d1?S-1:0),T=1;T1?m-1:0),y=1;y=0;s--){var a=i[s];if(a.path.length===0&&a.op==="replace"){n=a.value;break}}s>-1&&(i=i.slice(s+1));var u=Xt("Patches").$;return Jn(n)?u(n,i):this.produce(n,function(f){return u(f,i)})},e}(),ft=new CP,kP=ft.produce;ft.produceWithPatches.bind(ft);ft.setAutoFreeze.bind(ft);ft.setUseProxies.bind(ft);ft.applyPatches.bind(ft);ft.createDraft.bind(ft);ft.finishDraft.bind(ft);const Lg=kP;function Bo(e){"@babel/helpers - typeof";return Bo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bo(e)}function LP(e,t){if(Bo(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t||"default");if(Bo(i)!=="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function OP(e){var t=LP(e,"string");return Bo(t)==="symbol"?t:String(t)}function NP(e,t,n){return t=OP(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,i)}return n}function mm(e){for(var t=1;t"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(Ve(1));return n(Og)(e,t)}if(typeof e!="function")throw new Error(Ve(2));var s=e,a=t,u=[],f=u,d=!1;function p(){f===u&&(f=u.slice())}function m(){if(d)throw new Error(Ve(3));return a}function g(P){if(typeof P!="function")throw new Error(Ve(4));if(d)throw new Error(Ve(5));var R=!0;return p(),f.push(P),function(){if(R){if(d)throw new Error(Ve(6));R=!1,p();var w=f.indexOf(P);f.splice(w,1),u=null}}}function y(P){if(!MP(P))throw new Error(Ve(7));if(typeof P.type>"u")throw new Error(Ve(8));if(d)throw new Error(Ve(9));try{d=!0,a=s(a,P)}finally{d=!1}for(var R=u=f,S=0;S"u")throw new Error(Ve(12));if(typeof n(void 0,{type:Aa.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Ve(13))})}function zP(e){for(var t=Object.keys(e),n={},i=0;i"u")throw p&&p.type,new Error(Ve(14));g[C]=R,m=m||R!==P}return m=m||a.length!==Object.keys(d).length,m?g:d}}function ja(){for(var e=arguments.length,t=new Array(e),n=0;n0&&a[a.length-1])&&(p[0]===6||p[0]===2)){n=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]v.jsx("li",{className:"locations__item",children:n.name===e?v.jsx("a",{className:"locations__item-link tabs__item tabs__item--active",children:v.jsx("span",{children:n.name})}):v.jsx("a",{className:"locations__item-link tabs__item",onClick:()=>t(zg(n)),children:v.jsx("span",{children:n.name})})},n.name))})})}function aE({onSortChange:e}){const[t,n]=j.useState("Popular"),[i,s]=j.useState(!1),a=f=>{n(f),e(f),s(!1)},u=()=>{s(!i)};return v.jsxs("form",{className:"places__sorting",action:"#",method:"get",children:[v.jsx("span",{className:"places__sorting-caption",children:"Sort by"}),v.jsxs("span",{className:"places__sorting-type",tabIndex:0,onClick:u,children:[t,v.jsx("svg",{className:"places__sorting-arrow",width:"7",height:"4",children:v.jsx("use",{xlinkHref:"#icon-arrow-select"})})]}),v.jsx("ul",{className:`places__options places__options--custom ${i?"places__options--opened":""}`,children:xS.map(f=>v.jsx("li",{className:`places__option ${f===t?"places__option--active":""}`,tabIndex:0,onClick:()=>a(f),children:f},f))})]})}const lE={activeCity:lg,offers:[],detailOffer:null,nearOffers:[],reviews:[],authorizationStatus:en.Unknown},uE=XP(lE,e=>{e.addCase(zg,(t,n)=>{t.activeCity=n.payload}).addCase(Ag,(t,n)=>{t.offers=n.payload}).addCase(xl,(t,n)=>{t.detailOffer=n.payload}).addCase(jg,(t,n)=>{t.nearOffers=n.payload}).addCase(bg,(t,n)=>{t.reviews=n.payload}).addCase(qo,(t,n)=>{t.authorizationStatus=n.payload})});function Ig(e,t){return function(){return e.apply(t,arguments)}}const{toString:cE}=Object.prototype,{getPrototypeOf:Nd}=Object,Sl=(e=>t=>{const n=cE.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),tn=e=>(e=e.toLowerCase(),t=>Sl(t)===e),Pl=e=>t=>typeof t===e,{isArray:Mi}=Array,Fo=Pl("undefined");function fE(e){return e!==null&&!Fo(e)&&e.constructor!==null&&!Fo(e.constructor)&&Ct(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Dg=tn("ArrayBuffer");function dE(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Dg(e.buffer),t}const hE=Pl("string"),Ct=Pl("function"),Bg=Pl("number"),El=e=>e!==null&&typeof e=="object",pE=e=>e===!0||e===!1,Xs=e=>{if(Sl(e)!=="object")return!1;const t=Nd(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},mE=tn("Date"),_E=tn("File"),vE=tn("Blob"),gE=tn("FileList"),yE=e=>El(e)&&Ct(e.pipe),wE=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Ct(e.append)&&((t=Sl(e))==="formdata"||t==="object"&&Ct(e.toString)&&e.toString()==="[object FormData]"))},xE=tn("URLSearchParams"),SE=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Go(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let i,s;if(typeof e!="object"&&(e=[e]),Mi(e))for(i=0,s=e.length;i0;)if(s=n[i],t===s.toLowerCase())return s;return null}const $g=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),Ug=e=>!Fo(e)&&e!==$g;function ff(){const{caseless:e}=Ug(this)&&this||{},t={},n=(i,s)=>{const a=e&&Fg(t,s)||s;Xs(t[a])&&Xs(i)?t[a]=ff(t[a],i):Xs(i)?t[a]=ff({},i):Mi(i)?t[a]=i.slice():t[a]=i};for(let i=0,s=arguments.length;i(Go(t,(s,a)=>{n&&Ct(s)?e[a]=Ig(s,n):e[a]=s},{allOwnKeys:i}),e),EE=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),TE=(e,t,n,i)=>{e.prototype=Object.create(t.prototype,i),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},CE=(e,t,n,i)=>{let s,a,u;const f={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),a=s.length;a-- >0;)u=s[a],(!i||i(u,e,t))&&!f[u]&&(t[u]=e[u],f[u]=!0);e=n!==!1&&Nd(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kE=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const i=e.indexOf(t,n);return i!==-1&&i===n},LE=e=>{if(!e)return null;if(Mi(e))return e;let t=e.length;if(!Bg(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},OE=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Nd(Uint8Array)),NE=(e,t)=>{const i=(e&&e[Symbol.iterator]).call(e);let s;for(;(s=i.next())&&!s.done;){const a=s.value;t.call(e,a[0],a[1])}},ME=(e,t)=>{let n;const i=[];for(;(n=e.exec(t))!==null;)i.push(n);return i},RE=tn("HTMLFormElement"),zE=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,i,s){return i.toUpperCase()+s}),Pm=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),AE=tn("RegExp"),Zg=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),i={};Go(n,(s,a)=>{let u;(u=t(s,a,e))!==!1&&(i[a]=u||s)}),Object.defineProperties(e,i)},jE=e=>{Zg(e,(t,n)=>{if(Ct(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const i=e[n];if(Ct(i)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},bE=(e,t)=>{const n={},i=s=>{s.forEach(a=>{n[a]=!0})};return Mi(e)?i(e):i(String(e).split(t)),n},IE=()=>{},DE=(e,t)=>(e=+e,Number.isFinite(e)?e:t),nc="abcdefghijklmnopqrstuvwxyz",Em="0123456789",Hg={DIGIT:Em,ALPHA:nc,ALPHA_DIGIT:nc+nc.toUpperCase()+Em},BE=(e=16,t=Hg.ALPHA_DIGIT)=>{let n="";const{length:i}=t;for(;e--;)n+=t[Math.random()*i|0];return n};function FE(e){return!!(e&&Ct(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const $E=e=>{const t=new Array(10),n=(i,s)=>{if(El(i)){if(t.indexOf(i)>=0)return;if(!("toJSON"in i)){t[s]=i;const a=Mi(i)?[]:{};return Go(i,(u,f)=>{const d=n(u,s+1);!Fo(d)&&(a[f]=d)}),t[s]=void 0,a}}return i};return n(e,0)},UE=tn("AsyncFunction"),ZE=e=>e&&(El(e)||Ct(e))&&Ct(e.then)&&Ct(e.catch),M={isArray:Mi,isArrayBuffer:Dg,isBuffer:fE,isFormData:wE,isArrayBufferView:dE,isString:hE,isNumber:Bg,isBoolean:pE,isObject:El,isPlainObject:Xs,isUndefined:Fo,isDate:mE,isFile:_E,isBlob:vE,isRegExp:AE,isFunction:Ct,isStream:yE,isURLSearchParams:xE,isTypedArray:OE,isFileList:gE,forEach:Go,merge:ff,extend:PE,trim:SE,stripBOM:EE,inherits:TE,toFlatObject:CE,kindOf:Sl,kindOfTest:tn,endsWith:kE,toArray:LE,forEachEntry:NE,matchAll:ME,isHTMLForm:RE,hasOwnProperty:Pm,hasOwnProp:Pm,reduceDescriptors:Zg,freezeMethods:jE,toObjectSet:bE,toCamelCase:zE,noop:IE,toFiniteNumber:DE,findKey:Fg,global:$g,isContextDefined:Ug,ALPHABET:Hg,generateString:BE,isSpecCompliantForm:FE,toJSONObject:$E,isAsyncFn:UE,isThenable:ZE};function ee(e,t,n,i,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),i&&(this.request=i),s&&(this.response=s)}M.inherits(ee,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:M.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Wg=ee.prototype,Vg={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Vg[e]={value:e}});Object.defineProperties(ee,Vg);Object.defineProperty(Wg,"isAxiosError",{value:!0});ee.from=(e,t,n,i,s,a)=>{const u=Object.create(Wg);return M.toFlatObject(e,u,function(d){return d!==Error.prototype},f=>f!=="isAxiosError"),ee.call(u,e.message,t,n,i,s),u.cause=e,u.name=e.name,a&&Object.assign(u,a),u};const HE=null;function df(e){return M.isPlainObject(e)||M.isArray(e)}function Kg(e){return M.endsWith(e,"[]")?e.slice(0,-2):e}function Tm(e,t,n){return e?e.concat(t).map(function(s,a){return s=Kg(s),!n&&a?"["+s+"]":s}).join(n?".":""):t}function WE(e){return M.isArray(e)&&!e.some(df)}const VE=M.toFlatObject(M,{},null,function(t){return/^is[A-Z]/.test(t)});function Tl(e,t,n){if(!M.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=M.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(P,R){return!M.isUndefined(R[P])});const i=n.metaTokens,s=n.visitor||m,a=n.dots,u=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&M.isSpecCompliantForm(t);if(!M.isFunction(s))throw new TypeError("visitor must be a function");function p(x){if(x===null)return"";if(M.isDate(x))return x.toISOString();if(!d&&M.isBlob(x))throw new ee("Blob is not supported. Use a Buffer instead.");return M.isArrayBuffer(x)||M.isTypedArray(x)?d&&typeof Blob=="function"?new Blob([x]):Buffer.from(x):x}function m(x,P,R){let S=x;if(x&&!R&&typeof x=="object"){if(M.endsWith(P,"{}"))P=i?P:P.slice(0,-2),x=JSON.stringify(x);else if(M.isArray(x)&&WE(x)||(M.isFileList(x)||M.endsWith(P,"[]"))&&(S=M.toArray(x)))return P=Kg(P),S.forEach(function(T,N){!(M.isUndefined(T)||T===null)&&t.append(u===!0?Tm([P],N,a):u===null?P:P+"[]",p(T))}),!1}return df(x)?!0:(t.append(Tm(R,P,a),p(x)),!1)}const g=[],y=Object.assign(VE,{defaultVisitor:m,convertValue:p,isVisitable:df});function C(x,P){if(!M.isUndefined(x)){if(g.indexOf(x)!==-1)throw Error("Circular reference detected in "+P.join("."));g.push(x),M.forEach(x,function(S,w){(!(M.isUndefined(S)||S===null)&&s.call(t,S,M.isString(w)?w.trim():w,P,y))===!0&&C(S,P?P.concat(w):[w])}),g.pop()}}if(!M.isObject(e))throw new TypeError("data must be an object");return C(e),t}function Cm(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(i){return t[i]})}function Md(e,t){this._pairs=[],e&&Tl(e,this,t)}const qg=Md.prototype;qg.append=function(t,n){this._pairs.push([t,n])};qg.toString=function(t){const n=t?function(i){return t.call(this,i,Cm)}:Cm;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function KE(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Gg(e,t,n){if(!t)return e;const i=n&&n.encode||KE,s=n&&n.serialize;let a;if(s?a=s(t,n):a=M.isURLSearchParams(t)?t.toString():new Md(t,n).toString(i),a){const u=e.indexOf("#");u!==-1&&(e=e.slice(0,u)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class qE{constructor(){this.handlers=[]}use(t,n,i){return this.handlers.push({fulfilled:t,rejected:n,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){M.forEach(this.handlers,function(i){i!==null&&t(i)})}}const km=qE,Qg={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},GE=typeof URLSearchParams<"u"?URLSearchParams:Md,QE=typeof FormData<"u"?FormData:null,YE=typeof Blob<"u"?Blob:null,JE=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),XE=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),Qt={isBrowser:!0,classes:{URLSearchParams:GE,FormData:QE,Blob:YE},isStandardBrowserEnv:JE,isStandardBrowserWebWorkerEnv:XE,protocols:["http","https","file","blob","url","data"]};function eT(e,t){return Tl(e,new Qt.classes.URLSearchParams,Object.assign({visitor:function(n,i,s,a){return Qt.isNode&&M.isBuffer(n)?(this.append(i,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function tT(e){return M.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function nT(e){const t={},n=Object.keys(e);let i;const s=n.length;let a;for(i=0;i=n.length;return u=!u&&M.isArray(s)?s.length:u,d?(M.hasOwnProp(s,u)?s[u]=[s[u],i]:s[u]=i,!f):((!s[u]||!M.isObject(s[u]))&&(s[u]=[]),t(n,i,s[u],a)&&M.isArray(s[u])&&(s[u]=nT(s[u])),!f)}if(M.isFormData(e)&&M.isFunction(e.entries)){const n={};return M.forEachEntry(e,(i,s)=>{t(tT(i),s,n,0)}),n}return null}function rT(e,t,n){if(M.isString(e))try{return(t||JSON.parse)(e),M.trim(e)}catch(i){if(i.name!=="SyntaxError")throw i}return(n||JSON.stringify)(e)}const Rd={transitional:Qg,adapter:["xhr","http"],transformRequest:[function(t,n){const i=n.getContentType()||"",s=i.indexOf("application/json")>-1,a=M.isObject(t);if(a&&M.isHTMLForm(t)&&(t=new FormData(t)),M.isFormData(t))return s&&s?JSON.stringify(Yg(t)):t;if(M.isArrayBuffer(t)||M.isBuffer(t)||M.isStream(t)||M.isFile(t)||M.isBlob(t))return t;if(M.isArrayBufferView(t))return t.buffer;if(M.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let f;if(a){if(i.indexOf("application/x-www-form-urlencoded")>-1)return eT(t,this.formSerializer).toString();if((f=M.isFileList(t))||i.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return Tl(f?{"files[]":t}:t,d&&new d,this.formSerializer)}}return a||s?(n.setContentType("application/json",!1),rT(t)):t}],transformResponse:[function(t){const n=this.transitional||Rd.transitional,i=n&&n.forcedJSONParsing,s=this.responseType==="json";if(t&&M.isString(t)&&(i&&!this.responseType||s)){const u=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(t)}catch(f){if(u)throw f.name==="SyntaxError"?ee.from(f,ee.ERR_BAD_RESPONSE,this,null,this.response):f}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Qt.classes.FormData,Blob:Qt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};M.forEach(["delete","get","head","post","put","patch"],e=>{Rd.headers[e]={}});const zd=Rd,iT=M.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),oT=e=>{const t={};let n,i,s;return e&&e.split(` -`).forEach(function(u){s=u.indexOf(":"),n=u.substring(0,s).trim().toLowerCase(),i=u.substring(s+1).trim(),!(!n||t[n]&&iT[n])&&(n==="set-cookie"?t[n]?t[n].push(i):t[n]=[i]:t[n]=t[n]?t[n]+", "+i:i)}),t},Lm=Symbol("internals");function ro(e){return e&&String(e).trim().toLowerCase()}function ea(e){return e===!1||e==null?e:M.isArray(e)?e.map(ea):String(e)}function sT(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let i;for(;i=n.exec(e);)t[i[1]]=i[2];return t}const aT=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function rc(e,t,n,i,s){if(M.isFunction(i))return i.call(this,t,n);if(s&&(t=n),!!M.isString(t)){if(M.isString(i))return t.indexOf(i)!==-1;if(M.isRegExp(i))return i.test(t)}}function lT(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,i)=>n.toUpperCase()+i)}function uT(e,t){const n=M.toCamelCase(" "+t);["get","set","has"].forEach(i=>{Object.defineProperty(e,i+n,{value:function(s,a,u){return this[i].call(this,t,s,a,u)},configurable:!0})})}class Cl{constructor(t){t&&this.set(t)}set(t,n,i){const s=this;function a(f,d,p){const m=ro(d);if(!m)throw new Error("header name must be a non-empty string");const g=M.findKey(s,m);(!g||s[g]===void 0||p===!0||p===void 0&&s[g]!==!1)&&(s[g||d]=ea(f))}const u=(f,d)=>M.forEach(f,(p,m)=>a(p,m,d));return M.isPlainObject(t)||t instanceof this.constructor?u(t,n):M.isString(t)&&(t=t.trim())&&!aT(t)?u(oT(t),n):t!=null&&a(n,t,i),this}get(t,n){if(t=ro(t),t){const i=M.findKey(this,t);if(i){const s=this[i];if(!n)return s;if(n===!0)return sT(s);if(M.isFunction(n))return n.call(this,s,i);if(M.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=ro(t),t){const i=M.findKey(this,t);return!!(i&&this[i]!==void 0&&(!n||rc(this,this[i],i,n)))}return!1}delete(t,n){const i=this;let s=!1;function a(u){if(u=ro(u),u){const f=M.findKey(i,u);f&&(!n||rc(i,i[f],f,n))&&(delete i[f],s=!0)}}return M.isArray(t)?t.forEach(a):a(t),s}clear(t){const n=Object.keys(this);let i=n.length,s=!1;for(;i--;){const a=n[i];(!t||rc(this,this[a],a,t,!0))&&(delete this[a],s=!0)}return s}normalize(t){const n=this,i={};return M.forEach(this,(s,a)=>{const u=M.findKey(i,a);if(u){n[u]=ea(s),delete n[a];return}const f=t?lT(a):String(a).trim();f!==a&&delete n[a],n[f]=ea(s),i[f]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return M.forEach(this,(i,s)=>{i!=null&&i!==!1&&(n[s]=t&&M.isArray(i)?i.join(", "):i)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` -`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const i=new this(t);return n.forEach(s=>i.set(s)),i}static accessor(t){const i=(this[Lm]=this[Lm]={accessors:{}}).accessors,s=this.prototype;function a(u){const f=ro(u);i[f]||(uT(s,u),i[f]=!0)}return M.isArray(t)?t.forEach(a):a(t),this}}Cl.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);M.reduceDescriptors(Cl.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(i){this[n]=i}}});M.freezeMethods(Cl);const mn=Cl;function ic(e,t){const n=this||zd,i=t||n,s=mn.from(i.headers);let a=i.data;return M.forEach(e,function(f){a=f.call(n,a,s.normalize(),t?t.status:void 0)}),s.normalize(),a}function Jg(e){return!!(e&&e.__CANCEL__)}function Qo(e,t,n){ee.call(this,e??"canceled",ee.ERR_CANCELED,t,n),this.name="CanceledError"}M.inherits(Qo,ee,{__CANCEL__:!0});function cT(e,t,n){const i=n.config.validateStatus;!n.status||!i||i(n.status)?e(n):t(new ee("Request failed with status code "+n.status,[ee.ERR_BAD_REQUEST,ee.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const fT=Qt.isStandardBrowserEnv?function(){return{write:function(n,i,s,a,u,f){const d=[];d.push(n+"="+encodeURIComponent(i)),M.isNumber(s)&&d.push("expires="+new Date(s).toGMTString()),M.isString(a)&&d.push("path="+a),M.isString(u)&&d.push("domain="+u),f===!0&&d.push("secure"),document.cookie=d.join("; ")},read:function(n){const i=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return i?decodeURIComponent(i[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function dT(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function hT(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function Xg(e,t){return e&&!dT(t)?hT(e,t):t}const pT=Qt.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let i;function s(a){let u=a;return t&&(n.setAttribute("href",u),u=n.href),n.setAttribute("href",u),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return i=s(window.location.href),function(u){const f=M.isString(u)?s(u):u;return f.protocol===i.protocol&&f.host===i.host}}():function(){return function(){return!0}}();function mT(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function _T(e,t){e=e||10;const n=new Array(e),i=new Array(e);let s=0,a=0,u;return t=t!==void 0?t:1e3,function(d){const p=Date.now(),m=i[a];u||(u=p),n[s]=d,i[s]=p;let g=a,y=0;for(;g!==s;)y+=n[g++],g=g%e;if(s=(s+1)%e,s===a&&(a=(a+1)%e),p-u{const a=s.loaded,u=s.lengthComputable?s.total:void 0,f=a-n,d=i(f),p=a<=u;n=a;const m={loaded:a,total:u,progress:u?a/u:void 0,bytes:f,rate:d||void 0,estimated:d&&u&&p?(u-a)/d:void 0,event:s};m[t?"download":"upload"]=!0,e(m)}}const vT=typeof XMLHttpRequest<"u",gT=vT&&function(e){return new Promise(function(n,i){let s=e.data;const a=mn.from(e.headers).normalize(),u=e.responseType;let f;function d(){e.cancelToken&&e.cancelToken.unsubscribe(f),e.signal&&e.signal.removeEventListener("abort",f)}let p;M.isFormData(s)&&(Qt.isStandardBrowserEnv||Qt.isStandardBrowserWebWorkerEnv?a.setContentType(!1):a.getContentType(/^\s*multipart\/form-data/)?M.isString(p=a.getContentType())&&a.setContentType(p.replace(/^\s*(multipart\/form-data);+/,"$1")):a.setContentType("multipart/form-data"));let m=new XMLHttpRequest;if(e.auth){const x=e.auth.username||"",P=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";a.set("Authorization","Basic "+btoa(x+":"+P))}const g=Xg(e.baseURL,e.url);m.open(e.method.toUpperCase(),Gg(g,e.params,e.paramsSerializer),!0),m.timeout=e.timeout;function y(){if(!m)return;const x=mn.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),R={data:!u||u==="text"||u==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:x,config:e,request:m};cT(function(w){n(w),d()},function(w){i(w),d()},R),m=null}if("onloadend"in m?m.onloadend=y:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(y)},m.onabort=function(){m&&(i(new ee("Request aborted",ee.ECONNABORTED,e,m)),m=null)},m.onerror=function(){i(new ee("Network Error",ee.ERR_NETWORK,e,m)),m=null},m.ontimeout=function(){let P=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const R=e.transitional||Qg;e.timeoutErrorMessage&&(P=e.timeoutErrorMessage),i(new ee(P,R.clarifyTimeoutError?ee.ETIMEDOUT:ee.ECONNABORTED,e,m)),m=null},Qt.isStandardBrowserEnv){const x=(e.withCredentials||pT(g))&&e.xsrfCookieName&&fT.read(e.xsrfCookieName);x&&a.set(e.xsrfHeaderName,x)}s===void 0&&a.setContentType(null),"setRequestHeader"in m&&M.forEach(a.toJSON(),function(P,R){m.setRequestHeader(R,P)}),M.isUndefined(e.withCredentials)||(m.withCredentials=!!e.withCredentials),u&&u!=="json"&&(m.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&m.addEventListener("progress",Om(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&m.upload&&m.upload.addEventListener("progress",Om(e.onUploadProgress)),(e.cancelToken||e.signal)&&(f=x=>{m&&(i(!x||x.type?new Qo(null,e,m):x),m.abort(),m=null)},e.cancelToken&&e.cancelToken.subscribe(f),e.signal&&(e.signal.aborted?f():e.signal.addEventListener("abort",f)));const C=mT(g);if(C&&Qt.protocols.indexOf(C)===-1){i(new ee("Unsupported protocol "+C+":",ee.ERR_BAD_REQUEST,e));return}m.send(s||null)})},hf={http:HE,xhr:gT};M.forEach(hf,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Nm=e=>`- ${e}`,yT=e=>M.isFunction(e)||e===null||e===!1,ey={getAdapter:e=>{e=M.isArray(e)?e:[e];const{length:t}=e;let n,i;const s={};for(let a=0;a`adapter ${f} `+(d===!1?"is not supported by the environment":"is not available in the build"));let u=t?a.length>1?`since : -`+a.map(Nm).join(` -`):" "+Nm(a[0]):"as no adapter specified";throw new ee("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return i},adapters:hf};function oc(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Qo(null,e)}function Mm(e){return oc(e),e.headers=mn.from(e.headers),e.data=ic.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),ey.getAdapter(e.adapter||zd.adapter)(e).then(function(i){return oc(e),i.data=ic.call(e,e.transformResponse,i),i.headers=mn.from(i.headers),i},function(i){return Jg(i)||(oc(e),i&&i.response&&(i.response.data=ic.call(e,e.transformResponse,i.response),i.response.headers=mn.from(i.response.headers))),Promise.reject(i)})}const Rm=e=>e instanceof mn?e.toJSON():e;function Pi(e,t){t=t||{};const n={};function i(p,m,g){return M.isPlainObject(p)&&M.isPlainObject(m)?M.merge.call({caseless:g},p,m):M.isPlainObject(m)?M.merge({},m):M.isArray(m)?m.slice():m}function s(p,m,g){if(M.isUndefined(m)){if(!M.isUndefined(p))return i(void 0,p,g)}else return i(p,m,g)}function a(p,m){if(!M.isUndefined(m))return i(void 0,m)}function u(p,m){if(M.isUndefined(m)){if(!M.isUndefined(p))return i(void 0,p)}else return i(void 0,m)}function f(p,m,g){if(g in t)return i(p,m);if(g in e)return i(void 0,p)}const d={url:a,method:a,data:a,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,beforeRedirect:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,responseEncoding:u,validateStatus:f,headers:(p,m)=>s(Rm(p),Rm(m),!0)};return M.forEach(Object.keys(Object.assign({},e,t)),function(m){const g=d[m]||s,y=g(e[m],t[m],m);M.isUndefined(y)&&g!==f||(n[m]=y)}),n}const ty="1.5.1",Ad={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Ad[e]=function(i){return typeof i===e||"a"+(t<1?"n ":" ")+e}});const zm={};Ad.transitional=function(t,n,i){function s(a,u){return"[Axios v"+ty+"] Transitional option '"+a+"'"+u+(i?". "+i:"")}return(a,u,f)=>{if(t===!1)throw new ee(s(u," has been removed"+(n?" in "+n:"")),ee.ERR_DEPRECATED);return n&&!zm[u]&&(zm[u]=!0,console.warn(s(u," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,u,f):!0}};function wT(e,t,n){if(typeof e!="object")throw new ee("options must be an object",ee.ERR_BAD_OPTION_VALUE);const i=Object.keys(e);let s=i.length;for(;s-- >0;){const a=i[s],u=t[a];if(u){const f=e[a],d=f===void 0||u(f,a,e);if(d!==!0)throw new ee("option "+a+" must be "+d,ee.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ee("Unknown option "+a,ee.ERR_BAD_OPTION)}}const pf={assertOptions:wT,validators:Ad},Nn=pf.validators;class ba{constructor(t){this.defaults=t,this.interceptors={request:new km,response:new km}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Pi(this.defaults,n);const{transitional:i,paramsSerializer:s,headers:a}=n;i!==void 0&&pf.assertOptions(i,{silentJSONParsing:Nn.transitional(Nn.boolean),forcedJSONParsing:Nn.transitional(Nn.boolean),clarifyTimeoutError:Nn.transitional(Nn.boolean)},!1),s!=null&&(M.isFunction(s)?n.paramsSerializer={serialize:s}:pf.assertOptions(s,{encode:Nn.function,serialize:Nn.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&M.merge(a.common,a[n.method]);a&&M.forEach(["delete","get","head","post","put","patch","common"],x=>{delete a[x]}),n.headers=mn.concat(u,a);const f=[];let d=!0;this.interceptors.request.forEach(function(P){typeof P.runWhen=="function"&&P.runWhen(n)===!1||(d=d&&P.synchronous,f.unshift(P.fulfilled,P.rejected))});const p=[];this.interceptors.response.forEach(function(P){p.push(P.fulfilled,P.rejected)});let m,g=0,y;if(!d){const x=[Mm.bind(this),void 0];for(x.unshift.apply(x,f),x.push.apply(x,p),y=x.length,m=Promise.resolve(n);g{if(!i._listeners)return;let a=i._listeners.length;for(;a-- >0;)i._listeners[a](s);i._listeners=null}),this.promise.then=s=>{let a;const u=new Promise(f=>{i.subscribe(f),a=f}).then(s);return u.cancel=function(){i.unsubscribe(a)},u},t(function(a,u,f){i.reason||(i.reason=new Qo(a,u,f),n(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new jd(function(s){t=s}),cancel:t}}}const xT=jd;function ST(e){return function(n){return e.apply(null,n)}}function PT(e){return M.isObject(e)&&e.isAxiosError===!0}const mf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(mf).forEach(([e,t])=>{mf[t]=e});const ET=mf;function ny(e){const t=new ta(e),n=Ig(ta.prototype.request,t);return M.extend(n,ta.prototype,t,{allOwnKeys:!0}),M.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return ny(Pi(e,s))},n}const Re=ny(zd);Re.Axios=ta;Re.CanceledError=Qo;Re.CancelToken=xT;Re.isCancel=Jg;Re.VERSION=ty;Re.toFormData=Tl;Re.AxiosError=ee;Re.Cancel=Re.CanceledError;Re.all=function(t){return Promise.all(t)};Re.spread=ST;Re.isAxiosError=PT;Re.mergeConfig=Pi;Re.AxiosHeaders=mn;Re.formToJSON=e=>Yg(M.isHTMLForm(e)?new FormData(e):e);Re.getAdapter=ey.getAdapter;Re.HttpStatusCode=ET;Re.default=Re;const TT=Re,ry="six-cities-token",CT=()=>localStorage.getItem(ry)??"",kT=e=>{localStorage.setItem(ry,e)},LT="https://14.design.htmlacademy.pro/six-cities",OT=5e3,NT=()=>{const e=TT.create({baseURL:LT,timeout:OT});return e.interceptors.request.use(t=>{const n=CT();return n&&t.headers&&(t.headers["x-token"]=n),t}),e.interceptors.response.use(t=>t,t=>{throw t.response&&t.response.status===401&<.dispatch(qo(en.Unauthorized)),t.response&&t.response.status===404&<.dispatch(xl(void 0)),t}),e},MT=NT(),lt=QP({reducer:uE,middleware:e=>e({thunk:{extraArgument:MT}})}),RT=rr("data/fetchOffers",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(nr.offers);t(Ag(i))}),zT=rr("data/fetchDetailOffer",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(`${nr.offers}/${e}`);t(xl(i))}),AT=rr("data/fetchNearOffers",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(`${nr.offers}/${e}/nearby`);t(jg(i))}),iy=rr("data/fetchReviews",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(`${nr.reviews}/${e}`);t(bg(i))}),jT=rr("data/fetchReviews",async(e,{extra:t})=>{(await t.post(`${nr.reviews}/${e.offerId}`,{comment:e.comment,rating:Number(e.rating)})).status===201&<.dispatch(iy(e.offerId))}),bT=rr("auth/login",async(e,{dispatch:t,extra:n})=>{const i=await n.post(nr.login,e);if(i.status===200||i.status===201)t(qo(en.Authorized)),kT(i.data.token);else throw i}),IT=rr("auth/checkAuthorization",async(e,{dispatch:t,extra:n})=>{await n.get(nr.login),t(qo(en.Unauthorized))}),DT=rr("auth/logout",async(e,{dispatch:t,extra:n})=>{await n.delete(nr.logout),t(qo(en.Unauthorized))});function BT(){const e=St(C=>C.activeCity),t=St(C=>C.offers).filter(C=>C.city.name===e.name),n=t.filter(C=>C.isFavorite).length,[i,s]=j.useState(null),a=t.find(C=>C.id===i),u=t.length===0?"No places to stay available":`${t.length} places to stay in ${e.name}`,[f,d]=j.useState("Popular"),p=[...t].sort((C,x)=>{switch(f){case"Price: low to high":return C.price-x.price;case"Price: high to low":return x.price-C.price;case"Top rated first":return x.rating-C.rating;default:return 0}}),m=C=>{d(C)},g=St(C=>C.authorizationStatus)===en.Authorized,y=()=>{lt.dispatch(DT())};return v.jsxs("div",{className:"page page--gray page--main",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities"})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsxs("div",{className:"header__wrapper",children:[v.jsx("div",{className:"header__left",children:v.jsx("a",{className:"header__logo-link header__logo-link--active",children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})}),g?v.jsx("nav",{className:"header__nav",children:v.jsxs("ul",{className:"header__nav-list",children:[v.jsx("li",{className:"header__nav-item user",children:v.jsxs(at,{className:"header__nav-link header__nav-link--profile",to:be.Favorites,children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__user-name user__name",children:"Oliver.conner@gmail.com"}),v.jsx("span",{className:"header__favorite-count",children:n})]})}),v.jsx("li",{className:"header__nav-item",children:v.jsx("a",{className:"header__nav-link",onClick:y,children:v.jsx("span",{className:"header__signout",children:"Sign out"})})})]})}):v.jsx("nav",{className:"header__nav",children:v.jsx("ul",{className:"header__nav-list",children:v.jsx("li",{className:"header__nav-item user",children:v.jsxs(at,{className:"header__nav-link header__nav-link--profile",to:be.Login,children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__login",children:"Sign in"})]})})})})]})})}),v.jsxs("main",{className:"page__main page__main--index",children:[v.jsx("h1",{className:"visually-hidden",children:"Cities"}),v.jsx("div",{className:"tabs",children:v.jsx(sE,{activeCity:e.name})}),v.jsx("div",{className:"cities",children:v.jsxs("div",{className:"cities__places-container container",children:[v.jsxs("section",{className:"cities__places places",children:[v.jsx("h2",{className:"visually-hidden",children:"Places"}),v.jsx("b",{className:"places__found",children:u}),v.jsx(aE,{onSortChange:m}),v.jsx(ug,{offers:p,onChange:s})]}),v.jsx("div",{className:"cities__right-section",children:v.jsx(cg,{city:e,offers:t,selectedOffer:a})})]})})]})]})}function FT(){const[e,t]=j.useState({email:"",password:""}),n=i=>{i.preventDefault(),lt.dispatch(bT(e))};return v.jsxs("div",{className:"page page--gray page--login",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities: authorization"})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsx("div",{className:"header__wrapper",children:v.jsx("div",{className:"header__left",children:v.jsx(at,{className:"header__logo-link",to:be.Main,children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})})})})}),v.jsx("main",{className:"page__main page__main--login",children:v.jsxs("div",{className:"page__login-container container",children:[v.jsxs("section",{className:"login",children:[v.jsx("h1",{className:"login__title",children:"Sign in"}),v.jsxs("form",{className:"login__form form",action:"#",method:"post",children:[v.jsxs("div",{className:"login__input-wrapper form__input-wrapper",children:[v.jsx("label",{className:"visually-hidden",children:"E-mail"}),v.jsx("input",{className:"login__input form__input",type:"email",name:"email",placeholder:"Email",onChange:i=>t({...e,email:i.target.value}),required:!0})]}),v.jsxs("div",{className:"login__input-wrapper form__input-wrapper",children:[v.jsx("label",{className:"visually-hidden",children:"Password"}),v.jsx("input",{className:"login__input form__input",type:"password",name:"password",placeholder:"Password",onChange:i=>t({...e,password:i.target.value}),required:!0})]}),v.jsx("button",{className:"login__submit form__submit button",type:"submit",onClick:n,children:"Sign in"})]})]}),v.jsx("section",{className:"locations locations--login locations--current",children:v.jsx("div",{className:"locations__item",children:v.jsx("a",{className:"locations__item-link",href:"#",children:v.jsx("span",{children:"Amsterdam"})})})})]})})]})}function $T(){const[e,t]=j.useState({review:"",rating:0}),n=St(f=>f.detailOffer).id,i=f=>{f.preventDefault(),lt.dispatch(jT({offerId:n,rating:e.rating,comment:e.review}))},s=e.review.length>=rm&&e.review.length<=pS&&e.rating!==null,a=f=>{const{name:d,value:p}=f.target;t({...e,[d]:p})};function u(f,d){return v.jsxs(v.Fragment,{children:[v.jsx("input",{className:"form__rating-input visually-hidden",onChange:a,name:"rating",value:f,id:`${f}-stars`,type:"radio"}),v.jsx("label",{htmlFor:`${f}-stars`,className:"reviews__rating-label form__rating-label",title:d,children:v.jsx("svg",{className:"form__star-image",width:"37",height:"33",children:v.jsx("use",{xlinkHref:"#icon-star"})})})]})}return v.jsxs("form",{className:"reviews__form form",onSubmit:i,children:[v.jsx("label",{className:"reviews__label form__label",htmlFor:"review",children:"Your review"}),v.jsxs("div",{className:"reviews__rating-form form__rating",children:[u(5,"perfect"),u(4,"good"),u(3,"not bad"),u(2,"badly"),u(1,"terribly")]}),v.jsx("textarea",{className:"reviews__textarea form__textarea",onChange:a,value:e.review,id:"review",name:"review",placeholder:"Tell how was your stay, what you like and what can be improved"}),v.jsxs("div",{className:"reviews__button-wrapper",children:[v.jsxs("p",{className:"reviews__help",children:["To submit review please make sure to set ",v.jsx("span",{className:"reviews__star",children:"rating"})," and describe your stay with at least ",v.jsxs("b",{className:"reviews__text-amount",children:[rm," characters"]}),"."]}),v.jsx("button",{className:"reviews__submit form__submit button",type:"submit",disabled:!s,children:"Submit"})]})]})}function UT({review:e}){return v.jsxs("li",{className:"reviews__item",children:[v.jsxs("div",{className:"reviews__user user",children:[v.jsx("div",{className:"reviews__avatar-wrapper user__avatar-wrapper",children:v.jsx("img",{className:"reviews__avatar user__avatar",src:e.user.avatarUrl,width:"54",height:"54",alt:"Reviews avatar"})}),v.jsx("span",{className:"reviews__user-name",children:e.user.name})]}),v.jsxs("div",{className:"reviews__info",children:[v.jsx("div",{className:"reviews__rating rating",children:v.jsxs("div",{className:"reviews__stars rating__stars",children:[v.jsx("span",{style:{width:`calc(100% / 5 * ${e.rating})`}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]})}),v.jsx("p",{className:"reviews__text",children:e.comment}),v.jsx("time",{className:"reviews__time",dateTime:e.date.split("T")[0],children:new Date(e.date).toLocaleDateString("en-US",{month:"long",year:"numeric"})})]})]})}function ZT({reviews:e}){return v.jsx("ul",{className:"reviews__list",children:e.map(t=>v.jsx(UT,{review:t},t.id))})}function HT(){const e="#3069a6",i={display:"flex",justifyContent:"center",alignItems:"center",position:"relative",width:"100vw",height:"100vh",animation:"react-spinners-rotate 2s 0s infinite linear"},s=a=>({position:"relative",top:a%2?"0":"auto",bottom:a%2?"auto":"0",height:`${80/2}px`,width:`${80/2}px`,backgroundColor:e,borderRadius:"100%",animation:`react-spinners-bounce ${2/1}s ${a===2?"1s":"0s"} infinite linear`});return v.jsxs("span",{style:i,children:[v.jsx("span",{style:s(1)}),v.jsx("span",{style:s(2)})]})}function WT(){const{id:e}=px();j.useEffect(()=>{lt.dispatch(xl(null)),lt.dispatch(zT(e)),lt.dispatch(AT(e)),lt.dispatch(iy(e))},[e]);const t=St(u=>u.detailOffer),n=St(u=>u.nearOffers).slice(0,3),i=St(u=>u.reviews),s=St(u=>u.offers).filter(u=>u.isFavorite).length,a=St(u=>u.authorizationStatus)===en.Authorized;return t===null?v.jsx(HT,{}):t===void 0?v.jsx(md,{to:"*"}):v.jsxs("div",{className:"page",children:[v.jsx(qn,{children:v.jsxs("title",{children:["6 sities: ",t.title]})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsxs("div",{className:"header__wrapper",children:[v.jsx("div",{className:"header__left",children:v.jsx(at,{className:"header__logo-link",to:be.Main,children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})}),v.jsx("nav",{className:"header__nav",children:v.jsxs("ul",{className:"header__nav-list",children:[v.jsxs("li",{className:"header__nav-item user",children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx(at,{to:be.Main,children:v.jsx("span",{className:"header__user-name user__name",children:"Oliver.conner@gmail.com"})}),v.jsx(at,{to:be.Favorites,children:v.jsx("span",{className:"header__favorite-count",children:s})})]}),v.jsx("li",{className:"header__nav-item",children:v.jsx("a",{className:"header__nav-link",href:"#",children:v.jsx("span",{className:"header__signout",children:"Sign out"})})})]})})]})})}),v.jsxs("main",{className:"page__main page__main--offer",children:[v.jsxs("section",{className:"offer",children:[v.jsx("div",{className:"offer__gallery-container container",children:v.jsx("div",{className:"offer__gallery",children:t.images.map((u,f)=>v.jsx("div",{className:"offer__image-wrapper",children:v.jsx("img",{className:"offer__image",src:u,alt:`Photo ${f+1}`})},u))})}),v.jsx("div",{className:"offer__container container",children:v.jsxs("div",{className:"offer__wrapper",children:[v.jsx("div",{className:"offer__mark",children:v.jsx("span",{children:t.isPremium})}),v.jsxs("div",{className:"offer__name-wrapper",children:[v.jsx("h1",{className:"offer__name",children:t.title}),v.jsxs("button",{className:`offer__bookmark-button ${t.isFavorite&&"offer__bookmark-button--active"} button`,type:"button",children:[v.jsx("svg",{className:"offer__bookmark-icon",width:"31",height:"33",children:v.jsx("use",{xlinkHref:"#icon-bookmark"})}),v.jsx("span",{className:"visually-hidden",children:"To bookmarks"})]})]}),v.jsxs("div",{className:"offer__rating rating",children:[v.jsxs("div",{className:"offer__stars rating__stars",children:[v.jsx("span",{style:{width:`calc(100% / 5 * ${t.rating})`}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]}),v.jsx("span",{className:"offer__rating-value rating__value",children:t.rating})]}),v.jsxs("ul",{className:"offer__features",children:[v.jsx("li",{className:"offer__feature offer__feature--entire",children:t.type}),v.jsxs("li",{className:"offer__feature offer__feature--bedrooms",children:[t.bedrooms," Bedrooms"]}),v.jsxs("li",{className:"offer__feature offer__feature--adults",children:["Max ",t.maxAdults," adults"]})]}),v.jsxs("div",{className:"offer__price",children:[v.jsxs("b",{className:"offer__price-value",children:["€",t.price]}),v.jsx("span",{className:"offer__price-text",children:" night"})]}),v.jsxs("div",{className:"offer__inside",children:[v.jsx("h2",{className:"offer__inside-title",children:"What's inside"}),v.jsx("ul",{className:"offer__inside-list",children:t.goods.map(u=>v.jsx("li",{className:"offer__inside-item",children:u},u))})]}),v.jsxs("div",{className:"offer__host",children:[v.jsx("h2",{className:"offer__host-title",children:"Meet the host"}),v.jsxs("div",{className:"offer__host-user user",children:[v.jsx("div",{className:"offer__avatar-wrapper offer__avatar-wrapper--pro user__avatar-wrapper",children:v.jsx("img",{className:"offer__avatar user__avatar",src:t.host.avatarUrl,width:"74",height:"74",alt:"Host avatar"})}),v.jsx("span",{className:"offer__user-name",children:t.host.name}),v.jsx("span",{className:"offer__user-status",children:t.host.isPro&&"Pro"})]}),v.jsx("div",{className:"offer__description",children:v.jsx("p",{className:"offer__text",children:t.description})})]}),v.jsxs("section",{className:"offer__reviews reviews",children:[v.jsxs("h2",{className:"reviews__title",children:["Reviews · ",v.jsx("span",{className:"reviews__amount",children:i.length})]}),v.jsx(ZT,{reviews:i}),a&&v.jsx($T,{})]})]})}),v.jsx(cg,{city:t.city,offers:n,selectedOffer:void 0})]}),v.jsx("div",{className:"container",children:v.jsxs("section",{className:"near-places places",children:[v.jsx("h2",{className:"near-places__title",children:"Other places in the neighbourhood"}),v.jsx("div",{className:"near-places__list places__list",children:v.jsx(ug,{offers:n,onChange:()=>{}})})]})})]})]})}function VT(){return v.jsxs("div",{className:"page-400",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities: Page Not Found"})}),v.jsxs("div",{className:"page-404",children:[v.jsx("h1",{className:"text-404",children:"404"}),v.jsx("h2",{className:"text-not-found",children:"Page Not Found"}),v.jsx(at,{to:be.Main,className:"back-button",children:"Go back to Home"})]})]})}function KT(e){const{children:t}=e;return St(i=>i.authorizationStatus)===en.Authorized?t:v.jsx(md,{to:be.Login})}function qT(e){const{children:t}=e;return St(i=>i.authorizationStatus)===en.Unauthorized?t:v.jsx(md,{to:be.Main})}function GT(){const t=St(i=>i.offers).filter(i=>i.isFavorite),n=Array.from(new Set(t.map(i=>i.city.name))).sort();return v.jsxs("div",{className:"page",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities: favorites"})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsxs("div",{className:"header__wrapper",children:[v.jsx("div",{className:"header__left",children:v.jsx(at,{className:"header__logo-link",to:be.Main,children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})}),v.jsx("nav",{className:"header__nav",children:v.jsxs("ul",{className:"header__nav-list",children:[v.jsx("li",{className:"header__nav-item user",children:v.jsxs("a",{className:"header__nav-link header__nav-link--profile",href:"#",children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__user-name user__name",children:"Oliver.conner@gmail.com"}),v.jsx("span",{className:"header__favorite-count",children:t.length})]})}),v.jsx("li",{className:"header__nav-item",children:v.jsx("a",{className:"header__nav-link",href:"#",children:v.jsx("span",{className:"header__signout",children:"Sign out"})})})]})})]})})}),v.jsx("main",{className:"page__main page__main--favorites",children:v.jsx("div",{className:"page__favorites-container container",children:v.jsxs("section",{className:"favorites",children:[v.jsx("h1",{className:"favorites__title",children:"Saved listing"}),v.jsx("ul",{className:"favorites__list",children:n.length>0?n.map(i=>v.jsxs("li",{className:"favorites__locations-items",children:[v.jsx("div",{className:"favorites__locations locations locations--current",children:v.jsx("div",{className:"locations__item",children:v.jsx(at,{className:"locations__item-link",to:"#",children:v.jsx("span",{children:i})})})}),v.jsx("div",{className:"favorites__places",children:t.filter(s=>s.city.name===i).map(s=>v.jsxs("article",{className:"favorites__card place-card",children:[s.isPremium&&v.jsx("div",{className:"place-card__mark",children:v.jsx("span",{children:"Premium"})}),v.jsx("div",{className:"favorites__image-wrapper place-card__image-wrapper",children:v.jsx(at,{to:be.Offer.replace(":id",s.id),children:v.jsx("img",{className:"place-card__image",src:s.previewImage,width:"150",height:"110",alt:"Place image"})})}),v.jsxs("div",{className:"favorites__card-info place-card__info",children:[v.jsxs("div",{className:"place-card__price-wrapper",children:[v.jsxs("div",{className:"place-card__price",children:[v.jsxs("b",{className:"place-card__price-value",children:["€",s.price]}),v.jsx("span",{className:"place-card__price-text",children:"/ night"})]}),v.jsxs("button",{className:"place-card__bookmark-button place-card__bookmark-button--active button",type:"button",children:[v.jsx("svg",{className:"place-card__bookmark-icon",width:"18",height:"19",children:v.jsx("use",{xlinkHref:"#icon-bookmark"})}),v.jsx("span",{className:"visually-hidden",children:"In bookmarks"})]})]}),v.jsx("div",{className:"place-card__rating rating",children:v.jsxs("div",{className:"place-card__stars rating__stars",children:[v.jsx("span",{style:{width:`${s.rating/5*100}%`}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]})}),v.jsx("h2",{className:"place-card__name",children:v.jsx(at,{to:be.Offer.replace(":id",s.id),children:s.title})}),v.jsx("p",{className:"place-card__type",children:s.type})]})]},s.id))})]},i)):v.jsx("li",{style:{textAlign:"center",marginTop:"15%",fontSize:"32px"},children:"Nothing yet saved"})})]})})}),v.jsx("footer",{className:"footer container",children:v.jsx("a",{className:"footer__logo-link",href:"main.html",children:v.jsx("img",{className:"footer__logo",src:"img/logo.svg",alt:"6 cities logo",width:"64",height:"33"})})})]})}function QT(){return v.jsx(ni,{children:v.jsx(Ax,{children:v.jsxs(Lx,{children:[v.jsx(Zr,{path:be.Main,element:v.jsx(BT,{})}),v.jsx(Zr,{path:be.Login,element:v.jsx(qT,{children:v.jsx(FT,{})})}),v.jsx(Zr,{path:be.Offer,element:v.jsx(WT,{})}),v.jsx(Zr,{path:be.Favorites,element:v.jsx(KT,{children:v.jsx(GT,{})})}),v.jsx(Zr,{path:"*",element:v.jsx(VT,{})})]})})})}const YT=sc.createRoot(document.getElementById("root"));lt.dispatch(RT());lt.dispatch(IT());YT.render(v.jsx(Gt.StrictMode,{children:v.jsx(dP,{store:lt,children:v.jsx(QT,{})})})); + */var xd=Symbol.for("react.element"),Sd=Symbol.for("react.portal"),fl=Symbol.for("react.fragment"),dl=Symbol.for("react.strict_mode"),hl=Symbol.for("react.profiler"),pl=Symbol.for("react.provider"),ml=Symbol.for("react.context"),aP=Symbol.for("react.server_context"),_l=Symbol.for("react.forward_ref"),vl=Symbol.for("react.suspense"),gl=Symbol.for("react.suspense_list"),yl=Symbol.for("react.memo"),wl=Symbol.for("react.lazy"),lP=Symbol.for("react.offscreen"),Pg;Pg=Symbol.for("react.module.reference");function Ot(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case xd:switch(e=e.type,e){case fl:case hl:case dl:case vl:case gl:return e;default:switch(e=e&&e.$$typeof,e){case aP:case ml:case _l:case wl:case yl:case pl:return e;default:return t}}case Sd:return t}}}fe.ContextConsumer=ml;fe.ContextProvider=pl;fe.Element=xd;fe.ForwardRef=_l;fe.Fragment=fl;fe.Lazy=wl;fe.Memo=yl;fe.Portal=Sd;fe.Profiler=hl;fe.StrictMode=dl;fe.Suspense=vl;fe.SuspenseList=gl;fe.isAsyncMode=function(){return!1};fe.isConcurrentMode=function(){return!1};fe.isContextConsumer=function(e){return Ot(e)===ml};fe.isContextProvider=function(e){return Ot(e)===pl};fe.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===xd};fe.isForwardRef=function(e){return Ot(e)===_l};fe.isFragment=function(e){return Ot(e)===fl};fe.isLazy=function(e){return Ot(e)===wl};fe.isMemo=function(e){return Ot(e)===yl};fe.isPortal=function(e){return Ot(e)===Sd};fe.isProfiler=function(e){return Ot(e)===hl};fe.isStrictMode=function(e){return Ot(e)===dl};fe.isSuspense=function(e){return Ot(e)===vl};fe.isSuspenseList=function(e){return Ot(e)===gl};fe.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===fl||e===hl||e===dl||e===vl||e===gl||e===lP||typeof e=="object"&&e!==null&&(e.$$typeof===wl||e.$$typeof===yl||e.$$typeof===pl||e.$$typeof===ml||e.$$typeof===_l||e.$$typeof===Pg||e.getModuleId!==void 0)};fe.typeOf=Ot;function uP(){const e=VS();let t=null,n=null;return{clear(){t=null,n=null},notify(){e(()=>{let i=t;for(;i;)i.callback(),i=i.next})},get(){let i=[],s=t;for(;s;)i.push(s),s=s.next;return i},subscribe(i){let s=!0,a=n={callback:i,next:null,prev:n};return a.prev?a.prev.next=a:t=a,function(){!s||t===null||(s=!1,a.next?a.next.prev=a.prev:n=a.prev,a.prev?a.prev.next=a.next:t=a.next)}}}}const am={notify(){},get:()=>[]};function cP(e,t){let n,i=am,s=0,a=!1;function u(P){m();const R=i.subscribe(P);let S=!1;return()=>{S||(S=!0,R(),g())}}function f(){i.notify()}function d(){x.onStateChange&&x.onStateChange()}function p(){return a}function m(){s++,n||(n=t?t.addNestedSub(d):e.subscribe(d),i=uP())}function g(){s--,n&&s===0&&(n(),n=void 0,i.clear(),i=am)}function y(){a||(a=!0,m())}function C(){a&&(a=!1,g())}const x={addNestedSub:u,notifyNestedSubs:f,handleChangeWrapper:d,isSubscribed:p,trySubscribe:y,tryUnsubscribe:C,getListeners:()=>i};return x}const fP=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",dP=fP?j.useLayoutEffect:j.useEffect;function hP({store:e,context:t,children:n,serverState:i,stabilityCheck:s="once",noopCheck:a="once"}){const u=j.useMemo(()=>{const p=cP(e);return{store:e,subscription:p,getServerState:i?()=>i:void 0,stabilityCheck:s,noopCheck:a}},[e,i,s,a]),f=j.useMemo(()=>e.getState(),[e]);dP(()=>{const{subscription:p}=u;return p.onStateChange=p.notifyNestedSubs,p.trySubscribe(),f!==e.getState()&&p.notifyNestedSubs(),()=>{p.tryUnsubscribe(),p.onStateChange=void 0}},[u,f]);const d=t||Yn;return j.createElement(d.Provider,{value:u},n)}function Eg(e=Yn){const t=e===Yn?vg:vd(e);return function(){const{store:i}=t();return i}}const pP=Eg();function mP(e=Yn){const t=e===Yn?pP:Eg(e);return function(){return t().dispatch}}const _P=mP();GS(ZS.useSyncExternalStoreWithSelector);WS(qv.unstable_batchedUpdates);const vP=()=>_P(),St=JS;function It(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i3?t.i-4:t.i:Array.isArray(e)?1:Pd(e)?2:Ed(e)?3:0}function ci(e,t){return Mi(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function gP(e,t){return Mi(e)===2?e.get(t):e[t]}function Tg(e,t,n){var i=Mi(e);i===2?e.set(t,n):i===3?e.add(n):e[t]=n}function Cg(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function Pd(e){return EP&&e instanceof Map}function Ed(e){return TP&&e instanceof Set}function dr(e){return e.o||e.t}function Td(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=Lg(e);delete t[_e];for(var n=fi(t),i=0;i1&&(e.set=e.add=e.clear=e.delete=yP),Object.freeze(e),t&&Pr(e,function(n,i){return Cd(i,!0)},!0)),e}function yP(){It(2)}function kd(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function en(e){var t=cf[e];return t||It(18,e),t}function wP(e,t){cf[e]||(cf[e]=t)}function af(){return Do}function Gu(e,t){t&&(en("Patches"),e.u=[],e.s=[],e.v=t)}function Ma(e){lf(e),e.p.forEach(xP),e.p=null}function lf(e){e===Do&&(Do=e.l)}function lm(e){return Do={p:[],l:Do,h:e,m:!0,_:0}}function xP(e){var t=e[_e];t.i===0||t.i===1?t.j():t.g=!0}function Qu(e,t){t._=t.p.length;var n=t.p[0],i=e!==void 0&&e!==n;return t.h.O||en("ES5").S(t,e,i),i?(n[_e].P&&(Ma(t),It(4)),wn(e)&&(e=Ra(t,e),t.l||za(t,e)),t.u&&en("Patches").M(n[_e].t,e,t.u,t.s)):e=Ra(t,n,[]),Ma(t),t.u&&t.v(t.u,t.s),e!==kg?e:void 0}function Ra(e,t,n){if(kd(t))return t;var i=t[_e];if(!i)return Pr(t,function(f,d){return um(e,i,t,f,d,n)},!0),t;if(i.A!==e)return t;if(!i.P)return za(e,i.t,!0),i.t;if(!i.I){i.I=!0,i.A._--;var s=i.i===4||i.i===5?i.o=Td(i.k):i.o,a=s,u=!1;i.i===3&&(a=new Set(s),s.clear(),u=!0),Pr(a,function(f,d){return um(e,i,s,f,d,n,u)}),za(e,s,!1),n&&e.u&&en("Patches").N(i,n,e.u,e.s)}return i.o}function um(e,t,n,i,s,a,u){if(Jn(s)){var f=Ra(e,s,a&&t&&t.i!==3&&!ci(t.R,i)?a.concat(i):void 0);if(Tg(n,i,f),!Jn(f))return;e.m=!1}else u&&n.add(s);if(wn(s)&&!kd(s)){if(!e.h.D&&e._<1)return;Ra(e,s),t&&t.A.l||za(e,s)}}function za(e,t,n){n===void 0&&(n=!1),!e.l&&e.h.D&&e.m&&Cd(t,n)}function Yu(e,t){var n=e[_e];return(n?dr(n):e)[t]}function cm(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var i=Object.getOwnPropertyDescriptor(n,t);if(i)return i;n=Object.getPrototypeOf(n)}}function jn(e){e.P||(e.P=!0,e.l&&jn(e.l))}function Ju(e){e.o||(e.o=Td(e.t))}function uf(e,t,n){var i=Pd(t)?en("MapSet").F(t,n):Ed(t)?en("MapSet").T(t,n):e.O?function(s,a){var u=Array.isArray(s),f={i:u?1:0,A:a?a.A:af(),P:!1,I:!1,R:{},l:a,t:s,k:null,o:null,j:null,C:!1},d=f,p=Bo;u&&(d=[f],p=uo);var m=Proxy.revocable(d,p),g=m.revoke,y=m.proxy;return f.k=y,f.j=g,y}(t,n):en("ES5").J(t,n);return(n?n.A:af()).p.push(i),i}function SP(e){return Jn(e)||It(22,e),function t(n){if(!wn(n))return n;var i,s=n[_e],a=Mi(n);if(s){if(!s.P&&(s.i<4||!en("ES5").K(s)))return s.t;s.I=!0,i=fm(n,a),s.I=!1}else i=fm(n,a);return Pr(i,function(u,f){s&&gP(s.t,u)===f||Tg(i,u,t(f))}),a===3?new Set(i):i}(e)}function fm(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return Td(e)}function PP(){function e(a,u){var f=s[a];return f?f.enumerable=u:s[a]=f={configurable:!0,enumerable:u,get:function(){var d=this[_e];return Bo.get(d,a)},set:function(d){var p=this[_e];Bo.set(p,a,d)}},f}function t(a){for(var u=a.length-1;u>=0;u--){var f=a[u][_e];if(!f.P)switch(f.i){case 5:i(f)&&jn(f);break;case 4:n(f)&&jn(f)}}}function n(a){for(var u=a.t,f=a.k,d=fi(f),p=d.length-1;p>=0;p--){var m=d[p];if(m!==_e){var g=u[m];if(g===void 0&&!ci(u,m))return!0;var y=f[m],C=y&&y[_e];if(C?C.t!==g:!Cg(y,g))return!0}}var x=!!u[_e];return d.length!==fi(u).length+(x?0:1)}function i(a){var u=a.k;if(u.length!==a.t.length)return!0;var f=Object.getOwnPropertyDescriptor(u,u.length-1);if(f&&!f.get)return!0;for(var d=0;d1?S-1:0),T=1;T1?m-1:0),y=1;y=0;s--){var a=i[s];if(a.path.length===0&&a.op==="replace"){n=a.value;break}}s>-1&&(i=i.slice(s+1));var u=en("Patches").$;return Jn(n)?u(n,i):this.produce(n,function(f){return u(f,i)})},e}(),ft=new kP,LP=ft.produce;ft.produceWithPatches.bind(ft);ft.setAutoFreeze.bind(ft);ft.setUseProxies.bind(ft);ft.applyPatches.bind(ft);ft.createDraft.bind(ft);ft.finishDraft.bind(ft);const Og=LP;function Fo(e){"@babel/helpers - typeof";return Fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fo(e)}function OP(e,t){if(Fo(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t||"default");if(Fo(i)!=="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function NP(e){var t=OP(e,"string");return Fo(t)==="symbol"?t:String(t)}function MP(e,t,n){return t=NP(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mm(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,i)}return n}function _m(e){for(var t=1;t"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(Ve(1));return n(Ng)(e,t)}if(typeof e!="function")throw new Error(Ve(2));var s=e,a=t,u=[],f=u,d=!1;function p(){f===u&&(f=u.slice())}function m(){if(d)throw new Error(Ve(3));return a}function g(P){if(typeof P!="function")throw new Error(Ve(4));if(d)throw new Error(Ve(5));var R=!0;return p(),f.push(P),function(){if(R){if(d)throw new Error(Ve(6));R=!1,p();var w=f.indexOf(P);f.splice(w,1),u=null}}}function y(P){if(!RP(P))throw new Error(Ve(7));if(typeof P.type>"u")throw new Error(Ve(8));if(d)throw new Error(Ve(9));try{d=!0,a=s(a,P)}finally{d=!1}for(var R=u=f,S=0;S"u")throw new Error(Ve(12));if(typeof n(void 0,{type:Aa.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(Ve(13))})}function AP(e){for(var t=Object.keys(e),n={},i=0;i"u")throw p&&p.type,new Error(Ve(14));g[C]=R,m=m||R!==P}return m=m||a.length!==Object.keys(d).length,m?g:d}}function ja(){for(var e=arguments.length,t=new Array(e),n=0;n0&&a[a.length-1])&&(p[0]===6||p[0]===2)){n=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]v.jsx("li",{className:"locations__item",children:n.name===e?v.jsx("a",{className:"locations__item-link tabs__item tabs__item--active",children:v.jsx("span",{children:n.name})}):v.jsx("a",{className:"locations__item-link tabs__item",onClick:()=>t(Ag(n)),children:v.jsx("span",{children:n.name})})},n.name))})})}function lE({onSortChange:e}){const[t,n]=j.useState("Popular"),[i,s]=j.useState(!1),a=f=>{n(f),e(f),s(!1)},u=()=>{s(!i)};return v.jsxs("form",{className:"places__sorting",action:"#",method:"get",children:[v.jsx("span",{className:"places__sorting-caption",children:"Sort by"}),v.jsxs("span",{className:"places__sorting-type",tabIndex:0,onClick:u,children:[t,v.jsx("svg",{className:"places__sorting-arrow",width:"7",height:"4",children:v.jsx("use",{xlinkHref:"#icon-arrow-select"})})]}),v.jsx("ul",{className:`places__options places__options--custom ${i?"places__options--opened":""}`,children:SS.map(f=>v.jsx("li",{className:`places__option ${f===t?"places__option--active":""}`,tabIndex:0,onClick:()=>a(f),children:f},f))})]})}const uE={activeCity:ug,offers:[],detailOffer:null,nearOffers:[],reviews:[],authorizationStatus:$t.Unknown},cE=eE(uE,e=>{e.addCase(Ag,(t,n)=>{t.activeCity=n.payload}).addCase(jg,(t,n)=>{t.offers=n.payload}).addCase(xl,(t,n)=>{t.detailOffer=n.payload}).addCase(bg,(t,n)=>{t.nearOffers=n.payload}).addCase(Ig,(t,n)=>{t.reviews=n.payload}).addCase(Pi,(t,n)=>{t.authorizationStatus=n.payload})});function Dg(e,t){return function(){return e.apply(t,arguments)}}const{toString:fE}=Object.prototype,{getPrototypeOf:Nd}=Object,Sl=(e=>t=>{const n=fE.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),tn=e=>(e=e.toLowerCase(),t=>Sl(t)===e),Pl=e=>t=>typeof t===e,{isArray:Ri}=Array,$o=Pl("undefined");function dE(e){return e!==null&&!$o(e)&&e.constructor!==null&&!$o(e.constructor)&&Ct(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Bg=tn("ArrayBuffer");function hE(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Bg(e.buffer),t}const pE=Pl("string"),Ct=Pl("function"),Fg=Pl("number"),El=e=>e!==null&&typeof e=="object",mE=e=>e===!0||e===!1,Xs=e=>{if(Sl(e)!=="object")return!1;const t=Nd(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},_E=tn("Date"),vE=tn("File"),gE=tn("Blob"),yE=tn("FileList"),wE=e=>El(e)&&Ct(e.pipe),xE=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Ct(e.append)&&((t=Sl(e))==="formdata"||t==="object"&&Ct(e.toString)&&e.toString()==="[object FormData]"))},SE=tn("URLSearchParams"),PE=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Go(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let i,s;if(typeof e!="object"&&(e=[e]),Ri(e))for(i=0,s=e.length;i0;)if(s=n[i],t===s.toLowerCase())return s;return null}const Ug=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),Zg=e=>!$o(e)&&e!==Ug;function ff(){const{caseless:e}=Zg(this)&&this||{},t={},n=(i,s)=>{const a=e&&$g(t,s)||s;Xs(t[a])&&Xs(i)?t[a]=ff(t[a],i):Xs(i)?t[a]=ff({},i):Ri(i)?t[a]=i.slice():t[a]=i};for(let i=0,s=arguments.length;i(Go(t,(s,a)=>{n&&Ct(s)?e[a]=Dg(s,n):e[a]=s},{allOwnKeys:i}),e),TE=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),CE=(e,t,n,i)=>{e.prototype=Object.create(t.prototype,i),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},kE=(e,t,n,i)=>{let s,a,u;const f={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),a=s.length;a-- >0;)u=s[a],(!i||i(u,e,t))&&!f[u]&&(t[u]=e[u],f[u]=!0);e=n!==!1&&Nd(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},LE=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const i=e.indexOf(t,n);return i!==-1&&i===n},OE=e=>{if(!e)return null;if(Ri(e))return e;let t=e.length;if(!Fg(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},NE=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Nd(Uint8Array)),ME=(e,t)=>{const i=(e&&e[Symbol.iterator]).call(e);let s;for(;(s=i.next())&&!s.done;){const a=s.value;t.call(e,a[0],a[1])}},RE=(e,t)=>{let n;const i=[];for(;(n=e.exec(t))!==null;)i.push(n);return i},zE=tn("HTMLFormElement"),AE=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,i,s){return i.toUpperCase()+s}),Em=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),jE=tn("RegExp"),Hg=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),i={};Go(n,(s,a)=>{let u;(u=t(s,a,e))!==!1&&(i[a]=u||s)}),Object.defineProperties(e,i)},bE=e=>{Hg(e,(t,n)=>{if(Ct(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const i=e[n];if(Ct(i)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},IE=(e,t)=>{const n={},i=s=>{s.forEach(a=>{n[a]=!0})};return Ri(e)?i(e):i(String(e).split(t)),n},DE=()=>{},BE=(e,t)=>(e=+e,Number.isFinite(e)?e:t),nc="abcdefghijklmnopqrstuvwxyz",Tm="0123456789",Wg={DIGIT:Tm,ALPHA:nc,ALPHA_DIGIT:nc+nc.toUpperCase()+Tm},FE=(e=16,t=Wg.ALPHA_DIGIT)=>{let n="";const{length:i}=t;for(;e--;)n+=t[Math.random()*i|0];return n};function $E(e){return!!(e&&Ct(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const UE=e=>{const t=new Array(10),n=(i,s)=>{if(El(i)){if(t.indexOf(i)>=0)return;if(!("toJSON"in i)){t[s]=i;const a=Ri(i)?[]:{};return Go(i,(u,f)=>{const d=n(u,s+1);!$o(d)&&(a[f]=d)}),t[s]=void 0,a}}return i};return n(e,0)},ZE=tn("AsyncFunction"),HE=e=>e&&(El(e)||Ct(e))&&Ct(e.then)&&Ct(e.catch),M={isArray:Ri,isArrayBuffer:Bg,isBuffer:dE,isFormData:xE,isArrayBufferView:hE,isString:pE,isNumber:Fg,isBoolean:mE,isObject:El,isPlainObject:Xs,isUndefined:$o,isDate:_E,isFile:vE,isBlob:gE,isRegExp:jE,isFunction:Ct,isStream:wE,isURLSearchParams:SE,isTypedArray:NE,isFileList:yE,forEach:Go,merge:ff,extend:EE,trim:PE,stripBOM:TE,inherits:CE,toFlatObject:kE,kindOf:Sl,kindOfTest:tn,endsWith:LE,toArray:OE,forEachEntry:ME,matchAll:RE,isHTMLForm:zE,hasOwnProperty:Em,hasOwnProp:Em,reduceDescriptors:Hg,freezeMethods:bE,toObjectSet:IE,toCamelCase:AE,noop:DE,toFiniteNumber:BE,findKey:$g,global:Ug,isContextDefined:Zg,ALPHABET:Wg,generateString:FE,isSpecCompliantForm:$E,toJSONObject:UE,isAsyncFn:ZE,isThenable:HE};function ee(e,t,n,i,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),i&&(this.request=i),s&&(this.response=s)}M.inherits(ee,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:M.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Vg=ee.prototype,Kg={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Kg[e]={value:e}});Object.defineProperties(ee,Kg);Object.defineProperty(Vg,"isAxiosError",{value:!0});ee.from=(e,t,n,i,s,a)=>{const u=Object.create(Vg);return M.toFlatObject(e,u,function(d){return d!==Error.prototype},f=>f!=="isAxiosError"),ee.call(u,e.message,t,n,i,s),u.cause=e,u.name=e.name,a&&Object.assign(u,a),u};const WE=null;function df(e){return M.isPlainObject(e)||M.isArray(e)}function qg(e){return M.endsWith(e,"[]")?e.slice(0,-2):e}function Cm(e,t,n){return e?e.concat(t).map(function(s,a){return s=qg(s),!n&&a?"["+s+"]":s}).join(n?".":""):t}function VE(e){return M.isArray(e)&&!e.some(df)}const KE=M.toFlatObject(M,{},null,function(t){return/^is[A-Z]/.test(t)});function Tl(e,t,n){if(!M.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=M.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(P,R){return!M.isUndefined(R[P])});const i=n.metaTokens,s=n.visitor||m,a=n.dots,u=n.indexes,d=(n.Blob||typeof Blob<"u"&&Blob)&&M.isSpecCompliantForm(t);if(!M.isFunction(s))throw new TypeError("visitor must be a function");function p(x){if(x===null)return"";if(M.isDate(x))return x.toISOString();if(!d&&M.isBlob(x))throw new ee("Blob is not supported. Use a Buffer instead.");return M.isArrayBuffer(x)||M.isTypedArray(x)?d&&typeof Blob=="function"?new Blob([x]):Buffer.from(x):x}function m(x,P,R){let S=x;if(x&&!R&&typeof x=="object"){if(M.endsWith(P,"{}"))P=i?P:P.slice(0,-2),x=JSON.stringify(x);else if(M.isArray(x)&&VE(x)||(M.isFileList(x)||M.endsWith(P,"[]"))&&(S=M.toArray(x)))return P=qg(P),S.forEach(function(T,N){!(M.isUndefined(T)||T===null)&&t.append(u===!0?Cm([P],N,a):u===null?P:P+"[]",p(T))}),!1}return df(x)?!0:(t.append(Cm(R,P,a),p(x)),!1)}const g=[],y=Object.assign(KE,{defaultVisitor:m,convertValue:p,isVisitable:df});function C(x,P){if(!M.isUndefined(x)){if(g.indexOf(x)!==-1)throw Error("Circular reference detected in "+P.join("."));g.push(x),M.forEach(x,function(S,w){(!(M.isUndefined(S)||S===null)&&s.call(t,S,M.isString(w)?w.trim():w,P,y))===!0&&C(S,P?P.concat(w):[w])}),g.pop()}}if(!M.isObject(e))throw new TypeError("data must be an object");return C(e),t}function km(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(i){return t[i]})}function Md(e,t){this._pairs=[],e&&Tl(e,this,t)}const Gg=Md.prototype;Gg.append=function(t,n){this._pairs.push([t,n])};Gg.toString=function(t){const n=t?function(i){return t.call(this,i,km)}:km;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function qE(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Qg(e,t,n){if(!t)return e;const i=n&&n.encode||qE,s=n&&n.serialize;let a;if(s?a=s(t,n):a=M.isURLSearchParams(t)?t.toString():new Md(t,n).toString(i),a){const u=e.indexOf("#");u!==-1&&(e=e.slice(0,u)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class GE{constructor(){this.handlers=[]}use(t,n,i){return this.handlers.push({fulfilled:t,rejected:n,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){M.forEach(this.handlers,function(i){i!==null&&t(i)})}}const Lm=GE,Yg={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},QE=typeof URLSearchParams<"u"?URLSearchParams:Md,YE=typeof FormData<"u"?FormData:null,JE=typeof Blob<"u"?Blob:null,XE=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),eT=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),Yt={isBrowser:!0,classes:{URLSearchParams:QE,FormData:YE,Blob:JE},isStandardBrowserEnv:XE,isStandardBrowserWebWorkerEnv:eT,protocols:["http","https","file","blob","url","data"]};function tT(e,t){return Tl(e,new Yt.classes.URLSearchParams,Object.assign({visitor:function(n,i,s,a){return Yt.isNode&&M.isBuffer(n)?(this.append(i,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function nT(e){return M.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function rT(e){const t={},n=Object.keys(e);let i;const s=n.length;let a;for(i=0;i=n.length;return u=!u&&M.isArray(s)?s.length:u,d?(M.hasOwnProp(s,u)?s[u]=[s[u],i]:s[u]=i,!f):((!s[u]||!M.isObject(s[u]))&&(s[u]=[]),t(n,i,s[u],a)&&M.isArray(s[u])&&(s[u]=rT(s[u])),!f)}if(M.isFormData(e)&&M.isFunction(e.entries)){const n={};return M.forEachEntry(e,(i,s)=>{t(nT(i),s,n,0)}),n}return null}function iT(e,t,n){if(M.isString(e))try{return(t||JSON.parse)(e),M.trim(e)}catch(i){if(i.name!=="SyntaxError")throw i}return(n||JSON.stringify)(e)}const Rd={transitional:Yg,adapter:["xhr","http"],transformRequest:[function(t,n){const i=n.getContentType()||"",s=i.indexOf("application/json")>-1,a=M.isObject(t);if(a&&M.isHTMLForm(t)&&(t=new FormData(t)),M.isFormData(t))return s&&s?JSON.stringify(Jg(t)):t;if(M.isArrayBuffer(t)||M.isBuffer(t)||M.isStream(t)||M.isFile(t)||M.isBlob(t))return t;if(M.isArrayBufferView(t))return t.buffer;if(M.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let f;if(a){if(i.indexOf("application/x-www-form-urlencoded")>-1)return tT(t,this.formSerializer).toString();if((f=M.isFileList(t))||i.indexOf("multipart/form-data")>-1){const d=this.env&&this.env.FormData;return Tl(f?{"files[]":t}:t,d&&new d,this.formSerializer)}}return a||s?(n.setContentType("application/json",!1),iT(t)):t}],transformResponse:[function(t){const n=this.transitional||Rd.transitional,i=n&&n.forcedJSONParsing,s=this.responseType==="json";if(t&&M.isString(t)&&(i&&!this.responseType||s)){const u=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(t)}catch(f){if(u)throw f.name==="SyntaxError"?ee.from(f,ee.ERR_BAD_RESPONSE,this,null,this.response):f}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Yt.classes.FormData,Blob:Yt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};M.forEach(["delete","get","head","post","put","patch"],e=>{Rd.headers[e]={}});const zd=Rd,oT=M.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),sT=e=>{const t={};let n,i,s;return e&&e.split(` +`).forEach(function(u){s=u.indexOf(":"),n=u.substring(0,s).trim().toLowerCase(),i=u.substring(s+1).trim(),!(!n||t[n]&&oT[n])&&(n==="set-cookie"?t[n]?t[n].push(i):t[n]=[i]:t[n]=t[n]?t[n]+", "+i:i)}),t},Om=Symbol("internals");function io(e){return e&&String(e).trim().toLowerCase()}function ea(e){return e===!1||e==null?e:M.isArray(e)?e.map(ea):String(e)}function aT(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let i;for(;i=n.exec(e);)t[i[1]]=i[2];return t}const lT=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function rc(e,t,n,i,s){if(M.isFunction(i))return i.call(this,t,n);if(s&&(t=n),!!M.isString(t)){if(M.isString(i))return t.indexOf(i)!==-1;if(M.isRegExp(i))return i.test(t)}}function uT(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,i)=>n.toUpperCase()+i)}function cT(e,t){const n=M.toCamelCase(" "+t);["get","set","has"].forEach(i=>{Object.defineProperty(e,i+n,{value:function(s,a,u){return this[i].call(this,t,s,a,u)},configurable:!0})})}class Cl{constructor(t){t&&this.set(t)}set(t,n,i){const s=this;function a(f,d,p){const m=io(d);if(!m)throw new Error("header name must be a non-empty string");const g=M.findKey(s,m);(!g||s[g]===void 0||p===!0||p===void 0&&s[g]!==!1)&&(s[g||d]=ea(f))}const u=(f,d)=>M.forEach(f,(p,m)=>a(p,m,d));return M.isPlainObject(t)||t instanceof this.constructor?u(t,n):M.isString(t)&&(t=t.trim())&&!lT(t)?u(sT(t),n):t!=null&&a(n,t,i),this}get(t,n){if(t=io(t),t){const i=M.findKey(this,t);if(i){const s=this[i];if(!n)return s;if(n===!0)return aT(s);if(M.isFunction(n))return n.call(this,s,i);if(M.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=io(t),t){const i=M.findKey(this,t);return!!(i&&this[i]!==void 0&&(!n||rc(this,this[i],i,n)))}return!1}delete(t,n){const i=this;let s=!1;function a(u){if(u=io(u),u){const f=M.findKey(i,u);f&&(!n||rc(i,i[f],f,n))&&(delete i[f],s=!0)}}return M.isArray(t)?t.forEach(a):a(t),s}clear(t){const n=Object.keys(this);let i=n.length,s=!1;for(;i--;){const a=n[i];(!t||rc(this,this[a],a,t,!0))&&(delete this[a],s=!0)}return s}normalize(t){const n=this,i={};return M.forEach(this,(s,a)=>{const u=M.findKey(i,a);if(u){n[u]=ea(s),delete n[a];return}const f=t?uT(a):String(a).trim();f!==a&&delete n[a],n[f]=ea(s),i[f]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return M.forEach(this,(i,s)=>{i!=null&&i!==!1&&(n[s]=t&&M.isArray(i)?i.join(", "):i)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` +`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const i=new this(t);return n.forEach(s=>i.set(s)),i}static accessor(t){const i=(this[Om]=this[Om]={accessors:{}}).accessors,s=this.prototype;function a(u){const f=io(u);i[f]||(cT(s,u),i[f]=!0)}return M.isArray(t)?t.forEach(a):a(t),this}}Cl.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);M.reduceDescriptors(Cl.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(i){this[n]=i}}});M.freezeMethods(Cl);const mn=Cl;function ic(e,t){const n=this||zd,i=t||n,s=mn.from(i.headers);let a=i.data;return M.forEach(e,function(f){a=f.call(n,a,s.normalize(),t?t.status:void 0)}),s.normalize(),a}function Xg(e){return!!(e&&e.__CANCEL__)}function Qo(e,t,n){ee.call(this,e??"canceled",ee.ERR_CANCELED,t,n),this.name="CanceledError"}M.inherits(Qo,ee,{__CANCEL__:!0});function fT(e,t,n){const i=n.config.validateStatus;!n.status||!i||i(n.status)?e(n):t(new ee("Request failed with status code "+n.status,[ee.ERR_BAD_REQUEST,ee.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const dT=Yt.isStandardBrowserEnv?function(){return{write:function(n,i,s,a,u,f){const d=[];d.push(n+"="+encodeURIComponent(i)),M.isNumber(s)&&d.push("expires="+new Date(s).toGMTString()),M.isString(a)&&d.push("path="+a),M.isString(u)&&d.push("domain="+u),f===!0&&d.push("secure"),document.cookie=d.join("; ")},read:function(n){const i=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return i?decodeURIComponent(i[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function hT(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function pT(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function ey(e,t){return e&&!hT(t)?pT(e,t):t}const mT=Yt.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let i;function s(a){let u=a;return t&&(n.setAttribute("href",u),u=n.href),n.setAttribute("href",u),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return i=s(window.location.href),function(u){const f=M.isString(u)?s(u):u;return f.protocol===i.protocol&&f.host===i.host}}():function(){return function(){return!0}}();function _T(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function vT(e,t){e=e||10;const n=new Array(e),i=new Array(e);let s=0,a=0,u;return t=t!==void 0?t:1e3,function(d){const p=Date.now(),m=i[a];u||(u=p),n[s]=d,i[s]=p;let g=a,y=0;for(;g!==s;)y+=n[g++],g=g%e;if(s=(s+1)%e,s===a&&(a=(a+1)%e),p-u{const a=s.loaded,u=s.lengthComputable?s.total:void 0,f=a-n,d=i(f),p=a<=u;n=a;const m={loaded:a,total:u,progress:u?a/u:void 0,bytes:f,rate:d||void 0,estimated:d&&u&&p?(u-a)/d:void 0,event:s};m[t?"download":"upload"]=!0,e(m)}}const gT=typeof XMLHttpRequest<"u",yT=gT&&function(e){return new Promise(function(n,i){let s=e.data;const a=mn.from(e.headers).normalize(),u=e.responseType;let f;function d(){e.cancelToken&&e.cancelToken.unsubscribe(f),e.signal&&e.signal.removeEventListener("abort",f)}let p;M.isFormData(s)&&(Yt.isStandardBrowserEnv||Yt.isStandardBrowserWebWorkerEnv?a.setContentType(!1):a.getContentType(/^\s*multipart\/form-data/)?M.isString(p=a.getContentType())&&a.setContentType(p.replace(/^\s*(multipart\/form-data);+/,"$1")):a.setContentType("multipart/form-data"));let m=new XMLHttpRequest;if(e.auth){const x=e.auth.username||"",P=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";a.set("Authorization","Basic "+btoa(x+":"+P))}const g=ey(e.baseURL,e.url);m.open(e.method.toUpperCase(),Qg(g,e.params,e.paramsSerializer),!0),m.timeout=e.timeout;function y(){if(!m)return;const x=mn.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),R={data:!u||u==="text"||u==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:x,config:e,request:m};fT(function(w){n(w),d()},function(w){i(w),d()},R),m=null}if("onloadend"in m?m.onloadend=y:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(y)},m.onabort=function(){m&&(i(new ee("Request aborted",ee.ECONNABORTED,e,m)),m=null)},m.onerror=function(){i(new ee("Network Error",ee.ERR_NETWORK,e,m)),m=null},m.ontimeout=function(){let P=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const R=e.transitional||Yg;e.timeoutErrorMessage&&(P=e.timeoutErrorMessage),i(new ee(P,R.clarifyTimeoutError?ee.ETIMEDOUT:ee.ECONNABORTED,e,m)),m=null},Yt.isStandardBrowserEnv){const x=(e.withCredentials||mT(g))&&e.xsrfCookieName&&dT.read(e.xsrfCookieName);x&&a.set(e.xsrfHeaderName,x)}s===void 0&&a.setContentType(null),"setRequestHeader"in m&&M.forEach(a.toJSON(),function(P,R){m.setRequestHeader(R,P)}),M.isUndefined(e.withCredentials)||(m.withCredentials=!!e.withCredentials),u&&u!=="json"&&(m.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&m.addEventListener("progress",Nm(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&m.upload&&m.upload.addEventListener("progress",Nm(e.onUploadProgress)),(e.cancelToken||e.signal)&&(f=x=>{m&&(i(!x||x.type?new Qo(null,e,m):x),m.abort(),m=null)},e.cancelToken&&e.cancelToken.subscribe(f),e.signal&&(e.signal.aborted?f():e.signal.addEventListener("abort",f)));const C=_T(g);if(C&&Yt.protocols.indexOf(C)===-1){i(new ee("Unsupported protocol "+C+":",ee.ERR_BAD_REQUEST,e));return}m.send(s||null)})},hf={http:WE,xhr:yT};M.forEach(hf,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Mm=e=>`- ${e}`,wT=e=>M.isFunction(e)||e===null||e===!1,ty={getAdapter:e=>{e=M.isArray(e)?e:[e];const{length:t}=e;let n,i;const s={};for(let a=0;a`adapter ${f} `+(d===!1?"is not supported by the environment":"is not available in the build"));let u=t?a.length>1?`since : +`+a.map(Mm).join(` +`):" "+Mm(a[0]):"as no adapter specified";throw new ee("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return i},adapters:hf};function oc(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Qo(null,e)}function Rm(e){return oc(e),e.headers=mn.from(e.headers),e.data=ic.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),ty.getAdapter(e.adapter||zd.adapter)(e).then(function(i){return oc(e),i.data=ic.call(e,e.transformResponse,i),i.headers=mn.from(i.headers),i},function(i){return Xg(i)||(oc(e),i&&i.response&&(i.response.data=ic.call(e,e.transformResponse,i.response),i.response.headers=mn.from(i.response.headers))),Promise.reject(i)})}const zm=e=>e instanceof mn?e.toJSON():e;function Ei(e,t){t=t||{};const n={};function i(p,m,g){return M.isPlainObject(p)&&M.isPlainObject(m)?M.merge.call({caseless:g},p,m):M.isPlainObject(m)?M.merge({},m):M.isArray(m)?m.slice():m}function s(p,m,g){if(M.isUndefined(m)){if(!M.isUndefined(p))return i(void 0,p,g)}else return i(p,m,g)}function a(p,m){if(!M.isUndefined(m))return i(void 0,m)}function u(p,m){if(M.isUndefined(m)){if(!M.isUndefined(p))return i(void 0,p)}else return i(void 0,m)}function f(p,m,g){if(g in t)return i(p,m);if(g in e)return i(void 0,p)}const d={url:a,method:a,data:a,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,beforeRedirect:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,responseEncoding:u,validateStatus:f,headers:(p,m)=>s(zm(p),zm(m),!0)};return M.forEach(Object.keys(Object.assign({},e,t)),function(m){const g=d[m]||s,y=g(e[m],t[m],m);M.isUndefined(y)&&g!==f||(n[m]=y)}),n}const ny="1.5.1",Ad={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Ad[e]=function(i){return typeof i===e||"a"+(t<1?"n ":" ")+e}});const Am={};Ad.transitional=function(t,n,i){function s(a,u){return"[Axios v"+ny+"] Transitional option '"+a+"'"+u+(i?". "+i:"")}return(a,u,f)=>{if(t===!1)throw new ee(s(u," has been removed"+(n?" in "+n:"")),ee.ERR_DEPRECATED);return n&&!Am[u]&&(Am[u]=!0,console.warn(s(u," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,u,f):!0}};function xT(e,t,n){if(typeof e!="object")throw new ee("options must be an object",ee.ERR_BAD_OPTION_VALUE);const i=Object.keys(e);let s=i.length;for(;s-- >0;){const a=i[s],u=t[a];if(u){const f=e[a],d=f===void 0||u(f,a,e);if(d!==!0)throw new ee("option "+a+" must be "+d,ee.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ee("Unknown option "+a,ee.ERR_BAD_OPTION)}}const pf={assertOptions:xT,validators:Ad},Nn=pf.validators;class ba{constructor(t){this.defaults=t,this.interceptors={request:new Lm,response:new Lm}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Ei(this.defaults,n);const{transitional:i,paramsSerializer:s,headers:a}=n;i!==void 0&&pf.assertOptions(i,{silentJSONParsing:Nn.transitional(Nn.boolean),forcedJSONParsing:Nn.transitional(Nn.boolean),clarifyTimeoutError:Nn.transitional(Nn.boolean)},!1),s!=null&&(M.isFunction(s)?n.paramsSerializer={serialize:s}:pf.assertOptions(s,{encode:Nn.function,serialize:Nn.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=a&&M.merge(a.common,a[n.method]);a&&M.forEach(["delete","get","head","post","put","patch","common"],x=>{delete a[x]}),n.headers=mn.concat(u,a);const f=[];let d=!0;this.interceptors.request.forEach(function(P){typeof P.runWhen=="function"&&P.runWhen(n)===!1||(d=d&&P.synchronous,f.unshift(P.fulfilled,P.rejected))});const p=[];this.interceptors.response.forEach(function(P){p.push(P.fulfilled,P.rejected)});let m,g=0,y;if(!d){const x=[Rm.bind(this),void 0];for(x.unshift.apply(x,f),x.push.apply(x,p),y=x.length,m=Promise.resolve(n);g{if(!i._listeners)return;let a=i._listeners.length;for(;a-- >0;)i._listeners[a](s);i._listeners=null}),this.promise.then=s=>{let a;const u=new Promise(f=>{i.subscribe(f),a=f}).then(s);return u.cancel=function(){i.unsubscribe(a)},u},t(function(a,u,f){i.reason||(i.reason=new Qo(a,u,f),n(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new jd(function(s){t=s}),cancel:t}}}const ST=jd;function PT(e){return function(n){return e.apply(null,n)}}function ET(e){return M.isObject(e)&&e.isAxiosError===!0}const mf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(mf).forEach(([e,t])=>{mf[t]=e});const TT=mf;function ry(e){const t=new ta(e),n=Dg(ta.prototype.request,t);return M.extend(n,ta.prototype,t,{allOwnKeys:!0}),M.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return ry(Ei(e,s))},n}const Re=ry(zd);Re.Axios=ta;Re.CanceledError=Qo;Re.CancelToken=ST;Re.isCancel=Xg;Re.VERSION=ny;Re.toFormData=Tl;Re.AxiosError=ee;Re.Cancel=Re.CanceledError;Re.all=function(t){return Promise.all(t)};Re.spread=PT;Re.isAxiosError=ET;Re.mergeConfig=Ei;Re.AxiosHeaders=mn;Re.formToJSON=e=>Jg(M.isHTMLForm(e)?new FormData(e):e);Re.getAdapter=ty.getAdapter;Re.HttpStatusCode=TT;Re.default=Re;const CT=Re,bd="six-cities-token",kT=()=>localStorage.getItem(bd)??"",LT=e=>{localStorage.setItem(bd,e)},OT=()=>{localStorage.removeItem(bd)},NT="https://14.design.htmlacademy.pro/six-cities",MT=5e3,RT=()=>{const e=CT.create({baseURL:NT,timeout:MT});return e.interceptors.request.use(t=>{const n=kT();return n&&t.headers&&(t.headers["x-token"]=n),t}),e.interceptors.response.use(t=>t,t=>{throw t.response&&t.response.status===401&&tt.dispatch(Pi($t.Unauthorized)),t.response&&t.response.status===404&&tt.dispatch(xl(void 0)),t}),e},zT=RT(),tt=YP({reducer:cE,middleware:e=>e({thunk:{extraArgument:zT}})}),AT=rr("data/fetchOffers",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(nr.offers);t(jg(i))}),jT=rr("data/fetchDetailOffer",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(`${nr.offers}/${e}`);t(xl(i))}),bT=rr("data/fetchNearOffers",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(`${nr.offers}/${e}/nearby`);t(bg(i))}),iy=rr("data/fetchReviews",async(e,{dispatch:t,extra:n})=>{const{data:i}=await n.get(`${nr.reviews}/${e}`);t(Ig(i))}),IT=rr("data/fetchReviews",async(e,{extra:t})=>{(await t.post(`${nr.reviews}/${e.offerId}`,{comment:e.comment,rating:e.rating})).status===201&&tt.dispatch(iy(e.offerId))}),DT=rr("auth/login",async(e,{dispatch:t,extra:n})=>{const i=await n.post(nr.login,e);if(i.status===200||i.status===201)t(Pi($t.Authorized)),LT(i.data.token);else throw i}),BT=rr("auth/checkAuthorization",async(e,{dispatch:t,extra:n})=>{const i=await n.get(nr.login);i.status===200||i.status===201?t(Pi($t.Authorized)):t(Pi($t.Unauthorized))}),oy=rr("auth/logout",async(e,{dispatch:t,extra:n})=>{await n.delete(nr.logout),OT(),t(Pi($t.Unauthorized))});function FT(){const e=St(C=>C.activeCity),t=St(C=>C.offers).filter(C=>C.city.name===e.name),n=t.filter(C=>C.isFavorite).length,[i,s]=j.useState(null),a=t.find(C=>C.id===i),u=t.length===0?"No places to stay available":`${t.length} places to stay in ${e.name}`,[f,d]=j.useState("Popular"),p=[...t].sort((C,x)=>{switch(f){case"Price: low to high":return C.price-x.price;case"Price: high to low":return x.price-C.price;case"Top rated first":return x.rating-C.rating;default:return 0}}),m=C=>{d(C)},g=St(C=>C.authorizationStatus)===$t.Authorized,y=()=>{tt.dispatch(oy())};return v.jsxs("div",{className:"page page--gray page--main",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities"})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsxs("div",{className:"header__wrapper",children:[v.jsx("div",{className:"header__left",children:v.jsx("a",{className:"header__logo-link header__logo-link--active",children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})}),g?v.jsx("nav",{className:"header__nav",children:v.jsxs("ul",{className:"header__nav-list",children:[v.jsx("li",{className:"header__nav-item user",children:v.jsxs(lt,{className:"header__nav-link header__nav-link--profile",to:be.Favorites,children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__user-name user__name",children:"Oliver.conner@gmail.com"}),v.jsx("span",{className:"header__favorite-count",children:n})]})}),v.jsx("li",{className:"header__nav-item",children:v.jsx("a",{className:"header__nav-link",onClick:y,children:v.jsx("span",{className:"header__signout",children:"Sign out"})})})]})}):v.jsx("nav",{className:"header__nav",children:v.jsx("ul",{className:"header__nav-list",children:v.jsx("li",{className:"header__nav-item user",children:v.jsxs(lt,{className:"header__nav-link header__nav-link--profile",to:be.Login,children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__login",children:"Sign in"})]})})})})]})})}),v.jsxs("main",{className:"page__main page__main--index",children:[v.jsx("h1",{className:"visually-hidden",children:"Cities"}),v.jsx("div",{className:"tabs",children:v.jsx(aE,{activeCity:e.name})}),v.jsx("div",{className:"cities",children:v.jsxs("div",{className:"cities__places-container container",children:[v.jsxs("section",{className:"cities__places places",children:[v.jsx("h2",{className:"visually-hidden",children:"Places"}),v.jsx("b",{className:"places__found",children:u}),v.jsx(lE,{onSortChange:m}),v.jsx(cg,{offers:p,onChange:s})]}),v.jsx("div",{className:"cities__right-section",children:v.jsx(fg,{city:e,offers:t,selectedOffer:a})})]})})]})]})}function $T(){const[e,t]=j.useState({email:"",password:""}),n=i=>{i.preventDefault(),tt.dispatch(DT(e))};return v.jsxs("div",{className:"page page--gray page--login",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities: authorization"})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsx("div",{className:"header__wrapper",children:v.jsx("div",{className:"header__left",children:v.jsx(lt,{className:"header__logo-link",to:be.Main,children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})})})})}),v.jsx("main",{className:"page__main page__main--login",children:v.jsxs("div",{className:"page__login-container container",children:[v.jsxs("section",{className:"login",children:[v.jsx("h1",{className:"login__title",children:"Sign in"}),v.jsxs("form",{className:"login__form form",action:"#",method:"post",children:[v.jsxs("div",{className:"login__input-wrapper form__input-wrapper",children:[v.jsx("label",{className:"visually-hidden",children:"E-mail"}),v.jsx("input",{className:"login__input form__input",type:"email",name:"email",placeholder:"Email",onChange:i=>t({...e,email:i.target.value}),required:!0})]}),v.jsxs("div",{className:"login__input-wrapper form__input-wrapper",children:[v.jsx("label",{className:"visually-hidden",children:"Password"}),v.jsx("input",{className:"login__input form__input",type:"password",name:"password",placeholder:"Password",onChange:i=>t({...e,password:i.target.value}),required:!0})]}),v.jsx("button",{className:"login__submit form__submit button",type:"submit",onClick:n,children:"Sign in"})]})]}),v.jsx("section",{className:"locations locations--login locations--current",children:v.jsx("div",{className:"locations__item",children:v.jsx("a",{className:"locations__item-link",href:"#",children:v.jsx("span",{children:"Amsterdam"})})})})]})})]})}function UT(){const[e,t]=j.useState({review:"",rating:0}),n=St(f=>f.detailOffer).id,i=f=>{f.preventDefault(),tt.dispatch(IT({offerId:n,rating:e.rating,comment:e.review})).then(()=>{t({rating:0,review:""})})},s=e.review.length>=im&&e.review.length<=mS&&e.rating!==null,a=f=>{const{name:d,value:p}=f.target;t({...e,[d]:d==="rating"?Number(p):p})};function u(f,d){return v.jsxs(v.Fragment,{children:[v.jsx("input",{className:"form__rating-input visually-hidden",onChange:a,name:"rating",value:f,id:`${f}-stars`,type:"radio",checked:e.rating===f}),v.jsx("label",{htmlFor:`${f}-stars`,className:"reviews__rating-label form__rating-label",title:d,children:v.jsx("svg",{className:"form__star-image",width:"37",height:"33",children:v.jsx("use",{xlinkHref:"#icon-star"})})})]})}return v.jsxs("form",{className:"reviews__form form",onSubmit:i,children:[v.jsx("label",{className:"reviews__label form__label",htmlFor:"review",children:"Your review"}),v.jsxs("div",{className:"reviews__rating-form form__rating",children:[u(5,"perfect"),u(4,"good"),u(3,"not bad"),u(2,"badly"),u(1,"terribly")]}),v.jsx("textarea",{className:"reviews__textarea form__textarea",onChange:a,value:e.review,id:"review",name:"review",placeholder:"Tell how was your stay, what you like and what can be improved"}),v.jsxs("div",{className:"reviews__button-wrapper",children:[v.jsxs("p",{className:"reviews__help",children:["To submit review please make sure to set ",v.jsx("span",{className:"reviews__star",children:"rating"})," and describe your stay with at least ",v.jsxs("b",{className:"reviews__text-amount",children:[im," characters"]}),"."]}),v.jsx("button",{className:"reviews__submit form__submit button",type:"submit",disabled:!s,children:"Submit"})]})]})}function ZT({review:e}){return v.jsxs("li",{className:"reviews__item",children:[v.jsxs("div",{className:"reviews__user user",children:[v.jsx("div",{className:"reviews__avatar-wrapper user__avatar-wrapper",children:v.jsx("img",{className:"reviews__avatar user__avatar",src:e.user.avatarUrl,width:"54",height:"54",alt:"Reviews avatar"})}),v.jsx("span",{className:"reviews__user-name",children:e.user.name})]}),v.jsxs("div",{className:"reviews__info",children:[v.jsx("div",{className:"reviews__rating rating",children:v.jsxs("div",{className:"reviews__stars rating__stars",children:[v.jsx("span",{style:{width:`calc(100% / 5 * ${e.rating})`}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]})}),v.jsx("p",{className:"reviews__text",children:e.comment}),v.jsx("time",{className:"reviews__time",dateTime:e.date.split("T")[0],children:new Date(e.date).toLocaleDateString("en-US",{month:"long",year:"numeric"})})]})]})}function HT({reviews:e}){return v.jsx("ul",{className:"reviews__list",children:e.map(t=>v.jsx(ZT,{review:t},t.id))})}function WT(){const e="#3069a6",i={display:"flex",justifyContent:"center",alignItems:"center",position:"relative",width:"100vw",height:"100vh",animation:"react-spinners-rotate 2s 0s infinite linear"},s=a=>({position:"relative",top:a%2?"0":"auto",bottom:a%2?"auto":"0",height:`${80/2}px`,width:`${80/2}px`,backgroundColor:e,borderRadius:"100%",animation:`react-spinners-bounce ${2/1}s ${a===2?"1s":"0s"} infinite linear`});return v.jsxs("span",{style:i,children:[v.jsx("span",{style:s(1)}),v.jsx("span",{style:s(2)})]})}function VT(){const{id:e}=mx();j.useEffect(()=>{tt.dispatch(xl(null)),tt.dispatch(jT(e)),tt.dispatch(bT(e)),tt.dispatch(iy(e))},[e]);const t=St(f=>f.detailOffer),n=St(f=>f.nearOffers).slice(0,3),i=St(f=>f.reviews),s=St(f=>f.offers).filter(f=>f.isFavorite).length,a=St(f=>f.authorizationStatus)===$t.Authorized,u=()=>{tt.dispatch(oy())};return t===null?v.jsx(WT,{}):t===void 0?v.jsx(md,{to:"*"}):v.jsxs("div",{className:"page",children:[v.jsx(qn,{children:v.jsxs("title",{children:["6 sities: ",t.title]})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsxs("div",{className:"header__wrapper",children:[v.jsx("div",{className:"header__left",children:v.jsx(lt,{className:"header__logo-link",to:be.Main,children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})}),a?v.jsx("nav",{className:"header__nav",children:v.jsxs("ul",{className:"header__nav-list",children:[v.jsx("li",{className:"header__nav-item user",children:v.jsxs(lt,{className:"header__nav-link header__nav-link--profile",to:be.Favorites,children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__user-name user__name",children:"Oliver.conner@gmail.com"}),v.jsx("span",{className:"header__favorite-count",children:s})]})}),v.jsx("li",{className:"header__nav-item",children:v.jsx("a",{className:"header__nav-link",onClick:u,children:v.jsx("span",{className:"header__signout",children:"Sign out"})})})]})}):v.jsx("nav",{className:"header__nav",children:v.jsx("ul",{className:"header__nav-list",children:v.jsx("li",{className:"header__nav-item user",children:v.jsxs(lt,{className:"header__nav-link header__nav-link--profile",to:be.Login,children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__login",children:"Sign in"})]})})})})]})})}),v.jsxs("main",{className:"page__main page__main--offer",children:[v.jsxs("section",{className:"offer",children:[v.jsx("div",{className:"offer__gallery-container container",children:v.jsx("div",{className:"offer__gallery",children:t.images.map((f,d)=>v.jsx("div",{className:"offer__image-wrapper",children:v.jsx("img",{className:"offer__image",src:f,alt:`Photo ${d+1}`})},f))})}),v.jsx("div",{className:"offer__container container",children:v.jsxs("div",{className:"offer__wrapper",children:[v.jsx("div",{className:"offer__mark",children:v.jsx("span",{children:t.isPremium})}),v.jsxs("div",{className:"offer__name-wrapper",children:[v.jsx("h1",{className:"offer__name",children:t.title}),v.jsxs("button",{className:`offer__bookmark-button ${t.isFavorite&&"offer__bookmark-button--active"} button`,type:"button",children:[v.jsx("svg",{className:"offer__bookmark-icon",width:"31",height:"33",children:v.jsx("use",{xlinkHref:"#icon-bookmark"})}),v.jsx("span",{className:"visually-hidden",children:"To bookmarks"})]})]}),v.jsxs("div",{className:"offer__rating rating",children:[v.jsxs("div",{className:"offer__stars rating__stars",children:[v.jsx("span",{style:{width:`calc(100% / 5 * ${t.rating})`}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]}),v.jsx("span",{className:"offer__rating-value rating__value",children:t.rating})]}),v.jsxs("ul",{className:"offer__features",children:[v.jsx("li",{className:"offer__feature offer__feature--entire",children:t.type}),v.jsxs("li",{className:"offer__feature offer__feature--bedrooms",children:[t.bedrooms," Bedrooms"]}),v.jsxs("li",{className:"offer__feature offer__feature--adults",children:["Max ",t.maxAdults," adults"]})]}),v.jsxs("div",{className:"offer__price",children:[v.jsxs("b",{className:"offer__price-value",children:["€",t.price]}),v.jsx("span",{className:"offer__price-text",children:" night"})]}),v.jsxs("div",{className:"offer__inside",children:[v.jsx("h2",{className:"offer__inside-title",children:"What's inside"}),v.jsx("ul",{className:"offer__inside-list",children:t.goods.map(f=>v.jsx("li",{className:"offer__inside-item",children:f},f))})]}),v.jsxs("div",{className:"offer__host",children:[v.jsx("h2",{className:"offer__host-title",children:"Meet the host"}),v.jsxs("div",{className:"offer__host-user user",children:[v.jsx("div",{className:"offer__avatar-wrapper offer__avatar-wrapper--pro user__avatar-wrapper",children:v.jsx("img",{className:"offer__avatar user__avatar",src:t.host.avatarUrl,width:"74",height:"74",alt:"Host avatar"})}),v.jsx("span",{className:"offer__user-name",children:t.host.name}),v.jsx("span",{className:"offer__user-status",children:t.host.isPro&&"Pro"})]}),v.jsx("div",{className:"offer__description",children:v.jsx("p",{className:"offer__text",children:t.description})})]}),v.jsxs("section",{className:"offer__reviews reviews",children:[v.jsxs("h2",{className:"reviews__title",children:["Reviews · ",v.jsx("span",{className:"reviews__amount",children:i.length})]}),v.jsx(HT,{reviews:i}),a&&v.jsx(UT,{})]})]})}),v.jsx(fg,{city:t.city,offers:n,selectedOffer:void 0})]}),v.jsx("div",{className:"container",children:v.jsxs("section",{className:"near-places places",children:[v.jsx("h2",{className:"near-places__title",children:"Other places in the neighbourhood"}),v.jsx("div",{className:"near-places__list places__list",children:v.jsx(cg,{offers:n,onChange:()=>{}})})]})})]})]})}function KT(){return v.jsxs("div",{className:"page-400",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities: Page Not Found"})}),v.jsxs("div",{className:"page-404",children:[v.jsx("h1",{className:"text-404",children:"404"}),v.jsx("h2",{className:"text-not-found",children:"Page Not Found"}),v.jsx(lt,{to:be.Main,className:"back-button",children:"Go back to Home"})]})]})}function qT(e){const{children:t}=e;return St(i=>i.authorizationStatus)===$t.Authorized?t:v.jsx(md,{to:be.Login})}function GT(e){const{children:t}=e;return St(i=>i.authorizationStatus)===$t.Unauthorized?t:v.jsx(md,{to:be.Main})}function QT(){const t=St(i=>i.offers).filter(i=>i.isFavorite),n=Array.from(new Set(t.map(i=>i.city.name))).sort();return v.jsxs("div",{className:"page",children:[v.jsx(qn,{children:v.jsx("title",{children:"6 sities: favorites"})}),v.jsx("header",{className:"header",children:v.jsx("div",{className:"container",children:v.jsxs("div",{className:"header__wrapper",children:[v.jsx("div",{className:"header__left",children:v.jsx(lt,{className:"header__logo-link",to:be.Main,children:v.jsx("img",{className:"header__logo",src:"img/logo.svg",alt:"6 cities logo",width:"81",height:"41"})})}),v.jsx("nav",{className:"header__nav",children:v.jsxs("ul",{className:"header__nav-list",children:[v.jsx("li",{className:"header__nav-item user",children:v.jsxs("a",{className:"header__nav-link header__nav-link--profile",href:"#",children:[v.jsx("div",{className:"header__avatar-wrapper user__avatar-wrapper"}),v.jsx("span",{className:"header__user-name user__name",children:"Oliver.conner@gmail.com"}),v.jsx("span",{className:"header__favorite-count",children:t.length})]})}),v.jsx("li",{className:"header__nav-item",children:v.jsx("a",{className:"header__nav-link",href:"#",children:v.jsx("span",{className:"header__signout",children:"Sign out"})})})]})})]})})}),v.jsx("main",{className:"page__main page__main--favorites",children:v.jsx("div",{className:"page__favorites-container container",children:v.jsxs("section",{className:"favorites",children:[v.jsx("h1",{className:"favorites__title",children:"Saved listing"}),v.jsx("ul",{className:"favorites__list",children:n.length>0?n.map(i=>v.jsxs("li",{className:"favorites__locations-items",children:[v.jsx("div",{className:"favorites__locations locations locations--current",children:v.jsx("div",{className:"locations__item",children:v.jsx(lt,{className:"locations__item-link",to:"#",children:v.jsx("span",{children:i})})})}),v.jsx("div",{className:"favorites__places",children:t.filter(s=>s.city.name===i).map(s=>v.jsxs("article",{className:"favorites__card place-card",children:[s.isPremium&&v.jsx("div",{className:"place-card__mark",children:v.jsx("span",{children:"Premium"})}),v.jsx("div",{className:"favorites__image-wrapper place-card__image-wrapper",children:v.jsx(lt,{to:be.Offer.replace(":id",s.id),children:v.jsx("img",{className:"place-card__image",src:s.previewImage,width:"150",height:"110",alt:"Place image"})})}),v.jsxs("div",{className:"favorites__card-info place-card__info",children:[v.jsxs("div",{className:"place-card__price-wrapper",children:[v.jsxs("div",{className:"place-card__price",children:[v.jsxs("b",{className:"place-card__price-value",children:["€",s.price]}),v.jsx("span",{className:"place-card__price-text",children:"/ night"})]}),v.jsxs("button",{className:"place-card__bookmark-button place-card__bookmark-button--active button",type:"button",children:[v.jsx("svg",{className:"place-card__bookmark-icon",width:"18",height:"19",children:v.jsx("use",{xlinkHref:"#icon-bookmark"})}),v.jsx("span",{className:"visually-hidden",children:"In bookmarks"})]})]}),v.jsx("div",{className:"place-card__rating rating",children:v.jsxs("div",{className:"place-card__stars rating__stars",children:[v.jsx("span",{style:{width:`${s.rating/5*100}%`}}),v.jsx("span",{className:"visually-hidden",children:"Rating"})]})}),v.jsx("h2",{className:"place-card__name",children:v.jsx(lt,{to:be.Offer.replace(":id",s.id),children:s.title})}),v.jsx("p",{className:"place-card__type",children:s.type})]})]},s.id))})]},i)):v.jsx("li",{style:{textAlign:"center",marginTop:"15%",fontSize:"32px"},children:"Nothing yet saved"})})]})})}),v.jsx("footer",{className:"footer container",children:v.jsx("a",{className:"footer__logo-link",href:"main.html",children:v.jsx("img",{className:"footer__logo",src:"img/logo.svg",alt:"6 cities logo",width:"64",height:"33"})})})]})}function YT(){return v.jsx(ni,{children:v.jsx(jx,{children:v.jsxs(Ox,{children:[v.jsx(Zr,{path:be.Main,element:v.jsx(FT,{})}),v.jsx(Zr,{path:be.Login,element:v.jsx(GT,{children:v.jsx($T,{})})}),v.jsx(Zr,{path:be.Offer,element:v.jsx(VT,{})}),v.jsx(Zr,{path:be.Favorites,element:v.jsx(qT,{children:v.jsx(QT,{})})}),v.jsx(Zr,{path:"*",element:v.jsx(KT,{})})]})})})}const JT=sc.createRoot(document.getElementById("root"));tt.dispatch(AT());tt.dispatch(BT());JT.render(v.jsx(Qt.StrictMode,{children:v.jsx(hP,{store:tt,children:v.jsx(YT,{})})})); diff --git a/11/index.html b/11/index.html index e7e0005..fbcf82f 100644 --- a/11/index.html +++ b/11/index.html @@ -7,7 +7,7 @@ 6 cities - +