Chart.js/test/fixtures/scale.radialLinear/gridlines-scriptable.js
Evert Timberg d315934513
Radial scale scriptable options (#7471)
Scriptable radialLinear options
2020-06-11 08:49:54 -04:00

35 lines
594 B
JavaScript

module.exports = {
config: {
type: 'radar',
data: {
labels: ['A', 'B', 'C', 'D', 'E']
},
options: {
responsive: false,
legend: false,
title: false,
scale: {
gridLines: {
display: true,
color: function(context) {
return context.index % 2 === 0 ? 'red' : 'green';
},
lineWidth: function(context) {
return context.index % 2 === 0 ? 1 : 5;
},
},
angleLines: {
color: 'rgba(255, 255, 255, 0.5)',
lineWidth: 2
},
pointLabels: {
display: false
},
ticks: {
display: false
}
}
}
}
};