From de9a7b1927b2ac78d9b53228c097fa6670e1ac4d Mon Sep 17 00:00:00 2001 From: Max Brunsfeld Date: Tue, 10 May 2022 11:25:12 -0700 Subject: [PATCH] Give the contact panel's filter editor some placeholder text Co-authored-by: Nathan Sobo --- crates/contacts_panel/src/contacts_panel.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/crates/contacts_panel/src/contacts_panel.rs b/crates/contacts_panel/src/contacts_panel.rs index f2e3c6414388afc752ec142b6be147fbbe231ae6..499d4d879c6bcb2ce74b6d09cbc14c9414ca6f5c 100644 --- a/crates/contacts_panel/src/contacts_panel.rs +++ b/crates/contacts_panel/src/contacts_panel.rs @@ -62,10 +62,12 @@ pub fn init(cx: &mut MutableAppContext) { impl ContactsPanel { pub fn new(app_state: Arc, cx: &mut ViewContext) -> Self { let user_query_editor = cx.add_view(|cx| { - Editor::single_line( + let mut editor = Editor::single_line( Some(|theme| theme.contacts_panel.user_query_editor.clone()), cx, - ) + ); + editor.set_placeholder_text("Filter contacts", cx); + editor }); cx.subscribe(&user_query_editor, |this, _, event, cx| {