未验证 提交 77655b72 编写于 作者: A abigale Li 提交者: GitHub

resolve histogram hover circle problem (#153)

上级 80a97ff6
......@@ -22,6 +22,11 @@ module.exports = function (path, queryParam, postParam) {
{
"displayName": "layer1/Wx_plus_b/pre_activations",
"description": ""
},
"layer1/Wx_plus_b/pre_activations_1":
{
"displayName": "layer1/Wx_plus_b/pre_activations_1",
"description": ""
}
}
}
......
......@@ -24,6 +24,7 @@ import {format, precisionRound} from 'd3-format';
import {getPluginHistogramsHistograms} from '../../service';
let zrDrawElement = {};
zrDrawElement.hoverDots = [];
// the time to refresh chart data
const intervalTime = 15;
......@@ -152,6 +153,9 @@ export default {
},
yAxis: {
type: 'value',
axisLine: {
onZero: false
},
axisLabel: {
formatter(value, index) {
return yValueFormat(value);
......@@ -224,6 +228,11 @@ export default {
axisLine: {
onZero: false
},
axisLabel: {
formatter: function (value) {
return Math.round(value * 100) / 100;
}
},
splitLine: {
show: false
}
......@@ -283,8 +292,6 @@ export default {
return pt;
}
zrDrawElement.hoverDots = [];
let zr = ecChart.getZr();
function removeTooltip() {
......@@ -361,7 +368,7 @@ export default {
zrDrawElement.tooltip = new echarts.graphic.Text({
position: [e.offsetX + 30, e.offsetY - 50],
style: {
text: hoveredItem.items[nearestIndex.binIndex][3],
text: yValueFormat(hoveredItem.items[nearestIndex.binIndex][3]),
textFill: '#000',
fontSize: 14,
textBackgroundColor: '#eee',
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册