Configuration

An object defining configuration options for the dxMap widget.

clickAction

An action performed when the widget is clicked.

Type: Action
Default Value: null

Show Example:
jQuery

controls

Specifies whether or not the map widget controls are available.

Type: Boolean|Object
Default Value: { mapNavigation: true, mapType: true }

You can assign a Boolean value to this option to enable or disable all controls, or assign an object containing the following Boolean fields to enable or disable only the required controls.

  • mapNavigation - specifies whether the navigation control is enabled or disabled.
  • mapType - specifies whether the map type control is enabled or disabled.
Show Example:
jQuery

disabled

A Boolean value specifying whether or not a component can respond to user interaction.

Type: Boolean
Default Value: false

Create an observable variable and assign it to this option to specify the availability of the component at runtime.

Show Example:
jQuery

height

Specifies the height of the widget.

Type: Number
Default Value: 300

The option can hold a value of the following types.

  • numeric - the height of the widget in pixels
  • string - a CSS measurement of the widget height (e.g., "55px", "80%", "auto" and "inherit")
  • function - a function returning the widget height (e.g., height:function(){ return baseHeight - 10 + "%"; })

key

A key used to authenticate the application within the required map provider.

Type: String
Default Value: ""

For more information on authentication keys, see the required map provider documentation.

location

An object, a string, or an array specifying the current location.

You can specify the location value in one of the following formats.

  • { lat: 40.749825, lng: -73.987963}
  • "40.749825, -73.987963"
  • [40.749825, -73.987963]
  • 'Brooklyn Bridge,New York,NY'

mapType

The type of map to display.

Type: String
Default Value: "roadmap"
Accepted Values: 'hybrid'|'roadmap'|'satellite'|'terrain'

The available option values are based on map types supported by the Google map provider. If you use the Bing map, the widget casts the option value to the appropriate value supported by the "bing" provider.

  • hybrid -> Road
  • roadmap -> Road
  • satellite -> Bird's eye
  • terrain -> Bird's eye
Show Example:
jQuery

markers

An array of markers displayed on a map.

Type: Array

An item of the array assigned to the markers option is an object containing the following fields.

  • location - an object, a string, or an array specifying the marker location (see the location option description).
  • tooltip - specifies the message text shown when the marker is clicked.
  • clickAction - an action performed when the marker is clicked.
Show Example:
jQuery

provider

The name of the current map data provider.

Type: String
Default Value: "google"
Accepted Values: 'bing'|'google'|'googleStatic'

Show Example:
jQuery

routes

An array of routes shown on the map.

Type: Array

An item of the array assigned to the routes option is an object containing the following fields.

  • locations - contains an array of locations making up the route.
  • color - specifies the color of the line displaying the route.
  • weight - specifies the thickness of the line displaying the route.
Show Example:
jQuery

visible

A Boolean value specifying whether or not the widget is visible.

Type: Boolean
Default Value: true

width

Specifies the width of the widget.

Type: Number
Default Value: 300

The option can hold a value of the following types.

  • numeric - the widget width in pixels
  • string - a CSS measurement of the widget width (e.g., "55px", "80%", "auto" and "inherit")
  • function - the function returning the widget width (e.g., width:function(){ return baseWidth - 10 + "%"; })

zoom

The zoom level of the map.

Type: Number
Default Value: 1

Show Example:
jQuery