@cotestdev/mcp_playwright 0.0.52 → 0.0.54

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.
Files changed (46) hide show
  1. package/lib/mcp/browser/browserContextFactory.js +1 -3
  2. package/lib/mcp/browser/tools/common.js +0 -6
  3. package/lib/mcp/program.js +6 -5
  4. package/lib/mcp/terminal/command.js +2 -2
  5. package/lib/mcp/terminal/commands.js +21 -10
  6. package/lib/mcp/terminal/daemon.js +2 -1
  7. package/lib/mcp/terminal/helpGenerator.js +19 -1
  8. package/lib/mcp/terminal/program.js +25 -16
  9. package/lib/mcpBundleImpl/index.js +27 -27
  10. package/package.json +1 -1
  11. package/lib/common/config.js +0 -281
  12. package/lib/common/configLoader.js +0 -344
  13. package/lib/common/esmLoaderHost.js +0 -104
  14. package/lib/common/expectBundle.js +0 -43
  15. package/lib/common/expectBundleImpl.js +0 -407
  16. package/lib/common/fixtures.js +0 -302
  17. package/lib/common/globals.js +0 -58
  18. package/lib/common/ipc.js +0 -60
  19. package/lib/common/poolBuilder.js +0 -85
  20. package/lib/common/process.js +0 -132
  21. package/lib/common/suiteUtils.js +0 -140
  22. package/lib/common/test.js +0 -322
  23. package/lib/common/testLoader.js +0 -101
  24. package/lib/common/testType.js +0 -298
  25. package/lib/common/validators.js +0 -68
  26. package/lib/mcp/browser/actions.d.js +0 -16
  27. package/lib/mcp/browser/codegen.js +0 -66
  28. package/lib/mcp/browser/processUtils.js +0 -102
  29. package/lib/mcp/browser/tools/script.js +0 -60
  30. package/lib/mcp/sdk/bundle.js +0 -75
  31. package/lib/mcp/sdk/mdb.js +0 -208
  32. package/lib/mcp/sdk/proxyBackend.js +0 -128
  33. package/lib/mcp/vscode/host.js +0 -187
  34. package/lib/mcp/vscode/main.js +0 -77
  35. package/lib/mcpBundleImpl.js +0 -41
  36. package/lib/third_party/pirates.js +0 -62
  37. package/lib/third_party/tsconfig-loader.js +0 -103
  38. package/lib/transform/babelBundle.js +0 -43
  39. package/lib/transform/babelBundleImpl.js +0 -461
  40. package/lib/transform/babelHighlightUtils.js +0 -63
  41. package/lib/transform/compilationCache.js +0 -272
  42. package/lib/transform/esmLoader.js +0 -103
  43. package/lib/transform/portTransport.js +0 -67
  44. package/lib/transform/transform.js +0 -296
  45. package/lib/utilsBundleImpl/index.js +0 -218
  46. package/lib/utilsBundleImpl.js +0 -103
