From 1034d1a6b54a66b403d1ea5b6b7b80fdab1d8130 Mon Sep 17 00:00:00 2001 From: Danilo Leal <67129314+danilo-leal@users.noreply.github.com> Date: Thu, 13 Mar 2025 12:48:39 -0300 Subject: [PATCH] docs: Add section about Edit Prediction modes (#26683) To go along the upcoming blog post as well as the new menu item options (https://github.com/zed-industries/zed/pull/26680). Release Notes: - N/A --- docs/src/completions.md | 15 +++++++++++++++ docs/theme/css/general.css | 9 ++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/docs/src/completions.md b/docs/src/completions.md index 09019e3fae..1b28302749 100644 --- a/docs/src/completions.md +++ b/docs/src/completions.md @@ -40,6 +40,21 @@ But, if you haven't come across the banner, start using Zed's Edit Prediction by }, ``` +### Switching modes + +Zed's Edit Prediction comes with two different display modes: + +1. `eager` (default): predictions are displayed inline as long as it doesn't conflict with language server completions +2. `subtle`: predictions only appear inline when holding a modifier key (`alt` by default) + +Toggle between them via the `mode` key: + +```json +"edit_predictions": { + "mode": "eager" | "subtle" +}, +``` + ### Conflict With Other `tab` Actions {#edit-predictions-conflict} By default, when `tab` would normally perform a different action, Zed requires a modifier key to accept predictions: diff --git a/docs/theme/css/general.css b/docs/theme/css/general.css index b4ef43518c..4f8331bd6c 100644 --- a/docs/theme/css/general.css +++ b/docs/theme/css/general.css @@ -169,7 +169,14 @@ h6:target::before { } .content ol { line-height: 1.8; - padding-left: 1.8em; + + ::marker { + font-size: 1.4rem; + } + + li { + padding-left: 0; + } } .content ul { line-height: 1.8;