Skip to content
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

[ISSUE-6350] - allow onSelect to prevent the default behavior of toggling node collapse #6351

Merged

Conversation

steverhoades
Copy link
Contributor

The proposed usage would allow for the onSelect method to call evt.preventDefault() to prevent the nodes from toggling. This is useful for determining programmatically whether a node should be collapsed. Further, it allows for the tree to be expanded and locked by the integrator.

What: Closes #6350

Additional issues: None

@patternfly-build
Copy link
Contributor

patternfly-build commented Sep 24, 2021

PF4 preview: https://patternfly-react-pr-6351.surge.sh

@tlabaj tlabaj requested a review from kmcfaul September 24, 2021 15:35
@redallen redallen merged commit dbc20f0 into patternfly:main Sep 27, 2021
@patternfly-build
Copy link
Contributor

Your changes have been released in:

  • @patternfly/react-catalog-view-extension@4.12.79
  • @patternfly/react-code-editor@4.3.66
  • @patternfly/react-console@4.11.47
  • @patternfly/react-core@4.157.8
  • @patternfly/react-docs@5.21.48
  • @patternfly/react-inline-edit-extension@4.7.89
  • demo-app-ts@4.121.8
  • @patternfly/react-log-viewer@4.7.1
  • @patternfly/react-table@4.30.8
  • @patternfly/react-topology@4.9.85
  • @patternfly/react-virtualized-extension@4.9.54

Thanks for your contribution! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TreeView: Allow onSelect to determine if TreeViewItem node is expanded
5 participants