[WIP] Refactor project

This commit is contained in:
Ludovic CANDELLIER
2021-05-21 00:21:05 +02:00
parent 4ce0fa942d
commit b50f50ea62
347 changed files with 14104 additions and 1608 deletions

View File

@@ -1,22 +1,22 @@
var circleCoordinates_{!! $id !!} = (
@foreach ($options['coordinates'] as $key => $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!})
@endforeach
@foreach ($options['coordinates'] as $key => $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!})
@endforeach
);
var circle_{!! $id !!} = new google.maps.Circle({
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
fillColor: '{!! $options['fillColor'] !!}',
fillOpacity: {!! $options['fillOpacity'] !!},
center: circleCoordinates_{!! $id !!},
radius: {!! $options['radius'] !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
fillColor: '{!! $options['fillColor'] !!}',
fillOpacity: {!! $options['fillOpacity'] !!},
center: circleCoordinates_{!! $id !!},
radius: {!! $options['radius'] !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
});
circle_{!! $id !!}.setMap({!! $options['map'] !!});
shapes.push({
'circle_{!! $id !!}': circle_{!! $id !!}
'circle_{!! $id !!}': circle_{!! $id !!}
});

View File

@@ -26,7 +26,7 @@
@if ($options['cluster'])
<script type="text/javascript" src="//googlemaps.github.io/js-marker-clusterer/src/markerclusterer.js"></script>
<script type="text/javascript" src="//googlearchive.github.io/js-marker-clusterer/src/markerclusterer.js"></script>
@endif

View File

@@ -2,111 +2,112 @@
<script type="text/javascript">
var maps = [];
var maps = [];
function initialize_{!! $id !!}() {
var bounds = new google.maps.LatLngBounds();
var infowindow = new google.maps.InfoWindow();
var position = new google.maps.LatLng({!! $options['latitude'] !!}, {!! $options['longitude'] !!});
function initialize_{!! $id !!}() {
var bounds = new google.maps.LatLngBounds();
var infowindow = new google.maps.InfoWindow();
var position = new google.maps.LatLng({!! $options['latitude'] !!}, {!! $options['longitude'] !!});
var mapOptions_{!! $id !!} = {
@if ($options['center'])
center: position,
@endif
var mapOptions_{!! $id !!} = {
@if ($options['center'])
center: position,
@endif
zoom: {!! $options['zoom'] !!},
mapTypeId: google.maps.MapTypeId.{!! $options['type'] !!},
disableDefaultUI: @if (!$options['ui']) true @else false @endif,
scrollwheel: @if ($options['scrollWheelZoom']) true @else false @endif,
mapTypeId: google.maps.MapTypeId.{!! $options['type'] !!},
disableDefaultUI: @if (!$options['ui']) true @else false @endif,
scrollwheel: @if ($options['scrollWheelZoom']) true @else false @endif,
zoomControl: @if ($options['zoomControl']) true @else false @endif,
mapTypeControl: @if ($options['mapTypeControl']) true @else false @endif,
scaleControl: @if ($options['scaleControl']) true @else false @endif,
streetViewControl: @if ($options['streetViewControl']) true @else false @endif,
rotateControl: @if ($options['rotateControl']) true @else false @endif,
fullscreenControl: @if ($options['fullscreenControl']) true @else false @endif
};
fullscreenControl: @if ($options['fullscreenControl']) true @else false @endif,
gestureHandling: '{!! $options['gestureHandling'] !!}'
};
var map_{!! $id !!} = new google.maps.Map(document.getElementById('map-canvas-{!! $id !!}'), mapOptions_{!! $id !!});
map_{!! $id !!}.setTilt({!! $options['tilt'] !!});
var map_{!! $id !!} = new google.maps.Map(document.getElementById('map-canvas-{!! $id !!}'), mapOptions_{!! $id !!});
map_{!! $id !!}.setTilt({!! $options['tilt'] !!});
var markers = [];
var infowindows = [];
var shapes = [];
var markers = [];
var infowindows = [];
var shapes = [];
@foreach ($options['markers'] as $key => $marker)
{!! $marker->render($key, $view) !!}
@endforeach
@foreach ($options['markers'] as $key => $marker)
{!! $marker->render($key, $view) !!}
@endforeach
@foreach ($options['shapes'] as $key => $shape)
{!! $shape->render($key, $view) !!}
@endforeach
@foreach ($options['shapes'] as $key => $shape)
{!! $shape->render($key, $view) !!}
@endforeach
@if ($options['overlay'] == 'BIKE')
var bikeLayer = new google.maps.BicyclingLayer();
bikeLayer.setMap(map_{!! $id !!});
@endif
@if ($options['overlay'] == 'BIKE')
var bikeLayer = new google.maps.BicyclingLayer();
bikeLayer.setMap(map_{!! $id !!});
@endif
@if ($options['overlay'] == 'TRANSIT')
var transitLayer = new google.maps.TransitLayer();
transitLayer.setMap(map_{!! $id !!});
@endif
@if ($options['overlay'] == 'TRANSIT')
var transitLayer = new google.maps.TransitLayer();
transitLayer.setMap(map_{!! $id !!});
@endif
@if ($options['overlay'] == 'TRAFFIC')
var trafficLayer = new google.maps.TrafficLayer();
trafficLayer.setMap(map_{!! $id !!});
@endif
@if ($options['overlay'] == 'TRAFFIC')
var trafficLayer = new google.maps.TrafficLayer();
trafficLayer.setMap(map_{!! $id !!});
@endif
var idleListener = google.maps.event.addListenerOnce(map_{!! $id !!}, "idle", function () {
map_{!! $id !!}.setZoom({!! $options['zoom'] !!});
var idleListener = google.maps.event.addListenerOnce(map_{!! $id !!}, "idle", function () {
map_{!! $id !!}.setZoom({!! $options['zoom'] !!});
@if (!$options['center'])
map_{!! $id !!}.fitBounds(bounds);
@endif
@if (!$options['center'])
map_{!! $id !!}.fitBounds(bounds);
@endif
@if ($options['locate'])
if (typeof navigator !== 'undefined' && navigator.geolocation) {
navigator.geolocation.getCurrentPosition(function (position) {
map_{!! $id !!}.setCenter(new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
});
}
@endif
});
@if ($options['locate'])
if (typeof navigator !== 'undefined' && navigator.geolocation) {
navigator.geolocation.getCurrentPosition(function (position) {
map_{!! $id !!}.setCenter(new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
});
}
@endif
});
var map = map_{!! $id !!};
@if (isset($options['eventBeforeLoad']))
{!! $options['eventBeforeLoad'] !!}
@endif
@if (isset($options['eventBeforeLoad']))
{!! $options['eventBeforeLoad'] !!}
@endif
@if (isset($options['eventAfterLoad']))
google.maps.event.addListenerOnce(map_{!! $id !!}, "tilesloaded", function() {
{!! $options['eventAfterLoad'] !!}
});
@endif
@if (isset($options['eventAfterLoad']))
google.maps.event.addListenerOnce(map_{!! $id !!}, "tilesloaded", function() {
{!! $options['eventAfterLoad'] !!}
});
@endif
@if ($options['cluster'])
var markerClusterOptions = {
imagePath: '{!! $options['clusters']['icon'] !!}',
gridSize: {!! $options['clusters']['grid'] !!},
maxZoom: @if ($options['clusters']['zoom'] === null) null @else {!! $options['clusters']['zoom'] !!} @endif,
averageCenter: @if ($options['clusters']['center'] === true) true @else false @endif,
minimumClusterSize: {!! $options['clusters']['size'] !!}
};
var markerCluster = new MarkerClusterer(map_{!! $id !!}, markers, markerClusterOptions);
@endif
@if ($options['cluster'])
var markerClusterOptions = {
imagePath: '{!! $options['clusters']['icon'] !!}',
gridSize: {!! $options['clusters']['grid'] !!},
maxZoom: @if ($options['clusters']['zoom'] === null) null @else {!! $options['clusters']['zoom'] !!} @endif,
averageCenter: @if ($options['clusters']['center'] === true) true @else false @endif,
minimumClusterSize: {!! $options['clusters']['size'] !!}
};
var markerCluster = new MarkerClusterer(map_{!! $id !!}, markers, markerClusterOptions);
@endif
maps.push({
key: {!! $id !!},
markers: markers,
infowindows: infowindows,
map: map_{!! $id !!},
shapes: shapes
});
}
maps.push({
key: {!! $id !!},
markers: markers,
infowindows: infowindows,
map: map_{!! $id !!},
shapes: shapes
});
}
@if (!$options['async'])
google.maps.event.addDomListener(window, 'load', initialize_{!! $id !!});
google.maps.event.addDomListener(window, 'load', initialize_{!! $id !!});
@endif
</script>
</script>

View File

@@ -2,7 +2,7 @@
@foreach ($items as $id => $item)
{!! $item->render($id, $view) !!}
{!! $item->render($id, $view) !!}
@if ($options['async'])

View File

@@ -1,71 +1,126 @@
@if ($options['place'])
var service = new google.maps.places.PlacesService({!! $options['map'] !!});
var request = {
placeId: '{!! $options['place'] !!}'
};
var service = new google.maps.places.PlacesService({!! $options['map'] !!});
var request = {
placeId: {!! json_encode((string) $options['place']) !!}
};
service.getDetails(request, function(placeResult, status) {
if (status != google.maps.places.PlacesServiceStatus.OK) {
alert('Unable to find the Place details.');
return;
}
service.getDetails(request, function(placeResult, status) {
if (status != google.maps.places.PlacesServiceStatus.OK) {
alert('Unable to find the Place details.');
return;
}
@endif
@if ($options['locate'] && $options['marker'])
if (typeof navigator !== 'undefined' && navigator.geolocation) {
navigator.geolocation.getCurrentPosition(function (position) {
marker_0.setPosition(new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
});
}
if (typeof navigator !== 'undefined' && navigator.geolocation) {
navigator.geolocation.getCurrentPosition(function (position) {
marker_0.setPosition(new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
});
}
@endif
var markerPosition_{!! $id !!} = new google.maps.LatLng({!! $options['latitude'] !!}, {!! $options['longitude'] !!});
var marker_{!! $id !!} = new google.maps.Marker({
position: markerPosition_{!! $id !!},
@if ($options['place'])
place: {
placeId: '{!! $options['place'] !!}',
location: { lat: {!! $options['latitude'] !!}, lng: {!! $options['longitude'] !!} }
},
attribution: {
source: document.title,
webUrl: document.URL
},
@endif
@if (isset($options['draggable']) && $options['draggable'] == true)
draggable: true,
@endif
title: {!! json_encode((string) $options['title']) !!},
label: {!! json_encode($options['label']) !!},
animation: @if (empty($options['animation']) || $options['animation'] == 'NONE') '' @else google.maps.Animation.{!! $options['animation'] !!} @endif,
@if ($options['symbol'])
icon: {
path: google.maps.SymbolPath.{!! $options['symbol'] !!},
scale: {!! $options['scale'] !!}
}
@else
icon:
@if (is_array($options['icon']) && isset($options['icon']['url']))
{
url: {!! json_encode((string) $options['icon']['url']) !!},
position: markerPosition_{!! $id !!},
@if ($options['place'])
place: {
placeId: {!! json_encode((string) $options['place']) !!},
location: { lat: {!! $options['latitude'] !!}, lng: {!! $options['longitude'] !!} }
},
attribution: {
source: document.title,
webUrl: document.URL
},
@endif
@if (isset($options['icon']['size']))
@if (is_array($options['icon']['size']))
scaledSize: new google.maps.Size({!! $options['icon']['size'][0] !!}, {!! $options['icon']['size'][1] !!})
@else
scaledSize: new google.maps.Size({!! $options['icon']['size'] !!}, {!! $options['icon']['size'] !!})
@endif
@endif
}
@else
{!! json_encode($options['icon']) !!}
@endif
@endif
@if (isset($options['clickable']))
clickable: {!! json_encode((bool) $options['clickable']) !!},
@endif
@if (isset($options['cursor']))
cursor: {!! json_encode((string) $options['cursor']) !!},
@endif
@if (isset($options['draggable']))
draggable: {!! json_encode((bool) $options['draggable']) !!},
@endif
@if (isset($options['opacity']))
opacity: {!! json_encode((float) $options['opacity']) !!},
@endif
@if (isset($options['visible']))
visible: {!! json_encode((bool) $options['visible']) !!},
@endif
@if (isset($options['zIndex']))
zIndex: {!! json_encode((int) $options['zIndex']) !!},
@endif
title: {!! json_encode((string) $options['title']) !!},
label: @if (is_array($options['label']))
{
@foreach ($options['label'] as $key => $value)
{!! $key !!}: {!! json_encode((string) $value) !!},
@endforeach
}
@else
{!! json_encode($options['label']) !!}
@endif
,
animation: @if (empty($options['animation']) || $options['animation'] == 'NONE') '' @else google.maps.Animation.{!! $options['animation'] !!} @endif,
@if (isset($options['icon']))
icon: @if (is_array($options['icon']))
{
@foreach ($options['icon'] as $key => $value)
@switch($key)
@case('symbol')
path: google.maps.SymbolPath.{!! $value !!},
@break;
@case('size')
@case('scaledSize')
@if (is_array($value))
{!! $key !!}: new google.maps.Size({!! $value[0] !!}, {!! $value[1] !!}),
@else
{!! $key !!}: new google.maps.Size({!! $value !!}, {!! $value !!}),
@endif
@break;
@case('anchor')
@case('origin')
@case('labelOrigin')
@if (is_array($value))
{!! $key !!}: new google.maps.Point({!! $value[0] !!}, {!! $value[1] !!}),
@else
{!! $key !!}: new google.maps.Point({!! $value !!}, {!! $value !!}),
@endif
@break;
@case('fillOpacity')
@case('rotation')
@case('scale')
@case('strokeOpacity')
@case('strokeWeight')
{!! $key !!}: {!! json_encode((int) $value) !!},
@break
@default
{!! $key !!}: {!! json_encode((string) $value) !!},
@break
@endswitch
@endforeach
}
@else
{!! json_encode((string) $options['icon']) !!}
@endif
@endif
});
bounds.extend(marker_{!! $id !!}.position);
@@ -75,59 +130,59 @@ markers.push(marker_{!! $id !!});
@if ($options['place'])
marker_{!! $id !!}.addListener('click', function() {
infowindow.setContent('<a href="' + placeResult.website + '">' + placeResult.name + '</a>');
infowindow.open({!! $options['map'] !!}, this);
});
});
marker_{!! $id !!}.addListener('click', function() {
infowindow.setContent('<a href="' + placeResult.website + '">' + placeResult.name + '</a>');
infowindow.open({!! $options['map'] !!}, this);
});
});
@else
@if (!empty($options['content']))
@if (!empty($options['content']))
var infowindow_{!! $id !!} = new google.maps.InfoWindow({
content: {!! json_encode((string) $options['content']) !!}
});
var infowindow_{!! $id !!} = new google.maps.InfoWindow({
content: {!! json_encode((string) $options['content']) !!}
});
@if (isset($options['maxWidth']))
@if (isset($options['maxWidth']))
infowindow_{!! $id !!}.setOptions({ maxWidth: {!! $options['maxWidth'] !!} });
infowindow_{!! $id !!}.setOptions({ maxWidth: {!! $options['maxWidth'] !!} });
@endif
@endif
@if (isset($options['open']) && $options['open'])
@if (isset($options['open']) && $options['open'])
infowindow_{!! $id !!}.open({!! $options['map'] !!}, marker_{!! $id !!});
infowindow_{!! $id !!}.open({!! $options['map'] !!}, marker_{!! $id !!});
@endif
@endif
google.maps.event.addListener(marker_{!! $id !!}, 'click', function() {
google.maps.event.addListener(marker_{!! $id !!}, 'click', function() {
@if (isset($options['autoClose']) && $options['autoClose'])
@if (isset($options['autoClose']) && $options['autoClose'])
for (var i = 0; i < infowindows.length; i++) {
infowindows[i].close();
}
for (var i = 0; i < infowindows.length; i++) {
infowindows[i].close();
}
@endif
@endif
infowindow_{!! $id !!}.open({!! $options['map'] !!}, marker_{!! $id !!});
});
infowindow_{!! $id !!}.open({!! $options['map'] !!}, marker_{!! $id !!});
});
infowindows.push(infowindow_{!! $id !!});
infowindows.push(infowindow_{!! $id !!});
@endif
@endif
@endif
@foreach (['eventClick', 'eventDblClick', 'eventRightClick', 'eventMouseOver', 'eventMouseDown', 'eventMouseUp', 'eventMouseOut', 'eventDrag', 'eventDragStart', 'eventDragEnd', 'eventDomReady'] as $event)
@if (isset($options[$event]))
@if (isset($options[$event]))
google.maps.event.addListener(marker_{!! $id !!}, '{!! str_replace('event', '', strtolower($event)) !!}', function (event) {
{!! $options[$event] !!}
});
google.maps.event.addListener(marker_{!! $id !!}, '{!! str_replace('event', '', strtolower($event)) !!}', function (event) {
{!! $options[$event] !!}
});
@endif
@endif
@endforeach

View File

@@ -1,12 +1,12 @@
var overlayCoordinates_{!! $id !!} = new google.maps.LatLngBounds(
@foreach ($options['coordinates'] as $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!}),
@endforeach
@foreach ($options['coordinates'] as $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!}),
@endforeach
);
overlay_{!! $id !!} = new google.maps.GroundOverlay(
'{!! $options['image'] !!}',
overlayCoordinates_{!! $id !!}
'{!! $options['image'] !!}',
overlayCoordinates_{!! $id !!}
);
overlay_{!! $id !!}.setMap({!! $options['map'] !!});

View File

@@ -1,21 +1,21 @@
var polygonCoordinates_{!! $id !!} = [
@foreach ($options['coordinates'] as $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!}),
@endforeach
@foreach ($options['coordinates'] as $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!}),
@endforeach
];
var polygon_{!! $id !!} = new google.maps.Polygon({
paths: polygonCoordinates_{!! $id !!},
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
fillColor: '{!! $options['fillColor'] !!}',
fillOpacity: {!! $options['fillOpacity'] !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
paths: polygonCoordinates_{!! $id !!},
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
fillColor: '{!! $options['fillColor'] !!}',
fillOpacity: {!! $options['fillOpacity'] !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
});
polygon_{!! $id !!}.setMap({!! $options['map'] !!});
shapes.push({
'polygon_{!! $id !!}': polygon_{!! $id !!}
'polygon_{!! $id !!}': polygon_{!! $id !!}
});

View File

@@ -1,20 +1,20 @@
var polylineCoordinates_{!! $id !!} = [
@foreach ($options['coordinates'] as $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!}),
@endforeach
@foreach ($options['coordinates'] as $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!}),
@endforeach
];
var polyline_{!! $id !!} = new google.maps.Polyline({
path: polylineCoordinates_{!! $id !!},
geodesic: {!! $options['strokeColor'] ? 'true' : 'false' !!},
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
path: polylineCoordinates_{!! $id !!},
geodesic: {!! $options['strokeColor'] ? 'true' : 'false' !!},
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
});
polyline_{!! $id !!}.setMap({!! $options['map'] !!});
shapes.push({
'polyline_{!! $id !!}': polyline_{!! $id !!}
'polyline_{!! $id !!}': polyline_{!! $id !!}
});

View File

@@ -1,21 +1,21 @@
var rectangleCoordinates_{!! $id !!} = new google.maps.LatLngBounds(
@foreach ($options['coordinates'] as $key => $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!})@if (count($options['coordinates']) - 1 > $key), @endif
@endforeach
@foreach ($options['coordinates'] as $key => $coordinate)
new google.maps.LatLng({!! $coordinate['latitude'] !!}, {!! $coordinate['longitude'] !!})@if (count($options['coordinates']) - 1 > $key), @endif
@endforeach
);
var rectangle_{!! $id !!} = new google.maps.Rectangle({
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
fillColor: '{!! $options['fillColor'] !!}',
fillOpacity: {!! $options['fillOpacity'] !!},
bounds: rectangleCoordinates_{!! $id !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
strokeColor: '{!! $options['strokeColor'] !!}',
strokeOpacity: {!! $options['strokeOpacity'] !!},
strokeWeight: {!! $options['strokeWeight'] !!},
fillColor: '{!! $options['fillColor'] !!}',
fillOpacity: {!! $options['fillOpacity'] !!},
bounds: rectangleCoordinates_{!! $id !!},
editable: {!! $options['editable'] ? 'true' : 'false' !!}
});
rectangle_{!! $id !!}.setMap({!! $options['map'] !!});
shapes.push({
'rectangle_{!! $id !!}': rectangle_{!! $id !!}
'rectangle_{!! $id !!}': rectangle_{!! $id !!}
});

View File

@@ -2,33 +2,33 @@
<script type="text/javascript">
function initialize_{!! $id !!}() {
var bounds = new google.maps.LatLngBounds();
var position = new google.maps.LatLng({!! $options['latitude'] !!}, {!! $options['longitude'] !!});
function initialize_{!! $id !!}() {
var bounds = new google.maps.LatLngBounds();
var position = new google.maps.LatLng({!! $options['latitude'] !!}, {!! $options['longitude'] !!});
var mapOptions = {
@if ($options['center'])
center: position,
@endif
zoom: {!! $options['zoom'] !!},
mapTypeId: google.maps.MapTypeId.{!! $options['type'] !!},
disableDefaultUI: @if (!$options['ui']) true @else false @endif
};
var mapOptions = {
@if ($options['center'])
center: position,
@endif
zoom: {!! $options['zoom'] !!},
mapTypeId: google.maps.MapTypeId.{!! $options['type'] !!},
disableDefaultUI: @if (!$options['ui']) true @else false @endif
};
var map = new google.maps.Map(document.getElementById('map-canvas-{!! $id !!}'), mapOptions);
var map = new google.maps.Map(document.getElementById('map-canvas-{!! $id !!}'), mapOptions);
var panoramaOptions = {
position: position,
pov: {
heading: {!! $options['heading'] !!},
pitch: {!! $options['pitch'] !!}
}
};
var panoramaOptions = {
position: position,
pov: {
heading: {!! $options['heading'] !!},
pitch: {!! $options['pitch'] !!}
}
};
var panorama = new google.maps.StreetViewPanorama(document.getElementById('map-canvas-{!! $id !!}'), panoramaOptions);
var panorama = new google.maps.StreetViewPanorama(document.getElementById('map-canvas-{!! $id !!}'), panoramaOptions);
map.setStreetView(panorama);
}
map.setStreetView(panorama);
}
@if (!$options['async'])