Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

pie chart for percentage with transition, gradient color and mouse over

Public visualization

pie chart for percentage with transition, gradient color and mouse over

0 stars1🌍 Public
SSchmittYannic
Last edited Aug 10, 2020
Created on Aug 10, 2020

This example shows a donut chart displaying a percentage value, where the foreground arc animates to its final angle using a repeating transition. The arc’s color shifts through a gradient that changes based on the input percentage, with hover effects highlighting the path by increasing its stroke width and color. Built with D3 v5 in a React framework, the visualization uses `d3.arc`, `transition.attrTween` for smooth angle interpolation, and `linearGradient` definitions for the dynamic color stops.

AI-generated description

A bare minimum HTML page.

See also React Starter.

Comments

Sign in to join the discussion.

MIT Licensed