You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by "jianghaoran116 (via GitHub)" <gi...@apache.org> on 2023/02/01 10:58:10 UTC

[GitHub] [echarts] jianghaoran116 opened a new pull request, #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

jianghaoran116 opened a new pull request, #18221:
URL: https://github.com/apache/echarts/pull/18221

   …tooltip  . close #18111
   
   <!-- Please fill in the following information to help us review your PR more efficiently. -->
   
   ## Brief Information
   
   This pull request is in the type of:
   
   - [ ] bug fixing
   - [ ] new feature
   - [ ] others
   
   
   
   ### What does this PR do?
   
   <!-- USE ONE SENTENCE TO DESCRIBE WHAT THIS PR DOES. -->
   
   
   
   ### Fixed issues
   
   <!--
   - #xxxx: ...
   -->
   
   
   ## Details
   
   ### Before: What was the problem?
   
   <!-- DESCRIBE THE BUG OR REQUIREMENT HERE. -->
   
   <!-- ADD SCREENSHOT HERE IF APPLICABLE. -->
   
   
   
   ### After: How does it behave after the fixing?
   
   <!-- THE RESULT AFTER FIXING AND A SIMPLE EXPLANATION ABOUT HOW IT IS FIXED. -->
   
   <!-- ADD SCREENSHOT HERE IF APPLICABLE. -->
   
   
   
   ## Document Info
   
   One of the following should be checked.
   
   - [ ] This PR doesn't relate to document changes
   - [ ] The document should be updated later
   - [ ] The document changes have been made in apache/echarts-doc#xxx
   
   
   
   ## Misc
   
   ### ZRender Changes
   
   - [ ] This PR depends on ZRender changes (ecomfe/zrender#xxx).
   
   ### Related test cases or examples to use the new APIs
   
   N.A.
   
   
   
   ## Others
   
   ### Merging options
   
   - [ ] Please squash the commits into a single one when merging.
   
   ### Other information
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] jianghaoran116 commented on a diff in pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "jianghaoran116 (via GitHub)" <gi...@apache.org>.
jianghaoran116 commented on code in PR #18221:
URL: https://github.com/apache/echarts/pull/18221#discussion_r1094108148


##########
src/component/tooltip/TooltipHTMLContent.ts:
##########
@@ -336,7 +337,7 @@ class TooltipHTMLContent {
             self._inContent = false;
 
             if (self._enterable) {
-                if (self._show) {
+                if (self._show && !self._alwaysShowContent) {

Review Comment:
   get it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] Ovilia merged pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia merged PR #18221:
URL: https://github.com/apache/echarts/pull/18221


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] echarts-bot[bot] commented on pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by echarts-bot.
echarts-bot[bot] commented on PR #18221:
URL: https://github.com/apache/echarts/pull/18221#issuecomment-1411865207

   Thanks for your contribution!
   The community will review it ASAP. In the meanwhile, please checkout [the coding standard](https://echarts.apache.org/en/coding-standard.html) and Wiki about [How to make a pull request](https://github.com/apache/echarts/wiki/How-to-make-a-pull-request).
   
   ⚠️ MISSING DOCUMENT INFO: Please make sure one of the document options are checked in this PR's description. Search "Document Info" in the description of this PR. This should be done either by the author or the reviewers of the PR.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] jianghaoran116 commented on a diff in pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "jianghaoran116 (via GitHub)" <gi...@apache.org>.
jianghaoran116 commented on code in PR #18221:
URL: https://github.com/apache/echarts/pull/18221#discussion_r1112476480


##########
src/component/tooltip/TooltipView.ts:
##########
@@ -200,7 +200,7 @@ class TooltipView extends ComponentView {
          * @private
          * @type {boolean}
          */
-        this._alwaysShowContent = tooltipModel.get('alwaysShowContent');
+        // this._alwaysShowContent = tooltipModel.get('alwaysShowContent');

Review Comment:
   got it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] Ovilia commented on a diff in pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on code in PR #18221:
URL: https://github.com/apache/echarts/pull/18221#discussion_r1094099541


##########
src/component/tooltip/TooltipHTMLContent.ts:
##########
@@ -336,7 +337,7 @@ class TooltipHTMLContent {
             self._inContent = false;
 
             if (self._enterable) {
-                if (self._show) {
+                if (self._show && !self._alwaysShowContent) {

Review Comment:
   I think it's more rust to check this in `hideLater` rather than `onmouseleave` because when other reasons triggers hiding, this should also be checked.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] Ovilia commented on a diff in pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on code in PR #18221:
URL: https://github.com/apache/echarts/pull/18221#discussion_r1112469099


##########
src/component/tooltip/TooltipView.ts:
##########
@@ -147,7 +147,7 @@ class TooltipView extends ComponentView {
 
     private _api: ExtensionAPI;
 
-    private _alwaysShowContent: boolean;
+    // private _alwaysShowContent: boolean;

Review Comment:
   Remove this.



##########
src/component/tooltip/TooltipView.ts:
##########
@@ -200,7 +200,7 @@ class TooltipView extends ComponentView {
          * @private
          * @type {boolean}
          */
-        this._alwaysShowContent = tooltipModel.get('alwaysShowContent');
+        // this._alwaysShowContent = tooltipModel.get('alwaysShowContent');

Review Comment:
   Remove these 5 lines.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] Ovilia commented on a diff in pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "Ovilia (via GitHub)" <gi...@apache.org>.
Ovilia commented on code in PR #18221:
URL: https://github.com/apache/echarts/pull/18221#discussion_r1094099541


##########
src/component/tooltip/TooltipHTMLContent.ts:
##########
@@ -336,7 +337,7 @@ class TooltipHTMLContent {
             self._inContent = false;
 
             if (self._enterable) {
-                if (self._show) {
+                if (self._show && !self._alwaysShowContent) {

Review Comment:
   I think it's more robust to check this in `hideLater` rather than `onmouseleave` because when other reasons triggers hiding, this should also be checked.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [echarts] echarts-bot[bot] commented on pull request #18221: (tooltip): fix alwaysShowContent doesn't work after leaving the …

Posted by "echarts-bot[bot] (via GitHub)" <gi...@apache.org>.
echarts-bot[bot] commented on PR #18221:
URL: https://github.com/apache/echarts/pull/18221#issuecomment-1453047349

   Congratulations! Your PR has been merged. Thanks for your contribution! 👍


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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