public function ChartsOverridesChartjs::chartOverrides in Charts 8.3
Builds an array of Chart Settings with key value pairs
Parameters
$settings array:
Return value
array
Overrides ChartjsOverrides::chartOverrides
File
- starterkits/
charts_overrides/ src/ Plugin/ override/ ChartsOverridesChartjs.php, line 17
Class
- ChartsOverridesChartjs
- Defines a concrete class for a Billboard.
Namespace
Drupal\charts_overrides\Plugin\overrideCode
public function chartOverrides(array $originalOptions = []) {
$options = [];
// The following are currently available for overriding; they are the
// private variables in
// charts_chartjs/src/Settings/Chartjs/ChartjsChart.php
//
// An example of how to override the field_colors property.
// $options['field_colors'] = [
// 'field_one': '#2f7ed8',
// 'field_two': '#8bbc21'
// ];
return $options;
}