?
| Current Path : /home/w/e/b/webyoo/www/sarah/site/wp-content/themes/woodmart/js/scripts/elements/ |
| Current File : /home/w/e/b/webyoo/www/sarah/site/wp-content/themes/woodmart/js/scripts/elements/googleMap.min.js |
!function(n){n.each(["frontend/element_ready/wd_google_map.default"],function(e,o){woodmartThemeModule.wdElementorAddAction(o,function(){woodmartThemeModule.googleMapInit()})}),woodmartThemeModule.googleMapInit=function(){n(".google-map-container").each(function(){var o=n(this),e=o.data("map-args"),t={locations:[{lat:e.latitude,lon:e.longitude,icon:e.marker_icon,animation:google.maps.Animation.DROP}],controls_on_map:!1,map_div:"#"+e.selector,start:1,map_options:{zoom:parseInt(e.zoom),scrollwheel:"yes"===e.mouse_zoom}};e.json_style&&!e.elementor?(t.styles={},t.styles[woodmart_settings.google_map_style_text]=JSON.parse(e.json_style)):e.json_style&&e.elementor&&(t.styles={},t.styles[woodmart_settings.google_map_style_text]=JSON.parse(atob(e.json_style))),"yes"===e.marker_text_needed&&(t.locations[0].html=e.marker_text),"button"===e.init_type?o.find(".wd-init-map").on("click",function(e){e.preventDefault(),o.hasClass("wd-map-inited")||(o.addClass("wd-map-inited"),new Maplace(t).Load())}):"scroll"===e.init_type?woodmartThemeModule.$window.on("scroll",function(){window.innerHeight+woodmartThemeModule.$window.scrollTop()+parseInt(e.init_offset)>o.offset().top&&(o.hasClass("wd-map-inited")||(o.addClass("wd-map-inited"),new Maplace(t).Load()))}):"interaction"===e.init_type?woodmartThemeModule.$window.on("wdEventStarted",function(){new Maplace(t).Load()}):new Maplace(t).Load()});var e=n(".google-map-container-with-content");woodmartThemeModule.$window.on("resize",function(){e.css({height:e.find(".wd-google-map.with-content").outerHeight()})})},n(document).ready(function(){woodmartThemeModule.googleMapInit()})}(jQuery);