From f09b64ea24bbb751647ac45fb11ac7e7405ab066 Mon Sep 17 00:00:00 2001 From: Helmi Date: Thu, 26 Feb 2026 15:49:49 +0100 Subject: [PATCH] feat(ui): simplify session detail sidebar layout - Remove redundant status badge ('Working', 'Idle') - dot color already conveys status - Remove agent label text ('Codex CLI') - icon already shows agent type - Remove 'LOCATION' section header - unnecessary visual weight - Remove folder icon + project name line - path is sufficient - Keep branch name + path with copy-to-clipboard Result: More compact sidebar with essential info immediately visible. Closes: td-26d768 --- client/src/components/ContextSidebar.tsx | 100 +++++++++-------------- 1 file changed, 37 insertions(+), 63 deletions(-) diff --git a/client/src/components/ContextSidebar.tsx b/client/src/components/ContextSidebar.tsx index 8b96d2a..6ffe962 100644 --- a/client/src/components/ContextSidebar.tsx +++ b/client/src/components/ContextSidebar.tsx @@ -6,12 +6,12 @@ import { Input } from '@/components/ui/input' import { ScrollArea } from '@/components/ui/scroll-area' import { Tabs, TabsList, TabsTrigger, TabsContent } from '@/components/ui/tabs' import { Tooltip, TooltipContent, TooltipTrigger } from '@/components/ui/tooltip' -import { StatusIndicator, statusLabels } from '@/components/StatusIndicator' +import { StatusIndicator } from '@/components/StatusIndicator' import { AgentIcon, getLegacyAgentIconProps } from '@/components/AgentIcon' import { FileBrowser } from '@/components/FileBrowser' import { mapSessionState, ChangedFile } from '@/lib/types' import { TaskContextCard } from '@/components/TaskContextCard' -import { X, GitBranch, Folder, Copy, Check, FileText, FilePlus, FileX, FileEdit, FileQuestion, GitCommit, FolderTree, Pencil } from 'lucide-react' +import { X, GitBranch, Copy, Check, FileText, FilePlus, FileX, FileEdit, FileQuestion, GitCommit, FolderTree, Pencil } from 'lucide-react' import { cn, formatPath, copyToClipboard } from '@/lib/utils' export function ContextSidebar() { @@ -19,7 +19,6 @@ export function ContextSidebar() { sessions, worktrees, agents, - currentProject, contextSidebarSessionId, closeContextSidebar, openFileDiff, @@ -45,12 +44,11 @@ export function ContextSidebar() { // Find the worktree for this session const worktree = session ? worktrees.find((w) => w.path === session.path) : null - // Find agent config (for icon + label) + // Find agent config (for icon) const agentConfig = session?.agentId ? agents.find(a => a.id === session.agentId) : undefined const legacyIconProps = session?.agentId ? getLegacyAgentIconProps(session.agentId) : undefined const agentIcon = agentConfig?.icon || legacyIconProps?.icon const agentIconColor = agentConfig?.iconColor || legacyIconProps?.iconColor - const agentLabel = agentConfig?.name || session?.agentId || 'unknown' // Fetch changed files function const fetchChangedFiles = useCallback(async () => { @@ -162,8 +160,8 @@ export function ContextSidebar() { // Content shared between mobile and desktop const mainContent = ( <> - {/* Session Info */} -
+ {/* Session Info - Header area with status dot, icon, and name */} +
@@ -181,64 +179,40 @@ export function ContextSidebar() { {session.name || formatName(session.path)} )}
-
- - {statusLabels[mapSessionState(session.state)] || session.state} - - - {agentLabel} -
-
- - {/* Divider */} -
- {/* Project Info */} -
-
- Location + {/* Compact location info below session name - no section header */} +
+ {worktree && ( +
+ + + {worktree.branch || formatName(worktree.path)} + +
+ )} + + + + + +

{session.path}

+

Click to copy

+
+
- {currentProject && ( -
- - {currentProject.name} -
- )} - {worktree && ( -
- - - {worktree.branch || formatName(worktree.path)} - -
- )} - - - - - -

{session.path}

-

Click to copy

-
-
{/* Task Context (only when td is enabled) */}