You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by sh...@apache.org on 2020/10/19 13:43:15 UTC

[incubator-echarts] branch next updated: fix(tooltip): hide tooltip when mouse leaves the chart(fix apache#12778).

This is an automated email from the ASF dual-hosted git repository.

shenyi pushed a commit to branch next
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git


The following commit(s) were added to refs/heads/next by this push:
     new f4e372e  fix(tooltip): hide tooltip when mouse leaves the chart(fix apache#12778).
     new 3de41dc  Merge pull request #13382 from plainheart/fix-12778
f4e372e is described below

commit f4e372e5fc2e15d0ae51cd71012aacec76f05287
Author: plainheart <yh...@all-my-life.cn>
AuthorDate: Fri Oct 2 15:08:26 2020 +0800

    fix(tooltip): hide tooltip when mouse leaves the chart(fix apache#12778).
---
 src/component/tooltip/TooltipHTMLContent.ts | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/component/tooltip/TooltipHTMLContent.ts b/src/component/tooltip/TooltipHTMLContent.ts
index 2545342..9b5ce27 100644
--- a/src/component/tooltip/TooltipHTMLContent.ts
+++ b/src/component/tooltip/TooltipHTMLContent.ts
@@ -289,12 +289,14 @@ class TooltipHTMLContent {
             }
         };
         el.onmouseleave = function () {
+            // set `_inContent` to `false` before `hideLater`
+            self._inContent = false;
+
             if (self._enterable) {
                 if (self._show) {
                     self.hideLater(self._hideDelay);
                 }
             }
-            self._inContent = false;
         };
     }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org