BasemapLayerListViewModel

require(["esri/widgets/BasemapLayerList/BasemapLayerListViewModel"], function(BasemapLayerListVM) { /* code goes here */ });
Class: esri/widgets/BasemapLayerList/BasemapLayerListViewModel
Inheritance: BasemapLayerListViewModel Accessor
Since: ArcGIS API for JavaScript 4.13

Provides logic for the BasemapLayerList widget.

See also:

Constructors

new BasemapLayerListViewModel(properties)
Parameter:
properties Object
optional

See the properties for a list of all the properties that may be passed into the constructor.

Property Overview

Any properties can be set, retrieved or listened to. See the Working with Properties topic.
Show inherited properties Hide inherited properties
Name Type Summary Class
Collection<ListItem>

A collection of ListItems representing the baseLayers.

more details
more detailsBasemapLayerListViewModel
ListItemCreatedHandler

Specifies a function that accesses each ListItem.

more details
more detailsBasemapLayerListViewModel
String

The current basemap's title.

more details
more detailsBasemapLayerListViewModel
String

The name of the class.

more details
more detailsAccessor
Collection<ListItem>

A collection of ListItems representing the referenceLayers.

more details
more detailsBasemapLayerListViewModel
ListItemCreatedHandler

Specifies a function that accesses each ListItem representing reference layers.

more details
more detailsBasemapLayerListViewModel
String

The view model's state.

more details
more detailsBasemapLayerListViewModel
MapView|SceneView

A reference to the MapView or SceneView.

more details
more detailsBasemapLayerListViewModel

Property Details

baseItems Collection<ListItem>readonly

A collection of ListItems representing the baseLayers.

baseListItemCreatedFunction ListItemCreatedHandler

Specifies a function that accesses each ListItem. Each list item can be modified according to its modifiable properties. Actions can be added to list items using the actionsSections property of the ListItem.

basemapTitle String

The current basemap's title.

declaredClass Stringreadonly inherited

The name of the class. The declared class name is formatted as esri.folder.className.

referenceItems Collection<ListItem>readonly

A collection of ListItems representing the referenceLayers.

referenceListItemCreatedFunction ListItemCreatedHandler

Specifies a function that accesses each ListItem representing reference layers.

state Stringreadonly

The view model's state.

Possible Values:"ready"|"loading"|"disabled"

Default Value:disabled

A reference to the MapView or SceneView. Set this to link the widget to a specific view.

Method Overview

Name Return Type Summary Class

Triggers the trigger-action event and executes the given action or action toggle.

more details
more detailsBasemapLayerListViewModel

Method Details

triggerAction(action, item)

Triggers the trigger-action event and executes the given action or action toggle.

Parameters:

The action to execute.

item ListItem

An item associated with the action.