Commit graph

665 commits

Author SHA1 Message Date
iliya
98a1155635 feat(graph): wire popover actions to real dialogs (Message, Open task/member)
- TeamGraphOverlay accepts onSendMessage, onOpenTaskDetail, onOpenMemberProfile
- TeamDetailView passes dialog openers to overlay:
  - Message → opens SendMessageDialog with recipient pre-filled
  - Open (task) → opens TaskDetailDialog with task found by ID
  - Open (member) → opens SendMessageDialog for that member
  - Double-click → same as Open
- Removed console.log stubs
2026-03-28 12:56:43 +02:00
iliya
d85058f198 feat(graph): robohash avatars inside member hexagons + center column headers
- Member/lead nodes show robohash avatar image clipped to circle inside hex
- Async image loading with cache (fallback to first letter while loading)
- avatarUrl field added to GraphNode type + adapter passes agentAvatarUrl()
- Column headers now centered over pill center (was offset by half pill width)
2026-03-28 12:46:25 +02:00
iliya
6866f003dc feat(graph): spawn/edge/task/comment animations
1. Member spawn animation: rotating dashed ring for 'spawning' status,
   pulsing hex outline for 'waiting' status
2. Edge flash: active edges pulse brighter (0.1-0.5 alpha) with glow
   shadow when particles travel along them
3. Smooth task positioning: tasks LERP to target position (0.15 factor)
   instead of teleporting when kanban column changes
4. Comment flight particles: when a member adds a comment to a task,
   a purple particle with speech bubble flies from member to task node
2026-03-28 12:27:37 +02:00
iliya
17e9be99dd fix(ui): change auto-approve banner from warning to info style 2026-03-28 12:23:28 +02:00
Илия
11bb49c53e
feat(graph): force-directed agent graph visualization with kanban-zone task layout
Force-directed graph visualization for agent teams.

Package: @claude-teams/agent-graph (isolated workspace package)
- Space theme: bloom, particles, hex grid, depth stars
- Members as hexagonal nodes with breathing glow
- Tasks as pill cards in kanban columns (todo/wip/done/review/approved) per owner
- Message particles along edges (real-time only)
- Deterministic layout, Figma-style pan, scroll/pinch zoom
- Clean Architecture: ports/adapters/strategies, ES #private classes

Integration: features/agent-graph/ (adapter + overlay + tab)
- Full-screen overlay (Cmd+Shift+G) + Pin as Tab
- Graph button in Team section header
- Frustum culling, zero per-frame allocations, adaptive fps
- Performance overlay via ?perf query param

Also: CI runs on all PR branches, features/CLAUDE.md architecture guide
2026-03-28 12:03:42 +02:00
iliya
dd42cf0069 fix(team): scan inbox for permission_request during provisioning
relayLeadInboxMessages only processes unread messages after
provisioningComplete, but CLI marks permission_request messages as
read after native delivery -- before our relay runs.

Move permission_request inbox scan BEFORE provisioningComplete check.
Scan ALL messages (including read=true), track processed IDs via
processedPermissionRequestIds Set on ProvisioningRun to prevent
re-emitting. Also look up both alive and provisioning runs so the
scan works during team bootstrap.
2026-03-27 23:35:52 +02:00
iliya
df6a23e3a2 Merge branch 'worktree-fix-permission-request-ui' into dev 2026-03-27 22:04:55 +02:00
iliya
d0b9c4f529 fix(team): settings panel opens below buttons instead of beside them
Split ToolApprovalSettingsPanel into ToolApprovalSettingsToggle (inline
button) and ToolApprovalSettingsContent (full-width expandable panel).
Toggle sits in the actions row, content renders below it inside the popup.
2026-03-27 22:04:44 +02:00
iliya
5c0eb1fa38 Merge branch 'worktree-fix-permission-request-ui' into dev 2026-03-27 20:16:14 +02:00
iliya
c0c20d07f8 fix(team): add backdrop overlay to ToolApprovalSheet and move Settings inline
- Add semi-transparent backdrop (bg-black/40) behind the approval popup
  to draw attention and dim surrounding UI
