@oh-my-pi/pi-tui 18.9.1 → 18.10.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/CHANGELOG.md +39 -0
- package/dist/types/app-keybindings.d.ts +5 -0
- package/dist/types/chrome/transcript-container.d.ts +5 -0
- package/dist/types/debug-server.d.ts +2 -0
- package/dist/types/overlays/ask-dialog.d.ts +2 -2
- package/dist/types/prompt/composer.d.ts +1 -20
- package/dist/types/tmux.d.ts +10 -0
- package/dist/types/tui.d.ts +10 -3
- package/package.json +9 -9
- package/src/app-keybindings.ts +5 -0
- package/src/chrome/transcript-container.ts +224 -30
- package/src/debug-server.ts +51 -69
- package/src/hotkeys-markdown.ts +1 -0
- package/src/overlays/ask-dialog.ts +111 -31
- package/src/prompt/composer.ts +35 -72
- package/src/terminal.ts +39 -0
- package/src/tmux.ts +43 -0
- package/src/tui.ts +27 -4
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,45 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [18.10.0] - 2026-10-12
|
|
6
|
+
|
|
7
|
+
### Breaking Changes
|
|
8
|
+
|
|
9
|
+
- Removed `RuntimeChildrenOptions.transient` and `Component.retireDisplacedTranscript`: the composer now bills all chrome below the transcript at the smallest height it has rendered, so no root opts in or out ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
|
|
13
|
+
- Added the `app.ask.hide` keybinding (default `Alt+H`) and Hide/Show actions on `AskDialogComponent`, which collapse the dialog to a single line while its question stays pending ([#15400](https://github.com/can1357/oh-my-pi/pull/15400) by [@H4vC](https://github.com/H4vC))
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
|
|
17
|
+
- The `OMP_TUI_DEBUG` control socket now uses the native IPC transport: it is owner-only and no longer replaces a socket another live process is serving.
|
|
18
|
+
- Transcript rows pushed aside by an open dialog, report or HUD now reach scrollback when it closes or newer output pushes them out, instead of while it is open ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
19
|
+
- A transcript block straddling the top of the screen now sends only its off-screen rows to scrollback; the rest stays live ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
20
|
+
|
|
21
|
+
### Fixed
|
|
22
|
+
|
|
23
|
+
- Fixed blank rows opening under the editor after an ask or other inline dialog, command report or todo/loader HUD closed in a session that had filled the screen; the screen now refills with the transcript ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
24
|
+
- Fixed the editor rising above blank rows when a live tool preview collapses under scrolled-off output; it now stays on the bottom row ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
25
|
+
- Fixed blank rows opening inside a streamed answer when the working loader went away at the end of a turn ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
26
|
+
- Fixed a split transcript block dropping punctuation-only rows it reveals after the split (such as a tool pane's rule line on expand); the seam now stops before them instead of treating them as already committed ([#15420](https://github.com/can1357/oh-my-pi/pull/15420) by [@H4vC](https://github.com/H4vC))
|
|
27
|
+
- Fixed a split transcript block fingerprinting measured rows instead of the bytes committed to scrollback, which could duplicate a SIXEL image prefix once its pending encode landed ([#15420](https://github.com/can1357/oh-my-pi/pull/15420) by [@H4vC](https://github.com/H4vC))
|
|
28
|
+
- Fixed a transcript block straddling the top of the screen losing its off-screen rows when the inline-image limit demoted its images to text in the same frame; those rows now reach scrollback as text
|
|
29
|
+
|
|
30
|
+
### Removed
|
|
31
|
+
|
|
32
|
+
- Removed `Composer.pinInputToBottom()`; the composer keeps the input on the bottom row by itself ([#15405](https://github.com/can1357/oh-my-pi/pull/15405) by [@H4vC](https://github.com/H4vC))
|
|
33
|
+
|
|
34
|
+
## [18.9.2] - 2026-10-11
|
|
35
|
+
|
|
36
|
+
### Added
|
|
37
|
+
|
|
38
|
+
- Added native TSP rendering support for Tern terminal sessions running inside tmux, with automatic session detection and safe title-setting behavior.
|
|
39
|
+
|
|
40
|
+
### Fixed
|
|
41
|
+
|
|
42
|
+
- Improved responsiveness when inserting assistant messages after tool calls in long transcripts.
|
|
43
|
+
|
|
5
44
|
## [18.9.1] - 2026-10-11
|
|
6
45
|
|
|
7
46
|
### Fixed
|
|
@@ -17,6 +17,7 @@ interface AppKeybindings {
|
|
|
17
17
|
"app.model.selectTemporary": true;
|
|
18
18
|
"app.tools.expand": true;
|
|
19
19
|
"app.tools.toggleVisibility": true;
|
|
20
|
+
"app.ask.hide": true;
|
|
20
21
|
"app.editor.external": true;
|
|
21
22
|
"app.message.followUp": true;
|
|
22
23
|
"app.retry": true;
|
|
@@ -238,6 +239,10 @@ export declare const KEYBINDINGS: {
|
|
|
238
239
|
readonly defaultKeys: "ctrl+shift+o";
|
|
239
240
|
readonly description: "Show or hide tool activity";
|
|
240
241
|
};
|
|
242
|
+
readonly "app.ask.hide": {
|
|
243
|
+
readonly defaultKeys: "alt+h";
|
|
244
|
+
readonly description: "Hide or show a pending ask dialog";
|
|
245
|
+
};
|
|
241
246
|
readonly "app.editor.external": {
|
|
242
247
|
readonly defaultKeys: "ctrl+g";
|
|
243
248
|
readonly description: "Open external editor";
|
|
@@ -63,6 +63,11 @@ export interface TranscriptViewportSpan {
|
|
|
63
63
|
export declare class TranscriptContainer extends Container {
|
|
64
64
|
#private;
|
|
65
65
|
addChild(component: Component): void;
|
|
66
|
+
/**
|
|
67
|
+
* `#entries` mirrors `children`; move both together or the next `#syncEntries`
|
|
68
|
+
* pays a full O(n) rebuild.
|
|
69
|
+
*/
|
|
70
|
+
insertChildAt(component: Component, index: number): void;
|
|
66
71
|
/** Removes `component` if {@link canRemoveBlock} allows it; otherwise does nothing. */
|
|
67
72
|
removeChild(component: Component): void;
|
|
68
73
|
clear(): void;
|
|
@@ -22,6 +22,8 @@ export interface TuiDebugTree {
|
|
|
22
22
|
export declare class TuiDebugServer {
|
|
23
23
|
#private;
|
|
24
24
|
constructor(tui: TUI, path: string);
|
|
25
|
+
/** Resolves true once the socket accepts connections, false if listen failed or the server stopped first. */
|
|
26
|
+
get ready(): Promise<boolean>;
|
|
25
27
|
start(): void;
|
|
26
28
|
stop(): void;
|
|
27
29
|
}
|
|
@@ -88,7 +88,6 @@ export declare class AskDialogComponent implements Component {
|
|
|
88
88
|
#private;
|
|
89
89
|
private readonly callbacks;
|
|
90
90
|
private readonly options;
|
|
91
|
-
readonly retireDisplacedTranscript = true;
|
|
92
91
|
constructor(questions: ExtensionAskDialogQuestion[], callbacks: AskDialogCallbacks, options?: AskDialogOptions);
|
|
93
92
|
invalidate(): void;
|
|
94
93
|
dispose(): void;
|
|
@@ -112,7 +111,8 @@ export declare class AskDialogComponent implements Component {
|
|
|
112
111
|
* Pointer actions: a tab click switches to it; a click on an answer row is
|
|
113
112
|
* Enter on it (Space for a multi-select option, so it toggles; its
|
|
114
113
|
* double-click `activate` is Enter); the action bar's Submit, Note and Skip
|
|
115
|
-
* run exactly what Enter, `n` and Esc run on the highlighted row
|
|
114
|
+
* run exactly what Enter, `n` and Esc run on the highlighted row; Hide/Show
|
|
115
|
+
* collapse and restore the dialog.
|
|
116
116
|
*/
|
|
117
117
|
handleNativeEvent(event: NativeUiEvent): void;
|
|
118
118
|
}
|
|
@@ -50,18 +50,8 @@ export interface ComposerOptions {
|
|
|
50
50
|
readonly exit?: (code: number) => void;
|
|
51
51
|
readonly now?: () => number;
|
|
52
52
|
}
|
|
53
|
-
/** How {@link Composer.setRuntimeChildren}
|
|
53
|
+
/** How {@link Composer.setRuntimeChildren} lays out the roots below the transcript. */
|
|
54
54
|
export interface RuntimeChildrenOptions {
|
|
55
|
-
/**
|
|
56
|
-
* Below-transcript roots whose growth is momentary (inline dialogs, a tall
|
|
57
|
-
* multi-line editor). They are billed at their smallest height so expansion
|
|
58
|
-
* clips the live tail instead of retiring rows a later shrink could not
|
|
59
|
-
* reclaim (#11007). Every other root is billed at its current height, so
|
|
60
|
-
* settled rows it displaces retire to native scrollback. Decision panels
|
|
61
|
-
* declaring `retireDisplacedTranscript` opt out of this floor even when
|
|
62
|
-
* mounted as a child of a transient editor container.
|
|
63
|
-
*/
|
|
64
|
-
readonly transient?: readonly Component[];
|
|
65
55
|
/**
|
|
66
56
|
* Dock order on a TSP terminal (no status strip; the composer carries its
|
|
67
57
|
* facts): the native dock stacks HUD pills, the working row and queued messages over
|
|
@@ -123,15 +113,6 @@ export declare class Composer implements TerminalFrameProvider, NativeSurfacePro
|
|
|
123
113
|
* the screen rows left above them; `undefined` before `root` was laid out.
|
|
124
114
|
*/
|
|
125
115
|
rowsBelow(root: Component): number | undefined;
|
|
126
|
-
/**
|
|
127
|
-
* Keep the input on the bottom row while the live rows cannot fill the
|
|
128
|
-
* screen, as after an inline decision panel closes. A tall block that just
|
|
129
|
-
* left the chrome above the editor (a command report) may have scrolled
|
|
130
|
-
* rows into native history that cannot be pulled back; without the pin the
|
|
131
|
-
* editor would jump up to where the shorter frame now ends. The pin lifts
|
|
132
|
-
* once live rows fill the screen again.
|
|
133
|
-
*/
|
|
134
|
-
pinInputToBottom(): void;
|
|
135
116
|
/** Compose the bounded mutable viewport and the next ordered history append. */
|
|
136
117
|
renderFrame(viewport: ViewportSize): TerminalFramePlan;
|
|
137
118
|
/**
|
package/dist/types/tmux.d.ts
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
export { wrapTmuxPassthrough } from "./multiplexers/tmux.js";
|
|
2
2
|
/** Pass a control sequence through tmux, leaving direct-terminal output unchanged. */
|
|
3
3
|
export declare function wrapTmuxPassthroughIfNeeded(payload: string, env?: NodeJS.ProcessEnv): string;
|
|
4
|
+
/**
|
|
5
|
+
* Whether the terminal hosting this tmux session draws TSP programs natively:
|
|
6
|
+
* it sets the session user option `@tern-tsp` while it watches the session.
|
|
7
|
+
*/
|
|
8
|
+
export declare function tmuxSessionSpeaksTsp(env?: NodeJS.ProcessEnv): boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Stop (`on` false) or restore (`on` true) tmux turning this pane's APC
|
|
11
|
+
* strings into its title, which would otherwise swallow every TSP message.
|
|
12
|
+
*/
|
|
13
|
+
export declare function setTmuxPaneApcTitles(on: boolean, env?: NodeJS.ProcessEnv): void;
|
|
4
14
|
/**
|
|
5
15
|
* Resolve the terminal emulator name recorded for this tmux client.
|
|
6
16
|
*
|
package/dist/types/tui.d.ts
CHANGED
|
@@ -115,9 +115,6 @@ export interface Component {
|
|
|
115
115
|
* last time.
|
|
116
116
|
*/
|
|
117
117
|
render(width: number): readonly string[];
|
|
118
|
-
/** Inline decision panels must keep displaced settled transcript rows in
|
|
119
|
-
* native scrollback even when mounted inside a transient editor container. */
|
|
120
|
-
readonly retireDisplacedTranscript?: boolean;
|
|
121
118
|
/**
|
|
122
119
|
* Describe the component semantically for a Tern Surface Protocol
|
|
123
120
|
* terminal (see `native/node.ts`). Called instead of `render()` when the
|
|
@@ -440,6 +437,16 @@ export declare class TUI extends Container {
|
|
|
440
437
|
top: number;
|
|
441
438
|
length: number;
|
|
442
439
|
};
|
|
440
|
+
/**
|
|
441
|
+
* Rows of native history the last paint left on screen above a mutable
|
|
442
|
+
* viewport that reached the bottom row, or `undefined` when that paint left
|
|
443
|
+
* rows free below it (or none happened, or a destructive reset will repaint
|
|
444
|
+
* from row zero). Rows above a bottom-reaching viewport may already sit in
|
|
445
|
+
* native scrollback, which a later shrink cannot pull back down.
|
|
446
|
+
*/
|
|
447
|
+
getFilledHistoryRows(): number | undefined;
|
|
448
|
+
/** Whether native history holds rows the frame provider committed since the last destructive reset. */
|
|
449
|
+
hasProviderHistory(): boolean;
|
|
443
450
|
/**
|
|
444
451
|
* Probe for opt-in normal-buffer click capture. The provider is read every
|
|
445
452
|
* frame; while it returns true (and no fullscreen overlay owns the
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "module",
|
|
3
3
|
"name": "@oh-my-pi/pi-tui",
|
|
4
|
-
"version": "18.
|
|
4
|
+
"version": "18.10.0",
|
|
5
5
|
"description": "Terminal User Interface library with differential rendering for efficient text-based applications",
|
|
6
6
|
"homepage": "https://omp.sh",
|
|
7
7
|
"author": {
|
|
@@ -41,14 +41,14 @@
|
|
|
41
41
|
"gen:glyphs": "bun scripts/gen-glyphs.ts"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@oh-my-pi/omptype": "18.
|
|
45
|
-
"@oh-my-pi/pi-agent-core": "18.
|
|
46
|
-
"@oh-my-pi/pi-ai": "18.
|
|
47
|
-
"@oh-my-pi/pi-catalog": "18.
|
|
48
|
-
"@oh-my-pi/pi-natives": "18.
|
|
49
|
-
"@oh-my-pi/pi-utils": "18.
|
|
50
|
-
"@oh-my-pi/pi-wire": "18.
|
|
51
|
-
"@oh-my-pi/snapcompact": "18.
|
|
44
|
+
"@oh-my-pi/omptype": "18.10.0",
|
|
45
|
+
"@oh-my-pi/pi-agent-core": "18.10.0",
|
|
46
|
+
"@oh-my-pi/pi-ai": "18.10.0",
|
|
47
|
+
"@oh-my-pi/pi-catalog": "18.10.0",
|
|
48
|
+
"@oh-my-pi/pi-natives": "18.10.0",
|
|
49
|
+
"@oh-my-pi/pi-utils": "18.10.0",
|
|
50
|
+
"@oh-my-pi/pi-wire": "18.10.0",
|
|
51
|
+
"@oh-my-pi/snapcompact": "18.10.0"
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
54
|
"kitty-vt-wasm": "^0.2.0"
|
package/src/app-keybindings.ts
CHANGED
|
@@ -37,6 +37,7 @@ interface AppKeybindings {
|
|
|
37
37
|
"app.model.selectTemporary": true;
|
|
38
38
|
"app.tools.expand": true;
|
|
39
39
|
"app.tools.toggleVisibility": true;
|
|
40
|
+
"app.ask.hide": true;
|
|
40
41
|
"app.editor.external": true;
|
|
41
42
|
"app.message.followUp": true;
|
|
42
43
|
"app.retry": true;
|
|
@@ -138,6 +139,10 @@ export const KEYBINDINGS = {
|
|
|
138
139
|
defaultKeys: "ctrl+shift+o",
|
|
139
140
|
description: "Show or hide tool activity",
|
|
140
141
|
},
|
|
142
|
+
"app.ask.hide": {
|
|
143
|
+
defaultKeys: "alt+h",
|
|
144
|
+
description: "Hide or show a pending ask dialog",
|
|
145
|
+
},
|
|
141
146
|
"app.editor.external": {
|
|
142
147
|
defaultKeys: "ctrl+g",
|
|
143
148
|
description: "Open external editor",
|