MMapHotspot
The MMapHotspot
class determines a hotspot not displayed separately on the map.
MMapHotspot
is used to mark hotspots on raster layer images.
Usage example
vanilla
react
vue
const map = new mappable.MMap(document.getElementById('map-root'), {...});
map.addChild(new mappable.MMapListener({
layer: 'any',
onClick: (object) => {
if (object instanceof mappable.MMapHotspot) {
console.log('Hotspot clicked', object);
}
}
}))
Constructor
new MMapHotspot(geometry
, properties
)
Constructor parameters
Parameter |
Type |
|
|
|
|
Properties
geometry
optional readonly geometry: <a href="ref/#GenericGeometry">GenericGeometry</a><<a href="ref/#LngLat">LngLat
id
readonly id: string
properties
readonly properties: <a href="ref/#recordkeys-type ">Record</a><string, unknown>