agent: Only show expand message editor when focused on it (#29595)

Simplifying the UI as much as possible.

Release Notes:

- N/A
This commit is contained in:
Danilo Leal 2025-04-29 09:38:53 -03:00 committed by GitHub
parent 7e25460708
commit fcef101227
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -495,7 +495,8 @@ impl MessageEditor {
.items_start()
.justify_between()
.child(self.context_strip.clone())
.child(
.when(focus_handle.is_focused(window), |this| {
this.child(
IconButton::new("toggle-height", expand_icon)
.icon_size(IconSize::XSmall)
.icon_color(Color::Muted)
@ -520,7 +521,8 @@ impl MessageEditor {
.on_click(cx.listener(|_, _, window, cx| {
window.dispatch_action(Box::new(ExpandMessageEditor), cx);
})),
),
)
}),
)
.child(
v_flex()