Class Outdoor

The outdoor map shown around the Mappedin indoor map can be manipulated to show or hide additional information. It can be used to add GeoJSON based geometry, images, deck.gl layers and more.

The outdoor map is accessed using MapView.Outdoor.map, which returns a maplibregl.Map object. MapLibre GL JS is a TypeScript library that uses WebGL to render interactive maps from vector tiles in a browser. The Mappedin SDK makes use of it to display the outdoor map.

By providing access to the MapLibre map used to draw the outdoor map, the Mappedin SDK enables developers to draw on and manipulate the outdoor map. Developers can use most capabilities of MapLibre GL JS with key exceptions being Interactivity and Camera, which are not available.

User touch and click events are handled by Mappedin JS and are not propagated to the outdoor map layer. Camera movement is also handled by Mappedin JS and cannot be manipulated using MapLibre controls.

Refer to the Outdoor Map Guide for more information and interactive examples.

Accessors

  • get enabled(): boolean
  • Whether the outdoorView is enabled.

    Returns boolean

  • get map(): undefined | Map
  • Returns a Maplibre map for advanced usage.

    Returns undefined | Map

    Maplibre map instance

    Limitations:

    • Maplibre interaction events are not supported, use Mappedin JS interaction events.
    • Maplibre markers and labels may overlap as they are not integrated with the Mappedin JS collision engine.
  • get visible(): boolean
  • Whether the outdoorView is visible.

    Returns boolean

Methods

  • Hide the outdoor map.

    Parameters

    • excludedStyleLayerIds: string[] = []

      {string[]}

    Returns void

  • Set outdoor view opacity.

    Parameters

    • targetOpacity: number | "initial"

      {number | 'initial'}

    • excludedStyleLayerIds: string[] = []

      {string[]}

    Returns void

  • Set the style of the outdoor map. Use one of Mappedin's predefined styles or link to a custom style.

    Parameters

    • style: any

      {any}

    Returns void

  • Show the outdoor map.

    Returns void