Update npm packages (73 packages including @jqhtml 2.3.36)
Update npm registry domain from privatenpm.hanson.xyz to npm.internal.hanson.xyz 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
19
node_modules/playwright/lib/mcp/browser/tools/navigate.js
generated
vendored
19
node_modules/playwright/lib/mcp/browser/tools/navigate.js
generated
vendored
@@ -21,7 +21,7 @@ __export(navigate_exports, {
|
||||
default: () => navigate_default
|
||||
});
|
||||
module.exports = __toCommonJS(navigate_exports);
|
||||
var import_bundle = require("../../sdk/bundle");
|
||||
var import_mcpBundle = require("playwright-core/lib/mcpBundle");
|
||||
var import_tool = require("./tool");
|
||||
const navigate = (0, import_tool.defineTool)({
|
||||
capability: "core",
|
||||
@@ -29,14 +29,23 @@ const navigate = (0, import_tool.defineTool)({
|
||||
name: "browser_navigate",
|
||||
title: "Navigate to a URL",
|
||||
description: "Navigate to a URL",
|
||||
inputSchema: import_bundle.z.object({
|
||||
url: import_bundle.z.string().describe("The URL to navigate to")
|
||||
inputSchema: import_mcpBundle.z.object({
|
||||
url: import_mcpBundle.z.string().describe("The URL to navigate to")
|
||||
}),
|
||||
type: "action"
|
||||
},
|
||||
handle: async (context, params, response) => {
|
||||
const tab = await context.ensureTab();
|
||||
await tab.navigate(params.url);
|
||||
let url = params.url;
|
||||
try {
|
||||
new URL(url);
|
||||
} catch (e) {
|
||||
if (url.startsWith("localhost"))
|
||||
url = "http://" + url;
|
||||
else
|
||||
url = "https://" + url;
|
||||
}
|
||||
await tab.navigate(url);
|
||||
response.setIncludeSnapshot();
|
||||
response.addCode(`await page.goto('${params.url}');`);
|
||||
}
|
||||
@@ -47,7 +56,7 @@ const goBack = (0, import_tool.defineTabTool)({
|
||||
name: "browser_navigate_back",
|
||||
title: "Go back",
|
||||
description: "Go back to the previous page",
|
||||
inputSchema: import_bundle.z.object({}),
|
||||
inputSchema: import_mcpBundle.z.object({}),
|
||||
type: "action"
|
||||
},
|
||||
handle: async (tab, params, response) => {
|
||||
|
||||
Reference in New Issue
Block a user