Class defaultMaptiler
Implements
Index
Constructors
Properties
Methods
Constructors
Maptilerconstructor
Parameters
- options: MinimapOptionsInput
- mapOptions: MapOptions
Returns default
Methods
MaptileraddLayer
- addLayer(
layer:
| CustomLayerInterface
| (
LayerSpecification & { source?: string | SourceSpecification | undefined; }
),
beforeId?: string,
): MapParameters
- layer:
| CustomLayerInterface
| (
LayerSpecification & { source?: string | SourceSpecification | undefined; }
) OptionalbeforeId: string
Returns Map
- layer:
MaptilermoveLayer
Parameters
- id: string
OptionalbeforeId: string
Returns Map
MaptileronAdd
Register a control on the map and give it a chance to register event listeners and resources. This method is called by Map.addControl internally.
Parameters
- parentMap: Map
Returns HTMLElement
The control's container element. This should be created by the control and returned by onAdd without being attached to the DOM: the map will insert the control's element into the DOM as necessary.
MaptileronRemove
Unregister a control on the map and give it a chance to detach event listeners and resources. This method is called by Map.removeControl internally.
Returns void
MaptilerremoveLayer
Parameters
- id: string
Returns this
MaptilersetFilter
- setFilter(
layerId: string,
filter?: FilterSpecification | null,
options?: StyleSetterOptions,
): thisParameters
- layerId: string
Optionalfilter: FilterSpecification | nullOptionaloptions: StyleSetterOptions
Returns this
MaptilersetGlyphs
Parameters
- glyphsUrl: string | null
Optionaloptions: StyleSetterOptions
Returns this
MaptilersetLayerZoomRange
Parameters
- layerId: string
- minzoom: number
- maxzoom: number
Returns this
MaptilersetLayoutProperty
Parameters
- layerId: string
- name: string
- value: any
Optionaloptions: StyleSetterOptions
Returns this
MaptilersetPaintProperty
Parameters
- layerId: string
- name: string
- value: any
Optionaloptions: StyleSetterOptions
Returns this
MaptilersetStyle
- setStyle(
style:
| string
| StyleSpecification
| ReferenceMapStyle
| MapStyleVariant
| null,
options?: StyleSwapOptions & StyleOptions,
): voidParameters
- style: string | StyleSpecification | ReferenceMapStyle | MapStyleVariant | null
Optionaloptions: StyleSwapOptions & StyleOptions
Returns void
Was this helpful?
Interface for interactive controls added to the map. This is a specification for implementers to model: it is not an exported method or class.
Controls must implement
onAddandonRemove, and must own an element, which is often adivelement. To use MapLibre GL JS's default control styling, add themaplibregl-ctrlclass to your control's node.Example