Commit 0814f5f91c5d2dfc72f773660b194ca86612c7a0

Authored by ww
1 parent 5f0777fb

fix: echarts deprecated attribute

@@ -64,7 +64,7 @@ @@ -64,7 +64,7 @@
64 64
65 function update() { 65 function update() {
66 const option = beforeUpdateFn(props.layout.componentType); 66 const option = beforeUpdateFn(props.layout.componentType);
67 - unref(chartRef)?.setOption(option(unref(getRadio)) as unknown as EChartsOption); 67 + unref(chartRef)?.setOption((option(unref(getRadio)) as unknown as EChartsOption) || {});
68 unref(chartRef)?.resize(); 68 unref(chartRef)?.resize();
69 } 69 }
70 70
@@ -99,7 +99,7 @@ export const instrumentComponent1 = (params?: { value: number; unit: string }): @@ -99,7 +99,7 @@ export const instrumentComponent1 = (params?: { value: number; unit: string }):
99 // fontSize: 16, 99 // fontSize: 16,
100 fontWeight: 'bolder', 100 fontWeight: 'bolder',
101 formatter: `{value} ${unit}`, 101 formatter: `{value} ${unit}`,
102 - color: 'auto', 102 + color: 'inherit',
103 }, 103 },
104 data: [ 104 data: [
105 { 105 {
@@ -184,7 +184,7 @@ export const instrumentComponent2 = (params?: { @@ -184,7 +184,7 @@ export const instrumentComponent2 = (params?: {
184 }, 184 },
185 pointer: { 185 pointer: {
186 itemStyle: { 186 itemStyle: {
187 - color: 'auto', 187 + color: 'inherit',
188 }, 188 },
189 }, 189 },
190 axisTick: { 190 axisTick: {
@@ -205,14 +205,14 @@ export const instrumentComponent2 = (params?: { @@ -205,14 +205,14 @@ export const instrumentComponent2 = (params?: {
205 }, 205 },
206 }, 206 },
207 axisLabel: { 207 axisLabel: {
208 - color: 'auto', 208 + color: 'inherit',
209 distance: 5, 209 distance: 5,
210 fontSize: 6, 210 fontSize: 6,
211 }, 211 },
212 detail: { 212 detail: {
213 valueAnimation: true, 213 valueAnimation: true,
214 formatter: `{value} ${unit}`, 214 formatter: `{value} ${unit}`,
215 - color: 'auto', 215 + color: 'inherit',
216 fontSize: 14, 216 fontSize: 14,
217 }, 217 },
218 data: [ 218 data: [