- Refactor ToolApprovalSettingsPanel to render toggle button inline
  (fragment-based) so it can sit in the actions row next to pending count
- Settings button now appears right-aligned at the same level as
  Allow/Deny buttons; expanded panel renders below
2026-03-27 20:16:03 +02:00
iliya
f2eabf3866 Merge branch 'worktree-fix-permission-request-ui' into dev 2026-03-27 20:09:09 +02:00
iliya
bdd0dc6f39 fix(team): add permission_request interception in stdout handler + diagnostic logging
- Parse raw user text for permission_request in handleStreamJsonMessage
  (covers case where permission_request arrives without <teammate-message> wrapper)
- Add [PERM-TRACE] logger.warn diagnostics to trace the exact flow:
  where permission_request is detected, whether it reaches handleTeammatePermissionRequest,
  and whether relay or stdout interception triggers
- These logs will help diagnose why ToolApprovalSheet may not appear
2026-03-27 20:09:01 +02:00
iliya
148823e284 Merge branch 'worktree-fix-permission-request-ui' into dev 2026-03-27 18:45:07 +02:00
iliya
ed1726c298 fix(team): intercept permission_request in native stdout delivery path
relayLeadInboxMessages only runs after provisioningComplete, but
teammate permission_request messages arrive during bootstrap (before
provisioning finishes). Claude Code delivers them natively via stdout
type:"user" messages, bypassing the relay entirely.

Add permission_request interception in handleNativeTeammateUserMessage
which processes stdout user messages at all times, including during
provisioning. This ensures ToolApprovalSheet appears immediately when
teammates need tool permission.
2026-03-27 18:44:58 +02:00
iliya
373f2aac9b Merge branch 'worktree-fix-permission-request-ui' into dev 2026-03-27 18:13:06 +02:00
iliya
8ea470b1ae fix(team): intercept permission_request regardless of native delivery status
When Claude Code runtime natively delivers permission_request to the
lead via stdout, the message was excluded from interception by the
nativeMatchedMessageIds filter. This caused the ToolApprovalSheet to
not appear for teammate requests.

