'wip'
This commit is contained in:
23
resources/views/index.blade.php
Normal file
23
resources/views/index.blade.php
Normal file
@@ -0,0 +1,23 @@
|
||||
@if ($enabled)
|
||||
<div class="map-container fade">
|
||||
<div class="map" data-map-key="{{ $key }}" data-map-type="{{ $type }}" data-map-lat="{{ $lat }}" data-map-lng="{{ $lng }}" data-map-zoom="{{ $zoom }}" data-map-markers="{{ json_encode($markers) }}"></div>
|
||||
</div>
|
||||
{{--
|
||||
<div class="col-lg-12"></div>
|
||||
<div class="clear-fix"></div>
|
||||
|
||||
<div class="col-lg-12"></div>
|
||||
<div class="clear-fix"></div>
|
||||
|
||||
<iframe class="map" width="800" height="450" frameborder="0" style="border:0" src="https://www.google.com/maps/embed/v1/place?key={{ $key ?? '' }}&q={{ $lat }},{{ $lng }}¢er={{ $lat }},{{ $lng }}&zoom={{ $zoom }}" scrolling="no">
|
||||
</iframe>
|
||||
|
||||
<div class="col-lg-12"></div>
|
||||
<div class="clear-fix"></div>
|
||||
|
||||
<div class="map-container fade in">
|
||||
<iframe class="map" width="800" height="800" frameborder="0" style="border:0" src="https://www.bing.com/maps/embed?h=800&w=800&cp={{ $lat }}~{{ $lng }}&lvl={{ $zoom }}&typ=d&sty=r&src=SHELL&FORM=MBEDV8" scrolling="no">
|
||||
</iframe>
|
||||
</div>
|
||||
--}}
|
||||
@endif
|
||||
16
resources/views/scripts.blade.php
Normal file
16
resources/views/scripts.blade.php
Normal file
@@ -0,0 +1,16 @@
|
||||
@if ($enabled)
|
||||
{{--TODO: If overriding type via @map() then type is not working--}}
|
||||
@if ($type == 'osm' || $type == 'bing')
|
||||
<script src="https://unpkg.com/leaflet@1.3.4/dist/leaflet.js"
|
||||
integrity="sha512-nMMmRyTVoLYqjP9hrbed9S+FzjZHW5gY1TWCHA5ckwXZBadntCNs8kEqAWdrb9O7rxbCaA4lKTIWjDXZxflOcA=="
|
||||
crossorigin="" async defer></script>
|
||||
{{-- TODO check if bing needs polyfill: https://github.com/digidem/leaflet-bing-layer--}}
|
||||
@endif
|
||||
@if ($type == 'mapkit')
|
||||
<script src="https://cdn.apple-mapkit.com/mk/5.x.x/mapkit.js" async defer></script>
|
||||
@endif
|
||||
<script src="{{ asset(mix('js/index.js', 'vendor/maps')) }}" type="text/javascript"></script>
|
||||
@if($type == 'google')
|
||||
<script src="https://maps-api-ssl.google.com/maps/api/js?v=3&ie=UTF8&oe=UTF8&key={{ $key }}&language={{ app()->getLocale() }}&callback=onGoogleMapsReady" async defer></script>
|
||||
@endif
|
||||
@endif
|
||||
8
resources/views/styles.blade.php
Normal file
8
resources/views/styles.blade.php
Normal file
@@ -0,0 +1,8 @@
|
||||
@if ($enabled)
|
||||
@if($type == 'osm' || $type == 'bing')
|
||||
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.3.4/dist/leaflet.css"
|
||||
integrity="sha512-puBpdR0798OZvTTbP4A8Ix/l+A4dHDD0DGqYW6RQ+9jxkRFclaxxQb/SJAWZfWAkuyeQUytO7+7N4QKrDh+drA=="
|
||||
crossorigin=""/>
|
||||
@endif
|
||||
<link rel="stylesheet" href="{{ asset(mix('css/index.css', 'vendor/maps')) }}" type="text/css">
|
||||
@endif
|
||||
Reference in New Issue
Block a user