@simon_he/vue-tui 1.1.7 → 1.1.9
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/dist/cli.cjs
CHANGED
|
@@ -9105,7 +9105,7 @@ function createStdoutRenderer(terminal, options) {
|
|
|
9105
9105
|
}
|
|
9106
9106
|
return end > start ? end : codePointEnd(data, start);
|
|
9107
9107
|
};
|
|
9108
|
-
function writeChunked(data
|
|
9108
|
+
function writeChunked(data) {
|
|
9109
9109
|
if (import_node_buffer3.Buffer.byteLength(data, "utf8") <= chunkSize) {
|
|
9110
9110
|
out.write(data);
|
|
9111
9111
|
return;
|
|
@@ -9115,8 +9115,8 @@ function createStdoutRenderer(terminal, options) {
|
|
|
9115
9115
|
);
|
|
9116
9116
|
try {
|
|
9117
9117
|
for (let start = 0; start < data.length; ) {
|
|
9118
|
-
let end = safeChunkEnd(data, start, chunkSize)
|
|
9119
|
-
out.write(
|
|
9118
|
+
let end = safeChunkEnd(data, start, chunkSize);
|
|
9119
|
+
out.write(data.slice(start, end)), start = end;
|
|
9120
9120
|
}
|
|
9121
9121
|
isDebugEnabled() && getDebugLog().render("writeChunked: chunked write completed");
|
|
9122
9122
|
} catch (e) {
|
|
@@ -9904,12 +9904,12 @@ function createStdoutRenderer(terminal, options) {
|
|
|
9904
9904
|
`terminal graphics frame: draws=${terminalGraphicsDraws}, clears=${terminalGraphicsClears}, bytes=${terminalGraphicsBytes}, activeNext=${nextActiveGraphics.size}`
|
|
9905
9905
|
);
|
|
9906
9906
|
}
|
|
9907
|
-
let emittedCursorPos = null
|
|
9907
|
+
let emittedCursorPos = null;
|
|
9908
9908
|
if (getImeAnchor) {
|
|
9909
9909
|
let anchor = getImeAnchor();
|
|
9910
9910
|
if (anchor) {
|
|
9911
|
-
let { x, y } = clampCellToViewport(anchor, size)
|
|
9912
|
-
|
|
9911
|
+
let { x, y } = clampCellToViewport(anchor, size);
|
|
9912
|
+
(hasFrameOutput || x !== lastCursorX || y !== lastCursorY) && (hasFrameOutput = !0, emittedCursorPos = { x, y }, closeActiveHrefBeforeCursorMove(), frameParts.push(`\x1B[${y + 1 + rowOffset};${x + 1}H`));
|
|
9913
9913
|
}
|
|
9914
9914
|
}
|
|
9915
9915
|
if (!hasFrameOutput) {
|
|
@@ -9972,7 +9972,7 @@ function createStdoutRenderer(terminal, options) {
|
|
|
9972
9972
|
if (writeMode === "chunked")
|
|
9973
9973
|
isDebugEnabled() && getDebugLog().render(
|
|
9974
9974
|
` Using chunked write (chunkSize=${chunkSize}, threshold=${chunkThresholdBytes}, emaMs=${writeEmaMs.toFixed(2)})`
|
|
9975
|
-
), writeChunked(frame
|
|
9975
|
+
), writeChunked(frame);
|
|
9976
9976
|
else if (writeMode === "sync" && canUseSyncStdout) {
|
|
9977
9977
|
isDebugEnabled() && getDebugLog().render(" Using writeSync");
|
|
9978
9978
|
try {
|
package/dist/cli.js
CHANGED
|
@@ -11547,13 +11547,14 @@ function createStdoutRenderer(terminal, options) {
|
|
|
11547
11547
|
* Write data in chunks to avoid overwhelming terminal buffers.
|
|
11548
11548
|
* This is especially important for ghostty which can hang on large writes.
|
|
11549
11549
|
*
|
|
11550
|
-
*
|
|
11551
|
-
*
|
|
11552
|
-
*
|
|
11553
|
-
*
|
|
11554
|
-
*
|
|
11550
|
+
* A chunked write must not interpose anything of its own: the frame's bytes form
|
|
11551
|
+
* one stream of cursor moves and cell writes, so an extra cursor move in the
|
|
11552
|
+
* middle of a span (the IME pin #141 appended after every chunk) painted the
|
|
11553
|
+
* rest of that span at the pin's cell — the input caret — and scrambled the
|
|
11554
|
+
* screen. The frame's own anchor move at its end is the only cursor move the
|
|
11555
|
+
* renderer owns.
|
|
11555
11556
|
*/
|
|
11556
|
-
function writeChunked(data
|
|
11557
|
+
function writeChunked(data) {
|
|
11557
11558
|
if (Buffer.byteLength(data, "utf8") <= chunkSize) {
|
|
11558
11559
|
out.write(data);
|
|
11559
11560
|
return;
|
|
@@ -11562,8 +11563,7 @@ function createStdoutRenderer(terminal, options) {
|
|
|
11562
11563
|
try {
|
|
11563
11564
|
for (let start = 0; start < data.length;) {
|
|
11564
11565
|
const end = safeChunkEnd(data, start, chunkSize);
|
|
11565
|
-
|
|
11566
|
-
out.write(end >= data.length || !pin ? chunk : `${chunk}${pin}`);
|
|
11566
|
+
out.write(data.slice(start, end));
|
|
11567
11567
|
start = end;
|
|
11568
11568
|
}
|
|
11569
11569
|
if (isDebugEnabled()) getDebugLog().render(`writeChunked: chunked write completed`);
|
|
@@ -12673,13 +12673,10 @@ function createStdoutRenderer(terminal, options) {
|
|
|
12673
12673
|
if (isDebugEnabled()) getDebugLog().render(`terminal graphics frame: draws=${terminalGraphicsDraws}, clears=${terminalGraphicsClears}, bytes=${terminalGraphicsBytes}, activeNext=${nextActiveGraphics.size}`);
|
|
12674
12674
|
}
|
|
12675
12675
|
let emittedCursorPos = null;
|
|
12676
|
-
let frameCursorPin = null;
|
|
12677
12676
|
if (getImeAnchor) {
|
|
12678
12677
|
const anchor = getImeAnchor();
|
|
12679
12678
|
if (anchor) {
|
|
12680
12679
|
const { x, y } = clampCellToViewport(anchor, size);
|
|
12681
|
-
const cursorSequence = `\u001B[${y + 1 + rowOffset};${x + 1}H`;
|
|
12682
|
-
frameCursorPin = cursorSequence;
|
|
12683
12680
|
if (hasFrameOutput || x !== lastCursorX || y !== lastCursorY) {
|
|
12684
12681
|
hasFrameOutput = true;
|
|
12685
12682
|
emittedCursorPos = {
|
|
@@ -12687,7 +12684,7 @@ function createStdoutRenderer(terminal, options) {
|
|
|
12687
12684
|
y
|
|
12688
12685
|
};
|
|
12689
12686
|
closeActiveHrefBeforeCursorMove();
|
|
12690
|
-
frameParts.push(
|
|
12687
|
+
frameParts.push(`\u001B[${y + 1 + rowOffset};${x + 1}H`);
|
|
12691
12688
|
}
|
|
12692
12689
|
}
|
|
12693
12690
|
}
|
|
@@ -12778,7 +12775,7 @@ function createStdoutRenderer(terminal, options) {
|
|
|
12778
12775
|
try {
|
|
12779
12776
|
if (writeMode === "chunked") {
|
|
12780
12777
|
if (isDebugEnabled()) getDebugLog().render(` Using chunked write (chunkSize=${chunkSize}, threshold=${chunkThresholdBytes}, emaMs=${writeEmaMs.toFixed(2)})`);
|
|
12781
|
-
writeChunked(frame
|
|
12778
|
+
writeChunked(frame);
|
|
12782
12779
|
} else if (writeMode === "sync" && canUseSyncStdout) {
|
|
12783
12780
|
if (isDebugEnabled()) getDebugLog().render(` Using writeSync`);
|
|
12784
12781
|
try {
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
+
import type { Style } from "../../../../core/types.js";
|
|
1
2
|
import type { MentionPathProvider, MentionSuggestionProvider } from "./promptMentionState.js";
|
|
2
3
|
import type { TInputPlugin } from "./types.js";
|
|
3
4
|
export type { MentionPathProvider, MentionSuggestionProvider } from "./promptMentionState.js";
|
|
4
5
|
export type PromptMentionPluginOptions = Readonly<{
|
|
6
|
+
/** Bisect-only type shim: the 1.1.7 consumer patch declares this option; this release ignores it at runtime. */
|
|
7
|
+
selectedMarkerStyle?: () => Style;
|
|
5
8
|
mentionSuggestionProviders?: readonly MentionSuggestionProvider[];
|
|
6
9
|
mentionPathProvider?: MentionPathProvider;
|
|
7
10
|
}>;
|
package/package.json
CHANGED