feat: matrix-style subagent connection lines + smart window layout

Subagent windows now visually connect to their parent session tabs with
glowing matrix-green lines that pulse with life. Windows automatically
arrange in a non-overlapping grid, and each shows its origin with a
clickable "from [session]" header.

Watch your AI agents spawn and dance across the screen, tethered to
their creators by neon threads of digital consciousness.

Changes:
- Matrix green (#00ff41) connection lines with glow effect
- Smart grid positioning prevents window overlap
- Smaller default window size (420x350) for better density
- Auto-sizing activity columns for cleaner logs

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
arkon
2026-01-25 23:55:53 +01:00
co-authored by Claude Opus 4.5
parent 23022b533d
commit c4b737bc15
4 changed files with 25 additions and 14 deletions
+11 -3
View File
@@ -5098,10 +5098,18 @@ class ClaudemanApp {
const agent = this.subagents.get(agentId);
if (!agent) return;
// Calculate final position (cascade from top-left)
// Calculate final position - grid layout to avoid overlaps
const windowCount = this.subagentWindows.size;
const finalX = 50 + (windowCount % 5) * 30;
const finalY = 100 + (windowCount % 5) * 30;
const windowWidth = 420;
const windowHeight = 350;
const gap = 20;
const startX = 50;
const startY = 120;
const maxCols = Math.floor((window.innerWidth - startX - 50) / (windowWidth + gap)) || 1;
const col = windowCount % maxCols;
const row = Math.floor(windowCount / maxCols);
const finalX = startX + col * (windowWidth + gap);
const finalY = startY + row * (windowHeight + gap);
// Get parent tab position for spawn animation
const parentTab = agent.parentSessionId