agent: Improve discoverability of the quote selection action (#40897)
This PR renames the `agent::QuoteSelection` to `agent::AddSelectionToThread` _and_ adds it as a menu item in both the right-click context menu within regular buffers as well as the "Selection" app menu. We've received feedback in the past about how hard to discover this feature is, and after watching [the Syntax podcast crew](https://www.youtube.com/watch?v=bRK3PeVFfVE) recently struggle with doing so—and then naturally looking for it in the context menu and not finding it—it felt like time to push a change. I think the rename + the availability in these places could help bringing it to surface more. The same action can be done in Cursor through the `cmd-l` keybinding, but in Zed, that triggers `editor::SelectLine`, which I don't want to override by default. However, if you're using Cursor's keymap, then `cmd-l` does trigger this action, as expected. <img width="500" height="1812" alt="Screenshot 2025-10-22 at 12 01@2x" src="https://github.com/user-attachments/assets/dfc2c41c-8d0a-4a1a-8ea1-1bd5d1aa1171" /> Release Notes: - agent: Improves discoverability of the previously called "quote selection" action—which allows to add a text selection in a buffer as context within the agent panel—by renaming it to "add selection to thread" and making it available from the right-click editor context menu as well as the "Selection" app menu.
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
use crate::{
|
||||
QuoteSelection,
|
||||
language_model_selector::{LanguageModelSelector, language_model_selector},
|
||||
ui::BurnModeTooltip,
|
||||
};
|
||||
@@ -72,7 +71,7 @@ use workspace::{
|
||||
pane,
|
||||
searchable::{SearchEvent, SearchableItem},
|
||||
};
|
||||
use zed_actions::agent::ToggleModelSelector;
|
||||
use zed_actions::agent::{AddSelectionToThread, ToggleModelSelector};
|
||||
|
||||
use crate::{slash_command::SlashCommandCompletionProvider, slash_command_picker};
|
||||
use assistant_context::{
|
||||
@@ -1450,7 +1449,7 @@ impl TextThreadEditor {
|
||||
|
||||
pub fn quote_selection(
|
||||
workspace: &mut Workspace,
|
||||
_: &QuoteSelection,
|
||||
_: &AddSelectionToThread,
|
||||
window: &mut Window,
|
||||
cx: &mut Context<Workspace>,
|
||||
) {
|
||||
|
||||
Reference in New Issue
Block a user