assistant2: Rework @mentions
(#26983)
https://github.com/user-attachments/assets/167f753f-2775-4d31-bfef-55565e61e4bc Release Notes: - N/A
This commit is contained in:
parent
4a5f89aded
commit
699369995b
18 changed files with 1637 additions and 485 deletions
|
@ -2,7 +2,7 @@ use anyhow::{Context as _, Result};
|
|||
use channel::{ChannelChat, ChannelStore, MessageParams};
|
||||
use client::{UserId, UserStore};
|
||||
use collections::HashSet;
|
||||
use editor::{AnchorRangeExt, CompletionProvider, Editor, EditorElement, EditorStyle};
|
||||
use editor::{AnchorRangeExt, CompletionProvider, Editor, EditorElement, EditorStyle, ExcerptId};
|
||||
use fuzzy::{StringMatch, StringMatchCandidate};
|
||||
use gpui::{
|
||||
AsyncApp, AsyncWindowContext, Context, Entity, Focusable, FontStyle, FontWeight,
|
||||
|
@ -56,6 +56,7 @@ struct MessageEditorCompletionProvider(WeakEntity<MessageEditor>);
|
|||
impl CompletionProvider for MessageEditorCompletionProvider {
|
||||
fn completions(
|
||||
&self,
|
||||
_excerpt_id: ExcerptId,
|
||||
buffer: &Entity<Buffer>,
|
||||
buffer_position: language::Anchor,
|
||||
_: editor::CompletionContext,
|
||||
|
@ -311,6 +312,7 @@ impl MessageEditor {
|
|||
old_range: range.clone(),
|
||||
new_text,
|
||||
label,
|
||||
icon_path: None,
|
||||
confirm: None,
|
||||
documentation: None,
|
||||
source: CompletionSource::Custom,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue