edit predictions: Preview while holding modifier mode (#24316)

This PR adds a new `inline_completions.inline_preview` config which can
be set to `auto` (current behavior) or to `when_holding_modifier`.
When set to the latter, instead of showing edit prediction previews
inline in the buffer, we'll show it in a popover (even when there's no
LSP completion) so your isn't constantly moving as completions arrive.


https://github.com/user-attachments/assets/3615d151-3633-4ee4-98b9-66ee0aa735b8

Release Notes:

- N/A

---------

Co-authored-by: Danilo <danilo@zed.dev>
This commit is contained in:
Agus Zubiaga
2025-02-06 09:58:19 -03:00
committed by GitHub
co-authored by Danilo
parent b4d8b1be3f
commit 8ed8b4d2ec
8 changed files with 113 additions and 60 deletions
+8 -1
View File
@@ -783,7 +783,14 @@
"**/*.cert",
"**/*.crt",
"**/secrets.yml"
]
],
// When to show edit predictions previews in buffer.
// This setting takes two possible values:
// 1. Display inline when there are no language server completions available.
// "inline_preview": "auto"
// 2. Display inline when holding modifier key (alt by default).
// "inline_preview": "when_holding_modifier"
"inline_preview": "auto"
},
// Settings specific to journaling
"journal": {