coverage
The coverage namespace draws world-anchored coverage discs — a soft radial
fill, an optional boundary ring, and an optional animated radar pulse — around
graph nodes or explicit positions. Use it for circles of influence: cell-tower
signal, a blast / impact radius, a delivery catchment, a sensor footprint.
It is convenience sugar over api.layers: it keeps an items
map keyed by node, resolves radiusKm + latitude into world units via
api.map.groundKmToWorld, and drives a single coverage layer.
api.coverage.set(stations.map(s => ({
anchorNodeId: s.id,
radiusKm: s.rangeKm,
latitude: s.lat,
fillColor: [0.2, 0.9, 0.4],
fillOpacity: 0.12,
ringOpacity: 0.85,
pulse: { speed: 0.4, rings: 2 }, // omit for a static disc
})));
api.coverage.clear(); // all discs (or pass a nodeId for one)
For the full option reference, the declarative <CoverageLayer> alternative, and
the km-vs-world-units rules, see the
Coverage discs guide.