@bastani/atomic 0.10.0 → 0.10.1
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/CHANGELOG.md +98 -0
- package/dist/builtin/intercom/package.json +1 -1
- package/dist/builtin/mcp/package.json +1 -1
- package/dist/builtin/subagents/CHANGELOG.md +12 -0
- package/dist/builtin/subagents/package.json +1 -1
- package/dist/builtin/subagents/skills/tmux/scripts/wait-for-text.sh +33 -3
- package/dist/builtin/web-access/package.json +1 -1
- package/dist/core/agent-session-events.d.ts.map +1 -1
- package/dist/core/agent-session-events.js +21 -6
- package/dist/core/agent-session-events.js.map +1 -1
- package/dist/core/lifecycle-timings.d.ts +6 -0
- package/dist/core/lifecycle-timings.d.ts.map +1 -1
- package/dist/core/lifecycle-timings.js +12 -0
- package/dist/core/lifecycle-timings.js.map +1 -1
- package/dist/core/queued-message-delivery.d.ts +41 -0
- package/dist/core/queued-message-delivery.d.ts.map +1 -0
- package/dist/core/queued-message-delivery.js +48 -0
- package/dist/core/queued-message-delivery.js.map +1 -0
- package/dist/core/storage/node-sqlite-thread.d.ts +64 -0
- package/dist/core/storage/node-sqlite-thread.d.ts.map +1 -0
- package/dist/core/storage/node-sqlite-thread.js +326 -0
- package/dist/core/storage/node-sqlite-thread.js.map +1 -0
- package/dist/core/storage/node-sqlite.d.ts.map +1 -1
- package/dist/core/storage/node-sqlite.js +230 -104
- package/dist/core/storage/node-sqlite.js.map +1 -1
- package/dist/core/tasks/agent-panel-source.d.ts +5 -0
- package/dist/core/tasks/agent-panel-source.d.ts.map +1 -1
- package/dist/core/tasks/agent-panel-source.js +1 -1
- package/dist/core/tasks/agent-panel-source.js.map +1 -1
- package/dist/modes/interactive/agent-view/agent-view-bridge.d.ts +8 -1
- package/dist/modes/interactive/agent-view/agent-view-bridge.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/agent-view-bridge.js.map +1 -1
- package/dist/modes/interactive/agent-view/agent-view-switcher.d.ts +11 -5
- package/dist/modes/interactive/agent-view/agent-view-switcher.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/agent-view-switcher.js +17 -5
- package/dist/modes/interactive/agent-view/agent-view-switcher.js.map +1 -1
- package/dist/modes/interactive/agent-view/contracts.d.ts +5 -0
- package/dist/modes/interactive/agent-view/contracts.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/contracts.js.map +1 -1
- package/dist/modes/interactive/agent-view/install.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/install.js +6 -3
- package/dist/modes/interactive/agent-view/install.js.map +1 -1
- package/dist/modes/interactive/agent-view/local-port.d.ts +5 -0
- package/dist/modes/interactive/agent-view/local-port.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/local-port.js +8 -0
- package/dist/modes/interactive/agent-view/local-port.js.map +1 -1
- package/dist/modes/interactive/agent-view/remote-port.d.ts +4 -1
- package/dist/modes/interactive/agent-view/remote-port.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/remote-port.js +22 -8
- package/dist/modes/interactive/agent-view/remote-port.js.map +1 -1
- package/dist/modes/interactive/agent-view/transcript-slot.d.ts +9 -0
- package/dist/modes/interactive/agent-view/transcript-slot.d.ts.map +1 -1
- package/dist/modes/interactive/agent-view/transcript-slot.js +141 -1
- package/dist/modes/interactive/agent-view/transcript-slot.js.map +1 -1
- package/dist/modes/interactive/components/agent-panel.d.ts +6 -0
- package/dist/modes/interactive/components/agent-panel.d.ts.map +1 -1
- package/dist/modes/interactive/components/agent-panel.js +40 -10
- package/dist/modes/interactive/components/agent-panel.js.map +1 -1
- package/dist/modes/interactive/components/atomic-working-status.d.ts +15 -0
- package/dist/modes/interactive/components/atomic-working-status.d.ts.map +1 -1
- package/dist/modes/interactive/components/atomic-working-status.js +51 -3
- package/dist/modes/interactive/components/atomic-working-status.js.map +1 -1
- package/dist/modes/interactive/components/bash-execution.d.ts +2 -0
- package/dist/modes/interactive/components/bash-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/bash-execution.js +5 -1
- package/dist/modes/interactive/components/bash-execution.js.map +1 -1
- package/dist/modes/interactive/components/branch-summary-message.d.ts +2 -0
- package/dist/modes/interactive/components/branch-summary-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/branch-summary-message.js +5 -1
- package/dist/modes/interactive/components/branch-summary-message.js.map +1 -1
- package/dist/modes/interactive/components/chat-message-renderer.d.ts +2 -0
- package/dist/modes/interactive/components/chat-message-renderer.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-message-renderer.js +17 -6
- package/dist/modes/interactive/components/chat-message-renderer.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-events.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-events.js +35 -4
- package/dist/modes/interactive/components/chat-session-host-events.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-rendering.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-rendering.js +70 -13
- package/dist/modes/interactive/components/chat-session-host-rendering.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-runtime.d.ts +7 -0
- package/dist/modes/interactive/components/chat-session-host-runtime.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-runtime.js +25 -4
- package/dist/modes/interactive/components/chat-session-host-runtime.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-state.d.ts +41 -1
- package/dist/modes/interactive/components/chat-session-host-state.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-state.js +24 -3
- package/dist/modes/interactive/components/chat-session-host-state.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-steering.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host-steering.js +2 -1
- package/dist/modes/interactive/components/chat-session-host-steering.js.map +1 -1
- package/dist/modes/interactive/components/chat-session-host.d.ts +13 -1
- package/dist/modes/interactive/components/chat-session-host.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-session-host.js +20 -2
- package/dist/modes/interactive/components/chat-session-host.js.map +1 -1
- package/dist/modes/interactive/components/chat-transcript.d.ts +15 -0
- package/dist/modes/interactive/components/chat-transcript.d.ts.map +1 -1
- package/dist/modes/interactive/components/chat-transcript.js +14 -1
- package/dist/modes/interactive/components/chat-transcript.js.map +1 -1
- package/dist/modes/interactive/components/compaction-boundary-message.d.ts +2 -0
- package/dist/modes/interactive/components/compaction-boundary-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/compaction-boundary-message.js +5 -1
- package/dist/modes/interactive/components/compaction-boundary-message.js.map +1 -1
- package/dist/modes/interactive/components/custom-entry.d.ts +2 -0
- package/dist/modes/interactive/components/custom-entry.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-entry.js +5 -1
- package/dist/modes/interactive/components/custom-entry.js.map +1 -1
- package/dist/modes/interactive/components/custom-message.d.ts +2 -0
- package/dist/modes/interactive/components/custom-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-message.js +5 -1
- package/dist/modes/interactive/components/custom-message.js.map +1 -1
- package/dist/modes/interactive/components/model-column.d.ts +96 -0
- package/dist/modes/interactive/components/model-column.d.ts.map +1 -0
- package/dist/modes/interactive/components/model-column.js +207 -0
- package/dist/modes/interactive/components/model-column.js.map +1 -0
- package/dist/modes/interactive/components/prompt-slot.d.ts +73 -0
- package/dist/modes/interactive/components/prompt-slot.d.ts.map +1 -0
- package/dist/modes/interactive/components/prompt-slot.js +201 -0
- package/dist/modes/interactive/components/prompt-slot.js.map +1 -0
- package/dist/modes/interactive/components/queued-messages-view.d.ts +6 -3
- package/dist/modes/interactive/components/queued-messages-view.d.ts.map +1 -1
- package/dist/modes/interactive/components/queued-messages-view.js +7 -4
- package/dist/modes/interactive/components/queued-messages-view.js.map +1 -1
- package/dist/modes/interactive/components/session-selector.d.ts +2 -0
- package/dist/modes/interactive/components/session-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/session-selector.js +4 -0
- package/dist/modes/interactive/components/session-selector.js.map +1 -1
- package/dist/modes/interactive/components/skill-invocation-message.d.ts +2 -0
- package/dist/modes/interactive/components/skill-invocation-message.d.ts.map +1 -1
- package/dist/modes/interactive/components/skill-invocation-message.js +5 -1
- package/dist/modes/interactive/components/skill-invocation-message.js.map +1 -1
- package/dist/modes/interactive/components/task-board.d.ts +12 -3
- package/dist/modes/interactive/components/task-board.d.ts.map +1 -1
- package/dist/modes/interactive/components/task-board.js +33 -17
- package/dist/modes/interactive/components/task-board.js.map +1 -1
- package/dist/modes/interactive/components/task-inspector.d.ts +6 -1
- package/dist/modes/interactive/components/task-inspector.d.ts.map +1 -1
- package/dist/modes/interactive/components/task-inspector.js +27 -7
- package/dist/modes/interactive/components/task-inspector.js.map +1 -1
- package/dist/modes/interactive/components/task-row.d.ts +4 -0
- package/dist/modes/interactive/components/task-row.d.ts.map +1 -1
- package/dist/modes/interactive/components/task-row.js +7 -1
- package/dist/modes/interactive/components/task-row.js.map +1 -1
- package/dist/modes/interactive/components/task-transcript-page.d.ts +5 -0
- package/dist/modes/interactive/components/task-transcript-page.d.ts.map +1 -1
- package/dist/modes/interactive/components/task-transcript-page.js +25 -0
- package/dist/modes/interactive/components/task-transcript-page.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts +7 -0
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +19 -2
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/components/tool-group-tracker.d.ts +20 -3
- package/dist/modes/interactive/components/tool-group-tracker.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-group-tracker.js +34 -7
- package/dist/modes/interactive/components/tool-group-tracker.js.map +1 -1
- package/dist/modes/interactive/components/transcript-block-clicks.d.ts +14 -2
- package/dist/modes/interactive/components/transcript-block-clicks.d.ts.map +1 -1
- package/dist/modes/interactive/components/transcript-block-clicks.js +23 -2
- package/dist/modes/interactive/components/transcript-block-clicks.js.map +1 -1
- package/dist/modes/interactive/interactive-agent-events.js +10 -2
- package/dist/modes/interactive/interactive-agent-events.js.map +1 -1
- package/dist/modes/interactive/interactive-extension-runtime.d.ts +12 -1
- package/dist/modes/interactive/interactive-extension-runtime.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-extension-runtime.js +37 -5
- package/dist/modes/interactive/interactive-extension-runtime.js.map +1 -1
- package/dist/modes/interactive/interactive-input-handling.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-input-handling.js +70 -46
- package/dist/modes/interactive/interactive-input-handling.js.map +1 -1
- package/dist/modes/interactive/interactive-mode-base.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode-base.js +7 -1
- package/dist/modes/interactive/interactive-mode-base.js.map +1 -1
- package/dist/modes/interactive/interactive-prompt-turn.js +17 -9
- package/dist/modes/interactive/interactive-prompt-turn.js.map +1 -1
- package/dist/modes/interactive/interactive-queueing.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-queueing.js +2 -1
- package/dist/modes/interactive/interactive-queueing.js.map +1 -1
- package/dist/modes/interactive/interactive-render-chat.d.ts +18 -1
- package/dist/modes/interactive/interactive-render-chat.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-render-chat.js +90 -10
- package/dist/modes/interactive/interactive-render-chat.js.map +1 -1
- package/dist/modes/interactive/interactive-session-routing.js +2 -0
- package/dist/modes/interactive/interactive-session-routing.js.map +1 -1
- package/dist/modes/interactive/interactive-task-projection.js +2 -2
- package/dist/modes/interactive/interactive-task-projection.js.map +1 -1
- package/dist/modes/interactive/screen-hold.d.ts +41 -0
- package/dist/modes/interactive/screen-hold.d.ts.map +1 -0
- package/dist/modes/interactive/screen-hold.js +80 -0
- package/dist/modes/interactive/screen-hold.js.map +1 -0
- package/dist/modes/interactive/started-run-echo.d.ts +66 -0
- package/dist/modes/interactive/started-run-echo.d.ts.map +1 -0
- package/dist/modes/interactive/started-run-echo.js +75 -0
- package/dist/modes/interactive/started-run-echo.js.map +1 -0
- package/dist/modes/interactive-engine/engine-custom-ui.d.ts +1 -0
- package/dist/modes/interactive-engine/engine-custom-ui.d.ts.map +1 -1
- package/dist/modes/interactive-engine/engine-custom-ui.js +25 -1
- package/dist/modes/interactive-engine/engine-custom-ui.js.map +1 -1
- package/dist/modes/interactive-engine/engine-quit-intent.d.ts.map +1 -1
- package/dist/modes/interactive-engine/engine-quit-intent.js +3 -0
- package/dist/modes/interactive-engine/engine-quit-intent.js.map +1 -1
- package/dist/modes/interactive-engine/protocol.d.ts +5 -0
- package/dist/modes/interactive-engine/protocol.d.ts.map +1 -1
- package/dist/modes/interactive-engine/protocol.js +7 -1
- package/dist/modes/interactive-engine/protocol.js.map +1 -1
- package/dist/modes/interactive-engine/remote-component.d.ts +10 -2
- package/dist/modes/interactive-engine/remote-component.d.ts.map +1 -1
- package/dist/modes/interactive-engine/remote-component.js +19 -2
- package/dist/modes/interactive-engine/remote-component.js.map +1 -1
- package/dist/modes/interactive-engine/remote-renderer.d.ts +10 -0
- package/dist/modes/interactive-engine/remote-renderer.d.ts.map +1 -1
- package/dist/modes/interactive-engine/remote-renderer.js +24 -4
- package/dist/modes/interactive-engine/remote-renderer.js.map +1 -1
- package/dist/modes/interactive-engine/transcript-frame-layout.d.ts +50 -0
- package/dist/modes/interactive-engine/transcript-frame-layout.d.ts.map +1 -0
- package/dist/modes/interactive-engine/transcript-frame-layout.js +95 -0
- package/dist/modes/interactive-engine/transcript-frame-layout.js.map +1 -0
- package/dist/modes/rpc/agent-panel-bridge.d.ts.map +1 -1
- package/dist/modes/rpc/agent-panel-bridge.js +16 -0
- package/dist/modes/rpc/agent-panel-bridge.js.map +1 -1
- package/dist/modes/rpc/agent-view-engine-registry.d.ts.map +1 -1
- package/dist/modes/rpc/agent-view-engine-registry.js +36 -1
- package/dist/modes/rpc/agent-view-engine-registry.js.map +1 -1
- package/dist/modes/rpc/agent-view-rpc-panel.d.ts.map +1 -1
- package/dist/modes/rpc/agent-view-rpc-panel.js +5 -1
- package/dist/modes/rpc/agent-view-rpc-panel.js.map +1 -1
- package/dist/modes/rpc/task-ui-bridge.js +1 -1
- package/dist/modes/rpc/task-ui-bridge.js.map +1 -1
- package/docs/background-tasks.md +1 -1
- package/docs/development.md +2 -0
- package/docs/extensions/authoring.md +1 -1
- package/docs/keybindings.md +2 -2
- package/docs/storage.md +1 -0
- package/npm-shrinkwrap.json +49 -49
- package/package.json +6 -6
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transcript-frame-layout.d.ts","sourceRoot":"","sources":["../../../src/modes/interactive-engine/transcript-frame-layout.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,6GAA6G;AAC7G,MAAM,WAAW,qBAAqB;IACrC,yCAAyC;IACzC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,kHAAkH;IAClH,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,+CAA+C;IAC/C,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,qCAAqC;IACrC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,2GAA2G;IAC3G,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,+FAA+F;IAC/F,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,qBAAqB;IACrC,QAAQ,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC;IACzB;;;OAGG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,CAAC,MAAM,GAAG,SAAS,CAAC,EAAE,CAAC;IACrD,yFAAyF;IACzF,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACxB;AAID,kGAAkG;AAClG,wBAAgB,0BAA0B,CAAC,KAAK,EAAE,OAAO,GAAG,qBAAqB,GAAG,SAAS,CAiB5F;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CACnC,KAAK,EAAE,MAAM,EAAE,EACf,MAAM,EAAE,qBAAqB,GAAG,SAAS,EACzC,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,GACZ,qBAAqB,CAWvB;AAyCD,sFAAsF;AACtF,MAAM,WAAW,sBAAsB;IACtC,gBAAgB,CAAC,IAAI,qBAAqB,GAAG,SAAS,CAAC;CACvD;AAED,yEAAyE;AACzE,wBAAgB,kBAAkB,CAAC,SAAS,EAAE,MAAM,GAAG,qBAAqB,GAAG,SAAS,CAEvF"}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Placing a viewed subagent's transcript frame in a transcript area of another height.
|
|
3
|
+
*
|
|
4
|
+
* The engine draws the transcript for the rows the host asks for, and the host paints the frame it has until the one
|
|
5
|
+
* for the new height arrives. A frame is the scrolled transcript (its body) with the page's notes and question form
|
|
6
|
+
* below it. With the frame's layout the host puts every row it has where the engine's frame for the new height will
|
|
7
|
+
* put it: rows the reader follows at the end stay at the bottom and earlier rows open above them, a reader scrolled up
|
|
8
|
+
* keeps the rows they read at the top, and the notes and form stay at the bottom. Rows the frame does not have stay
|
|
9
|
+
* blank until that frame is here; nothing painted moves when it arrives.
|
|
10
|
+
*/
|
|
11
|
+
const LAYOUT_FIELDS = ["width", "bodyRows", "firstRow", "totalRows", "headRows", "footRows"];
|
|
12
|
+
/** The layout in `value`, when it is one: whole, non-negative numbers whose rows fit the body. */
|
|
13
|
+
export function parseTranscriptFrameLayout(value) {
|
|
14
|
+
if (typeof value !== "object" || value === null)
|
|
15
|
+
return undefined;
|
|
16
|
+
const record = value;
|
|
17
|
+
for (const field of LAYOUT_FIELDS) {
|
|
18
|
+
const entry = record[field];
|
|
19
|
+
if (typeof entry !== "number" || !Number.isSafeInteger(entry) || entry < 0)
|
|
20
|
+
return undefined;
|
|
21
|
+
}
|
|
22
|
+
const layout = record;
|
|
23
|
+
if (layout.headRows + layout.footRows > layout.bodyRows)
|
|
24
|
+
return undefined;
|
|
25
|
+
return {
|
|
26
|
+
width: layout.width,
|
|
27
|
+
bodyRows: layout.bodyRows,
|
|
28
|
+
firstRow: layout.firstRow,
|
|
29
|
+
totalRows: layout.totalRows,
|
|
30
|
+
headRows: layout.headRows,
|
|
31
|
+
footRows: layout.footRows,
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* `lines`, a frame laid out as `layout` says, in `height` rows of `width`. A frame drawn for this height is shown as
|
|
36
|
+
* it is. One drawn for another height is placed as the engine's frame for this height places the same rows; without a
|
|
37
|
+
* layout that says how, its last rows are shown and blank rows follow.
|
|
38
|
+
*/
|
|
39
|
+
export function placeTranscriptFrame(lines, layout, width, height) {
|
|
40
|
+
const rows = Math.max(0, height);
|
|
41
|
+
if (lines.length !== rows && layout !== undefined && layout.width === width) {
|
|
42
|
+
const placed = placeByLayout(lines, layout, rows);
|
|
43
|
+
if (placed !== undefined)
|
|
44
|
+
return placed;
|
|
45
|
+
}
|
|
46
|
+
// A frame drawn for another height until the next one is here: keep its last rows, where the latest are.
|
|
47
|
+
const hidden = Math.max(0, lines.length - rows);
|
|
48
|
+
const shown = hidden > 0 ? lines.slice(hidden) : lines;
|
|
49
|
+
const placed = shown.length < rows ? [...shown, ...Array.from({ length: rows - shown.length }, () => "")] : shown;
|
|
50
|
+
return { lines: placed, hidden };
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* The rows the engine's frame for `height` puts where, after `ScrollableComponentViewport.render`: a reader at the
|
|
54
|
+
* end stays at the end, a reader scrolled up keeps their first row until the end comes into view, and the notes and
|
|
55
|
+
* form keep their rows below. Undefined when the frame cannot say: the area leaves the body no row, or a small frame
|
|
56
|
+
* left out a pinned prompt or a jump row that the taller one draws.
|
|
57
|
+
*/
|
|
58
|
+
function placeByLayout(lines, layout, height) {
|
|
59
|
+
const { bodyRows, firstRow, totalRows, headRows, footRows } = layout;
|
|
60
|
+
const bandRows = lines.length - bodyRows;
|
|
61
|
+
const nextBody = height - bandRows;
|
|
62
|
+
if (bandRows < 0 || nextBody < 1)
|
|
63
|
+
return undefined;
|
|
64
|
+
const following = firstRow + bodyRows >= totalRows;
|
|
65
|
+
const lastStart = Math.max(0, totalRows - nextBody);
|
|
66
|
+
const nextFirst = following ? lastStart : Math.min(firstRow, lastStart);
|
|
67
|
+
// Scrolled up, and still short of the end: the body keeps its pinned prompt and jump row where the rows allow them.
|
|
68
|
+
const scrolled = !following && nextFirst < lastStart;
|
|
69
|
+
if (scrolled && bodyRows <= 1 && nextBody > 1)
|
|
70
|
+
return undefined;
|
|
71
|
+
const nextFoot = scrolled && footRows > 0 && nextBody > 1 ? footRows : 0;
|
|
72
|
+
if (scrolled && headRows === 0 && firstRow > 0 && bodyRows - footRows <= 2 && nextBody - nextFoot > 2)
|
|
73
|
+
return undefined;
|
|
74
|
+
const nextHead = scrolled && headRows > 0 && nextBody - nextFoot > 2 ? headRows : 0;
|
|
75
|
+
const transcriptRows = bodyRows - headRows - footRows;
|
|
76
|
+
const frameRows = [];
|
|
77
|
+
for (let row = 0; row < nextBody; row++) {
|
|
78
|
+
if (row < nextHead)
|
|
79
|
+
frameRows.push(row);
|
|
80
|
+
else if (row >= nextBody - nextFoot)
|
|
81
|
+
frameRows.push(bodyRows - (nextBody - row));
|
|
82
|
+
else {
|
|
83
|
+
const transcriptRow = nextFirst + (row - nextHead) - firstRow;
|
|
84
|
+
frameRows.push(transcriptRow >= 0 && transcriptRow < transcriptRows ? headRows + transcriptRow : undefined);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
for (let row = 0; row < bandRows; row++)
|
|
88
|
+
frameRows.push(bodyRows + row);
|
|
89
|
+
return { lines: frameRows.map((row) => (row === undefined ? "" : (lines[row] ?? ""))), frameRows, hidden: 0 };
|
|
90
|
+
}
|
|
91
|
+
/** How `component` laid out the frame it rendered last, when it says. */
|
|
92
|
+
export function transcriptLayoutOf(component) {
|
|
93
|
+
return component.transcriptLayout?.();
|
|
94
|
+
}
|
|
95
|
+
//# sourceMappingURL=transcript-frame-layout.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transcript-frame-layout.js","sourceRoot":"","sources":["../../../src/modes/interactive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AM,aAAa,GAAG,SAAS,GAAG,CAAC,GAAG,GAAG,QAAQ,CAAC,GAAG,QAAQ,CAAC;YAC9D,SAAS,CAAC,IAAI,CAAC,aAAa,IAAI,CAAC,IAAI,aAAa,GAAG,cAAc,CAAC,CAAC,CAAC,QAAQ,GAAG,aAAa,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;QAC7G,CAAC;IACF,CAAC;IACD,KAAK,IAAI,GAAG,GAAG,CAAC,EAAE,GAAG,GAAG,QAAQ,EAAE,GAAG,EAAE;QAAE,SAAS,CAAC,IAAI,CAAC,QAAQ,GAAG,GAAG,CAAC,CAAC;IACxE,OAAO,EAAE,KAAK,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,GAAG,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;AAC/G,CAAC;AAOD,yEAAyE;AACzE,MAAM,UAAU,kBAAkB,CAAC,SAAiB;IACnD,OAAQ,SAAoC,CAAC,gBAAgB,EAAE,EAAE,CAAC;AACnE,CAAC","sourcesContent":["/**\n * Placing a viewed subagent's transcript frame in a transcript area of another height.\n *\n * The engine draws the transcript for the rows the host asks for, and the host paints the frame it has until the one\n * for the new height arrives. A frame is the scrolled transcript (its body) with the page's notes and question form\n * below it. With the frame's layout the host puts every row it has where the engine's frame for the new height will\n * put it: rows the reader follows at the end stay at the bottom and earlier rows open above them, a reader scrolled up\n * keeps the rows they read at the top, and the notes and form stay at the bottom. Rows the frame does not have stay\n * blank until that frame is here; nothing painted moves when it arrives.\n */\n\n/** How a transcript frame laid out its rows, sent with each frame the engine draws for a viewed subagent. */\nexport interface TranscriptFrameLayout {\n\t/** The width the frame was drawn for. */\n\treadonly width: number;\n\t/** Rows at the top of the frame that show the scrolled transcript; the rows after them are notes and the form. */\n\treadonly bodyRows: number;\n\t/** The transcript row the body shows first. */\n\treadonly firstRow: number;\n\t/** Rows the whole transcript has. */\n\treadonly totalRows: number;\n\t/** Rows at the top of the body that are not transcript rows: the pinned prompt of a reader scrolled up. */\n\treadonly headRows: number;\n\t/** Rows at the bottom of the body that are not transcript rows: the jump to the latest row. */\n\treadonly footRows: number;\n}\n\nexport interface PlacedTranscriptFrame {\n\treadonly lines: string[];\n\t/**\n\t * The frame row each row shows when the frame was placed by its layout, undefined where the frame has no row for\n\t * it. Without it, row `r` shows frame row `r + hidden`.\n\t */\n\treadonly frameRows?: readonly (number | undefined)[];\n\t/** Rows of the frame above the first one shown, when it was not placed by its layout. */\n\treadonly hidden: number;\n}\n\nconst LAYOUT_FIELDS = [\"width\", \"bodyRows\", \"firstRow\", \"totalRows\", \"headRows\", \"footRows\"] as const;\n\n/** The layout in `value`, when it is one: whole, non-negative numbers whose rows fit the body. */\nexport function parseTranscriptFrameLayout(value: unknown): TranscriptFrameLayout | undefined {\n\tif (typeof value !== \"object\" || value === null) return undefined;\n\tconst record = value as Record<string, unknown>;\n\tfor (const field of LAYOUT_FIELDS) {\n\t\tconst entry = record[field];\n\t\tif (typeof entry !== \"number\" || !Number.isSafeInteger(entry) || entry < 0) return undefined;\n\t}\n\tconst layout = record as unknown as TranscriptFrameLayout;\n\tif (layout.headRows + layout.footRows > layout.bodyRows) return undefined;\n\treturn {\n\t\twidth: layout.width,\n\t\tbodyRows: layout.bodyRows,\n\t\tfirstRow: layout.firstRow,\n\t\ttotalRows: layout.totalRows,\n\t\theadRows: layout.headRows,\n\t\tfootRows: layout.footRows,\n\t};\n}\n\n/**\n * `lines`, a frame laid out as `layout` says, in `height` rows of `width`. A frame drawn for this height is shown as\n * it is. One drawn for another height is placed as the engine's frame for this height places the same rows; without a\n * layout that says how, its last rows are shown and blank rows follow.\n */\nexport function placeTranscriptFrame(\n\tlines: string[],\n\tlayout: TranscriptFrameLayout | undefined,\n\twidth: number,\n\theight: number,\n): PlacedTranscriptFrame {\n\tconst rows = Math.max(0, height);\n\tif (lines.length !== rows && layout !== undefined && layout.width === width) {\n\t\tconst placed = placeByLayout(lines, layout, rows);\n\t\tif (placed !== undefined) return placed;\n\t}\n\t// A frame drawn for another height until the next one is here: keep its last rows, where the latest are.\n\tconst hidden = Math.max(0, lines.length - rows);\n\tconst shown = hidden > 0 ? lines.slice(hidden) : lines;\n\tconst placed = shown.length < rows ? [...shown, ...Array.from({ length: rows - shown.length }, () => \"\")] : shown;\n\treturn { lines: placed, hidden };\n}\n\n/**\n * The rows the engine's frame for `height` puts where, after `ScrollableComponentViewport.render`: a reader at the\n * end stays at the end, a reader scrolled up keeps their first row until the end comes into view, and the notes and\n * form keep their rows below. Undefined when the frame cannot say: the area leaves the body no row, or a small frame\n * left out a pinned prompt or a jump row that the taller one draws.\n */\nfunction placeByLayout(\n\tlines: string[],\n\tlayout: TranscriptFrameLayout,\n\theight: number,\n): PlacedTranscriptFrame | undefined {\n\tconst { bodyRows, firstRow, totalRows, headRows, footRows } = layout;\n\tconst bandRows = lines.length - bodyRows;\n\tconst nextBody = height - bandRows;\n\tif (bandRows < 0 || nextBody < 1) return undefined;\n\tconst following = firstRow + bodyRows >= totalRows;\n\tconst lastStart = Math.max(0, totalRows - nextBody);\n\tconst nextFirst = following ? lastStart : Math.min(firstRow, lastStart);\n\t// Scrolled up, and still short of the end: the body keeps its pinned prompt and jump row where the rows allow them.\n\tconst scrolled = !following && nextFirst < lastStart;\n\tif (scrolled && bodyRows <= 1 && nextBody > 1) return undefined;\n\tconst nextFoot = scrolled && footRows > 0 && nextBody > 1 ? footRows : 0;\n\tif (scrolled && headRows === 0 && firstRow > 0 && bodyRows - footRows <= 2 && nextBody - nextFoot > 2)\n\t\treturn undefined;\n\tconst nextHead = scrolled && headRows > 0 && nextBody - nextFoot > 2 ? headRows : 0;\n\tconst transcriptRows = bodyRows - headRows - footRows;\n\tconst frameRows: (number | undefined)[] = [];\n\tfor (let row = 0; row < nextBody; row++) {\n\t\tif (row < nextHead) frameRows.push(row);\n\t\telse if (row >= nextBody - nextFoot) frameRows.push(bodyRows - (nextBody - row));\n\t\telse {\n\t\t\tconst transcriptRow = nextFirst + (row - nextHead) - firstRow;\n\t\t\tframeRows.push(transcriptRow >= 0 && transcriptRow < transcriptRows ? headRows + transcriptRow : undefined);\n\t\t}\n\t}\n\tfor (let row = 0; row < bandRows; row++) frameRows.push(bodyRows + row);\n\treturn { lines: frameRows.map((row) => (row === undefined ? \"\" : (lines[row] ?? \"\"))), frameRows, hidden: 0 };\n}\n\n/** A component that reports how it laid out the transcript frame it rendered last. */\nexport interface TranscriptLayoutSource {\n\ttranscriptLayout?(): TranscriptFrameLayout | undefined;\n}\n\n/** How `component` laid out the frame it rendered last, when it says. */\nexport function transcriptLayoutOf(component: object): TranscriptFrameLayout | undefined {\n\treturn (component as TranscriptLayoutSource).transcriptLayout?.();\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-panel-bridge.d.ts","sourceRoot":"","sources":["../../../src/modes/rpc/agent-panel-bridge.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAQzE,OAAO,EAEN,KAAK,iBAAiB,EAkBtB,MAAM,wCAAwC,CAAC;AAWhD,OAAO,EAMN,KAAK,aAAa,EAClB,KAAK,eAAe,EAQpB,MAAM,0CAA0C,CAAC;
|
|
1
|
+
{"version":3,"file":"agent-panel-bridge.d.ts","sourceRoot":"","sources":["../../../src/modes/rpc/agent-panel-bridge.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAQzE,OAAO,EAEN,KAAK,iBAAiB,EAkBtB,MAAM,wCAAwC,CAAC;AAWhD,OAAO,EAMN,KAAK,aAAa,EAClB,KAAK,eAAe,EAQpB,MAAM,0CAA0C,CAAC;AAUlD,OAAO,EAAqB,KAAK,eAAe,EAAE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AAE,OAAO,EAAE,OAAO,GAAG,IAAI,CAI5E;AAED,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,iBAAiB,GAAG,MAAM,GAAG,gBAAgB,CAStF;AAED,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,iBAAiB,GAAG,MAAM,GAAG,OAAO,CAE9E"}
|
|
@@ -8,6 +8,7 @@ import { launchedTaskViewSource, ownerTaskViewSource } from "../../core/tasks/ta
|
|
|
8
8
|
import { agentViewBridge } from "../interactive/agent-view/agent-view-bridge.js";
|
|
9
9
|
import { AGENT_PANEL_FOCUSED_ROWS, AGENT_PANEL_IDLE_ROWS, AGENT_PANEL_MAIN_ID, AgentPanelFocus, AgentPanelModel, agentPanelKeys, agentPanelRowIdAtLine, isActivePanelRow, isFinishedPanelRow, panelTaskId, renderAgentPanelHint, renderAgentPanelRows, } from "../interactive/components/agent-panel.js";
|
|
10
10
|
import { atomicWorkingFrame } from "../interactive/components/atomic-working-status.js";
|
|
11
|
+
import { ModelColumn } from "../interactive/components/model-column.js";
|
|
11
12
|
import { renderNavKeyOverlay } from "../interactive/components/nav-keys.js";
|
|
12
13
|
import { isSingleLeftClick } from "../interactive/components/single-click.js";
|
|
13
14
|
import { dismissedTasks } from "../interactive/components/task-dismissal.js";
|
|
@@ -468,6 +469,11 @@ inspector) {
|
|
|
468
469
|
let painted;
|
|
469
470
|
let cachedLines = [];
|
|
470
471
|
let timer;
|
|
472
|
+
/** The panel's model column, measured afresh each time the panel is mounted. */
|
|
473
|
+
const modelColumn = new ModelColumn(() => {
|
|
474
|
+
cachedRows = undefined;
|
|
475
|
+
ui.requestRender();
|
|
476
|
+
});
|
|
471
477
|
const publishCounts = (counts) => {
|
|
472
478
|
if (lastCounts !== undefined &&
|
|
473
479
|
counts.total === lastCounts.total &&
|
|
@@ -503,6 +509,7 @@ inspector) {
|
|
|
503
509
|
cachedLines = [];
|
|
504
510
|
const wasMounted = mounted;
|
|
505
511
|
mounted = false;
|
|
512
|
+
modelColumn.reset();
|
|
506
513
|
stopTimer();
|
|
507
514
|
if (resetCounts)
|
|
508
515
|
publishCounts(EMPTY_PANEL_COUNTS);
|
|
@@ -634,6 +641,7 @@ inspector) {
|
|
|
634
641
|
faded,
|
|
635
642
|
hiddenBelow: currentHiddenBelow,
|
|
636
643
|
showMain: currentMain,
|
|
644
|
+
modelColumn,
|
|
637
645
|
...idleMarks(),
|
|
638
646
|
});
|
|
639
647
|
}
|
|
@@ -654,6 +662,7 @@ inspector) {
|
|
|
654
662
|
faded,
|
|
655
663
|
hiddenBelow: currentHiddenBelow,
|
|
656
664
|
showMain: currentMain,
|
|
665
|
+
modelColumn,
|
|
657
666
|
...idleMarks(),
|
|
658
667
|
});
|
|
659
668
|
spent += Math.max(0, performance.now() - renderStart);
|
|
@@ -854,6 +863,10 @@ export async function showAgentPanel(session, ui, selectId) {
|
|
|
854
863
|
let cachedRowLines = [];
|
|
855
864
|
let materializedScroll = 0;
|
|
856
865
|
let tick;
|
|
866
|
+
const modelColumn = new ModelColumn(() => {
|
|
867
|
+
cachedRows = undefined;
|
|
868
|
+
tui.requestRender();
|
|
869
|
+
});
|
|
857
870
|
const finish = () => {
|
|
858
871
|
if (finished)
|
|
859
872
|
return;
|
|
@@ -1025,6 +1038,7 @@ export async function showAgentPanel(session, ui, selectId) {
|
|
|
1025
1038
|
faded,
|
|
1026
1039
|
scroll: focus.scroll,
|
|
1027
1040
|
showMain: focus.showMain,
|
|
1041
|
+
modelColumn,
|
|
1028
1042
|
...focusMarks(),
|
|
1029
1043
|
});
|
|
1030
1044
|
}
|
|
@@ -1048,6 +1062,7 @@ export async function showAgentPanel(session, ui, selectId) {
|
|
|
1048
1062
|
faded,
|
|
1049
1063
|
scroll: focus.scroll,
|
|
1050
1064
|
showMain: focus.showMain,
|
|
1065
|
+
modelColumn,
|
|
1051
1066
|
...focusMarks(),
|
|
1052
1067
|
});
|
|
1053
1068
|
cachedRows = currentRows;
|
|
@@ -1104,6 +1119,7 @@ export async function showAgentPanel(session, ui, selectId) {
|
|
|
1104
1119
|
disposed = true;
|
|
1105
1120
|
if (tick !== undefined)
|
|
1106
1121
|
clearInterval(tick);
|
|
1122
|
+
modelColumn.dispose();
|
|
1107
1123
|
unsubscribe();
|
|
1108
1124
|
if (!finished)
|
|
1109
1125
|
queueMicrotask(finish);
|