Back to all examples
Traffic incident focus
Bring a city's traffic incidents forward and push the rest of the map back, with one switch
One switch brings London’s incidents and boundary forward and pushes traffic flow, POIs and road labels back. Switch it off and every layer returns to its default.
- Traffic flow fades through its own
opacityFactor. styling.layers.queryselects the style’s layers by group,poisincluded, so one call fades a whole module’s layers andresetundoes it.- Those queries reach only the style’s own layers.
The incidents and the boundary take theirs through each module’s
layersconfig, set withupdateConfigand merged over the defaults rather than replacing them.
Related examples
Borrowed looks
Places, a route and fetched traffic incidents drawn in the style's own look, following the styling knobs that restyle it, live
Customization
Map Style
Places and POIs
Routing
Traffic
Web
Traffic flow with bloom
Light up live traffic over a mono dark map with the map-effects plugin's bloom.
Customization
Traffic
Map Style
Plugins
Web
Bloom playground
Every bloom knob on one panel, including the scope that decides which part of the map is allowed to glow.
Playground
Traffic
Map Style
Plugins
Web
Globe and 3D terrain
Switch the map to a globe with an atmosphere with the styling foundations module's view knobs, or raise it in 3D with the terrain module
Customization
Map Style
Terrain and 3D
Web