@geoblocks/ol-maplibre-layer
    Preparing search index...

    This class is a renderer for MapLibre Layer to be able to use the native ol functionalities like map.getFeaturesAtPixel or map.hasFeatureAtPixel.

    Hierarchy

    Index

    Constructors

    Methods

    • Type Parameters

      • Feature

      Parameters

      • coordinate: Coordinate

        Coordinate.

      • _frameState: FrameState
      • hitTolerance: number

        Hit tolerance in pixels.

      • callback: FeatureCallback<Feature>

        Feature callback.

      Returns Feature

      Callback result.

    • Asynchronous layer level hit detection.

      Parameters

      • pixel: Pixel

        Pixel.

      Returns Promise<Feature<Geometry>[]>

      Promise that resolves with an array of features.

    • Parameters

      • coordinate: Coordinate
      • hitTolerance: number = 5

      Returns Feature<Geometry>[]

    • Determine whether render should be called.

      Returns boolean

      Layer is ready to be rendered.

    • Render the layer.

      Parameters

      • frameState: FrameState

        Frame state.

      Returns HTMLElement

      The rendered element.