Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Bowl of Fruit-Hover to Select

Public visualization

Viewing a saved revision (read-only)

7c818e35461140448fb229cb8d61205e

Bowl of Fruit-Hover to Select

0 stars0🌍 Public
Ssgzzhinde
Last edited Jan 4, 2021
Created on Jan 4, 2021

D3 v5 renders five apples as SVG circles that smoothly grow into place, then shrink and vanish when items are removed. Hovering highlights a fruit with a black stroke while updating the `selectedFruit` state. The code uses the general update pattern with `data()` joins, `merge()`, `exit()`, and `transition()` for animation, alongside ordinal scales for color and radius mapping.

AI-generated description