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

Fixes #36793 - Allow plugins to close ActionsBar kebab via React context #9847

Merged

Conversation

jeremylenz
Copy link
Contributor

@jeremylenz jeremylenz commented Sep 29, 2023

The Foreman host details ActionsBar allows plugins to extend it and add items, but it doesn't expose a function that would allow a plugin to close the menu when you click on an item.

This PR fixes the issue by exposing the function via a React context, which can then be consumed from plugins via useContext.

Corresponding Katello PR: Katello/katello#10757

Related React documentation: https://react.dev/reference/react/useContext

@theforeman-bot
Copy link
Member

Issues: #36793

Copy link
Contributor

@ianballou ianballou left a comment

Choose a reason for hiding this comment

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

ACK from testing Katello/katello#10757

@jeremylenz jeremylenz merged commit d329c93 into theforeman:develop Oct 12, 2023
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants