Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Cheap tricks for Interaction

Public visualization

Cheap tricks for Interaction

0 stars0🌍 Public
Ppkcesar
Last edited May 26, 2020
Created on May 26, 2020

This example demonstrates a world map with smooth zoom and pan interaction, achieved using D3 v5’s `zoom` behavior. Hovering over countries highlights them in red, while the base map renders with a blue sphere outline and a green country fill. The visualization uses `d3.geoNaturalEarth1` for the projection and `d3.geoPath` to draw geometries from TopoJSON world-atlas data, with country names loaded from a TSV file and attached as `title` tooltips. The zoom transform is applied to a group element containing all map paths.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed