agentgui 1.0.606 → 1.0.608
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/docs/screenshot-chat.png +0 -0
- package/docs/screenshot-conversation.png +0 -0
- package/docs/screenshot-files.png +0 -0
- package/docs/screenshot-main.png +0 -0
- package/docs/screenshot-terminal.png +0 -0
- package/docs/screenshot-tools-popup.png +0 -0
- package/lib/acp-sdk-manager.js +9 -6
- package/package.json +1 -1
- package/scripts/take-screenshots.sh +13 -9
package/docs/screenshot-chat.png
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/docs/screenshot-main.png
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/lib/acp-sdk-manager.js
CHANGED
|
@@ -26,11 +26,14 @@ let shuttingDown = false;
|
|
|
26
26
|
|
|
27
27
|
function log(msg) { console.log('[ACP-SDK] ' + msg); }
|
|
28
28
|
|
|
29
|
-
function
|
|
29
|
+
function resolveCommand(tool) {
|
|
30
30
|
const ext = isWindows ? '.cmd' : '';
|
|
31
|
-
const localBin = path.join(projectRoot, 'node_modules', '.bin', cmd + ext);
|
|
32
|
-
if (fs.existsSync(localBin)) return localBin;
|
|
33
|
-
|
|
31
|
+
const localBin = path.join(projectRoot, 'node_modules', '.bin', tool.cmd + ext);
|
|
32
|
+
if (fs.existsSync(localBin)) return { bin: localBin, args: tool.args };
|
|
33
|
+
const bunx = path.join(projectRoot, 'node_modules', '.bin', 'bunx' + ext);
|
|
34
|
+
const runner = fs.existsSync(bunx) ? bunx : 'bunx';
|
|
35
|
+
if (tool.npxPkg) return { bin: runner, args: [tool.npxPkg, ...tool.args] };
|
|
36
|
+
return { bin: tool.cmd, args: tool.args };
|
|
34
37
|
}
|
|
35
38
|
|
|
36
39
|
function startProcess(tool) {
|
|
@@ -38,7 +41,7 @@ function startProcess(tool) {
|
|
|
38
41
|
const existing = processes.get(tool.id);
|
|
39
42
|
if (existing?.process && !existing.process.killed) return existing;
|
|
40
43
|
|
|
41
|
-
const
|
|
44
|
+
const resolved = resolveCommand(tool);
|
|
42
45
|
const entry = {
|
|
43
46
|
id: tool.id,
|
|
44
47
|
port: tool.port,
|
|
@@ -55,7 +58,7 @@ function startProcess(tool) {
|
|
|
55
58
|
};
|
|
56
59
|
|
|
57
60
|
try {
|
|
58
|
-
entry.process = spawn(
|
|
61
|
+
entry.process = spawn(resolved.bin, resolved.args, {
|
|
59
62
|
stdio: ['ignore', 'pipe', 'pipe'],
|
|
60
63
|
detached: false
|
|
61
64
|
});
|
package/package.json
CHANGED
|
@@ -24,14 +24,14 @@ echo "Saving to $DOCS_DIR"
|
|
|
24
24
|
|
|
25
25
|
ab open "$BASE_URL"
|
|
26
26
|
ab wait --load networkidle
|
|
27
|
-
|
|
27
|
+
sleep 1
|
|
28
28
|
|
|
29
29
|
ab screenshot --full "$DOCS_DIR/screenshot-main.png"
|
|
30
30
|
echo "Saved screenshot-main.png"
|
|
31
31
|
|
|
32
|
-
ab eval 'document.querySelector(".conversation-item")
|
|
32
|
+
ab eval 'document.querySelector(".conversation-item")?.click()'
|
|
33
|
+
sleep 2
|
|
33
34
|
ab wait --load networkidle
|
|
34
|
-
ab wait ".message, .event-block, .streaming-event, #chatView, .chat-messages"
|
|
35
35
|
|
|
36
36
|
ab screenshot --full "$DOCS_DIR/screenshot-chat.png"
|
|
37
37
|
echo "Saved screenshot-chat.png"
|
|
@@ -39,20 +39,24 @@ echo "Saved screenshot-chat.png"
|
|
|
39
39
|
ab screenshot --full "$DOCS_DIR/screenshot-conversation.png"
|
|
40
40
|
echo "Saved screenshot-conversation.png"
|
|
41
41
|
|
|
42
|
-
ab eval 'document.getElementById("toolsManagerBtn")
|
|
43
|
-
|
|
42
|
+
ab eval 'var b=document.getElementById("toolsManagerBtn"); if(b){b.style.display="";b.click();}'
|
|
43
|
+
sleep 1
|
|
44
44
|
|
|
45
45
|
ab screenshot --full "$DOCS_DIR/screenshot-tools-popup.png"
|
|
46
46
|
echo "Saved screenshot-tools-popup.png"
|
|
47
47
|
|
|
48
|
-
ab eval 'document.
|
|
49
|
-
|
|
48
|
+
ab eval 'var p=document.getElementById("toolsPopup"); if(p)p.classList.remove("open");'
|
|
49
|
+
sleep 0.5
|
|
50
|
+
|
|
51
|
+
ab eval 'document.querySelector(".view-toggle-btn[data-view=\"files\"]")?.click()'
|
|
52
|
+
sleep 2
|
|
53
|
+
ab wait --load networkidle
|
|
50
54
|
|
|
51
55
|
ab screenshot --full "$DOCS_DIR/screenshot-files.png"
|
|
52
56
|
echo "Saved screenshot-files.png"
|
|
53
57
|
|
|
54
|
-
ab eval 'document.querySelector("[data-view
|
|
55
|
-
|
|
58
|
+
ab eval 'document.querySelector(".view-toggle-btn[data-view=\"terminal\"]")?.click()'
|
|
59
|
+
sleep 1
|
|
56
60
|
|
|
57
61
|
ab screenshot --full "$DOCS_DIR/screenshot-terminal.png"
|
|
58
62
|
echo "Saved screenshot-terminal.png"
|