Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

assistant2: Respect panel dock position (#23465)

Marshall Bowers1e88e2924c26
diff --git a/crates/assistant2/src/assistant_panel.rs b/crates/assistant2/src/assistant_panel.rs
index 1d92243a89b..b730b4ef97c 100644
--- a/crates/assistant2/src/assistant_panel.rs
+++ b/crates/assistant2/src/assistant_panel.rs
@@ -397,8 +397,12 @@ impl Panel for AssistantPanel {
"AssistantPanel2"
}
- fn position(&self, _cx: &WindowContext) -> DockPosition {
- DockPosition::Right
+ fn position(&self, cx: &WindowContext) -> DockPosition {
+ match AssistantSettings::get_global(cx).dock {
+ AssistantDockPosition::Left => DockPosition::Left,
+ AssistantDockPosition::Bottom => DockPosition::Bottom,
+ AssistantDockPosition::Right => DockPosition::Right,
+ }
}
fn position_is_valid(&self, _: DockPosition) -> bool {