@@ -87,6 +87,15 @@ enum WorkspaceButtonFadeSettings {
8787 }
8888}
8989
90+ enum FileExplorerFeatureSettings {
91+ static let enabledKey = " fileExplorer.featureEnabled "
92+ static let defaultEnabled = false
93+
94+ static func isEnabled( defaults: UserDefaults = . standard) -> Bool {
95+ defaults. object ( forKey: enabledKey) as? Bool ?? defaultEnabled
96+ }
97+ }
98+
9099enum PaneFirstClickFocusSettings {
91100 static let enabledKey = " paneFirstClickFocus.enabled "
92101 static let defaultEnabled = false
@@ -4247,6 +4256,8 @@ struct SettingsView: View {
42474256 private var closeWorkspaceOnLastSurfaceShortcut = LastSurfaceCloseShortcutSettings . defaultValue
42484257 @AppStorage ( PaneFirstClickFocusSettings . enabledKey)
42494258 private var paneFirstClickFocusEnabled = PaneFirstClickFocusSettings . defaultEnabled
4259+ @AppStorage ( FileExplorerFeatureSettings . enabledKey)
4260+ private var fileExplorerFeatureEnabled = FileExplorerFeatureSettings . defaultEnabled
42504261 @AppStorage ( WorkspaceAutoReorderSettings . key) private var workspaceAutoReorder = WorkspaceAutoReorderSettings . defaultValue
42514262 @AppStorage ( SidebarWorkspaceDetailSettings . hideAllDetailsKey)
42524263 private var sidebarHideAllDetails = SidebarWorkspaceDetailSettings . defaultHideAllDetails
@@ -4346,6 +4357,22 @@ struct SettingsView: View {
43464357 )
43474358 }
43484359
4360+ @ViewBuilder
4361+ private var fileExplorerSettingsRow : some View {
4362+ SettingsCardRow (
4363+ configurationReview: . settingsOnly,
4364+ String ( localized: " settings.app.fileExplorer " , defaultValue: " File Explorer " ) ,
4365+ subtitle: String ( localized: " settings.app.fileExplorer.subtitle " , defaultValue: " Show a file explorer panel on the right side of the terminal (Cmd+Option+B). " )
4366+ ) {
4367+ Toggle ( " " , isOn: $fileExplorerFeatureEnabled)
4368+ . labelsHidden ( )
4369+ . controlSize ( . small)
4370+ . accessibilityLabel (
4371+ String ( localized: " settings.app.fileExplorer " , defaultValue: " File Explorer " )
4372+ )
4373+ }
4374+ }
4375+
43494376 private var paneFirstClickFocusSubtitle : String {
43504377 if paneFirstClickFocusEnabled {
43514378 return String (
@@ -4889,6 +4916,10 @@ struct SettingsView: View {
48894916
48904917 SettingsCardDivider ( )
48914918
4919+ fileExplorerSettingsRow
4920+
4921+ SettingsCardDivider ( )
4922+
48924923 SettingsCardRow (
48934924 configurationReview: . json( " app.preferredEditor " ) ,
48944925 String ( localized: " settings.app.preferredEditor " , defaultValue: " Open Files With " ) ,
@@ -6333,6 +6364,7 @@ struct SettingsView: View {
63336364 defaults. removeObject ( forKey: WorkspaceButtonFadeSettings . legacyPaneTabBarControlsVisibilityModeKey)
63346365 closeWorkspaceOnLastSurfaceShortcut = LastSurfaceCloseShortcutSettings . defaultValue
63356366 paneFirstClickFocusEnabled = PaneFirstClickFocusSettings . defaultEnabled
6367+ fileExplorerFeatureEnabled = FileExplorerFeatureSettings . defaultEnabled
63366368 workspaceAutoReorder = WorkspaceAutoReorderSettings . defaultValue
63376369 sidebarHideAllDetails = SidebarWorkspaceDetailSettings . defaultHideAllDetails
63386370 sidebarShowNotificationMessage = SidebarWorkspaceDetailSettings . defaultShowNotificationMessage
0 commit comments