@@ -155,11 +155,9 @@ export function SessionHeader() {
155155 } )
156156 const hotkey = createMemo ( ( ) => command . keybind ( "file.open" ) )
157157 const os = createMemo ( ( ) => detectOS ( platform ) )
158- const isDesktopV2 = createMemo ( ( ) => platform . platform === "desktop" && settings . general . newLayoutDesigns ( ) )
159- const search = createMemo ( ( ) => ( isDesktopV2 ( ) ? settings . general . showSearch ( ) : true ) )
160- const tree = createMemo ( ( ) => ( isDesktopV2 ( ) ? settings . general . showFileTree ( ) : true ) )
161- const term = createMemo ( ( ) => ( isDesktopV2 ( ) ? settings . general . showTerminal ( ) : true ) )
162- const status = createMemo ( ( ) => ( isDesktopV2 ( ) ? settings . general . showStatus ( ) : true ) )
158+ const isV2 = settings . general . newLayoutDesigns
159+ const search = settings . visibility . search
160+ const status = settings . visibility . status
163161
164162 const [ exists , setExists ] = createStore < Partial < Record < OpenApp , boolean > > > ( {
165163 finder : true ,
@@ -322,7 +320,7 @@ export function SessionHeader() {
322320 { ( mount ) => (
323321 < Portal mount = { mount ( ) } >
324322 < Show
325- when = { isDesktopV2 }
323+ when = { isV2 }
326324 fallback = {
327325 < div class = "flex items-center gap-2" >
328326 < Show when = { projectDirectory ( ) } >
@@ -444,23 +442,21 @@ export function SessionHeader() {
444442 < StatusPopover />
445443 </ Tooltip >
446444 </ Show >
447- < Show when = { term ( ) } >
448- < TooltipKeybind
449- title = { language . t ( "command.terminal.toggle" ) }
450- keybind = { command . keybind ( "terminal.toggle" ) }
445+ < TooltipKeybind
446+ title = { language . t ( "command.terminal.toggle" ) }
447+ keybind = { command . keybind ( "terminal.toggle" ) }
448+ >
449+ < Button
450+ variant = "ghost"
451+ class = "group/terminal-toggle titlebar-icon w-8 h-6 p-0 box-border shrink-0"
452+ onClick = { toggleTerminal }
453+ aria-label = { language . t ( "command.terminal.toggle" ) }
454+ aria-expanded = { view ( ) . terminal . opened ( ) }
455+ aria-controls = "terminal-panel"
451456 >
452- < Button
453- variant = "ghost"
454- class = "group/terminal-toggle titlebar-icon w-8 h-6 p-0 box-border shrink-0"
455- onClick = { toggleTerminal }
456- aria-label = { language . t ( "command.terminal.toggle" ) }
457- aria-expanded = { view ( ) . terminal . opened ( ) }
458- aria-controls = "terminal-panel"
459- >
460- < Icon size = "small" name = { view ( ) . terminal . opened ( ) ? "terminal-active" : "terminal" } />
461- </ Button >
462- </ TooltipKeybind >
463- </ Show >
457+ < Icon size = "small" name = { view ( ) . terminal . opened ( ) ? "terminal-active" : "terminal" } />
458+ </ Button >
459+ </ TooltipKeybind >
464460
465461 < div class = "hidden md:flex items-center gap-1 shrink-0" >
466462 < TooltipKeybind
@@ -479,32 +475,30 @@ export function SessionHeader() {
479475 </ Button >
480476 </ TooltipKeybind >
481477
482- < Show when = { tree ( ) } >
483- < TooltipKeybind
484- title = { language . t ( "command.fileTree.toggle" ) }
485- keybind = { command . keybind ( "fileTree.toggle" ) }
478+ < TooltipKeybind
479+ title = { language . t ( "command.fileTree.toggle" ) }
480+ keybind = { command . keybind ( "fileTree.toggle" ) }
481+ >
482+ < Button
483+ variant = "ghost"
484+ class = "titlebar-icon w-8 h-6 p-0 box-border"
485+ onClick = { ( ) => layout . fileTree . toggle ( ) }
486+ aria-label = { language . t ( "command.fileTree.toggle" ) }
487+ aria-expanded = { layout . fileTree . opened ( ) }
488+ aria-controls = "file-tree-panel"
486489 >
487- < Button
488- variant = "ghost"
489- class = "titlebar-icon w-8 h-6 p-0 box-border"
490- onClick = { ( ) => layout . fileTree . toggle ( ) }
491- aria-label = { language . t ( "command.fileTree.toggle" ) }
492- aria-expanded = { layout . fileTree . opened ( ) }
493- aria-controls = "file-tree-panel"
494- >
495- < div class = "relative flex items-center justify-center size-4" >
496- < Icon
497- size = "small"
498- name = { layout . fileTree . opened ( ) ? "file-tree-active" : "file-tree" }
499- classList = { {
500- "text-icon-strong" : layout . fileTree . opened ( ) ,
501- "text-icon-weak" : ! layout . fileTree . opened ( ) ,
502- } }
503- />
504- </ div >
505- </ Button >
506- </ TooltipKeybind >
507- </ Show >
490+ < div class = "relative flex items-center justify-center size-4" >
491+ < Icon
492+ size = "small"
493+ name = { layout . fileTree . opened ( ) ? "file-tree-active" : "file-tree" }
494+ classList = { {
495+ "text-icon-strong" : layout . fileTree . opened ( ) ,
496+ "text-icon-weak" : ! layout . fileTree . opened ( ) ,
497+ } }
498+ />
499+ </ div >
500+ </ Button >
501+ </ TooltipKeybind >
508502 </ div >
509503 </ div >
510504 </ div >
0 commit comments