Skip to content

Conversation

@mattpap
Copy link
Contributor

@mattpap mattpap commented Jun 4, 2024

This PR adds LegendItemClick(Legend, LegendItem) event and Legend.on_click() and Legend.js_on_click().

From examples/interaction/legends/legend_click. Click on legend items to cycle through markers:

Screencast.from.05.06.2024.15.27.26.webm

fixes #12185

@mattpap mattpap added this to the 3.5 milestone Jun 4, 2024
@mattpap mattpap force-pushed the mattpap/12185_Legend_item_click branch from e30f603 to 0b73745 Compare June 5, 2024 13:26
@mattpap
Copy link
Contributor Author

mattpap commented Jun 5, 2024

This is tentatively ready. I need to add bokehjs integration tests and update release notes.

@mattpap mattpap force-pushed the mattpap/12185_Legend_item_click branch from 0b73745 to f03329b Compare June 5, 2024 13:37
Copy link
Contributor

@philippjfr philippjfr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a simple, well isolated change.

@mattpap mattpap merged commit 59a2c45 into branch-3.5 Jun 5, 2024
@mattpap mattpap deleted the mattpap/12185_Legend_item_click branch June 5, 2024 18:42
Chiemezuo pushed a commit to Chiemezuo/bokeh that referenced this pull request Aug 27, 2024
* Add support for `Legend` item click events

* Allow correct cursor when using JS callbacks

* Add Legend.js_on_click() and Legend.on_click()

* Add interaction/legends/legend_click example

* Update unit tests

* Add visual integration tests
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Legend click events

3 participants