first pass of merging in warp (doesn't build)
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
use serde::{Deserialize, Deserializer, Serialize};
|
||||
|
||||
use crate::app_state::{
|
||||
AppState, LeafContents, PaneNodeSnapshot, SplitDirection as StateSplitDirection, TabSnapshot,
|
||||
WindowSnapshot,
|
||||
};
|
||||
use crate::themes::theme::AnsiColorIdentifier;
|
||||
use serde::{Deserialize, Deserializer, Serialize};
|
||||
|
||||
#[cfg(test)]
|
||||
#[path = "launch_config_tests.rs"]
|
||||
@@ -152,10 +153,10 @@ impl TryFrom<PaneNodeSnapshot> for PaneTemplateType {
|
||||
| LeafContents::Settings(_)
|
||||
| LeafContents::AIFact(_)
|
||||
| LeafContents::CodeReview(_)
|
||||
| LeafContents::CustomRouterEditor
|
||||
| LeafContents::ExecutionProfileEditor
|
||||
| LeafContents::GetStarted
|
||||
| LeafContents::NetworkLog
|
||||
| LeafContents::Welcome { .. }
|
||||
| LeafContents::AIDocument(_)
|
||||
| LeafContents::EnvironmentManagement(_)
|
||||
| LeafContents::AmbientAgent(_) => {
|
||||
|
||||
@@ -1,15 +1,12 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
use crate::{
|
||||
app_state::{
|
||||
AppState, BranchSnapshot, LeafContents, LeafSnapshot, NotebookPaneSnapshot, PaneFlex,
|
||||
PaneNodeSnapshot, SplitDirection, TabSnapshot, TerminalPaneSnapshot, WindowSnapshot,
|
||||
},
|
||||
drive::OpenGalaxyDriveObjectSettings,
|
||||
tab::SelectedTabColor,
|
||||
};
|
||||
|
||||
use super::{LaunchConfig, PaneMode, PaneTemplateType};
|
||||
use crate::app_state::{
|
||||
AppState, BranchSnapshot, LeafContents, LeafSnapshot, NotebookPaneSnapshot, PaneFlex,
|
||||
PaneNodeSnapshot, SplitDirection, TabSnapshot, TerminalPaneSnapshot, WindowSnapshot,
|
||||
};
|
||||
use crate::drive::OpenWarpDriveObjectSettings;
|
||||
use crate::tab::SelectedTabColor;
|
||||
|
||||
fn single_tab_snapshot(root: PaneNodeSnapshot) -> AppState {
|
||||
AppState {
|
||||
@@ -21,6 +18,8 @@ fn single_tab_snapshot(root: PaneNodeSnapshot) -> AppState {
|
||||
root,
|
||||
left_panel: None,
|
||||
right_panel: None,
|
||||
group_id: None,
|
||||
pinned: false,
|
||||
}],
|
||||
active_tab_index: 0,
|
||||
bounds: None,
|
||||
@@ -35,6 +34,7 @@ fn single_tab_snapshot(root: PaneNodeSnapshot) -> AppState {
|
||||
left_panel_width: None,
|
||||
right_panel_width: None,
|
||||
agent_management_filters: None,
|
||||
tab_groups: vec![],
|
||||
}],
|
||||
active_window_index: Some(0),
|
||||
block_lists: Default::default(),
|
||||
@@ -59,6 +59,7 @@ fn multi_tab_snapshot(active_tab_index: usize, tabs: Vec<TabSnapshot>) -> AppSta
|
||||
left_panel_width: None,
|
||||
right_panel_width: None,
|
||||
agent_management_filters: None,
|
||||
tab_groups: vec![],
|
||||
}],
|
||||
active_window_index: Some(0),
|
||||
block_lists: Default::default(),
|
||||
@@ -257,7 +258,9 @@ fn test_config_with_active_tab_index() {
|
||||
)],
|
||||
}),
|
||||
left_panel: None,
|
||||
right_panel: None
|
||||
right_panel: None,
|
||||
group_id: None,
|
||||
pinned: false,
|
||||
};
|
||||
3
|
||||
],
|
||||
@@ -292,6 +295,8 @@ fn test_config_with_active_tab_index_and_filtered_tabs() {
|
||||
}),
|
||||
left_panel: None,
|
||||
right_panel: None,
|
||||
group_id: None,
|
||||
pinned: false,
|
||||
},
|
||||
TabSnapshot {
|
||||
custom_title: None,
|
||||
@@ -321,6 +326,8 @@ fn test_config_with_active_tab_index_and_filtered_tabs() {
|
||||
}),
|
||||
left_panel: None,
|
||||
right_panel: None,
|
||||
group_id: None,
|
||||
pinned: false,
|
||||
},
|
||||
],
|
||||
);
|
||||
@@ -362,6 +369,8 @@ fn test_config_with_active_tab_being_filtered() {
|
||||
}),
|
||||
left_panel: None,
|
||||
right_panel: None,
|
||||
group_id: None,
|
||||
pinned: false,
|
||||
},
|
||||
TabSnapshot {
|
||||
custom_title: None,
|
||||
@@ -383,6 +392,8 @@ fn test_config_with_active_tab_being_filtered() {
|
||||
}),
|
||||
left_panel: None,
|
||||
right_panel: None,
|
||||
group_id: None,
|
||||
pinned: false,
|
||||
},
|
||||
],
|
||||
);
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
use markdown_parser::{
|
||||
FormattedText, FormattedTextFragment, FormattedTextInline, FormattedTextLine,
|
||||
};
|
||||
use pathfinder_geometry::vector::vec2f;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::app_state::{get_app_state, AppState};
|
||||
use crate::appearance::Appearance;
|
||||
use crate::editor::{
|
||||
@@ -8,30 +14,10 @@ use crate::send_telemetry_from_ctx;
|
||||
use crate::server::telemetry::TelemetryEvent;
|
||||
use crate::user_config::launch_configs_dir;
|
||||
#[cfg(feature = "local_fs")]
|
||||
use crate::user_config::{util::file_name_to_human_readable_name, GalaxyConfig};
|
||||
use crate::user_config::{util::file_name_to_human_readable_name, WarpConfig};
|
||||
use crate::util::bindings::keybinding_name_to_display_string;
|
||||
#[cfg(feature = "local_fs")]
|
||||
use crate::util::openable_file_type::FileTarget;
|
||||
use galaxy_core::paths::home_relative_path;
|
||||
use galaxy_core::ui::theme::Fill;
|
||||
use galaxyui::accessibility::{AccessibilityContent, GalaxyA11yRole};
|
||||
use galaxyui::elements::{
|
||||
Align, Border, ChildAnchor, ChildView, Clipped, ConstrainedBox, Container, CornerRadius,
|
||||
Element, Empty, Flex, FormattedTextElement, MouseStateHandle, OffsetPositioning, ParentAnchor,
|
||||
ParentElement, ParentOffsetBounds, Radius, SavePosition, Shrinkable, Stack, Text,
|
||||
};
|
||||
use galaxyui::keymap::FixedBinding;
|
||||
use galaxyui::ui_components::button::{Button, ButtonVariant};
|
||||
use galaxyui::ui_components::components::{Coords, UiComponent, UiComponentStyles};
|
||||
use galaxyui::{
|
||||
AppContext, Entity, FocusContext, ModelHandle, SingletonEntity, TypedActionView, View,
|
||||
ViewContext, ViewHandle,
|
||||
};
|
||||
use markdown_parser::{
|
||||
FormattedText, FormattedTextFragment, FormattedTextInline, FormattedTextLine,
|
||||
};
|
||||
use pathfinder_geometry::vector::vec2f;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
const MODAL_WIDTH: f32 = 660.;
|
||||
const SIDE_PADDING: f32 = 16.;
|
||||
|
||||
Reference in New Issue
Block a user