GPS Widget
Description
The GPSWidget enables the use of the browsers geolocation api.
Attributes
latitude: Number | null - The initial lat value
longitude: Number | null - The initial lng value
showMap: Boolean - Shows a map allowing users to select a location. If a lat & lng value is passed a marker will be displayed allowing users to drag to a new location.
mapCenter: Lat/Lng object - Default map center used if no lat & lng are set
enableHighAccuracy: Boolean - Force high accuracy when using geolocation (can take longer)
showActions: Boolean - When set will display action buttons to post location data back to DSL app or reset location
mustConfirm: Boolean - User must confirm setting their location
enableAddressSearch: Boolean - Allow address search for location
addressSearchBounds: N,E,S,W co-ordinates of the bounding box for the address search - this limits the address autocomplete to within the bounds in order to exclude irrelevant addresses. Can be done by country.
<raw type="GpsWidget" action="gpsAction" cols-xs="12" cols-md="4">
<content variable="rawGpsContent" />
</raw>{
"latitude": -27.810728114774516,
"longitude": 23.258056640625,
"showMap": true,
"mapCenter": {"latitude": -27.810728114774516, "longitude": 23.258056640625},
"enableHighAccuracy": false,
"showActions": true,
"mustConfirm": true,
"enableAddressSearch": true,
"addressSearchBounds": {
"north": -22.0913127581,
"south": -34.8191663551,
"west": 16.3449768409,
"east": 32.830120477
}
}