Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

mouseMove

Public visualization

mouseMove

0 stars1🌍 Public
RRuanzhenglin
Last edited Apr 13, 2021
Created on Apr 13, 2021

This example shows a single yellow circle centered in an SVG canvas that responds to mouse movement. The visualization uses React to render the SVG element and attaches a `handleMouseMove` event handler that logs the cursor’s client coordinates to the console, though no visual feedback is drawn. The circle has a fixed radius of 30 pixels, and the canvas dimensions are set to 960 by 500. The code imports the `arc` function from D3 v6 but does not use it; instead, it relies on React’s event system and SVG circle element for the core interaction.

AI-generated description

Half way towards a smiley face

Comments

Sign in to join the discussion.

MIT Licensed