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.

assistant2: Adjust "Recent" header label design in context picker (#23364)

Danilo Leal40a6b0a0a30a
diff --git a/crates/assistant2/src/context_picker.rs b/crates/assistant2/src/context_picker.rs
index e7adc61eea1..6456c10660d 100644
--- a/crates/assistant2/src/context_picker.rs
+++ b/crates/assistant2/src/context_picker.rs
@@ -92,7 +92,18 @@ impl ContextPicker {
.map(|(ix, entry)| self.recent_menu_item(context_picker.clone(), ix, entry));
let menu = menu
- .when(has_recent, |menu| menu.label("Recent"))
+ .when(has_recent, |menu| {
+ menu.custom_row(|_| {
+ div()
+ .mb_1()
+ .child(
+ Label::new("Recent")
+ .color(Color::Muted)
+ .size(LabelSize::Small),
+ )
+ .into_any_element()
+ })
+ })
.extend(recent_entries)
.when(has_recent, |menu| menu.separator())
.extend(ContextKind::all().into_iter().map(kind_entry));