@maptiler/geocoding-control
Version:
The Javascript & TypeScript Map Control component for MapTiler Geocoding service. Easy to be integrated into any JavaScript mapping application.
13 lines • 53.5 kB
JavaScript
(function(C,b){typeof exports=="object"&&typeof module<"u"?b(exports):typeof define=="function"&&define.amd?define(["exports"],b):(C=typeof globalThis<"u"?globalThis:C||self,b(C.maptilerGeocoder={}))})(this,function(C){"use strict";var Yn=Object.defineProperty;var Xn=Object.getPrototypeOf;var Jn=Reflect.get;var gi=C=>{throw TypeError(C)};var xn=(C,b,Z)=>b in C?Yn(C,b,{enumerable:!0,configurable:!0,writable:!0,value:Z}):C[b]=Z;var Mt=(C,b,Z)=>xn(C,typeof b!="symbol"?b+"":b,Z),Ct=(C,b,Z)=>b.has(C)||gi("Cannot "+Z);var ae=(C,b,Z)=>(Ct(C,b,"read from private field"),Z?Z.call(C):b.get(C)),Wt=(C,b,Z)=>b.has(C)?gi("Cannot add the same private member more than once"):b instanceof WeakSet?b.add(C):b.set(C,Z),hi=(C,b,Z,Ue)=>(Ct(C,b,"write to private field"),Ue?Ue.call(C,Z):b.set(C,Z),Z),bi=(C,b,Z)=>(Ct(C,b,"access private method"),Z);var vi=(C,b,Z)=>Jn(Xn(C),Z,b);var $,Je,Li;function b(){}function Z(i,e){for(const t in e)i[t]=e[t];return i}function Ue(i){return i()}function Ot(){return Object.create(null)}function de(i){i.forEach(Ue)}function zt(i){return typeof i=="function"}function Ee(i,e){return i!=i?e==e:i!==e||i&&typeof i=="object"||typeof i=="function"}let Ke;function J(i,e){return i===e?!0:(Ke||(Ke=document.createElement("a")),Ke.href=e,i===Ke.href)}function _i(i){return Object.keys(i).length===0}function yi(i,e,t,n){if(i){const r=Rt(i,e,t,n);return i[0](r)}}function Rt(i,e,t,n){return i[1]&&n?Z(t.ctx.slice(),i[1](n(e))):t.ctx}function wi(i,e,t,n){return i[2],e.dirty}function Ei(i,e,t,n,r,l){if(r){const u=Rt(e,t,n,l);i.p(u,r)}}function pi(i){if(i.ctx.length>32){const e=[],t=i.ctx.length/32;for(let n=0;n<t;n++)e[n]=-1;return e}return-1}function Ve(i){return i??""}function M(i,e){i.appendChild(e)}function B(i,e,t){i.insertBefore(e,t||null)}function P(i){i.parentNode&&i.parentNode.removeChild(i)}function z(i){return document.createElement(i)}function fe(i){return document.createElementNS("http://www.w3.org/2000/svg",i)}function Le(i){return document.createTextNode(i)}function ee(){return Le(" ")}function Si(){return Le("")}function V(i,e,t,n){return i.addEventListener(e,t,n),()=>i.removeEventListener(e,t,n)}function ki(i){return function(e){return e.preventDefault(),i.call(this,e)}}function a(i,e,t){t==null?i.removeAttribute(e):i.getAttribute(e)!==t&&i.setAttribute(e,t)}function Ti(i){return Array.from(i.childNodes)}function Ie(i,e){e=""+e,i.data!==e&&(i.data=e)}function Dt(i,e){i.value=e??""}function Ne(i,e,t){i.classList.toggle(e,!!t)}function Ni(i,e,{bubbles:t=!1,cancelable:n=!1}={}){return new CustomEvent(i,{detail:e,bubbles:t,cancelable:n})}let Ae;function Pe(i){Ae=i}function Ut(){if(!Ae)throw new Error("Function called outside component initialization");return Ae}function Mi(i){Ut().$$.on_destroy.push(i)}function It(){const i=Ut();return(e,t,{cancelable:n=!1}={})=>{const r=i.$$.callbacks[e];if(r){const l=Ni(e,t,{cancelable:n});return r.slice().forEach(u=>{u.call(i,l)}),!l.defaultPrevented}return!0}}function Ci(i,e){const t=i.$$.callbacks[e.type];t&&t.slice().forEach(n=>n.call(this,e))}const Me=[],at=[];let Ce=[];const At=[],Wi=Promise.resolve();let lt=!1;function Oi(){lt||(lt=!0,Wi.then(Pt))}function ut(i){Ce.push(i)}const ct=new Set;let We=0;function Pt(){if(We!==0)return;const i=Ae;do{try{for(;We<Me.length;){const e=Me[We];We++,Pe(e),zi(e.$$)}}catch(e){throw Me.length=0,We=0,e}for(Pe(null),Me.length=0,We=0;at.length;)at.pop()();for(let e=0;e<Ce.length;e+=1){const t=Ce[e];ct.has(t)||(ct.add(t),t())}Ce.length=0}while(Me.length);for(;At.length;)At.pop()();lt=!1,ct.clear(),Pe(i)}function zi(i){if(i.fragment!==null){i.update(),de(i.before_update);const e=i.dirty;i.dirty=[-1],i.fragment&&i.fragment.p(i.ctx,e),i.after_update.forEach(ut)}}function Ri(i){const e=[],t=[];Ce.forEach(n=>i.indexOf(n)===-1?e.push(n):t.push(n)),t.forEach(n=>n()),Ce=e}const Ye=new Set;let pe;function Be(){pe={r:0,c:[],p:pe}}function je(){pe.r||de(pe.c),pe=pe.p}function j(i,e){i&&i.i&&(Ye.delete(i),i.i(e))}function Q(i,e,t,n){if(i&&i.o){if(Ye.has(i))return;Ye.add(i),pe.c.push(()=>{Ye.delete(i),n&&(t&&i.d(1),n())}),i.o(e)}else n&&n()}function Bt(i){return(i==null?void 0:i.length)!==void 0?i:Array.from(i)}function Di(i,e){Q(i,1,1,()=>{e.delete(i.key)})}function Ui(i,e,t,n,r,l,u,s,d,c,f,_){let v=i.length,p=l.length,g=v;const k={};for(;g--;)k[i[g].key]=g;const I=[],T=new Map,R=new Map,F=[];for(g=p;g--;){const E=_(r,l,g),y=t(E);let S=u.get(y);S?F.push(()=>S.p(E,e)):(S=c(y,E),S.c()),T.set(y,I[g]=S),y in k&&R.set(y,Math.abs(g-k[y]))}const Y=new Set,O=new Set;function W(E){j(E,1),E.m(s,f),u.set(E.key,E),f=E.first,p--}for(;v&&p;){const E=I[p-1],y=i[v-1],S=E.key,A=y.key;E===y?(f=E.first,v--,p--):T.has(A)?!u.has(S)||Y.has(S)?W(E):O.has(A)?v--:R.get(S)>R.get(A)?(O.add(S),W(E)):(Y.add(A),v--):(d(y,u),v--)}for(;v--;){const E=i[v];T.has(E.key)||d(E,u)}for(;p;)W(I[p-1]);return de(F),I}function _e(i){i&&i.c()}function me(i,e,t){const{fragment:n,after_update:r}=i.$$;n&&n.m(e,t),ut(()=>{const l=i.$$.on_mount.map(Ue).filter(zt);i.$$.on_destroy?i.$$.on_destroy.push(...l):de(l),i.$$.on_mount=[]}),r.forEach(ut)}function ge(i,e){const t=i.$$;t.fragment!==null&&(Ri(t.after_update),de(t.on_destroy),t.fragment&&t.fragment.d(e),t.on_destroy=t.fragment=null,t.ctx=[])}function Ii(i,e){i.$$.dirty[0]===-1&&(Me.push(i),Oi(),i.$$.dirty.fill(0)),i.$$.dirty[e/31|0]|=1<<e%31}function Se(i,e,t,n,r,l,u=null,s=[-1]){const d=Ae;Pe(i);const c=i.$$={fragment:null,ctx:[],props:l,update:b,not_equal:r,bound:Ot(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(e.context||(d?d.$$.context:[])),callbacks:Ot(),dirty:s,skip_bound:!1,root:e.target||d.$$.root};u&&u(c.root);let f=!1;if(c.ctx=t?t(i,e.props||{},(_,v,...p)=>{const g=p.length?p[0]:v;return c.ctx&&r(c.ctx[_],c.ctx[_]=g)&&(!c.skip_bound&&c.bound[_]&&c.bound[_](g),f&&Ii(i,_)),v}):[],c.update(),f=!0,de(c.before_update),c.fragment=n?n(c.ctx):!1,e.target){if(e.hydrate){const _=Ti(e.target);c.fragment&&c.fragment.l(_),_.forEach(P)}else c.fragment&&c.fragment.c();e.intro&&j(i.$$.fragment),me(i,e.target,e.anchor),Pt()}Pe(d)}class ke{constructor(){Mt(this,"$$");Mt(this,"$$set")}$destroy(){ge(this,1),this.$destroy=b}$on(e,t){if(!zt(t))return b;const n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(t),()=>{const r=n.indexOf(t);r!==-1&&n.splice(r,1)}}$set(e){this.$$set&&!_i(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}const Ai="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(Ai);function Pi(i){let e,t;return{c(){e=fe("svg"),t=fe("path"),a(t,"d","M13.12.706a.982.982 0 0 0-1.391 0L6.907 5.517 2.087.696a.982.982 0 1 0-1.391 1.39l4.821 4.821L.696 11.73a.982.982 0 1 0 1.39 1.39l4.821-4.821 4.822 4.821a.982.982 0 1 0 1.39-1.39L8.298 6.908l4.821-4.822a.988.988 0 0 0 0-1.38Z"),a(e,"viewBox","0 0 14 14"),a(e,"width","13"),a(e,"height","13"),a(e,"class","svelte-en2qvf")},m(n,r){B(n,e,r),M(e,t)},p:b,i:b,o:b,d(n){n&&P(e)}}}class jt extends ke{constructor(e){super(),Se(this,e,null,Pi,Ee,{})}}function Bi(i){let e,t;return{c(){e=fe("svg"),t=fe("path"),a(t,"d","M15 0C6.705 0 0 6.705 0 15C0 23.295 6.705 30 15 30C23.295 30 30 23.295 30 15C30 6.705 23.295 0 15 0ZM22.5 20.385L20.385 22.5L15 17.115L9.615 22.5L7.5 20.385L12.885 15L7.5 9.615L9.615 7.5L15 12.885L20.385 7.5L22.5 9.615L17.115 15L22.5 20.385Z"),a(e,"viewBox","0 0 30 30"),a(e,"fill","none"),a(e,"xmlns","http://www.w3.org/2000/svg"),a(e,"class","svelte-d2loi5")},m(n,r){B(n,e,r),M(e,t)},p:b,i:b,o:b,d(n){n&&P(e)}}}class Ft extends ke{constructor(e){super(),Se(this,e,null,Bi,Ee,{})}}function ji(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"area.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"area.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Fi(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"reverse.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"reverse.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Gi(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"poi.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"poi.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Hi(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"postal_code.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"postal_code.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Zi(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"street.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"street.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function qi(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"road.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"road.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Qi(i){let e,t;return{c(){e=z("img"),J(e.src,t=i[3]+"housenumber.svg")||a(e,"src",t),a(e,"alt",i[7]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(n,r){B(n,e,r)},p(n,r){r&8&&!J(e.src,t=n[3]+"housenumber.svg")&&a(e,"src",t),r&128&&a(e,"alt",n[7]),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Ki(i){let e,t,n,r;return{c(){e=z("img"),J(e.src,t=i[5])||a(e,"src",t),a(e,"alt",i[4]),a(e,"title",i[7]),a(e,"class","svelte-w9y5n9")},m(l,u){B(l,e,u),n||(r=V(e,"error",i[14]),n=!0)},p(l,u){u&32&&!J(e.src,t=l[5])&&a(e,"src",t),u&16&&a(e,"alt",l[4]),u&128&&a(e,"title",l[7])},d(l){l&&P(e),n=!1,r()}}}function Vi(i){let e,t;return{c(){e=z("div"),a(e,"class","sprite-icon svelte-w9y5n9"),a(e,"style",t=`
width: ${i[6].width/ne}px;
height: ${i[6].height/ne}px;
background-image: url(${i[3]}sprite${dt}.png);
background-position: -${i[6].x/ne}px -${i[6].y/ne}px;
background-size: ${se.width/ne}px ${se.height/ne}px;
`),a(e,"title",i[7])},m(n,r){B(n,e,r)},p(n,r){r&72&&t!==(t=`
width: ${n[6].width/ne}px;
height: ${n[6].height/ne}px;
background-image: url(${n[3]}sprite${dt}.png);
background-position: -${n[6].x/ne}px -${n[6].y/ne}px;
background-size: ${se.width/ne}px ${se.height/ne}px;
`)&&a(e,"style",t),r&128&&a(e,"title",n[7])},d(n){n&&P(e)}}}function Gt(i){let e,t;return{c(){e=z("span"),t=Le(i[7]),a(e,"class","secondary svelte-w9y5n9")},m(n,r){B(n,e,r),M(e,t)},p(n,r){r&128&&Ie(t,n[7])},d(n){n&&P(e)}}}function Yi(i){let e,t,n,r,l,u,s,d,c,f=(i[8]?i[0].place_name:i[0].place_name.replace(/,.*/,""))+"",_,v,p=i[2]==="always"||i[2]!=="never"&&!i[0].address&&!i[0].id.startsWith("road.")&&!i[0].id.startsWith("address.")&&!i[0].id.startsWith("postal_code.")&&(!i[0].id.startsWith("poi.")||!i[5])&&!i[8],g,k,I=(i[8]?"":i[0].place_name.replace(/[^,]*,?\s*/,""))+"",T,R,F,Y,O,W;function E(L,m){return m&1&&(t=null),m&1&&(n=null),m&1&&(r=null),m&1&&(l=null),se&&L[6]?Vi:L[5]?Ki:L[0].address?Qi:(t==null&&(t=!!L[0].id.startsWith("road.")),t?qi:(n==null&&(n=!!L[0].id.startsWith("address.")),n?Zi:(r==null&&(r=!!L[0].id.startsWith("postal_code.")),r?Hi:(l==null&&(l=!!L[0].id.startsWith("poi.")),l?Gi:L[8]?Fi:ji))))}let y=E(i,-1),S=y(i),A=p&&Gt(i);return{c(){e=z("li"),S.c(),u=ee(),s=z("span"),d=z("span"),c=z("span"),_=Le(f),v=ee(),A&&A.c(),g=ee(),k=z("span"),T=Le(I),a(c,"class","primary svelte-w9y5n9"),a(d,"class","svelte-w9y5n9"),a(k,"class","line2 svelte-w9y5n9"),a(s,"class","texts svelte-w9y5n9"),a(e,"tabindex","-1"),a(e,"role","option"),a(e,"aria-selected",R=i[1]==="selected"),a(e,"aria-checked",F=i[1]==="picked"),a(e,"class",Y=Ve(i[1])+" svelte-w9y5n9")},m(L,m){B(L,e,m),S.m(e,null),M(e,u),M(e,s),M(s,d),M(d,c),M(c,_),M(d,v),A&&A.m(d,null),M(s,g),M(s,k),M(k,T),O||(W=[V(e,"mouseenter",i[13]),V(e,"focus",i[15]),V(e,"click",i[16])],O=!0)},p(L,[m]){y===(y=E(L,m))&&S?S.p(L,m):(S.d(1),S=y(L),S&&(S.c(),S.m(e,u))),m&257&&f!==(f=(L[8]?L[0].place_name:L[0].place_name.replace(/,.*/,""))+"")&&Ie(_,f),m&293&&(p=L[2]==="always"||L[2]!=="never"&&!L[0].address&&!L[0].id.startsWith("road.")&&!L[0].id.startsWith("address.")&&!L[0].id.startsWith("postal_code.")&&(!L[0].id.startsWith("poi.")||!L[5])&&!L[8]),p?A?A.p(L,m):(A=Gt(L),A.c(),A.m(d,null)):A&&(A.d(1),A=null),m&257&&I!==(I=(L[8]?"":L[0].place_name.replace(/[^,]*,?\s*/,""))+"")&&Ie(T,I),m&2&&R!==(R=L[1]==="selected")&&a(e,"aria-selected",R),m&2&&F!==(F=L[1]==="picked")&&a(e,"aria-checked",F),m&2&&Y!==(Y=Ve(L[1])+" svelte-w9y5n9")&&a(e,"class",Y)},i:b,o:b,d(L){L&&P(e),S.d(),A&&A.d(),O=!1,de(W)}}}const Ht=typeof devicePixelRatio>"u"?1:devicePixelRatio>1.25,dt=Ht?"@2x":"",ne=Ht?2:1;let se,Xe;function Xi(i,e,t){let n,r,l,{feature:u}=e,{style:s="default"}=e,{showPlaceType:d}=e,{missingIconsCache:c}=e,{iconsBaseUrl:f}=e;const _=It();let v,p,g,k;function I(){Xe??(Xe=fetch(`${f}sprite${dt}.json`).then(y=>y.json()).then(y=>{se=y}).catch(()=>{se=null}))}function T(){p&&c.add(p),R()}function R(){se!==void 0?F():(I(),Xe==null||Xe.then(F))}function F(){do{if(k--,t(4,v=n==null?void 0:n[k]),t(6,g=v?se==null?void 0:se.icons[v]:void 0),g)break;t(5,p=v?f+v.replace(/ /g,"_")+".svg":void 0)}while(k>-1&&(!p||c.has(p)))}function Y(y){Ci.call(this,i,y)}const O=()=>T(),W=()=>_("select",void 0),E=y=>{document.activeElement!==y.target&&_("select",void 0)};return i.$$set=y=>{"feature"in y&&t(0,u=y.feature),"style"in y&&t(1,s=y.style),"showPlaceType"in y&&t(2,d=y.showPlaceType),"missingIconsCache"in y&&t(11,c=y.missingIconsCache),"iconsBaseUrl"in y&&t(3,f=y.iconsBaseUrl)},i.$$.update=()=>{var y,S,A,L,m;i.$$.dirty&1&&t(12,n=(y=u.properties)==null?void 0:y.categories),i.$$.dirty&1&&t(8,r=u.place_type[0]==="reverse"),i.$$.dirty&1&&t(7,l=((A=(S=u.properties)==null?void 0:S.categories)==null?void 0:A.join(", "))??((m=(L=u.properties)==null?void 0:L.place_type_name)==null?void 0:m[0])??u.place_type[0]),i.$$.dirty&4096&&(k=(n==null?void 0:n.length)??0,R())},[u,s,d,f,v,p,g,l,r,_,T,c,n,Y,O,W,E]}class Ji extends ke{constructor(e){super(),Se(this,e,Xi,Yi,Ee,{feature:0,style:1,showPlaceType:2,missingIconsCache:11,iconsBaseUrl:3})}}function xi(i){let e;return{c(){e=z("div"),e.innerHTML='<svg viewBox="0 0 18 18" width="24" height="24" class="loading-icon svelte-1ocfouu"><path fill="#333" d="M4.4 4.4l.8.8c2.1-2.1 5.5-2.1 7.6 0l.8-.8c-2.5-2.5-6.7-2.5-9.2 0z"></path><path opacity=".1" d="M12.8 12.9c-2.1 2.1-5.5 2.1-7.6 0-2.1-2.1-2.1-5.5 0-7.7l-.8-.8c-2.5 2.5-2.5 6.7 0 9.2s6.6 2.5 9.2 0 2.5-6.6 0-9.2l-.8.8c2.2 2.1 2.2 5.6 0 7.7z"></path></svg>',a(e,"class","svelte-1ocfouu")},m(t,n){B(t,e,n)},p:b,i:b,o:b,d(t){t&&P(e)}}}class $i extends ke{constructor(e){super(),Se(this,e,null,xi,Ee,{})}}function en(i){let e,t;return{c(){e=fe("svg"),t=fe("path"),a(t,"d","M30.003-26.765C13.46-26.765 0-14.158 0 1.337c0 23.286 24.535 42.952 28.39 46.04.24.192.402.316.471.376.323.282.732.424 1.142.424.41 0 .82-.142 1.142-.424.068-.06.231-.183.471-.376 3.856-3.09 28.39-22.754 28.39-46.04 0-15.495-13.46-28.102-30.003-28.102Zm1.757 12.469c4.38 0 7.858 1.052 10.431 3.158 2.595 2.105 3.89 4.913 3.89 8.422 0 2.34-.53 4.362-1.593 6.063-1.063 1.702-3.086 3.616-6.063 5.742-2.042 1.51-3.337 2.659-3.89 3.446-.532.787-.8 1.82-.8 3.096v1.914h-8.449V15.18c0-2.041.434-3.815 1.306-5.325.872-1.51 2.467-3.118 4.785-4.82 2.233-1.594 3.7-2.89 4.402-3.889a5.582 5.582 0 0 0 1.087-3.35c0-1.382-.51-2.435-1.531-3.158-1.02-.723-2.45-1.087-4.28-1.087-3.19 0-6.826 1.047-10.91 3.131l-3.472-6.986c4.742-2.659 9.77-3.992 15.087-3.992Zm-1.88 37.324c1.765 0 3.124.472 4.08 1.408.98.936 1.47 2.276 1.47 4.02 0 1.68-.49 3.007-1.47 3.985-.977.957-2.336 1.435-4.08 1.435-1.787 0-3.171-.465-4.15-1.4-.978-.958-1.47-2.298-1.47-4.02 0-1.787.48-3.14 1.436-4.054.957-.915 2.355-1.374 4.184-1.374Z"),a(e,"viewBox","0 0 60.006 21.412"),a(e,"width","14"),a(e,"height","20"),a(e,"class","svelte-en2qvf")},m(n,r){B(n,e,r),M(e,t)},p:b,i:b,o:b,d(n){n&&P(e)}}}class tn extends ke{constructor(e){super(),Se(this,e,null,en,Ee,{})}}function nn(i){let e,t,n;return{c(){e=fe("svg"),t=fe("circle"),n=fe("path"),a(t,"cx","4.789"),a(t,"cy","4.787"),a(t,"r","3.85"),a(t,"class","svelte-1aq105l"),a(n,"d","M12.063 12.063 7.635 7.635"),a(n,"class","svelte-1aq105l"),a(e,"xmlns","http://www.w3.org/2000/svg"),a(e,"width","13"),a(e,"height","13"),a(e,"viewBox","0 0 13 13"),a(e,"class","svelte-1aq105l")},m(r,l){B(r,e,l),M(e,t),M(e,n)},p:b,i:b,o:b,d(r){r&&P(e)}}}class rn extends ke{constructor(e){super(),Se(this,e,null,nn,Ee,{})}}function sn(i,e,t){const n=e[1],r=e[0],l=n-r;return i===n&&t?i:((i-r)%l+l)%l+r}function Zt(i){const e=[...i];return e[2]<e[0]&&(Math.abs((e[0]+e[2]+360)/2)>Math.abs((e[0]-360+e[2])/2)?e[0]-=360:e[2]+=360),e}let Fe;async function on(i,e,t){const n=i==null?void 0:i.getCenterAndZoom();for(const r of e??[])if(!(n&&(r.minZoom!=null&&r.minZoom>n[0]||r.maxZoom!=null&&r.maxZoom<n[0]))){if(r.type==="fixed")return r.coordinates.join(",");e:if(r.type==="client-geolocation"){if(Fe&&r.cachedLocationExpiry&&Fe.time+r.cachedLocationExpiry>Date.now()){if(!Fe.coords)break e;return Fe.coords}let l;try{return l=await new Promise((u,s)=>{t.signal.addEventListener("abort",()=>{s(Error("aborted"))}),navigator.geolocation.getCurrentPosition(d=>{u([d.coords.longitude,d.coords.latitude].map(c=>c.toFixed(6)).join(","))},d=>{s(d)},r)}),l}catch{}finally{r.cachedLocationExpiry&&(Fe={time:Date.now(),coords:l})}if(t.signal.aborted)return}if(r.type==="server-geolocation")return"ip";if(n&&r.type==="map-center")return n[1].toFixed(6)+","+n[2].toFixed(6)}}const an=/^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([6-9][0-9])\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([6-9][0-9])\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*(EAST|WEST|[EW])?$/i,qt=/^([+-]?[0-8]?[0-9])\s+([0-5]?[0-9]\.\d{3,})[\s,]{1,}([+-]?[0-1]?[0-9]?[0-9])\s+([0-5]?[0-9]\.\d{3,})$/,Qt=/^(NORTH|SOUTH|[NS])?[\s]*([+-]?[0-8]?[0-9](?:[\.,]\d{3,}))[\s]*([•º°]?)[\s]*(NORTH|SOUTH|[NS])?[\s]*[,/;]?[\s]*(EAST|WEST|[EW])?[\s]*([+-]?[0-1]?[0-9]?[0-9](?:[\.,]\d{3,}))[\s]*([•º°]?)[\s]*(EAST|WEST|[EW])?$/i,Kt=/^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*(\.)\s*([0-5]?[0-9])\s*(\.)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*(\.)\s*([0-5]?[0-9])\s*(\.)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(EAST|WEST|[EW])?$/i,Vt=/^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*(D(?:EG)?(?:REES)?)\s*([0-5]?[0-9])\s*(M(?:IN)?(?:UTES)?)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(S(?:EC)?(?:ONDS)?)?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*(D(?:EG)?(?:REES)?)\s*([0-5]?[0-9])\s*(M(?:IN)?(?:UTES)?)\s*((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(S(?:EC)?(?:ONDS)?)\s*(EAST|WEST|[EW])?$/i,Yt=/^(NORTH|SOUTH|[NS])?\s*([+-]?[0-8]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([0-5]?[0-9](?:[\.,]\d{1,})?)?\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*,?((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(''|′′|’’|´´|["″”\.])?\s*(NORTH|SOUTH|[NS])?(?:\s*[,/;]\s*|\s*)(EAST|WEST|[EW])?\s*([+-]?[0-1]?[0-9]?[0-9])\s*([•º°\.:]|D(?:EG)?(?:REES)?)?\s*,?([0-5]?[0-9](?:[\.,]\d{1,})?)?\s*(['′´’\.:]|M(?:IN)?(?:UTES)?)?\s*,?((?:[0-5]?[0-9])(?:[\.,]\d{1,3})?)?\s*(''|′′|´´|’’|["″”\.])?\s*(EAST|WEST|[EW])?$/i;function ln(i){if(!["DMS","DM","DD"].includes(i))throw new Error("invalid format specified");if(this.decimalCoordinates&&this.decimalCoordinates.trim()){const e=this.decimalCoordinates.split(",").map(p=>Number(p.trim())),t=Number(e[0]),n=Number(e[1]),r=Math.abs(t),l=Math.abs(n),u=t>0?"N":"S",s=n>0?"E":"W";let d;i=="DD"&&(d=`${r}° ${u}, ${l}° ${s}`);const c=Math.floor(r),f=Math.floor(l),_=(r-c)*60,v=(l-f)*60;if(i=="DM"){let p=Xt(_,3).toFixed(3).padStart(6,"0"),g=Xt(v,3).toFixed(3).padStart(6,"0");p.endsWith(".000")&&g.endsWith(".000")&&(p=p.replace(/\.000$/,""),g=g.replace(/\.000$/,"")),d=`${c}° ${p}' ${u}, ${f}° ${g}' ${s}`}if(i=="DMS"){const p=Math.floor(_),g=Math.floor(v);let k=((_-p)*60).toFixed(1).padStart(4,"0"),I=((v-g)*60).toFixed(1).padStart(4,"0");const T=p.toString().padStart(2,"0"),R=g.toString().padStart(2,"0");k.endsWith(".0")&&I.endsWith(".0")&&(k=k.replace(/\.0$/,""),I=I.replace(/\.0$/,"")),d=`${c}° ${T}' ${k}" ${u}, ${f}° ${R}' ${I}" ${s}`}return d}else throw new Error("no decimal coordinates to convert")}function Xt(i,e){const t=Math.pow(10,e);return Math.round((i+Number.EPSILON)*t)/t}function ft(i,e){e||(e=5),i=i.replace(/\s+/g," ").trim();let t=null,n=null,r="",l="",u=null,s=[],d=!1;if(an.test(i))throw new Error("invalid coordinate value");if(qt.test(i))if(s=qt.exec(i),d=Ge(s),d)t=Math.abs(s[1])+s[2]/60,Number(s[1])<0&&(t*=-1),n=Math.abs(s[3])+s[4]/60,Number(s[3])<0&&(n*=-1),u="DM";else throw new Error("invalid coordinate format");else if(Qt.test(i))if(s=Qt.exec(i),d=Ge(s),d){if(t=s[2],n=s[6],t.includes(",")&&(t=t.replace(",",".")),n.includes(",")&&(n=n.replace(",",".")),u="DD",Number(Math.round(t))==Number(t))throw new Error("integer only coordinate provided");if(Number(Math.round(n))==Number(n))throw new Error("integer only coordinate provided");s[1]?(r=s[1],l=s[5]):s[4]&&(r=s[4],l=s[8])}else throw new Error("invalid decimal coordinate format");else if(Kt.test(i))if(s=Kt.exec(i),d=Ge(s),d)t=Math.abs(parseInt(s[2])),s[4]&&(t+=s[4]/60,u="DM"),s[6]&&(t+=s[6].replace(",",".")/3600,u="DMS"),parseInt(s[2])<0&&(t=-1*t),n=Math.abs(parseInt(s[9])),s[11]&&(n+=s[11]/60),s[13]&&(n+=s[13].replace(",",".")/3600),parseInt(s[9])<0&&(n=-1*n),s[1]?(r=s[1],l=s[8]):s[7]&&(r=s[7],l=s[14]);else throw new Error("invalid DMS coordinates format");else if(Vt.test(i))if(s=Vt.exec(i),d=Ge(s),d)t=Math.abs(parseInt(s[2])),s[4]&&(t+=s[4]/60,u="DM"),s[6]&&(t+=s[6]/3600,u="DMS"),parseInt(s[2])<0&&(t=-1*t),n=Math.abs(parseInt(s[10])),s[12]&&(n+=s[12]/60),s[14]&&(n+=s[14]/3600),parseInt(s[10])<0&&(n=-1*n),s[1]?(r=s[1],l=s[9]):s[8]&&(r=s[8],l=s[16]);else throw new Error("invalid DMS coordinates format");else if(Yt.test(i)){if(s=Yt.exec(i),d=Ge(s),s.filter(c=>c).length<=5)throw new Error("invalid coordinates format");if(d)t=Math.abs(parseInt(s[2])),s[4]&&(t+=s[4].replace(",",".")/60,u="DM"),s[6]&&(t+=s[6].replace(",",".")/3600,u="DMS"),parseInt(s[2])<0&&(t=-1*t),n=Math.abs(parseInt(s[10])),s[12]&&(n+=s[12].replace(",",".")/60),s[14]&&(n+=s[14].replace(",",".")/3600),parseInt(s[10])<0&&(n=-1*n),s[1]?(r=s[1],l=s[9]):s[8]&&(r=s[8],l=s[16]);else throw new Error("invalid coordinates format")}if(d){if(Math.abs(n)>=180)throw new Error("invalid longitude value");if(Math.abs(t)>=90)throw new Error("invalid latitude value");if(r&&!l||!r&&l)throw new Error("invalid coordinates value");if(r&&r==l)throw new Error("invalid coordinates format");t.toString().includes(",")&&(t=t.replace(",",".")),n.toString().includes(",")&&(n=n.replace(",","."));let c=/S|SOUTH/i;c.test(r)&&t>0&&(t=-1*t),c=/W|WEST/i,c.test(l)&&n>0&&(n=-1*n);const f=s[0].trim();let _,v;const p=/[,/;\u0020]/g,g=f.match(p);if(g==null){const T=Math.floor(i.length/2);_=f.substring(0,T).trim(),v=f.substring(T).trim()}else{let T;g.length%2==1?T=Math.floor(g.length/2):T=g.length/2-1;let R=0;if(T==0)R=f.indexOf(g[0]),_=f.substring(0,R).trim(),v=f.substring(R+1).trim();else{let F=0,Y=0;for(;F<=T;)R=f.indexOf(g[F],Y),Y=R+1,F++;_=f.substring(0,R).trim(),v=f.substring(R+1).trim()}}const k=_.split(".");if(k.length==2&&k[1]==0&&k[1].length!=2)throw new Error("invalid coordinates format");const I=v.split(".");if(I.length==2&&I[1]==0&&I[1].length!=2)throw new Error("invalid coordinates format");if(/^\d+$/.test(_)||/^\d+$/.test(v))throw new Error("degree only coordinate/s provided");return t=Number(Number(t).toFixed(e)),n=Number(Number(n).toFixed(e)),Object.freeze({verbatimCoordinates:f,verbatimLatitude:_,verbatimLongitude:v,decimalLatitude:t,decimalLongitude:n,decimalCoordinates:`${t},${n}`,originalFormat:u,closeEnough:un,toCoordinateFormat:ln})}else throw new Error("coordinates pattern match failed")}function Ge(i){if(!isNaN(i[0]))return!1;const e=[...i];if(e.shift(),e.length%2>0)return!1;const t=/^[-+]?\d+([\.,]\d+)?$/,n=/[eastsouthnorthwest]+/i,r=e.length/2;for(let l=0;l<r;l++){const u=e[l],s=e[l+r],d=t.test(u)&&t.test(s),c=n.test(u)&&n.test(s),f=u==s;if(!(u==null&&s==null)){if(u==null||s==null)return!1;if(d||c||f)continue;return!1}}return!0}function Jt(i,e){const t=Math.abs(i-e);return Number(t.toFixed(6))<=1e-5}function un(i){if(!i)throw new Error("coords must be provided");if(i.includes(",")){const e=i.split(",");if(Number(e[0])==NaN||Number(e[1])==NaN)throw new Error("coords are not valid decimals");return Jt(this.decimalLatitude,Number(e[0]))&&Jt(this.decimalLongitude,e[1])}else throw new Error("coords being tested must be separated by a comma")}const cn=Object.freeze({DMS:"DMS",DM:"DM",DD:"DD"});ft.to=cn;const dn=[{verbatimCoordinates:"40.123, -74.123",verbatimLatitude:"40.123",verbatimLongitude:"-74.123"},{verbatimCoordinates:"40.123° N 74.123° W",verbatimLatitude:"40.123° N",verbatimLongitude:"74.123° W"},{verbatimCoordinates:"40.123° N 74.123° W",verbatimLatitude:"40.123° N",verbatimLongitude:"74.123° W"},{verbatimCoordinates:'40° 7´ 22.8" N 74° 7´ 22.8" W',verbatimLatitude:'40° 7´ 22.8" N',verbatimLongitude:'74° 7´ 22.8" W'},{verbatimCoordinates:"40° 7.38’ , -74° 7.38’",verbatimLatitude:"40° 7.38’",verbatimLongitude:"-74° 7.38’"},{verbatimCoordinates:"N40°7’22.8’’, W74°7’22.8’’",verbatimLatitude:"N40°7’22.8’’",verbatimLongitude:"W74°7’22.8’’"},{verbatimCoordinates:'40°7’22.8"N, 74°7’22.8"W',verbatimLatitude:'40°7’22.8"N',verbatimLongitude:'74°7’22.8"W'},{verbatimCoordinates:`40°7'22.8"N, 74°7'22.8"W`,verbatimLatitude:`40°7'22.8"N`,verbatimLongitude:`74°7'22.8"W`},{verbatimCoordinates:"40 7 22.8, -74 7 22.8",verbatimLatitude:"40 7 22.8",verbatimLongitude:"-74 7 22.8"},{verbatimCoordinates:"40.123 -74.123",verbatimLatitude:"40.123",verbatimLongitude:"-74.123"},{verbatimCoordinates:"40.123°,-74.123°",verbatimLatitude:"40.123°",verbatimLongitude:"-74.123°"},{verbatimCoordinates:"40.123N74.123W",verbatimLatitude:"40.123N",verbatimLongitude:"74.123W"},{verbatimCoordinates:"4007.38N7407.38W",verbatimLatitude:"4007.38N",verbatimLongitude:"7407.38W"},{verbatimCoordinates:'40°7’22.8"N, 74°7’22.8"W',verbatimLatitude:'40°7’22.8"N',verbatimLongitude:'74°7’22.8"W'},{verbatimCoordinates:"400722.8N740722.8W",verbatimLatitude:"400722.8N",verbatimLongitude:"740722.8W"},{verbatimCoordinates:"N 40 7.38 W 74 7.38",verbatimLatitude:"N 40 7.38",verbatimLongitude:"W 74 7.38"},{verbatimCoordinates:"40:7:22.8N 74:7:22.8W",verbatimLatitude:"40:7:22.8N",verbatimLongitude:"74:7:22.8W"},{verbatimCoordinates:"40:7:23N,74:7:23W",verbatimLatitude:"40:7:23N",verbatimLongitude:"74:7:23W",decimalLatitude:40.1230555555,decimalLongitude:-74.1230555555},{verbatimCoordinates:'40°7’23"N 74°7’23"W',verbatimLatitude:'40°7’23"N',verbatimLongitude:'74°7’23"W',decimalLatitude:40.1230555555,decimalLongitude:-74.12305555555555},{verbatimCoordinates:'40°7’23"S 74°7’23"E',verbatimLatitude:'40°7’23"S',verbatimLongitude:'74°7’23"E',decimalLatitude:-40.1230555555,decimalLongitude:74.12305555555555},{verbatimCoordinates:'40°7’23" -74°7’23"',verbatimLatitude:'40°7’23"',verbatimLongitude:'-74°7’23"',decimalLatitude:40.1230555555,decimalLongitude:-74.123055555},{verbatimCoordinates:'40d 7’ 23" N 74d 7’ 23" W',verbatimLatitude:'40d 7’ 23" N',verbatimLongitude:'74d 7’ 23" W',decimalLatitude:40.1230555555,decimalLongitude:-74.123055555},{verbatimCoordinates:"40.123N 74.123W",verbatimLatitude:"40.123N",verbatimLongitude:"74.123W"},{verbatimCoordinates:"40° 7.38, -74° 7.38",verbatimLatitude:"40° 7.38",verbatimLongitude:"-74° 7.38"},{verbatimCoordinates:"40° 7.38, -74° 7.38",verbatimLatitude:"40° 7.38",verbatimLongitude:"-74° 7.38"},{verbatimCoordinates:"40 7 22.8; -74 7 22.8",verbatimLatitude:"40 7 22.8",verbatimLongitude:"-74 7 22.8"}],fn={decimalLatitude:40.123,decimalLongitude:-74.123},mn=[{verbatimCoordinates:`50°4'17.698"south, 14°24'2.826"east`,verbatimLatitude:`50°4'17.698"south`,verbatimLongitude:`14°24'2.826"east`,decimalLatitude:-50.07158277777778,decimalLongitude:14.400785},{verbatimCoordinates:"50d4m17.698S 14d24m2.826E",verbatimLatitude:"50d4m17.698S",verbatimLongitude:"14d24m2.826E",decimalLatitude:-50.07158277777778,decimalLongitude:14.400785},{verbatimCoordinates:"40:26:46N,79:56:55W",verbatimLatitude:"40:26:46N",verbatimLongitude:"79:56:55W",decimalLatitude:40.44611111111111,decimalLongitude:-79.9486111111111},{verbatimCoordinates:"40:26:46.302N 79:56:55.903W",verbatimLatitude:"40:26:46.302N",verbatimLongitude:"79:56:55.903W",decimalLatitude:40.446195,decimalLongitude:-79.94886194444445},{verbatimCoordinates:"40°26′47″N 79°58′36″W",verbatimLatitude:"40°26′47″N",verbatimLongitude:"79°58′36″W",decimalLatitude:40.44638888888889,decimalLongitude:-79.97666666666667},{verbatimCoordinates:"40d 26′ 47″ N 79d 58′ 36″ W",verbatimLatitude:"40d 26′ 47″ N",verbatimLongitude:"79d 58′ 36″ W",decimalLatitude:40.44638888888889,decimalLongitude:-79.97666666666667},{verbatimCoordinates:"40.446195N 79.948862W",verbatimLatitude:"40.446195N",verbatimLongitude:"79.948862W",decimalLatitude:40.446195,decimalLongitude:-79.948862},{verbatimCoordinates:"40,446195° 79,948862°",verbatimLatitude:"40,446195°",verbatimLongitude:"79,948862°",decimalLatitude:40.446195,decimalLongitude:79.948862},{verbatimCoordinates:"40° 26.7717, -79° 56.93172",verbatimLatitude:"40° 26.7717",verbatimLongitude:"-79° 56.93172",decimalLatitude:40.446195,decimalLongitude:-79.948862},{verbatimCoordinates:"40.446195, -79.948862",verbatimLatitude:"40.446195",verbatimLongitude:"-79.948862",decimalLatitude:40.446195,decimalLongitude:-79.948862},{verbatimCoordinates:"40.123256; -74.123256",verbatimLatitude:"40.123256",verbatimLongitude:"-74.123256",decimalLatitude:40.123256,decimalLongitude:-74.123256},{verbatimCoordinates:"18°24S 22°45E",verbatimLatitude:"18°24S",verbatimLongitude:"22°45E",decimalLatitude:-18.4,decimalLongitude:22.75}],gn=[{verbatimCoordinates:"10.432342S 10.6345345E",verbatimLatitude:"10.432342S",verbatimLongitude:"10.6345345E",decimalLatitude:-10.432342,decimalLongitude:10.6345345},{verbatimCoordinates:"10.00S 10.00E",verbatimLatitude:"10.00S",verbatimLongitude:"10.00E",decimalLatitude:-10,decimalLongitude:10},{verbatimCoordinates:"00.00S 01.00E",verbatimLatitude:"00.00S",verbatimLongitude:"01.00E",decimalLatitude:0,decimalLongitude:1},{verbatimCoordinates:"18.24S 22.45E",verbatimLatitude:"18.24S",verbatimLongitude:"22.45E",decimalLatitude:-18.4,decimalLongitude:22.75},{verbatimCoordinates:"27deg 15min 45.2sec S 18deg 32min 53.7sec E",verbatimLatitude:"27deg 15min 45.2sec S",verbatimLongitude:"18deg 32min 53.7sec E",decimalLatitude:-27.262555555555554,decimalLongitude:18.54825},{verbatimCoordinates:"-23.3245° S / 28.2344° E",verbatimLatitude:"-23.3245° S",verbatimLongitude:"28.2344° E",decimalLatitude:-23.3245,decimalLongitude:28.2344},{verbatimCoordinates:"40° 26.7717 -79° 56.93172",verbatimLatitude:"40° 26.7717",verbatimLongitude:"-79° 56.93172",decimalLatitude:40.446195,decimalLongitude:-79.948862},{verbatimCoordinates:"27.15.45S 18.32.53E",verbatimLatitude:"27.15.45S",verbatimLongitude:"18.32.53E",decimalLatitude:-27.2625,decimalLongitude:18.548055},{verbatimCoordinates:"-27.15.45 18.32.53",verbatimLatitude:"-27.15.45",verbatimLongitude:"18.32.53",decimalLatitude:-27.2625,decimalLongitude:18.548055},{verbatimCoordinates:"27.15.45.2S 18.32.53.4E",verbatimLatitude:"27.15.45.2S",verbatimLongitude:"18.32.53.4E",decimalLatitude:-27.262556,decimalLongitude:18.548167},{verbatimCoordinates:"27.15.45,2S 18.32.53,4E",verbatimLatitude:"27.15.45,2S",verbatimLongitude:"18.32.53,4E",decimalLatitude:-27.262556,decimalLongitude:18.548167},{verbatimCoordinates:"S23.43563 ° E22.45634 °",verbatimLatitude:"S23.43563 °",verbatimLongitude:"E22.45634 °",decimalLatitude:-23.43563,decimalLongitude:22.45634},{verbatimCoordinates:"27,71372° S 23,07771° E",verbatimLatitude:"27,71372° S",verbatimLongitude:"23,07771° E",decimalLatitude:-27.71372,decimalLongitude:23.07771},{verbatimCoordinates:"27.45.34 S 23.23.23 E",verbatimLatitude:"27.45.34 S",verbatimLongitude:"23.23.23 E",decimalLatitude:-27.759444,decimalLongitude:23.38972222},{verbatimCoordinates:"S 27.45.34 E 23.23.23",verbatimLatitude:"S 27.45.34",verbatimLongitude:"E 23.23.23",decimalLatitude:-27.759444,decimalLongitude:23.38972222},{verbatimCoordinates:"53 16.3863,4 52.8171",verbatimLatitude:"53 16.3863",verbatimLongitude:"4 52.8171",decimalLatitude:53.273105,decimalLongitude:4.88029},{verbatimCoordinates:"50 8.2914,-5 2.4447",verbatimLatitude:"50 8.2914",verbatimLongitude:"-5 2.4447",decimalLatitude:50.13819,decimalLongitude:-5.040745},{verbatimCoordinates:"N 48° 30,6410', E 18° 57,4583'",verbatimLatitude:"N 48° 30,6410'",verbatimLongitude:"E 18° 57,4583'",decimalLatitude:48.51068,decimalLongitude:18.95764},{verbatimCoordinates:"1.23456, 18.33453",verbatimLatitude:"1.23456",verbatimLongitude:"18.33453",decimalLatitude:1.23456,decimalLongitude:18.33453}];function hn(){const i=[];return dn.forEach(e=>{e.decimalLatitude?i.push(e):i.push({...e,...fn})}),[...i,...mn,...gn]}const bn=hn();ft.formats=bn.map(i=>i.verbatimCoordinates);const vn=ft;function xt(i,e,t){const n=i.slice();return n[97]=e[t],n[99]=t,n}function $t(i){let e,t,n,r,l;return t=new jt({}),{c(){e=z("button"),_e(t.$$.fragment),a(e,"type","button"),a(e,"title",i[3]),a(e,"class","svelte-bz0zu3")},m(u,s){B(u,e,s),me(t,e,null),n=!0,r||(l=V(e,"click",i[78]),r=!0)},p(u,s){(!n||s[0]&8)&&a(e,"title",u[3])},i(u){n||(j(t.$$.fragment,u),n=!0)},o(u){Q(t.$$.fragment,u),n=!1},d(u){u&&P(e),ge(t),r=!1,l()}}}function ei(i){let e,t;return e=new $i({}),{c(){_e(e.$$.fragment)},m(n,r){me(e,n,r),t=!0},i(n){t||(j(e.$$.fragment,n),t=!0)},o(n){Q(e.$$.fragment,n),t=!1},d(n){ge(e,n)}}}function ti(i){let e,t,n,r,l;return t=new tn({}),{c(){e=z("button"),_e(t.$$.fragment),a(e,"type","button"),a(e,"title",i[10]),a(e,"class","svelte-bz0zu3"),Ne(e,"active",i[0])},m(u,s){B(u,e,s),me(t,e,null),n=!0,r||(l=V(e,"click",i[79]),r=!0)},p(u,s){(!n||s[0]&1024)&&a(e,"title",u[10]),(!n||s[0]&1)&&Ne(e,"active",u[0])},i(u){n||(j(t.$$.fragment,u),n=!0)},o(u){Q(t.$$.fragment,u),n=!1},d(u){u&&P(e),ge(t),r=!1,l()}}}function Ln(i){let e,t=[],n=new Map,r,l,u,s=Bt(i[13]);const d=c=>c[97].id+(c[97].address?","+c[97].address:"");for(let c=0;c<s.length;c+=1){let f=xt(i,s,c),_=d(f);n.set(_,t[c]=ii(_,f))}return{c(){e=z("ul");for(let c=0;c<t.length;c+=1)t[c].c();a(e,"class","options svelte-bz0zu3"),a(e,"role","listbox")},m(c,f){B(c,e,f);for(let _=0;_<t.length;_+=1)t[_]&&t[_].m(e,null);r=!0,l||(u=[V(e,"mouseleave",i[27]),V(e,"blur",i[83]),V(e,"keydown",i[23])],l=!0)},p(c,f){f[0]&102823936&&(s=Bt(c[13]),Be(),t=Ui(t,f,d,1,c,s,n,e,Di,ii,null,xt),je())},i(c){if(!r){for(let f=0;f<s.length;f+=1)j(t[f]);r=!0}},o(c){for(let f=0;f<t.length;f+=1)Q(t[f]);r=!1},d(c){c&&P(e);for(let f=0;f<t.length;f+=1)t[f].d();l=!1,de(u)}}}function _n(i){let e,t,n,r,l,u;return t=new Ft({}),{c(){e=z("div"),_e(t.$$.fragment),n=ee(),r=z("div"),l=Le(i[8]),a(r,"class","svelte-bz0zu3"),a(e,"class","no-results svelte-bz0zu3")},m(s,d){B(s,e,d),me(t,e,null),M(e,n),M(e,r),M(r,l),u=!0},p(s,d){(!u||d[0]&256)&&Ie(l,s[8])},i(s){u||(j(t.$$.fragment,s),u=!0)},o(s){Q(t.$$.fragment,s),u=!1},d(s){s&&P(e),ge(t)}}}function yn(i){let e="",t;return{c(){t=Le(e)},m(n,r){B(n,t,r)},p:b,i:b,o:b,d(n){n&&P(t)}}}function wn(i){let e,t,n,r,l,u,s,d,c,f,_;return t=new Ft({}),d=new jt({}),{c(){e=z("div"),_e(t.$$.fragment),n=ee(),r=z("div"),l=Le(i[7]),u=ee(),s=z("button"),_e(d.$$.fragment),a(r,"class","svelte-bz0zu3"),a(s,"class","svelte-bz0zu3"),a(e,"class","error svelte-bz0zu3")},m(v,p){B(v,e,p),me(t,e,null),M(e,n),M(e,r),M(r,l),M(e,u),M(e,s),me(d,s,null),c=!0,f||(_=V(s,"click",i[80]),f=!0)},p(v,p){(!c||p[0]&128)&&Ie(l,v[7])},i(v){c||(j(t.$$.fragment,v),j(d.$$.fragment,v),c=!0)},o(v){Q(t.$$.fragment,v),Q(d.$$.fragment,v),c=!1},d(v){v&&P(e),ge(t),ge(d),f=!1,_()}}}function ii(i,e){var s;let t,n,r;function l(){return e[81](e[99])}function u(){return e[82](e[97])}return n=new Ji({props:{feature:e[97],showPlaceType:e[11],style:e[15]===e[99]?"selected":((s=e[14])==null?void 0:s.id)===e[97].id?"picked":"default",missingIconsCache:e[21],iconsBaseUrl:e[12]}}),n.$on("mouseenter",l),n.$on("select",u),{key:i,first:null,c(){t=Si(),_e(n.$$.fragment),this.first=t},m(d,c){B(d,t,c),me(n,d,c),r=!0},p(d,c){var _;e=d;const f={};c[0]&8192&&(f.feature=e[97]),c[0]&2048&&(f.showPlaceType=e[11]),c[0]&57344&&(f.style=e[15]===e[99]?"selected":((_=e[14])==null?void 0:_.id)===e[97].id?"picked":"default"),c[0]&4096&&(f.iconsBaseUrl=e[12]),n.$set(f)},i(d){r||(j(n.$$.fragment,d),r=!0)},o(d){Q(n.$$.fragment,d),r=!1},d(d){d&&P(t),ge(n,d)}}}function En(i){let e,t,n,r,l,u,s,d,c,f,_,v,p,g,k,I,T,R,F,Y=!1;l=new rn({});let O=!i[20]&&$t(i),W=i[20]&&ei(),E=i[6]==="button"&&ti(i);const y=i[70].default,S=yi(y,i,i[69],null),A=[wn,yn,_n,Ln],L=[];function m(w,H){var he,Oe;return w[19]?0:!w[16]&&!w[4]?1:((he=w[13])==null?void 0:he.length)===0?2:(Oe=w[13])!=null&&Oe.length&&(w[16]||w[4])?3:-1}return~(g=m(i))&&(k=L[g]=A[g](i)),{c(){e=ee(),t=z("form"),n=z("div"),r=z("button"),_e(l.$$.fragment),u=ee(),s=z("input"),d=ee(),c=z("div"),O&&O.c(),f=ee(),W&&W.c(),_=ee(),E&&E.c(),v=ee(),S&&S.c(),p=ee(),k&&k.c(),a(r,"class","search-button svelte-bz0zu3"),a(r,"type","button"),a(s,"placeholder",i[9]),a(s,"aria-label",i[9]),a(s,"class","svelte-bz0zu3"),a(c,"class","clear-button-container svelte-bz0zu3"),Ne(c,"displayable",i[1]!==""),a(n,"class","input-group svelte-bz0zu3"),a(t,"class",I=Ve(i[2])+" svelte-bz0zu3"),Ne(t,"can-collapse",i[5]&&i[1]==="")},m(w,H){B(w,e,H),B(w,t,H),M(t,n),M(n,r),me(l,r,null),M(n,u),M(n,s),i[72](s),Dt(s,i[1]),M(n,d),M(n,c),O&&O.m(c,null),M(c,f),W&&W.m(c,null),M(n,_),E&&E.m(n,null),M(n,v),S&&S.m(n,null),M(t,p),~g&&L[g].m(t,null),T=!0,R||(F=[V(r,"click",i[71]),V(s,"input",i[73]),V(s,"focus",i[74]),V(s,"blur",i[75]),V(s,"click",i[76]),V(s,"keydown",i[23]),V(s,"input",i[24]),V(s,"change",i[77]),V(t,"submit",ki(i[22]))],R=!0)},p(w,H){(!T||H[0]&512)&&a(s,"placeholder",w[9]),(!T||H[0]&512)&&a(s,"aria-label",w[9]),H[0]&2&&s.value!==w[1]&&Dt(s,w[1]),w[20]?O&&(Be(),Q(O,1,1,()=>{O=null}),je()):O?(O.p(w,H),H[0]&1048576&&j(O,1)):(O=$t(w),O.c(),j(O,1),O.m(c,f)),w[20]?W?H[0]&1048576&&j(W,1):(W=ei(),W.c(),j(W,1),W.m(c,null)):W&&(Be(),Q(W,1,1,()=>{W=null}),je()),(!T||H[0]&2)&&Ne(c,"displayable",w[1]!==""),w[6]==="button"?E?(E.p(w,H),H[0]&64&&j(E,1)):(E=ti(w),E.c(),j(E,1),E.m(n,v)):E&&(Be(),Q(E,1,1,()=>{E=null}),je()),S&&S.p&&(!T||H[2]&128)&&Ei(S,y,w,w[69],T?wi(y,w[69],H,null):pi(w[69]),null);let he=g;g=m(w),g===he?~g&&L[g].p(w,H):(k&&(Be(),Q(L[he],1,1,()=>{L[he]=null}),je()),~g?(k=L[g],k?k.p(w,H):(k=L[g]=A[g](w),k.c()),j(k,1),k.m(t,null)):k=null),(!T||H[0]&4&&I!==(I=Ve(w[2])+" svelte-bz0zu3"))&&a(t,"class",I),(!T||H[0]&38)&&Ne(t,"can-collapse",w[5]&&w[1]==="")},i(w){T||(j(Y),j(l.$$.fragment,w),j(O),j(W),j(E),j(S,w),j(k),T=!0)},o(w){Q(Y),Q(l.$$.fragment,w),Q(O),Q(W),Q(E),Q(S,w),Q(k),T=!1},d(w){w&&(P(e),P(t)),ge(l),i[72](null),O&&O.d(),W&&W.d(),E&&E.d(),S&&S.d(w),~g&&L[g].d(),R=!1,de(F)}}}function pn(i,e,t){let n,r,l,{$$slots:u={},$$scope:s}=e;const d={continental_marine:4,country:4,major_landform:8,region:5,subregion:6,county:7,joint_municipality:8,joint_submunicipality:9,municipality:10,municipal_district:11,locality:12,neighbourhood:13,place:14,postal_code:14,road:16,poi:17,address:18,"poi.peak":15,"poi.shop":18,"poi.cafe":18,"poi.restaurant":18,"poi.aerodrome":13};let{class:c=void 0}=e,{apiKey:f=void 0}=e,{bbox:_=void 0}=e,{clearButtonTitle:v="clear"}=e,{clearOnBlur:p=!1}=e,{clearListOnPick:g=!1}=e,{keepListOpen:k=!1}=e,{collapsed:I=!1}=e,{country:T=void 0}=e,{debounceSearch:R=200}=e,{enableReverse:F="never"}=e,{errorMessage:Y="Something went wrong…"}=e,{filter:O=()=>!0}=e,{flyTo:W=!0}=e,{fuzzyMatch:E=!0}=e,{language:y=void 0}=e,{limit:S=void 0}=e;const A=41415112612;let{reverseGeocodingLimit:L=A}=e,{mapController:m=void 0}=e,{minLength:w=2}=e,{noResultsMessage:H="Oops! Looks like you're trying to predict something that's not quite right. We can't seem to find what you're looking for. Maybe try double-checking your spelling or try a different search term. Keep on typing - we'll do our best to get you where you need to go!"}=e,{placeholder:he="Search"}=e,{proximity:Oe=[{type:"server-geolocation"}]}=e,{reverseActive:be=F==="always"}=e,{reverseButtonTitle:ni="toggle reverse geocoding"}=e,{searchValue:X=""}=e,{pickedResultStyle:xe="full-geometry"}=e,{showPlaceType:ri="if-needed"}=e,{showResultsWhileTyping:$e=!0}=e,{selectFirst:ze=!0}=e,{flyToSelected:et=!1}=e,{markerOnSelected:tt=!0}=e,{types:ht=void 0}=e;const si=[];let{reverseGeocodingTypes:it=si}=e,{exhaustiveReverseGeocoding:bt=!1}=e,{excludeTypes:vt=!1}=e;const oi=void 0;let{reverseGeocodingExcludeTypes:nt=oi}=e,{zoom:rt=d}=e,{apiUrl:Lt="https://api.maptiler.com/geocoding"}=e,{fetchParameters:_t={}}=e,{iconsBaseUrl:ai="https://cdn.maptiler.com/maptiler-geocoding-control/v2.1.7/icons/"}=e,{adjustUrlQuery:yt=()=>{}}=e,{adjustUrl:wt=()=>{}}=e;function Tn(o){oe.focus(o)}function Nn(){oe.blur()}function li(o,G=!0,q=!1){t(1,X=o),G?(t(15,D=-1),ci()):(di(void 0,!q,q),setTimeout(()=>{oe.focus(),oe.select()}))}function Mn(){t(13,N=void 0),t(14,h=void 0),t(15,D=-1)}function Cn(){t(64,K=[]),t(14,h=void 0)}let N,K,h,ui="",oe,D=-1,le,st=[],Te,Re,De,Et,ve=!1;const Wn=new Set,ye=It();Mi(()=>{m&&(m.setEventHandler(void 0),m.indicateReverse(!1),m.setSelectedMarker(-1),m.setFeatures(void 0,void 0,!1))});function ci(o){if(t(17,ve=!1),Re&&(clearTimeout(Re),Re=void 0),D>-1&&N)t(14,h=N[D]),t(1,X=h.place_type[0]==="reverse"?h.place_name:h.place_name.replace(/,.*/,"")),t(19,le=void 0),t(64,K=void 0),t(15,D=-1);else if(X){const G=o||!pt(X);St(X,{exact:!0}).then(()=>{t(64,K=N),t(14,h=void 0),G&&On()}).catch(q=>t(19,le=q))}}function pt(o){try{return vn(o,6)}catch{return!1}}async function St(o,{byId:G=!1,exact:q=!1}={}){var ie,ue,we;t(19,le=void 0),Te==null||Te.abort();const te=new AbortController;t(20,Te=te);try{const U=pt(o),Ze=new URL(Lt+"/"+encodeURIComponent(U?U.decimalLongitude+","+U.decimalLatitude:o)+".json"),re=Ze.searchParams;y!==void 0&&re.set("language",Array.isArray(y)?y.join(","):y??"");const[Nt]=(m==null?void 0:m.getCenterAndZoom())??[];let ce=(ie=!U||it===si?ht:it)==null?void 0:ie.map(x=>typeof x=="string"?x:Nt===void 0||(x[0]??0)<=Nt&&Nt<(x[1]??1/0)?x[2]:void 0).filter(x=>x!==void 0);ce&&(ce=[...new Set(ce)],re.set("types",ce.join(",")));const mi=!U||nt===oi?vt:nt;if(mi&&re.set("excludeTypes",String(mi)),_&&re.set("bbox",_.map(x=>x.toFixed(6)).join(",")),T&&re.set("country",Array.isArray(T)?T.join(","):T),!G&&!U){const x=await on(m,Oe,te);x&&re.set("proximity",x),(q||!$e)&&re.set("autocomplete","false"),re.set("fuzzyMatch",String(E))}const qe=L===A?S:L;qe!==void 0&&qe>1&&(ce==null?void 0:ce.length)!==1&&console.warn("For reverse geocoding when limit > 1 then types must contain single value."),U?(qe===1||qe!==void 0&&(bt||(ce==null?void 0:ce.length)===1))&&re.set("limit",String(qe)):S!==void 0&&re.set("limit",String(S)),f&&re.set("key",f),yt(re),wt(Ze);const Vn=Ze.searchParams.get("types")===""&&Ze.searchParams.get("excludeTypes")!=="true",ot=Ze.toString();if(ot===ui){G?(g&&t(13,N=void 0),t(14,h=st[0])):(t(13,N=st),((ue=N[D])==null?void 0:ue.id)!==(r==null?void 0:r.id)&&t(15,D=-1));return}ui=ot;let Qe;if(Vn)Qe={type:"FeatureCollection",features:[]};else{const x=await fetch(ot,{signal:te.signal,..._t});if(!x.ok)throw new Error(await x.text());Qe=await x.json()}ye("response",{url:ot,featureCollection:Qe}),G?(g&&t(13,N=void 0),t(14,h=Qe.features[0]),st=[h]):(t(13,N=Qe.features.filter(O)),U&&N.unshift({type:"Feature",properties:{},id:"reverse_"+U.decimalLongitude+"_"+U.decimalLatitude,text:U.decimalLatitude+", "+U.decimalLongitude,place_name:U.decimalLatitude+", "+U.decimalLongitude,place_type:["reverse"],center:[U.decimalLongitude,U.decimalLatitude],bbox:[U.decimalLongitude,U.decimalLatitude,U.decimalLongitude,U.decimalLatitude],geometry:{type:"Point",coordinates:[U.decimalLongitude,U.decimalLatitude]}}),st=N,((we=N[D])==null?void 0:we.id)!==(r==null?void 0:r.id)&&t(15,D=-1),U&&oe.focus())}catch(U){if(U&&typeof U=="object"&&"name"in U&&U.name==="AbortError")return;throw U}finally{te===Te&&t(20,Te=void 0)}}function On(){var te;if(!(K!=null&&K.length)||!W)return;const o=[180,90,-180,-90],G=!K.some(ie=>!ie.matching_text);let q;for(const ie of K){const ue=He(ie);if(q=q===void 0?ue:ue===void 0?q:Math.max(q,ue),G||!ie.matching_text)for(const we of[0,1,2,3])o[we]=Math[we<2?"min":"max"](o[we],((te=ie.bbox)==null?void 0:te[we])??ie.center[we%2])}m&&K.length>0&&(h&&o[0]===o[2]&&o[1]===o[3]?m.flyTo(h.center,He(h)):m.fitBounds(Zt(o),50,q))}function kt(){!h||!m||(!h.bbox||h.bbox[0]===h.bbox[2]&&h.bbox[1]===h.bbox[3]?m.flyTo(h.center,He(h)):m.fitBounds(Zt(h.bbox),50,He(h)))}function He(o){var q;if(!o.bbox||o.bbox[0]!==o.bbox[2]&&o.bbox[1]!==o.bbox[3])return;const G=o.id.replace(/\..*/,"");return(Array.isArray((q=o.properties)==null?void 0:q.categories)?o.properties.categories.reduce((te,ie)=>{const ue=rt[G+"."+ie];return te===void 0?ue:ue===void 0?te:Math.max(te,ue)},void 0):void 0)??rt[G]}function zn(o){t(0,be=F==="always"),t(13,N=void 0),t(14,h=void 0),t(15,D=-1),li(o[1].toFixed(6)+", "+sn(o[0],[-180,180],!0).toFixed(6),!1,!0)}function Rn(o){if(!N)return;let G=o.key==="ArrowDown"?1:o.key==="ArrowUp"?-1:0;G&&(oe.focus(),t(17,ve=!0),o.preventDefault(),h&&D===-1&&t(15,D=N.findIndex(q=>q.id===(h==null?void 0:h.id))),D===(h||ze?0:-1)&&G===-1&&t(15,D=N.length),t(15,D+=G),D>=N.length&&t(15,D=-1),D<0&&(h||ze)&&t(15,D=0))}function di(o,G=!0,q=!1){if(t(19,le=void 0),t(14,h=void 0),t(17,ve=!0),$e||q){if(Re&&clearTimeout(Re),X.length<w)return;const te=X;Re=window.setTimeout(()=>{St(te).catch(ie=>t(19,le=ie))},G?R:0)}else t(13,N=void 0),t(19,le=void 0)}function Tt(o){h&&(h==null?void 0:h.id)===(o==null?void 0:o.id)?kt():(t(14,h=o),t(1,X=o.place_name))}function fi(o){t(15,D=o)}function Dn(){(!ze||h)&&t(15,D=-1),et&&kt()}const Un=()=>oe.focus();function In(o){at[o?"unshift":"push"](()=>{oe=o,t(18,oe)})}function An(){X=this.value,t(1,X),t(17,ve),t(31,p),t(16,De)}const Pn=()=>t(17,ve=!0),Bn=()=>t(17,ve=!1),jn=()=>t(17,ve=!0),Fn=()=>t(14,h=void 0),Gn=()=>{t(1,X=""),t(14,h=void 0),oe.focus()},Hn=()=>t(0,be=!be),Zn=()=>t(19,le=void 0),qn=o=>fi(o),Qn=o=>Tt(o),Kn=()=>{};return i.$$set=o=>{"class"in o&&t(2,c=o.class),"apiKey"in o&&t(29,f=o.apiKey),"bbox"in o&&t(30,_=o.bbox),"clearButtonTitle"in o&&t(3,v=o.clearButtonTitle),"clearOnBlur"in o&&t(31,p=o.clearOnBlur),"clearListOnPick"in o&&t(32,g=o.clearListOnPick),"keepListOpen"in o&&t(4,k=o.keepListOpen),"collapsed"in o&&t(5,I=o.collapsed),"country"in o&&t(33,T=o.country),"debounceSearch"in o&&t(34,R=o.debounceSearch),"enableReverse"in o&&t(6,F=o.enableReverse),"errorMessage"in o&&t(7,Y=o.errorMessage),"filter"in o&&t(35,O=o.filter),"flyTo"in o&&t(36,W=o.flyTo),"fuzzyMatch"in o&&t(37,E=o.fuzzyMatch),"language"in o&&t(38,y=o.language),"limit"in o&&t(39,S=o.limit),"reverseGeocodingLimit"in o&&t(40,L=o.reverseGeocodingLimit),"mapController"in o&&t(41,m=o.mapController),"minLength"in o&&t(42,w=o.minLength),"noResultsMessage"in o&&t(8,H=o.noResultsMessage),"placeholder"in o&&t(9,he=o.placeholder),"proximity"in o&&t(43,Oe=o.proximity),"reverseActive"in o&&t(0,be=o.reverseActive),"reverseButtonTitle"in o&&t(10,ni=o.reverseButtonTitle),"searchValue"in o&&t(1,X=o.searchValue),"pickedResultStyle"in o&&t(44,xe=o.pickedResultStyle),"showPlaceType"in o&&t(11,ri=o.showPlaceType),"showResultsWhileTyping"in o&&t(45,$e=o.showResultsWhileTyping),"selectFirst"in o&&t(46,ze=o.selectFirst),"flyToSelected"in o&&t(47,et=o.flyToSelected),"markerOnSelected"in o&&t(48,tt=o.markerOnSelected),"types"in o&&t(49,ht=o.types),"reverseGeocodingTypes"in o&&t(50,it=o.reverseGeocodingTypes),"exhaustiveReverseGeocoding"in o&&t(51,bt=o.exhaustiveReverseGeocoding),"excludeTypes"in o&&t(52,vt=o.excludeTypes),"reverseGeocodingExcludeTypes"in o&&t(53,nt=o.reverseGeocodingExcludeTypes),"zoom"in o&&t(54,rt=o.zoom),"apiUrl"in o&&t(55,Lt=o.apiUrl),"fetchParameters"in o&&t(56,_t=o.fetchParameters),"iconsBaseUrl"in o&&t(12,ai=o.iconsBaseUrl),"adjustUrlQuery"in o&&t(57,yt=o.adjustUrlQuery),"adjustUrl"in o&&t(58,wt=o.adjustUrl),"$$scope"in o&&t(69,s=o.$$scope)},i.$$.update=()=>{if(i.$$.dirty[0]&64&&t(0,be=F==="always"),i.$$.dirty[0]&16384|i.$$.dirty[1]&8192&&xe!=="marker-only"&&h&&!h.address&&h.geometry.type==="Point"&&h.place_type[0]!=="reverse"&&St(h.id,{byId:!0}).catch(o=>t(19,le=o)),i.$$.dirty[0]&16384|i.$$.dirty[1]&1058|i.$$.dirty[2]&8&&(m&&h&&h.id!==Et&&W&&(kt(),g&&t(13,N=void 0),t(64,K=void 0),t(15,D=-1)),t(65,Et=h==null?void 0:h.id)),i.$$.dirty[0]&196608|i.$$.dirty[1]&1&&setTimeout(()=>{t(16,De=ve),p&&!De&&t(1,X="")}),i.$$.dirty[0]&8194|i.$$.dirty[1]&2048&&X.length<w&&(t(13,N=void 0),t(19,le=void 0),t(64,K=N)),i.$$.dirty[0]&57344|i.$$.dirty[1]&32768&&ze&&N!=null&&N.length&&D==-1&&!h&&t(15,D=0),i.$$.dirty[0]&8192|i.$$.dirty[2]&4&&K!==N&&t(64,K=void 0),i.$$.dirty[0]&73729|i.$$.dirty[1]&1024|i.$$.dirty[2]&4&&m&&m.setEventHandler(o=>{switch(o.type){case"mapClick":be&&zn(o.coordinates);break;case"markerClick":{const G=N==null?void 0:N.find(q=>q.id===o.id);G&&Tt(G)}break;case"markerMouseEnter":K&&t(15,D=De?(N==null?void 0:N.findIndex(G=>G.id===o.id))??-1:-1);break;case"markerMouseLeave":K&&t(15,D=-1);break}}),i.$$.dirty[0]&40960&&t(66,r=N==null?void 0:N[D]),i.$$.dirty[1]&66592|i.$$.dirty[2]&16&&m&&r&&W&&et&&m.flyTo(r.center,He(r)),i.$$.dirty[1]&8192&&t(68,n=xe==="full-geometry-including-polygon-center-marker"),i.$$.dirty[1]&132096|i.$$.dirty[2]&64&&(tt||m==null||m.setFeatures(void 0,void 0,n)),i.$$.dirty[0]&16384|i.$$.dirty[1]&132096|i.$$.dirty[2]&84&&m&&tt&&!K&&(m.setFeatures(r?[r]:void 0,h,n),m.setSelectedMarker(r?0:-1)),i.$$.dirty[0]&16384|i.$$.dirty[1]&1024|i.$$.dirty[2]&68&&m&&m.setFeatures(K,h,n),i.$$.dirty[0]&32768|i.$$.dirty[1]&1024|i.$$.dirty[2]&4&&K&&m&&m.setSelectedMarker(D),i.$$.dirty[0]&2|i.$$.di