Prop
colors
string[]Change the default colors.
index
stringRequired*Sets the key to map the data to the axis.
data
Record<string, any>[]Required*The source data, in which each entry is a dictionary.
margin
SpacingMargin of each the container
filterOpacity
numberChange the opacity of the non-selected field
showTooltip
booleanControls the visibility of tooltip.
showLegend
booleanControls the visibility of legend.
category
stringRequired*Sets the name of the key containing the quantitative chart values.
type
'donut' | 'pie'Change the type of the chart
sortFunction
((a: any, b: any) => number)Function to sort the segment
valueFormatter
((tick: number, i?: number, ticks?: number[]) => string)Controls the formatting for the label.
customTooltip
ComponentRender custom tooltip component.