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
enh/3957-legend-item-click-event #21096
base: master
Are you sure you want to change the base?
Conversation
Visual test results - No difference foundSamples changed
|
d02bd91
to
8d361a2
Compare
File size comparisonSizes for compiled+gzipped (bold) and compiled files.
|
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.
Great work! Looks good. 👍
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.
Could you add the version number after the added deprecated
tags? Using @next
should work fine.
Good idea, but this will not work here as these are not API options. JSDoc and Docstrap do not understand extended |
We're using |
This is not supported by JSDoc. Kacper is working on the new class reference, where it can be supported. Only the API options support the extended |
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.
Thanks, great work!
if ((item as any).setVisible) { | ||
(item as any).setVisible(); | ||
} |
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.
if ((item as any).setVisible) { | |
(item as any).setVisible(); | |
} | |
(item as Point|Series).setVisible?.(); |
Trying to get rid of any
. I'm not 100% sure this change is correct, can you check that?
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.
It can also be an item as a DataClass legend item, but we don't have good typing for this. Also, the item can be BubbleLegendItem
, but this item does not contain setVisible
method. Removing this any
would need a lot of refactoring, so I left as any
here. Do you think this refactor should be done now or we can leave it for this moment?
Introduced new event and option
legend.events.itemClick
, deprecatedevents.legendItemClick
, closes #3957.I am not sure if we should treat it as a Feature Request (label), but we don't have an Ehnacement label.