aimux-cli 0.1.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/README.md +743 -0
- package/bin/aimux +2 -0
- package/dist/agent-events.d.ts +20 -0
- package/dist/agent-events.js +2 -0
- package/dist/agent-events.js.map +1 -0
- package/dist/agent-message-parts.d.ts +17 -0
- package/dist/agent-message-parts.js +31 -0
- package/dist/agent-message-parts.js.map +1 -0
- package/dist/agent-output-parser.d.ts +16 -0
- package/dist/agent-output-parser.js +229 -0
- package/dist/agent-output-parser.js.map +1 -0
- package/dist/agent-tracker.d.ts +9 -0
- package/dist/agent-tracker.js +144 -0
- package/dist/agent-tracker.js.map +1 -0
- package/dist/agent-watcher.d.ts +15 -0
- package/dist/agent-watcher.js +2 -0
- package/dist/agent-watcher.js.map +1 -0
- package/dist/attachment-store.d.ts +35 -0
- package/dist/attachment-store.js +129 -0
- package/dist/attachment-store.js.map +1 -0
- package/dist/builtin-metadata-watchers.d.ts +2 -0
- package/dist/builtin-metadata-watchers.js +275 -0
- package/dist/builtin-metadata-watchers.js.map +1 -0
- package/dist/claude-hooks.d.ts +29 -0
- package/dist/claude-hooks.js +106 -0
- package/dist/claude-hooks.js.map +1 -0
- package/dist/config.d.ts +78 -0
- package/dist/config.js +172 -0
- package/dist/config.js.map +1 -0
- package/dist/context/compactor.d.ts +20 -0
- package/dist/context/compactor.js +212 -0
- package/dist/context/compactor.js.map +1 -0
- package/dist/context/context-bridge.d.ts +67 -0
- package/dist/context/context-bridge.js +471 -0
- package/dist/context/context-bridge.js.map +1 -0
- package/dist/context/context-file.d.ts +11 -0
- package/dist/context/context-file.js +93 -0
- package/dist/context/context-file.js.map +1 -0
- package/dist/context/history.d.ts +40 -0
- package/dist/context/history.js +108 -0
- package/dist/context/history.js.map +1 -0
- package/dist/daemon.d.ts +39 -0
- package/dist/daemon.js +344 -0
- package/dist/daemon.js.map +1 -0
- package/dist/dashboard-session-registry.d.ts +47 -0
- package/dist/dashboard-session-registry.js +161 -0
- package/dist/dashboard-session-registry.js.map +1 -0
- package/dist/dashboard-state.d.ts +18 -0
- package/dist/dashboard-state.js +26 -0
- package/dist/dashboard-state.js.map +1 -0
- package/dist/dashboard.d.ts +118 -0
- package/dist/dashboard.js +91 -0
- package/dist/dashboard.js.map +1 -0
- package/dist/debug.d.ts +7 -0
- package/dist/debug.js +41 -0
- package/dist/debug.js.map +1 -0
- package/dist/fast-control.d.ts +45 -0
- package/dist/fast-control.js +174 -0
- package/dist/fast-control.js.map +1 -0
- package/dist/hotkeys.d.ts +44 -0
- package/dist/hotkeys.js +118 -0
- package/dist/hotkeys.js.map +1 -0
- package/dist/http-client.d.ts +10 -0
- package/dist/http-client.js +54 -0
- package/dist/http-client.js.map +1 -0
- package/dist/instance-directory.d.ts +32 -0
- package/dist/instance-directory.js +82 -0
- package/dist/instance-directory.js.map +1 -0
- package/dist/instance-registry.d.ts +38 -0
- package/dist/instance-registry.js +208 -0
- package/dist/instance-registry.js.map +1 -0
- package/dist/key-parser.d.ts +30 -0
- package/dist/key-parser.js +272 -0
- package/dist/key-parser.js.map +1 -0
- package/dist/last-used.d.ts +31 -0
- package/dist/last-used.js +93 -0
- package/dist/last-used.js.map +1 -0
- package/dist/main.d.ts +1 -0
- package/dist/main.js +2483 -0
- package/dist/main.js.map +1 -0
- package/dist/metadata-server.d.ts +268 -0
- package/dist/metadata-server.js +1379 -0
- package/dist/metadata-server.js.map +1 -0
- package/dist/metadata-store.d.ts +80 -0
- package/dist/metadata-store.js +87 -0
- package/dist/metadata-store.js.map +1 -0
- package/dist/multiplexer.d.ts +471 -0
- package/dist/multiplexer.js +5714 -0
- package/dist/multiplexer.js.map +1 -0
- package/dist/notification-context.d.ts +18 -0
- package/dist/notification-context.js +68 -0
- package/dist/notification-context.js.map +1 -0
- package/dist/notifications.d.ts +38 -0
- package/dist/notifications.js +111 -0
- package/dist/notifications.js.map +1 -0
- package/dist/notify.d.ts +10 -0
- package/dist/notify.js +62 -0
- package/dist/notify.js.map +1 -0
- package/dist/orchestration-actions.d.ts +76 -0
- package/dist/orchestration-actions.js +310 -0
- package/dist/orchestration-actions.js.map +1 -0
- package/dist/orchestration-dispatcher.d.ts +22 -0
- package/dist/orchestration-dispatcher.js +49 -0
- package/dist/orchestration-dispatcher.js.map +1 -0
- package/dist/orchestration-routing.d.ts +20 -0
- package/dist/orchestration-routing.js +78 -0
- package/dist/orchestration-routing.js.map +1 -0
- package/dist/orchestration.d.ts +26 -0
- package/dist/orchestration.js +110 -0
- package/dist/orchestration.js.map +1 -0
- package/dist/osc-notifications.d.ts +15 -0
- package/dist/osc-notifications.js +180 -0
- package/dist/osc-notifications.js.map +1 -0
- package/dist/paths.d.ts +55 -0
- package/dist/paths.js +259 -0
- package/dist/paths.js.map +1 -0
- package/dist/plugin-runtime.d.ts +46 -0
- package/dist/plugin-runtime.js +180 -0
- package/dist/plugin-runtime.js.map +1 -0
- package/dist/project-events.d.ts +36 -0
- package/dist/project-events.js +63 -0
- package/dist/project-events.js.map +1 -0
- package/dist/project-scanner.d.ts +38 -0
- package/dist/project-scanner.js +243 -0
- package/dist/project-scanner.js.map +1 -0
- package/dist/project-service-manifest.d.ts +18 -0
- package/dist/project-service-manifest.js +56 -0
- package/dist/project-service-manifest.js.map +1 -0
- package/dist/recency.d.ts +2 -0
- package/dist/recency.js +34 -0
- package/dist/recency.js.map +1 -0
- package/dist/recorder.d.ts +14 -0
- package/dist/recorder.js +130 -0
- package/dist/recorder.js.map +1 -0
- package/dist/session-bootstrap.d.ts +45 -0
- package/dist/session-bootstrap.js +436 -0
- package/dist/session-bootstrap.js.map +1 -0
- package/dist/session-message-history.d.ts +27 -0
- package/dist/session-message-history.js +105 -0
- package/dist/session-message-history.js.map +1 -0
- package/dist/session-runtime.d.ts +44 -0
- package/dist/session-runtime.js +56 -0
- package/dist/session-runtime.js.map +1 -0
- package/dist/session-semantics.d.ts +35 -0
- package/dist/session-semantics.js +110 -0
- package/dist/session-semantics.js.map +1 -0
- package/dist/status-detector.d.ts +17 -0
- package/dist/status-detector.js +67 -0
- package/dist/status-detector.js.map +1 -0
- package/dist/statusline-model.d.ts +103 -0
- package/dist/statusline-model.js +177 -0
- package/dist/statusline-model.js.map +1 -0
- package/dist/task-dispatcher.d.ts +63 -0
- package/dist/task-dispatcher.js +210 -0
- package/dist/task-dispatcher.js.map +1 -0
- package/dist/task-workflow.d.ts +13 -0
- package/dist/task-workflow.js +153 -0
- package/dist/task-workflow.js.map +1 -0
- package/dist/tasks.d.ts +60 -0
- package/dist/tasks.js +120 -0
- package/dist/tasks.js.map +1 -0
- package/dist/team.d.ts +28 -0
- package/dist/team.js +91 -0
- package/dist/team.js.map +1 -0
- package/dist/terminal-host.d.ts +10 -0
- package/dist/terminal-host.js +52 -0
- package/dist/terminal-host.js.map +1 -0
- package/dist/threads.d.ts +61 -0
- package/dist/threads.js +200 -0
- package/dist/threads.js.map +1 -0
- package/dist/tmux-doctor.d.ts +47 -0
- package/dist/tmux-doctor.js +112 -0
- package/dist/tmux-doctor.js.map +1 -0
- package/dist/tmux-runtime-manager.d.ts +164 -0
- package/dist/tmux-runtime-manager.js +794 -0
- package/dist/tmux-runtime-manager.js.map +1 -0
- package/dist/tmux-session-transport.d.ts +31 -0
- package/dist/tmux-session-transport.js +115 -0
- package/dist/tmux-session-transport.js.map +1 -0
- package/dist/tmux-statusline.d.ts +17 -0
- package/dist/tmux-statusline.js +166 -0
- package/dist/tmux-statusline.js.map +1 -0
- package/dist/tool-output-watchers.d.ts +10 -0
- package/dist/tool-output-watchers.js +190 -0
- package/dist/tool-output-watchers.js.map +1 -0
- package/dist/tui/render/box.d.ts +1 -0
- package/dist/tui/render/box.js +20 -0
- package/dist/tui/render/box.js.map +1 -0
- package/dist/tui/render/text.d.ts +8 -0
- package/dist/tui/render/text.js +92 -0
- package/dist/tui/render/text.js.map +1 -0
- package/dist/tui/screens/dashboard-renderers.d.ts +23 -0
- package/dist/tui/screens/dashboard-renderers.js +411 -0
- package/dist/tui/screens/dashboard-renderers.js.map +1 -0
- package/dist/tui/screens/overlay-renderers.d.ts +10 -0
- package/dist/tui/screens/overlay-renderers.js +274 -0
- package/dist/tui/screens/overlay-renderers.js.map +1 -0
- package/dist/tui/screens/subscreen-renderers.d.ts +9 -0
- package/dist/tui/screens/subscreen-renderers.js +327 -0
- package/dist/tui/screens/subscreen-renderers.js.map +1 -0
- package/dist/workflow.d.ts +19 -0
- package/dist/workflow.js +111 -0
- package/dist/workflow.js.map +1 -0
- package/dist/worktree.d.ts +23 -0
- package/dist/worktree.js +101 -0
- package/dist/worktree.js.map +1 -0
- package/package.json +70 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export function renderOverlayBox(lines, cols, rows, style = "blue") {
|
|
2
|
+
const boxWidth = Math.max(...lines.map((line) => line.length)) + 4;
|
|
3
|
+
const startRow = Math.floor((rows - lines.length - 2) / 2);
|
|
4
|
+
const startCol = Math.floor((cols - boxWidth) / 2);
|
|
5
|
+
const borderStyle = style === "red" ? "\x1b[41;97m" : "\x1b[44;97m";
|
|
6
|
+
let output = "\x1b7";
|
|
7
|
+
for (let i = 0; i < lines.length + 2; i++) {
|
|
8
|
+
const row = startRow + i;
|
|
9
|
+
output += `\x1b[${row};${startCol}H`;
|
|
10
|
+
if (i === 0 || i === lines.length + 1) {
|
|
11
|
+
output += `${borderStyle}${"─".repeat(boxWidth)}\x1b[0m`;
|
|
12
|
+
}
|
|
13
|
+
else {
|
|
14
|
+
output += `${borderStyle} ${lines[i - 1].padEnd(boxWidth - 2)}\x1b[0m`;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
output += "\x1b8";
|
|
18
|
+
return output;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=box.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"box.js","sourceRoot":"","sources":["../../../src/tui/render/box.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,gBAAgB,CAAC,KAAe,EAAE,IAA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
|
+
export declare function stripAnsi(text: string): string;
|
|
2
|
+
export declare function center(text: string, width: number): string;
|
|
3
|
+
export declare function truncate(text: string, max: number): string;
|
|
4
|
+
export declare function truncatePlain(text: string, max: number): string;
|
|
5
|
+
export declare function truncateAnsi(text: string, max: number): string;
|
|
6
|
+
export declare function wrapText(text: string, width: number): string[];
|
|
7
|
+
export declare function wrapKeyValue(key: string, value: string, width: number): string[];
|
|
8
|
+
export declare function composeTwoPane(left: string[], right: string[], cols: number): string[];
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
export function stripAnsi(text) {
|
|
2
|
+
return text.replace(/\x1b\[[0-9;]*m/g, "");
|
|
3
|
+
}
|
|
4
|
+
export function center(text, width) {
|
|
5
|
+
const pad = Math.max(0, Math.floor((width - stripAnsi(text).length) / 2));
|
|
6
|
+
return " ".repeat(pad) + text;
|
|
7
|
+
}
|
|
8
|
+
export function truncate(text, max) {
|
|
9
|
+
if (text.length <= max)
|
|
10
|
+
return text;
|
|
11
|
+
return text.slice(0, max) + "…";
|
|
12
|
+
}
|
|
13
|
+
export function truncatePlain(text, max) {
|
|
14
|
+
if (text.length <= max)
|
|
15
|
+
return text;
|
|
16
|
+
if (max <= 1)
|
|
17
|
+
return text.slice(0, max);
|
|
18
|
+
return `${text.slice(0, max - 1)}…`;
|
|
19
|
+
}
|
|
20
|
+
export function truncateAnsi(text, max) {
|
|
21
|
+
if (max <= 0)
|
|
22
|
+
return "";
|
|
23
|
+
const plainLength = stripAnsi(text).length;
|
|
24
|
+
const needsEllipsis = plainLength > max;
|
|
25
|
+
const limit = needsEllipsis && max > 1 ? max - 1 : max;
|
|
26
|
+
let visible = 0;
|
|
27
|
+
let out = "";
|
|
28
|
+
for (let i = 0; i < text.length; i++) {
|
|
29
|
+
if (text[i] === "\x1b") {
|
|
30
|
+
const match = text.slice(i).match(/^\x1b\[[0-9;]*m/);
|
|
31
|
+
if (match) {
|
|
32
|
+
out += match[0];
|
|
33
|
+
i += match[0].length - 1;
|
|
34
|
+
continue;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
if (visible >= limit)
|
|
38
|
+
break;
|
|
39
|
+
out += text[i];
|
|
40
|
+
visible += 1;
|
|
41
|
+
}
|
|
42
|
+
if (needsEllipsis)
|
|
43
|
+
out += "…";
|
|
44
|
+
if (out.includes("\x1b["))
|
|
45
|
+
out += "\x1b[0m";
|
|
46
|
+
return out;
|
|
47
|
+
}
|
|
48
|
+
export function wrapText(text, width) {
|
|
49
|
+
const plain = text.trim();
|
|
50
|
+
if (!plain)
|
|
51
|
+
return [""];
|
|
52
|
+
if (width <= 8)
|
|
53
|
+
return [truncatePlain(plain, width)];
|
|
54
|
+
const words = plain.split(/\s+/);
|
|
55
|
+
const lines = [];
|
|
56
|
+
let current = "";
|
|
57
|
+
for (const word of words) {
|
|
58
|
+
const next = current ? `${current} ${word}` : word;
|
|
59
|
+
if (next.length <= width) {
|
|
60
|
+
current = next;
|
|
61
|
+
continue;
|
|
62
|
+
}
|
|
63
|
+
if (current)
|
|
64
|
+
lines.push(current);
|
|
65
|
+
current = word.length > width ? truncatePlain(word, width) : word;
|
|
66
|
+
}
|
|
67
|
+
if (current)
|
|
68
|
+
lines.push(current);
|
|
69
|
+
return lines;
|
|
70
|
+
}
|
|
71
|
+
export function wrapKeyValue(key, value, width) {
|
|
72
|
+
const prefix = `${key}: `;
|
|
73
|
+
const wrapped = wrapText(value, Math.max(8, width - prefix.length));
|
|
74
|
+
return wrapped.map((line, idx) => (idx === 0 ? `${prefix}${line}` : `${" ".repeat(prefix.length)}${line}`));
|
|
75
|
+
}
|
|
76
|
+
export function composeTwoPane(left, right, cols) {
|
|
77
|
+
const leftWidth = Math.max(32, Math.floor(cols * 0.58));
|
|
78
|
+
const rightWidth = Math.max(20, cols - leftWidth - 4);
|
|
79
|
+
const height = Math.max(left.length, right.length);
|
|
80
|
+
const totalWidth = leftWidth + 3 + rightWidth;
|
|
81
|
+
const outerPad = Math.max(0, Math.floor((cols - totalWidth) / 2));
|
|
82
|
+
const out = [];
|
|
83
|
+
for (let i = 0; i < height; i++) {
|
|
84
|
+
const leftLine = truncateAnsi(left[i] ?? "", leftWidth);
|
|
85
|
+
const rightLine = truncateAnsi(right[i] ?? "", rightWidth);
|
|
86
|
+
const leftPad = Math.max(0, leftWidth - stripAnsi(leftLine).length);
|
|
87
|
+
const rightPad = Math.max(0, rightWidth - stripAnsi(rightLine).length);
|
|
88
|
+
out.push(`${" ".repeat(outerPad)}${leftLine}${" ".repeat(leftPad)} │ ${rightLine}${" ".repeat(rightPad)}`);
|
|
89
|
+
}
|
|
90
|
+
return out;
|
|
91
|
+
}
|
|
92
|
+
//# sourceMappingURL=text.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text.js","sourceRoot":"","sources":["../../../src/tui/render/text.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,SAAS,CAAC,IAAY;IACpC,OAAO,IAAI,CAAC,OAAO,CAAC,iBAAiB,EAAE,EAAE,CAAC,CAAC;AAC7C,CAAC;AAED,MAAM,UAAU,MAAM,CAAC,IAAY,EAAE,KAAa;IAChD,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;IAC1E,OAAO,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC;AAChC,CAAC;AAED,MAAM,UAAU,QAAQ,CAAC,IAAY,EAAE,GAAW;IAChD,IAAI,IAAI,CAAC,MAAM,IAAI,GAAG;QAAE,OAAO,IAAI,CAAC;IACpC,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC,GAAG,GAAG,CAAC;AAClC,CAAC;AAED,MAAM,UAAU,aAAa,CAAC,IAAY,EAAE,GAAW;IACrD,IAAI,IAAI,CAAC,MAAM,IAA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S,GAAG,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,EAAE,EAAE,UAAU,CAAC,CAAC;QAC3D,MAAM,OAAO,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC;QACpE,MAAM,QAAQ,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC;QACvE,GAAG,CAAC,IAAI,CAAC,GAAG,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,QAAQ,GAAG,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,MAAM,SAAS,GAAG,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;IAC7G,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { DashboardService, DashboardSession, MainCheckoutInfo, WorktreeGroup } from "../../dashboard.js";
|
|
2
|
+
import { derivedStatusLabel } from "../../dashboard.js";
|
|
3
|
+
type DashboardNavLevel = "worktrees" | "sessions";
|
|
4
|
+
export interface DashboardRenderState {
|
|
5
|
+
sessions: DashboardSession[];
|
|
6
|
+
services: DashboardService[];
|
|
7
|
+
worktreeGroups: WorktreeGroup[];
|
|
8
|
+
hasWorktrees: boolean;
|
|
9
|
+
focusedWorktreePath?: string;
|
|
10
|
+
navLevel: DashboardNavLevel;
|
|
11
|
+
selectedSessionId?: string;
|
|
12
|
+
selectedServiceId?: string;
|
|
13
|
+
runtimeLabel?: string;
|
|
14
|
+
mainCheckout: MainCheckoutInfo;
|
|
15
|
+
detailsPaneVisible: boolean;
|
|
16
|
+
scrollOffset: number;
|
|
17
|
+
derivedStatusLabel: typeof derivedStatusLabel;
|
|
18
|
+
}
|
|
19
|
+
export declare function renderDashboardFrame(state: DashboardRenderState, cols: number, rows: number): {
|
|
20
|
+
frame: string;
|
|
21
|
+
scrollOffset: number;
|
|
22
|
+
};
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,411 @@
|
|
|
1
|
+
import { formatRelativeRecency } from "../../recency.js";
|
|
2
|
+
import { sessionSemanticCompactHint } from "../../session-semantics.js";
|
|
3
|
+
import { center, composeTwoPane, stripAnsi, truncate, wrapKeyValue } from "../render/text.js";
|
|
4
|
+
const STATUS_ICONS = {
|
|
5
|
+
running: "\x1b[33m●\x1b[0m",
|
|
6
|
+
idle: "\x1b[32m●\x1b[0m",
|
|
7
|
+
waiting: "\x1b[36m◉\x1b[0m",
|
|
8
|
+
exited: "\x1b[31m○\x1b[0m",
|
|
9
|
+
offline: "\x1b[2m○\x1b[0m",
|
|
10
|
+
};
|
|
11
|
+
const SERVICE_ICONS = {
|
|
12
|
+
running: "\x1b[32m◆\x1b[0m",
|
|
13
|
+
exited: "\x1b[31m◇\x1b[0m",
|
|
14
|
+
};
|
|
15
|
+
export function renderDashboardFrame(state, cols, rows) {
|
|
16
|
+
const contentWidth = Math.max(72, cols);
|
|
17
|
+
const padBlockLine = (line) => line;
|
|
18
|
+
const centerInBlock = (line) => center(line, contentWidth).slice(0, cols);
|
|
19
|
+
const wrapCommandGroups = (line) => {
|
|
20
|
+
const groups = line
|
|
21
|
+
.trim()
|
|
22
|
+
.split(/\s{2,}/)
|
|
23
|
+
.filter(Boolean);
|
|
24
|
+
const lines = [];
|
|
25
|
+
let current = "";
|
|
26
|
+
for (const group of groups) {
|
|
27
|
+
const next = current ? `${current} ${group}` : group;
|
|
28
|
+
if (stripAnsi(next).length <= contentWidth) {
|
|
29
|
+
current = next;
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
if (current)
|
|
33
|
+
lines.push(current);
|
|
34
|
+
current = group;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
if (current)
|
|
38
|
+
lines.push(current);
|
|
39
|
+
return lines;
|
|
40
|
+
};
|
|
41
|
+
let renderSessionCounter = 0;
|
|
42
|
+
const renderSession = (session, indent) => {
|
|
43
|
+
const num = ++renderSessionCounter;
|
|
44
|
+
const isSelected = state.navLevel === "sessions" && session.id === state.selectedSessionId;
|
|
45
|
+
const prefix = isSelected ? "\x1b[33m▸\x1b[0m " : " ";
|
|
46
|
+
const taskBadge = session.taskDescription ? ` \x1b[2;35m⧫ ${truncate(session.taskDescription, 40)}\x1b[0m` : "";
|
|
47
|
+
const threadBadge = (session.threadUnreadCount ?? 0) > 0 ||
|
|
48
|
+
(session.threadWaitingOnMeCount ?? 0) > 0 ||
|
|
49
|
+
(session.threadWaitingOnThemCount ?? 0) > 0
|
|
50
|
+
? ` \x1b[2;34m💬 ${session.threadUnreadCount ?? 0}/${session.threadWaitingOnMeCount ?? 0}/${session.threadWaitingOnThemCount ?? 0}\x1b[0m`
|
|
51
|
+
: "";
|
|
52
|
+
const pendingBadge = (session.threadPendingCount ?? 0) > 0 ? ` \x1b[2;31m⇢ ${session.threadPendingCount}\x1b[0m` : "";
|
|
53
|
+
const workflowBadge = (session.workflowOnMeCount ?? 0) > 0 ||
|
|
54
|
+
(session.workflowBlockedCount ?? 0) > 0 ||
|
|
55
|
+
(session.workflowFamilyCount ?? 0) > 0
|
|
56
|
+
? ` \x1b[2;35mwf ${session.workflowOnMeCount ?? 0}/${session.workflowBlockedCount ?? 0}/${session.workflowFamilyCount ?? 0}\x1b[0m`
|
|
57
|
+
: "";
|
|
58
|
+
const workflowHint = session.workflowNextAction
|
|
59
|
+
? ` \x1b[2;33m→ ${truncate(session.workflowNextAction, 24)}\x1b[0m`
|
|
60
|
+
: "";
|
|
61
|
+
const attentionBadge = session.attention === "error"
|
|
62
|
+
? " \x1b[31m✗\x1b[0m"
|
|
63
|
+
: session.attention === "needs_input"
|
|
64
|
+
? " \x1b[33m?\x1b[0m"
|
|
65
|
+
: session.attention === "blocked"
|
|
66
|
+
? " \x1b[35m!\x1b[0m"
|
|
67
|
+
: "";
|
|
68
|
+
const unseenBadge = session.unseenCount && session.unseenCount > 0 ? ` \x1b[36m${session.unseenCount}\x1b[0m` : "";
|
|
69
|
+
const lastUsedHint = session.lastUsedAt ? ` \x1b[2m· ${formatRelativeRecency(session.lastUsedAt)}\x1b[0m` : "";
|
|
70
|
+
if (session.remoteInstancePid) {
|
|
71
|
+
const icon = "\x1b[2;36m◈\x1b[0m";
|
|
72
|
+
const ownerTag = `\x1b[2mother tab (PID ${session.remoteInstancePid})\x1b[0m`;
|
|
73
|
+
const identity = session.label ?? session.command;
|
|
74
|
+
const headlineText = session.headline ? ` \x1b[2m· ${truncate(session.headline, 40)}\x1b[0m` : "";
|
|
75
|
+
const remoteRoleTag = session.role ? ` \x1b[2;36m(${session.role})\x1b[0m` : "";
|
|
76
|
+
return `${indent}${prefix}${icon} [${num}] ${identity}${remoteRoleTag}${headlineText}${threadBadge}${pendingBadge}${workflowBadge}${workflowHint}${attentionBadge}${unseenBadge}${lastUsedHint} — ${ownerTag}`;
|
|
77
|
+
}
|
|
78
|
+
const icon = STATUS_ICONS[session.status];
|
|
79
|
+
const statusLabel = state.derivedStatusLabel(session);
|
|
80
|
+
const compactHintValue = session.semantic ? sessionSemanticCompactHint(session.semantic) : null;
|
|
81
|
+
const compactHint = compactHintValue && compactHintValue !== statusLabel ? ` \x1b[2m· ${compactHintValue}\x1b[0m` : "";
|
|
82
|
+
const roleTag = session.role ? ` \x1b[36m(${session.role})\x1b[0m` : "";
|
|
83
|
+
const identity = session.label ?? session.command;
|
|
84
|
+
const headlineText = session.headline ? ` \x1b[2m· ${truncate(session.headline, 50)}\x1b[0m` : "";
|
|
85
|
+
return `${indent}${prefix}${icon} [${num}] ${identity}${roleTag} — ${statusLabel}${compactHint}${headlineText}${taskBadge}${threadBadge}${pendingBadge}${workflowBadge}${workflowHint}${attentionBadge}${unseenBadge}${lastUsedHint}`;
|
|
86
|
+
};
|
|
87
|
+
const renderService = (service, indent) => {
|
|
88
|
+
const isSelected = state.navLevel === "sessions" && service.id === state.selectedServiceId;
|
|
89
|
+
const prefix = isSelected ? "\x1b[33m▸\x1b[0m " : " ";
|
|
90
|
+
const icon = SERVICE_ICONS[service.status];
|
|
91
|
+
const identity = service.label ?? service.command;
|
|
92
|
+
const commandHint = service.foregroundCommand ? ` \x1b[2m· ${truncate(service.foregroundCommand, 22)}\x1b[0m` : "";
|
|
93
|
+
const pidHint = service.pid ? ` \x1b[2m(pid ${service.pid})\x1b[0m` : "";
|
|
94
|
+
const previewHint = service.previewLine ? ` \x1b[2m· ${truncate(service.previewLine, 40)}\x1b[0m` : "";
|
|
95
|
+
const lastUsedHint = service.lastUsedAt ? ` \x1b[2m· ${formatRelativeRecency(service.lastUsedAt)}\x1b[0m` : "";
|
|
96
|
+
return `${indent}${prefix}${icon} ${identity} \x1b[2m[service]\x1b[0m — ${service.status}${commandHint}${pidHint}${previewHint}${lastUsedHint}`;
|
|
97
|
+
};
|
|
98
|
+
const renderWorktreeGrouped = (lines) => {
|
|
99
|
+
const isFocused = (wtPath) => wtPath === state.focusedWorktreePath;
|
|
100
|
+
const wtCursor = "\x1b[33m▸\x1b[0m";
|
|
101
|
+
const wtSessionMap = new Map();
|
|
102
|
+
const wtServiceMap = new Map();
|
|
103
|
+
const mainSessions = [];
|
|
104
|
+
const mainServices = [];
|
|
105
|
+
for (const session of state.sessions) {
|
|
106
|
+
if (!session.worktreePath) {
|
|
107
|
+
mainSessions.push(session);
|
|
108
|
+
}
|
|
109
|
+
else {
|
|
110
|
+
const group = wtSessionMap.get(session.worktreePath) ?? [];
|
|
111
|
+
group.push(session);
|
|
112
|
+
wtSessionMap.set(session.worktreePath, group);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
for (const service of state.services) {
|
|
116
|
+
if (!service.worktreePath) {
|
|
117
|
+
mainServices.push(service);
|
|
118
|
+
}
|
|
119
|
+
else {
|
|
120
|
+
const group = wtServiceMap.get(service.worktreePath) ?? [];
|
|
121
|
+
group.push(service);
|
|
122
|
+
wtServiceMap.set(service.worktreePath, group);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
const focused = isFocused(undefined);
|
|
126
|
+
const prefix = focused && state.navLevel === "worktrees" ? ` ${wtCursor}` : " ";
|
|
127
|
+
const highlight = focused ? "\x1b[1;33m" : "\x1b[1m";
|
|
128
|
+
const mainBranch = state.mainCheckout.branch ? ` \x1b[2m${state.mainCheckout.branch}\x1b[0m` : "";
|
|
129
|
+
const mainLabel = `${state.mainCheckout.name}${mainBranch}`;
|
|
130
|
+
if (mainSessions.length > 0 || mainServices.length > 0) {
|
|
131
|
+
lines.push(`${prefix} ${highlight}${mainLabel}\x1b[0m`);
|
|
132
|
+
for (const session of mainSessions)
|
|
133
|
+
lines.push(renderSession(session, " "));
|
|
134
|
+
for (const service of mainServices)
|
|
135
|
+
lines.push(renderService(service, " "));
|
|
136
|
+
lines.push("");
|
|
137
|
+
}
|
|
138
|
+
else {
|
|
139
|
+
lines.push(`${prefix} ${highlight}${mainLabel}\x1b[0m`);
|
|
140
|
+
}
|
|
141
|
+
const renderedPaths = new Set();
|
|
142
|
+
for (const group of state.worktreeGroups) {
|
|
143
|
+
const sessions = wtSessionMap.get(group.path) ?? [];
|
|
144
|
+
const services = wtServiceMap.get(group.path) ?? [];
|
|
145
|
+
const gFocused = isFocused(group.path);
|
|
146
|
+
const gPrefix = gFocused && state.navLevel === "worktrees" ? ` ${wtCursor}` : " ";
|
|
147
|
+
const gHighlight = gFocused ? "\x1b[1;33m" : "";
|
|
148
|
+
const gReset = gFocused ? "\x1b[0m" : "";
|
|
149
|
+
if (sessions.length > 0 || services.length > 0) {
|
|
150
|
+
lines.push(`${gPrefix} ${gHighlight}\x1b[1m${group.name}\x1b[0m${gReset} \x1b[2m${group.branch}\x1b[0m`);
|
|
151
|
+
for (const session of sessions)
|
|
152
|
+
lines.push(renderSession(session, " "));
|
|
153
|
+
for (const service of services)
|
|
154
|
+
lines.push(renderService(service, " "));
|
|
155
|
+
lines.push("");
|
|
156
|
+
}
|
|
157
|
+
else {
|
|
158
|
+
lines.push(`${gPrefix} \x1b[2m${gHighlight}${group.name}\x1b[0m \x1b[2m${group.branch}\x1b[0m`);
|
|
159
|
+
}
|
|
160
|
+
renderedPaths.add(group.path);
|
|
161
|
+
}
|
|
162
|
+
const orphanPaths = new Set([...Array.from(wtSessionMap.keys()), ...Array.from(wtServiceMap.keys())]);
|
|
163
|
+
for (const path of orphanPaths) {
|
|
164
|
+
if (!path || renderedPaths.has(path))
|
|
165
|
+
continue;
|
|
166
|
+
const sessions = wtSessionMap.get(path) ?? [];
|
|
167
|
+
const services = wtServiceMap.get(path) ?? [];
|
|
168
|
+
const exemplar = sessions[0] ?? services[0];
|
|
169
|
+
const name = exemplar?.worktreeName ?? "unknown";
|
|
170
|
+
const branch = exemplar?.worktreeBranch ?? "unknown";
|
|
171
|
+
lines.push(` \x1b[1m${name}\x1b[0m \x1b[2m${branch}\x1b[0m`);
|
|
172
|
+
for (const session of sessions)
|
|
173
|
+
lines.push(renderSession(session, " "));
|
|
174
|
+
for (const service of services)
|
|
175
|
+
lines.push(renderService(service, " "));
|
|
176
|
+
lines.push("");
|
|
177
|
+
}
|
|
178
|
+
};
|
|
179
|
+
const findFocusLine = (content) => {
|
|
180
|
+
for (let i = 0; i < content.length; i++) {
|
|
181
|
+
const stripped = content[i].replace(/\x1b\[[0-9;]*m/g, "");
|
|
182
|
+
if (stripped.includes("▸"))
|
|
183
|
+
return i;
|
|
184
|
+
}
|
|
185
|
+
return -1;
|
|
186
|
+
};
|
|
187
|
+
const buildHelpLine = () => {
|
|
188
|
+
const selectedSession = state.selectedSessionId
|
|
189
|
+
? state.sessions.find((s) => s.id === state.selectedSessionId)
|
|
190
|
+
: undefined;
|
|
191
|
+
const selectedService = state.selectedServiceId
|
|
192
|
+
? state.services.find((s) => s.id === state.selectedServiceId)
|
|
193
|
+
: undefined;
|
|
194
|
+
const xLabel = selectedService
|
|
195
|
+
? "[x] stop"
|
|
196
|
+
: selectedSession?.status === "offline"
|
|
197
|
+
? "[x] kill"
|
|
198
|
+
: selectedSession?.remoteInstancePid
|
|
199
|
+
? ""
|
|
200
|
+
: selectedSession
|
|
201
|
+
? "[x] stop"
|
|
202
|
+
: "";
|
|
203
|
+
const rLabel = selectedSession && !selectedSession.remoteInstancePid ? " [r] name" : "";
|
|
204
|
+
const enterLabel = selectedService
|
|
205
|
+
? "Enter open"
|
|
206
|
+
: selectedSession?.remoteInstancePid
|
|
207
|
+
? "Enter takeover"
|
|
208
|
+
: selectedSession?.status === "offline"
|
|
209
|
+
? "Enter resume"
|
|
210
|
+
: "Enter focus";
|
|
211
|
+
if (state.sessions.length === 0 && !state.hasWorktrees) {
|
|
212
|
+
return " [u] attention [a] activity [t] threads [i] inbox [Tab] details [c] new agent [v] service [f] fork [S] msg [H] handoff [T] task [o] thread [R] reply [p] plans [g] graveyard [?] help [q] quit ";
|
|
213
|
+
}
|
|
214
|
+
if (state.hasWorktrees && state.navLevel === "sessions") {
|
|
215
|
+
const xPart = xLabel ? ` ${xLabel}` : "";
|
|
216
|
+
return ` ↑↓ items ${enterLabel} Esc back [u] attention [a] activity [t] threads [i] inbox [Tab] details [c] new agent [v] service [f] fork [S] msg [H] handoff [T] task [o] thread [R] reply [m] migrate${xPart}${rLabel} [p] plans [g] graveyard [?] help [q] quit `;
|
|
217
|
+
}
|
|
218
|
+
if (state.hasWorktrees) {
|
|
219
|
+
return ` ↑↓ worktrees Enter step in [u] attention [a] activity [t] threads [i] inbox [Tab] details [c] new agent [v] service [f] fork(step in) [w] worktree [p] plans [g] graveyard [?] help [q] quit `;
|
|
220
|
+
}
|
|
221
|
+
if (state.sessions.length > 0) {
|
|
222
|
+
const xPart = xLabel ? ` ${xLabel}` : "";
|
|
223
|
+
return ` ↑↓ select ${enterLabel} [u] attention [a] activity [t] threads [i] inbox [Tab] details [c] new agent [v] service [f] fork [S] msg [H] handoff [T] task [o] thread [R] reply [w] worktree${xPart}${rLabel} [p] plans [g] graveyard [?] help [q] quit `;
|
|
224
|
+
}
|
|
225
|
+
return " [u] attention [a] activity [t] threads [i] inbox [Tab] details [c] new agent [v] service [f] fork [S] msg [H] handoff [T] task [o] thread [R] reply [w] worktree [p] plans [g] graveyard [?] help [q] quit ";
|
|
226
|
+
};
|
|
227
|
+
const renderSelectedDetailsPanel = (width, height) => {
|
|
228
|
+
const selectedSession = state.selectedSessionId
|
|
229
|
+
? state.sessions.find((session) => session.id === state.selectedSessionId)
|
|
230
|
+
: undefined;
|
|
231
|
+
const selectedService = state.selectedServiceId
|
|
232
|
+
? state.services.find((service) => service.id === state.selectedServiceId)
|
|
233
|
+
: undefined;
|
|
234
|
+
if (!selectedSession && !selectedService) {
|
|
235
|
+
const focusedWorktreePath = state.focusedWorktreePath;
|
|
236
|
+
const focusedSessions = state.sessions.filter((session) => (session.worktreePath ?? undefined) === focusedWorktreePath);
|
|
237
|
+
const focusedServices = state.services.filter((service) => (service.worktreePath ?? undefined) === focusedWorktreePath);
|
|
238
|
+
const worktree = focusedWorktreePath === undefined
|
|
239
|
+
? {
|
|
240
|
+
name: state.mainCheckout.name,
|
|
241
|
+
branch: state.mainCheckout.branch,
|
|
242
|
+
path: "(main checkout)",
|
|
243
|
+
}
|
|
244
|
+
: (state.worktreeGroups.find((group) => group.path === focusedWorktreePath) ?? {
|
|
245
|
+
name: focusedSessions[0]?.worktreeName ?? focusedServices[0]?.worktreeName ?? "Worktree",
|
|
246
|
+
branch: focusedSessions[0]?.worktreeBranch ?? focusedServices[0]?.worktreeBranch ?? "",
|
|
247
|
+
path: focusedWorktreePath,
|
|
248
|
+
});
|
|
249
|
+
const lines = ["\x1b[1mWorktree\x1b[0m"];
|
|
250
|
+
lines.push(...wrapKeyValue("Name", worktree.name, width));
|
|
251
|
+
if (worktree.branch)
|
|
252
|
+
lines.push(...wrapKeyValue("Branch", worktree.branch, width));
|
|
253
|
+
lines.push(...wrapKeyValue("Path", worktree.path, width));
|
|
254
|
+
lines.push(...wrapKeyValue("Agents", String(focusedSessions.length), width));
|
|
255
|
+
lines.push(...wrapKeyValue("Services", String(focusedServices.length), width));
|
|
256
|
+
if (focusedSessions.length > 0) {
|
|
257
|
+
lines.push(...wrapKeyValue("Active", focusedSessions
|
|
258
|
+
.map((session) => session.label ?? session.command)
|
|
259
|
+
.slice(0, 3)
|
|
260
|
+
.join(", "), width));
|
|
261
|
+
}
|
|
262
|
+
if (focusedServices.length > 0) {
|
|
263
|
+
lines.push(...wrapKeyValue("Running", focusedServices
|
|
264
|
+
.map((service) => service.label ?? service.command)
|
|
265
|
+
.slice(0, 3)
|
|
266
|
+
.join(", "), width));
|
|
267
|
+
}
|
|
268
|
+
while (lines.length < height)
|
|
269
|
+
lines.push("");
|
|
270
|
+
return lines.slice(0, height);
|
|
271
|
+
}
|
|
272
|
+
const lines = ["\x1b[1mDetails\x1b[0m"];
|
|
273
|
+
if (selectedService) {
|
|
274
|
+
lines.push(...wrapKeyValue("Service", `${selectedService.label ?? selectedService.command} (${selectedService.id})`, width));
|
|
275
|
+
lines.push(...wrapKeyValue("Command", selectedService.command, width));
|
|
276
|
+
if (selectedService.foregroundCommand)
|
|
277
|
+
lines.push(...wrapKeyValue("Foreground", selectedService.foregroundCommand, width));
|
|
278
|
+
if (selectedService.pid)
|
|
279
|
+
lines.push(...wrapKeyValue("PID", String(selectedService.pid), width));
|
|
280
|
+
if (selectedService.worktreeName || selectedService.worktreeBranch) {
|
|
281
|
+
lines.push(...wrapKeyValue("Worktree", `${selectedService.worktreeName ?? "main"}${selectedService.worktreeBranch ? ` · ${selectedService.worktreeBranch}` : ""}`, width));
|
|
282
|
+
}
|
|
283
|
+
if (selectedService.cwd)
|
|
284
|
+
lines.push(...wrapKeyValue("CWD", selectedService.cwd, width));
|
|
285
|
+
lines.push(...wrapKeyValue("Status", selectedService.status, width));
|
|
286
|
+
if (selectedService.previewLine)
|
|
287
|
+
lines.push(...wrapKeyValue("Preview", selectedService.previewLine, width));
|
|
288
|
+
while (lines.length < height)
|
|
289
|
+
lines.push("");
|
|
290
|
+
return lines.slice(0, height);
|
|
291
|
+
}
|
|
292
|
+
const selected = selectedSession;
|
|
293
|
+
lines.push(...wrapKeyValue("Agent", `${selected.label ?? selected.command} (${selected.id})`, width));
|
|
294
|
+
lines.push(...wrapKeyValue("Tool", selected.command, width));
|
|
295
|
+
if (selected.worktreeName || selected.worktreeBranch) {
|
|
296
|
+
lines.push(...wrapKeyValue("Worktree", `${selected.worktreeName ?? "main"}${selected.worktreeBranch ? ` · ${selected.worktreeBranch}` : ""}`, width));
|
|
297
|
+
}
|
|
298
|
+
if (selected.cwd)
|
|
299
|
+
lines.push(...wrapKeyValue("CWD", selected.cwd, width));
|
|
300
|
+
if (selected.foregroundCommand)
|
|
301
|
+
lines.push(...wrapKeyValue("Foreground", selected.foregroundCommand, width));
|
|
302
|
+
if (selected.pid)
|
|
303
|
+
lines.push(...wrapKeyValue("PID", String(selected.pid), width));
|
|
304
|
+
if (selected.prNumber || selected.prTitle || selected.prUrl) {
|
|
305
|
+
const prHeader = [`PR${selected.prNumber ? ` #${selected.prNumber}` : ""}`];
|
|
306
|
+
if (selected.prTitle)
|
|
307
|
+
prHeader.push(selected.prTitle);
|
|
308
|
+
lines.push(...wrapKeyValue("PR", prHeader.join(": "), width));
|
|
309
|
+
if (selected.prUrl)
|
|
310
|
+
lines.push(...wrapKeyValue("URL", selected.prUrl, width));
|
|
311
|
+
}
|
|
312
|
+
if (selected.repoOwner || selected.repoName)
|
|
313
|
+
lines.push(...wrapKeyValue("Repo", `${selected.repoOwner ?? "?"}/${selected.repoName ?? "?"}`, width));
|
|
314
|
+
if (selected.repoRemote)
|
|
315
|
+
lines.push(...wrapKeyValue("Remote", selected.repoRemote, width));
|
|
316
|
+
if (selected.previewLine)
|
|
317
|
+
lines.push(...wrapKeyValue("Preview", selected.previewLine, width));
|
|
318
|
+
if (selected.activity)
|
|
319
|
+
lines.push(...wrapKeyValue("Activity", selected.activity, width));
|
|
320
|
+
if (selected.attention && selected.attention !== "normal")
|
|
321
|
+
lines.push(...wrapKeyValue("Attention", selected.attention, width));
|
|
322
|
+
if (selected.unseenCount && selected.unseenCount > 0)
|
|
323
|
+
lines.push(...wrapKeyValue("Unseen", String(selected.unseenCount), width));
|
|
324
|
+
if (selected.lastEvent?.message)
|
|
325
|
+
lines.push(...wrapKeyValue("Last", selected.lastEvent.message, width));
|
|
326
|
+
if (selected.threadName || selected.threadId)
|
|
327
|
+
lines.push(...wrapKeyValue("Thread", selected.threadName ?? selected.threadId ?? "", width));
|
|
328
|
+
if ((selected.threadUnreadCount ?? 0) > 0 ||
|
|
329
|
+
(selected.threadWaitingOnMeCount ?? 0) > 0 ||
|
|
330
|
+
(selected.threadWaitingOnThemCount ?? 0) > 0 ||
|
|
331
|
+
(selected.threadPendingCount ?? 0) > 0) {
|
|
332
|
+
lines.push(...wrapKeyValue("Threads", `${selected.threadUnreadCount ?? 0} unread · ${selected.threadWaitingOnMeCount ?? 0} on me · ${selected.threadWaitingOnThemCount ?? 0} on them · ${selected.threadPendingCount ?? 0} pending`, width));
|
|
333
|
+
}
|
|
334
|
+
if ((selected.workflowOnMeCount ?? 0) > 0 ||
|
|
335
|
+
(selected.workflowBlockedCount ?? 0) > 0 ||
|
|
336
|
+
(selected.workflowFamilyCount ?? 0) > 0 ||
|
|
337
|
+
selected.workflowTopLabel) {
|
|
338
|
+
const summary = [
|
|
339
|
+
`${selected.workflowOnMeCount ?? 0} on me`,
|
|
340
|
+
`${selected.workflowBlockedCount ?? 0} blocked`,
|
|
341
|
+
`${selected.workflowFamilyCount ?? 0} families`,
|
|
342
|
+
selected.workflowTopLabel ? `top: ${selected.workflowTopLabel}` : undefined,
|
|
343
|
+
selected.workflowNextAction ? `next: ${selected.workflowNextAction}` : undefined,
|
|
344
|
+
]
|
|
345
|
+
.filter(Boolean)
|
|
346
|
+
.join(" · ");
|
|
347
|
+
lines.push(...wrapKeyValue("Workflow", summary, width));
|
|
348
|
+
}
|
|
349
|
+
if ((selected.services?.length ?? 0) > 0) {
|
|
350
|
+
lines.push(...wrapKeyValue("Services", selected.services.map((s) => s.url ?? `:${s.port}`).join(", "), width));
|
|
351
|
+
}
|
|
352
|
+
while (lines.length < height)
|
|
353
|
+
lines.push("");
|
|
354
|
+
return lines.slice(0, height);
|
|
355
|
+
};
|
|
356
|
+
const header = [
|
|
357
|
+
"",
|
|
358
|
+
centerInBlock(`\x1b[1maimux\x1b[0m — agent multiplexer${state.runtimeLabel ? ` \x1b[32m● ${state.runtimeLabel}\x1b[0m` : ""}`),
|
|
359
|
+
"─".repeat(Math.max(0, cols)),
|
|
360
|
+
"",
|
|
361
|
+
];
|
|
362
|
+
const content = [];
|
|
363
|
+
if (state.sessions.length === 0 && state.worktreeGroups.length === 0) {
|
|
364
|
+
content.push(centerInBlock("No sessions. Press [c] to create one."));
|
|
365
|
+
}
|
|
366
|
+
else if (state.hasWorktrees) {
|
|
367
|
+
renderWorktreeGrouped(content);
|
|
368
|
+
}
|
|
369
|
+
else {
|
|
370
|
+
for (const session of state.sessions)
|
|
371
|
+
content.push(renderSession(session, " "));
|
|
372
|
+
}
|
|
373
|
+
const helpLines = wrapCommandGroups(buildHelpLine());
|
|
374
|
+
const footer = ["─".repeat(Math.max(0, cols)), ...helpLines.map((line) => centerInBlock(line))];
|
|
375
|
+
const viewportHeight = rows - header.length - footer.length;
|
|
376
|
+
const twoPane = cols >= 72 && state.detailsPaneVisible;
|
|
377
|
+
let scrollOffset = state.scrollOffset;
|
|
378
|
+
const focusLine = findFocusLine(content);
|
|
379
|
+
const maxScroll = Math.max(0, content.length - viewportHeight);
|
|
380
|
+
if (focusLine >= 0) {
|
|
381
|
+
if (focusLine < scrollOffset + 1) {
|
|
382
|
+
scrollOffset = Math.max(0, focusLine - 1);
|
|
383
|
+
}
|
|
384
|
+
else if (focusLine >= scrollOffset + viewportHeight - 1) {
|
|
385
|
+
scrollOffset = Math.min(maxScroll, focusLine - viewportHeight + 2);
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
scrollOffset = Math.min(scrollOffset, maxScroll);
|
|
389
|
+
const visibleContent = content.slice(scrollOffset, scrollOffset + viewportHeight);
|
|
390
|
+
const canScrollUp = scrollOffset > 0;
|
|
391
|
+
const canScrollDown = scrollOffset < maxScroll;
|
|
392
|
+
if (canScrollUp)
|
|
393
|
+
visibleContent[0] = centerInBlock("\x1b[2m▲ more ▲\x1b[0m");
|
|
394
|
+
if (canScrollDown && visibleContent.length > 0)
|
|
395
|
+
visibleContent[visibleContent.length - 1] = centerInBlock("\x1b[2m▼ more ▼\x1b[0m");
|
|
396
|
+
while (visibleContent.length < viewportHeight)
|
|
397
|
+
visibleContent.push("");
|
|
398
|
+
let bodyLines = visibleContent;
|
|
399
|
+
if (twoPane) {
|
|
400
|
+
const rightPanel = renderSelectedDetailsPanel(Math.max(24, contentWidth - Math.max(32, Math.floor(contentWidth * 0.58)) - 3), viewportHeight);
|
|
401
|
+
bodyLines = composeTwoPane(visibleContent, rightPanel, contentWidth).map(padBlockLine);
|
|
402
|
+
}
|
|
403
|
+
else {
|
|
404
|
+
bodyLines = visibleContent.map((line) => padBlockLine(line));
|
|
405
|
+
}
|
|
406
|
+
return {
|
|
407
|
+
frame: "\x1b[2J\x1b[H" + [...header, ...bodyLines, ...footer].join("\r\n"),
|
|
408
|
+
scrollOffset,
|
|
409
|
+
};
|
|
410
|
+
}
|
|
411
|
+
//# sourceMappingURL=dashboard-renderers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dashboard-renderers.js","sourceRoot":"","sources":["../../../src/tui/screens/dashboard-renderers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AACzD,OAAO,EAAE,0BAA0B,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,SAAS,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAoB9F,MAAM,YAAY,GAA+C;IAC/D,OAAO,EAAE,kBAAkB;IA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"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare function renderServiceInputOverlay(ctx: any): void;
|
|
2
|
+
export declare function renderLabelInputOverlay(ctx: any): void;
|
|
3
|
+
export declare function renderWorktreeListOverlay(ctx: any): void;
|
|
4
|
+
export declare function renderWorktreeRemoveConfirmOverlay(ctx: any): void;
|
|
5
|
+
export declare function renderDashboardBusyOverlay(ctx: any): void;
|
|
6
|
+
export declare function renderDashboardErrorOverlay(ctx: any): void;
|
|
7
|
+
export declare function renderNotificationPanel(ctx: any): void;
|
|
8
|
+
export declare function renderHelpOverlay(_ctx: any): void;
|
|
9
|
+
export declare function renderSwitcherOverlay(ctx: any): void;
|
|
10
|
+
export declare function renderMigratePickerOverlay(ctx: any): void;
|