geofield-embed-google-map.html.twig in Geofield Map 8.2
Displays the Geofield Google Map (embed) formatter.
Available variables:
- width: Width of map.
- height: Height of map.
- q: The place address / location string, url-escaped.
- apikey: Google Maps API key.
1 theme call to geofield-embed-google-map.html.twig
- GeofieldGoogleEmbedMapFormatter::viewElements in modules/
geofield_map_extras/ src/ Plugin/ Field/ FieldFormatter/ GeofieldGoogleEmbedMapFormatter.php - Builds a renderable array for a field value.
File
modules/geofield_map_extras/templates/geofield-embed-google-map.html.twigView source
- {#
- /**
- * @file
- * Displays the Geofield Google Map (embed) formatter.
- *
- * Available variables:
- * - width: Width of map.
- * - height: Height of map.
- * - q: The place address / location string, url-escaped.
- * - apikey: Google Maps API key.
- *
- * @ingroup themeable
- */
- #}
- <div class="geofield-embed-google-map">
- <iframe
- width={{ width }}
- height={{ height }}
- frameborder="0" style="border:0"
- title="{{ title }}"
- src="https://www.google.com/maps/embed/v1/place?key={{ apikey }}&q={{ q }}{{ options_string }}" allowfullscreen>
- </iframe>
- </div>