From 3fc0098b65dde91d1c68ac32aec7fe419e10f84c Mon Sep 17 00:00:00 2001 From: junjun Date: Tue, 7 Jun 2022 13:47:17 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E5=9B=BE=E8=A1=A8?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E9=BB=98=E8=AE=A4=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/views/chart/chart/chart.js | 29 +++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/frontend/src/views/chart/chart/chart.js b/frontend/src/views/chart/chart/chart.js index dcf3b75094..2fb841598d 100644 --- a/frontend/src/views/chart/chart/chart.js +++ b/frontend/src/views/chart/chart/chart.js @@ -41,6 +41,7 @@ export const DEFAULT_SIZE = { gaugeMax: 100, gaugeStartAngle: 225, gaugeEndAngle: -45, + gaugeTickCount: 5, dimensionFontSize: 18, quotaFontSize: 18, spaceSplit: 10, @@ -70,6 +71,13 @@ export const DEFAULT_LABEL = { gaugeFormatter: '{value}', labelLine: { show: true + }, + gaugeLabelFormatter: { + type: 'value', // auto,value,percent + unit: 1, // 换算单位 + suffix: '', // 单位后缀 + decimalCount: 2, // 小数位数 + thousandSeparator: true// 千分符 } } export const DEFAULT_TOOLTIP = { @@ -163,6 +171,13 @@ export const DEFAULT_XAXIS_STYLE = { max: null, split: null, splitCount: null + }, + axisLabelFormatter: { + type: 'auto', // auto,value,percent + unit: 1, // 换算单位 + suffix: '', // 单位后缀 + decimalCount: 2, // 小数位数 + thousandSeparator: true// 千分符 } } export const DEFAULT_YAXIS_STYLE = { @@ -194,6 +209,13 @@ export const DEFAULT_YAXIS_STYLE = { max: null, split: null, splitCount: null + }, + axisLabelFormatter: { + type: 'auto', // auto,value,percent + unit: 1, // 换算单位 + suffix: '', // 单位后缀 + decimalCount: 2, // 小数位数 + thousandSeparator: true// 千分符 } } export const DEFAULT_YAXIS_EXT_STYLE = { @@ -225,6 +247,13 @@ export const DEFAULT_YAXIS_EXT_STYLE = { max: null, split: null, splitCount: null + }, + axisLabelFormatter: { + type: 'auto', // auto,value,percent + unit: 1, // 换算单位 + suffix: '', // 单位后缀 + decimalCount: 2, // 小数位数 + thousandSeparator: true// 千分符 } } export const DEFAULT_BACKGROUND_COLOR = {