Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Pie Chart Render of CSS Color Data in React & D3

Public visualization

Viewing a saved revision (read-only)

2521de1f15ff44f29f513554a890bbcb

Pie Chart Render of CSS Color Data in React & D3

0 stars1🌍 Public
RRichardPearce60
Last edited Jan 28, 2022
Created on Jan 28, 2022

This visualization renders all 148 CSS named colors as segments of a single pie chart, using each color's actual hex value as its fill. The chart is built with React 17 and D3 v7, loading data from a CSV file of CSS color names. The code uses `d3.pie()` to compute arc angles and `d3.arc()` to generate SVG path shapes. Each segment is equally sized, and the resulting ring displays the full spectrum of named colors in a circular arrangement.

AI-generated description