cluk3 / cluk3/use-context-menu
Default menu shows up when ctrl + clicking
- Dominant language
- JavaScript
- Stars
- 36
- Forks
- 3
- PR merge metrics
- No merged PRs in 30d
Description
- `react-use-context-menu`: 0.1.4
- `node`: 12.16.2
- `yarn`: 1.22.4
## What you did:
Press ctrl + click to emulate right click
## What happened:
Browser defualt menu shows up on top of custom context menu. Not sure if this is the desired behavior but some users prefer to ctrl+click rather than right click.
Reproduction codesandbox:
https://codesandbox.io/s/hopeful-hopper-v4zzv?fontsize=14
Suggested solution:
Window events have access to a ctrlKey property so we could check if ctrl key is being pressed on a left click event and adjust the event handlers to recognize this click. Probably want to add a config option to enable/disable this as well. I can take a crack at this if I find some free time this week.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.