nikolas-sapa

Chart Donut Halftone

Component 22

About

A part-to-whole donut chart whose wedge fill uses ordered-dither halftone density to encode an ordinal tier order alongside wedge angle for share, with a keyboard-navigable legend and an accessible data-table toggle.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Chart Donut Halftone to your project and fits it to your theme.

Code

How Chart Donut Halftone is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import ChartDonutHalftone from "@/components/ui/chart-donut-halftone";

export default function Demo() {
  return (
    <div className="flex min-h-screen w-full items-center justify-center bg-background p-10">
      <ChartDonutHalftone
        title="Order Size Tiers"
        unit="orders"
        data={[
          { label: "S", value: 420 },
          { label: "M", value: 860 },
          { label: "L", value: 610 },
          { label: "XL", value: 240 },
        ]}
      />
    </div>
  );
}

More by nikolas-sapa

View all
  • Dye Whorl

    Dye Whorl

    138
  • Countdown Vapor Digits

    Countdown Vapor Digits

    122
  • Hero Burin Hatch

    Hero Burin Hatch

    62
  • Background ASCII Wake

    Background ASCII Wake

    55
  • Hero Text Ring Funnel

    Hero Text Ring Funnel

    48
  • Toast Gravity Stack

    Toast Gravity Stack

    46
  • Hero ASCII Schlieren

    Hero ASCII Schlieren

    45
  • Hero ASCII Reaction Front

    Hero ASCII Reaction Front

    41