Maplibre Map
Displays a MapLibre based map.
Parameters
The modifier to be applied to the layout.
The URI or JSON of the map style to use. See MapLibre Style.
The camera state specifies what position of the map is rendered, at what zoom, at what tilt, etc.
The allowable camera zoom range.
The allowable camera pitch range.
The allowable bounds for the camera position. On iOS and Web, it prevents the camera edges from going out of bounds. If null is provided, the bounds are reset. On Android, it prevents the camera center from going out of bounds. See this GH Issue.
Invoked when the map is clicked. A click callback can be defined per layer, too, see e.g. the onClick parameter for LineLayer. However, this callback is always called first and can thus prevent subsequent callbacks to be invoked by consuming the event.
Invoked when the map is long-clicked. See onMapClick.
Invoked on every rendered frame.
kermit logger to use.
Invoked when the map failed to load.
Invoked when the map finished loading.
The map content additional to what is already part of the map as defined in the base map style linked in baseStyle.
Additional sources can be added via:
rememberVectorSource (see VectorSource),
A source that is already defined in the base map style can be referenced via getBaseSource.
The data from a source can then be used in layer definition(s), which define how that data is rendered, see:
BackgroundLayer
LineLayer
FillExtrusionLayer
FillLayer
HeatmapLayer
HillshadeLayer
LineLayer
RasterLayer
SymbolLayer
By default, the layers defined in this scope are put on top of the layers from the base style, in the order they are defined. Alternatively, it is possible to anchor layers at certain layers from the base style. This is done, for example, in order to add a layer just below the first symbol layer from the base style so that it isn't above labels. See: