Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions app/src/settings/tui_zero_state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,59 @@ define_settings_group!(TuiZeroStateSettings, settings: [
toml_path: "appearance.zero_state.extrusion_depth",
description: "Normalized half-depth of the extruded Warp Agent CLI zero-state object, from 0.02 through 0.5.",
},
// Per-section visibility toggles. Each defaults to true so the zero state
// keeps rendering every section unless a section is explicitly turned off.
// The title and version lines are always shown and have no toggle.
show_signed_in_user: TuiZeroStateShowSignedInUserSetting {
type: bool,
default: true,
supported_platforms: SupportedPlatforms::DESKTOP,
sync_to_cloud: SyncToCloud::Never,
surface: settings::SettingSurfaces::TUI,
private: false,
toml_path: "appearance.zero_state.show_signed_in_user",
description: "Whether the Warp Agent CLI zero state shows the signed-in account line.",
},
show_changelog: TuiZeroStateShowChangelogSetting {
type: bool,
default: true,
supported_platforms: SupportedPlatforms::DESKTOP,
sync_to_cloud: SyncToCloud::Never,
surface: settings::SettingSurfaces::TUI,
private: false,
toml_path: "appearance.zero_state.show_changelog",
description: "Whether the Warp Agent CLI zero state shows the \"What's new\" changelog section.",
},
show_project_info: TuiZeroStateShowProjectInfoSetting {
type: bool,
default: true,
supported_platforms: SupportedPlatforms::DESKTOP,
sync_to_cloud: SyncToCloud::Never,
surface: settings::SettingSurfaces::TUI,
private: false,
toml_path: "appearance.zero_state.show_project_info",
description: "Whether the Warp Agent CLI zero state shows the project path and its discovered rules and skills.",
},
show_mcp: TuiZeroStateShowMcpSetting {
type: bool,
default: true,
supported_platforms: SupportedPlatforms::DESKTOP,
sync_to_cloud: SyncToCloud::Never,
surface: settings::SettingSurfaces::TUI,
private: false,
toml_path: "appearance.zero_state.show_mcp",
description: "Whether the Warp Agent CLI zero state shows the MCP section.",
},
show_animation: TuiZeroStateShowAnimationSetting {
type: bool,
default: true,
supported_platforms: SupportedPlatforms::DESKTOP,
sync_to_cloud: SyncToCloud::Never,
surface: settings::SettingSurfaces::TUI,
private: false,
toml_path: "appearance.zero_state.show_animation",
description: "Whether the Warp Agent CLI zero state shows the rotating object and its starfield.",
},
]);

#[cfg(test)]
Expand Down
20 changes: 1 addition & 19 deletions app/src/settings/tui_zero_state_tests.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
use std::path::PathBuf;

use serde::Deserialize as _;
use settings::schema::SettingSchemaEntry;
use settings::{Setting, SettingSurfaces, SettingsMode, SyncToCloud};
use settings::{Setting, SyncToCloud};
use settings_value::SettingsValue;

use super::{
Expand Down Expand Up @@ -106,20 +105,3 @@ fn zero_state_settings_are_tui_local_file_settings() {
);
assert_eq!(TuiZeroStateObjectSetting::max_table_depth(), Some(0));
}

#[test]
fn zero_state_schema_entries_are_tui_only() {
let zero_state_entries = inventory::iter::<SettingSchemaEntry>
.into_iter()
.filter(|entry| entry.hierarchy == Some("appearance.zero_state"))
.collect::<Vec<_>>();

assert_eq!(zero_state_entries.len(), 3);
for entry in zero_state_entries {
assert!(entry.description.contains("Warp Agent CLI"));
assert!(!entry.description.contains("TUI"));
let surfaces: SettingSurfaces = (entry.surfaces_fn)();
assert!(surfaces.includes(SettingsMode::Tui));
assert!(!surfaces.includes(SettingsMode::Gui));
}
}
Loading
Loading