commandmate 0.39.1 → 0.40.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.next/BUILD_ID +1 -1
- package/.next/app-build-manifest.json +250 -243
- package/.next/app-path-routes-manifest.json +31 -30
- package/.next/build-manifest.json +2 -2
- package/.next/prerender-manifest.json +15 -15
- package/.next/required-server-files.json +1 -1
- package/.next/routes-manifest.json +8 -0
- package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/server/app/api/agents/update/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/agents/versions/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/app/release-notes/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/app/update/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/app/update-check/route.js +1 -1
- package/.next/server/app/api/app/update-check/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/auth/login/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/auth/logout/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/auth/status/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/capabilities/route.js +1 -1
- package/.next/server/app/api/capabilities/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/daily-summary/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/daily-summary/status/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/external-apps/[id]/health/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/external-apps/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/external-apps/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/fs/browse/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/fs/recent-paths/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/hooks/agent-event/route.js.nft.json +1 -1
- package/.next/server/app/api/hooks/agent-event/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/hooks/claude-done/route.js +1 -1
- package/.next/server/app/api/hooks/claude-done/route.js.nft.json +1 -1
- package/.next/server/app/api/hooks/claude-done/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/hooks/permission-request/route.js.nft.json +1 -1
- package/.next/server/app/api/hooks/permission-request/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/metrics/vibe/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/ollama/models/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/push/escalation/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/push/subscriptions/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/push/vapid/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/relays/[relayId]/cancel/route.js.nft.json +1 -1
- package/.next/server/app/api/relays/[relayId]/cancel/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/relays/route.js.nft.json +1 -1
- package/.next/server/app/api/relays/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/remote/pair/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/clone/[jobId]/route.js +1 -1
- package/.next/server/app/api/repositories/clone/[jobId]/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/clone/[jobId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/clone/route.js +1 -1
- package/.next/server/app/api/repositories/clone/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/clone/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/excluded/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/restore/route.js +1 -1
- package/.next/server/app/api/repositories/restore/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/restore/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/route.js +1 -1
- package/.next/server/app/api/repositories/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/scan/route.js +1 -1
- package/.next/server/app/api/repositories/scan/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/scan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/sync/route.js +1 -1
- package/.next/server/app/api/repositories/sync/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/sync/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/validate-path/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/settings/default-agents/route.js +1 -1
- package/.next/server/app/api/settings/default-agents/route.js.nft.json +1 -1
- package/.next/server/app/api/settings/default-agents/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/settings/default-surface-mode/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/sidebar/group-order/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/installations/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/operations/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/reindex/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/slash-commands/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/tasks/[taskId]/cancel/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/tasks/[taskId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/templates/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/templates/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/verification/runs/[runId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/verification/runs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/auto-yes/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/auto-yes/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/auto-yes/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/capture/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/capture/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/capture/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/clear-composer/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/clear-composer/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/clear-composer/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/cli-reference/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/cli-tool/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/cmate/schedules/route.js +2 -2
- package/.next/server/app/api/worktrees/[id]/cmate/schedules/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/cmate/schedules/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/current-output/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/current-output/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/current-output/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/direct-input/route.js +1 -0
- package/.next/server/app/api/worktrees/[id]/direct-input/route.js.nft.json +1 -0
- package/.next/server/app/api/worktrees/[id]/direct-input/route_client-reference-manifest.js +1 -0
- package/.next/server/app/api/worktrees/[id]/env/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/execution-logs/[logId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/execution-logs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/files/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/branch/create/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/branch/delete/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/branches/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/checkout/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/commit/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/diff/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/fetch/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/log/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/pull/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/push/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/reset/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/revert/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/show/[commitHash]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stage/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/staged/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/[index]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/apply/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/pop/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/push/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/status/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/unstage/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/working-diff/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/instances/notes/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/instances/opencode/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/instances/opencode/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/interrupt/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/interrupt/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/interrupt/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/kill-session/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/kill-session/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/kill-session/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/logs/[filename]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/logs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/marp-render/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/memos/[memoId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/memos/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/messages/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/opencode/diff/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/opencode/session/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/opencode/share/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/prompt-response/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/prompt-response/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/prompt-response/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/resolve-target/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/respond/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/respond/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/respond/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/[scheduleId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/active/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/active/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/active/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/search/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/send/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/send/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/send/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/install/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/plan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall-plan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update-plan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/slash-commands/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/special-keys/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/special-keys/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/special-keys/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/tasks/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/terminal/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/terminal/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/terminal/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/history/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/todos/[todoId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/todos/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/tree/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/tree/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/upload/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/config/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/viewed/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/apply-default-agents/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/route.js +1 -1
- package/.next/server/app/api/worktrees/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/route_client-reference-manifest.js +1 -1
- package/.next/server/app/login/page_client-reference-manifest.js +1 -1
- package/.next/server/app/manifest.webmanifest/route_client-reference-manifest.js +1 -1
- package/.next/server/app/more/page_client-reference-manifest.js +1 -1
- package/.next/server/app/offline/page_client-reference-manifest.js +1 -1
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/app/proxy/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/repositories/page_client-reference-manifest.js +1 -1
- package/.next/server/app/review/page.js +1 -1
- package/.next/server/app/review/page_client-reference-manifest.js +1 -1
- package/.next/server/app/sessions/page.js +1 -1
- package/.next/server/app/sessions/page.js.nft.json +1 -1
- package/.next/server/app/sessions/page_client-reference-manifest.js +1 -1
- package/.next/server/app/skills/[skillId]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/skills/installed/page_client-reference-manifest.js +1 -1
- package/.next/server/app/skills/page_client-reference-manifest.js +1 -1
- package/.next/server/app/worktrees/[id]/files/[...path]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/worktrees/[id]/page.js +10 -10
- package/.next/server/app/worktrees/[id]/page.js.nft.json +1 -1
- package/.next/server/app/worktrees/[id]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/worktrees/[id]/terminal/page_client-reference-manifest.js +1 -1
- package/.next/server/app-paths-manifest.json +31 -30
- package/.next/server/chunks/2119.js +1 -1
- package/.next/server/chunks/2445.js +1 -1
- package/.next/server/chunks/252.js +1 -0
- package/.next/server/chunks/2816.js +1 -1
- package/.next/server/chunks/3241.js +1 -1
- package/.next/server/chunks/3323.js +1 -1
- package/.next/server/chunks/4443.js +1 -1
- package/.next/server/chunks/5164.js +1 -1
- package/.next/server/chunks/6130.js +1 -1
- package/.next/server/chunks/650.js +1 -1
- package/.next/server/chunks/6661.js +1 -1
- package/.next/server/chunks/6793.js +1 -1
- package/.next/server/chunks/7685.js +1 -1
- package/.next/server/chunks/7905.js +1 -1
- package/.next/server/chunks/8581.js +29 -29
- package/.next/server/chunks/8673.js +14 -0
- package/.next/server/chunks/8728.js +4 -3
- package/.next/server/chunks/8800.js +1 -1
- package/.next/server/chunks/9080.js +1 -1
- package/.next/server/chunks/9731.js +2 -2
- package/.next/server/chunks/9882.js +3 -3
- package/.next/server/middleware-manifest.json +5 -5
- package/.next/server/pages/500.html +1 -1
- package/.next/server/server-reference-manifest.json +1 -1
- package/.next/static/chunks/{1642-fb2e176aaadbd137.js → 1642-767aed8e7c61ef7f.js} +1 -1
- package/.next/static/chunks/{2407-9ac8b6188ddbb119.js → 2407-e259744922e0834c.js} +1 -1
- package/.next/static/chunks/{2619-04bc32f026a0d946.js → 2619-a305ad4810f1393a.js} +1 -1
- package/.next/static/chunks/4768-979c8a03bed218e7.js +1 -0
- package/.next/static/chunks/7705-25076b57224da370.js +1 -0
- package/.next/static/chunks/{8165-d3b7c8a7aa776bc7.js → 8165-8944f74c53f3021f.js} +1 -1
- package/.next/static/chunks/8606-9a381b996f9b6834.js +1 -0
- package/.next/static/chunks/9619-22adf5367c4b7080.js +1 -0
- package/.next/static/chunks/app/api/agents/update/{route-70779af8b4c8259a.js → route-0468c3c4baa46028.js} +1 -1
- package/.next/static/chunks/app/api/agents/versions/{route-70779af8b4c8259a.js → route-0468c3c4baa46028.js} +1 -1
- package/.next/static/chunks/app/api/app/release-notes/{route-70779af8b4c8259a.js → route-0468c3c4baa46028.js} +1 -1
- package/.next/static/chunks/app/api/app/update/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/app/update-check/{route-70779af8b4c8259a.js → route-0468c3c4baa46028.js} +1 -1
- package/.next/static/chunks/app/api/auth/login/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/auth/logout/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/auth/status/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/capabilities/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/daily-summary/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/daily-summary/status/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/external-apps/[id]/health/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/external-apps/[id]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/external-apps/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/fs/browse/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/fs/recent-paths/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/hooks/agent-event/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/hooks/claude-done/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/hooks/permission-request/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/metrics/vibe/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/ollama/models/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/push/escalation/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/push/subscriptions/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/push/vapid/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/relays/[relayId]/cancel/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/relays/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/remote/pair/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/[id]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/clone/[jobId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/clone/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/excluded/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/restore/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/scan/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/sync/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/repositories/validate-path/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/settings/default-agents/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/settings/default-surface-mode/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/sidebar/group-order/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/skills/[id]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/skills/installations/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/skills/operations/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/skills/reindex/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/skills/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/slash-commands/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/tasks/[taskId]/cancel/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/tasks/[taskId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/templates/[id]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/templates/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/verification/runs/[runId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/verification/runs/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/auto-yes/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/capture/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/clear-composer/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/cli-reference/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/cli-tool/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/cmate/schedules/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/current-output/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/direct-input/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/env/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/execution-logs/[logId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/execution-logs/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/files/[...path]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/branch/create/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/branch/delete/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/branches/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/checkout/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/commit/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/diff/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/fetch/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/log/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/pull/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/push/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/reset/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/revert/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/show/[commitHash]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/stage/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/staged/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/[index]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/apply/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/pop/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/push/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/status/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/unstage/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/git/working-diff/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/instances/notes/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/instances/opencode/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/interrupt/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/kill-session/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/logs/[filename]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/logs/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/marp-render/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/memos/[memoId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/memos/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/messages/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/opencode/diff/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/opencode/session/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/opencode/share/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/prompt-response/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/resolve-target/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/respond/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/schedules/[scheduleId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/schedules/active/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/schedules/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/search/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/send/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/install/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/plan/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/uninstall/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/uninstall-plan/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/update/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/update-plan/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/skills/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/slash-commands/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/special-keys/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/tasks/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/terminal/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/timers/history/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/timers/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/todos/[todoId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/todos/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/tree/[...path]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/tree/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/upload/[...path]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/verify/config/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/verify/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/verify/runs/[runId]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/verify/runs/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/[id]/viewed/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/apply-default-agents/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/api/worktrees/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/layout-b90cce6a51c91f4c.js +1 -0
- package/.next/static/chunks/app/manifest.webmanifest/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/proxy/[...path]/route-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/review/page-30616daa1dc595c2.js +1 -0
- package/.next/static/chunks/app/sessions/page-1a8ba152bbcb9efb.js +1 -0
- package/.next/static/chunks/app/worktrees/[id]/layout-0468c3c4baa46028.js +1 -0
- package/.next/static/chunks/app/worktrees/[id]/page-e9ebdcd317b62e4a.js +1 -0
- package/.next/static/chunks/app/worktrees/[id]/terminal/{page-373ea37b16d930c7.js → page-c601f3b3ece6557e.js} +1 -1
- package/.next/static/css/974314e796232f53.css +1 -0
- package/.next/trace +13 -13
- package/.next/types/app/api/worktrees/[id]/direct-input/route.ts +347 -0
- package/.next/types/routes.d.ts +2 -1
- package/.next/types/validator.ts +9 -0
- package/dist/cli/commands/ls.d.ts.map +1 -1
- package/dist/cli/commands/ls.js +9 -0
- package/dist/cli/commands/peers.d.ts.map +1 -1
- package/dist/cli/commands/peers.js +4 -0
- package/dist/cli/commands/send.d.ts.map +1 -1
- package/dist/cli/commands/send.js +20 -6
- package/dist/cli/config/model-validation.d.ts +22 -0
- package/dist/cli/config/model-validation.d.ts.map +1 -1
- package/dist/cli/config/model-validation.js +35 -1
- package/dist/cli/types/api-responses.d.ts +11 -0
- package/dist/cli/types/api-responses.d.ts.map +1 -1
- package/dist/lib/detection/status-reason.d.ts +13 -0
- package/dist/lib/detection/status-reason.d.ts.map +1 -1
- package/dist/lib/detection/status-reason.js +13 -0
- package/dist/lib/detection/tools/verified-against.d.ts +74 -5
- package/dist/lib/detection/tools/verified-against.d.ts.map +1 -1
- package/dist/lib/detection/tools/verified-against.js +74 -5
- package/dist/server/locales/en/worktree.json +58 -0
- package/dist/server/locales/ja/worktree.json +58 -0
- package/dist/server/src/config/claude-constants.js +27 -0
- package/dist/server/src/lib/cli-tools/base.js +2 -1
- package/dist/server/src/lib/cli-tools/claude.js +5 -1
- package/dist/server/src/lib/cli-tools/command-code.js +5 -1
- package/dist/server/src/lib/cli-tools/direct-input.js +22 -0
- package/dist/server/src/lib/cmate-cli-tool-parser.js +31 -0
- package/dist/server/src/lib/detection/cli-patterns.js +44 -5
- package/dist/server/src/lib/detection/selection-shape.js +274 -19
- package/dist/server/src/lib/detection/status-detector.js +2 -0
- package/dist/server/src/lib/detection/status-reason.js +13 -0
- package/dist/server/src/lib/detection/tools/codex/cli-patterns.js +67 -27
- package/dist/server/src/lib/detection/tools/codex/detect.js +18 -3
- package/dist/server/src/lib/detection/tools/command-code/detect.js +46 -0
- package/dist/server/src/lib/detection/tools/command-code/dialog.js +116 -25
- package/dist/server/src/lib/detection/tools/verified-against.js +74 -5
- package/dist/server/src/lib/detection/tui-detection-frame.js +18 -3
- package/dist/server/src/lib/polling/auto-yes-resolver.js +8 -0
- package/dist/server/src/lib/prompt-answer-sender.js +255 -1
- package/dist/server/src/lib/realtime-snippet.js +53 -0
- package/dist/server/src/lib/session/claude-session.js +19 -2
- package/dist/server/src/lib/session/current-output-builder.js +4 -1
- package/dist/server/src/lib/session/status-mapping.js +58 -8
- package/dist/server/src/lib/tmux/key-sequence.js +27 -1
- package/dist/server/src/lib/tmux/tmux-control-client.js +26 -3
- package/dist/server/src/lib/tmux/tmux.js +64 -3
- package/dist/server/src/types/direct-input.js +113 -0
- package/dist/server/src/types/sidebar.js +67 -7
- package/dist/server/src/types/terminal-keys.js +33 -1
- package/dist/types/terminal-keys.d.ts +28 -1
- package/dist/types/terminal-keys.d.ts.map +1 -1
- package/dist/types/terminal-keys.js +33 -1
- package/package.json +1 -1
- package/release-notes/0.40.0.json +69 -0
- package/.next/server/chunks/6092.js +0 -14
- package/.next/static/chunks/4768-0ad5eb716bed5de9.js +0 -1
- package/.next/static/chunks/8606-e893c1dab6fb81bc.js +0 -1
- package/.next/static/chunks/9619-7bc0e9524f0773b5.js +0 -1
- package/.next/static/chunks/982-edf98d9d54c5ce9b.js +0 -1
- package/.next/static/chunks/app/api/app/update/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/auth/login/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/auth/logout/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/auth/status/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/capabilities/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/daily-summary/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/daily-summary/status/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/external-apps/[id]/health/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/external-apps/[id]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/external-apps/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/fs/browse/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/fs/recent-paths/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/hooks/agent-event/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/hooks/claude-done/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/hooks/permission-request/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/metrics/vibe/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/ollama/models/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/push/escalation/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/push/subscriptions/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/push/vapid/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/relays/[relayId]/cancel/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/relays/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/remote/pair/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/[id]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/clone/[jobId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/clone/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/excluded/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/restore/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/scan/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/sync/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/repositories/validate-path/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/settings/default-agents/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/settings/default-surface-mode/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/sidebar/group-order/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/skills/[id]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/skills/installations/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/skills/operations/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/skills/reindex/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/skills/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/slash-commands/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/tasks/[taskId]/cancel/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/tasks/[taskId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/templates/[id]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/templates/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/verification/runs/[runId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/verification/runs/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/auto-yes/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/capture/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/clear-composer/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/cli-reference/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/cli-tool/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/cmate/schedules/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/current-output/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/env/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/execution-logs/[logId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/execution-logs/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/files/[...path]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/branch/create/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/branch/delete/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/branches/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/checkout/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/commit/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/diff/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/fetch/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/log/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/pull/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/push/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/reset/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/revert/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/show/[commitHash]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/stage/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/staged/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/[index]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/apply/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/pop/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/push/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/stash/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/status/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/unstage/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/git/working-diff/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/instances/notes/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/instances/opencode/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/interrupt/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/kill-session/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/logs/[filename]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/logs/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/marp-render/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/memos/[memoId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/memos/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/messages/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/opencode/diff/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/opencode/session/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/opencode/share/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/prompt-response/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/resolve-target/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/respond/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/schedules/[scheduleId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/schedules/active/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/schedules/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/search/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/send/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/install/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/plan/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/uninstall/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/uninstall-plan/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/update/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/[skillId]/update-plan/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/skills/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/slash-commands/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/special-keys/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/tasks/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/terminal/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/timers/history/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/timers/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/todos/[todoId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/todos/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/tree/[...path]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/tree/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/upload/[...path]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/verify/config/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/verify/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/verify/runs/[runId]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/verify/runs/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/[id]/viewed/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/apply-default-agents/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/api/worktrees/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/layout-542d075e9d7cc541.js +0 -1
- package/.next/static/chunks/app/manifest.webmanifest/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/proxy/[...path]/route-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/review/page-8ed49e2edcc7667b.js +0 -1
- package/.next/static/chunks/app/sessions/page-56f6a2466dd0479d.js +0 -1
- package/.next/static/chunks/app/worktrees/[id]/layout-70779af8b4c8259a.js +0 -1
- package/.next/static/chunks/app/worktrees/[id]/page-760408096ad697b4.js +0 -1
- package/.next/static/css/b4aaf81d10efdd00.css +0 -1
- /package/.next/static/{7Ge9-hsqlip_Z6bhEnVkd → o3mZdwNhCks6IlcAOPinc}/_buildManifest.js +0 -0
- /package/.next/static/{7Ge9-hsqlip_Z6bhEnVkd → o3mZdwNhCks6IlcAOPinc}/_ssgManifest.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7177],{13673:()=>{},25772:(e,t,r)=>{"use strict";r.d(t,{AppProviders:()=>E});var n=r(95155),s=r(3809),a=r(5379),o=r(32916),i=r(65380),l=r(22592),c=r(92614),d=r(70628),u=r(66966),m=r(89275),f=r(60199),h=r(36402),x=r(63470),b=r(40823),p=r(58165),g=r(94442),v=r(72604),y=r(95275),w=r(79832),j=r(12115),N=r(18955),k=r(89559),C=r(59854),M=r(77016);function S(){let e=(0,N.c)("pwa"),[t,r]=(0,j.useState)(null),s=(0,j.useRef)(!1),a=(0,M.W)();return((0,j.useEffect)(()=>{if("undefined"==typeof navigator||!("serviceWorker"in navigator))return;let e=!1,t=t=>{e||r(t)};navigator.serviceWorker.register("/sw.js").then(e=>{e.waiting&&navigator.serviceWorker.controller&&t(e.waiting),e.addEventListener("updatefound",()=>{let r=e.installing;r&&r.addEventListener("statechange",()=>{"installed"===r.state&&navigator.serviceWorker.controller&&t(r)})})}).catch(()=>{});let n=()=>{s.current||(s.current=!0,window.location.reload())};return navigator.serviceWorker.addEventListener("controllerchange",n),()=>{e=!0,navigator.serviceWorker.removeEventListener("controllerchange",n)}},[]),!t||a)?null:(0,n.jsx)("div",{"data-testid":"pwa-update-toast",role:"status","aria-live":"polite",className:"pointer-events-none fixed bottom-0 right-0 flex max-w-full justify-end px-4 pb-safe",style:{zIndex:C.M.TOAST},children:(0,n.jsxs)("div",{"data-testid":"pwa-update-toast-card",className:"pointer-events-auto mb-4 flex items-center gap-3 rounded-lg border border-border bg-surface px-4 py-3 shadow-lg",children:[(0,n.jsx)("span",{className:"text-sm font-medium text-foreground",children:e("update.available")}),(0,n.jsxs)("button",{type:"button",onClick:()=>{t.postMessage({type:"SKIP_WAITING"})},className:"inline-flex items-center gap-1.5 rounded-md bg-accent-600 px-3 py-1.5 text-sm font-medium text-white transition-colors hover:bg-accent-700 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 ring-offset-background dark:bg-accent-500 dark:hover:bg-accent-600",children:[(0,n.jsx)(k.A,{className:"h-4 w-4"}),e("update.reload")]})]})})}function E(e){let{children:t,locale:r,messages:j,timeZone:N,authEnabled:k=!1}=e;return(0,n.jsx)(s.default,{locale:r,messages:j,timeZone:N,children:(0,n.jsx)(g.tE,{children:(0,n.jsx)(a.N,{attribute:"class",defaultTheme:"system",enableSystem:!0,children:(0,n.jsx)(i.O,{authEnabled:k,children:(0,n.jsx)(l.W5,{children:(0,n.jsx)(o.GB,{children:(0,n.jsx)(f.tS,{children:(0,n.jsxs)(u.g7,{children:[(0,n.jsx)(v.rM,{}),(0,n.jsx)(w.o,{}),(0,n.jsx)(y.H,{}),(0,n.jsx)(c.E,{children:(0,n.jsx)(d.S,{children:(0,n.jsx)(h.aF,{children:(0,n.jsx)(x.y2,{children:(0,n.jsxs)(b.NS,{children:[(0,n.jsx)(m.Bo,{children:t}),(0,n.jsx)(S,{}),(0,n.jsx)(p.gZ,{})]})})})})})]})})})})})})})})}},38218:(e,t,r)=>{"use strict";r.d(t,{D:()=>a,a:()=>o});var n=r(12115);let s=n.useLayoutEffect,a=768;function o(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{breakpoint:t=a}=e,[r,o]=(0,n.useState)(!1);return s(()=>{let e=window.matchMedia("(max-width: ".concat(t-1,"px)"));o(e.matches);let r=e=>{o(e.matches)};return e.addEventListener("change",r),()=>{e.removeEventListener("change",r)}},[t]),r}},62295:(e,t,r)=>{"use strict";r.d(t,{AppShellGate:()=>to});var n=r(95155),s=r(20063),a=r(12115),o=r(32916),i=r(38218);let l={showSidebar:!0,showGlobalNav:!0,showLocalNav:!1,autoCollapseSidebar:!1},c=[{prefix:"/worktrees/",config:{showGlobalNav:!1,showLocalNav:!0}},{prefix:"/sessions",config:{autoCollapseSidebar:!0}}];var d=r(22592),u=r(52619),m=r.n(u),f=r(89275);let h=(0,a.forwardRef)(function(e,t){let{href:r,onClick:a,target:o,...i}=e,l=(0,s.usePathname)(),c=(0,f.Hq)();return(0,n.jsx)(m(),{ref:t,href:r,target:o,onClick:e=>{var t;null==a||a(e),e.defaultPrevented||0!==(t=e).button||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||void 0!==o&&"_self"!==o||/^([a-z][a-z0-9+.-]*:)?\/\//i.test(r)||/^(mailto:|tel:)/i.test(r)||(e.preventDefault(),r!==l&&c.push(r))},...i})});var x=r(18955),b=r(85710),p=r(66685),g=r(61362),v=r(15870),y=r(17787),w=r(49027),j=r(27587),N=r(39649),k=r(47650),C=r(38606),M=r(76471);function S(e,t,r){let n=r-8-t;return n<=8?8:Math.min(Math.max(e,8),n)}function E(e){let{id:t,branch:r,isVisible:s,anchorRef:o,nextActionLabel:i,unclassified:l}=e,[c,d]=(0,a.useState)({top:-9999,left:-9999}),u=(0,a.useRef)(null);if((0,a.useEffect)(()=>{var e,t,r;if(!s||!o.current)return;let n=o.current.getBoundingClientRect(),a=null==(e=u.current)?void 0:e.getBoundingClientRect(),i=null!=(t=null==a?void 0:a.width)?t:0,l=null!=(r=null==a?void 0:a.height)?r:0,c=window.innerWidth,m=window.innerHeight,f=n.right+8;if(f+i>c-8){let e=n.left-8-i;e>=8&&(f=e)}d({top:S(n.top,l,m),left:S(f,i,c)})},[s,o]),"undefined"==typeof document||!s)return null;let m=Math.min(384,Math.max(0,window.innerWidth-16));return k.createPortal((0,n.jsxs)("div",{ref:u,id:t,role:"tooltip",className:" fixed z-[9999] px-3 py-2 rounded-md shadow-lg bg-sidebar text-xs text-sidebar-foreground border border-sidebar-border pointer-events-none max-w-sm transition-opacity duration-150 ",style:{top:c.top,left:c.left,maxWidth:m},children:[(0,n.jsx)("p",{className:"font-medium text-sidebar-foreground whitespace-nowrap",children:r.name}),(0,n.jsx)("p",{className:"text-sidebar-muted whitespace-nowrap",children:r.repositoryName}),(0,n.jsxs)("p",{className:"text-sidebar-muted whitespace-nowrap",children:["Status: ",l?C.pu:r.status]}),r.worktreePath&&(0,n.jsx)("p",{className:"text-sidebar-muted truncate",children:r.worktreePath}),i&&(0,n.jsxs)("p",{className:"text-sidebar-muted whitespace-nowrap",children:["Next: ",i]}),r.description&&(0,n.jsx)("p",{className:"text-sidebar-muted mt-1 border-t border-sidebar-border pt-1 whitespace-pre-wrap break-words",children:r.description})]}),document.body)}let A=0,L=(0,a.memo)(function(e){let{branch:t,isSelected:r,onClick:s,showRepositoryName:o=!0}=e,i=(0,x.c)("common"),l=(0,x.c)("worktree"),c="tooltip-".concat(t.id),d=(0,a.useRef)(null),[u,m]=(0,a.useState)(!1),f=(0,a.useRef)(null),h=(0,a.useCallback)(()=>{null!==f.current&&(clearTimeout(f.current),f.current=null)},[]);(0,a.useEffect)(()=>()=>h(),[h]);let b=(0,C.A7)(t.cliStatus),p="waiting"===b,g=!0===t.awaitingInstruction,v=t.nextActionKey?l(t.nextActionKey):null,y=(0,a.useMemo)(()=>{var e;return new Set(null!=(e=t.exitedInstanceIds)?e:[])},[t.exitedInstanceIds]),w=(0,a.useMemo)(()=>{var e;return new Set(null!=(e=t.unclassifiedInstanceIds)?e:[])},[t.unclassifiedInstanceIds]),j=(0,C.Pn)(t.cliStatus,t.unclassifiedInstanceIds),N=(p||g)&&null!==v,k=u&&!r;return(0,a.useEffect)(()=>{r&&m(!1)},[r]),(0,a.useEffect)(()=>{if(!u)return;let e=()=>m(!1);return document.addEventListener("click",e),()=>document.removeEventListener("click",e)},[u]),(0,n.jsxs)("button",{ref:d,"data-testid":"branch-list-item",onClick:()=>{h(),A=Date.now()+400,m(!1),s()},onMouseEnter:()=>{h(),Date.now()>=A&&(f.current=setTimeout(()=>{m(!0)},150))},onMouseLeave:()=>{h(),m(!1)},onFocus:e=>{h(),e.target.matches(":focus-visible")&&(f.current=setTimeout(()=>{m(!0)},150))},onBlur:()=>{h(),m(!1)},"aria-current":r?"true":void 0,"aria-describedby":k?c:void 0,"aria-label":o?void 0:"".concat(t.name," - ").concat(t.repositoryName),className:"\n group relative w-full px-4 py-3 flex flex-col gap-1\n hover:bg-sidebar-hover transition-colors\n focus:outline-none focus:ring-2 focus:ring-inset focus:ring-ring\n ".concat(r?"bg-sidebar-hover border-l-2 border-accent-500":"border-l-2 border-transparent","\n "),children:[(0,n.jsxs)("div",{className:"flex items-center gap-3 w-full",children:[t.cliStatus&&Object.keys(t.cliStatus).length>0&&(0,n.jsx)("div",{className:"flex items-center justify-center flex-shrink-0 w-4","aria-label":i("branchItem.cliToolStatus"),children:(0,n.jsx)(M.Ej,{status:b,label:(0,C.dw)(t.cliStatus,t.cliStatusLabels,y.size>0?e=>y.has(e)?i("branchItem.agentExited"):null:void 0,w),waitingKind:t.waitingKind,unclassified:j})}),(0,n.jsxs)("div",{className:"flex-1 min-w-0 text-left",children:[(0,n.jsx)("p",{className:"text-sm font-medium text-sidebar-foreground truncate",children:t.name}),o&&(0,n.jsx)("p",{className:"text-xs text-sidebar-muted truncate",children:t.repositoryName}),N&&(0,n.jsx)("p",{"data-testid":"branch-next-action",className:"text-xs font-medium truncate ".concat(p?"text-warning-foreground":"text-success-foreground"),children:v})]}),g&&(0,n.jsx)("span",{"data-testid":"awaiting-instruction-badge",className:"flex-shrink-0 rounded-full bg-success-subtle px-1.5 py-0.5 text-[10px] font-medium leading-4 text-success-foreground",title:l("awaitingInstruction.label"),children:l("awaitingInstruction.badge")}),t.hasUnread&&(0,n.jsx)("span",{"data-testid":"unread-indicator",className:"w-2 h-2 rounded-full bg-accent-500 flex-shrink-0","aria-label":i("branchItem.hasUnread")})]}),t.description&&(0,n.jsx)("div",{"data-testid":"branch-description",className:"pl-6 pr-2 mt-1 text-left",children:(0,n.jsx)("p",{className:"text-xs text-sidebar-muted line-clamp-2",children:t.description})}),(0,n.jsx)(E,{id:c,branch:t,isVisible:k,anchorRef:d,nextActionLabel:v,unclassified:j})]})});var K=r(24033),T=r(41898);function I(e,t,r){if(t<=0||r<=0)return 0;let n=e+t+8-r;return n>0?-Math.min(n,Math.max(0,e-8)):e<8?8-e:0}let R=(0,a.memo)(function(e){var t,r;let{sortKey:s,sortDirection:o,onSortKeyChange:i,onSortDirectionChange:l,options:c,defaultDirections:d,compact:u,showLabel:m=!1,directionLabels:f,tooltip:h,iconClassName:b="w-3 h-3"}=e,p=(0,x.c)("common"),[g,v]=(0,a.useState)(!1),y=(0,a.useRef)(null),w=(0,a.useRef)(null),j=(0,a.useRef)({x:0,y:0}),[N,k]=(0,a.useState)({x:0,y:0});(0,a.useEffect)(()=>{function e(e){y.current&&!y.current.contains(e.target)&&v(!1)}if(g)return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[g]),(0,a.useEffect)(()=>{function e(e){"Escape"===e.key&&v(!1)}if(g)return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[g]),(0,a.useLayoutEffect)(()=>{let e=e=>{j.current=e,k(t=>t.x===e.x&&t.y===e.y?t:e)};if(!g)return void e({x:0,y:0});let t=w.current;if(!t)return;let r=t.getBoundingClientRect();e({x:I(r.left-j.current.x,r.width,window.innerWidth),y:I(r.top-j.current.y,r.height,window.innerHeight)})},[g]);let C=(0,a.useCallback)(()=>{v(e=>!e)},[]),M=(0,a.useCallback)(e=>{if(e===s)l("asc"===o?"desc":"asc");else{var t;i(e),l(null!=(t=null==d?void 0:d[e])?t:"asc")}v(!1)},[s,o,i,l,d]),S=(0,a.useCallback)(()=>{l("asc"===o?"desc":"asc")},[o,l]),E=(null==(t=c.find(e=>e.key===s))?void 0:t.label)||p("sort.label"),A=null==f||null==(r=f[s])?void 0:r[o],L=p("asc"===o?"sort.ascShort":"sort.descShort"),R=(0,n.jsx)("button",{type:"button",onClick:C,"aria-expanded":g,"aria-haspopup":"listbox","aria-label":p("sort.sortBy",{label:E}),className:m?"flex min-w-0 max-w-full items-center gap-1 rounded border border-sidebar-border px-2 py-1 text-xs text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring transition-colors":"flex items-center gap-1 px-2 py-1 rounded text-xs text-sidebar-muted hover:text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring transition-colors",children:m?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{className:"min-w-0 truncate",children:E}),(0,n.jsx)(K.A,{className:"h-3 w-3 flex-shrink-0","aria-hidden":"true"})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(W,{className:b}),(0,n.jsx)("span",{className:u?"hidden":"hidden sm:inline",children:E})]})});return(0,n.jsxs)("div",{ref:y,className:m?"relative min-w-0":"relative","data-testid":"sort-selector-base",children:[(0,n.jsxs)("div",{className:m?"flex min-w-0 flex-wrap items-center gap-1":"flex items-center gap-1",children:[h?(0,n.jsx)(T.m_,{content:h,placement:"bottom",children:R}):R,(0,n.jsx)("button",{type:"button",onClick:S,"aria-label":null!=A?A:p("asc"===o?"sort.ascending":"sort.descending"),className:A?"min-w-0 max-w-full truncate rounded px-2 py-1 text-xs text-sidebar-muted hover:text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring transition-colors":"p-1 rounded text-sidebar-muted hover:text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring transition-colors",children:null!=A?A:"asc"===o?(0,n.jsx)(z,{className:b}):(0,n.jsx)(P,{className:b})})]}),g&&(0,n.jsx)("div",{ref:w,role:"listbox","aria-label":p("sort.options"),className:" absolute right-0 top-full mt-1 z-50 min-w-[140px] py-1 rounded-md shadow-lg bg-sidebar border border-sidebar-border ",style:0!==N.x||0!==N.y?{transform:"translate(".concat(N.x,"px, ").concat(N.y,"px)")}:void 0,children:c.map(e=>{var t,r;return(0,n.jsxs)("button",{type:"button",role:"option","aria-selected":s===e.key,onClick:()=>M(e.key),className:"\n w-full px-3 py-2 text-left text-sm whitespace-nowrap\n flex items-center justify-between gap-3\n hover:bg-sidebar-hover transition-colors\n ".concat(s===e.key?"text-accent-700 dark:text-accent-400":"text-sidebar-muted","\n "),children:[(0,n.jsx)("span",{children:e.label}),s===e.key&&(0,n.jsx)("span",{className:"text-xs",children:null!=(r=null==f||null==(t=f[e.key])?void 0:t[o])?r:L})]},e.key)})})]})});function W(e){let{className:t}=e;return(0,n.jsx)("svg",{className:t,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,n.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 4h13M3 8h9m-9 4h6m4 0l4-4m0 0l4 4m-4-4v12"})})}function z(e){let{className:t}=e;return(0,n.jsx)("svg",{className:t,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,n.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 15l7-7 7 7"})})}function P(e){let{className:t}=e;return(0,n.jsx)("svg",{className:t,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,n.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19 9l-7 7-7-7"})})}let B=[{key:"updatedAt",labelKey:"sort.updatedAt"},{key:"repositoryName",labelKey:"sort.repositoryName"},{key:"branchName",labelKey:"sort.branchName"},{key:"status",labelKey:"sort.status"}],D={updatedAt:"desc"},O=(0,a.memo)(function(){let{sortKey:e,sortDirection:t,setSortKey:r,setSortDirection:s}=(0,o.VF)(),i=(0,x.c)("common"),l=(0,a.useMemo)(()=>B.map(e=>{let{key:t,labelKey:r}=e;return{key:t,label:i(r)}}),[i]),c=(0,a.useMemo)(()=>({updatedAt:{asc:i("sort.direction.oldestFirst"),desc:i("sort.direction.newestFirst")},repositoryName:{asc:i("sort.direction.aToZ"),desc:i("sort.direction.zToA")},branchName:{asc:i("sort.direction.aToZ"),desc:i("sort.direction.zToA")},status:{asc:i("sort.direction.attentionFirst"),desc:i("sort.direction.attentionLast")}}),[i]);return(0,n.jsx)(R,{sortKey:e,sortDirection:t,onSortKeyChange:r,onSortDirectionChange:s,options:l,defaultDirections:D,showLabel:!0,directionLabels:c,iconClassName:"w-4 h-4"})});var F=r(48407),H=r(30061),V=r(45195),_=r(26020);function q(){let{currentLocale:e,switchLocale:t}=(0,V.g)(),r=(0,x.c)("common");return(0,n.jsx)("select",{value:e,onChange:e=>t(e.target.value),"data-testid":"locale-switcher","aria-label":r("language"),className:" w-full px-3 py-2 rounded-md bg-sidebar text-sidebar-foreground border border-sidebar-border focus:outline-none focus:ring-2 focus:ring-ring focus:border-transparent text-sm ",children:_.dI.map(e=>(0,n.jsx)("option",{value:e,children:_.vK[e]},e))})}var G=r(5379),J=r(59427),U=r(37494);function $(){let{theme:e,setTheme:t}=(0,G.D)(),[r,s]=(0,a.useState)(!1);if((0,a.useEffect)(()=>{s(!0)},[]),!r)return(0,n.jsx)("div",{"data-testid":"theme-toggle-placeholder",className:"w-8 h-8","aria-hidden":"true"});let o="dark"===e;return(0,n.jsx)("button",{"data-testid":"theme-toggle",onClick:()=>t(o?"light":"dark"),className:"p-1.5 rounded-md text-muted-foreground hover:text-foreground hover:bg-muted transition-colors focus:outline-none focus:ring-2 focus:ring-ring","aria-label":o?"Switch to light mode":"Switch to dark mode",title:o?"Switch to light mode":"Switch to dark mode",children:o?(0,n.jsx)(J.A,{className:"w-5 h-5","data-testid":"theme-icon-sun"}):(0,n.jsx)(U.A,{className:"w-5 h-5","data-testid":"theme-icon-moon"})})}var X=r(65380);function Y(){let e=(0,x.c)("auth"),t=(0,X.H)(),[r,s]=(0,a.useState)(!1);if(!t)return null;async function o(){s(!0);try{await fetch("/api/auth/logout",{method:"POST"}),window.location.href="/login"}catch(e){window.location.href="/login"}}return(0,n.jsx)("button",{type:"button",onClick:o,disabled:r,"data-testid":"logout-button",className:" w-full px-3 py-2 text-sm text-left rounded-md text-muted-foreground hover:text-foreground hover:bg-muted focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50 transition-colors ",children:r?"...":e("logout.button")})}var Z=r(94442),Q=r(44308),ee=r(24373),et=r(40823),er=r(80344),en=r(7636);function es(e){let{items:t,sortKey:r,sortDirection:n,viewMode:s,filterText:o}=e,i=(0,a.useMemo)(()=>{if(!o)return t;let e=o.toLowerCase();return t.filter(t=>t.name.toLowerCase().includes(e)||t.repositoryName.toLowerCase().includes(e))},[t,o]);return{sortedItems:(0,a.useMemo)(()=>(0,en.Xn)(i,r,n),[i,r,n]),groupedItems:(0,a.useMemo)(()=>"grouped"===s?(0,en._s)(i,r,n):[],[i,r,n,s])}}let ea="mcbd-sidebar-group-collapsed",eo="mcbd-sidebar-scroll-top",ei=0,el=(0,a.memo)(function(){var e,t,r;let i=(0,f.Hq)(),{worktrees:l,repositories:c,selectedWorktreeId:d,selectWorktree:u,refreshWorktrees:m,isLoading:h,error:v}=(0,N.$f)(),{closeMobileDrawer:j,sortKey:k,sortDirection:M,viewMode:S,setViewMode:E,repositoryOrder:A,setRepositoryOrder:K}=(0,o.VF)(),T=(0,x.c)("common"),I=null!=(e=(0,s.usePathname)())?e:"",{count:R}=(0,ee.Lv)(),[W,z]=(0,a.useState)(""),P=(0,a.useRef)(null),[B,D]=(0,a.useState)(()=>{try{let e=localStorage.getItem(ea);return e?function(e){try{let t=JSON.parse(e);if("object"!=typeof t||null===t||Array.isArray(t))return{};let r={},n=0;for(let[e,s]of Object.entries(t))if(!eu.has(e)&&"boolean"==typeof s){if(++n>100)break;r[e]=s}return r}catch(e){return{}}}(e):{}}catch(e){return{}}}),H=(0,a.useRef)(!1);(0,a.useEffect)(()=>{H.current||(H.current=!0,fetch("/api/sidebar/group-order").then(e=>e.json()).then(e=>{e.success&&Array.isArray(e.order)&&K(e.order)}).catch(()=>{}))},[K]);let V=(0,a.useMemo)(()=>(0,en.UZ)(c),[c]),_=(0,a.useMemo)(()=>(0,en.s6)(l,V),[l,V]),G=(0,a.useMemo)(()=>_.map(C.XK),[_]),J=(0,a.useDeferredValue)(G),U=(0,a.useRef)(null),X=(0,a.useRef)(null),[Z,et]=(0,a.useState)(0);(0,a.useEffect)(()=>()=>{null!==X.current&&clearTimeout(X.current)},[]);let er=(0,a.useCallback)(()=>{null!==X.current&&(clearTimeout(X.current),X.current=null),U.current=null},[]),el=(0,a.useMemo)(()=>{let e=U.current;return!e||0===e.items.length||Date.now()>=e.expiresAt?J:e.items},[J,Z]),em=(0,a.useRef)(el);(0,a.useLayoutEffect)(()=>{em.current=el;let e=U.current;e&&0===e.items.length&&J.length>0&&er()});let eb=(0,a.useCallback)(()=>{if(0===em.current.length)return;null!==X.current&&(clearTimeout(X.current),X.current=null);let e=U.current;if(e&&Date.now()<e.expiresAt){U.current={...e,expiresAt:1/0};return}U.current={items:em.current,expiresAt:1/0}},[]),ep=(0,a.useCallback)(()=>{U.current&&(U.current={...U.current,expiresAt:Date.now()+1e3},null!==X.current&&clearTimeout(X.current),X.current=setTimeout(()=>{er(),et(e=>e+1)},1e3))},[er]),{sortedItems:eg,groupedItems:ew}=es({items:el,sortKey:k,sortDirection:M,viewMode:S,filterText:W}),ej=(0,a.useMemo)(()=>"grouped"===S&&ew?W.trim()?ew:(0,en.BN)(ew,A):null,[S,ew,A,W]),eN="grouped"===S?ej:null,ek=(0,a.useMemo)(()=>"sessions"===S?(0,en.EY)((0,en.UB)(eg),k,M):[],[S,eg,k,M]);(0,a.useEffect)(()=>{try{localStorage.setItem(ea,JSON.stringify(B))}catch(e){}},[B]);let eC=(0,a.useCallback)(e=>{D(t=>({...t,[e]:!t[e]}))},[]),eM=(0,a.useCallback)(()=>{var e,t,r=null!=(t=null==(e=P.current)?void 0:e.scrollTop)?t:0;let n=Number.isFinite(r)&&r>0?r:0;ei=n;try{localStorage.setItem(eo,String(n))}catch(e){}},[]),eS=eg.length>0||(null!=(t=null==eN?void 0:eN.length)?t:0)>0||ek.length>0;(0,a.useEffect)(()=>{let e=P.current;if(!e)return;let t=window.requestAnimationFrame(()=>{e.scrollTop=function(){try{let e=localStorage.getItem(eo);if(!e)return ei=0,0;let t=Number(e);Number.isFinite(t)&&t>=0&&(ei=t)}catch(e){}return ei}()});return()=>{window.cancelAnimationFrame(t)}},[eS,S]);let eE=(0,a.useCallback)(e=>{eM(),u(e),i.push("/worktrees/".concat(e)),j()},[eM,u,i,j]),eA=(0,a.useCallback)(e=>{eM(),u(e.worktreeId),i.push((0,en.Ii)(e)),j()},[eM,u,i,j]),eL=(0,y.FR)((0,y.MS)(y.AN,{activationConstraint:{distance:8}})),eK=(0,a.useCallback)(e=>{let{active:t,over:r}=e;if(!r||t.id===r.id||!eN)return;let n=eN.map(e=>e.repositoryName),s=n.indexOf(String(t.id)),a=n.indexOf(String(r.id));if(-1===s||-1===a)return;let o=(0,w.be)(n,s,a);K(o),fetch("/api/sidebar/group-order",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({order:o})}).catch(()=>{K(n)})},[eN,K]),eT="grouped"===S?(null!=(r=null==eN?void 0:eN.length)?r:0)===0:"sessions"===S?0===ek.length:0===eg.length,eI=h&&0===l.length,eR=!eI&&!!v&&0===l.length,eW=(0,a.useCallback)(()=>{m()},[m]);return(0,n.jsxs)("nav",{"data-testid":"sidebar","aria-label":T("sidebar.branchNavigation"),className:"h-full flex flex-col bg-sidebar text-sidebar-foreground",role:"navigation",children:[(0,n.jsxs)("div",{"data-testid":"sidebar-header",className:"flex-shrink-0 space-y-2 border-b border-sidebar-border px-2 py-2",children:[(0,n.jsxs)("ul",{"data-testid":"sidebar-nav",className:"space-y-0.5",children:[(0,n.jsxs)("li",{className:"flex min-w-0 items-center gap-1",children:[(0,n.jsx)(ef,{href:"/repositories",icon:b.A,label:T("nav.repositories"),testId:"sidebar-nav-repositories",isActive:I.startsWith("/repositories"),onNavigate:j}),(0,n.jsx)(ev,{refreshWorktrees:m})]}),(0,n.jsx)("li",{className:"flex min-w-0",children:(0,n.jsx)(ef,{href:"/sessions",icon:p.A,label:T("nav.sessions"),testId:"sidebar-nav-sessions",isActive:I.startsWith("/sessions"),onNavigate:j})}),(0,n.jsx)("li",{className:"flex min-w-0",children:(0,n.jsx)(ef,{href:R>0?Q.ks:"/review",icon:g.A,label:T("nav.review"),testId:"sidebar-nav-review",isActive:I.startsWith("/review"),onNavigate:j,trailing:R>0?(0,n.jsx)("span",{"data-testid":"sidebar-nav-review-count",role:"status","aria-label":T("attention.badgeLabel",{count:R}),className:"flex-shrink-0 rounded-full bg-warning-subtle px-1.5 text-xs font-semibold leading-5 tabular-nums text-warning-foreground",children:R>99?"99+":R}):null})})]}),(0,n.jsxs)("div",{"data-testid":"sidebar-list-controls",className:"grid grid-cols-[auto_minmax(0,1fr)] items-center gap-x-2 gap-y-1.5 px-2",children:[(0,n.jsx)(eh,{viewMode:S,onChange:E}),(0,n.jsx)("span",{className:"whitespace-nowrap text-xs text-sidebar-muted",children:T("sort.label")}),(0,n.jsx)(O,{})]})]}),(0,n.jsx)("div",{className:"flex-shrink-0 px-4 py-3 border-b border-sidebar-border",children:(0,n.jsx)(F.pd,{type:"text",placeholder:T("sidebar.searchBranches"),value:W,onChange:e=>z(e.target.value),className:"bg-background shadow-none"})}),(0,n.jsx)("div",{ref:P,"data-testid":"branch-list",onScroll:eM,onMouseEnter:eb,onMouseLeave:ep,className:"flex-1 overflow-y-auto overflow-x-hidden",children:eI?(0,n.jsx)(ec,{label:T("sidebar.loadingBranches")}):eR?(0,n.jsxs)("div",{"data-testid":"branch-list-error",role:"alert",className:"px-4 py-8 text-center text-sidebar-muted",children:[(0,n.jsx)("p",{className:"text-sm",children:T("sidebar.branchesLoadFailed")}),(0,n.jsx)(F.$n,{type:"button",variant:"secondary",size:"sm",className:"mt-3","data-testid":"branch-list-retry",onClick:eW,children:T("sidebar.retryLoadBranches")})]}):eT?(0,n.jsx)("div",{className:"px-4 py-8 text-center text-sidebar-muted",children:T(W?"sidebar.noBranchesFound":"sidebar.noBranchesAvailable")}):"sessions"===S?ek.map(e=>(0,n.jsx)(ex,{row:e,isSelected:e.worktreeId===d,onClick:eA},e.key)):"grouped"===S&&eN?(0,n.jsx)(y.Mp,{sensors:eL,collisionDetection:y.fp,onDragEnd:eK,children:(0,n.jsx)(w.gB,{items:eN.map(e=>e.repositoryName),strategy:w._G,children:eN.map(e=>{let t=!B[e.repositoryName]||!!W.trim();return(0,n.jsx)(ed,{group:e,isExpanded:t,selectedWorktreeId:d,onToggle:()=>eC(e.repositoryName),onBranchClick:eE,isDragDisabled:!!W.trim()},e.repositoryName)})})}):eg.map(e=>(0,n.jsx)(L,{branch:e,isSelected:e.id===d,onClick:()=>eE(e.id)},e.id))}),(0,n.jsxs)("div",{className:"flex-shrink-0 px-4 py-3 border-t border-sidebar-border space-y-2",children:[(0,n.jsxs)("div",{className:"flex items-center gap-2",children:[(0,n.jsx)(ey,{onNavigate:j}),(0,n.jsx)("div",{className:"flex-1 min-w-0",children:(0,n.jsx)(q,{})}),(0,n.jsx)($,{})]}),(0,n.jsx)(Y,{})]})]})}),ec=(0,a.memo)(function(e){let{label:t}=e;return(0,n.jsxs)("div",{"data-testid":"branch-list-skeleton",role:"status","aria-live":"polite",className:"px-4 py-3 space-y-3",children:[(0,n.jsx)("span",{className:"sr-only",children:t}),[0,1,2,3,4].map(e=>(0,n.jsxs)("div",{className:"flex items-center gap-2",children:[(0,n.jsx)(F.EA,{className:"h-2 w-2 rounded-full"}),(0,n.jsx)(F.EA,{className:"h-3 flex-1"})]},e))]})});function ed(e){let{group:t,isExpanded:r,selectedWorktreeId:s,onToggle:a,onBranchClick:o,isDragDisabled:i}=e,{attributes:l,listeners:c,setNodeRef:d,setActivatorNodeRef:u,transform:m,transition:f,isDragging:h}=(0,w.gl)({id:t.repositoryName,disabled:i}),x={transform:j.Ks.Transform.toString(m),transition:f,opacity:h?.5:1};return(0,n.jsxs)("div",{ref:d,style:x,className:"w-full min-w-0",children:[(0,n.jsx)(em,{repositoryName:t.repositoryName,branchCount:t.branches.length,isExpanded:r,onClick:a,dragHandleRef:u,dragHandleListeners:i?void 0:c,dragHandleAttributes:i?void 0:l}),r&&t.branches.map(e=>(0,n.jsx)(L,{branch:e,isSelected:e.id===s,onClick:()=>o(e.id),showRepositoryName:!1},e.id))]})}let eu=new Set(["__proto__","constructor","prototype"]);function em(e){let{repositoryName:t,branchCount:r,isExpanded:s,onClick:a,dragHandleRef:o,dragHandleListeners:i,dragHandleAttributes:l}=e,c=(0,x.c)("common");return(0,n.jsxs)("div",{className:"flex items-center w-full",children:[i&&(0,n.jsx)("div",{ref:o,...i,...l,"aria-label":c("sidebar.dragToReorderGroup"),className:" flex-shrink-0 flex items-center justify-center w-6 h-full pl-2 cursor-grab active:cursor-grabbing text-sidebar-muted hover:text-sidebar-foreground transition-colors ",children:(0,n.jsx)(ep,{})}),(0,n.jsxs)("button",{"data-testid":"group-header",type:"button",onClick:a,"aria-expanded":s,className:" flex-1 min-w-0 flex items-center gap-2 px-2 py-2 text-xs font-semibold text-sidebar-muted uppercase tracking-wider focus:outline-none focus:ring-2 focus:ring-inset focus:ring-ring transition-colors ",children:[(0,n.jsx)(eb,{isExpanded:s}),(0,n.jsx)(F.nF,{color:(0,en.LV)(t)}),(0,n.jsx)(H.nR,{content:t,className:"flex-1 min-w-0 text-left truncate",children:t}),(0,n.jsx)("span",{className:"text-sidebar-muted font-normal tabular-nums pr-2",children:r})]})]})}function ef(e){let{href:t,icon:r,label:s,testId:a,isActive:o,onNavigate:i,trailing:l}=e;return(0,n.jsxs)(h,{href:t,"data-testid":a,"aria-current":o?"page":void 0,onClick:i,className:"flex min-w-0 flex-1 items-center gap-2 rounded-md px-2 py-1.5 text-sm transition-colors hover:bg-sidebar-hover hover:text-sidebar-foreground focus:outline-none focus-visible:ring-2 focus-visible:ring-ring ".concat(o?"bg-sidebar-hover font-medium text-sidebar-foreground":"text-sidebar-muted"),children:[(0,n.jsx)(r,{className:"h-4 w-4 flex-shrink-0","aria-hidden":"true"}),(0,n.jsx)("span",{className:"min-w-0 flex-1 truncate",children:s}),l]})}function eh(e){let{viewMode:t,onChange:r}=e,s=(0,x.c)("common"),o=(0,a.useId)();return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("label",{htmlFor:o,className:"whitespace-nowrap text-xs text-sidebar-muted",children:s("sidebar.viewLabel")}),(0,n.jsxs)("select",{id:o,"data-testid":"view-mode-select",value:t,onChange:e=>{let t=e.target.value;(0,en.$m)(t)&&r(t)},className:"w-full min-w-0 truncate rounded border border-sidebar-border bg-sidebar px-1.5 py-1 text-xs text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring",children:[(0,n.jsx)("option",{value:"grouped",children:s("sidebar.viewMode.grouped")}),(0,n.jsx)("option",{value:"flat",children:s("sidebar.viewMode.flat")}),(0,n.jsx)("option",{value:"sessions",children:s("sidebar.viewMode.sessions")})]})]})}let ex=(0,a.memo)(function(e){let{row:t,isSelected:r,onClick:s}=e,a=(0,x.c)("common"),o=(0,M.Mq)(t.status,t.unclassified),i=a(o?M.rH:"status.".concat(t.status));return(0,n.jsxs)("button",{type:"button","data-testid":"session-list-item","data-session-key":t.key,onClick:()=>s(t),"aria-current":r?"true":void 0,className:"w-full min-w-0 px-4 py-2 flex items-center gap-3 text-left hover:bg-sidebar-hover transition-colors focus:outline-none focus:ring-2 focus:ring-inset focus:ring-ring ".concat(r?"bg-sidebar-hover border-l-2 border-accent-500":"border-l-2 border-transparent"),children:[(0,n.jsx)(F.md,{status:t.status,size:"lg",label:t.exited?"".concat(i," (").concat(a("branchItem.agentExited"),")"):i,className:o?M.Jd:void 0}),(0,n.jsxs)("span",{className:"min-w-0 flex-1",children:[(0,n.jsx)("span",{className:"block truncate text-sm font-semibold text-sidebar-foreground",children:t.label}),(0,n.jsxs)("span",{className:"block truncate text-xs text-sidebar-muted",children:[t.branchName," \xb7 ",t.repositoryName]})]})]})});function eb(e){let{isExpanded:t}=e;return(0,n.jsx)("svg",{className:"w-3 h-3 flex-shrink-0 transition-transform ".concat(t?"rotate-90":""),fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,n.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 5l7 7-7 7"})})}function ep(){return(0,n.jsxs)("svg",{className:"w-3 h-3",fill:"currentColor",viewBox:"0 0 24 24","aria-hidden":"true",children:[(0,n.jsx)("circle",{cx:"9",cy:"5",r:"1.5"}),(0,n.jsx)("circle",{cx:"15",cy:"5",r:"1.5"}),(0,n.jsx)("circle",{cx:"9",cy:"12",r:"1.5"}),(0,n.jsx)("circle",{cx:"15",cy:"12",r:"1.5"}),(0,n.jsx)("circle",{cx:"9",cy:"19",r:"1.5"}),(0,n.jsx)("circle",{cx:"15",cy:"19",r:"1.5"})]})}function eg(e){let{className:t=""}=e;return(0,n.jsx)("svg",{className:"".concat("w-4 h-4"," ").concat(t),fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:(0,n.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 4v5h5M20 20v-5h-5M20.49 9A9 9 0 005.64 5.64L4 4m16 16l-1.64-1.64A9 9 0 014.51 15"})})}let ev=(0,a.memo)(function(e){let{refreshWorktrees:t}=e,[r,s]=(0,a.useState)(!1),o=(0,a.useRef)(!1),{showToast:i}=(0,Z.dj)(),l=(0,x.c)("common"),c=(0,a.useCallback)(async()=>{if(!o.current){o.current=!0,s(!0);try{let e=await er.Rx.sync();await t(),i(l("syncSuccess",{count:e.worktreeCount}),"success",3e3)}catch(e){e instanceof er.hD&&401===e.status?i(l("syncAuthError"),"error",5e3):i(l("syncError"),"error",5e3)}finally{o.current=!1,s(!1)}}},[t,i,l]);return(0,n.jsx)(n.Fragment,{children:(0,n.jsx)(T.m_,{content:l("tooltips.sync"),placement:"bottom",children:(0,n.jsx)("button",{type:"button",onClick:c,disabled:r,"aria-label":l("syncButtonLabel"),className:"p-1 rounded-md text-sidebar-muted hover:text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring disabled:opacity-50 disabled:cursor-not-allowed transition-colors",children:(0,n.jsx)(eg,{className:r?"animate-spin":""})})})})});function ey(e){let{onNavigate:t}=e,r=(0,x.c)("common"),s=(0,i.a)(),{open:o}=(0,et.V0)(),l=r("settings.title"),c=(0,a.useCallback)(e=>{t(),!s&&(0!==e.button||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||(e.preventDefault(),o()))},[s,t,o]);return(0,n.jsx)(T.m_,{content:l,placement:"top",className:"flex-shrink-0",children:(0,n.jsx)(h,{href:"/more","data-testid":"sidebar-settings","aria-label":l,"aria-haspopup":s?void 0:"dialog",onClick:c,className:"p-1.5 rounded-md text-sidebar-muted hover:text-sidebar-foreground hover:bg-sidebar-hover focus:outline-none focus:ring-2 focus:ring-ring transition-colors",children:(0,n.jsx)(v.A,{size:20,"aria-hidden":"true"})})})}var ew=r(59847),ej=r(86651),eN=r(94684),ek=r(34681);function eC(){let e=(0,o.pT)(),t=(0,x.c)("common");if(!e)return null;let{repoTabBarMode:r,setRepoTabBarMode:s}=e;return(0,n.jsxs)("div",{className:"hidden md:flex items-center",children:[(0,n.jsx)("label",{htmlFor:"repo-tab-bar-mode",className:"sr-only",children:t("repoTabBar.settingLabel")}),(0,n.jsx)("select",{id:"repo-tab-bar-mode","data-testid":"repo-tab-bar-mode-select","aria-label":t("repoTabBar.settingLabel"),title:t("repoTabBar.settingLabel"),value:r,onChange:e=>{let t=e.target.value;(0,en.m3)(t)&&s(t)},className:"rounded-md border border-border bg-surface px-2 py-1 text-sm text-muted-foreground transition-colors hover:text-foreground focus:outline-none focus:ring-2 focus:ring-ring",children:en.EN.map(e=>(0,n.jsx)("option",{value:e,children:t("repoTabBar.mode.".concat(e))},e))})]})}var eM=r(52407);function eS(){let{shouldSurface:e,isReconnecting:t}=(0,eM.Fx)(),r=(0,x.c)("common");if(!e)return null;let s=r(t?"connection.reconnecting":"connection.offline");return(0,n.jsxs)("span",{"data-testid":"connection-status-indicator","data-connection-state":t?"reconnecting":"offline",role:"status","aria-live":"polite",title:r(t?"connection.reconnectingTooltip":"connection.offlineTooltip"),className:"hidden sm:inline-flex items-center gap-1.5 rounded-full border border-border bg-surface px-2 py-0.5 text-xs text-muted-foreground",children:[(0,n.jsx)("span",{"aria-hidden":"true",className:["w-1.5 h-1.5 rounded-full",t?"bg-warning motion-safe:animate-pulse":"bg-muted-foreground"].join(" ")}),s]})}var eE=r(72137),eA=r(79651),eL=r(92614);let eK=[{labelKey:"nav.sessions",href:"/sessions",isActive:e=>e.startsWith("/sessions")},{labelKey:"nav.repositoriesShort",href:"/repositories",isActive:e=>e.startsWith("/repositories")},{labelKey:"nav.reviewReport",href:"/review",isActive:e=>e.startsWith("/review")},{labelKey:"nav.more",href:"/more",isActive:e=>e.startsWith("/more"),opensSettings:!0}];function eT(e){let{title:t="CommandMate"}=e,r=(0,s.usePathname)(),o=(0,x.c)("commandPalette"),i=(0,x.c)("common"),{setOpen:l}=(0,eL.C)(),[c,d]=a.useState(null);a.useEffect(()=>{d("undefined"!=typeof navigator&&/Mac|iPhone|iPad|iPod/i.test(navigator.platform||"")?"⌘":"Ctrl")},[]);let{open:u}=(0,et.V0)(),m=a.useCallback(e=>{0!==e.button||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||(e.preventDefault(),u())},[u]);return(0,n.jsx)("header",{className:"sticky top-0 z-50 border-b border-border bg-background supports-[backdrop-filter]:bg-background/80 backdrop-blur-md",children:(0,n.jsx)("div",{className:"container-custom",children:(0,n.jsxs)("div",{className:"flex items-center justify-between h-16",children:[(0,n.jsx)("div",{className:"flex items-center space-x-4",children:(0,n.jsxs)(h,{href:"/",className:"flex items-center space-x-2 hover:opacity-80 transition-opacity",children:[(0,n.jsx)("div",{className:"w-8 h-8 bg-accent-600 rounded-lg flex items-center justify-center",children:(0,n.jsx)(ew.A,{size:20,strokeWidth:2,className:"text-white","aria-hidden":"true"})}),(0,n.jsx)("h1",{className:"text-xl font-bold text-foreground",children:t})]})}),(0,n.jsxs)("nav",{className:"flex items-center space-x-6",role:"navigation",children:[eK.map(e=>{let t=e.isActive(r);return(0,n.jsx)(h,{href:e.href,"aria-current":t?"page":void 0,"aria-haspopup":e.opensSettings?"dialog":void 0,onClick:e.opensSettings?m:void 0,className:"relative py-1 text-sm font-medium transition-colors after:absolute after:inset-x-0 after:bottom-0 after:h-0.5 after:rounded-full after:bg-accent-600 dark:after:bg-accent-400 after:origin-center motion-safe:after:transition-transform after:duration-200 after:ease-[var(--motion-ease-out)] ".concat(t?"text-accent-600 dark:text-accent-400 after:scale-x-100":"text-muted-foreground hover:text-foreground after:scale-x-0"),children:i(e.labelKey)},e.href)}),(0,n.jsxs)("button",{type:"button","data-testid":"header-command-palette-trigger",onClick:()=>l(!0),"aria-label":o("mobileTrigger"),className:"hidden md:inline-flex items-center gap-2 rounded-md border border-border bg-surface px-2.5 py-1.5 text-sm text-muted-foreground hover:bg-surface-2 transition-colors",children:[(0,n.jsx)(ej.A,{size:16,strokeWidth:2,"aria-hidden":"true",className:"shrink-0"}),(0,n.jsx)("span",{children:o("searchAction")}),c&&(0,n.jsxs)("span",{className:"flex items-center gap-0.5",children:[(0,n.jsx)(eA.u,{children:c}),(0,n.jsx)(eA.u,{children:"K"})]})]}),(0,n.jsx)(eS,{}),(0,n.jsx)(ek.g,{}),(0,n.jsx)(eC,{}),(0,n.jsx)(eE.H,{}),(0,n.jsx)($,{}),(0,n.jsxs)("a",{href:"https://github.com/kewton/MyCodeBranchDesk",target:"_blank",rel:"noopener noreferrer",className:"text-sm font-medium text-muted-foreground hover:text-foreground transition-colors flex items-center space-x-1",children:[(0,n.jsx)(eN.A,{size:20,strokeWidth:2,"aria-hidden":"true"}),(0,n.jsx)("span",{children:"GitHub"})]})]})]})})})}var eI=r(37772),eR=r(17848),eW=r(48481),ez=r(46892),eP=r(59854);let eB=/^\/worktrees\/([^/]+)/;function eD(e,t,r){let n=r-8-t;return n<=8?8:Math.min(Math.max(e.left+t>r-8?e.right-t:e.left,8),n)}function eO(e){var t;null==e||null==(t=e.scrollIntoView)||t.call(e,{block:"nearest",inline:"nearest"})}let eF=(0,a.memo)(function(){var e;let t=(0,x.c)("common"),r=(0,s.usePathname)(),i=(0,f.Hq)(),{sortKey:l,sortDirection:c,repositoryOrder:u}=(0,o.VF)(),{worktrees:m,repositories:h,selectedWorktreeId:b,selectWorktree:p}=(0,N.$f)(),{factor:g}=(0,d.Ps)(),v=(0,a.useMemo)(()=>(0,en.UZ)(null!=h?h:[]),[h]),y=(0,a.useMemo)(()=>(0,en.s6)(null!=m?m:[],v),[m,v]),{groupedItems:w}=es({items:(0,a.useMemo)(()=>y.map(C.XK),[y]),sortKey:l,sortDirection:c,viewMode:"grouped"}),j=(0,a.useMemo)(()=>(0,en.BN)(w,u),[w,u]),k=function(e,t){let r=eB.exec(e);if(!r)return t;try{return decodeURIComponent(r[1])}catch(e){return r[1]}}(r,b),M=(0,a.useMemo)(()=>{var e,t;return null!=(t=null==(e=j.find(e=>e.branches.some(e=>e.id===k)))?void 0:e.repositoryName)?t:null},[j,k]),[S,E]=(0,a.useState)(null),[A,L]=(0,a.useState)(null),[K,T]=(0,a.useState)(!1),I=(0,a.useRef)(null),R=(0,a.useRef)(null),W=(0,a.useRef)(new Map),z=(0,a.useCallback)((e,t)=>{t?W.current.set(e,t):W.current.delete(e)},[]),P=(0,a.useCallback)(()=>{E(null),L(null),T(!1)},[]),B=(0,a.useCallback)(e=>{let t=W.current.get(e);if(!t)return;let r=t.getBoundingClientRect();L({left:r.left,right:r.right,bottom:r.bottom}),E(e),T(!1)},[]),D=(0,a.useCallback)(e=>{if(S===e)return void P();B(e)},[S,P,B]),[O,F]=(0,a.useState)(!1),H=(0,a.useCallback)(()=>{let e=I.current;e&&F(e.scrollWidth>e.clientWidth+1)},[]);(0,a.useLayoutEffect)(()=>{H()},[H,j.length,g]),(0,a.useEffect)(()=>{window.addEventListener("resize",H);let e="undefined"!=typeof ResizeObserver?new ResizeObserver(()=>H()):null;return e&&I.current&&e.observe(I.current),()=>{window.removeEventListener("resize",H),null==e||e.disconnect()}},[H]);let V=null!==S||K;(0,a.useEffect)(()=>{if(!V)return;let e=e=>{var t,r,n;let s=e.target;!(!s||(null==(t=I.current)?void 0:t.contains(s))||(null==(r=R.current)?void 0:r.contains(s)))&&((null==(n=s.closest)?void 0:n.call(s,"[data-repository-tab-panel]"))||P())},t=e=>{if("Escape"!==e.key)return;let t=S?W.current.get(S):R.current;P(),null==t||t.focus()};return document.addEventListener("mousedown",e),document.addEventListener("keydown",t),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)}},[V,S,P]),(0,a.useEffect)(()=>{P()},[r,P]),(0,a.useLayoutEffect)(()=>{M&&eO(W.current.get(M))},[M,r,O]);let _=(0,a.useCallback)(e=>{P(),p(e),i.push("/worktrees/".concat(e))},[P,p,i]),q=(0,a.useCallback)(e=>{let t=W.current.get(e);eO(t),B(e),null==t||t.focus()},[B]),G=(0,a.useCallback)(e=>{var t;let r=e.currentTarget,n=(t=r.clientWidth,e.ctrlKey||e.shiftKey||Math.abs(e.deltaY)<=Math.abs(e.deltaX)?0:1===e.deltaMode?40*e.deltaY:2===e.deltaMode?e.deltaY*t:e.deltaY);0!==n&&(r.scrollLeft+=n)},[]);if(0===j.length)return null;let J=Math.round(32*g),U=null!=(e=j.find(e=>e.repositoryName===S))?e:null;return(0,n.jsxs)("div",{"data-testid":"repository-tab-bar",className:"relative flex-shrink-0 flex items-stretch border-b border-border bg-surface",style:{height:"".concat(J,"px")},children:[(0,n.jsx)("nav",{ref:I,"data-testid":"repository-tab-strip","aria-label":t("nav.repositories"),onWheel:G,className:"flex min-w-0 flex-1 flex-nowrap items-stretch overflow-x-auto overflow-y-hidden scrollbar-hide",children:j.map(e=>(0,n.jsx)(eH,{group:e,isActive:e.repositoryName===M,isOpen:e.repositoryName===S,registerTab:z,onToggle:D},e.repositoryName))}),O&&(0,n.jsx)("button",{ref:R,type:"button","data-testid":"repository-tab-overflow","aria-haspopup":"menu","aria-expanded":K,"aria-label":t("repoTabBar.overflow"),title:t("repoTabBar.overflow"),onClick:()=>{E(null),L(null),T(e=>!e)},className:"flex-shrink-0 flex items-center border-l border-border px-2 text-muted-foreground transition-colors hover:bg-surface-2 hover:text-foreground focus:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring",children:(0,n.jsx)(eI.A,{size:16,strokeWidth:2,"aria-hidden":"true"})}),U&&A&&(0,n.jsx)(eV,{group:U,anchor:A,factor:g,activeWorktreeId:k,onBranchClick:_}),K&&(0,n.jsx)(e_,{groups:j,anchorRef:R,activeRepositoryName:M,onSelect:q})]})}),eH=(0,a.memo)(function(e){let{group:t,isActive:r,isOpen:s,registerTab:a,onToggle:o}=e,i=(0,x.c)("common"),l=(0,en.zD)(t.branches),c=(0,M.Mq)(l,(0,en.El)(t.branches)),d=(0,en.j)(t.branches),u=i(c?M.rH:ez.PL[l].labelKey);return(0,n.jsxs)("button",{ref:e=>a(t.repositoryName,e),type:"button","data-testid":"repository-tab","data-repository":t.repositoryName,"aria-haspopup":"menu","aria-expanded":s,"aria-current":r?"true":void 0,title:"".concat(t.repositoryName," — ").concat(u),onClick:()=>o(t.repositoryName),onKeyDown:e=>{"ArrowDown"===e.key&&(e.preventDefault(),s||o(t.repositoryName))},className:"\n group/tab flex-shrink-0 flex max-w-[14rem] items-center gap-1.5 px-2.5\n border-b-2 text-xs font-medium transition-colors\n focus:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring\n ".concat(r?"border-accent-500 bg-surface-2 text-foreground":"border-transparent text-muted-foreground hover:bg-surface-2 hover:text-foreground","\n "),children:[(0,n.jsx)(eR.n,{className:"h-3.5 w-3.5",color:(0,en.LV)(t.repositoryName)}),(0,n.jsx)("span",{className:"min-w-0 truncate",children:t.repositoryName}),(0,n.jsx)(eW.m,{status:l,size:"sm",label:u,className:c?M.Jd:void 0,"data-testid":"repository-tab-status"}),d>0&&(0,n.jsx)("span",{"data-testid":"repository-tab-attention-count","aria-label":i("attention.badgeLabel",{count:d}),className:"flex-shrink-0 rounded-full bg-warning-subtle px-1.5 text-[10px] font-semibold leading-4 tabular-nums text-warning-foreground",children:d})]})});function eV(e){let{group:t,anchor:r,factor:s,activeWorktreeId:o,onBranchClick:i}=e,l=(0,x.c)("common"),c=(0,a.useRef)(null);if((0,a.useEffect)(()=>{var e;let t=null==(e=c.current)?void 0:e.querySelector("button");null==t||t.focus()},[t.repositoryName]),"undefined"==typeof document)return null;let d=Math.round(300*s),u=window.innerWidth;return k.createPortal((0,n.jsx)("div",{ref:c,"data-repository-tab-panel":"","data-testid":"repository-tab-popover","data-repository":t.repositoryName,role:"menu","aria-label":l("sidebar.branchNavigation"),className:"fixed rounded-md border border-sidebar-border bg-sidebar text-sidebar-foreground shadow-lg",style:{top:r.bottom+4,left:eD(r,d,u),width:d,zIndex:eP.M.POPOVER},children:(0,n.jsx)("div",{"data-testid":"repository-tab-popover-list",className:"overflow-y-auto overflow-x-hidden py-1",style:{maxHeight:"".concat(Math.round(520*s),"px")},children:0===t.branches.length?(0,n.jsx)("p",{className:"px-4 py-6 text-center text-sm text-sidebar-muted",children:l("sidebar.noBranchesAvailable")}):t.branches.map(e=>(0,n.jsx)(L,{branch:e,isSelected:e.id===o,onClick:()=>i(e.id),showRepositoryName:!1},e.id))})}),document.body)}function e_(e){var t;let{groups:r,anchorRef:s,activeRepositoryName:a,onSelect:o}=e,i=(0,x.c)("common"),l=null==(t=s.current)?void 0:t.getBoundingClientRect();if("undefined"==typeof document||!l)return null;let c=window.innerWidth;return k.createPortal((0,n.jsx)("div",{"data-repository-tab-panel":"","data-testid":"repository-tab-overflow-menu",role:"menu","aria-label":i("nav.repositories"),className:"fixed rounded-md border border-sidebar-border bg-sidebar text-sidebar-foreground shadow-lg",style:{top:l.bottom+4,left:eD({left:l.left,right:l.right,bottom:l.bottom},300,c),width:300,maxHeight:"".concat(520,"px"),zIndex:eP.M.POPOVER},children:(0,n.jsx)("div",{className:"overflow-y-auto py-1",style:{maxHeight:"inherit"},children:r.map(e=>{let t=(0,en.zD)(e.branches),r=(0,M.Mq)(t,(0,en.El)(e.branches));return(0,n.jsxs)("button",{type:"button",role:"menuitem","data-testid":"repository-tab-overflow-item","data-repository":e.repositoryName,"aria-current":e.repositoryName===a?"true":void 0,onClick:()=>o(e.repositoryName),className:"flex w-full items-center gap-2 px-3 py-2 text-left text-sm transition-colors hover:bg-sidebar-hover focus:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring",children:[(0,n.jsx)(eR.n,{className:"h-3.5 w-3.5",color:(0,en.LV)(e.repositoryName)}),(0,n.jsx)("span",{className:"min-w-0 flex-1 truncate",children:e.repositoryName}),(0,n.jsx)(eW.m,{status:t,size:"sm",label:i(r?M.rH:ez.PL[t].labelKey),className:r?M.Jd:void 0}),(0,n.jsx)("span",{className:"tabular-nums text-xs text-sidebar-muted",children:e.branches.length})]},e.repositoryName)})})}),document.body)}var eq=r(9540);function eG(e){let{count:t}=e,r=(0,x.c)("common");return 0===t?null:(0,n.jsx)("span",{"data-testid":"attention-badge-bubble",role:"status","aria-label":r("attention.badgeLabel",{count:t}),className:"absolute -top-1.5 -right-2.5 min-w-[1.05rem] rounded-full bg-warning-foreground px-1 text-[0.625rem] font-bold leading-[1.05rem] text-warning-subtle tabular-nums text-center",children:t>99?"99+":t})}let eJ=[{labelKey:"nav.sessions",href:"/sessions",isActive:e=>e.startsWith("/sessions"),icon:(0,n.jsx)(p.A,{size:20,"aria-hidden":"true"})},{labelKey:"nav.review",href:"/review",isActive:e=>e.startsWith("/review"),icon:(0,n.jsx)(g.A,{size:20,"aria-hidden":"true"}),showsAttentionBadge:!0},{labelKey:"nav.more",href:"/more",isActive:e=>e.startsWith("/more"),icon:(0,n.jsx)(eI.A,{size:20,"aria-hidden":"true"})}];function eU(){let e=(0,s.usePathname)(),{setOpen:t}=(0,eL.C)(),r=(0,x.c)("commandPalette"),a=(0,x.c)("common"),{count:i}=(0,ee.Lv)(),l=(0,o.pT)();return(null==l?void 0:l.isMobileDrawerOpen)?null:(0,n.jsx)("nav",{"data-testid":"global-mobile-nav",className:"fixed bottom-0 left-0 right-0 z-50 border-t border-border bg-background supports-[backdrop-filter]:bg-background/80 backdrop-blur-md pb-safe",children:(0,n.jsxs)("div",{className:"flex items-center justify-around h-14",children:[l&&(0,n.jsxs)("button",{type:"button","data-testid":"mobile-nav-open-sidebar",onClick:l.openMobileDrawer,className:"flex flex-col items-center justify-center flex-1 h-full text-xs text-muted-foreground hover:text-foreground transition-colors",children:[(0,n.jsx)(eq.A,{size:20,"aria-hidden":"true"}),(0,n.jsx)("span",{className:"mt-1 whitespace-nowrap",children:a("sidebar.branches")})]}),eJ.map(t=>{let r=t.isActive(e),s=!0===t.showsAttentionBadge&&i>0;return(0,n.jsxs)(h,{href:s?Q.ks:t.href,className:"flex flex-col items-center justify-center flex-1 h-full text-xs transition-colors ".concat(r?"text-accent-600 dark:text-accent-400":"text-muted-foreground hover:text-foreground"),children:[(0,n.jsxs)("span",{className:"relative inline-flex",children:[t.icon,!0===t.showsAttentionBadge&&(0,n.jsx)(eG,{count:i})]}),(0,n.jsx)("span",{className:"mt-1 whitespace-nowrap",children:a(t.labelKey)})]},t.href)}),(0,n.jsxs)("button",{type:"button","data-testid":"mobile-command-palette-trigger",onClick:()=>t(!0),"aria-label":r("mobileTrigger"),className:"flex flex-col items-center justify-center flex-1 h-full text-xs text-muted-foreground hover:text-foreground transition-colors",children:[(0,n.jsx)(ej.A,{size:20,"aria-hidden":"true"}),(0,n.jsx)("span",{className:"mt-1 whitespace-nowrap",children:r("mobileLabel")})]})]})})}function e$(){let{shouldSurface:e,isReconnecting:t}=(0,eM.Fx)(),r=(0,x.c)("common");if(!e)return null;let s=r(t?"connection.reconnecting":"connection.offline"),a=r(t?"connection.reconnectingTooltip":"connection.offlineTooltip");return(0,n.jsx)("div",{"data-testid":"mobile-connection-banner","data-connection-state":t?"reconnecting":"offline",role:"status","aria-live":"polite",title:a,className:"shrink-0 pt-safe border-b ".concat(t?"bg-warning-subtle border-warning-border text-warning-foreground":"bg-danger-subtle border-danger-border text-danger-foreground"),children:(0,n.jsxs)("div",{className:"flex items-center justify-center gap-1.5 px-3 py-1 text-xs",children:[(0,n.jsx)("span",{"aria-hidden":"true",className:"w-1.5 h-1.5 rounded-full ".concat(t?"bg-warning motion-safe:animate-pulse":"bg-danger")}),s]})})}var eX=r(45573),eY=r(94465),eZ=r(70628);let eQ=["global","terminal","composer","editor"],e0=[{id:"commandPalette",keys:["MOD","K"],scope:"global"},{id:"keyboardHelp",keys:["?"],scope:"global"},{id:"closeOverlay",keys:["Esc"],scope:"global"},{id:"navigateList",keys:["↑","↓"],scope:"global"},{id:"terminalSearch",keys:["MOD","F"],scope:"terminal"},{id:"toggleSurfaceMode",keys:["MOD","Shift","M"],scope:"terminal"},{id:"sendMessage",keys:["↵"],scope:"composer"},{id:"composerNewline",keys:["Shift","↵"],scope:"composer"},{id:"editorIndent",keys:["Tab"],scope:"editor"},{id:"editorOutdent",keys:["Shift","Tab"],scope:"editor"},{id:"editorTabFocus",keys:["Ctrl","M"],scope:"editor"},{id:"editorSave",keys:["MOD","S"],scope:"editor"},{id:"editorFullscreen",keys:["MOD","Shift","F"],scope:"editor"}];function e1(){let{open:e,setOpen:t}=(0,eZ.K)(),{open:r}=(0,eL.C)(),s=(0,x.c)("keyboardShortcuts"),[o,i]=(0,a.useState)(!1);(0,a.useEffect)(()=>i(function(){if("undefined"==typeof navigator)return!1;let e=navigator.platform||navigator.userAgent||"";return/Mac|iPhone|iPad|iPod/.test(e)}()),[]);let l=(0,a.useRef)(e);(0,a.useEffect)(()=>{l.current=e},[e]);let c=(0,a.useRef)(r);(0,a.useEffect)(()=>{c.current=r},[r]),(0,a.useEffect)(()=>{function e(e){"?"!==e.key||e.isComposing||229===e.keyCode||(0,eX.tJ)(e.target)||c.current||l.current||(e.preventDefault(),t(!0))}return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[t]);let d=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e0;return eQ.map(t=>({scope:t,shortcuts:e.filter(e=>e.scope===t)})).filter(e=>e.shortcuts.length>0)}();return(0,n.jsx)(eY.a,{isOpen:e,onClose:()=>t(!1),title:s("title"),size:"md",children:(0,n.jsx)("div",{"data-testid":"keyboard-shortcuts-overlay",className:"space-y-6",children:d.map(e=>{let{scope:t,shortcuts:r}=e;return(0,n.jsxs)("section",{"data-testid":"keyboard-shortcuts-scope-".concat(t),children:[(0,n.jsx)("h4",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-muted-foreground",children:s("scopes.".concat(t))}),(0,n.jsx)("ul",{className:"divide-y divide-border",children:r.map(e=>(0,n.jsxs)("li",{"data-testid":"keyboard-shortcut-".concat(e.id),className:"flex items-center justify-between gap-4 py-2",children:[(0,n.jsx)("span",{className:"text-sm text-foreground",children:s("shortcuts.".concat(e.id))}),(0,n.jsx)("span",{className:"flex flex-shrink-0 items-center gap-1",children:e.keys.map((e,t)=>(0,n.jsx)(eA.u,{children:"MOD"===e?o?"⌘":"Ctrl":e},t))})]},e.id))})]},t)})})})}var e2=r(77016),e5=r(36809),e4=r(31166);let e3=/^v?\d+\.\d+\.\d+$/;function e9(e){return e.replace(/^v/,"").split(".").map(Number)}let e6="commandmate.lastSeenAppVersion";function e8(e){try{window.localStorage.setItem(e6,e)}catch(e){}}let e7=[{key:"added",labelKey:"whatsNew.added"},{key:"improved",labelKey:"whatsNew.improved"},{key:"fixed",labelKey:"whatsNew.fixed"}];function te(){let e=(0,x.c)("common"),t=(0,e5.Ym)(),[r,s]=(0,a.useState)(null),[o,i]=(0,a.useState)(!1);(0,a.useEffect)(()=>{let e,t="0.40.0";try{e=window.localStorage.getItem(e6)}catch(e){return}let r=function(e,t){if(!e3.test(t))return{kind:"none"};if(null===e||!e3.test(e))return{kind:"remember"};let r=function(e,t){let r=e9(e),n=e9(t),s=Math.max(r.length,n.length);for(let e=0;e<s;e++){let t=r[e]||0,s=n[e]||0;if(t>s)return 1;if(t<s)return -1}return 0}(t,e);return 0===r?{kind:"none"}:r<0?{kind:"remember"}:{kind:"show",from:e}}(e,t);if("none"===r.kind)return;if("remember"===r.kind)return void e8(t);let n=!1;return er.GQ.getReleaseNotes(r.from,t).then(e=>{n||(s({from:r.from,to:t,notes:e.notes}),i(!0))},()=>{}),()=>{n=!0}},[]);let l=(0,a.useCallback)(()=>{r&&e8(r.to),i(!1)},[r]);if(!r)return null;let c="ja"===t?"ja":"en";return(0,n.jsx)(eY.a,{isOpen:o,onClose:l,title:e("whatsNew.title",{from:r.from,to:r.to}),size:"md",children:(0,n.jsxs)("div",{className:"space-y-4","data-testid":"whats-new-dialog",children:[0===r.notes.length?(0,n.jsx)("p",{className:"text-sm text-foreground","data-testid":"whats-new-empty",children:e("whatsNew.empty")}):r.notes.map(t=>(0,n.jsxs)("section",{className:"space-y-3","data-testid":"whats-new-version-".concat(t.version),children:[(0,n.jsxs)("h4",{className:"text-sm font-semibold text-foreground",children:["v",t.version,(0,n.jsx)("span",{className:"ml-2 text-xs font-normal text-muted-foreground",children:t.date})]}),t.highlight&&(0,n.jsxs)("div",{"data-testid":"whats-new-highlight",children:[(0,n.jsx)("h5",{className:"text-xs font-medium text-muted-foreground",children:e("whatsNew.highlight")}),(0,n.jsx)("p",{className:"mt-1 text-sm text-foreground",children:t.highlight[c]})]}),e7.map(r=>{let{key:s,labelKey:a}=r;return t[s].length>0?(0,n.jsxs)("div",{"data-testid":"whats-new-".concat(s),children:[(0,n.jsx)("h5",{className:"text-xs font-medium text-muted-foreground",children:e(a)}),(0,n.jsx)("ul",{className:"mt-1 list-disc space-y-1 pl-5 text-sm text-foreground",children:t[s].map((e,t)=>(0,n.jsx)("li",{children:e[c]},t))})]},s):null})]},t.version)),(0,n.jsxs)("div",{className:"flex items-center justify-between gap-3 border-t border-border pt-3",children:[(0,n.jsx)("a",{href:"".concat("https://github.com/Kewton/CommandMate/releases/tag/v").concat(r.to),target:"_blank",rel:"noopener noreferrer",className:"text-sm text-accent-600 dark:text-accent-400 hover:underline","data-testid":"whats-new-release-link",children:e("whatsNew.releaseLink")}),(0,n.jsx)(e4.$,{type:"button",variant:"primary",size:"sm",onClick:l,"data-testid":"whats-new-close",children:e("whatsNew.close")})]})]})})}let tt="transform transition-transform duration-300 ease-out",tr=(0,a.memo)(function(e){let{children:t}=e,{isOpen:r,isMobileDrawerOpen:u,closeMobileDrawer:m,width:f,setWidth:h,repoTabBarMode:x}=(0,o.VF)(),b=(0,i.a)(),{showSidebar:p,showGlobalNav:g}=function(){var e=(0,s.usePathname)();for(let t of c)if(e.startsWith(t.prefix))return{...l,...t.config};return{...l}}(),{factor:v}=(0,d.Ps)(),y=Math.round(160*v),w=Math.round(480*v),j=Math.round(Math.min(w,Math.max(y,f*v))),N=(0,en.fs)(null!=x?x:en.PB,r),k=Math.round(32*v)+64*!!g,C=(0,a.useRef)(null),M=(0,a.useRef)(null),S=(0,a.useCallback)(e=>{h(Math.round(e/v))},[h,v]);return b?(0,n.jsxs)("div",{"data-testid":"app-shell",className:"h-screen flex flex-col",children:[(0,n.jsx)(e$,{}),u&&(0,n.jsx)("div",{"data-testid":"drawer-overlay",className:"fixed inset-0 bg-black/50 z-40",onClick:m,"aria-hidden":"true"}),p&&(0,n.jsx)("aside",{"data-testid":"sidebar-container",className:"\n fixed left-0 top-0 h-full w-72 z-50\n ".concat(tt,"\n ").concat(u?"translate-x-0":"-translate-x-full","\n "),role:"complementary",children:(0,n.jsx)(el,{})}),(0,n.jsx)("main",{className:"flex-1 min-h-0 overflow-hidden ".concat(g?"pb-nav-safe":""),role:"main","data-view-transition":"content",children:t}),g&&(0,n.jsx)(eU,{}),(0,n.jsx)(eX.xq,{}),(0,n.jsx)(e1,{}),(0,n.jsx)(e2.n,{}),(0,n.jsx)(te,{})]}):(0,n.jsxs)("div",{"data-testid":"app-shell",className:"h-screen flex flex-col",children:[N&&(0,n.jsx)(eF,{}),g&&(0,n.jsx)(eT,{}),(0,n.jsxs)("div",{className:"flex flex-1 min-h-0",children:[p&&(0,n.jsxs)("aside",{ref:C,"data-testid":"sidebar-container",className:"\n fixed left-0\n ".concat(g?"top-16 h-[calc(100vh-4rem)]":"top-0 h-full","\n border-r border-border\n ").concat(tt,"\n ").concat(r?"translate-x-0":"-translate-x-full","\n "),style:{width:"".concat(j,"px"),zIndex:eP.M.SIDEBAR,...N?{top:"".concat(k,"px"),height:"calc(100vh - ".concat(k,"px)")}:{}},role:"complementary","aria-hidden":!r,children:[(0,n.jsx)(el,{}),(0,n.jsx)(tn,{currentWidth:j,minWidth:y,maxWidth:w,sidebarRef:C,mainRef:M,onWidthChange:S})]}),(0,n.jsx)("main",{ref:M,className:"flex-1 min-w-0 h-full overflow-hidden transition-[padding] duration-300 ease-out",style:{paddingLeft:p&&r?"".concat(j,"px"):0},role:"main","data-view-transition":"content",children:t})]}),(0,n.jsx)(eX.xq,{}),(0,n.jsx)(e1,{}),(0,n.jsx)(e2.n,{}),(0,n.jsx)(te,{})]})});function tn(e){let{currentWidth:t,minWidth:r,maxWidth:s,sidebarRef:a,mainRef:o,onWidthChange:i}=e;return(0,n.jsx)("div",{"data-testid":"sidebar-resize-handle","aria-hidden":"true",onMouseDown:e=>{e.preventDefault();let n=e.clientX,l=t;o.current&&(o.current.style.transition="none");let c=e=>{l=Math.max(r,Math.min(s,t+(e.clientX-n))),a.current&&(a.current.style.width="".concat(l,"px")),o.current&&(o.current.style.paddingLeft="".concat(l,"px"))},d=()=>{document.body.style.cursor="",document.body.style.userSelect="",o.current&&(o.current.style.transition=""),document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",d),i(l)};document.body.style.cursor="col-resize",document.body.style.userSelect="none",document.addEventListener("mousemove",c),document.addEventListener("mouseup",d)},className:"absolute top-0 right-0 w-1 h-full cursor-col-resize hover:bg-accent-500/40 transition-colors"})}let ts=["/login","/offline","/proxy"],ta=/^\/worktrees\/[^/]+\/(terminal|files)(\/|$)/;function to(e){var t;let{children:r}=e,a=(0,s.usePathname)();return(t=null!=a?a:"",ts.some(e=>t===e||t.startsWith("".concat(e,"/")))||ta.test(t)||0)?(0,n.jsx)(n.Fragment,{children:r}):(0,n.jsx)(tr,{children:r})}},76471:(e,t,r)=>{"use strict";r.d(t,{Ej:()=>d,Jd:()=>i,Mq:()=>c,rH:()=>l});var n=r(95155),s=r(12115),a=r(18955),o=r(48481);let i="bg-transparent border-2 border-muted-foreground",l="status.unknown";function c(e,t){return!0===t&&"ready"===e}let d=(0,s.memo)(function(e){let{status:t,label:r,waitingKind:s,unclassified:d}=e,u=(0,a.c)("common"),m=c(t,d);return(0,n.jsx)(o.m,{"data-testid":"status-indicator",status:t,label:m?null!=r?r:u(l):r,waitingKind:s,size:"lg",className:m?i:void 0,"data-unclassified":m?"true":void 0})})},77016:(e,t,r)=>{"use strict";r.d(t,{W:()=>g,n:()=>v});var n=r(95155),s=r(12115),a=r(18955),o=r(52056),i=r(89559),l=r(65229),c=r(59854),d=r(60199),u=r(52703);let m=0,f=new Set;function h(){for(let e of f)e()}function x(e){return f.add(e),()=>{f.delete(e)}}function b(){return m>0}function p(){return!1}function g(){return(0,s.useSyncExternalStore)(x,b,p)}function v(){let e=(0,a.c)("common"),[t,r]=(0,s.useState)(null),[f,x]=(0,s.useState)(null),b=(0,s.useCallback)(e=>{if(e.type!==u.Oo)return;let{serverVersion:t,clientVersion:n}=e;"string"==typeof t&&"string"==typeof n&&t&&n&&t!==f&&r({serverVersion:t,clientVersion:n})},[f]);(0,d.T3)(b);let p=null!==t;(0,s.useEffect)(()=>{if(p)return m+=1,h(),()=>{m-=1,h()}},[p]);let g=(0,s.useCallback)(()=>{window.location.reload()},[]),v=(0,s.useCallback)(()=>{r(e=>(e&&x(e.serverVersion),null))},[]);return t?(0,n.jsxs)("div",{"data-testid":"version-mismatch-banner",role:"alert","aria-live":"assertive",className:"fixed top-3 left-1/2 -translate-x-1/2 flex items-start gap-3 max-w-[92vw] rounded-lg border border-warning-border bg-warning-subtle px-4 py-3 text-warning-foreground shadow-lg",style:{zIndex:c.M.TOAST},children:[(0,n.jsx)(o.A,{className:"h-5 w-5 shrink-0 mt-0.5","aria-hidden":"true"}),(0,n.jsxs)("div",{className:"flex flex-col gap-0.5 text-sm",children:[(0,n.jsx)("span",{className:"font-semibold",children:e("versionMismatch.title")}),(0,n.jsx)("span",{children:e("versionMismatch.description",{serverVersion:t.serverVersion,clientVersion:t.clientVersion})})]}),(0,n.jsxs)("button",{type:"button","data-testid":"version-mismatch-reload",onClick:g,className:"shrink-0 inline-flex items-center gap-1.5 rounded-md border border-warning-border px-3 py-1.5 text-sm font-medium hover:opacity-80 focus:outline-none focus:ring-2 focus:ring-offset-2",children:[(0,n.jsx)(i.A,{className:"h-4 w-4","aria-hidden":"true"}),e("versionMismatch.reload")]}),(0,n.jsx)("button",{type:"button","data-testid":"version-mismatch-dismiss",onClick:v,"aria-label":e("versionMismatch.dismiss"),className:"shrink-0 hover:opacity-70 focus:outline-none focus:ring-2 focus:ring-offset-2",children:(0,n.jsx)(l.A,{className:"h-4 w-4","aria-hidden":"true"})})]}):null}},80903:(e,t,r)=>{Promise.resolve().then(r.t.bind(r,22311,23)),Promise.resolve().then(r.t.bind(r,7183,23)),Promise.resolve().then(r.t.bind(r,13673,23)),Promise.resolve().then(r.bind(r,62295)),Promise.resolve().then(r.bind(r,25772))}},e=>{e.O(0,[5373,2978,6809,4909,2770,2619,6192,8318,8407,2407,344,5449,6966,8606,4768,8165,9619,8441,1255,7358],()=>e(e.s=80903)),_N_E=e.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8975],{3199:(e,t,a)=>{"use strict";a.d(t,{Vt:()=>s,aN:()=>l,zK:()=>u,I_:()=>i,JY:()=>o,sd:()=>d,kj:()=>c});let r=/^[a-zA-Z0-9][a-zA-Z0-9\-._/:]*$/,n=/^[a-zA-Z0-9][a-zA-Z0-9\-._]*$/,s=new Set(["copilot","opencode"]),l=new Set(["opencode"]);function i(e){let t=e.trim();if(!t)return{cliToolId:"claude",model:void 0};let{tokens:a,error:r}=function(e){let t=[],a="",r=!1,n=null;for(let s of e){if(n){s===n?n=null:a+=s;continue}if('"'===s||"'"===s){n=s,r=!0;continue}if(/\s/.test(s)){r&&(t.push(a),a="",r=!1);continue}a+=s,r=!0}return n?{tokens:[],error:"CLI Tool column has an unterminated quote"}:(r&&t.push(a),{tokens:t})}(t);if(r)return{cliToolId:t.split(/\s+/)[0],error:r};let n=a[0];return 1===a.length?{cliToolId:n,model:void 0}:s.has(n)?l.has(n)?function(e,t){let a={cliToolId:e},r=new Set,n=(e,a)=>{let r=t[a+1];return void 0===r||r.startsWith("-")?null:r};for(let s=0;s<t.length;s++){let l=t[s];if(r.has(l))return{cliToolId:e,error:"".concat(e,' option "').concat(l,'" is repeated')};switch(l){case"--model":case"-m":{let t=n(l,s);if(null===t)return{cliToolId:e,error:"".concat(e,' option "').concat(l,'" needs a value')};r.add("--model"),r.add("-m"),a.model=t,s++;break}case"--agent":{let t=n(l,s);if(null===t)return{cliToolId:e,error:"".concat(e,' option "').concat(l,'" needs a value')};r.add(l),a.agent=t,s++;break}case"--variant":{let t=n(l,s);if(null===t)return{cliToolId:e,error:"".concat(e,' option "').concat(l,'" needs a value')};r.add(l),a.variant=t,s++;break}case"--title":{let t=n(l,s);if(null===t)return{cliToolId:e,error:"".concat(e,' option "').concat(l,'" needs a value')};r.add(l),a.title=t,s++;break}case"--continue":case"-c":r.add("--continue"),r.add("-c"),a.continueSession=!0;break;default:return{cliToolId:e,error:"".concat(e," only supports: ").concat("opencode [--model <provider/model>] [--agent <name>] [--variant <name>] [--continue] [--title <text>]")}}}return a}(n,a.slice(1)):3===a.length&&"--model"===a[1]?{cliToolId:n,model:a[2]}:{cliToolId:n,error:"".concat(n," only supports: ").concat(n," --model <modelName>")}:{cliToolId:n,error:'CLI Tool "'.concat(n,'" does not support additional options')}}function o(e){return/[\x00-\x1f\x7f]/.test(e)?{valid:!1,reason:"Model name contains control characters"}:""===e.trim()?{valid:!1,reason:"Model name must not be empty"}:r.test(e)?e.length>128?{valid:!1,reason:"Model name exceeds ".concat(128," characters")}:{valid:!0}:{valid:!1,reason:"Model name contains invalid characters"}}function d(e,t){return/[\x00-\x1f\x7f]/.test(e)?{valid:!1,reason:"opencode ".concat(t," contains control characters")}:""===e.trim()?{valid:!1,reason:"opencode ".concat(t," must not be empty")}:n.test(e)?e.length>64?{valid:!1,reason:"opencode ".concat(t," exceeds ").concat(64," characters")}:{valid:!0}:{valid:!1,reason:"opencode ".concat(t," contains invalid characters")}}function c(e){return/[\x00-\x1f\x7f]/.test(e)?{valid:!1,reason:"opencode title contains control characters"}:""===e.trim()?{valid:!1,reason:"opencode title must not be empty"}:e.startsWith("-")?{valid:!1,reason:'opencode title must not start with "-"'}:e.includes("|")?{valid:!1,reason:'opencode title must not contain "|"'}:e.length>200?{valid:!1,reason:"opencode title exceeds ".concat(200," characters")}:{valid:!0}}function u(e){let t=[],a=i(e);if(a.error&&t.push(a.error),a.model){let e=o(a.model);e.valid||t.push(e.reason)}if(a.agent){let e=d(a.agent,"agent");e.valid||t.push(e.reason)}if(a.variant){let e=d(a.variant,"variant");e.valid||t.push(e.reason)}if(a.title){let e=c(a.title);e.valid||t.push(e.reason)}return{result:a,errors:t}}},4138:(e,t,a)=>{"use strict";a.d(t,{q:()=>s});var r=a(12115),n=a(9900);function s(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n.pX,[t,a]=(0,r.useState)(!1),s=(0,r.useRef)(null);return(0,r.useEffect)(()=>()=>{null!==s.current&&(clearTimeout(s.current),s.current=null)},[]),{copied:t,markCopied:(0,r.useCallback)(()=>{a(!0),null!==s.current&&clearTimeout(s.current),s.current=setTimeout(()=>{s.current=null,a(!1)},e)},[e]),reset:(0,r.useCallback)(()=>{null!==s.current&&(clearTimeout(s.current),s.current=null),a(!1)},[])}}},17442:(e,t,a)=>{"use strict";a.r(t),a.d(t,{default:()=>A});var r=a(95155),n=a(12115),s=a(18955),l=a(48407),i=a(52619),o=a.n(i),d=a(20063),c=a(87531),u=a(44308),m=a(55449),p=a(38606),x=a(76471),h=a(54014),f=a(46892);let g={in_review:"status.inReview",approval:"status.approval",stalled:"status.stalled"},v=u.DR,b={in_review:e=>"in_review"===e.status,approval:e=>!0===e.isWaitingForResponse,stalled:e=>!0===e.isStalled};function y(e){let{status:t,label:a,unclassified:n}=e,l=(0,s.c)("common"),i=f.PL[t],o="w-2.5 h-2.5 rounded-full flex-shrink-0";if((0,x.Mq)(t,n))return(0,r.jsx)("span",{className:"".concat(o," ").concat(x.Jd),title:"".concat(a,": ").concat(l(x.rH)),"data-unclassified":"true"});let d="".concat(a,": ").concat(l(i.labelKey));return"spinner"===i.type?(0,r.jsx)("span",{className:"".concat(o," border-2 border-t-transparent animate-spin ").concat(i.className),title:d}):(0,r.jsx)("span",{className:"".concat(o," ").concat(i.className),title:d})}function j(){var e;let t=(0,s.c)("review"),[a,i]=(0,n.useState)([]),[x,f]=(0,n.useState)(!0),j=(0,d.useSearchParams)(),[w,N]=(0,n.useState)(()=>{var e;return null!=(e=(0,u._d)(null==j?void 0:j.get(u.z7)))?e:u.SD}),S=(0,n.useRef)(null),k=null!=(e=null==j?void 0:j.get(u.z7))?e:null;(0,n.useEffect)(()=>{let e=(0,u._d)(k);e&&N(e)},[k]);let C=(0,n.useCallback)(async()=>{try{let t=await fetch("/api/worktrees?include=review");if(t.ok){var e;let a=await t.json();(0,m.IK)(a.defaultSelectedAgents),i(null!=(e=a.worktrees)?e:[])}}catch(e){}finally{f(!1)}},[]);(0,n.useEffect)(()=>(C(),S.current=setInterval(C,u.Iu),()=>{S.current&&clearInterval(S.current)}),[C]);let T=(0,n.useMemo)(()=>a.filter(b[w]),[a,w]),z=(0,n.useMemo)(()=>({in_review:a.filter(b.in_review).length,approval:a.filter(b.approval).length,stalled:a.filter(b.stalled).length}),[a]),P=(0,n.useMemo)(()=>{switch(w){case"in_review":return t("empty.inReview");case"approval":return t("empty.approval");case"stalled":return t("empty.stalled")}},[w,t]);return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("div",{className:"mb-6 inline-flex items-center gap-1 rounded-lg bg-muted p-1",role:"group","aria-label":t("filters.ariaLabel"),"data-testid":"review-filters",children:v.map(e=>{let a=w===e;return(0,r.jsxs)("button",{type:"button","aria-pressed":a,onClick:()=>N(e),"data-testid":"review-filter-".concat(e),className:(0,c.cn)("inline-flex items-center gap-1.5 rounded-md px-3 py-1.5 text-sm font-medium transition-colors","focus:outline-none focus-visible:ring-2 focus-visible:ring-ring",a?"bg-accent-500/15 text-accent-700 dark:text-accent-300":"text-muted-foreground hover:text-foreground"),children:[t(g[e]),(0,r.jsx)("span",{className:(0,c.cn)("text-xs font-semibold tabular-nums",a?"text-accent-700 dark:text-accent-300":"text-muted-foreground"),children:z[e]})]},e)})}),x&&(0,r.jsx)("div",{className:"space-y-2","data-testid":"review-loading",role:"status","aria-label":t("filters.loading"),children:[0,1,2].map(e=>(0,r.jsx)(l.Zp,{padding:"md",children:(0,r.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,r.jsxs)("div",{className:"min-w-0 flex-1 space-y-1.5",children:[(0,r.jsx)(l.EA,{className:"h-4 w-40 max-w-full"}),(0,r.jsx)(l.EA,{className:"h-3 w-24 max-w-full"})]}),(0,r.jsx)(l.EA,{className:"ml-4 h-5 w-16 flex-shrink-0"})]})},e))}),!x&&(0,r.jsx)("div",{className:"space-y-2","data-testid":"review-list",children:0===T.length?(0,r.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"review-empty",children:P}):T.map(e=>{var a;let n=null!=(a=e.selectedAgents)?a:(0,m.sA)();return(0,r.jsx)(o(),{href:"/worktrees/".concat(e.id),className:"block","data-testid":"review-item-".concat(e.id),children:(0,r.jsxs)(l.Zp,{padding:"md",className:"transition-colors ".concat(function(e){switch(e){case"in_review":return"border-info-border hover:border-info-border";case"approval":return"border-warning-border hover:border-warning-border";case"stalled":return"border-danger-border hover:border-danger-border"}}(w)),children:[(0,r.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,r.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,r.jsx)("div",{className:"text-sm font-medium text-foreground truncate",children:e.name}),(0,r.jsx)("div",{className:"text-xs text-muted-foreground truncate",children:e.repositoryName})]}),(0,r.jsxs)("div",{className:"flex items-center gap-2 ml-4 flex-shrink-0",children:[(0,r.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium rounded ".concat(function(e){switch(e){case"in_review":return"bg-info-subtle text-info-foreground";case"approval":return"bg-warning-subtle text-warning-foreground";case"stalled":return"bg-danger-subtle text-danger-foreground"}}(w)),children:t(g[w])}),n.map(t=>{var a;let n=null==(a=e.sessionStatusByCli)?void 0:a[t],s=(0,p.kA)(n);return(0,r.jsxs)("div",{className:"flex items-center gap-1",children:[(0,r.jsx)(y,{status:s,label:(0,h.oo)(t),unclassified:(0,p.px)(n)}),(0,r.jsx)("span",{className:"text-xs text-muted-foreground",children:(0,h.oo)(t)})]},t)})]})]}),e.description&&(0,r.jsx)("div",{className:"mt-2",children:(0,r.jsx)("p",{className:"text-xs text-muted-foreground line-clamp-2 whitespace-pre-wrap",children:e.description})})]})},e.id)})})]})}function w(e){let t=e.getFullYear(),a=String(e.getMonth()+1).padStart(2,"0"),r=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(a,"-").concat(r)}function N(e){let{value:t,onChange:a}=e,n=(0,s.c)("review"),i=w(new Date),o=t===i;return(0,r.jsxs)("div",{className:"flex items-center gap-2","data-testid":"report-date-picker",children:[(0,r.jsx)(l.$n,{variant:"secondary",size:"sm",onClick:()=>{let e=new Date(t+"T00:00:00");e.setDate(e.getDate()-1),a(w(e))},"data-testid":"date-prev","aria-label":n("datePicker.previousDay"),children:"<"}),(0,r.jsx)(l.pd,{type:"date",inputSize:"sm",value:t,max:i,onChange:e=>a(e.target.value),className:"w-auto","data-testid":"date-input"}),(0,r.jsx)(l.$n,{variant:"secondary",size:"sm",onClick:()=>{if(o)return;let e=new Date(t+"T00:00:00");e.setDate(e.getDate()+1);let r=w(e);r>i||a(r)},disabled:o,"data-testid":"date-next","aria-label":n("datePicker.nextDay"),children:">"})]})}var S=a(36402),k=a(3199),C=a(4138),T=a(60322);let z=[{value:"none",labelKey:"report.modes.none"},{value:"template",labelKey:"report.modes.template"},{value:"custom",labelKey:"report.modes.custom"}];function P(){let e=(0,s.c)("review"),t=(0,S.SC)(),[a,i]=(0,n.useState)(function(){let e=new Date,t=e.getFullYear(),a=String(e.getMonth()+1).padStart(2,"0"),r=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(a,"-").concat(r)}()),[o,d]=(0,n.useState)("claude"),[c,m]=(0,n.useState)(""),[p,x]=(0,n.useState)(null),[h,f]=(0,n.useState)(0),[g,v]=(0,n.useState)(""),[b,y]=(0,n.useState)(!1),[j,w]=(0,n.useState)(!1),[P,_]=(0,n.useState)(!1),[E,A]=(0,n.useState)(!1),{copied:D,markCopied:K}=(0,C.q)(),[I,R]=(0,n.useState)(null),$=k.Vt.has(o),{mode:M,setMode:L,userInstruction:O,setUserInstruction:Z,isUserInstructionReadOnly:q,templates:J,selectedTemplateId:F,selectTemplate:H,isLoadingTemplates:U}=function(){let[e,t]=(0,n.useState)("none"),[a,r]=(0,n.useState)(""),[s,l]=(0,n.useState)([]),[i,o]=(0,n.useState)(null),[d,c]=(0,n.useState)(!1),u=(0,n.useCallback)(async()=>{c(!0);try{let e=await fetch("/api/templates");if(e.ok){let t=await e.json();l(t.templates||[])}}catch(e){}finally{c(!1)}},[]);(0,n.useEffect)(()=>{u()},[u]);let m=(0,n.useCallback)(e=>{t(e),r(""),o(null)},[]),p=(0,n.useCallback)(t=>{"custom"===e&&r(t)},[e]),x=(0,n.useCallback)(t=>{let a=s.find(e=>e.id===t);a&&"template"===e&&(o(t),r(a.content))},[s,e]);return{mode:e,setMode:m,userInstruction:a,setUserInstruction:p,isUserInstructionReadOnly:"template"===e,templates:s,selectedTemplateId:i,selectTemplate:x,isLoadingTemplates:d,refreshTemplates:u}}(),V=function(e){let[t,a]=(0,n.useState)({generating:!1}),r=(0,n.useRef)(null),s=(0,n.useCallback)(async()=>{try{let e=await fetch("/api/daily-summary/status");if(e.ok){let t=await e.json();a(t)}}catch(e){}},[]);return(0,n.useEffect)(()=>e?(s(),r.current=setInterval(s,5e3),()=>{r.current&&(clearInterval(r.current),r.current=null)}):void a({generating:!1}),[e,s]),t}(!P),W=V.generating&&!P,B=(0,n.useCallback)(async t=>{w(!0),R(null);try{let a=await fetch("/api/daily-summary?date=".concat(t));if(!a.ok){let t=await a.json();R(t.error||e("report.errors.fetch"));return}let r=await a.json();x(r.report),f(r.messageCount),r.report?v(r.report.content):v(""),y(!1)}catch(t){R(e("report.errors.fetch"))}finally{w(!1)}},[e]);(0,n.useEffect)(()=>{B(a)},[a,B]);let[Y,X]=(0,n.useState)(!1);(0,n.useEffect)(()=>{V.generating?X(!0):Y&&(X(!1),B(a))},[V.generating,Y,B,a]);let G=async()=>{if(!p||await t({description:e("report.regenerateConfirm")})){_(!0),R(null);try{let t={date:a,tool:o};$&&c.trim()&&(t.model=c.trim()),"none"!==M&&O.trim()&&(t.userInstruction=O.trim());let r=await fetch("/api/daily-summary",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)});if(429===r.status)return void R(e("report.errors.rateLimited"));if(!r.ok){let t=await r.json();R(t.error||e("report.errors.generate"));return}let n=await r.json();x(n.report),v(n.report.content),y(!1)}catch(t){R(e("report.errors.generate"))}finally{_(!1)}}},Q=async()=>{if(!g.trim())return void R(e("report.errors.emptyContent"));A(!0),R(null);try{let t=await fetch("/api/daily-summary",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({date:a,content:g})});if(!t.ok){let a=await t.json();R(a.error||e("report.errors.save"));return}let r=await t.json();x(r.report),y(!1)}catch(t){R(e("report.errors.save"))}finally{A(!1)}};return(0,r.jsxs)("div",{"data-testid":"report-tab",children:[(0,r.jsxs)("div",{className:"flex flex-wrap items-center gap-4 mb-6",children:[(0,r.jsx)(N,{value:a,onChange:e=>{i(e)}}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)("label",{className:"text-sm text-muted-foreground",children:e("report.toolLabel")}),(0,r.jsx)("select",{value:o,onChange:e=>d(e.target.value),className:"px-3 py-1 text-sm rounded border border-input bg-surface dark:bg-surface-2 text-surface-foreground","data-testid":"tool-selector",children:u.IH.map(e=>(0,r.jsx)("option",{value:e,children:e},e))}),$&&(0,r.jsx)(l.pd,{type:"text",inputSize:"sm",placeholder:"opencode"===o?e("report.modelPlaceholderOpencode"):e("report.modelPlaceholder"),value:c,onChange:e=>m(e.target.value),className:"w-auto","data-testid":"model-input"})]})]}),(0,r.jsxs)("div",{className:"mb-4","data-testid":"generation-mode-selector",children:[(0,r.jsx)("label",{className:"text-sm font-medium text-foreground mb-2 block",children:e("report.generationMode")}),(0,r.jsx)(l.z6,{value:M,onValueChange:e=>L(e),name:"generation-mode",className:"flex flex-row gap-4",children:z.map(t=>(0,r.jsxs)("label",{className:"flex items-center gap-2 text-sm cursor-pointer",children:[(0,r.jsx)(l.CU,{value:t.value,"data-testid":"mode-radio-".concat(t.value)}),(0,r.jsx)("span",{className:"text-foreground",children:e(t.labelKey)})]},t.value))})]}),"template"===M&&(0,r.jsxs)("div",{className:"mb-4","data-testid":"template-selector",children:[(0,r.jsx)("label",{className:"text-sm font-medium text-foreground mb-2 block",children:e("report.selectTemplate")}),U?(0,r.jsx)(l.EA,{className:"h-9 w-full","data-testid":"report-template-loading",role:"status","aria-label":e("report.loadingTemplates"),"aria-hidden":void 0}):0===J.length?(0,r.jsx)("div",{className:"text-sm text-muted-foreground",children:e("report.noTemplates")}):(0,r.jsxs)("select",{value:F||"",onChange:e=>H(e.target.value),className:"px-3 py-1 text-sm rounded border border-input bg-surface dark:bg-surface-2 text-surface-foreground","data-testid":"template-select",children:[(0,r.jsx)("option",{value:"",children:e("report.templatePlaceholderOption")}),J.map(e=>(0,r.jsx)("option",{value:e.id,children:e.name},e.id))]})]}),"none"!==M&&(0,r.jsx)("div",{className:"mb-4",children:(0,r.jsx)(l.k_,{value:O,onChange:e=>Z(e.target.value),rows:3,maxLength:u.t7,readOnly:q,placeholder:"template"===M?e("report.instructionPlaceholderTemplate"):e("report.instructionPlaceholderCustom"),className:"resize-y ".concat(q?"bg-muted cursor-not-allowed":""),"data-testid":"user-instruction-input"})}),(0,r.jsx)("div",{className:"mb-6",children:(0,r.jsx)(l.$n,{variant:"primary",onClick:G,disabled:P||W||0===h,"data-testid":"generate-button",children:P||W?e("report.generating"):e("report.generate")})}),(0,r.jsx)("div",{className:"mb-4 text-sm text-muted-foreground","data-testid":"message-count",children:j?(0,r.jsx)(l.EA,{className:"h-4 w-48"}):0===h?e("report.noMessages"):e("report.messagesFound",{count:h})}),I&&(0,r.jsx)("div",{className:"mb-4 p-3 bg-danger-subtle text-danger-foreground rounded-lg text-sm","data-testid":"report-error",children:I}),(P||W)&&(0,r.jsxs)("div",{className:"flex items-center gap-2 mb-4 text-sm text-muted-foreground","data-testid":"generating-spinner",children:[(0,r.jsx)(l.y$,{size:"sm",variant:"muted"}),W&&V.tool?V.startedAt?e("report.generatingRemoteWithTime",{tool:V.tool,seconds:Math.round((Date.now()-new Date(V.startedAt).getTime())/1e3)}):e("report.generatingRemote",{tool:V.tool}):e("report.generatingSummary")]}),!j&&p&&(0,r.jsxs)(l.Zp,{"data-testid":"report-content",children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-3",children:[(0,r.jsxs)("div",{className:"text-xs text-muted-foreground",children:[e("report.generatedBy",{tool:p.generatedByTool}),p.model&&" (".concat(p.model,")")]}),(0,r.jsxs)("div",{className:"flex items-center gap-2",children:[(0,r.jsx)(l.$n,{variant:"secondary",size:"sm",onClick:async()=>{await (0,T.l)(p.content),K()},"data-testid":"copy-report-button",children:D?e("report.copied"):e("report.copy")}),(0,r.jsx)(l.$n,{variant:"secondary",size:"sm",onClick:()=>{b?Q():y(!0)},disabled:E,"data-testid":"edit-save-button",children:E?e("report.saving"):b?e("report.save"):e("report.edit")})]})]}),b?(0,r.jsx)(l.k_,{value:g,onChange:e=>v(e.target.value),className:"h-64 p-3 font-mono","data-testid":"report-editor"}):(0,r.jsx)("div",{className:"prose dark:prose-invert max-w-none text-sm whitespace-pre-wrap","data-testid":"report-preview",children:p.content})]})]})}function _(){let e=(0,s.c)("review"),t=(0,S.SC)(),[a,i]=(0,n.useState)([]),[o,d]=(0,n.useState)(!1),[c,m]=(0,n.useState)(null),[p,x]=(0,n.useState)(""),[h,f]=(0,n.useState)(""),[g,v]=(0,n.useState)(!1),[b,y]=(0,n.useState)(null),[j,w]=(0,n.useState)(""),[N,k]=(0,n.useState)(""),[C,T]=(0,n.useState)(!1),z=(0,n.useCallback)(async()=>{d(!0),m(null);try{let t=await fetch("/api/templates");if(!t.ok){let a=await t.json();m(a.error||e("template.errors.fetch"));return}let a=await t.json();i(a.templates||[])}catch(t){m(e("template.errors.fetch"))}finally{d(!1)}},[e]);(0,n.useEffect)(()=>{z()},[z]);let P=async()=>{if(!p.trim()||!h.trim())return void m(e("template.errors.nameAndContentRequired"));v(!0),m(null);try{let t=await fetch("/api/templates",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:p.trim(),content:h.trim()})});if(!t.ok){let a=await t.json();m(a.error||e("template.errors.create"));return}x(""),f(""),await z()}catch(t){m(e("template.errors.create"))}finally{v(!1)}},_=async()=>{if(!b||!j.trim()||!N.trim())return void m(e("template.errors.nameAndContentRequired"));T(!0),m(null);try{let t=await fetch("/api/templates/".concat(b),{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:j.trim(),content:N.trim()})});if(!t.ok){let a=await t.json();m(a.error||e("template.errors.update"));return}y(null),await z()}catch(t){m(e("template.errors.update"))}finally{T(!1)}},E=async a=>{if(await t({description:e("template.deleteConfirm"),variant:"danger"})){m(null);try{let t=await fetch("/api/templates/".concat(a),{method:"DELETE"});if(!t.ok){let a=await t.json();m(a.error||e("template.errors.delete"));return}await z()}catch(t){m(e("template.errors.delete"))}}},A=()=>{y(null),w(""),k("")};return(0,r.jsxs)("div",{"data-testid":"template-tab",children:[c&&(0,r.jsx)("div",{className:"mb-4 p-3 bg-danger-subtle text-danger-foreground rounded-lg text-sm","data-testid":"template-error",children:c}),(0,r.jsxs)("div",{className:"mb-6",children:[(0,r.jsx)("h2",{className:"text-lg font-semibold text-foreground mb-3",children:e("template.heading",{count:a.length,max:u.$h})}),o?(0,r.jsx)("div",{className:"space-y-3","data-testid":"template-loading",role:"status","aria-label":e("template.loading"),children:[0,1].map(e=>(0,r.jsx)(l.Zp,{padding:"md",children:(0,r.jsxs)("div",{className:"space-y-2",children:[(0,r.jsx)(l.EA,{className:"h-4 w-32"}),(0,r.jsx)(l.EA,{className:"h-3 w-full"}),(0,r.jsx)(l.EA,{className:"h-3 w-2/3"})]})},e))}):0===a.length?(0,r.jsx)("div",{className:"text-sm text-muted-foreground","data-testid":"template-empty",children:e("template.empty")}):(0,r.jsx)("div",{className:"space-y-3","data-testid":"template-list",children:a.map(t=>(0,r.jsx)(l.Zp,{padding:"sm","data-testid":"template-item-".concat(t.id),children:b===t.id?(0,r.jsxs)("div",{className:"space-y-2",children:[(0,r.jsx)(l.pd,{type:"text",inputSize:"sm",value:j,onChange:e=>w(e.target.value),maxLength:u.Nb,"data-testid":"edit-name-input"}),(0,r.jsx)(l.k_,{value:N,onChange:e=>k(e.target.value),maxLength:u.bm,rows:3,className:"resize-y","data-testid":"edit-content-input"}),(0,r.jsxs)("div",{className:"flex gap-2",children:[(0,r.jsx)(l.$n,{variant:"primary",size:"sm",onClick:_,disabled:C,"data-testid":"edit-save-button",children:C?e("template.saving"):e("template.save")}),(0,r.jsx)(l.$n,{variant:"secondary",size:"sm",onClick:A,"data-testid":"edit-cancel-button",children:e("template.cancel")})]})]}):(0,r.jsxs)("div",{children:[(0,r.jsxs)("div",{className:"flex items-center justify-between mb-1",children:[(0,r.jsx)("span",{className:"font-medium text-sm text-foreground","data-testid":"template-name",children:t.name}),(0,r.jsxs)("div",{className:"flex gap-2",children:[(0,r.jsx)(l.$n,{variant:"secondary",size:"sm",onClick:()=>{y(t.id),w(t.name),k(t.content)},"data-testid":"edit-button-".concat(t.id),children:e("template.edit")}),(0,r.jsx)(l.$n,{variant:"danger",size:"sm",onClick:()=>E(t.id),"data-testid":"delete-button-".concat(t.id),children:e("template.delete")})]})]}),(0,r.jsx)("p",{className:"text-xs text-muted-foreground whitespace-pre-wrap","data-testid":"template-content",children:t.content})]})},t.id))})]}),a.length<u.$h&&(0,r.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg shadow-sm","data-testid":"create-form",children:[(0,r.jsx)("h3",{className:"text-sm font-semibold text-foreground mb-3",children:e("template.newHeading")}),(0,r.jsxs)("div",{className:"space-y-3",children:[(0,r.jsx)(l.pd,{type:"text",value:p,onChange:e=>x(e.target.value),maxLength:u.Nb,placeholder:e("template.namePlaceholder"),"data-testid":"new-name-input"}),(0,r.jsx)(l.k_,{value:h,onChange:e=>f(e.target.value),maxLength:u.bm,rows:3,placeholder:e("template.contentPlaceholder"),className:"resize-y","data-testid":"new-content-input"}),(0,r.jsx)(l.$n,{variant:"primary",onClick:P,disabled:g||!p.trim()||!h.trim(),"data-testid":"create-button",children:g?e("template.creating"):e("template.create")})]})]})]})}let E=[{value:"review",labelKey:"tabs.review"},{value:"report",labelKey:"tabs.report"},{value:"template",labelKey:"tabs.template"}];function A(){let e=(0,s.c)("review"),[t,a]=(0,n.useState)("review");return(0,r.jsxs)("div",{className:"container-custom py-8 overflow-auto h-full",children:[(0,r.jsxs)("div",{className:"mb-6",children:[(0,r.jsx)("h1",{className:"text-2xl font-bold text-foreground mb-2",children:e("page.title")}),(0,r.jsx)("p",{className:"text-sm text-muted-foreground",children:e("page.description")})]}),(0,r.jsxs)(l.tU,{value:t,onValueChange:e=>a(e),children:[(0,r.jsx)(l.j7,{className:"mb-6 w-full justify-start","data-testid":"page-tabs",children:E.map(t=>(0,r.jsx)(l.Xi,{value:t.value,"data-testid":"page-tab-".concat(t.value),children:e(t.labelKey)},t.value))}),(0,r.jsx)(l.av,{value:"review",children:(0,r.jsx)(n.Suspense,{fallback:null,children:(0,r.jsx)(j,{})})}),(0,r.jsx)(l.av,{value:"report",children:(0,r.jsx)(P,{})}),(0,r.jsx)(l.av,{value:"template",children:(0,r.jsx)(_,{})})]})]})}},20063:(e,t,a)=>{"use strict";var r=a(47260);a.o(r,"useParams")&&a.d(t,{useParams:function(){return r.useParams}}),a.o(r,"usePathname")&&a.d(t,{usePathname:function(){return r.usePathname}}),a.o(r,"useRouter")&&a.d(t,{useRouter:function(){return r.useRouter}}),a.o(r,"useSearchParams")&&a.d(t,{useSearchParams:function(){return r.useSearchParams}})},44308:(e,t,a)=>{"use strict";a.d(t,{$h:()=>u,DR:()=>n,IH:()=>d,Iu:()=>r,Nb:()=>m,SD:()=>s,_d:()=>o,bm:()=>p,ks:()=>i,t7:()=>c,z7:()=>l});let r=7e3,n=["in_review","approval","stalled"],s="in_review",l="filter",i="/review?".concat(l,"=approval");function o(e){return e&&n.includes(e)?e:null}let d=["claude","codex","copilot","antigravity","opencode"],c=1e3,u=5,m=100,p=1e3},46892:(e,t,a)=>{"use strict";a.d(t,{PL:()=>n,sb:()=>s});let r={idle:"bg-muted-foreground",ready:"bg-success",spinner:"border-info",waiting:"bg-warning"},n={idle:{className:r.idle,labelKey:"status.idle",type:"dot"},ready:{className:r.ready,labelKey:"status.ready",type:"dot"},running:{className:r.spinner,labelKey:"status.running",type:"spinner"},waiting:{className:r.waiting,labelKey:"status.waiting",type:"dot"},generating:{className:r.spinner,labelKey:"status.generating",type:"spinner"}},s={idle:"detailStatus.idle",ready:"detailStatus.ready",running:"detailStatus.running",waiting:"detailStatus.waiting"}},60322:(e,t,a)=>{"use strict";a.d(t,{l:()=>n});let r=/\x1b\[[0-9;]*[a-zA-Z]|\x1b\][^\x07]*\x07|\[[0-9;]*m/g;async function n(e){var t;if(!e||0===e.trim().length)return;let a=e.replace(r,"");if(null==(t=navigator.clipboard)?void 0:t.writeText)try{await navigator.clipboard.writeText(a);return}catch(e){}let n=document.createElement("textarea");n.value=a,n.style.position="fixed",n.style.left="-9999px",n.style.top="-9999px",n.style.opacity="0",document.body.appendChild(n),n.focus(),n.select();try{document.execCommand("copy")}finally{document.body.removeChild(n)}}},76471:(e,t,a)=>{"use strict";a.d(t,{Ej:()=>c,Jd:()=>i,Mq:()=>d,rH:()=>o});var r=a(95155),n=a(12115),s=a(18955),l=a(48481);let i="bg-transparent border-2 border-muted-foreground",o="status.unknown";function d(e,t){return!0===t&&"ready"===e}let c=(0,n.memo)(function(e){let{status:t,label:a,waitingKind:n,unclassified:c}=e,u=(0,s.c)("common"),m=d(t,c);return(0,r.jsx)(l.m,{"data-testid":"status-indicator",status:t,label:m?null!=a?a:u(o):a,waitingKind:n,size:"lg",className:m?i:void 0,"data-unclassified":m?"true":void 0})})},80488:(e,t,a)=>{Promise.resolve().then(a.bind(a,17442))}},e=>{e.O(0,[6809,4909,2770,2619,8407,5449,8606,8441,1255,7358],()=>e(e.s=80488)),_N_E=e.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8898],{9219:(e,t,s)=>{"use strict";s.d(t,{k:()=>l});var n=s(95155),a=s(12115),i=s(48407),r=s(87531);function l(e){let{onRefresh:t,enabled:s=!0,className:l,children:o}=e,{containerRef:c,pullDistance:d,isRefreshing:u,isPulling:m}=function(e){let{onRefresh:t,enabled:s=!0,threshold:n=64,maxPull:i=96,resistance:r=.5}=e,l=(0,a.useRef)(null),[o,c]=(0,a.useState)(0),[d,u]=(0,a.useState)(!1),[m,h]=(0,a.useState)(!1),x=(0,a.useRef)(null),f=(0,a.useRef)(0),g=(0,a.useRef)(!1);g.current=d;let p=(0,a.useCallback)(()=>{x.current=null,f.current=0,c(0),h(!1)},[]),b=(0,a.useCallback)(e=>{if(!s||g.current)return;let t=l.current;t&&!(t.scrollTop>0)&&(x.current=e.touches[0].clientY,f.current=0)},[s]),v=(0,a.useCallback)(e=>{if(null===x.current)return;let t=l.current;if(!t)return;if(t.scrollTop>0)return void p();let s=e.touches[0].clientY-x.current;if(s<=0){0!==f.current&&(f.current=0,c(0),h(!1));return}e.cancelable&&e.preventDefault();let n=Math.min(s*r,i);f.current=n,c(n),h(!0)},[r,i,p]),y=(0,a.useCallback)(async()=>{u(!0),h(!1),c(n);try{await Promise.resolve(t())}finally{u(!1),c(0)}},[t,n]),w=(0,a.useCallback)(()=>{if(null===x.current)return;let e=f.current>=n&&!g.current;x.current=null,f.current=0,e?y():(c(0),h(!1))},[n,y]);return(0,a.useEffect)(()=>{let e=l.current;if(e)return e.addEventListener("touchstart",b,{passive:!0}),e.addEventListener("touchmove",v,{passive:!1}),e.addEventListener("touchend",w,{passive:!0}),e.addEventListener("touchcancel",w,{passive:!0}),()=>{e.removeEventListener("touchstart",b),e.removeEventListener("touchmove",v),e.removeEventListener("touchend",w),e.removeEventListener("touchcancel",w)}},[b,v,w]),{containerRef:l,pullDistance:o,isRefreshing:d,isPulling:m}}({onRefresh:t,enabled:s,threshold:64}),h=u||d>0,x=u?1:Math.min(d/64,1);return(0,n.jsxs)("div",{ref:c,className:(0,r.cn)("relative overflow-auto",l),style:{overscrollBehaviorY:"contain"},"data-testid":"pull-to-refresh",children:[(0,n.jsx)("div",{className:"pointer-events-none absolute inset-x-0 top-0 z-10 flex justify-center",style:{transform:"translateY(".concat(h?Math.max(d-24,8):-32,"px)"),opacity:x,transition:m?"none":"transform 0.2s ease-out, opacity 0.2s ease-out"},"data-testid":"pull-to-refresh-indicator",role:"status","aria-hidden":!u,children:(0,n.jsx)(i.y$,{size:"sm",variant:"accent"})}),(0,n.jsx)("div",{style:{transform:h?"translateY(".concat(d,"px)"):void 0,transition:m?"none":"transform 0.2s ease-out"},children:o})]})}},75676:(e,t,s)=>{"use strict";s.d(t,{jg:()=>i,kQ:()=>r,mR:()=>c,mS:()=>o,wf:()=>n});let n="terminal",a=new Set(["terminal","chat"]);function i(e){return"string"==typeof e&&a.has(e)}let r={data:null,messageId:null,visible:!1,answering:!1},l={mode:"split",mobileActivePane:"terminal",leftPaneTab:"history",splitRatio:.5,leftPaneCollapsed:!1,activityBar:{active:"files"},historyPane:{visible:!0,width:25,collapsed:!1}},o={type:null,message:null,retryable:!1,retryCount:0};function c(){return{phase:"idle",prompt:{...r},layout:{...l},error:{...o},messages:[],wsConnected:!1}}},80003:(e,t,s)=>{"use strict";s.d(t,{A:()=>n});let n=(0,s(71847).A)("list",[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]])},87047:(e,t,s)=>{Promise.resolve().then(s.bind(s,89569))},89569:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>ec});var n=s(95155),a=s(12115),i=s(52619),r=s.n(i),l=s(18955),o=s(20562),c=s(8803),d=s(9219),u=s(37586),m=s(22479),h=s(54485),x=s(29260),f=s(83051),g=s(14006),p=s(73333),b=s(2954),v=s(48407),y=s(32771),w=s(308),j=s(80635),k=s(52407);function N(){let{signals:e}=(0,k.Fx)();return(0,a.useMemo)(()=>({offline:(0,k.sV)(e),reachable:(0,k._X)(e)}),[e])}var A=s(66966);let C=Object.freeze({enabled:!1,expiresAt:null});var M=s(81507),S=s(2317),I=s(75676),L=s(63881),P=s(8355),E=s(80344),T=s(38606),R=s(76471),_=s(54014),D=s(55449),z=s(67149),F=s(68394);let U=[{mode:"chat",labelKey:"surfaceMode.showChat",icon:u.A},{mode:"terminal",labelKey:"surfaceMode.showTerminal",icon:m.A}];function K(e){return"flex h-7 w-7 shrink-0 items-center justify-center rounded transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-ring ".concat(e?"bg-accent-500/15 text-accent-600 dark:text-accent-400":"text-muted-foreground hover:bg-muted hover:text-foreground")}let B=()=>{},O=(0,a.memo)(function(e){return e.connectivity?(0,n.jsx)(Y,{...e,connectivity:e.connectivity}):(0,n.jsx)(H,{...e})});function H(e){let t=N();return(0,n.jsx)(Y,{...e,connectivity:t})}function Y(e){var t,s,i,o,c,d,u;let{worktree:m,enabled:k,connectivity:N,className:O=""}=e,H=(0,l.c)("common"),Y=(0,l.c)("worktree"),V=(0,a.useMemo)(()=>{var e;return m.agentInstances&&m.agentInstances.length>0?m.agentInstances:(0,_.lu)(null!=(e=m.selectedAgents)?e:(0,D.sA)())},[m]),[q,W]=(0,a.useState)(null),J=null!=(s=V.find(e=>e.id===q))?s:V[0],Q=null==J?void 0:J.id,G=null!=(i=null==J?void 0:J.cliTool)?i:"claude",X=null!=Q?Q:G,{surfaceMode:$,setSurfaceMode:Z}=function(e){let{value:t,setValue:s}=(0,S.V)({key:"".concat("commandmate.sessions.tileSurfaceMode-").concat(e),defaultValue:"chat",validate:I.jg,serialize:e=>e,deserialize:e=>e});return{surfaceMode:t,setSurfaceMode:(0,a.useCallback)(e=>s(e),[s])}}(m.id),{visible:ee,toggle:et}=(0,M.TG)(M.jt),es="terminal"===$,en=es&&ee,[ea,ei]=(0,a.useState)(null),[er,el]=(0,a.useState)(null),eo=(0,L.b4)(ea,er,240),{terminal:ec,prompt:ed,refresh:eu,setAutoScroll:em}=(0,y.NK)({worktreeId:m.id,cliToolId:G,instanceId:Q,enabled:k,cadence:z.sD}),{messages:eh,isLoading:ex,refresh:ef}=(0,w.Md)({worktreeId:m.id,cliToolId:G,instanceId:Q,enabled:k&&(!es||ee),cadence:z.WT}),eg=(0,a.useCallback)((e,t)=>E.y.sendMessage(m.id,e,t),[m.id]),{messages:ep,sendOptimistic:eb,retry:ev,discard:ey}=(0,j.v4)({worktreeId:m.id,serverMessages:eh,sendFn:eg,onSent:ef,connectivity:N}),ew=(0,a.useMemo)(()=>(function(e,t){let s=e=>{var s;return void 0!==e.optimisticState&&(null!=(s=e.instanceId)?s:e.cliToolId)!==t};return e.some(s)?e.filter(e=>!s(e)):e})(ep,X),[ep,X]),[ej,ek]=(0,a.useState)(null),eN=(0,a.useCallback)(()=>ek(null),[]),eA=(0,a.useCallback)(e=>{let t=ey(e);t&&ek(t)},[ey]),eC=(0,a.useCallback)(()=>{eu()},[eu]),eM=function(e){var t;let{worktree:s,cliToolId:n,instanceId:i}=e,r=null==(t=(0,A.rC)())?void 0:t.refresh,l=s.id,o=(0,a.useMemo)(()=>(function(e,t){var s;let n=null==(s=e.autoYesByInstance)?void 0:s[t];return n&&!0===n.enabled?{enabled:!0,expiresAt:"number"==typeof n.expiresAt?n.expiresAt:null}:C})(s,i),[s,i]),[c,d]=(0,a.useState)(null),u=(0,a.useRef)(s);u.current=s;let m=null===c||c.instanceId!==i||function(e,t,s){let n=t.enabled===e.value.enabled&&(!t.enabled||t.expiresAt===e.value.expiresAt),a=null!==e.settledRow&&s!==e.settledRow;return n||a}(c,o,s)?null:c;(0,a.useEffect)(()=>{null!==c&&null===m&&d(null)},[c,m]);let h=(0,a.useCallback)(async e=>{let t;try{let s=await fetch("/api/worktrees/".concat(encodeURIComponent(l),"/auto-yes"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({enabled:e.enabled,cliToolId:n,instanceId:i,duration:e.duration,stopPattern:e.stopPattern})});if(!s.ok)return;let a=await s.json(),r=!0===a.enabled;t={enabled:r,expiresAt:r&&"number"==typeof a.expiresAt?a.expiresAt:null}}catch(e){return}let s={instanceId:i,value:t,settledRow:null};d(s);try{await (null==r?void 0:r())}catch(e){}d(e=>e===s?{...s,settledRow:u.current}:e)},[l,n,i,r]),x=m?m.value:o;return{enabled:x.enabled,expiresAt:x.expiresAt,toggle:h}}({worktree:m,cliToolId:G,instanceId:X}),eS=(0,a.useMemo)(()=>({isRunning:ec.isRunning,attaching:ec.attaching,sessionStatus:ec.sessionStatus,isThinking:ec.isThinking,isPromptWaiting:ed.visible,promptData:ed.data,isSelectionListActive:ec.isSelectionListActive,isPagerActive:ec.isPagerActive,isDismissablePanelActive:ec.isDismissablePanelActive,isUnclassifiedActive:ec.isUnclassifiedActive}),[ec.isRunning,ec.attaching,ec.sessionStatus,ec.isThinking,ec.isSelectionListActive,ec.isPagerActive,ec.isDismissablePanelActive,ec.isUnclassifiedActive,ed.visible,ed.data]),eI=(0,a.useCallback)(e=>Z(e),[Z]),eL=(0,a.useMemo)(()=>({isLoading:ex,onRetryPending:ev,onDiscardPending:eA,onInsertToMessage:ek}),[ex,ev,eA]),{compactTuiLayoutPadding:eP,preservePaintedPanelRows:eE}=(0,a.useMemo)(()=>(0,F.EK)(G),[G]),eT="opencode"===G||"copilot"===G,eR=(u=m.id,"session-tile-history-".concat(u)),e_=(0,a.useCallback)(e=>{W(e.target.value)},[]),eD=null!=(o=m.branch)?o:m.name,ez=null!=(c=m.repositoryDisplayName)?c:m.repositoryName,eF=Q?null==(t=m.sessionStatusByInstance)?void 0:t[Q]:void 0,eU=(0,T.kA)(eF),eK=(0,R.Mq)(eU,(0,T.px)(eF));return(0,n.jsxs)("section",{className:"flex h-full min-w-0 flex-col overflow-hidden rounded-lg border border-border bg-surface shadow-sm ".concat(O),"data-testid":"session-tile-".concat(m.id),"data-enabled":k?"true":"false","aria-label":H("sessions.tileAriaLabel",{branch:eD}),children:[(0,n.jsxs)("header",{className:"flex shrink-0 items-center gap-2 border-b border-border px-3 py-2",children:[(0,n.jsx)(v.md,{status:eU,size:"sm",label:H(eK?R.rH:"status.".concat(eU)),className:eK?R.Jd:void 0,"data-unclassified":eK?"true":void 0}),(0,n.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,n.jsx)("div",{className:"truncate text-xs text-muted-foreground",children:ez}),(0,n.jsx)(r(),{href:"/worktrees/".concat(m.id),className:"block truncate text-sm font-medium text-foreground underline-offset-2 hover:text-accent-600 hover:underline focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring dark:hover:text-accent-400","data-testid":"session-tile-branch-".concat(m.id),title:eD,children:eD})]}),V.length>1&&(0,n.jsx)("select",{value:null!=(d=null==J?void 0:J.id)?d:"",onChange:e_,className:"max-w-[9rem] shrink-0 rounded-md border border-border bg-surface px-2 py-1 text-xs text-muted-foreground transition-colors hover:text-foreground focus:outline-none focus:ring-2 focus:ring-ring","data-testid":"session-tile-instance-".concat(m.id),"aria-label":H("sessions.tileInstanceAriaLabel"),children:V.map(e=>(0,n.jsx)("option",{value:e.id,children:(0,_.sw)(e)},e.id))}),es&&(0,n.jsx)("button",{type:"button",onClick:et,"aria-pressed":ee,"aria-expanded":ee,"aria-controls":eR,"aria-label":ee?Y("terminal.hideHistory"):Y("terminal.showHistory"),title:ee?Y("terminal.hideHistory"):Y("terminal.showHistory"),className:K(ee),"data-testid":"session-tile-history-toggle-".concat(m.id),children:(0,n.jsx)(h.A,{size:14,"aria-hidden":"true"})}),(0,n.jsx)("div",{role:"group","aria-label":Y("surfaceMode.groupLabelMobile"),className:"flex shrink-0 items-center gap-0.5 rounded-md border border-border p-0.5","data-testid":"session-tile-surface-mode-".concat(m.id),children:U.map(e=>{let{mode:t,labelKey:s,icon:a}=e,i=$===t,r=Y(s);return(0,n.jsx)("button",{type:"button",onClick:()=>Z(t),"aria-pressed":i,"aria-label":r,title:r,className:K(i),"data-testid":"session-tile-surface-".concat(t,"-").concat(m.id),children:(0,n.jsx)(a,{size:14,"aria-hidden":"true"})},t)})})]}),(0,n.jsx)("div",{ref:ei,className:"min-w-0 flex-1 overflow-hidden ".concat("min-h-[15rem]"),"data-testid":"session-tile-body-".concat(m.id),children:k&&es?(0,n.jsxs)("div",{className:"flex h-full min-h-0 min-w-0 flex-col","data-testid":"session-tile-terminal-stack-".concat(m.id),children:[(0,n.jsx)("div",{className:"relative min-w-0 overflow-hidden ".concat(en?"flex-[3_3_0%] min-h-[8.5rem]":"min-h-0 flex-1"),"data-testid":"session-tile-terminal-".concat(m.id),children:(0,n.jsx)(g.D,{output:ec.output,isActive:ec.isRunning,attaching:ec.attaching,isThinking:ec.isThinking,autoScroll:ec.autoScroll,onScrollChange:em,disableAutoFollow:eT,compactTuiLayoutPadding:eP,preservePaintedPanelRows:eE,wrapMode:F.Wq.wrapMode,density:F.Wq.density})}),en&&(0,n.jsx)("div",{id:eR,className:"min-w-0 overflow-hidden border-t border-border ".concat("flex-[2_2_0%] min-h-[6.5rem]"),"data-testid":"session-tile-history-".concat(m.id),children:(0,n.jsx)(f.bl,{messages:ew,worktreeId:m.id,worktreePath:m.path,cliToolId:G,isLoading:ex,onFilePathClick:B,onInsertToMessage:ek,onRetryPending:ev,onDiscardPending:eA,className:"h-full"})})]}):k?(0,n.jsx)(x.wY,{messages:ew,worktreeId:m.id,worktreePath:m.path,cliToolId:G,instanceId:Q,live:eS,frame:ec.output,onKeysSent:eu,onSurfaceModeChange:eI,compact:!0,history:eL}):(0,n.jsx)("div",{className:"h-full","data-testid":"session-tile-placeholder-".concat(m.id),"aria-hidden":"true"})}),k&&(0,n.jsx)("div",{ref:el,className:"shrink-0 border-t border-border p-2","data-testid":"session-tile-composer-".concat(m.id),children:(0,n.jsx)(p.E,{worktreeId:m.id,cliToolId:G,instanceId:X,isSessionRunning:ec.isRunning,onOptimisticSend:eb,onMessageSent:eC,pendingInsertText:ej,onInsertConsumed:eN,heightScope:P.CM,maxHeight:eo,autoYesSlot:(0,n.jsx)(b.T,{enabled:eM.enabled,expiresAt:eM.expiresAt,onToggle:eM.toggle,lastAutoResponse:null,cliToolName:G,inline:!0})})})]})}let V=(0,a.memo)(function(e){let{worktree:t,connectivity:s}=e,{ref:i,inViewport:r}=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{rootMargin:t,threshold:s}=e,[n,i]=(0,a.useState)(!1),[r,l]=(0,a.useState)(null),o=(0,a.useCallback)(e=>{l(e)},[]);return(0,a.useEffect)(()=>{if("undefined"==typeof IntersectionObserver)return void i(!0);if(!r)return;let e=new IntersectionObserver(e=>{let t=e[e.length-1];t&&i(t.isIntersecting)},{rootMargin:t,threshold:s});return e.observe(r),()=>e.disconnect()},[r,t,s]),{ref:o,inViewport:n}}({rootMargin:"560px"});return(0,n.jsx)("div",{ref:i,className:"min-w-0 ".concat("h-[35rem]"),children:(0,n.jsx)(O,{worktree:t,enabled:r,connectivity:s})})}),q=(0,a.memo)(function(e){let{worktrees:t}=e,s=N();return(0,n.jsx)("div",{className:"grid grid-cols-1 gap-4 xl:grid-cols-2","data-testid":"sessions-tile-grid",children:t.map(e=>(0,n.jsx)(V,{worktree:e,connectivity:s},e.id))})});var W=s(80003);let J=(0,s(71847).A)("layout-grid",[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]]),Q=["list","tile"];function G(e){return"string"==typeof e&&Q.includes(e)}let X=[{mode:"list",labelKey:"sessions.viewMode.list",icon:W.A},{mode:"tile",labelKey:"sessions.viewMode.tile",icon:J}],$=(0,a.memo)(function(e){let{value:t,onChange:s}=e,a=(0,l.c)("common");return(0,n.jsx)("div",{className:"flex shrink-0 items-center gap-1 rounded-md border border-input bg-surface p-0.5",role:"group","aria-label":a("sessions.viewMode.groupAriaLabel"),"data-testid":"sessions-view-mode",children:X.map(e=>{let{mode:i,labelKey:r,icon:l}=e,o=t===i;return(0,n.jsx)("button",{type:"button",onClick:()=>s(i),"aria-pressed":o,"aria-label":a(r),title:a(r),"data-testid":"sessions-view-mode-".concat(i),className:"rounded p-1.5 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring ".concat(o?"bg-accent-100 text-accent-700 dark:bg-accent-900/30 dark:text-accent-400":"text-muted-foreground hover:text-foreground"),children:(0,n.jsx)(l,{size:16,"aria-hidden":"true"})},i)})})});var Z=s(38218),ee=s(50857),et=s(7636),es=s(83012);let en=[{key:"repositoryName",labelKey:"sort.repositoryName"},{key:"status",labelKey:"sort.status"},{key:"lastSent",labelKey:"sort.lastSent"}],ea={lastSent:"desc",updatedAt:"desc"},ei={ready:0,in_progress:1,in_review:2,done:3};function er(e){let{status:t,label:s,unclassified:a}=e,i=(0,l.c)("common"),r=(0,R.Mq)(t,a),o="".concat(s,": ").concat(i(r?R.rH:"status.".concat(t)));return(0,n.jsx)(v.md,{status:t,size:"md",label:o,className:r?R.Jd:void 0,"data-unclassified":r?"true":void 0})}let el={ready:"worktreeStatus.ready",in_progress:"worktreeStatus.inProgress",in_review:"worktreeStatus.inReview",done:"worktreeStatus.done"},eo={done:"bg-success-subtle text-success-foreground",in_review:"bg-info-subtle text-info-foreground",in_progress:"bg-accent-100 dark:bg-accent-900/30 text-accent-700 dark:text-accent-400"};function ec(){let e=(0,l.c)("common"),t=(0,l.c)("worktree"),s=(0,Z.a)(),{worktrees:i,isLoading:u,error:m,refresh:h}=(0,A.Fn)(),x=i.length>0,[f,g]=(0,a.useState)(""),[p,b]=(0,a.useState)("lastSent"),[y,w]=(0,a.useState)("desc"),{viewMode:j,setViewMode:k}=function(){let{value:e,setValue:t}=(0,S.V)({key:"mcbd-sessions-view-mode",defaultValue:"list",validate:G,serialize:e=>e,deserialize:e=>e});return{viewMode:e,setViewMode:(0,a.useCallback)(e=>t(e),[t])}}(),N="tile"===j;(0,a.useEffect)(()=>{(0,D.qD)()},[]);let C=(0,a.useMemo)(()=>{let e=i;if(f){let t=f.toLowerCase();e=e.filter(e=>{var s,n;return e.name.toLowerCase().includes(t)||e.repositoryName.toLowerCase().includes(t)||null!=(n=null==(s=e.repositoryDisplayName)?void 0:s.toLowerCase().includes(t))&&n})}let t=[...e];return t.sort((e,t)=>{var s,n,a,i,r,l,o,c;let d=0;switch(p){case"lastSent":{let s=(0,et.nO)(e.lastUserMessageAt,t.lastUserMessageAt);if(!e.lastUserMessageAt&&!t.lastUserMessageAt)return 0;if(!e.lastUserMessageAt)return 1;if(!t.lastUserMessageAt)return -1;d=s;break}case"repositoryName":{let a=(null!=(s=e.repositoryDisplayName)?s:e.repositoryName).toLowerCase(),i=(null!=(n=t.repositoryDisplayName)?n:t.repositoryName).toLowerCase();0===(d=a.localeCompare(i))&&(d=e.name.toLowerCase().localeCompare(t.name.toLowerCase()));break}case"status":if(0==(d=(null!=(i=ei[null!=(a=e.status)?a:""])?i:4)-(null!=(l=ei[null!=(r=t.status)?r:""])?l:4))){let s=(null!=(o=e.repositoryDisplayName)?o:e.repositoryName).toLowerCase(),n=(null!=(c=t.repositoryDisplayName)?c:t.repositoryName).toLowerCase();d=s.localeCompare(n)}break;default:d=0}return("lastSent"===p?"desc"===y:"asc"===y)?d:-d}),t},[i,f,p,y]),M=(0,a.useCallback)(e=>{g(e.target.value)},[]),I=(0,a.useCallback)(e=>{var t;b(e),w(null!=(t=ea[e])?t:"asc")},[]),L=(0,a.useCallback)(()=>{w(e=>"asc"===e?"desc":"asc")},[]);return(0,n.jsx)(n.Fragment,{children:(0,n.jsxs)(d.k,{onRefresh:h,enabled:s,className:"".concat(N?"w-full px-4 sm:px-6 lg:px-8":"container-custom"," py-8 h-full"),children:[(0,n.jsxs)("div",{className:"mb-6",children:[(0,n.jsx)("h1",{className:"text-2xl font-bold text-foreground mb-2",children:e("sessions.title")}),(0,n.jsx)("p",{className:"text-sm text-muted-foreground",children:e("sessions.description")})]}),(0,n.jsxs)("div",{className:"mb-6 flex items-center gap-3",children:[(0,n.jsx)(v.pd,{type:"text",placeholder:e("sessions.filterPlaceholder"),value:f,onChange:M,className:"max-w-md flex-1","data-testid":"sessions-filter","aria-label":e("sessions.filterAriaLabel"),inputMode:"search",enterKeyHint:"search"}),(0,n.jsxs)(v.l6,{value:p,onValueChange:I,children:[(0,n.jsx)(v.bq,{className:"w-40","data-testid":"sessions-sort-select","aria-label":e("sessions.sortByAriaLabel"),children:(0,n.jsx)(v.yv,{})}),(0,n.jsx)(v.gC,{children:en.map(t=>(0,n.jsx)(v.eb,{value:t.key,children:e(t.labelKey)},t.key))})]}),(0,n.jsx)("button",{type:"button",onClick:L,"data-testid":"sessions-sort-direction","aria-label":"asc"===y?e("sessions.sortAscending"):e("sessions.sortDescending"),className:"rounded-md border border-input bg-surface p-2 text-muted-foreground transition-colors hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:"asc"===y?(0,n.jsx)(o.A,{size:16,"aria-hidden":"true"}):(0,n.jsx)(c.A,{size:16,"aria-hidden":"true"})}),(0,n.jsx)($,{value:j,onChange:k})]}),x?(0,n.jsxs)(n.Fragment,{children:[m&&(0,n.jsx)("div",{className:"mb-4 rounded-md border border-danger-border bg-danger-subtle px-3 py-2 text-sm text-danger-foreground",role:"status","data-testid":"sessions-error-banner",children:e("sessions.refreshError",{message:m.message})}),N?0===C.length?(0,n.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"sessions-empty",children:e("sessions.noMatching")}):(0,n.jsx)(q,{worktrees:C}):(0,n.jsx)("div",{className:"space-y-2","data-testid":"sessions-list",children:0===C.length?(0,n.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"sessions-empty",children:e("sessions.noMatching")}):C.map((s,a)=>{var i,l,o,c;let d=null!=(i=s.selectedAgents)?i:(0,D.sA)(),u=s.lastUserMessage?s.lastUserMessage.replace(/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x9F]/g,"").replace(/[\u200B-\u200F\u2028-\u202F\uFEFF\u061C]/g,"").replace(/[\r\n\t]/g," ").replace(/\s+/g," ").trim():null,m=s.lastUserMessageAt?(0,es.Fx)(String(s.lastUserMessageAt)):null,h=d.map(e=>{var t;let n=null==(t=s.sessionStatusByCli)?void 0:t[e];return{agent:e,status:(0,T.kA)(n),unclassified:(0,T.px)(n)}}),x=h.filter(e=>(0,ee.Qo)(e.status)||e.unclassified),f=h.length-x.length,g=d.some(e=>{var t;let n=(0,T.kA)(null==(t=s.sessionStatusByCli)?void 0:t[e]);return"running"===n||"generating"===n});return(0,n.jsxs)(r(),{href:"/worktrees/".concat(s.id),style:{animationDelay:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:40,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10;if(Number.isFinite(e)&&!(e<=0)&&!(e>=s))return"".concat(e*t,"ms")}(a)},className:"block bg-surface rounded-lg p-4 border transition-colors ".concat(g?"border-accent-500/40 shadow-[0_0_16px_-4px_rgb(var(--accent-500)/0.45)] hover:border-accent-400":"border-border shadow-sm hover:border-accent-300 dark:hover:border-accent-700"," ").concat("animate-in fade-in-0 slide-in-from-bottom-2 fill-mode-backwards duration-300"),"data-testid":"session-item-".concat(s.id),children:[(0,n.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,n.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,n.jsx)("div",{className:"text-sm font-medium text-foreground truncate",children:null!=(l=s.repositoryDisplayName)?l:s.repositoryName}),(0,n.jsx)("div",{className:"text-xs text-muted-foreground truncate",children:s.name})]}),(0,n.jsxs)("div",{className:"flex items-center gap-2 ml-4 flex-shrink-0","data-testid":"session-agents-".concat(s.id),children:[x.map(e=>{let{agent:t,status:s,unclassified:a}=e;return(0,n.jsxs)("div",{className:"flex items-center gap-1","data-testid":"session-agent-".concat(t),children:[(0,n.jsx)(er,{status:s,label:(0,_.oo)(t),unclassified:a}),(0,n.jsx)("span",{className:"text-xs text-muted-foreground",children:(0,_.oo)(t)})]},t)}),f>0&&(0,n.jsxs)("div",{className:"flex items-center gap-1","data-testid":"session-idle-cluster-".concat(s.id),"aria-label":e("sessions.idleAgents",{count:f}),children:[(0,n.jsx)(v.md,{status:"idle",size:"sm","aria-hidden":!0,title:void 0}),(0,n.jsxs)("span",{className:"text-xs text-muted-foreground tabular-nums",children:["+",f]})]})]})]}),s.description&&(0,n.jsx)("div",{className:"mt-2",children:(0,n.jsx)("p",{className:"text-xs text-muted-foreground line-clamp-2 whitespace-pre-wrap",children:s.description})}),s.status&&(0,n.jsx)("div",{className:"mt-2",children:(0,n.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium rounded ".concat(null!=(c=eo[null!=(o=s.status)?o:""])?c:"bg-muted text-muted-foreground"),children:function(e,t){if(!e)return"";let s=el[e];return s?t(s):e}(s.status,t)})}),u&&(0,n.jsxs)("div",{className:"mt-2 flex items-center gap-2","data-testid":"session-message-".concat(s.id),children:[(0,n.jsx)("span",{className:"text-xs text-muted-foreground truncate min-w-0 flex-1","data-testid":"session-message-text-".concat(s.id),title:u,children:u}),m&&(0,n.jsx)("span",{className:"text-xs text-muted-foreground flex-shrink-0 whitespace-nowrap tabular-nums","data-testid":"session-time-".concat(s.id),children:m})]})]},s.id)})})]}):(0,n.jsxs)(n.Fragment,{children:[u&&(0,n.jsx)("div",{className:"space-y-2","data-testid":"sessions-loading",role:"status","aria-label":e("sessions.loadingAriaLabel"),children:[0,1,2].map(e=>(0,n.jsxs)("div",{className:"block bg-surface rounded-lg p-4 border border-border shadow-sm",children:[(0,n.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,n.jsxs)("div",{className:"min-w-0 flex-1 space-y-1.5",children:[(0,n.jsx)(v.EA,{className:"h-4 w-40 max-w-full"}),(0,n.jsx)(v.EA,{className:"h-3 w-56 max-w-full"})]}),(0,n.jsx)(v.EA,{className:"ml-4 h-3 w-16 flex-shrink-0"})]}),(0,n.jsxs)("div",{className:"mt-3 flex items-center gap-2",children:[(0,n.jsx)(v.EA,{className:"h-3 min-w-0 flex-1"}),(0,n.jsx)(v.EA,{className:"h-3 w-10 flex-shrink-0"})]})]},e))}),!u&&m&&(0,n.jsx)("div",{className:"text-danger-foreground","data-testid":"sessions-error",children:e("sessions.loadError",{message:m.message})}),!u&&!m&&(0,n.jsx)("div",{className:"text-muted-foreground py-8 text-center","data-testid":"sessions-empty",children:f?e("sessions.noMatching"):e("sessions.empty")})]})]})})}}},e=>{e.O(0,[6809,4909,2770,2619,8566,6322,3778,8407,2407,344,5449,6966,8606,4768,2039,7705,8441,1255,7358],()=>e(e.s=87047)),_N_E=e.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[11,66,74,263,341,532,543,640,836,865,890,960,1099,1123,1158,1164,1274,1295,1310,1317,1327,1337,1360,1363,1377,1421,1437,1523,1645,1652,1745,1796,1972,2017,2046,2117,2132,2207,2260,2344,2360,2464,2548,2609,2786,2852,2893,3002,3175,3350,3657,3685,3792,3797,3845,3965,3969,3990,4016,4035,4042,4199,4225,4240,4275,4468,4476,4594,4614,4748,4767,4779,4907,4961,4985,5004,5145,5286,5332,5522,5580,5657,5683,5832,6067,6140,6194,6248,6393,6451,6564,6635,6680,6734,6824,6839,6901,7e3,7115,7238,7473,7509,7560,7670,7758,7760,7895,7921,7939,8043,8238,8418,8457,8460,8464,8472,8489,8509,8544,8658,8710,8914,8979,9015,9059,9114,9162,9245,9281,9282,9325,9416,9549,9602,9792,9932,9946,9968],{84441:()=>{}},_=>{_.O(0,[8441,1255,7358],()=>_(_.s=84441)),_N_E=_.O()}]);
|