Skip to main content
ChartStyleOptions
Basic style options for a chart.
NameTypeDescription
backgroundColor?stringBackground color for chart. Defaults to #FFFFFF. You can also use the .vjs-chart-background css class to set this.
crosshairColor?stringWhat color to draw crosshairs
gridLineColor?stringWhat color to draw gridlines. Defaults to #AAAAAA.
labelColor?stringColor for labels, defaults to #000000. Can be overridden in axis definitions via the labelColor property.
labelColorGenerator?(v:number, idx:number) => stringOptional function invoked to compute a custom color for a given label
legendBackgroundColor?stringBackground color for the legend.
legendOutlineColor?stringWhat color to draw as outline for the legend
legendOutlineWidth?numberWidth of the legend outline
plotBackgroundColor?stringBackground color for chart's plot area. Defaults to being the same as the value calculated for backgroundColor. You can also use the .vjs-chart-plot-background css class to set this.