Theia: [proposal] add 'References' widget

Created on 2 Apr 2019  路  7Comments  路  Source: eclipse-theia/theia

I propose we implement and introduce the References widget in Theia.

Screenshot from 2019-04-02 09-12-11

The widget (triggered by the Find All References command) offers a more persistent option as compared to the Peek References command. It opens the search results in a designated widget as compared to the peek, and is great for todo lists. Since it is a widget, it is also possible to save it's state in local storage to easily be able to recover on startup.

enhancement help wanted vscode

All 7 comments

We should use vscode extension: https://github.com/Microsoft/vscode-references-view

We should use vscode extension: https://github.com/Microsoft/vscode-references-view

Oh great! It looks like its the official extension and is shipped with vscode, it'd be great to try it in Theia :)

But there are many missing things yet to run it:

  ],
  "missingSymbols": [
    "\"vscode\".Clipboard",
    "\"vscode\".Clipboard.writeText",
    "\"vscode\".ThemeIcon.File",
    "\"vscode\".TreeItem.description",
    "\"vscode\".TreeView.message",
    "\"vscode\".TreeView.onDidChangeVisibility",
    "\"vscode\".TreeView.visible",
    "\"vscode\".TreeViewVisibilityChangeEvent",
    "\"vscode\".TreeViewVisibilityChangeEvent.visible",
    "\"vscode\".env.clipboard"
  ],
  "missingCommands": [
    "editor.action.showReferences",
    "editor.findMatchHighlightBackground",
    "vscode.executeReferenceProvider"
  ],
  "dynamicCommanCalls": [
    "`${viewId}.focus` (/workspace/vscode-references-view/src/extension.ts 58:39)"
  ]

Someone has to look into them. Complete TreeView interface would be the easiest to start.

TreeView.message and the commands "editor.findMatchingHighlightBackground" and "vscode.executeReferenceProvider" seem to be missing, the rest seems to work in master as of today

See in plugin-vscode-commands-contribution.ts

Btw: view.message is the text that shows "20 results in 12 files" at the top of the view.

Was this page helpful?
0 / 5 - 0 ratings