agent: Add reactions at the response level (#27958)
Release Notes: - Added the user reaction (👍 or 👎) to each agent response. - 👎 will trigger a comment box linked to the response --------- Co-authored-by: Danilo Leal <daniloleal09@gmail.com> Co-authored-by: Agus Zubiaga <hi@aguz.me>
This commit is contained in:
parent
b47aa33459
commit
342134fbab
3 changed files with 173 additions and 68 deletions
|
@ -498,10 +498,12 @@ impl RateCompletionModal {
|
|||
cx
|
||||
))
|
||||
.on_click(cx.listener(move |this, _, window, cx| {
|
||||
this.thumbs_down_active(
|
||||
&ThumbsDownActiveCompletion,
|
||||
window, cx,
|
||||
);
|
||||
if this.active_completion.is_some() {
|
||||
this.thumbs_down_active(
|
||||
&ThumbsDownActiveCompletion,
|
||||
window, cx,
|
||||
);
|
||||
}
|
||||
})),
|
||||
)
|
||||
.child(
|
||||
|
@ -517,7 +519,9 @@ impl RateCompletionModal {
|
|||
cx
|
||||
))
|
||||
.on_click(cx.listener(move |this, _, window, cx| {
|
||||
this.thumbs_up_active(&ThumbsUpActiveCompletion, window, cx);
|
||||
if this.active_completion.is_some() {
|
||||
this.thumbs_up_active(&ThumbsUpActiveCompletion, window, cx);
|
||||
}
|
||||
})),
|
||||
),
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue