Skip to content

Sunburst

Examples

Revenue › Events

API Reference

Types come from the public API. A dash indicates no default is documented here.

SunburstChart props

Public source
PropTypeDefaultDescription
keyKeepAliveKey<K, Ends> | undefined''The child's identity among its parent's children of one component, or a kept child's among its author's. The empty string by default.
onEmit
Show type
((events: { readonly _tag: "FocusChanged"; readonly id: string; } | { readonly _tag: "HoverChanged"; readonly index: number | null; }) => NoInfer<Msg> | undefined) | { readonly FocusChanged: (event: { readonly _tag: "FocusChanged"; readonly id: string; }) => NoInfer<Msg> | undefined; readonly HoverChanged: (event: { readonly _tag: "HoverChanged"; readonly index: number | null; }) => NoInfer<Msg> | undefined; } | undefined
—Handle the child's events with a callback, or supply one handler per tag for tagged events. Return a parent message to dispatch it, or `undefined` to ignore the event.
props.dataSunburstNodeRequired
props.idstringRequired
props.sizenumber—
props.centerboolean—
props.paddingnumber—
props.classNamestring—
props.ariaLabelstring
Varies
  • ''
  • `Sunburst chart of ${h.props.data.name}`
props.breadcrumbboolean—
props.labels
Show type
{ readonly fill?: string; readonly stroke?: string; readonly fontSize?: number; readonly strokeWidth?: number; }
—
props.enterTransition
Show type
{ readonly delay?: number; readonly duration?: number; readonly ease?: string | readonly number[] | readonly (string | readonly number[])[]; readonly type?: unknown; readonly stiffness?: number; readonly damping?: number; readonly mass?: number; readonly bounce?: number; }
—
props.hoveredIndexnumber | null
Varies
  • -1
  • null
props.enterStaggerScalenumber—
props.playKeynumber—
props.focusIdstring
Varies
  • focusId
  • null
props.hoverPopnumber—
props.segments
Show type
readonly { readonly index: number; readonly fill?: string; readonly color?: string; readonly fillOpacity?: number; }[]
[]
props.hintboolean—