Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Mike Bostock's zoom

Public visualization

Mike Bostock's zoom

0 stars0🌍 Public
11andrey3
Last edited Dec 4, 2018
Created on Dec 4, 2018
Forked from Hello VizHub

This example displays a zoomable, gradient-filled rectangle with corresponding axis tick lines that rescale smoothly as the user pans and zooms. The visualization uses D3 v5’s `d3.zoom` behavior with `scaleExtent` and `translateExtent` limits, and applies the zoom transform to both a styled `<rect>` and axes via `d3.axisBottom` and `d3.axisRight`. A reset button triggers a 750-millisecond transition back to the identity transform. The SVG background uses a linear gradient with ten color stops, and the axis lines are drawn with reduced stroke opacity.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed