The Sunburst Chart component for Retool Apps
A content area to display sunburst charts.
The Sunburst Chart component renders hierarchical data in a series of concentric rings. Sunburst Chart is useful for visualizing parent-child relationships and how parts make up a whole.
For more information about using the Sunburst Chart component, refer to the charts guide.
Properties
All properties for this object with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read property values.
chartType
The type of chart to display.
Type | string | ||||||||||||||||||||||||||||||||||||||||||
Format | Plain Text | ||||||||||||||||||||||||||||||||||||||||||
Mutability |
| ||||||||||||||||||||||||||||||||||||||||||
Allowed Values |
|
Examples
clearOnEmptyData
Whether to clear the chart when the data is empty.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
colorArray
A list of colors to use when colorInputMode
is colorArray
.
Type | array | ||||
Format | Color | ||||
Array values | string | ||||
Mutability |
|
Examples
colorArrayDropDown
A list of colors to use when colorInputMode
is colorArrayDropDown
.
Type | array | ||||
Format | Color | ||||
Array values | string | ||||
Mutability |
|
Examples
colorInputMode
The mode for the color input.
Type | string | ||||||||||||
Format | Plain Text | ||||||||||||
Mutability |
| ||||||||||||
Allowed Values |
| ||||||||||||
Default |
|
Examples
datasource
The source data when using UI Form.
Type | array | ||||
Array values | object | ||||
Mutability |
|
datasourceMode
The data source mode.
Type | string | ||||||
Mutability | Read-only | ||||||
Allowed Values |
|
gradientColorArray
A list of colors to use when colorInputMode
is gradientColorArray
.
Type | array | ||||
Format | Color | ||||
Array values | string | ||||
Mutability |
|
hidden
Whether this object is hidden from view.
Type | boolean | ||||||
Format | True/False | ||||||
Mutability |
| ||||||
Default |
|
Examples
hoverTemplate
The tooltip template for displaying information when you hover over a point.
Type | string | ||||
Format | Plain Text | ||||
Mutability |
| ||||
Default |
|
Examples
hoverTemplateMode
Whether the hover tooltip text maps from available options or is manually specified.
Type | string | ||||||
Format | Plain Text | ||||||
Mutability |
| ||||||
Allowed Values |
|
id
The unique identifier (name).
Type | string | ||||
Format | Plain Text | ||||
Mutability |
| ||||
Default |
|
Examples
isHiddenOnDesktop
Whether to show or hide this object in the desktop layout.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
isHiddenOnMobile
Whether to show or hide this object in the mobile layout.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
labelData
A list of labels for each node.
Type | array | ||||
Array values | string | ||||
Mutability |
| ||||
Default |
|
Examples
labelDataMode
Whether labels map from a selected option or are manually specified.
Type | string | ||||||
Format | Plain Text | ||||||
Mutability |
| ||||||
Allowed Values |
|
legendPosition
The position of the legend.
Type | string | ||||||||||||||||||
Mutability |
| ||||||||||||||||||
Allowed Values |
|
maintainSpaceWhenHidden
Whether to take up space on the canvas if hidden
is true
.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
margin
The amount of margin to render outside.
Type | string | |||||||||
Format | Plain Text | |||||||||
Mutability |
| |||||||||
Allowed Values |
| |||||||||
Default |
|
Examples
parentData
The parent to which a given node is associated.
Type | array | ||||
Array values | string | ||||
Mutability |
|
showInEditor
Whether the component remains visible in the editor if hidden
is true
.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
sunburstDataBranchValues
The branch values for the Sunburst Chart.
Type | string | ||||||
Mutability |
| ||||||
Allowed Values |
|
sunburstDataLeafOpacity
The opacity of the leaf nodes in the Sunburst Chart.
Type | number | ||||
Mutability |
|
textTemplate
The format to use for data labels, constructed in Plotly template format.
Type | string | ||||
Mutability |
|
textTemplateMode
Whether the text template is in manual mode.
Type | string | ||||||
Format | Plain Text | ||||||
Mutability | Read-only | ||||||
Allowed Values |
|
textTemplatePosition
The orientation of the data labels.
Type | string | ||||||||
Mutability |
| ||||||||
Allowed Values |
|
toolbar
The toolbar configuration.
Type | object | ||||
Mutability |
|
Object Properties
valueData
The value for a specific node.
Type | array | ||||
Array values | number | ||||
Mutability |
|
valueDataMode
Whether values map from a selected option or are manually specified.
Type | string | ||||||
Format | Plain Text | ||||||
Mutability |
| ||||||
Allowed Values |
|
Methods
JavaScript API methods for this object. You can write JavaScript almost anywhere in Retool and use methods to manipulate data and property values.
sunburstChart.scrollIntoView()
Scrolls the canvas or parent container so that the selected component appears in the visible area.
sunburstChart.scrollIntoView(options)
Parameters
Examples
sunburstChart.setHidden()
Set the hidden
value to toggle whether the component is visible. Defaults to true
without a parameter.
sunburstChart.setHidden(hidden)
Parameters
Examples
Events
Events triggered by user interactions. You can configure event handlers in the IDE to trigger queries or other actions in response to events.
Event | Description |
---|---|
Clear | A value is cleared. |
Hover | An item is hovered over. |
Legend Click | A legend item is clicked or pressed. |
Legend Double Click | A legend item is double-clicked or pressed. |
Select | A value is selected. |
Unhover | An item is no longer hovered over. |