chart
The chart widget is suitable for displaying the <line-chart, bar-chart, or pie-chart on the Home Hub.
Configuration options
chart
The configuration is the same as for the chart components, refer to the line-chart, bar-chart, or pie-chart examples.
bottom
The titles component will be added to the bottom of the widget.
footer
Add text to the footer of the widget.
footerAlign
Align the footer text to left, right, center.
placeholders
Specify a placeholder text to display if there is no data, for example - title: No data to display.
top
The titles component will be added to the top of the widget.
Considerations
It is recommended to set either the
top,bottom, or both properties when configuring a chart widget to ensure it renders correctly and maintains a clear, readable layout within the widget.
Examples and code snippets
Chart widget: line-chart component (2x2)
In this example select the chart widget and add a component.line-chart and add a component.trend at the top to show the positive percentage trend and a component.titles at the bottom.
Example: See the complete example in GitHub.
widgets:
line1-2x2:
# select chart widget and then add the compoments trend and line-chart
type: widget.chart
options:
top:
type: component.trend
options:
title: Quarterly Revenue
style:
isAlignRight: false
isValueBottom: true
value: 0.911111111111
format:
numberStyle: percent
chart:
type: component.line-chart
options:
legend:
isHidden: false
series:
- data: [email protected]
dataLabels:
- isEnabled: true
name: Quarterly Revenue 2020
layout: area-gradient
xAxis:
categories:
- Q1
- Q2
- Q3
- Q4
yAxis:
isFirstLabelHidden: true
isFirstTickHidden: true
labels:
format:
compactDisplay: long
notation: compact
numberStyle: currency
min: 0
tickAmount: 3
bottom:
type: component.titles
options:
subtitle: Updated 1 min ago
align: centerChart widget: line-chart component (2x4)
In this example select the chart widget and add a component.line-chart and add a component.title at the top.
Example: See the complete example in GitHub.
Chart widget: line-chart component (4x4)
Chart widget - line-chart component (4x2)

This example is configured using a line-chart to display in the chart widget.
Examples: See the complete example using static data in GitHub. See the complete example using dynamic data in GitHub.
Datasources: See the complete datasource for static data in GitHub. See the complete datasource for dynamic data in GitHub
Chart widget: line-chart component in group widget (4x4)
In this example two line-chart widgets are combined in the group widget with the component.titles to add additional information.
Example: See the complete example in GitHub.
Chart widget: bar-chart component (2x2)
In this example select the chart widget and add a component.bar-chart and add a component.trend at the top.
Example: See the complete example in GitHub.
Chart widget: bar-chart component (4x2)
In this example a chart widget is used with the component.bar-chart and component.titles at the top to add a title and subtitle.
Example: See the complete example in GitHub.
Chart widget: bar-chart component (4x2)

This example is configured using a bar-chart to display in the chart widget.
Examples: See the complete example using static data in GitHub. See the complete example using dynamic data in GitHub.
Datasources: See the complete datasource for static data in GitHub. See the complete datasource for dynamic data in GitHub.
Chart widget: pie-chart component (2x2)

This example is configured using a pie-chart to display in the chart widget.
Examples: See the complete example using static data in GitHub. See the complete example using dynamic data in GitHub.
Datasources: See the complete datasource for static data in GitHub. See the complete datasource for dynamic data in GitHub.
Chart widget: pie-chart component (2x4)
In this example a chart widget is used with the component.pie-chart and component.titles at the top and bottom to add additional information.
Example: See the complete example in GitHub.
Chart widget: pie-chart component in group widget (4x4)
In this example a group widget is used to combine a chart and list widget with component.pie-chart and component.titles at the top to add additional information.
Example: See the complete example in GitHub.
Last updated
Was this helpful?