jQuery(document).ready(function(t){"use strict";var a=[];function i(){t(".nectar-leaflet-map").each(function(i){var r=t(this).attr("id"),e=parseFloat(t(this).attr("data-zoom-level")),n=parseFloat(t(this).attr("data-center-lat")),o=parseFloat(t(this).attr("data-center-lng")),s=t(this).attr("data-marker-style"),d=!t(this).is("[data-infowindow-start-open]")||"1"!=t(this).attr("data-infowindow-start-open");a[i]=L.map(r,{scrollWheelZoom:!1,center:[n,o],zoom:e,closePopupOnClick:d}),L.tileLayer("https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",{attribution:'&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'}).addTo(a[i]);var h=i;t(".map-marker-list."+r).each(function(){t(this).find(".map-marker").each(function(){var i={};if("nectar"==s)i={icon:L.divIcon({html:'<div><div class="animated-dot"><div class="middle-dot"></div><div class="signal"></div><div class="signal2"></div></div></div>'})};else if(t("#"+r).attr("data-marker-img").length>0){var l=t(this).is("[data-marker-image-height]")&&t(this).attr("data-marker-image-height").length>0?parseInt(t(this).attr("data-marker-image-height")):50,m=t(this).is("[data-marker-image-width]")&&t(this).attr("data-marker-image-width").length>0?parseInt(t(this).attr("data-marker-image-width")):50;i={icon:L.icon({iconUrl:t("#"+r).attr("data-marker-img"),iconSize:[m,l]})}}else i={icon:L.divIcon({html:'<div class="nectar-leaflet-pin"></div>',iconSize:[34,34],popupAnchor:[-3,-13],iconAnchor:[20,20]})};var p=t(this).is("[data-lat]")&&t(this).attr("data-lat").length>0?parseFloat(t(this).attr("data-lat")):0,c=t(this).is("[data-lng]")&&t(this).attr("data-lng").length>0?parseFloat(t(this).attr("data-lng")):0;""!=t(this).attr("data-mapinfo")&&"<br />"!=t(this).attr("data-mapinfo")&&"<br/>"!=t(this).attr("data-mapinfo")?d?L.marker([p,c],i).addTo(a[h]).bindPopup(t(this).attr("data-mapinfo")):(L.marker([p,c],i).addTo(a[h]).bindPopup(t(this).attr("data-mapinfo"),{autoClose:!1}).openPopup(),a[h].setView([n,o],e)):L.marker([p,c],i).addTo(a[h])})})})}t(window).on("vc_reload",function(){if(a.length>0)for(var t=0;t<a.length;t++)a[t].remove();a=[],i()}),i()});