稳态、暂态电能质量,稳态质量效果各个弹框
This commit is contained in:
@@ -15,6 +15,7 @@ import { color, gradeColor3 } from './color'
|
||||
import { useConfig } from '@/stores/config'
|
||||
// import { nextTick } from 'process'
|
||||
|
||||
const emit = defineEmits(['chartClick'])
|
||||
const config = useConfig()
|
||||
color[0] = config.layout.elementUiPrimary[0]
|
||||
const chartRef = ref<HTMLDivElement>()
|
||||
@@ -89,7 +90,7 @@ const initChart = () => {
|
||||
...(props.options?.legend || null)
|
||||
},
|
||||
grid: {
|
||||
top: '50px',
|
||||
top: '50px',
|
||||
left: '30px',
|
||||
right: '70px',
|
||||
bottom: props.options?.options?.dataZoom === null ? '10px' : '40px',
|
||||
@@ -131,6 +132,10 @@ const initChart = () => {
|
||||
// 处理柱状图
|
||||
chart.setOption(options, true)
|
||||
chart.group = 'group'
|
||||
// 添加点击事件
|
||||
chart.on('click', function (params: any) {
|
||||
emit('chartClick', params)
|
||||
})
|
||||
setTimeout(() => {
|
||||
chart.resize()
|
||||
}, 0)
|
||||
|
||||
Reference in New Issue
Block a user