The CirclePacking
component is available in the nivo
HTTP rendering API.
The API generates a SVG and return a path to this SVG
which can then be easily embedded.
The api accepts almost the same properties as the regular component, in json, however it's not interactive and you cannot use code in properties (functions).
Please note that the demo API server is installed on heroku using a free plan, so it might be unavailable from times to times.
no response available
Chart data, which should be immutable.
'id'
Id accessor.
'value'
Value accessor
Optional formatter for values.
0
Padding between each circle.
false
Only render leaf nodes (skip parent nodes).
Chart width.
Chart height.
'Depends on device'
Adjust pixel ratio, useful for HiDPI screens.
Chart margin.
Define style for common elements such as labels, axes…
Define chart's colors.
'depth'
Define the property to use to assign a color to circles.
false
Inherit color from parent node starting from 2nd level.
Defines how to compute child nodes color, only used when inheritColorFromParent is enabled.
0
Width of circle border.
Method to compute border color.
Define patterns and gradients.
Define rules to apply patterns and gradients
Custom circle component.
false
Enable/disable labels.
'id'
Label accessor.
Filter labels using custom conditions.
8
Skip label rendering if node radius is lower than given value, 0 to disable.
Method to compute label text color.
Custom label component.
true
Enable/disable interactivity.
onMouseEnter handler, it receives target node data and mouse event.
onMouseMove handler, it receives target node data and mouse event.
onMouseLeave handler, it receives target node data and mouse event.
onClick handler, it receives target node data and mouse event.
Zoom on a specific node.
true
Enable/disable transitions.
'gentle'
Motion config for react-spring, either a preset or a custom configuration.