mirror of
https://github.com/ansible/awx.git
synced 2026-03-20 18:37:39 -02:30
Turn off broken growOnHover feature in nv
This commit is contained in:
@@ -58,28 +58,28 @@ function HostStatusGraph($compile, $window) {
|
|||||||
];
|
];
|
||||||
|
|
||||||
host_pie_chart = nv.models.pieChart()
|
host_pie_chart = nv.models.pieChart()
|
||||||
.margin({top: 5, right: 75, bottom: 25, left: 85})
|
.margin({top: 5, right: 75, bottom: 25, left: 85})
|
||||||
.x(function(d) { return d.label; })
|
.x(function(d) { return d.label; })
|
||||||
.y(function(d) { return d.value; })
|
.y(function(d) { return d.value; })
|
||||||
.showLabels(true)
|
.showLabels(true)
|
||||||
.labelThreshold(0.01)
|
.growOnHover(false)
|
||||||
.tooltipContent(function(x, y) {
|
.labelThreshold(0.01)
|
||||||
return '<b>'+x+'</b>'+ '<p>' + Math.floor(y.replace(',','')) + ' Hosts ' + '</p>';
|
.tooltipContent(function(x, y) {
|
||||||
})
|
return '<b>'+x+'</b>'+ '<p>' + Math.floor(y.replace(',','')) + ' Hosts ' + '</p>';
|
||||||
.color(['#00aa00', '#aa0000']);
|
})
|
||||||
|
.labelType("percent")
|
||||||
host_pie_chart.pie.pieLabelsOutside(true).labelType("percent");
|
.color(['#00aa00', '#aa0000']);
|
||||||
|
|
||||||
d3.select(element.find('svg')[0])
|
d3.select(element.find('svg')[0])
|
||||||
.datum(data)
|
.datum(data)
|
||||||
.transition().duration(350)
|
.transition().duration(350)
|
||||||
.call(host_pie_chart)
|
.call(host_pie_chart)
|
||||||
.style({
|
.style({
|
||||||
"font-family": 'Open Sans',
|
"font-family": 'Open Sans',
|
||||||
"font-style": "normal",
|
"font-style": "normal",
|
||||||
"font-weight":400,
|
"font-weight":400,
|
||||||
"src": "url(/static/fonts/OpenSans-Regular.ttf)"
|
"src": "url(/static/fonts/OpenSans-Regular.ttf)"
|
||||||
});
|
});
|
||||||
|
|
||||||
adjustGraphSize();
|
adjustGraphSize();
|
||||||
return host_pie_chart;
|
return host_pie_chart;
|
||||||
|
|||||||
Reference in New Issue
Block a user