我无法更改标签的字体。如下所示,我有一个标签为"# of votes"
的标签和另一个标签为"# of points"
的标签。我想为他们增加尺寸。所以我什至添加了以下内容:
label: {
fontSize: 50
},
但是 我没有运气
我的JS代码
var options = {
type: 'line',
data: {
labels: ["Red", "Blue", "Yellow", "Green", "Purple", "Orange"],
datasets: [
{
label: '# of Votes',
data: [12, 19, 3, 5, 2, 3],
borderWidth: 1,
backgroundColor: 'rgba(255, 0, 15, 0.54)'
},
{
label: '# of Points',
data: [7, 11, 5, 8, 3, 7],
borderWidth: 1
}
]
},
options: {
label: {
fontSize: 50
},
scales: {
yAxes: [{
ticks: {
reverse: false
}
}]
}
}
}
var ctx = document.getElementById('chartJSContainer').getContext('2d');
new Chart(ctx, options);
答案 0 :(得分:2)
尝试类似的方法(在我的项目中效果很好):
a1<=a2, b1<=b2, c1<=c2