✨ feat: 左上折线图tooltip加单位
This commit is contained in:
parent
7577e6c29c
commit
4f70d910cb
|
@ -41,7 +41,29 @@ export default {
|
|||
id: "main",
|
||||
Xdata: [],
|
||||
Ydata: [],
|
||||
option: {},
|
||||
option: {
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "cross",
|
||||
label: {
|
||||
backgroundColor: "#6a7985",
|
||||
},
|
||||
},
|
||||
formatter: function (params) {
|
||||
return (
|
||||
`${params[0].name}
|
||||
<br />
|
||||
${params[0].marker}
|
||||
读数
|
||||
:
|
||||
<strong>${params[0].value}</strong>
|
||||
mg/m³
|
||||
`
|
||||
);
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
refreshDebounce: null,
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue