Extract ContextEditor to assistant_context_editor (#23433)

This PR extracts the `ContextEditor` to the `assistant_context_editor`
crate.

As part of this, we have decoupled the `ContextEditor` from the
`AssistantPanel`.

There is now an `AssistantPanelDelegate` that the `ContextEditor` uses
when it needs to interface with the Assistant panel.

Release Notes:

- N/A
This commit is contained in:
Marshall Bowers 2025-01-21 18:08:34 -05:00 committed by GitHub
parent 9a7f1d1de4
commit 417760ade7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 263 additions and 166 deletions

View file

@ -1,6 +1,6 @@
use crate::{humanize_token_count, AssistantPanel, AssistantPanelEvent, DEFAULT_CONTEXT_LINES};
use crate::{AssistantPanel, AssistantPanelEvent, DEFAULT_CONTEXT_LINES};
use anyhow::{Context as _, Result};
use assistant_context_editor::RequestType;
use assistant_context_editor::{humanize_token_count, RequestType};
use assistant_settings::AssistantSettings;
use client::telemetry::Telemetry;
use collections::{HashMap, VecDeque};