@gajae-code/tui 0.12.2 → 0.12.5

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 CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.12.5] - 2026-07-30
6
+
7
+ ## [0.12.4] - 2026-07-30
8
+
9
+ ## [0.12.3] - 2026-07-30
10
+
5
11
  ## [0.12.2] - 2026-07-30
6
12
 
7
13
  ## [0.12.1] - 2026-07-29
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@gajae-code/tui",
4
- "version": "0.12.2",
4
+ "version": "0.12.5",
5
5
  "description": "Terminal User Interface library with differential rendering for efficient text-based applications",
6
6
  "homepage": "https://gajae-code.com",
7
7
  "author": "Yeachan-Heo and Gajae Code Contributors",
@@ -36,8 +36,8 @@
36
36
  "fmt": "biome format --write ."
37
37
  },
38
38
  "dependencies": {
39
- "@gajae-code/natives": "0.12.2",
40
- "@gajae-code/utils": "0.12.2",
39
+ "@gajae-code/natives": "0.12.5",
40
+ "@gajae-code/utils": "0.12.5",
41
41
  "lru-cache": "11.3.6",
42
42
  "marked": "18.0.6"
43
43
  },
package/src/terminal.ts CHANGED
@@ -80,6 +80,7 @@ export function emergencyTerminalRestore(): void {
80
80
  "\x1b[?1000l" + // Disable normal mouse reporting
81
81
  "\x1b[?1002l" + // Disable button-event mouse reporting
82
82
  "\x1b[?1006l" + // Disable SGR extended mouse reporting
83
+ "\x1b[?1007l" + // Disable alternate-scroll wheel-to-cursor translation
83
84
  "\x1b[?2031l" + // Disable Mode 2031 appearance notifications
84
85
  "\x1b[<u" + // Pop kitty keyboard protocol
85
86
  "\x1b[>4;0m" + // Disable modifyOtherKeys fallback
@@ -278,7 +279,9 @@ export class ProcessTerminal implements Terminal {
278
279
  this.#mouseEnabled = enabled;
279
280
  if (this.#started)
280
281
  this.#safeWrite(
281
- this.#mouseEnabled ? "\x1b[?1000l\x1b[?1002h\x1b[?1006h" : "\x1b[?1000l\x1b[?1002l\x1b[?1006l",
282
+ this.#mouseEnabled
283
+ ? "\x1b[?1000l\x1b[?1002h\x1b[?1006h\x1b[?1007l"
284
+ : "\x1b[?1000l\x1b[?1002l\x1b[?1006l\x1b[?1007l",
282
285
  );
283
286
  }
284
287
 
@@ -306,8 +309,14 @@ export class ProcessTerminal implements Terminal {
306
309
  // Enable bracketed paste mode - terminal will wrap pastes in \x1b[200~ ... \x1b[201~
307
310
  this.#safeWrite("\x1b[?2004h");
308
311
  // Button-event reporting preserves wheel input while also letting the TUI implement drag selection.
312
+ // Alternate-scroll must stay disabled: otherwise Windows Terminal/tmux can translate wheel notches
313
+ // into cursor Up/Down input, which the focused composer interprets as prompt history.
309
314
  // Clear both tracking variants first so stale modes from another application cannot leak across startup.
310
- this.#safeWrite(this.#mouseEnabled ? "\x1b[?1000l\x1b[?1002h\x1b[?1006h" : "\x1b[?1000l\x1b[?1002l\x1b[?1006l");
315
+ this.#safeWrite(
316
+ this.#mouseEnabled
317
+ ? "\x1b[?1000l\x1b[?1002h\x1b[?1006h\x1b[?1007l"
318
+ : "\x1b[?1000l\x1b[?1002l\x1b[?1006l\x1b[?1007l",
319
+ );
311
320
 
312
321
  // Set up resize handler immediately
313
322
  process.stdout.on("resize", this.#resizeHandler);
@@ -801,6 +810,7 @@ export class ProcessTerminal implements Terminal {
801
810
  this.#safeWrite("\x1b[?1000l");
802
811
  this.#safeWrite("\x1b[?1002l");
803
812
  this.#safeWrite("\x1b[?1006l");
813
+ this.#safeWrite("\x1b[?1007l");
804
814
 
805
815
  // Disable Mode 2031 appearance change notifications
806
816
  this.#safeWrite("\x1b[?2031l");