Skip to content

grafit-charts


Interface: HierarchyItemStylerParams ​

What the item styler of a treemap or a sunburst is handed: any node of the tree, a branch as much as a leaf. The color a branch is styled with is the fill its children are handed, so painting a branch paints all of it.

Properties ​

datum ​

datum: Datum


depth ​

depth: number

0 for the roots.


fill ​

fill: string

The color the node would have without the styler: its parent's, or the palette's for a root.


highlighted ​

highlighted: boolean


index ​

index: number

Index of the node, counted the way events and the tooltip count them — depth first.


label ​

label: string

Name of the node (labelField).


leaf ​

leaf: boolean

Whether the node has no children.


share ​

share: number

Share of the chart total, 0..1.


value ​

value: number

Size of the node: its own for a leaf, the sum of its children for a branch.