Skip to main content

Sunburst Chart

A sunburst chart component built using Recharts v3. Visualize hierarchical data in concentric rings with customizable colors, gradients, and glow effects.

Installation

$ npx shadcn@latest add @orecus/sunburst-chart
Registry:
@orecus/chart@orecus/color-utils@orecus/chart-utils@orecus/card

Component

Tech Stack Distribution

Hierarchical view of technology usage

Organization Structure

Team distribution across departments

Props

PropTypeDefaultDescription
data*{ name: string; value?: number; children?: SunburstDataItem[] }Hierarchical data tree with optional children
colorsThemeColor[]Colors for rings/segments
colorStyle'default' | 'gradient''gradient'Segment fill style
glowbooleantrueAdd glow effect behind segments
innerRadiusnumber | string0Inner radius (center hole)
outerRadiusnumber | string'80%'Outer radius
cxnumber | string'50%'Center X position
cynumber | string'50%'Center Y position
showLabelsbooleantrueShow labels on segments
labelType'value' | 'percent' | 'name''name'Label content type
showLegendbooleantrueShow chart legend
cardPropsCardPropsProps to pass to the underlying Card component
tooltipSortByValuebooleanfalseSort tooltip items by value (descending)
legendIndicator'square' | 'circle' | 'line''square'Shape of legend indicators
legendShowValuesbooleanfalseShow values in legend
legendWrapbooleantrueAllow legend items to wrap