fix: 监测曲线功能优化。
This commit is contained in:
1
src/types/components.d.ts
vendored
1
src/types/components.d.ts
vendored
@@ -36,6 +36,7 @@ declare module 'vue' {
|
|||||||
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
||||||
ElIcon: typeof import('element-plus/es')['ElIcon']
|
ElIcon: typeof import('element-plus/es')['ElIcon']
|
||||||
ElInput: typeof import('element-plus/es')['ElInput']
|
ElInput: typeof import('element-plus/es')['ElInput']
|
||||||
|
ElInputNumber: typeof import('element-plus/es')['ElInputNumber']
|
||||||
ElMenu: typeof import('element-plus/es')['ElMenu']
|
ElMenu: typeof import('element-plus/es')['ElMenu']
|
||||||
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
||||||
ElOption: typeof import('element-plus/es')['ElOption']
|
ElOption: typeof import('element-plus/es')['ElOption']
|
||||||
|
|||||||
@@ -455,6 +455,8 @@ const updateChart = () => {
|
|||||||
type: chartType.value,
|
type: chartType.value,
|
||||||
data: yData,
|
data: yData,
|
||||||
smooth: chartType.value === 'line',
|
smooth: chartType.value === 'line',
|
||||||
|
symbol: 'circle', // 使用圆形标记
|
||||||
|
symbolSize: chartType.value === 'line' ? 0 : 6, // 折线图默认不显示点,柱状图不受影响
|
||||||
itemStyle: {
|
itemStyle: {
|
||||||
color: config.color
|
color: config.color
|
||||||
},
|
},
|
||||||
@@ -463,6 +465,17 @@ const updateChart = () => {
|
|||||||
} : undefined,
|
} : undefined,
|
||||||
areaStyle: chartType.value === 'line' ? {
|
areaStyle: chartType.value === 'line' ? {
|
||||||
opacity: 0.1
|
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
|
} : undefined
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Reference in New Issue
Block a user