fix: 监测曲线功能优化。

This commit is contained in:
tianyongbao
2026-01-11 16:22:55 +08:00
parent e0a52e4430
commit 1fdbc95b49
2 changed files with 15 additions and 0 deletions

View File

@@ -455,6 +455,8 @@ const updateChart = () => {
type: chartType.value,
data: yData,
smooth: chartType.value === 'line',
symbol: 'circle', // 使用圆形标记
symbolSize: chartType.value === 'line' ? 0 : 6, // 折线图默认不显示点,柱状图不受影响
itemStyle: {
color: config.color
},
@@ -463,6 +465,17 @@ const updateChart = () => {
} : undefined,
areaStyle: chartType.value === 'line' ? {
opacity: 0.1
} : undefined,
emphasis: chartType.value === 'line' ? {
symbol: 'circle',
symbolSize: 12,
itemStyle: {
color: config.color,
borderColor: '#fff',
borderWidth: 3,
shadowBlur: 8,
shadowColor: config.color
}
} : undefined
}
]