Skip to content

Commit

Permalink
outline panel: Improve the search query header design (#25283)
Browse files Browse the repository at this point in the history
Fine-tuning alignment and spacing.

| Before | After |
|--------|--------|
| ![CleanShot 2025-02-20 at 5  45
09@2x](https://github.com/user-attachments/assets/0db377b2-e030-4a88-8465-fb8c3a535ad3)
| ![CleanShot 2025-02-20 at 5  44
33@2x](https://github.com/user-attachments/assets/ccabef92-3e2b-47b8-a766-2f707d9d9e8f)
|

Release Notes:

- N/A
  • Loading branch information
danilo-leal authored Feb 20, 2025
1 parent 4151b5b commit 3c8dbaf
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions crates/outline_panel/src/outline_panel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4950,13 +4950,16 @@ impl Render for OutlinePanel {
.track_focus(&self.focus_handle)
.when_some(search_query, |outline_panel, search_state| {
outline_panel.child(
v_flex()
.child(
Label::new(format!("Searching: '{}'", search_state.query))
.color(Color::Muted)
.mx_2(),
)
.child(horizontal_separator(cx)),
h_flex()
.py_1p5()
.px_2()
.h(DynamicSpacing::Base32.px(cx))
.flex_shrink_0()
.border_b_1()
.border_color(cx.theme().colors().border)
.gap_0p5()
.child(Label::new("Searching:").color(Color::Muted))
.child(Label::new(format!("'{}'", search_state.query))),
)
})
.child(self.render_main_contents(query, show_indent_guides, indent_size, window, cx))
Expand Down

0 comments on commit 3c8dbaf

Please sign in to comment.