mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
[vislib/tooltip] requery the DOM for tooltip el
This commit is contained in:
parent
ab0dafb70e
commit
49b183deba
2 changed files with 4 additions and 3 deletions
|
@ -29,7 +29,8 @@ define(function (require) {
|
|||
.css({
|
||||
visibility: 'hidden',
|
||||
position: 'absolute',
|
||||
top: -100
|
||||
top: -500,
|
||||
left: -500
|
||||
})
|
||||
.appendTo('body');
|
||||
}
|
||||
|
|
|
@ -25,7 +25,6 @@ define(function (require) {
|
|||
|
||||
this.$window = $(window);
|
||||
this.$chart = $(el).find('.' + this.containerClass);
|
||||
this.$tip = $('.' + this.tooltipClass);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -52,6 +51,7 @@ define(function (require) {
|
|||
if (d3.select('body').select('.' + self.tooltipClass)[0][0] === null) {
|
||||
d3.select('body').append('div').attr('class', self.tooltipClass);
|
||||
}
|
||||
|
||||
if (self.container === undefined || self.container !== d3.select(self.el).select('.' + self.containerClass)) {
|
||||
self.container = d3.select(self.el).select('.' + self.containerClass);
|
||||
}
|
||||
|
@ -66,7 +66,7 @@ define(function (require) {
|
|||
var placement = self.getTooltipPlacement(
|
||||
self.$window,
|
||||
self.$chart,
|
||||
self.$tip,
|
||||
$('.' + self.tooltipClass),
|
||||
d3.event
|
||||
);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue