Atmosphere
Enhance your map with atmospheric effects using the Atmosphere component.
The Atmosphere component allows you to add and customize atmospheric effects like fog, helping to set the mood or highlight certain areas on your map. It provides an easy way to control the appearance of the atmosphere using a declarative syntax.
Props
The component accepts the following properties (props):
style
object
An object specifying the style properties of the atmosphere element according to Mapbox's Atmosphere style specification.
{}
(The default atmosphere style used by the map style)
Note: All properties are optional. If omitted, the map's default atmosphere style will be applied.
Example
To utilize the Atmosphere component, import it from solid-map-gl
and include it within your MapGL
component. Below is a simple example demonstrating how to add the Atmosphere component to your map and specify its style properties:
Through this example, the Atmosphere
component is applied to the map, enhancing the visual depth and adding an ethereal effect that blends the horizon with the sky. Customize the atmosphereStyle
object to experiment with different looks and find the perfect ambiance for your map.
Last updated