[dashboard] trigger query for chart in nested tab only after chart becomes visible#7700
Merged
graceguo-supercat merged 1 commit intoJun 14, 2019
Conversation
etr2460
reviewed
Jun 13, 2019
Member
There was a problem hiding this comment.
this simplifies to !renderTabContent || isComponentVisible I think. What does renderTabContent actually signify here? I'm having a bit of trouble understanding the logic.
Author
There was a problem hiding this comment.
I updated the logic be more clear.
40f53e0 to
041ce63
Compare
Author
|
@etr2460 tab logic is a little confusing here.
|
041ce63 to
072ba2c
Compare
Codecov Report
@@ Coverage Diff @@
## master #7700 +/- ##
==========================================
+ Coverage 65.76% 65.76% +<.01%
==========================================
Files 459 459
Lines 21909 21910 +1
Branches 2408 2409 +1
==========================================
+ Hits 14409 14410 +1
Misses 7379 7379
Partials 121 121
Continue to review full report at Codecov.
|
etr2460
approved these changes
Jun 14, 2019
| onDropOnTab={this.handleDropOnTab} | ||
| isComponentVisible={selectedTabIndex === tabIndex} | ||
| isComponentVisible={ | ||
| selectedTabIndex === tabIndex && isCurrentTabVisible |
Member
There was a problem hiding this comment.
much more understandable, thanks!
qfcwell
pushed a commit
to qfcwell/superset
that referenced
this pull request
May 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CATEGORY
Choose one
SUMMARY
In #7233 I added a feature that only trigger query when chart is visible to user. If user apply filter in 1 tab, all the charts in another tab (not visible right now) should delay query update until user click to see the tab.
I found there is a bug for nested tab case: when chart in the nested tab, update filter (in another tab) will trigger new query right away. Please see before/after gif. Also updated integration test to cover this case.
Note: charts outside nested tab behaves good, and is covered in the existed unit tests.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Before:

After:

TEST PLAN
CI and manual test.
REVIEWERS
@etr2460 @williaster