This commit is contained in:
Antonio Scandurra 2023-12-06 16:34:07 +01:00
parent 5f172a52a4
commit a1c8f01ff3

View file

@ -1140,6 +1140,7 @@ impl Render for AssistantPanel {
} }
v_stack() v_stack()
.size_full()
.on_action(cx.listener(|this, _: &workspace::NewFile, cx| { .on_action(cx.listener(|this, _: &workspace::NewFile, cx| {
this.new_conversation(cx); this.new_conversation(cx);
})) }))
@ -1156,6 +1157,9 @@ impl Render for AssistantPanel {
} else { } else {
Some(self.toolbar.clone()) Some(self.toolbar.clone())
}) })
.child(
div()
.flex_1()
.child(if let Some(editor) = self.active_editor() { .child(if let Some(editor) = self.active_editor() {
editor.clone().into_any_element() editor.clone().into_any_element()
} else { } else {
@ -1171,7 +1175,8 @@ impl Render for AssistantPanel {
) )
.track_scroll(self.saved_conversations_scroll_handle.clone()) .track_scroll(self.saved_conversations_scroll_handle.clone())
.into_any_element() .into_any_element()
}) }),
)
.border() .border()
.border_color(gpui::red()) .border_color(gpui::red())
} }
@ -2469,6 +2474,7 @@ impl Render for ConversationEditor {
fn render(&mut self, cx: &mut ViewContext<Self>) -> Self::Element { fn render(&mut self, cx: &mut ViewContext<Self>) -> Self::Element {
div() div()
.size_full()
.relative() .relative()
.capture_action(cx.listener(ConversationEditor::cancel_last_assist)) .capture_action(cx.listener(ConversationEditor::cancel_last_assist))
.capture_action(cx.listener(ConversationEditor::save)) .capture_action(cx.listener(ConversationEditor::save))