agent: Add small UI fixes (#38231)

Release Notes:

- N/A
This commit is contained in:
Danilo Leal
2025-09-16 01:06:45 +00:00
committed by GitHub
parent 6446963a0c
commit 555b6ee4e5
2 changed files with 24 additions and 16 deletions
+17 -13
View File
@@ -500,20 +500,24 @@ impl Render for AcpThreadHistory {
), ),
) )
} else { } else {
view.pr_5() view.child(
.child( uniform_list(
uniform_list( "thread-history",
"thread-history", self.visible_items.len(),
self.visible_items.len(), cx.processor(|this, range: Range<usize>, window, cx| {
cx.processor(|this, range: Range<usize>, window, cx| { this.render_list_items(range, window, cx)
this.render_list_items(range, window, cx) }),
}),
)
.p_1()
.track_scroll(self.scroll_handle.clone())
.flex_grow(),
) )
.vertical_scrollbar_for(self.scroll_handle.clone(), window, cx) .p_1()
.pr_4()
.track_scroll(self.scroll_handle.clone())
.flex_grow(),
)
.vertical_scrollbar_for(
self.scroll_handle.clone(),
window,
cx,
)
} }
}) })
} }
+7 -3
View File
@@ -3182,10 +3182,14 @@ impl AcpThreadView {
}; };
Button::new(SharedString::from(method_id.clone()), name) Button::new(SharedString::from(method_id.clone()), name)
.when(ix == 0, |el| {
el.style(ButtonStyle::Tinted(ui::TintColor::Warning))
})
.label_size(LabelSize::Small) .label_size(LabelSize::Small)
.map(|this| {
if ix == 0 {
this.style(ButtonStyle::Tinted(TintColor::Warning))
} else {
this.style(ButtonStyle::Outlined)
}
})
.on_click({ .on_click({
cx.listener(move |this, _, window, cx| { cx.listener(move |this, _, window, cx| {
telemetry::event!( telemetry::event!(