Fix building of a chart component.