Skip to content

Type Alias: MapEntity

ts
type MapEntity = {
  buildingId?: string | number;
  highlight?: HighlightStyle;
  html?: string;
  id: MapstedId;
  marker?: string;
  name?: string;
};

The options for a map entity

Properties

PropertyTypeDescription
buildingId?string | numberBuilding id of the entity
highlight?HighlightStyle-
html?stringOptional html string rendered in the entity popup. The iframe inspects the rendered children for data-mapsted-trigger / data-mapsted-event / data-mapsted-payload attributes — these are an internal escape-hatch inside the Mapsted Maps web iframe, NOT part of the public JS API surface and may change or be removed without a major-version bump. See the /guide/how-to/customize-popups guide ("Current public-API scope note") for the supported patterns for reacting to popup content.
idMapstedId-
marker?stringCan either be html or an image url. If the string doesn't start with "<" it is assumed to be an image url.
name?stringOptional string to show on the top of the popup in a formatted fashion.