pub enum ChatEvent {
Show 15 variants
Prompt(PromptBarEvent),
RetryRequested {
message_id: SharedString,
},
FollowUpSelected {
message_id: SharedString,
follow_up_id: SharedString,
},
SourceActivated {
message_id: SharedString,
source_id: SharedString,
url: SharedString,
},
AttachmentActivated {
message_id: SharedString,
attachment_id: SharedString,
},
CitationActivated {
message_id: SharedString,
citation_id: SharedString,
destination: SharedString,
},
MessageCopied {
message_id: SharedString,
},
RegenerateRequested {
message_id: SharedString,
},
EditRequested {
message_id: SharedString,
},
EditSubmitted {
message_id: SharedString,
text: SharedString,
},
EditCancelled {
message_id: SharedString,
},
BranchSelected {
message_id: SharedString,
index: usize,
},
FeedbackSubmitted {
message_id: SharedString,
positive: bool,
},
SuggestionSelected {
suggestion_id: SharedString,
},
JumpedToLatest,
}Expand description
A typed application intent emitted by Chat.
Variants§
Prompt(PromptBarEvent)
A cloned event from the composed PromptBar.
RetryRequested
The user requested another attempt for a failed message.
Fields
message_id: SharedStringStable message identifier.
FollowUpSelected
The user selected a follow-up attached to a message.
Fields
message_id: SharedStringStable message identifier.
follow_up_id: SharedStringStable follow-up identifier.
SourceActivated
The user activated a source chip attached to a message.
Fields
message_id: SharedStringStable message identifier.
source_id: SharedStringStable source identifier.
url: SharedStringThe source location.
AttachmentActivated
The user activated an attachment carried by a message.
Fields
message_id: SharedStringStable message identifier.
attachment_id: SharedStringStable attachment identifier.
CitationActivated
The user activated an inline citation attached to a message.
Fields
message_id: SharedStringStable message identifier.
citation_id: SharedStringStable citation identifier.
destination: SharedStringOpaque application-owned destination.
MessageCopied
The user copied a message; the text is already on the clipboard.
Fields
message_id: SharedStringStable message identifier.
RegenerateRequested
The user asked for a new response in place of this one.
Fields
message_id: SharedStringStable message identifier.
EditRequested
The user opened the in-place editor for this message.
Fields
message_id: SharedStringStable message identifier.
EditSubmitted
The user committed an in-place edit; the application decides whether that resends, branches, or simply rewrites the message.
EditCancelled
The user abandoned an in-place edit.
Fields
message_id: SharedStringStable message identifier.
BranchSelected
The user moved to another version of a branched message.
Fields
message_id: SharedStringStable message identifier.
FeedbackSubmitted
The user rated a response.
Fields
message_id: SharedStringStable message identifier.
SuggestionSelected
The user chose a welcome suggestion.
Fields
suggestion_id: SharedStringStable suggestion identifier.
JumpedToLatest
The user returned the transcript to active tail-following.
Trait Implementations§
impl Eq for ChatEvent
impl EventEmitter<ChatEvent> for Chat
impl StructuralPartialEq for ChatEvent
Auto Trait Implementations§
impl Freeze for ChatEvent
impl RefUnwindSafe for ChatEvent
impl Send for ChatEvent
impl Sync for ChatEvent
impl Unpin for ChatEvent
impl UnsafeUnpin for ChatEvent
impl UnwindSafe for ChatEvent
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Span], returning an
Instrumented wrapper.§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘwhere
S: Into<Dispatch>,
Subscriber to this type, returning a
[WithDispatch] wrapper.