API REFERENCE

plotBands

Gauge plot bands — an array (property), or 'auto' for %-of-max zones.

Definition

ItemValue
JavaScript propertyplotBands
HTML attributePass objects, arrays, and callbacks as JavaScript properties
TypeGaugePlotBand[] | 'auto'
Defaultundefined
Literals in the typeauto

undefined means this property was not explicitly set. The effective value may depend on the chart type and other settings.

Configuration example

javascript
// Register sy-gauge-chart and create the element before configuring it.
chart.plotBands = [
  {
    "from": 0,
    "to": 120,
    "color": "#16a34a"
  },
  {
    "from": 120,
    "to": 160,
    "color": "#f59e0b"
  },
  {
    "from": 160,
    "to": 200,
    "color": "#dc2626"
  }
];