Skip to content

Commit

Permalink
assistant2: Respect panel dock position (#23465)
Browse files Browse the repository at this point in the history
This PR fixes an issue where Assistant2 was not respecting the panel
dock position.

Release Notes:

- N/A
  • Loading branch information
maxdeviant authored Jan 22, 2025
1 parent 636df12 commit 1e88e29
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions crates/assistant2/src/assistant_panel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down

0 comments on commit 1e88e29

Please sign in to comment.