Remove nativeMatchedMessageIds check from the permission_request
filter so interception works even for natively delivered messages.
2026-03-27 18:12:58 +02:00
iliya
085147ffc0 Merge branch 'worktree-fix-permission-request-ui' into dev 2026-03-27 17:56:08 +02:00
iliya
924bcd8b99 fix(team): render teammate permission requests in ToolApprovalSheet instead of raw JSON
When auto-approve is disabled, teammate tool requests arrived as
permission_request JSON via SendMessage and rendered as "Raw JSON"
with no way to approve/deny (#29).

- Intercept permission_request in lead inbox relay, convert to
  ToolApprovalRequest and show in existing ToolApprovalSheet
- Respond via teammate inbox (permission_response) + control_response
  via stdin as fallback
- Show teammate name in approval header (e.g. "bob — Bash")
- Compact noise label in Messages panel for permission_request/response
- Proper file locking, race condition protection, idempotency checks
2026-03-27 17:55:59 +02:00
iliya
507bf798eb improvement(task-change): improve task change presence tracking and related IPC handlers
- Added support for tracking task change presence with new IPC channels: TEAM_GET_TASK_CHANGE_PRESENCE and TEAM_SET_CHANGE_PRESENCE_TRACKING.
- Introduced JsonTaskChangePresenceRepository and TeamLogSourceTracker to manage task change presence data.
- Enhanced ChangeExtractorService to utilize task change presence services for improved task change detection.
- Updated TeamDataService to integrate task change presence tracking and resolve task change presence states.
- Modified UI components to reflect task change presence status in Kanban and task detail views.

This feature aims to provide real-time insights into task changes, enhancing user experience and task management capabilities.
2026-03-27 17:52:39 +02:00
iliya
ecba775c76 Improve macOS title bar drag area 2026-03-27 17:21:18 +02:00
iliya
e1413a32bd Guard renderer IPC sends during crash recovery 2026-03-27 17:07:40 +02:00
iliya
9f8287755c fix(updater): improve update dialog layout and strip downloads section
Widen dialog (max-w-lg → max-w-2xl), remove prose max-width constraint
that caused empty space on the right, and filter out the Downloads
heading with everything below it from release notes.
2026-03-26 13:13:50 +02:00
iliya
344bf41fe5 fix(updater): verify platform asset exists before showing update notification
HEAD-request the expected installer URL (DMG/EXE/AppImage) before
notifying the user about a new version. If CI hasn't finished
uploading the artifact for the current OS yet, the notification is
suppressed and retried on the next periodic check.
2026-03-26 00:50:12 +02:00
iliya
c7ee51884d Merge branch 'worktree-upstream-merge' into dev 2026-03-25 15:44:54 +02:00
iliya
bd90de8e81 fix(team): notify lead on task create with startImmediately
Extract sendUserTaskStartNotification as reusable private method.
When a task is created via UI directly in "In Progress" column
(startImmediately=true), the controller's maybeNotifyAssignedOwner
skips the lead. Now createTask sends the notification to the lead
with full description, prompt, and task_get instructions.
2026-03-25 15:03:44 +02:00
iliya
58f3ccd4b4 feat(dashboard): add auth troubleshooting guide to CLI status banner
Add "Already logged in?" button next to Login that expands a
step-by-step troubleshooting panel: re-check status, terminal
commands, re-login instructions, and binary path display.
Also clarifies that browsing works without login.
2026-03-25 15:00:42 +02:00
iliya
141d0e22d9 feat(team): implement startTaskByUser functionality
- Added a new IPC handler for starting tasks triggered by users, ensuring that the task owner is always notified.
- Introduced `startTaskByUser` method in `TeamDataService` to handle task initiation and notifications.
- Updated relevant components and API interfaces to support the new functionality, including changes in the UI to call `startTaskByUser` instead of the previous `startTask`.
- Documented agent block usage for internal instructions in CLAUDE.md.

This enhancement improves user interaction with task management by providing a clear mechanism for user-initiated task starts.
2026-03-25 14:47:27 +02:00
iliya
22387ca0cb perf: add search debounce and increase global search timeout
- SearchBar: 300ms debounce with local input state, flush on Enter
- CommandPalette: global search debounce 200→400ms
- Show "500+" when search results are capped
- Fix: syncSearchMatchesWithRendered now updates searchMatchItemIds

Ported from upstream 5c7f921e (SearchBar/CommandPalette parts).
2026-03-25 14:38:07 +02:00
iliya
c21350713c perf: replace remark-based search with plain text indexOf
Manually ported from upstream 5c7f921e. Key changes:
- SessionSearcher: indexOf instead of remark AST, batch size 8→16
- conversationSlice: indexOf with MAX_SEARCH_MATCHES=500 cap
- Item-scoped store selectors (searchMatchItemIds Set) to skip re-renders
- Pre-filter in markdownTextSearch (skip parse if no raw match)
- SearchTextCache: 200→1000 entries
- ProjectScanner: 30s search project cache, batch 4→8
2026-03-25 14:32:37 +02:00
iliya
e30f6482bf fix: WSL mount path translation + Windows drive letter normalization
Manually ported from upstream:
- c239cda6: translateWslMountPath() converts /mnt/X/... → X:/... on Windows
- 7f5fbdab: normalizeDriveLetter() uppercases drive letter (c:/ → C:/)

Both are no-op on macOS/Linux. Fixes session fragmentation on Windows+WSL.
2026-03-25 14:22:04 +02:00
iliya
aeed5a0873 feat: add syntax highlighting for R, Ruby, PHP, and SQL
Cherry-picked from upstream 022c75da with conflict resolution.
Merged our codeClassName support with upstream per-line highlighting.
2026-03-25 14:05:53 +02:00
iliya
b87082a915 fix: requestId dedup to prevent ~2x cost overcounting + stale session detection
Manually ported from upstream:
- ef2e0868: deduplicate streaming JSONL entries by requestId
- 4f21f267: mark stale ongoing sessions as dead after 5min inactivity
2026-03-25 14:05:01 +02:00
iliya
aaa766b2ba perf: replace 8 filter passes with single-pass message categorization
Cherry-picked from upstream 9fa2590e
2026-03-25 13:59:03 +02:00
iliya
6fa075de51 fix: sidebar header repo/branch not syncing when switching tabs
Cherry-picked from upstream d2341d50
2026-03-25 13:58:48 +02:00
iliya
4946a65a7b feat: cherry-pick upstream CollapsibleOutputSection + TriggerMatcher regex cache
Cherry-picked from upstream:
- 516d0f6b: CollapsibleOutputSection with markdown preview toggle
- e51c1fd1: cache compiled regexes in TriggerMatcher (perf)
2026-03-25 13:58:38 +02:00
iliya
7324b5236d fix(team): update tool references from Task to Agent in provisioning messages
- Changed references in messages to use the **Agent** tool instead of the Task tool for spawning teammates.
- Added warnings for missing team_name to ensure agents are persistent rather than ephemeral.
- Updated documentation within the code to reflect the new requirements for spawning teammates.
2026-03-25 13:38:26 +02:00
iliya
b8aa2d9f14 fix(auth): enrich PTY env and invalidate status cache after login
- Use buildEnrichedEnv() in PtyTerminalService so login terminal gets
  full PATH (Homebrew, nvm, etc.) and USER for Keychain lookup
- Add cliInstaller:invalidateStatus IPC to clear cached auth status
  after successful login, preventing stale "not logged in" responses
- Show "Verifying authentication..." spinner instead of flashing
  the "Not logged in" banner between modal close and status refresh

Ref #27
2026-03-25 13:36:12 +02:00
iliya
60d80cde70 fix(auth): avoid setting CLAUDE_CONFIG_DIR when it matches default path
On macOS, the Claude CLI uses a Keychain namespace derived from the
presence of CLAUDE_CONFIG_DIR env var. Setting it to the default
~/.claude creates a different Keychain key than when the var is absent,
causing "not logged in" errors even after successful `claude auth login`.

Only set CLAUDE_CONFIG_DIR when the user has configured a custom path
that differs from the auto-detected default.

Fixes #27
2026-03-25 12:23:57 +02:00
iliya
896c749e76 fix: add recursive option to fs.rm for directory removal
fs.rm() without { recursive: true } throws ERR_FS_EISDIR on directories,
unlike the deprecated fs.rmdir() which handled empty dirs. Also fix
broken roadmap bullet in README.
2026-03-24 21:43:43 +02:00
iliya
08be8590da fix: electron 28→40 migration fixes
- Replace deprecated fs.rmdir with fs.rm (Node 22+ deprecation)
- Update electron-builder 25.1.8 → 26.8.1 (required for Electron 35+)
- Add macOS minimumSystemVersion 12.0 (Electron 38+ requirement)
- Update React 18 → 19 in README.md tech stack
2026-03-24 21:13:06 +02:00
iliya
3b65dc4e3b fix(lint): resolve import sort errors and update tech stack in CLAUDE.md
- ProjectScanner.ts, cliEnv.ts: fix simple-import-sort/imports order
- CLAUDE.md: update tech stack to Electron 40.x, React 19.x
2026-03-24 18:23:00 +02:00
iliya
368f42f04f fix(hooks): resolve react-hooks/refs lint errors breaking CI
- useMarkCommentsRead: replace useRef().current with useCallback for
  stable ref callback (accessing ref during render is not allowed)
- useAttachments: add eslint-disable for intentional ref sync pattern
2026-03-24 18:06:08 +02:00
iliya
94fc564bf5 feat: UI improvements, bug fixes, and protocol noise filtering
- Fix incorrect error message when attaching files to team lead while team is offline
- Kanban columns: color only on headers, body with 30% alpha tint per user preference
- Worktree projects now correctly detected on Dashboard via path-based detection
- Filter raw protocol messages (idle_notification, teammate-message) from lead thoughts
- Consistent text styles in Attachments section (From original message / From comments)
- Secondary sort for teams by lastActivity timestamp with alphabetical fallback
- Remove colored background from team cards, keep only left border
- Dynamic member color in Add Members dialog based on next available palette color
- Stylized @-mentions in task comments with colored MemberBadge
- Refactor CLI env resolution to shared utility
2026-03-24 17:47:15 +02:00
iliya
7298cffaf5 Merge remote-tracking branch 'origin/worktree-react-19-migration' into dev 2026-03-24 17:12:52 +02:00
iliya
47dac2e8b5 feat: migrate to React 19
Upgrade React 18.3.1 → 19.2.4 with full type compatibility.

Changes:
- react, react-dom → ^19.0.0
- @types/react, @types/react-dom → ^19.0.0
- lucide-react → ^0.577.0 (React 19 type fixes)
- @tiptap/* → ^3.20.4 (React 19 support)
- useRef calls now require explicit initial value (undefined)
- RefObject types updated for React 19 (includes null)
- MutableRefObject → RefObject (deprecated in 19)
- act() import moved from react-dom/test-utils to react
- Scoped JSX namespace imports added where needed
2026-03-24 17:11:55 +02:00
iliya
1718f9cf7c refactor(README): reorganize roadmap items for clarity and update language switcher flag icon
- Rearranged roadmap items in README.md for better organization, moving planning mode and visual workflow editor to the top.
- Updated the flag icon for English in LanguageSwitcher.vue from the US to the GB flag.
- Enhanced user environment setup in CliInstallerService.ts by adding user information retrieval.
- Improved timestamp handling in MemberLogsTab.tsx to better reflect recent activity.
- Adjusted button class names in ProvisioningProgressBlock.tsx for consistency.
2026-03-24 16:52:12 +02:00
iliya
e0d4782c80 fix(lint): resolve ESLint errors breaking CI validate
- markdownPlugins.ts: use dot notation for abbr attribute access
- useResizablePanel.ts: wrap ref.current assignments in useEffect
  to comply with react-hooks/refs rule
2026-03-24 12:39:06 +02:00
iliya
2e5d91f8f8 fix(settings): update About section description to reflect current features
Old text referenced waterfall charts; replaced with current capabilities:
agent teams, kanban board, code review, cross-team communication.
2026-03-24 12:38:58 +02:00
Leigh Stillard
8e84961d4a fix(standalone): fix standalone mode to run without Electron
Three issues prevented standalone (non-Electron) mode from working:

1. sentry.ts used a top-level `import * from '@sentry/electron/main'`
   which crashes in plain Node.js. Changed to a try/catch require()
   so the module is safe to import in both environments.

2. vite.standalone.config.ts resolved all paths relative to __dirname
   (docker/) but is invoked from the repo root. Fixed to resolve
   relative to the repo root via a ROOT constant.

3. The electron stub was missing `safeStorage` and `screen` exports
   that newer code imports. Added them, and externalized
   agent-teams-controller (plain CJS with relative requires that
   break when bundled by Vite).
2026-03-24 03:43:26 +00:00
Leigh Stillard
d6ee7bc320 fix(security): simplify attributes merge to prevent future override
The previous Object.fromEntries spread would silently overwrite the
custom abbr attribute list if rehype-sanitize adds abbr to its default
schema in a future version. Simplify to a direct merge.
2026-03-24 01:25:26 +00:00