物业之前,新工作台
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
<script name="repairEcharts" setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
import Echarts from '@/components/Echarts/index.vue';
|
||||
import { EChartsOption } from 'echarts';
|
||||
|
||||
@@ -15,7 +14,7 @@ const chartConfig = shallowRef<EChartsOption>({
|
||||
grid: {
|
||||
left: '1%',
|
||||
right: '1%',
|
||||
top: '3%',
|
||||
top: '10%',
|
||||
bottom: '1%',
|
||||
containLabel: true
|
||||
},
|
||||
@@ -27,10 +26,21 @@ const chartConfig = shallowRef<EChartsOption>({
|
||||
},
|
||||
series: [
|
||||
{
|
||||
data: [820, 932, 901, 934, 1290, 1330, 1320],
|
||||
data: [5, 92, 12, 34, 120, 10, 120],
|
||||
type: 'line',
|
||||
smooth: true,
|
||||
areaStyle: {
|
||||
color: '#d1e3ff'
|
||||
color: {
|
||||
type: 'linear',
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 0,
|
||||
y2: 1, // 从上到下渐变
|
||||
colorStops: [
|
||||
{ offset: 0, color: '#e2edff' }, // 顶部:半透明蓝色
|
||||
{ offset: 1, color: '#f2f9ff' } // 底部:极浅蓝/透明
|
||||
]
|
||||
}
|
||||
},
|
||||
lineStyle: {
|
||||
color: '#1a75ff'
|
||||
@@ -40,10 +50,30 @@ const chartConfig = shallowRef<EChartsOption>({
|
||||
color: '#3f8afc',
|
||||
position: 'top'
|
||||
}
|
||||
},
|
||||
{
|
||||
data: [5, 92, 12, 34, 120, 10, 120].reverse(),
|
||||
type: 'line',
|
||||
smooth: true,
|
||||
areaStyle: {
|
||||
color: {
|
||||
type: 'linear',
|
||||
x: 0,
|
||||
y: 0,
|
||||
x2: 0,
|
||||
y2: 1, // 从上到下渐变
|
||||
colorStops: [
|
||||
{ offset: 0, color: '#e2edff' }, // 顶部:半透明蓝色
|
||||
{ offset: 1, color: '#f2f9ff' } // 底部:极浅蓝/透明
|
||||
]
|
||||
}
|
||||
},
|
||||
lineStyle: {
|
||||
color: '#ffc800'
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
||||
// 图表配置不应该被深度响应式劫持,会导致性能下降 + 类型错误。
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
Reference in New Issue
Block a user