-
Improvement
-
Resolution: Fixed
-
Major
-
3.8.2, 3.9
-
MOODLE_38_STABLE, MOODLE_39_STABLE
-
MOODLE_39_STABLE
-
MDL-68477-master -
This patch branch provides a means to set legend options as per: https://www.chartjs.org/docs/2.7.0/configuration/legend.html
It adds a field, setters and getters to the Base chart classes in PHP and Javascript. From Moodle, it is invoked via e.g.: $chart->set_legend_options(array('position' => 'bottom', 'reverse' => true))
At this point, specifying onClick and onHover events is not directly supported via this method. Dynamically creating functions out of strings is not permitted by the ESLint no-new-func directive, and it's arguable as to whether that would be a good approach to take in the first place.
- has a non-specific relationship to
-
MDL-68386 Charts API: support for Area Chart fill values from Chart.js
- Closed