@testany/hephos 0.3.15 → 0.3.17
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@testany/hephos",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.17",
|
|
4
4
|
"description": "Hephos - full CLI+REPL bundle for multi-agent conversation orchestration (depends on agent-chatter core)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./out/cli.js",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"@testany/agent-chatter-core": "^1.1.6",
|
|
29
29
|
"chalk": "^5.6.2",
|
|
30
30
|
"commander": "^14.0.2",
|
|
31
|
-
"ink": "npm:@jrichman/ink
|
|
31
|
+
"ink": "npm:@jrichman/ink@6.4.6",
|
|
32
32
|
"ink-text-input": "^6.0.0",
|
|
33
33
|
"inquirer": "^9.3.8",
|
|
34
34
|
"inquirer-autocomplete-standalone": "^0.8.1",
|
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
"@types/node": "^20.0.0",
|
|
40
40
|
"@types/react": "^19.2.5",
|
|
41
41
|
"ink-testing-library": "^4.0.0",
|
|
42
|
+
"patch-package": "^8.0.1",
|
|
42
43
|
"typescript": "^5.3.0",
|
|
43
44
|
"vitest": "^4.0.9"
|
|
44
45
|
},
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
diff --git a/node_modules/ink/build/parse-keypress.js b/node_modules/ink/build/parse-keypress.js
|
|
2
|
+
index 1e13e81..9788ab3 100644
|
|
3
|
+
--- a/node_modules/ink/build/parse-keypress.js
|
|
4
|
+
+++ b/node_modules/ink/build/parse-keypress.js
|
|
5
|
+
@@ -161,9 +161,8 @@ const parseKeypress = (s = '') => {
|
|
6
|
+
key.meta = s.charAt(0) === '\x1b';
|
|
7
|
+
}
|
|
8
|
+
else if (s === '\x7f' || s === '\x1b\x7f') {
|
|
9
|
+
- // TODO(vadimdemedes): `enquirer` detects delete key as backspace, but I had to split them up to avoid breaking changes in Ink. Merge them back together in the next major version.
|
|
10
|
+
- // delete
|
|
11
|
+
- key.name = 'delete';
|
|
12
|
+
+ // DEL (0x7f) is sent by Backspace in most terminals
|
|
13
|
+
+ key.name = 'backspace';
|
|
14
|
+
key.meta = s.charAt(0) === '\x1b';
|
|
15
|
+
}
|
|
16
|
+
else if (s === '\x1b' || s === '\x1b\x1b') {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
diff --git a/node_modules/ink-text-input/build/index.js b/node_modules/ink-text-input/build/index.js
|
|
2
|
-
index ada7cdc..
|
|
2
|
+
index ada7cdc..58b0342 100644
|
|
3
3
|
--- a/node_modules/ink-text-input/build/index.js
|
|
4
4
|
+++ b/node_modules/ink-text-input/build/index.js
|
|
5
|
-
@@ -73,11 +73,
|
|
5
|
+
@@ -73,11 +73,24 @@ function TextInput({ value: originalValue, placeholder = '', focus = true, mask,
|
|
6
6
|
}
|
|
7
7
|
}
|
|
8
8
|
else if (key.backspace || key.delete) {
|
|
@@ -11,14 +11,8 @@ index ada7cdc..5605141 100644
|
|
|
11
11
|
- originalValue.slice(0, cursorOffset - 1) +
|
|
12
12
|
- originalValue.slice(cursorOffset, originalValue.length);
|
|
13
13
|
- nextCursorOffset--;
|
|
14
|
-
+ //
|
|
15
|
-
+
|
|
16
|
-
+ // Use key.sequence (fallback to input) to detect actual key pressed
|
|
17
|
-
+ const sequence = key.sequence || input || '';
|
|
18
|
-
+ const isActualBackspace = (key.backspace === true) || (key.delete && sequence === '\x7f'); // Backspace key
|
|
19
|
-
+ const isRealDelete = key.delete && sequence === '\x1b[3~'; // Forward Delete
|
|
20
|
-
+
|
|
21
|
-
+ if (isActualBackspace) {
|
|
14
|
+
+ // With patched ink, key.backspace = Backspace key, key.delete = Delete key
|
|
15
|
+
+ if (key.backspace) {
|
|
22
16
|
+ // Backspace: delete character BEFORE cursor
|
|
23
17
|
+ if (cursorOffset > 0) {
|
|
24
18
|
+ nextValue =
|
|
@@ -28,7 +22,7 @@ index ada7cdc..5605141 100644
|
|
|
28
22
|
+ }
|
|
29
23
|
+ }
|
|
30
24
|
+ else if (key.delete) {
|
|
31
|
-
+ //
|
|
25
|
+
+ // Delete: delete character AT cursor position
|
|
32
26
|
+ if (cursorOffset < originalValue.length) {
|
|
33
27
|
+ nextValue =
|
|
34
28
|
+ originalValue.slice(0, cursorOffset) +
|