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

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

geometry

undefined | GenericGeometry<LngLat>

properties

Record<string, unknown>

Properties

geometry

optional readonly geometry: <a href="ref/#GenericGeometry">GenericGeometry</a>&lt;<a href="ref/#LngLat">LngLat

id

readonly id: string

properties

readonly properties: <a href="ref/#recordkeys-type ">Record</a>&lt;string, unknown&gt;