agentgui 1.0.584 → 1.0.585
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/package.json +1 -1
- package/scripts/take-screenshots.sh +60 -0
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/package.json
CHANGED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -eu
|
|
3
|
+
|
|
4
|
+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
5
|
+
DOCS_DIR="$SCRIPT_DIR/../docs"
|
|
6
|
+
SESSION="agentgui-screenshots"
|
|
7
|
+
LOG_FILE="/config/logs/services/agentgui.log"
|
|
8
|
+
|
|
9
|
+
PORT=$(grep -oP 'localhost:\K[0-9]+(?=/gm/)' "$LOG_FILE" 2>/dev/null | tail -1)
|
|
10
|
+
PORT="${PORT:-9897}"
|
|
11
|
+
BASE_URL="http://localhost:$PORT/gm/"
|
|
12
|
+
|
|
13
|
+
ab() {
|
|
14
|
+
agent-browser --session "$SESSION" "$@"
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
cleanup() {
|
|
18
|
+
agent-browser --session "$SESSION" close 2>/dev/null || true
|
|
19
|
+
}
|
|
20
|
+
trap cleanup EXIT
|
|
21
|
+
|
|
22
|
+
echo "Taking screenshots from $BASE_URL"
|
|
23
|
+
echo "Saving to $DOCS_DIR"
|
|
24
|
+
|
|
25
|
+
ab open "$BASE_URL"
|
|
26
|
+
ab wait --load networkidle
|
|
27
|
+
ab wait ".conversation-item"
|
|
28
|
+
|
|
29
|
+
ab screenshot --full "$DOCS_DIR/screenshot-main.png"
|
|
30
|
+
echo "Saved screenshot-main.png"
|
|
31
|
+
|
|
32
|
+
ab eval 'document.querySelector(".conversation-item").click()'
|
|
33
|
+
ab wait --load networkidle
|
|
34
|
+
ab wait ".message, .event-block, .streaming-event, #chatView, .chat-messages"
|
|
35
|
+
|
|
36
|
+
ab screenshot --full "$DOCS_DIR/screenshot-chat.png"
|
|
37
|
+
echo "Saved screenshot-chat.png"
|
|
38
|
+
|
|
39
|
+
ab screenshot --full "$DOCS_DIR/screenshot-conversation.png"
|
|
40
|
+
echo "Saved screenshot-conversation.png"
|
|
41
|
+
|
|
42
|
+
ab eval 'document.getElementById("toolsManagerBtn")?.click()'
|
|
43
|
+
ab wait "#toolsPopup.open, .tools-popup.open"
|
|
44
|
+
|
|
45
|
+
ab screenshot --full "$DOCS_DIR/screenshot-tools-popup.png"
|
|
46
|
+
echo "Saved screenshot-tools-popup.png"
|
|
47
|
+
|
|
48
|
+
ab eval 'document.querySelector("[data-view=files]")?.click()'
|
|
49
|
+
ab wait "[data-view=files].active, .files-view, #filesView"
|
|
50
|
+
|
|
51
|
+
ab screenshot --full "$DOCS_DIR/screenshot-files.png"
|
|
52
|
+
echo "Saved screenshot-files.png"
|
|
53
|
+
|
|
54
|
+
ab eval 'document.querySelector("[data-view=terminal]")?.click()'
|
|
55
|
+
ab wait "#terminalContainer:not([style*=\"display:none\"]), .terminal-container:not([style*=\"display:none\"])"
|
|
56
|
+
|
|
57
|
+
ab screenshot --full "$DOCS_DIR/screenshot-terminal.png"
|
|
58
|
+
echo "Saved screenshot-terminal.png"
|
|
59
|
+
|
|
60
|
+
echo "All screenshots saved to $DOCS_DIR"
|