microsoft / microsoft/monaco-editor

Expose quick-open functionality

Open
#683 8 comments 18 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature-request quick-pick
Dominant language
JavaScript
Stars
46.8k
Forks
4.1k
Avg merge
17h 58m
Merged PRs (30d)
1

Description

For a project I am working on I would love to use the QuickOpen functionality of the monaco editor for custom command-lists (or selection, ...) after executing another command.

An example for what I mean could be the "Go To Line" command, wich opens a new QuickOpen View and after executing shows a single command which jumps to the given line.

I imagine adding custom actions like "Rename file..." (action outside of monaco) or "Switch Language Mode...".

I tried to get the responsible controller and show it, but i didn't get it to work, because of exceptions about the object properties of QuickOpenModel (just giving an array does not work).
I got it to work by extending IActionDescriptor by getQuickOpenEntries() (this or run() is required in the addAction method of StandaloneCodeEditor, which does the magic). What I didn't get to work here was a usable build from my custom-code (like npm-folder with dev, min, ...).

If this is appreciated by others, maybe we could get this to work for everyone.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with StandaloneCodeEditor.addAction, IActionDescriptor, and QuickOpenModel, since the issue identifies these as the relevant entry points. Clarify how custom actions should provide QuickOpen entries and how the public build should expose them. Done should mean a documented, usable way to open custom command lists or selections after another command.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
developer-experience, frontend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.