=o.localMax))break;return f.sort((b,y)=>{const E=b.properties.__pplr_local,k=y.properties.__pplr_local,M=(E==null?void 0:E.depth)??99,L=(k==null?void 0:k.depth)??99;if(M!==L)return M-L;const J=b.place_name.toLowerCase().startsWith(w)?0:1,se=y.place_name.toLowerCase().startsWith(w)?0:1;return J!==se?J-se:((k==null?void 0:k.pop)||0)-((E==null?void 0:E.pop)||0)||((k==null?void 0:k.count)||0)-((E==null?void 0:E.count)||0)}),f}}function g(R){var k,M;const w=((k=R==null?void 0:R.properties)==null?void 0:k.__pplr_kind)||"",f=(M=R==null?void 0:R.properties)==null?void 0:M.__pplr_local,b=(f==null?void 0:f.color)||"",y=b?``:"",E=w?`${Rt(w)}`:"";return`
- ${y}${Rt(R.place_name)}${E}
-
`}const m=(qa[l]||qa.mapbox).css;function _(R){if(!R||R===document||R.querySelector("link[data-pplr-geocoder-css]"))return;const w=document.createElement("link");w.rel="stylesheet",w.href=m,w.setAttribute("data-pplr-geocoder-css","1"),R.prepend(w)}function T(){try{if(c){if(!window.MaplibreGeocoder||!window.maplibregl){console.warn("[MapboxGeocoder] maplibre-gl-geocoder or maplibre-gl not on window — search disabled");return}i=new window.MaplibreGeocoder({forwardGeocode:async()=>({type:"FeatureCollection",features:[]})},{maplibregl:window.maplibregl,placeholder:o.placeholder,localGeocoder:d(),localGeocoderOnly:!0,minLength:o.minChars,showResultsWhileTyping:!0,render:g})}else{if(!window.MapboxGeocoder||!jn("mapbox")){console.warn("[MapboxGeocoder] mapbox-gl-geocoder or mapbox-gl not on window — check CDN
-
+