Skip to content

[ContextMenu] Add "disabled" prop to Context Menu trigger #1746

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

Merged
merged 9 commits into from
Dec 12, 2022

Conversation

paperstick
Copy link

@paperstick paperstick commented Oct 29, 2022

Description

This PR adds disabled prop to <ContextMenu /> trigger


Closes #1745

Artsem Rudakou added 3 commits October 29, 2022 12:55
fix(contextmenu): allow native context menu to open when the context menu is disabled
Copy link
Contributor

@benoitgrelard benoitgrelard left a comment

Choose a reason for hiding this comment

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

Thanks for the contribution @paperstick!

@gunnartorfis
Copy link

Would it be possible to add disabled conditions based on PointerDown's type/button?
In our case, we want to disable the context menu entirely on touch devices and only allow it on right click.

@Andarist
Copy link
Contributor

@benoitgrelard is there anything that we could do to move this forward? :)

@benoitgrelard
Copy link
Contributor

Hey @Andarist, it seems the original contributor hasn't followed up, so if you want to address the remaining feedback we can move it forward.

@paperstick
Copy link
Author

Hi, @Andarist and @benoitgrelard! I have already made needed changes in the following commit. Let me know if we need to add anything else, I will check

@benoitgrelard
Copy link
Contributor

Oh sorry my bad!

@benoitgrelard benoitgrelard merged commit a492aa9 into radix-ui:main Dec 12, 2022
@benoitgrelard
Copy link
Contributor

@paperstick paperstick deleted the 1745-context-menu-disabled branch January 3, 2023 14:00
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.

Add disabled to ContextMenu
5 participants