microsoft / microsoft/monaco-editor
[Feature Request] Edit context menu actions/commands (easily)
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 46.8k
- Forks
- 4.1k
- Avg merge
- 17h 58m
- Merged PRs (30d)
- 1
Description
Context
- This issue is not a bug report. (please use a different template for reporting a bug)
- This issue is not a duplicate of an existing issue. (please use the search to find existing issues)
Description
I don't see any easy way to move / delete items from the context menu. I'm having issues moving 'Peek Definition' out of the Peek context submenu and into the main navigation menu. Since I only have 1 option inside the peek submenu I find it annoying to even have a submenu for it. Is there an easy way to move this into the navigation menu? Ideally it would go right under Go To Definition.
Edit:
I was able to get my desired result by iterating over the peek context menu items to remove the peek menu, then manually adding a new action that just triggers the peek action. There must be a better way?? The playground link shows the hack I had to do.
Monaco Editor Playground Link
Monaco Editor Playground Code
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked Monaco Editor Playground and inspect the context-menu items and manually added action described in the issue. Determine whether the existing context-menu customization entry points can support moving or deleting actions across menus. Done means users have a documented, supported way to relocate or remove actions such as Peek Definition without the workaround described.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend, web-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100