zed icon indicating copy to clipboard operation
zed copied to clipboard

Sort ShowCompletions results

Open Spoutnik97 opened this issue 1 year ago • 2 comments

Check for existing issues

  • [X] Completed

Describe the feature

Is it possible to sort completions results ?

For example when I tap ctrl+space I get this pop up menu for my React App, but I don't use HTMLOptGroupElement at all and need to scroll down up to my local components in the "#shared" directory.

image

The problem is that I need to scroll for each import, and most of the time I tap "enter" on the wrong import because it is the first one.

I already added "autoImportFileExcludePatterns": ["**/node_modules/@mantine/core"]to my settings in lsp.typescript-language-server.initialization_options.preferences to ignore some imports, but would like to avoid adding the whole list. Moreover I think that HTMLOptGroupElement is from the HTML language, what I can't exclude

If applicable, add mockups / screenshots to help present your vision of the feature

No response

Spoutnik97 avatar May 15 '24 14:05 Spoutnik97

This sounds similar to:

  • https://github.com/zed-industries/zed/issues/4327

JosephTLyons avatar May 15 '24 20:05 JosephTLyons

Yes, it is quite the same.

If there is an option to choose the order, it could be better

Spoutnik97 avatar May 16 '24 08:05 Spoutnik97

I'm going to close this issue in favor of the more general:

  • https://github.com/zed-industries/zed/issues/12698
  • https://github.com/zed-industries/zed/issues/4327

Please 👍 vote on those to increase visibility and subscribe to track their progress.

Thanks for reporting @Spoutnik97!

notpeter avatar Jun 20 '24 15:06 notpeter