mirror of
https://github.com/getpaseo/paseo.git
synced 2026-07-29 12:01:31 +00:00
Replay bracketed paste in terminal preamble
This commit is contained in:
@@ -106,6 +106,7 @@ describe("TerminalInputModeTracker", () => {
|
||||
applicationCursorKeys: false,
|
||||
bracketedPaste: true,
|
||||
});
|
||||
expect(tracker.getPreamble()).toBe("\x1b[?2004h");
|
||||
|
||||
expect(tracker.feed("\x1b[?2004l").changed).toBe(true);
|
||||
expect(tracker.getState()).toEqual({
|
||||
@@ -114,6 +115,7 @@ describe("TerminalInputModeTracker", () => {
|
||||
applicationCursorKeys: false,
|
||||
bracketedPaste: false,
|
||||
});
|
||||
expect(tracker.getPreamble()).toBe("");
|
||||
});
|
||||
|
||||
it("ignores encoded key input sequences", () => {
|
||||
|
||||
@@ -156,6 +156,9 @@ export class TerminalInputModeTracker {
|
||||
if (this.applicationCursorKeys) {
|
||||
parts.push("\x1b[?1h");
|
||||
}
|
||||
if (this.bracketedPaste) {
|
||||
parts.push("\x1b[?2004h");
|
||||
}
|
||||
return parts.join("");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user