The Map component
The Map component lets you add a configurable and searchable map to your project. This can show the user's location, as well as other specific location-based information.
To add the Map component to your project:
- Open the Components panel, then the Maps folder.
- Drag the Map component to the stage.
- In the Map properties section of the Properties panel, configure the component by setting its properties (described below).
|Name||The component name.|
|Search term||Text used as a search term when the Map component loads, which will show all matches in the displayed area.|
|Latitude||The latitude for your default map location.|
|Longitude||The longitude for your default map location.|
|Request user location||Check to ask the user for their location.|
Click the expand icon next to Advanced properties in the component properties pane to edit the following advanced properties:
|Fusion Table ID||The ID of the Fusion Table where you can set locations to pre-populate your map. The fusion table needs to have the following column titles:
|Maps Premier Client ID (deprecated)||The client ID for Google Maps Premier users. Google Maps Premium Plan customers will transition to the new pricing plan when their current contract expires and should use a Google Maps Platform API key instead.|
|Search radius||The radius, in meters, around the map search point, centered on the user's location.|
|Max results||The maximum number of search results presented to the user.|
|Default zoom||The default zoom level for the map.
We recommend a level of about 14, which is suitable for viewing city blocks and intersections.
|Marker icon||The URI for a custom marker icon, if you choose to replace the default marker. The image source for the marker must be a sprite similar to this:
The sprite needs two marker icons in the following order and position:
|Location icon||The URI for a custom user icon, if you choose to replace the default icon.|
|User location prompt text||Custom text to ask the user how they wish to have their location determined. By default, the text reads: "How would you like us to get your position?"|
|GPS choice button text||Custom text for the button that retrieves the user's location. By default, the text reads: "Use GPS"|
|Search choice button text||Custom text for the button that brings up a location search field. By default, the text reads: "Enter address"|
|Search prompt text||Custom text for the prompt to search for a location. By default, the text reads: "Enter your address or zip code"|
|Search box guide text||Custom placeholder text for the search box. By default, the text reads: "Address or zip code"|
|Location error text||Custom text for the message displayed when the location can't be found. By default, the text reads: "Your location could not be determined. Please enter a valid address."|
|No result text||Custom text for the message displayed when no map results where found for the specified location. By default, the text reads: "No results found near you."|
Events are how you connect a physical gesture from your user to an action in your ad. The Map component sends the following event, which can be used to trigger other actions:
|Pin click||Sent when the user clicks a pin on the map.|
The following Map component action can be triggered by other events:
|Set the center of the map||
Components can't be previewed inside the Google Web Designer interface. To see the component in action, preview your ad in your preferred browser.