refactor: merge workspace state into app root
Rust / build (macos-latest, stable) (push) Waiting to run
Rust / build (ubuntu-latest, stable) (push) Waiting to run
Rust / build (windows-latest, stable) (push) Waiting to run

This commit is contained in:
2026-11-23 03:26:11 +07:00
parent efb5761c56
commit bef96c614b
17 changed files with 374 additions and 385 deletions
+3 -7
View File
@@ -16,15 +16,15 @@ use ui::input::{Input, InputState};
use ui::tooltip::Tooltip;
use super::grasp_servers::{GraspServersState, grasp_servers_field, load_user_grasp_servers};
use crate::app::AppRoot;
use crate::repo::actions::open_repo_panel;
use crate::shared::progress::{
DialogProgress, dialog_submit_button, error_row, push_steps_row, run_dialog_task_with,
};
use crate::workspace::Workspace;
/// Progress of the create-repository flow, so async results can be rendered.
pub struct CreateRepoDialog {
workspace: WeakEntity<Workspace>,
workspace: WeakEntity<AppRoot>,
handle: DialogHandle,
name_input: Entity<InputState>,
desc_input: Entity<InputState>,
@@ -37,11 +37,7 @@ pub struct CreateRepoDialog {
}
impl CreateRepoDialog {
pub fn new(
workspace: WeakEntity<Workspace>,
window: &mut Window,
cx: &mut App,
) -> Entity<Self> {
pub fn new(workspace: WeakEntity<AppRoot>, window: &mut Window, cx: &mut App) -> Entity<Self> {
let settings = SettingsStore::global(cx);
let grasp_settings = settings.read(cx).settings().grasp_servers.clone();