chromeflow 0.1.25 → 0.1.26
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/CLAUDE.md +2 -1
- package/dist/tools/browser.js +5 -5
- package/package.json +1 -1
package/CLAUDE.md
CHANGED
|
@@ -63,7 +63,8 @@ Do NOT ask "should I open the browser?" — just do it. The user expects seamles
|
|
|
63
63
|
[if fails] get_elements() — get EXACT DOM coords, use these in highlight_region
|
|
64
64
|
highlight_region(x,y,w,h,msg) — use exact coords from get_elements, not estimates
|
|
65
65
|
[after wait_for_click] get_page_text() — confirm result, NOT take_screenshot
|
|
66
|
-
[last resort only] take_screenshot() —
|
|
66
|
+
[last resort only] take_screenshot() — returns image to Claude only (no file, no clipboard)
|
|
67
|
+
take_and_copy_screenshot() — same as above BUT also saves PNG + copies to clipboard
|
|
67
68
|
d. Pause for the user when needed:
|
|
68
69
|
find_and_highlight(text, msg) — show the user what to do
|
|
69
70
|
wait_for_click() — wait for user interaction
|
package/dist/tools/browser.js
CHANGED
|
@@ -50,7 +50,7 @@ ${lines.join("\n")}` }]
|
|
|
50
50
|
);
|
|
51
51
|
server.tool(
|
|
52
52
|
"take_screenshot",
|
|
53
|
-
"Capture a screenshot
|
|
53
|
+
"Capture a screenshot and return it to Claude only \u2014 no file is saved, nothing goes to the clipboard. Use ONLY when you need to visually inspect the page layout or get pixel coordinates for highlight_region. DO NOT use to check page state or confirm actions \u2014 use get_page_text for that. To also save or copy the image, use take_and_copy_screenshot instead.",
|
|
54
54
|
{},
|
|
55
55
|
async () => {
|
|
56
56
|
const response = await bridge.request({ type: "screenshot" });
|
|
@@ -74,10 +74,10 @@ ${lines.join("\n")}` }]
|
|
|
74
74
|
);
|
|
75
75
|
server.tool(
|
|
76
76
|
"take_and_copy_screenshot",
|
|
77
|
-
`Take a screenshot, copy it to the system clipboard, and save it as a PNG file.
|
|
78
|
-
Use this when you need to
|
|
79
|
-
|
|
80
|
-
save_to controls where the
|
|
77
|
+
`Take a screenshot, return it to Claude, copy it to the system clipboard, and save it as a PNG file.
|
|
78
|
+
Use this instead of take_screenshot when you need the image outside of Claude \u2014 to paste into a chat, upload to a form, or keep as a file.
|
|
79
|
+
Unlike take_screenshot (Claude-only), this also puts the image on the clipboard and saves it to disk.
|
|
80
|
+
save_to controls where the PNG is saved: "downloads" (default) saves to ~/Downloads, "cwd" saves to Claude's current working directory.`,
|
|
81
81
|
{
|
|
82
82
|
save_to: z.enum(["downloads", "cwd"]).optional().describe(`Where to save the PNG file: "downloads" (~/Downloads, default) or "cwd" (Claude's current working directory)`)
|
|
83
83
|
},
|
package/package.json
CHANGED