Current Path : /storage/v11800/fortrajwada-com/public_html/assets/js/ |
Linux v11800 5.3.0-1023-aws #25~18.04.1-Ubuntu SMP Fri Jun 5 15:19:18 UTC 2020 aarch64
|
Current File : /storage/v11800/fortrajwada-com/public_html/assets/js/map.min.js |
"use strict";jQuery(document).ready(function(e){e(".google-map").each(function(){function o(){var e=[{stylers:[{saturation:-100}]}],o={zoom:parseInt(t.map_zoom,10),scrollwheel:!1,draggable:"on"===t.map_scrollable,mapTypeId:google.maps.MapTypeId[t.map_type]};return"blackwhite"===t.map_style&&(o.styles=e),new google.maps.Map(a[0],o)}function n(e,o){if("show"===t.marker){var n={url:t.markerURL,size:new google.maps.Size(30,48),origin:new google.maps.Point(0,0),anchor:new google.maps.Point(15,48)},a=new google.maps.Marker({position:e,icon:n,map:s});if(l.extend(e),void 0!==t.label[o]){var g=new google.maps.InfoWindow({content:t.label[o]});google.maps.event.addListener(a,"click",function(e){g.open(s,this)})}}}var a=e(this),t=window[a.attr("id")],s=o(),l=new google.maps.LatLngBounds,g=!t.auto_center;if(g)if(void 0!==t.center_latlng){var r=t.center_latlng.split(","),i=new google.maps.LatLng(r[0],r[1]);s.setCenter(i)}else console.log("You have not set any coordinates for the map to be centered at.");if(t.address){var d=0;e.each(t.address,function(e,o){var a=new google.maps.Geocoder;a.geocode({address:o},function(o,a){if(a===google.maps.GeocoderStatus.OK){if(void 0!==o[0]){var r=o[0].geometry.location,i=new google.maps.LatLng(r.lat(),r.lng());n(i,e)}d++,g||d!==t.address.length||s.fitBounds(l)}else console.log("Geocode was not successful for the following reason: "+a)})})}else if(void 0!==t.latlng){for(var p=0;p<t.latlng.length;p++){var c=t.latlng[p].split(","),m=new google.maps.LatLng(c[0],c[1]);n(m,p)}g||s.fitBounds(l)}var f=google.maps.event.addListener(s,"bounds_changed",function(e){this.setZoom(parseInt(t.map_zoom,10)),google.maps.event.removeListener(f)})})});