enhance(pages): Improve hcart

This commit is contained in:
syuilo 2020-04-19 17:41:01 +09:00
parent 8cefcaa55f
commit f704e7a602

View file

@ -98,6 +98,7 @@ export class ASEvaluator {
}, },
options: { options: {
responsive: false, responsive: false,
devicePixelRatio: 1.5,
title: { title: {
display: opts.value.has('title'), display: opts.value.has('title'),
text: opts.value.has('title') ? opts.value.get('title').value : '', text: opts.value.has('title') ? opts.value.get('title').value : '',
@ -127,8 +128,10 @@ export class ASEvaluator {
...(opts.value.get('type').value === 'radar' ? { ...(opts.value.get('type').value === 'radar' ? {
scale: { scale: {
ticks: { ticks: {
display: opts.value.has('show_tick_label') ? opts.value.get('show_tick_label').value : false,
min: opts.value.has('min') ? opts.value.get('min').value : undefined, min: opts.value.has('min') ? opts.value.get('min').value : undefined,
max: opts.value.has('max') ? opts.value.get('max').value : undefined, max: opts.value.has('max') ? opts.value.get('max').value : undefined,
maxTicksLimit: 8,
}, },
pointLabels: { pointLabels: {
fontSize: 12 fontSize: 12
@ -138,6 +141,7 @@ export class ASEvaluator {
scales: { scales: {
yAxes: [{ yAxes: [{
ticks: { ticks: {
display: opts.value.has('show_tick_label') ? opts.value.get('show_tick_label').value : true,
min: opts.value.has('min') ? opts.value.get('min').value : undefined, min: opts.value.has('min') ? opts.value.get('min').value : undefined,
max: opts.value.has('max') ? opts.value.get('max').value : undefined, max: opts.value.has('max') ? opts.value.get('max').value : undefined,
} }