@@ -1,104 +0,0 @@
1
- "use strict";
2
- var __create = Object.create;
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf;
7
- var __hasOwnProp = Object.prototype.hasOwnProperty;
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __copyProps = (to, from, except, desc) => {
13
- if (from && typeof from === "object" || typeof from === "function") {
14
- for (let key of __getOwnPropNames(from))
15
- if (!__hasOwnProp.call(to, key) && key !== except)
16
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
- }
18
- return to;
19
- };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
- mod
27
- ));
28
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var esmLoaderHost_exports = {};
30
- __export(esmLoaderHost_exports, {
31
- configureESMLoader: () => configureESMLoader,
32
- configureESMLoaderTransformConfig: () => configureESMLoaderTransformConfig,
33
- incorporateCompilationCache: () => incorporateCompilationCache,
34
- registerESMLoader: () => registerESMLoader,
35
- startCollectingFileDeps: () => startCollectingFileDeps,
36
- stopCollectingFileDeps: () => stopCollectingFileDeps
37
- });
38
- module.exports = __toCommonJS(esmLoaderHost_exports);
39
- var import_url = __toESM(require("url"));
40
- var import_compilationCache = require("../transform/compilationCache");
41
- var import_portTransport = require("../transform/portTransport");
42
- var import_transform = require("../transform/transform");
43
- let loaderChannel;
44
- function registerESMLoader() {
45
- if (process.env.PW_DISABLE_TS_ESM)
46
- return true;
47
- if ("Bun" in globalThis)
48
- return true;
49
- if (loaderChannel)
50
- return true;
51
- const register = require("node:module").register;
52
- if (!register)
53
- return false;
54
- const { port1, port2 } = new MessageChannel();
55
- register(import_url.default.pathToFileURL(require.resolve("../transform/esmLoader")), {
56
- data: { port: port2 },
57
- transferList: [port2]
58
- });
59
- loaderChannel = createPortTransport(port1);
60
- return true;
61
- }
62
- function createPortTransport(port) {
63
- return new import_portTransport.PortTransport(port, async (method, params) => {
64
- if (method === "pushToCompilationCache")
65
- (0, import_compilationCache.addToCompilationCache)(params.cache);
66
- });
67
- }
68
- async function startCollectingFileDeps() {
69
- if (!loaderChannel)
70
- return;
71
- await loaderChannel.send("startCollectingFileDeps", {});
72
- }
73
- async function stopCollectingFileDeps(file) {
74
- if (!loaderChannel)
75
- return;
76
- await loaderChannel.send("stopCollectingFileDeps", { file });
77
- }
78
- async function incorporateCompilationCache() {
79
- if (!loaderChannel)
80
- return;
81
- const result = await loaderChannel.send("getCompilationCache", {});
82
- (0, import_compilationCache.addToCompilationCache)(result.cache);
83
- }
84
- async function configureESMLoader() {
85
- if (!loaderChannel)
86
- return;
87
- await loaderChannel.send("setSingleTSConfig", { tsconfig: (0, import_transform.singleTSConfig)() });
88
- await loaderChannel.send("addToCompilationCache", { cache: (0, import_compilationCache.serializeCompilationCache)() });
89
- }
90
- async function configureESMLoaderTransformConfig() {
91
- if (!loaderChannel)
92
- return;
93
- await loaderChannel.send("setSingleTSConfig", { tsconfig: (0, import_transform.singleTSConfig)() });
94
- await loaderChannel.send("setTransformConfig", { config: (0, import_transform.transformConfig)() });
95
- }
96
- // Annotate the CommonJS export names for ESM import in node:
97
- 0 && (module.exports = {
98
- configureESMLoader,
99
- configureESMLoaderTransformConfig,
100
- incorporateCompilationCache,
101
- registerESMLoader,
102
- startCollectingFileDeps,
103
- stopCollectingFileDeps
104
- });
@@ -1,43 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: true });
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var expectBundle_exports = {};
20
- __export(expectBundle_exports, {
21
- DIM_COLOR: () => DIM_COLOR,
22
- EXPECTED_COLOR: () => EXPECTED_COLOR,
23
- INVERTED_COLOR: () => INVERTED_COLOR,
24
- RECEIVED_COLOR: () => RECEIVED_COLOR,
25
- expect: () => expect,
26
- printReceived: () => printReceived
27
- });
28
- module.exports = __toCommonJS(expectBundle_exports);
29
- const expect = require("./expectBundleImpl").expect;
30
- const EXPECTED_COLOR = require("./expectBundleImpl").EXPECTED_COLOR;
31
- const INVERTED_COLOR = require("./expectBundleImpl").INVERTED_COLOR;
32
- const RECEIVED_COLOR = require("./expectBundleImpl").RECEIVED_COLOR;
33
- const DIM_COLOR = require("./expectBundleImpl").DIM_COLOR;
34
- const printReceived = require("./expectBundleImpl").printReceived;
35
- // Annotate the CommonJS export names for ESM import in node:
36
- 0 && (module.exports = {
37
- DIM_COLOR,
38
- EXPECTED_COLOR,
39
- INVERTED_COLOR,
40
- RECEIVED_COLOR,
41
- expect,
42
- printReceived
43
- });