Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

zeta: Improve UI for feedback instructions (#21857)

Danilo Lealdfe455b054b8
diff --git a/crates/zeta/src/rate_completion_modal.rs b/crates/zeta/src/rate_completion_modal.rs
index 4a2e622a685..d096fca8556 100644
--- a/crates/zeta/src/rate_completion_modal.rs
+++ b/crates/zeta/src/rate_completion_modal.rs
@@ -275,7 +275,7 @@ impl RateCompletionModal {
editor.set_show_wrap_guides(false, cx);
editor.set_show_indent_guides(false, cx);
editor.set_show_inline_completions(Some(false), cx);
- editor.set_placeholder_text("Add your feedback about this completion… (Negative feedback requires an explanation for why it was bad, and what you expected instead.)", cx);
+ editor.set_placeholder_text("Add your feedback…", cx);
if focus {
cx.focus_self();
}
@@ -369,12 +369,28 @@ impl RateCompletionModal {
.overflow_scroll()
.child(StyledText::new(diff).with_highlights(&text_style, diff_highlights)),
)
+ .child(
+ h_flex()
+ .p_2()
+ .gap_2()
+ .border_y_1()
+ .border_color(border_color)
+ .child(
+ Icon::new(IconName::Info)
+ .size(IconSize::XSmall)
+ .color(Color::Muted)
+ )
+ .child(
+ Label::new("Ensure you explain why this completion is negative or positive. In case it's negative, report what you expected instead.")
+ .size(LabelSize::Small)
+ .color(Color::Muted)
+ )
+ )
.child(
div()
.h_40()
+ .pt_1()
.bg(bg_color)
- .border_t_1()
- .border_color(border_color)
.child(active_completion.feedback_editor.clone()),
)
.child(