+ {expanded ? (
+
+ ) : (
+
+ )}
+ {isScratchpad ? (
+
+ ) : (
+
+ )}
+
{project.name}
- {!isScratchpad && project.git && (
-
- )}
+ {isScratchpad && (
+
+ {visibleSessions.length}
+
+ )}
-
- {!isScratchpad && onOpenProjectSettings && (
-
{
- e.stopPropagation();
- onOpenProjectSettings(project.id);
- }}
- role="button"
- title="Project settings"
- >
-
-
+ {!isScratchpad && (onOpenProjectSettings || onRefreshGitContext) && (
+
+ {onOpenProjectSettings && (
+ {
+ e.stopPropagation();
+ onOpenProjectSettings(project.id);
+ }}
+ role="button"
+ title="Project settings"
+ >
+
+
+ )}
+ {onRefreshGitContext && (
+ {
+ e.stopPropagation();
+ onRefreshGitContext(project.id);
+ }}
+ role="button"
+ title="Refresh git status"
+ >
+
+
+ )}
+
)}
- {!isScratchpad && onRefreshGitContext && (
-
{
- e.stopPropagation();
- onRefreshGitContext(project.id);
- }}
- role="button"
- title="Refresh git status"
- >
-
-
- )}
- {runningCount > 0 && (
-
-
- {runningCount}
-
- )}
- {pendingDiscoveryCount > 0 && (
-
{
- e.stopPropagation();
- onOpenProjectSettings?.(project.id);
- }}
- role="button"
- title={`${pendingDiscoveryCount} MCP server${pendingDiscoveryCount === 1 ? '' : 's'} discovered — click to review`}
- >
- {pendingDiscoveryCount} new
-
- )}
-
- {visibleSessions.length}
-
+
+ {/* Row 2 — metadata strip: branch, status badges, session count */}
+ {!isScratchpad && (project.git || runningCount > 0 || pendingDiscoveryCount > 0 || visibleSessions.length > 0) && (
+
+ {project.git && }
+
+ {runningCount > 0 && (
+
+
+ {runningCount}
+
+ )}
+ {pendingDiscoveryCount > 0 && (
+ {
+ e.stopPropagation();
+ onOpenProjectSettings?.(project.id);
+ }}
+ role="button"
+ title={`${pendingDiscoveryCount} MCP server${pendingDiscoveryCount === 1 ? '' : 's'} discovered — click to review`}
+ >
+ {pendingDiscoveryCount} new
+
+ )}
+
+ {visibleSessions.length}
+
+
+ )}
+
{expanded && (