mirror of
https://github.com/ngfchl/ptools
synced 2023-07-10 13:41:22 +08:00
优化显示提示位置
This commit is contained in:
@@ -594,22 +594,21 @@
|
||||
params.forEach((param, index) => {
|
||||
let temp = param.value == 0 ? '' : `
|
||||
<div style="display: block;height:20px;width: 50%;float:left;">
|
||||
<i style="width: 10px;height: 10px;display: inline-block;background: ${param.color};border-radius: 10px;"></i>
|
||||
<span>${param.seriesName}: ${renderSize(param.value)}</span>
|
||||
<span style="float: float:left;"><i style="width: 10px;height: 10px;display: inline-block;background: ${param.color};border-radius: 10px;"></i>${param.seriesName}: </span>
|
||||
<span style="float: float:right;">${renderSize(param.value)}</span>
|
||||
</div>
|
||||
`
|
||||
text += temp
|
||||
})
|
||||
|
||||
return `<div style="width: 300px;">${text}</div>`
|
||||
},
|
||||
//position: function (point, params, dom, rect, size) {
|
||||
// return [point[1], 0]
|
||||
//},
|
||||
|
||||
position: function (point, params, dom, rect, size) {
|
||||
console.log(point)
|
||||
return [point[1], 8]
|
||||
},
|
||||
order: 'valueDesc',
|
||||
confine: false,
|
||||
extraCssText: 'box-shadow: 0 0 3px rgba(0, 0, 0, 0.3);z-index: 9999;', // 附加阴影样式
|
||||
extraCssText: 'box-shadow: 0 0 3px rgba(0, 0, 0, 0.3);', // 附加阴影样式
|
||||
},
|
||||
legend: {
|
||||
show: false,
|
||||
|
||||
Reference in New Issue
Block a user