-
Notifications
You must be signed in to change notification settings - Fork 14k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Enables ECharts legend selector #23590
feat: Enables ECharts legend selector #23590
Conversation
OMG, I was just talking about this feature with @yousoph and here's the PR!!! Thank you! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!! Thanks for this!
I wondered for a moment about writing some tests with more assertions, but I don't think there's anything other than tech debt ahead if we wrote tests to check that ECharts continues to support what it claims to out-of-the-box.
Codecov Report
@@ Coverage Diff @@
## master #23590 +/- ##
=======================================
Coverage 67.72% 67.72%
=======================================
Files 1916 1916
Lines 74029 74026 -3
Branches 8040 8040
=======================================
- Hits 50135 50134 -1
+ Misses 21846 21844 -2
Partials 2048 2048
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Amazing!! I wonder if "Inv" is clear enough from the label? Curious what @kasiazjc thinks |
/testenv up |
@yousoph Ephemeral environment spinning up at http://34.221.232.22:8080. Credentials are |
@michael-s-molina this is very cool! I have a few thoughts -
I think this would be a good indicator to show in which state you currently are in thoughts @yousoph @michael-s-molina ?
|
@yousoph @kasiazjc Although the ideas are good, ECharts API currently does not offer this kind of flexibility 😢 . There's no native support for controlling the buttons states or adding a tooltip. I can change the text though, I just didn't because I figure it's a common pattern used by ECharts and people are used to it. One thing I noticed when interacting with the controls for the first time, is that you understand the feature pretty quick, and there's no harm when "trying/testing" the buttons. |
oooh, ok, that makes sense to me! I think we should keep "inv" if that's the case, because I don't think there is a better name for it and as you said it's widely used :) |
Ephemeral environment shutdown and build artifacts deleted. |
(cherry picked from commit 30f210b)
SUMMARY
Legacy charts had the ability to click on a legend item and exclusively select that series. This was really helpful, specially when you have many items and wishes to focus on only one. ECharts has a similar but more flexible feature called Legend selector that allows a user to select all items or invert the selection. This flexibility is specially helpful when you want to compare a few items among many. This PR enables that feature.
@kasiazjc
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Screen.Recording.2023-04-05.at.14.55.25.mov
TESTING INSTRUCTIONS
Check the video for instructions.
ADDITIONAL INFORMATION