@timurproko/a1 0.2.7-dev.1269 → 0.2.7-dev.1275
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 +6 -0
- package/dist/app/session-shell/apps-dialog.d.ts +33 -0
- package/dist/app/session-shell/apps-dialog.js +61 -0
- package/dist/app/session-shell/dialog-coordinator.d.ts +8 -0
- package/dist/app/session-shell/dialog-coordinator.js +72 -3
- package/dist/app/session-shell/session-selectors.d.ts +1 -1
- package/dist/app/session-shell/session-selectors.js +1 -1
- package/dist/app/session-shell/session-shell.js +9 -3
- package/dist/app/session-shell/shell-host.d.ts +1 -0
- package/dist/app/session-shell/shell-host.js +22 -11
- package/dist/app/session-shell/workflow-output.js +12 -0
- package/dist/app/session-shell/workflow-router.d.ts +1 -1
- package/dist/composition/owned-ui.js +17 -13
- package/dist/contracts/owned-ui/session-presenters.d.ts +1 -1
- package/dist/contracts/owned-ui/session-workflows.d.ts +3 -1
- package/dist/contracts/owned-ui/shell-components.d.ts +2 -0
- package/dist/contracts/presentation/progress-palette.generated.d.ts +1 -1
- package/dist/contracts/presentation/progress-palette.generated.js +1 -1
- package/dist/contracts/presentation/terminal.d.ts +4 -0
- package/dist/contracts/presentation/theme.d.ts +2 -0
- package/dist/foundation/lifecycle/user-exports.d.ts +5 -0
- package/dist/foundation/lifecycle/user-exports.js +37 -0
- package/dist/foundation/startup/startup-descriptor.js +2 -2
- package/dist/integrations/pi/components/models-dialog-loader.d.ts +11 -0
- package/dist/integrations/pi/components/models-dialog-loader.js +45 -0
- package/dist/integrations/pi/components/models-dialog.d.ts +2 -0
- package/dist/integrations/pi/components/models-dialog.js +13 -7
- package/dist/integrations/pi/components/resources/builtin-themes.d.ts +2 -2
- package/dist/integrations/pi/components/resources/builtin-themes.js +2 -2
- package/dist/integrations/pi/components/shell-editor-autocomplete.js +21 -15
- package/dist/integrations/pi/components/shell-footer-status.js +3 -2
- package/dist/integrations/pi/components/shell-presenters-info.js +1 -1
- package/dist/integrations/pi/components/shell-presenters-transcript.js +3 -1
- package/dist/integrations/pi/components/shell-selectors-dialogs.d.ts +2 -1
- package/dist/integrations/pi/components/shell-selectors-dialogs.js +2 -8
- package/dist/integrations/pi/components/theme.d.ts +2 -0
- package/dist/integrations/pi/components/theme.js +5 -0
- package/dist/integrations/pi/components/upstream/adjacent/core/keybindings.d.ts +8 -7
- package/dist/integrations/pi/components/upstream/adjacent/core/keybindings.js +13 -7
- package/dist/integrations/pi/components/upstream/assets/earendil-image.json +2 -2
- package/dist/integrations/pi/components/upstream/components/countdown-timer.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/earendil-announcement.js +1 -1
- package/dist/integrations/pi/components/upstream/components/extension-editor.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/extension-editor.js +1 -1
- package/dist/integrations/pi/components/upstream/components/extension-input.js +1 -1
- package/dist/integrations/pi/components/upstream/components/extension-selector.js +9 -2
- package/dist/integrations/pi/components/upstream/components/mermaid.d.ts +2 -1
- package/dist/integrations/pi/components/upstream/components/mermaid.js +26 -21
- package/dist/integrations/pi/components/upstream/components/owned-editor.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/owned-editor.js +1 -1
- package/dist/integrations/pi/components/upstream/components/pi-logo.js +1 -1
- package/dist/integrations/pi/components/upstream/components/scoped-models-selector.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/session-footer.js +9 -14
- package/dist/integrations/pi/components/upstream/components/session-selector-search.js +1 -1
- package/dist/integrations/pi/components/upstream/components/session-selector.js +1 -1
- package/dist/integrations/pi/components/upstream/components/skill-invocation-message.d.ts +6 -2
- package/dist/integrations/pi/components/upstream/components/skill-invocation-message.js +27 -3
- package/dist/integrations/pi/components/upstream/components/status-indicator.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/status-indicator.js +1 -1
- package/dist/integrations/pi/components/upstream/components/themed-text.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/themed-text.js +1 -1
- package/dist/integrations/pi/components/upstream/components/thinking-selector.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/thinking-selector.js +1 -1
- package/dist/integrations/pi/components/upstream/components/tool-execution.js +1 -1
- package/dist/integrations/pi/components/upstream/components/tree-selector.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/components/tree-selector.js +7 -6
- package/dist/integrations/pi/components/upstream/components/trust-selector.js +1 -1
- package/dist/integrations/pi/components/upstream/external-editor.js +1 -1
- package/dist/integrations/pi/components/upstream/history/editor-core.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/history/editor-core.js +2 -2
- package/dist/integrations/pi/components/upstream/history/kill-ring.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/history/kill-ring.js +1 -1
- package/dist/integrations/pi/components/upstream/history/printable-key.js +1 -1
- package/dist/integrations/pi/components/upstream/history/text-helpers.js +1 -1
- package/dist/integrations/pi/components/upstream/history/undo-stack.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/history/undo-stack.js +1 -1
- package/dist/integrations/pi/components/upstream/history/word-navigation.js +1 -1
- package/dist/integrations/pi/components/upstream/model-search.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/program-status-reporter.d.ts +1 -1
- package/dist/integrations/pi/components/upstream/theme/theme.js +1 -1
- package/dist/integrations/pi/engine/adapter.d.ts +1 -1
- package/dist/integrations/pi/engine/adapter.js +3 -3
- package/dist/integrations/pi/engine/host.d.ts +1 -1
- package/dist/integrations/pi/engine/resources/changelog.json +4 -4
- package/dist/integrations/pi/engine/workflow-export.d.ts +4 -0
- package/dist/integrations/pi/engine/workflow-export.js +25 -0
- package/dist/integrations/pi/engine/workflow-runner.d.ts +1 -0
- package/dist/integrations/pi/engine/workflow-runner.js +6 -10
- package/dist/integrations/pi/engine/workflow-support.d.ts +2 -1
- package/dist/integrations/pi/engine/workflow-support.js +28 -25
- package/dist/integrations/pi/engine/workflows.d.ts +6 -1
- package/dist/integrations/pi/engine/workflows.js +1 -1
- package/dist/integrations/pi/session-presenters/presentation.js +2 -1
- package/dist/integrations/pi/session-presenters/presenters.js +22 -10
- package/dist/integrations/pi/startup-public.js +289 -240
- package/dist/integrations/pi/startup-public.manifest.json +579 -363
- package/dist/integrations/pi/tui-runtime/adapter.js +3 -1
- package/dist/integrations/pi/tui-runtime/damage-aware-terminal.d.ts +1 -1
- package/dist/integrations/pi/tui-runtime/damage-aware-terminal.js +1 -1
- package/dist/integrations/pi/tui-runtime/overlay-geometry.d.ts +5 -2
- package/dist/integrations/pi/tui-runtime/overlay-geometry.js +12 -2
- package/dist/runtime-payload-inventory.json +8044 -6930
- package/dist/ui/components/dialog-panel.d.ts +4 -3
- package/dist/ui/components/dialog-panel.js +9 -13
- package/dist/ui/components/index.d.ts +1 -1
- package/dist/ui/components/index.js +1 -1
- package/dist/ui/components/scrollbar.d.ts +2 -2
- package/dist/ui/components/scrollbar.js +2 -2
- package/dist/ui/components/spans.d.ts +7 -0
- package/dist/ui/components/spans.js +63 -1
- package/dist/ui/components/surface.js +1 -1
- package/docs/architecture/prompt-suggestions.md +1 -1
- package/docs/architecture/ui-reference-provenance.md +2 -1
- package/docs/features/prompt-history.md +1 -1
- package/docs/features/session-exports.md +15 -0
- package/docs/local-worktree-cleanup.md +24 -0
- package/package.json +6 -6
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/mermaid.ts.
|
|
4
4
|
* Modifications: Mechanical pinned source port with private imports remapped to public package-root
|
|
5
5
|
* types/APIs and A1-owned theme boundaries; behavior remains acceptance-tested.
|
|
6
6
|
* Deviations: none.
|
|
7
7
|
*/
|
|
8
|
-
import { Marked } from "@earendil-works/pi-tui";
|
|
9
|
-
import { render } from "
|
|
8
|
+
import { getCapabilities, Marked } from "@earendil-works/pi-tui";
|
|
9
|
+
import { render, toAnsi } from "lovely-mermaid";
|
|
10
10
|
const markdownParser = new Marked();
|
|
11
11
|
function isMermaid(token) {
|
|
12
12
|
return token.type === "code" && token.lang?.trim().split(/\s+/, 1)[0]?.toLowerCase() === "mermaid";
|
|
@@ -30,31 +30,36 @@ function codeSpan(line) {
|
|
|
30
30
|
const padding = content.startsWith("`") || content.endsWith("`") ? " " : "";
|
|
31
31
|
return `${fence}${padding}${content}${padding}${fence}`;
|
|
32
32
|
}
|
|
33
|
-
function styleSpan(span, theme) {
|
|
34
|
-
switch (span.cls) {
|
|
35
|
-
case "border":
|
|
36
|
-
return theme.fg("borderMuted", span.text);
|
|
37
|
-
case "text":
|
|
38
|
-
return theme.fg("text", span.text);
|
|
39
|
-
case "edge":
|
|
40
|
-
return theme.fg("accent", span.text);
|
|
41
|
-
case "edgeLabel":
|
|
42
|
-
return theme.fg("muted", span.text);
|
|
43
|
-
case "title":
|
|
44
|
-
return theme.fg("accent", theme.bold(span.text));
|
|
45
|
-
case "none":
|
|
46
|
-
return span.text;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
33
|
function themedLines(art, theme) {
|
|
50
|
-
|
|
34
|
+
const foreground = (color) => theme.getFgAnsi(color).slice(2, -1);
|
|
35
|
+
const ansiTheme = {
|
|
36
|
+
border: foreground("borderMuted"),
|
|
37
|
+
text: foreground("text"),
|
|
38
|
+
edge: foreground("accent"),
|
|
39
|
+
edgeLabel: foreground("text"),
|
|
40
|
+
title: `1;${foreground("accent")}`,
|
|
41
|
+
};
|
|
42
|
+
const linkLabels = getCapabilities().hyperlinks;
|
|
43
|
+
const displayArt = {
|
|
44
|
+
...art,
|
|
45
|
+
// Only osc 8 the text, not the whole box.
|
|
46
|
+
styled: art.styled.map((row) => row.map((span) => {
|
|
47
|
+
if (span.href === undefined || (linkLabels && span.role === "text"))
|
|
48
|
+
return span;
|
|
49
|
+
const unlinked = { ...span };
|
|
50
|
+
delete unlinked.href;
|
|
51
|
+
return unlinked;
|
|
52
|
+
})),
|
|
53
|
+
};
|
|
54
|
+
return toAnsi(displayArt, ansiTheme);
|
|
51
55
|
}
|
|
52
56
|
/** Create a transformer that replaces top-level Mermaid code blocks with Unicode terminal diagrams. */
|
|
53
57
|
export function createMermaidMarkdownTransformer(options) {
|
|
54
58
|
return (markdown, context) => {
|
|
55
59
|
const mode = options.getMode();
|
|
60
|
+
// Diagrams render in user and assistant text and in model-written summaries, not in thinking or other surfaces.
|
|
56
61
|
if (mode === "off" ||
|
|
57
|
-
context.messageType
|
|
62
|
+
(context.messageType !== "user" && context.messageType !== "assistant" && context.messageType !== "summary") ||
|
|
58
63
|
(context.isStreaming && mode !== "streaming")) {
|
|
59
64
|
return markdown;
|
|
60
65
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/custom-editor.ts.
|
|
4
4
|
* Modifications: A1-owned class name and synchronized A1 keybinding contract replace the nominal
|
|
5
5
|
* private upstream keybinding constructor dependency; bare A1 injects the shared Settings/agent input
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/custom-editor.ts.
|
|
4
4
|
* Modifications: A1-owned class name and synchronized A1 keybinding contract replace the nominal
|
|
5
5
|
* private upstream keybinding constructor dependency; bare A1 injects the shared Settings/agent input
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/pi-logo.ts.
|
|
4
4
|
* Modifications: Remapped the private theme import to A1's public-backed adapter and composed the
|
|
5
5
|
* fixed-color logo into the owned startup header.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/scoped-models-selector.ts.
|
|
4
4
|
* Modifications: Source-synchronized scoped-model selector port: preserve session-only toggles,
|
|
5
5
|
* search, bulk/provider/reorder actions, dirty state, Ctrl+S persistence, refresh status,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/footer.ts.
|
|
4
|
-
* Modifications: Owned UI/routing; A1 level color, linked PRs
|
|
5
|
-
* secondary-accent name reveals after stats; Pi unchanged.
|
|
4
|
+
* Modifications: Owned UI/routing; A1 level color, linked PRs after a dim dot separator, dim ellipsis,
|
|
5
|
+
* model priority, and secondary-accent name reveals after stats; Pi unchanged.
|
|
6
6
|
* Deviations: owned-status-level-color, owned-pull-request-badge, owned-footer-ellipsis,
|
|
7
7
|
* owned-footer-model-priority, owned-session-name-reveal.
|
|
8
8
|
*/
|
|
@@ -77,17 +77,12 @@ export class SessionFooter {
|
|
|
77
77
|
pathRow = theme.fg("dim", this.profile === "pi" && sessionName ? `${pwd} • ${sessionName}` : pwd);
|
|
78
78
|
}
|
|
79
79
|
else {
|
|
80
|
-
const badge = theme.fg("
|
|
81
|
-
|
|
82
|
-
const
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
pathRow = truncateToWidth(theme.fg("dim", pwd), width - visibleWidth(badge), dimEllipsis) + badge;
|
|
87
|
-
}
|
|
88
|
-
else {
|
|
89
|
-
pathRow = truncateToWidth(badge, width, dimEllipsis);
|
|
90
|
-
}
|
|
80
|
+
const badge = hyperlink(theme.fg("mdLink", `#${pullRequest.number}`), pullRequest.url);
|
|
81
|
+
const separator = theme.fg("dim", " • ");
|
|
82
|
+
const budget = width - visibleWidth(badge) - visibleWidth(separator);
|
|
83
|
+
const prefix = budget > 0 ? truncateToWidth(theme.fg("dim", pwd), budget, dimEllipsis) : "";
|
|
84
|
+
pathRow = visibleWidth(badge) > width ? truncateToWidth(dimEllipsis, width, "")
|
|
85
|
+
: (visibleWidth(prefix) > 0 ? prefix + separator : "") + badge;
|
|
91
86
|
}
|
|
92
87
|
const parts = [];
|
|
93
88
|
if (input)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/session-selector-search.ts.
|
|
4
4
|
* Modifications: Source-synchronized session search port with only the public SessionInfo type import
|
|
5
5
|
* remapped.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/session-selector.ts.
|
|
4
4
|
* Modifications: Source-synchronized session selector port: preserve threaded/current/all scope,
|
|
5
5
|
* search, sort, named/path filters, rename, delete confirmation, active-session protection,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/skill-invocation-message.ts.
|
|
4
4
|
* Modifications: Mechanical port uses A1's public pi-tui instance, owned theme boundary, and
|
|
5
5
|
* root-instance keybinding registry because the public coding-agent component closes over a second
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* Deviations: none.
|
|
8
8
|
*/
|
|
9
9
|
import { Box, type MarkdownTheme } from "@earendil-works/pi-tui";
|
|
10
|
+
import type { MarkdownTransformer } from "@earendil-works/pi-coding-agent";
|
|
10
11
|
export interface SkillInvocationBlock {
|
|
11
12
|
readonly name: string;
|
|
12
13
|
readonly content: string;
|
|
@@ -15,7 +16,10 @@ export declare class SkillInvocationMessageComponent extends Box {
|
|
|
15
16
|
#private;
|
|
16
17
|
private readonly skillBlock;
|
|
17
18
|
private readonly markdownTheme;
|
|
18
|
-
|
|
19
|
+
private readonly markdownTransformers;
|
|
20
|
+
private readonly messageId;
|
|
21
|
+
private readonly timestamp;
|
|
22
|
+
constructor(skillBlock: SkillInvocationBlock, markdownTheme: MarkdownTheme, outputPad?: number, markdownTransformers?: readonly MarkdownTransformer[], messageId?: string, timestamp?: string);
|
|
19
23
|
setExpanded(expanded: boolean): void;
|
|
20
24
|
setOutputPad(outputPad: number): void;
|
|
21
25
|
invalidate(): void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/skill-invocation-message.ts.
|
|
4
4
|
* Modifications: Mechanical port uses A1's public pi-tui instance, owned theme boundary, and
|
|
5
5
|
* root-instance keybinding registry because the public coding-agent component closes over a second
|
|
@@ -12,10 +12,16 @@ export class SkillInvocationMessageComponent extends Box {
|
|
|
12
12
|
#expanded = false;
|
|
13
13
|
skillBlock;
|
|
14
14
|
markdownTheme;
|
|
15
|
-
|
|
15
|
+
markdownTransformers;
|
|
16
|
+
messageId;
|
|
17
|
+
timestamp;
|
|
18
|
+
constructor(skillBlock, markdownTheme, outputPad = 1, markdownTransformers = [], messageId, timestamp) {
|
|
16
19
|
super(outputPad, 1, text => piTheme().bg("customMessageBg", text));
|
|
17
20
|
this.skillBlock = skillBlock;
|
|
18
21
|
this.markdownTheme = markdownTheme;
|
|
22
|
+
this.markdownTransformers = markdownTransformers;
|
|
23
|
+
this.messageId = messageId;
|
|
24
|
+
this.timestamp = timestamp;
|
|
19
25
|
this.#updateDisplay();
|
|
20
26
|
}
|
|
21
27
|
setExpanded(expanded) {
|
|
@@ -36,8 +42,26 @@ export class SkillInvocationMessageComponent extends Box {
|
|
|
36
42
|
const label = piTheme().fg("customMessageLabel", "\x1b[1m[skill]\x1b[22m");
|
|
37
43
|
content.addChild(new Text(label, 0, 0));
|
|
38
44
|
const header = `**${this.skillBlock.name}**\n\n`;
|
|
39
|
-
content.addChild(new Markdown(
|
|
45
|
+
content.addChild(new Markdown(this.skillBlock.content, 0, 0, this.markdownTheme, {
|
|
40
46
|
color: text => piTheme().fg("customMessageText", text),
|
|
47
|
+
}, {
|
|
48
|
+
transform: (markdown, availableWidth) => {
|
|
49
|
+
// Transformers see only skill content, not Pi's header; failed transforms leave it intact.
|
|
50
|
+
let transformed = markdown;
|
|
51
|
+
for (const transformer of this.markdownTransformers) {
|
|
52
|
+
try {
|
|
53
|
+
const next = transformer(transformed, {
|
|
54
|
+
messageType: "custom", isStreaming: false, availableWidth,
|
|
55
|
+
...(this.messageId === undefined ? {} : { messageId: this.messageId }),
|
|
56
|
+
...(this.timestamp === undefined ? {} : { timestamp: this.timestamp }),
|
|
57
|
+
});
|
|
58
|
+
if (typeof next === "string")
|
|
59
|
+
transformed = next;
|
|
60
|
+
}
|
|
61
|
+
catch { /* Preserve the current Markdown and continue with the next transformer. */ }
|
|
62
|
+
}
|
|
63
|
+
return header + transformed;
|
|
64
|
+
},
|
|
41
65
|
}));
|
|
42
66
|
}
|
|
43
67
|
else {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/status-indicator.ts.
|
|
4
4
|
* Modifications: Mechanical source port with public package-root keybinding, Loader, and owned
|
|
5
5
|
* theme/countdown imports plus ECMAScript private fields.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/status-indicator.ts.
|
|
4
4
|
* Modifications: Mechanical source port with public package-root keybinding, Loader, and owned
|
|
5
5
|
* theme/countdown imports plus ECMAScript private fields.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/themed-text.ts.
|
|
4
4
|
* Modifications: Integrated invalidation-aware text into A1's owned startup header and notices;
|
|
5
5
|
* repository formatting only.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/themed-text.ts.
|
|
4
4
|
* Modifications: Integrated invalidation-aware text into A1's owned startup header and notices;
|
|
5
5
|
* repository formatting only.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/thinking-selector.ts.
|
|
4
4
|
* Modifications: Preserve the searchable thinking-level selector, current/default semantics,
|
|
5
5
|
* selection, and focus while accepting the active bare-A1 cycle-key label from the shell, styling the
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/thinking-selector.ts.
|
|
4
4
|
* Modifications: Preserve the searchable thinking-level selector, current/default semantics,
|
|
5
5
|
* selection, and focus while accepting the active bare-A1 cycle-key label from the shell, styling the
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/tool-execution.ts.
|
|
4
4
|
* Modifications: Retain pinned shell/public renderers. Own image conversion; replace private APIs with
|
|
5
5
|
* public/local equivalents. Use bare-A1 secondary-accent read ranges and concise collapse shortcut
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/tree-selector.ts.
|
|
4
4
|
* Modifications: Port remaps public types/components plus owned keybindings/theme helpers while
|
|
5
5
|
* preserving tree behavior; bare A1 uses compact modal chrome and label editing, four-mode
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/tree-selector.ts.
|
|
4
4
|
* Modifications: Port remaps public types/components plus owned keybindings/theme helpers while
|
|
5
5
|
* preserving tree behavior; bare A1 uses compact modal chrome and label editing, four-mode
|
|
@@ -1069,6 +1069,8 @@ class TreeSearchInput {
|
|
|
1069
1069
|
this.input.invalidate();
|
|
1070
1070
|
}
|
|
1071
1071
|
render(width) {
|
|
1072
|
+
if (width <= 0)
|
|
1073
|
+
return [""];
|
|
1072
1074
|
const query = this.treeList.getSearchQuery();
|
|
1073
1075
|
if (query !== this.renderedQuery) {
|
|
1074
1076
|
this.input = Object.assign(new Input(), { focused: this.input.focused });
|
|
@@ -1243,7 +1245,7 @@ export class TreeSelectorComponent extends Container {
|
|
|
1243
1245
|
labelInput = null;
|
|
1244
1246
|
onLabelChangeCallback;
|
|
1245
1247
|
onCopy;
|
|
1246
|
-
// Focusable implementation - propagate to
|
|
1248
|
+
// Focusable implementation - propagate to the active input for IME cursor positioning
|
|
1247
1249
|
_focused = false;
|
|
1248
1250
|
get focused() {
|
|
1249
1251
|
return this._focused;
|
|
@@ -1304,9 +1306,8 @@ export class TreeSelectorComponent extends Container {
|
|
|
1304
1306
|
this.hideLabelInput();
|
|
1305
1307
|
};
|
|
1306
1308
|
this.labelInput.onCancel = () => this.hideLabelInput();
|
|
1307
|
-
//
|
|
1308
|
-
this.
|
|
1309
|
-
this.labelInput.focused = this._focused;
|
|
1309
|
+
// Propagate focus to the active editor, never both inputs.
|
|
1310
|
+
this.focused = this._focused;
|
|
1310
1311
|
this.titleText.setText(theme.fg("accent", theme.bold("Label")));
|
|
1311
1312
|
this.searchInputContainer.clear();
|
|
1312
1313
|
this.treeContainer.clear();
|
|
@@ -1316,7 +1317,7 @@ export class TreeSelectorComponent extends Container {
|
|
|
1316
1317
|
}
|
|
1317
1318
|
hideLabelInput() {
|
|
1318
1319
|
this.labelInput = null;
|
|
1319
|
-
this.
|
|
1320
|
+
this.focused = this._focused;
|
|
1320
1321
|
this.labelInputContainer.clear();
|
|
1321
1322
|
this.restoreTreeContent();
|
|
1322
1323
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/components/trust-selector.ts.
|
|
4
4
|
* Modifications: Mechanical source-synchronized trust selector port with injected public
|
|
5
5
|
* ProjectTrustStore-derived options, remapped owned theme imports, the shared bare-A1 modal shortcut
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/external-editor.ts.
|
|
4
4
|
* Modifications: Mechanical port: retain temporary prompt file, asynchronous inherited-stdio editor
|
|
5
5
|
* process, completion readback, and best-effort cleanup behind the owned extension-editor component.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/components/editor.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, semantic border state with the user-approved numeric-only
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/components/editor.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, semantic border state with the user-approved numeric-only
|
|
@@ -1318,7 +1318,7 @@ export class HistoryEditorCore {
|
|
|
1318
1318
|
const x = Number(idGroup);
|
|
1319
1319
|
if (x <= targetId)
|
|
1320
1320
|
return fullMatch;
|
|
1321
|
-
return `[paste #${x - 1}${suffixGroup}]`;
|
|
1321
|
+
return `[paste #${x - 1}${suffixGroup ?? ""}]`;
|
|
1322
1322
|
}));
|
|
1323
1323
|
}
|
|
1324
1324
|
line = this.state.lines[this.state.cursorLine] || "";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/kill-ring.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/kill-ring.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/keys.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/utils.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/undo-stack.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/undo-stack.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-tui 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-tui 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/tui/src/word-navigation.ts.
|
|
4
4
|
* Modifications: Owned editor core or minimal editor-local helper subset; public imports, strict
|
|
5
5
|
* types, typed persistent-history hooks, and semantic border state. Public terminal runtime/exports
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/model-search.ts.
|
|
4
4
|
* Modifications: Mechanical source-synchronized port preserving pinned model search terms for stateful
|
|
5
5
|
* scoped-model filtering.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/program-status-reporter.ts.
|
|
4
4
|
* Modifications: Remap Pi session events to A1's neutral run events, inject the terminal reporter, use
|
|
5
5
|
* A1's application identity, and clear dialog state when the owned session changes.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Provenance: @earendil-works/pi-coding-agent 1.5.
|
|
2
|
+
* Provenance: @earendil-works/pi-coding-agent 1.5.1 (MIT), commit dd30101cfc5b0609411dd80b6f93adbc14db14cf,
|
|
3
3
|
* packages/coding-agent/src/modes/interactive/theme/theme.ts.
|
|
4
4
|
* Modifications: Source-synchronized theme port: retain pinned theme schema, variable/color
|
|
5
5
|
* resolution, built-in and custom loading, terminal detection, and layout defaults while constructing
|
|
@@ -31,7 +31,7 @@ export interface PiEngineAdapterOptions {
|
|
|
31
31
|
readonly sessionSelection?: PiSessionSelection;
|
|
32
32
|
readonly sessionForkPrompt?: PiSessionForkPrompt;
|
|
33
33
|
readonly createRuntime?: PiEngineRuntimeFactory;
|
|
34
|
-
readonly workflowHost?: PiWorkflowHost
|
|
34
|
+
readonly workflowHost?: Partial<PiWorkflowHost>;
|
|
35
35
|
/**
|
|
36
36
|
* Themes installed on this machine. Supplied because listing them belongs to
|
|
37
37
|
* the component adapter that owns the engine's theme unit; the grammar and the
|
|
@@ -14,7 +14,7 @@ import { PiEngineSettings } from "./settings-port.js";
|
|
|
14
14
|
import { PiSessionEvents } from "./session-events.js";
|
|
15
15
|
import { PiWorkflowContexts } from "./workflow-contexts.js";
|
|
16
16
|
import { PiWorkflowRunner } from "./workflow-runner.js";
|
|
17
|
-
import {
|
|
17
|
+
import { resolveWorkflowHost } from "./workflow-support.js";
|
|
18
18
|
import { EngineViewState, projectSessionView } from "./view-state.js";
|
|
19
19
|
import { createEnginePorts } from "./ports.js";
|
|
20
20
|
/** Explicit flush failure when required delivery was interrupted rather than completed. */
|
|
@@ -98,7 +98,7 @@ export class PiEngineAdapter {
|
|
|
98
98
|
this.#agentDir = options.agentDir ?? getAgentDir();
|
|
99
99
|
this.#sessionId = options.sessionId;
|
|
100
100
|
this.#engineHost = options.engineHost ?? detachedEngineHostPorts();
|
|
101
|
-
this.#workflowHost = options.workflowHost
|
|
101
|
+
this.#workflowHost = resolveWorkflowHost(options.workflowHost);
|
|
102
102
|
this.#workflowInteraction = { prompt: async () => null, notify() { } };
|
|
103
103
|
this.#engine = new PiEngineRuntime({
|
|
104
104
|
cwd: options.cwd ?? process.cwd(),
|
|
@@ -139,7 +139,7 @@ export class PiEngineAdapter {
|
|
|
139
139
|
activeModel: () => this.#state.activeModel,
|
|
140
140
|
emitView: () => { this.#emitView(); },
|
|
141
141
|
});
|
|
142
|
-
this.#workflows = new PiWorkflowRunner({ agentDir: this.#agentDir, host: this.#workflowHost, contexts: this.#contexts }, {
|
|
142
|
+
this.#workflows = new PiWorkflowRunner({ agentDir: this.#agentDir, productMode: options.settingsProductMode ?? "bare", host: this.#workflowHost, contexts: this.#contexts }, {
|
|
143
143
|
session: () => this.#engine.session,
|
|
144
144
|
runtime: () => this.#engine.runtime,
|
|
145
145
|
disposed: () => this.#disposed,
|
|
@@ -28,7 +28,7 @@ export interface PiEngineHostOptions {
|
|
|
28
28
|
readonly announceStartupChangelog?: boolean;
|
|
29
29
|
readonly projectTrustPrompt?: PiProjectTrustPreflightPrompt;
|
|
30
30
|
readonly checkPackageUpdates?: PiEnginePackageUpdateProbe;
|
|
31
|
-
readonly workflowHost?: PiWorkflowHost
|
|
31
|
+
readonly workflowHost?: Partial<PiWorkflowHost>;
|
|
32
32
|
readonly createRuntime?: PiEngineRuntimeFactory;
|
|
33
33
|
/** Installs the process HTTP dispatcher; defaults to the owned undici seam. */
|
|
34
34
|
readonly installHttpDispatcher?: (timeoutMs: number) => void;
|