cxstatusline 0.7.0 → 0.9.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.
@@ -1,3 +1,107 @@
1
+ diff --git a/build/ink.d.ts b/build/ink.d.ts
2
+ index 9dce0fe328a8eeb18d459b974ab0c3cf5fb38dda..f90bb0fe8c71beae7bf7db4e4d9d5f62812d33a3 100644
3
+ --- a/build/ink.d.ts
4
+ +++ b/build/ink.d.ts
5
+ @@ -4,6 +4,8 @@ export type Options = {
6
+ stdin: NodeJS.ReadStream;
7
+ stderr: NodeJS.WriteStream;
8
+ debug: boolean;
9
+ + preserveScrollback?: boolean;
10
+ + isCI?: boolean;
11
+ exitOnCtrlC: boolean;
12
+ patchConsole: boolean;
13
+ isScreenReaderEnabled?: boolean;
14
+ @@ -14,6 +16,7 @@ export default class Ink {
15
+ private readonly log;
16
+ private readonly throttledLog;
17
+ private readonly isScreenReaderEnabled;
18
+ + private readonly isInCi;
19
+ private isUnmounted;
20
+ private lastOutput;
21
+ private lastOutputHeight;
22
+ diff --git a/build/ink.js b/build/ink.js
23
+ index 5cad56e135f1074474d7d498ffd87c5699b9df78..46acd25d0df2d4382f2bb5c2586f4d802bbb4af2 100644
24
+ --- a/build/ink.js
25
+ +++ b/build/ink.js
26
+ @@ -21,6 +21,7 @@ export default class Ink {
27
+ log;
28
+ throttledLog;
29
+ isScreenReaderEnabled;
30
+ + isInCi;
31
+ // Ignore last render after unmounting a tree to prevent empty output before exit
32
+ isUnmounted;
33
+ lastOutput;
34
+ @@ -36,6 +37,7 @@ export default class Ink {
35
+ constructor(options) {
36
+ autoBind(this);
37
+ this.options = options;
38
+ + this.isInCi = options.isCI ?? isInCi;
39
+ this.rootNode = dom.createNode('ink-root');
40
+ this.rootNode.onComputeLayout = this.calculateLayout;
41
+ this.isScreenReaderEnabled =
42
+ @@ -83,7 +85,7 @@ export default class Ink {
43
+ if (options.patchConsole) {
44
+ this.patchConsole();
45
+ }
46
+ - if (!isInCi) {
47
+ + if (!this.isInCi) {
48
+ options.stdout.on('resize', this.resized);
49
+ this.unsubscribeResize = () => {
50
+ options.stdout.off('resize', this.resized);
51
+ @@ -118,7 +120,7 @@ export default class Ink {
52
+ this.options.stdout.write(this.fullStaticOutput + output);
53
+ return;
54
+ }
55
+ - if (isInCi) {
56
+ + if (this.isInCi) {
57
+ if (hasStaticOutput) {
58
+ this.options.stdout.write(staticOutput);
59
+ }
60
+ @@ -129,7 +131,7 @@ export default class Ink {
61
+ if (hasStaticOutput) {
62
+ this.fullStaticOutput += staticOutput;
63
+ }
64
+ - if (this.lastOutputHeight >= this.options.stdout.rows) {
65
+ + if (!this.options.preserveScrollback && this.lastOutputHeight >= this.options.stdout.rows) {
66
+ this.options.stdout.write(ansiEscapes.clearTerminal + this.fullStaticOutput + output + '\n');
67
+ this.lastOutput = output;
68
+ this.lastOutputHeight = outputHeight;
69
+ @@ -166,7 +168,7 @@ export default class Ink {
70
+ this.options.stdout.write(data + this.fullStaticOutput + this.lastOutput);
71
+ return;
72
+ }
73
+ - if (isInCi) {
74
+ + if (this.isInCi) {
75
+ this.options.stdout.write(data);
76
+ return;
77
+ }
78
+ @@ -183,7 +185,7 @@ export default class Ink {
79
+ this.options.stdout.write(this.fullStaticOutput + this.lastOutput);
80
+ return;
81
+ }
82
+ - if (isInCi) {
83
+ + if (this.isInCi) {
84
+ this.options.stderr.write(data);
85
+ return;
86
+ }
87
+ @@ -207,7 +209,7 @@ export default class Ink {
88
+ }
89
+ // CIs don't handle erasing ansi escapes well, so it's better to
90
+ // only render last frame of non-static output
91
+ - if (isInCi) {
92
+ + if (this.isInCi) {
93
+ this.options.stdout.write(this.lastOutput + '\n');
94
+ }
95
+ else if (!this.options.debug) {
96
+ @@ -236,7 +238,7 @@ export default class Ink {
97
+ return this.exitPromise;
98
+ }
99
+ clear() {
100
+ - if (!isInCi && !this.options.debug) {
101
+ + if (!this.isInCi && !this.options.debug) {
102
+ this.log.clear();
103
+ }
104
+ }
1
105
  diff --git a/build/parse-keypress.js b/build/parse-keypress.js
2
106
  index 1e13e819f59d259a3476510db822695576a9d93c..e100611d8661187c4ca191e89621cd5e480fcacc 100644
3
107
  --- a/build/parse-keypress.js
@@ -15,3 +119,18 @@ index 1e13e819f59d259a3476510db822695576a9d93c..e100611d8661187c4ca191e89621cd5e
15
119
  key.meta = s.charAt(0) === '\x1b';
16
120
  }
17
121
  else if (s === '\x1b' || s === '\x1b\x1b') {
122
+ diff --git a/build/render.d.ts b/build/render.d.ts
123
+ index ffcfbaca277cbd95b2e6a2c857230dd69e41b7e0..5fd94d71aa136f48447c162dd7453617f1824cc5 100644
124
+ --- a/build/render.d.ts
125
+ +++ b/build/render.d.ts
126
+ @@ -24,6 +24,10 @@ export type RenderOptions = {
127
+ * @default false
128
+ */
129
+ debug?: boolean;
130
+ + /** Preserve prior terminal output when an Ink view exceeds terminal height. */
131
+ + preserveScrollback?: boolean;
132
+ + /** Override CI detection when the caller has verified an interactive terminal. */
133
+ + isCI?: boolean;
134
+ /**
135
+ * Configure whether Ink should listen to Ctrl+C keyboard input and exit the app. This is needed in case `process.stdin` is in raw mode, because then Ctrl+C is ignored by default and process is expected to handle it manually.
136
+ *
@@ -1,13 +1,16 @@
1
1
  {
2
- "version": 1,
2
+ "version": 2,
3
3
  "tag_prefix": "rust-v",
4
- "candidate": "0.155.1",
4
+ "candidate": "0.156.1",
5
5
  "patches": [
6
- { "min": "0.152.1", "max": "0.152.1", "file": "codex-0.152.1.patch" },
7
- { "min": "0.153.0", "max": "0.153.0", "file": "codex-0.153.0.patch" },
8
- { "min": "0.153.4", "max": "0.153.4", "file": "codex-0.153.4.patch" },
9
- { "min": "0.154.0", "max": "0.154.0", "file": "codex-0.154.0.patch" },
10
- { "min": "0.155.0", "max": "0.155.0", "file": "codex-0.155.0.patch" },
11
- { "min": "0.155.1", "max": "0.155.1", "file": "codex-0.155.1.patch" }
6
+ { "patchVersion": 1, "min": "0.152.1", "max": "0.152.1", "file": "codex-0.152.1.patch" },
7
+ { "patchVersion": 1, "min": "0.153.0", "max": "0.153.0", "file": "codex-0.153.0.patch" },
8
+ { "patchVersion": 1, "min": "0.153.1", "max": "0.153.1", "file": "codex-0.153.4.patch" },
9
+ { "patchVersion": 1, "min": "0.153.4", "max": "0.153.4", "file": "codex-0.153.4.patch" },
10
+ { "patchVersion": 1, "min": "0.154.0", "max": "0.154.0", "file": "codex-0.154.0.patch" },
11
+ { "patchVersion": 1, "min": "0.155.0", "max": "0.155.0", "file": "codex-0.155.0.patch" },
12
+ { "patchVersion": 1, "min": "0.155.1", "max": "0.155.1", "file": "codex-0.155.1.patch" },
13
+ { "patchVersion": 2, "min": "0.156.0", "max": "0.156.0", "file": "codex-0.156.1.patch" },
14
+ { "patchVersion": 2, "min": "0.156.1", "max": "0.156.1", "file": "codex-0.156.1.patch" }
12
15
  ]
13
16
  }