openchrome-mcp 1.2.3 → 1.2.5
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/dist/cdp/client.d.ts.map +1 -1
- package/dist/cdp/client.js +10 -0
- package/dist/cdp/client.js.map +1 -1
- package/dist/chrome/launcher.d.ts +32 -15
- package/dist/chrome/launcher.d.ts.map +1 -1
- package/dist/chrome/launcher.js +136 -116
- package/dist/chrome/launcher.js.map +1 -1
- package/dist/chrome/profile-manager.d.ts +108 -0
- package/dist/chrome/profile-manager.d.ts.map +1 -0
- package/dist/chrome/profile-manager.js +372 -0
- package/dist/chrome/profile-manager.js.map +1 -0
- package/dist/chrome/sqlite-cookie-copy.d.ts +46 -0
- package/dist/chrome/sqlite-cookie-copy.d.ts.map +1 -0
- package/dist/chrome/sqlite-cookie-copy.js +145 -0
- package/dist/chrome/sqlite-cookie-copy.js.map +1 -0
- package/dist/cli/claude-session.js +0 -0
- package/dist/cli/index.js +0 -0
- package/dist/config/defaults.d.ts +8 -0
- package/dist/config/defaults.d.ts.map +1 -1
- package/dist/config/defaults.js +9 -1
- package/dist/config/defaults.js.map +1 -1
- package/dist/config/global.d.ts +2 -0
- package/dist/config/global.d.ts.map +1 -1
- package/dist/config/global.js.map +1 -1
- package/dist/hints/hint-engine.d.ts +36 -2
- package/dist/hints/hint-engine.d.ts.map +1 -1
- package/dist/hints/hint-engine.js +96 -27
- package/dist/hints/hint-engine.js.map +1 -1
- package/dist/hints/index.d.ts +1 -1
- package/dist/hints/index.d.ts.map +1 -1
- package/dist/hints/rules/error-recovery.d.ts.map +1 -1
- package/dist/hints/rules/error-recovery.js +5 -1
- package/dist/hints/rules/error-recovery.js.map +1 -1
- package/dist/hints/rules/repetition-detection.d.ts.map +1 -1
- package/dist/hints/rules/repetition-detection.js +42 -0
- package/dist/hints/rules/repetition-detection.js.map +1 -1
- package/dist/index.js +17 -1
- package/dist/index.js.map +1 -1
- package/dist/mcp-server.d.ts +12 -1
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/mcp-server.js +162 -20
- package/dist/mcp-server.js.map +1 -1
- package/dist/resources/usage-guide.d.ts +1 -1
- package/dist/resources/usage-guide.d.ts.map +1 -1
- package/dist/resources/usage-guide.js +22 -0
- package/dist/resources/usage-guide.js.map +1 -1
- package/dist/session-manager.d.ts +4 -0
- package/dist/session-manager.d.ts.map +1 -1
- package/dist/session-manager.js +56 -0
- package/dist/session-manager.js.map +1 -1
- package/dist/tools/click-element.d.ts.map +1 -1
- package/dist/tools/click-element.js +6 -2
- package/dist/tools/click-element.js.map +1 -1
- package/dist/tools/computer.d.ts.map +1 -1
- package/dist/tools/computer.js +101 -32
- package/dist/tools/computer.js.map +1 -1
- package/dist/tools/find.d.ts.map +1 -1
- package/dist/tools/find.js +16 -6
- package/dist/tools/find.js.map +1 -1
- package/dist/tools/form-input.d.ts.map +1 -1
- package/dist/tools/form-input.js +20 -0
- package/dist/tools/form-input.js.map +1 -1
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +2 -0
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/javascript.d.ts.map +1 -1
- package/dist/tools/javascript.js +38 -2
- package/dist/tools/javascript.js.map +1 -1
- package/dist/tools/navigate.d.ts.map +1 -1
- package/dist/tools/navigate.js +27 -0
- package/dist/tools/navigate.js.map +1 -1
- package/dist/tools/profile-status.d.ts +10 -0
- package/dist/tools/profile-status.d.ts.map +1 -0
- package/dist/tools/profile-status.js +101 -0
- package/dist/tools/profile-status.js.map +1 -0
- package/dist/tools/wait-and-click.d.ts.map +1 -1
- package/dist/tools/wait-and-click.js +3 -1
- package/dist/tools/wait-and-click.js.map +1 -1
- package/dist/utils/format-age.d.ts +5 -0
- package/dist/utils/format-age.d.ts.map +1 -0
- package/dist/utils/format-age.js +15 -0
- package/dist/utils/format-age.js.map +1 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/index.d.ts.map +1 -1
- package/dist/utils/index.js +1 -0
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/pid-manager.d.ts +6 -0
- package/dist/utils/pid-manager.d.ts.map +1 -0
- package/dist/utils/pid-manager.js +132 -0
- package/dist/utils/pid-manager.js.map +1 -0
- package/dist/utils/ref-id-manager.d.ts +19 -1
- package/dist/utils/ref-id-manager.d.ts.map +1 -1
- package/dist/utils/ref-id-manager.js +49 -2
- package/dist/utils/ref-id-manager.js.map +1 -1
- package/package.json +4 -1
- package/dist/chrome/profile-detector.d.ts +0 -52
- package/dist/chrome/profile-detector.d.ts.map +0 -1
- package/dist/chrome/profile-detector.js +0 -246
- package/dist/chrome/profile-detector.js.map +0 -1
- package/dist/hints/rules/dom-mode-suggestion.d.ts +0 -6
- package/dist/hints/rules/dom-mode-suggestion.d.ts.map +0 -1
- package/dist/hints/rules/dom-mode-suggestion.js +0 -24
- package/dist/hints/rules/dom-mode-suggestion.js.map +0 -1
- package/dist/types/profile.d.ts +0 -76
- package/dist/types/profile.d.ts.map +0 -1
- package/dist/types/profile.js +0 -35
- package/dist/types/profile.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dom-mode-suggestion.d.ts","sourceRoot":"","sources":["../../../src/hints/rules/dom-mode-suggestion.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAe,MAAM,gBAAgB,CAAC;AAE5D,eAAO,MAAM,sBAAsB,EAAE,QAAQ,EAc5C,CAAC"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* DOM Mode Suggestion — suggests compact DOM mode when AX tree output is truncated.
|
|
4
|
-
*/
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.domModeSuggestionRules = void 0;
|
|
7
|
-
exports.domModeSuggestionRules = [
|
|
8
|
-
{
|
|
9
|
-
name: 'suggest-dom-mode-on-truncation',
|
|
10
|
-
priority: 204, // Just after read-page-truncated at 203
|
|
11
|
-
match(ctx) {
|
|
12
|
-
if (ctx.toolName !== 'read_page')
|
|
13
|
-
return null;
|
|
14
|
-
if (ctx.isError)
|
|
15
|
-
return null;
|
|
16
|
-
// Match truncation indicators in the output
|
|
17
|
-
if (/Output truncated|truncat|\[Output .* chars\]/i.test(ctx.resultText)) {
|
|
18
|
-
return 'Hint: Use read_page with mode:"dom" for a compact DOM view (~5-10x fewer tokens) that avoids AX tree truncation.';
|
|
19
|
-
}
|
|
20
|
-
return null;
|
|
21
|
-
},
|
|
22
|
-
},
|
|
23
|
-
];
|
|
24
|
-
//# sourceMappingURL=dom-mode-suggestion.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dom-mode-suggestion.js","sourceRoot":"","sources":["../../../src/hints/rules/dom-mode-suggestion.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAIU,QAAA,sBAAsB,GAAe;IAChD;QACE,IAAI,EAAE,gCAAgC;QACtC,QAAQ,EAAE,GAAG,EAAG,wCAAwC;QACxD,KAAK,CAAC,GAAgB;YACpB,IAAI,GAAG,CAAC,QAAQ,KAAK,WAAW;gBAAE,OAAO,IAAI,CAAC;YAC9C,IAAI,GAAG,CAAC,OAAO;gBAAE,OAAO,IAAI,CAAC;YAC7B,4CAA4C;YAC5C,IAAI,+CAA+C,CAAC,IAAI,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,CAAC;gBACzE,OAAO,kHAAkH,CAAC;YAC5H,CAAC;YACD,OAAO,IAAI,CAAC;QACd,CAAC;KACF;CACF,CAAC"}
|
package/dist/types/profile.d.ts
DELETED
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Chrome Profile Types - Type definitions for profile management
|
|
3
|
-
*/
|
|
4
|
-
/**
|
|
5
|
-
* Represents a Chrome profile
|
|
6
|
-
*/
|
|
7
|
-
export interface ChromeProfile {
|
|
8
|
-
/** Profile directory name (e.g., "Default", "Profile 1") */
|
|
9
|
-
id: string;
|
|
10
|
-
/** Display name from profile metadata */
|
|
11
|
-
name: string;
|
|
12
|
-
/** Full path to profile directory */
|
|
13
|
-
path: string;
|
|
14
|
-
/** Google account email if signed in */
|
|
15
|
-
email?: string;
|
|
16
|
-
/** Whether the profile is currently in use (lock file exists) */
|
|
17
|
-
isInUse: boolean;
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* Result of profile detection
|
|
21
|
-
*/
|
|
22
|
-
export interface ProfileListResult {
|
|
23
|
-
/** Chrome user data directory path */
|
|
24
|
-
userDataDir: string;
|
|
25
|
-
/** List of detected profiles */
|
|
26
|
-
profiles: ChromeProfile[];
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Profile configuration for GlobalConfig
|
|
30
|
-
*/
|
|
31
|
-
export interface ProfileConfig {
|
|
32
|
-
/** Profile ID to use (e.g., "Default", "Profile 1") */
|
|
33
|
-
useProfile?: string;
|
|
34
|
-
/** Custom Chrome user data directory path */
|
|
35
|
-
chromeUserDataDir?: string;
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Chrome Local State file structure (partial)
|
|
39
|
-
*/
|
|
40
|
-
export interface LocalState {
|
|
41
|
-
profile: {
|
|
42
|
-
info_cache: Record<string, ProfileInfo>;
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Profile info from Local State
|
|
47
|
-
*/
|
|
48
|
-
export interface ProfileInfo {
|
|
49
|
-
/** Display name */
|
|
50
|
-
name: string;
|
|
51
|
-
/** Shortcut name */
|
|
52
|
-
shortcut_name?: string;
|
|
53
|
-
/** Google account email */
|
|
54
|
-
user_name?: string;
|
|
55
|
-
/** GAIA (Google Account ID) name */
|
|
56
|
-
gaia_name?: string;
|
|
57
|
-
/** Avatar icon index */
|
|
58
|
-
avatar_icon?: string;
|
|
59
|
-
}
|
|
60
|
-
/**
|
|
61
|
-
* Error thrown when profile is already in use
|
|
62
|
-
*/
|
|
63
|
-
export declare class ProfileInUseError extends Error {
|
|
64
|
-
readonly profileId: string;
|
|
65
|
-
readonly profilePath: string;
|
|
66
|
-
constructor(profileId: string, profilePath: string);
|
|
67
|
-
}
|
|
68
|
-
/**
|
|
69
|
-
* Error thrown when profile is not found
|
|
70
|
-
*/
|
|
71
|
-
export declare class ProfileNotFoundError extends Error {
|
|
72
|
-
readonly profileId: string;
|
|
73
|
-
readonly availableProfiles: string[];
|
|
74
|
-
constructor(profileId: string, availableProfiles: string[]);
|
|
75
|
-
}
|
|
76
|
-
//# sourceMappingURL=profile.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"profile.d.ts","sourceRoot":"","sources":["../../src/types/profile.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,4DAA4D;IAC5D,EAAE,EAAE,MAAM,CAAC;IACX,yCAAyC;IACzC,IAAI,EAAE,MAAM,CAAC;IACb,qCAAqC;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iEAAiE;IACjE,OAAO,EAAE,OAAO,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,sCAAsC;IACtC,WAAW,EAAE,MAAM,CAAC;IACpB,gCAAgC;IAChC,QAAQ,EAAE,aAAa,EAAE,CAAC;CAC3B;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,uDAAuD;IACvD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,6CAA6C;IAC7C,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,OAAO,EAAE;QACP,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;KACzC,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,oBAAoB;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,2BAA2B;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,oCAAoC;IACpC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,wBAAwB;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED;;GAEG;AACH,qBAAa,iBAAkB,SAAQ,KAAK;aAExB,SAAS,EAAE,MAAM;aACjB,WAAW,EAAE,MAAM;gBADnB,SAAS,EAAE,MAAM,EACjB,WAAW,EAAE,MAAM;CAKtC;AAED;;GAEG;AACH,qBAAa,oBAAqB,SAAQ,KAAK;aAE3B,SAAS,EAAE,MAAM;aACjB,iBAAiB,EAAE,MAAM,EAAE;gBAD3B,SAAS,EAAE,MAAM,EACjB,iBAAiB,EAAE,MAAM,EAAE;CAO9C"}
|
package/dist/types/profile.js
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Chrome Profile Types - Type definitions for profile management
|
|
4
|
-
*/
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.ProfileNotFoundError = exports.ProfileInUseError = void 0;
|
|
7
|
-
/**
|
|
8
|
-
* Error thrown when profile is already in use
|
|
9
|
-
*/
|
|
10
|
-
class ProfileInUseError extends Error {
|
|
11
|
-
profileId;
|
|
12
|
-
profilePath;
|
|
13
|
-
constructor(profileId, profilePath) {
|
|
14
|
-
super(`Profile "${profileId}" is already in use. Please close Chrome or use a different profile.`);
|
|
15
|
-
this.profileId = profileId;
|
|
16
|
-
this.profilePath = profilePath;
|
|
17
|
-
this.name = 'ProfileInUseError';
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
exports.ProfileInUseError = ProfileInUseError;
|
|
21
|
-
/**
|
|
22
|
-
* Error thrown when profile is not found
|
|
23
|
-
*/
|
|
24
|
-
class ProfileNotFoundError extends Error {
|
|
25
|
-
profileId;
|
|
26
|
-
availableProfiles;
|
|
27
|
-
constructor(profileId, availableProfiles) {
|
|
28
|
-
super(`Profile "${profileId}" not found. Available profiles: ${availableProfiles.join(', ') || 'none'}`);
|
|
29
|
-
this.profileId = profileId;
|
|
30
|
-
this.availableProfiles = availableProfiles;
|
|
31
|
-
this.name = 'ProfileNotFoundError';
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
exports.ProfileNotFoundError = ProfileNotFoundError;
|
|
35
|
-
//# sourceMappingURL=profile.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"profile.js","sourceRoot":"","sources":["../../src/types/profile.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AA+DH;;GAEG;AACH,MAAa,iBAAkB,SAAQ,KAAK;IAExB;IACA;IAFlB,YACkB,SAAiB,EACjB,WAAmB;QAEnC,KAAK,CAAC,YAAY,SAAS,sEAAsE,CAAC,CAAC;QAHnF,cAAS,GAAT,SAAS,CAAQ;QACjB,gBAAW,GAAX,WAAW,CAAQ;QAGnC,IAAI,CAAC,IAAI,GAAG,mBAAmB,CAAC;IAClC,CAAC;CACF;AARD,8CAQC;AAED;;GAEG;AACH,MAAa,oBAAqB,SAAQ,KAAK;IAE3B;IACA;IAFlB,YACkB,SAAiB,EACjB,iBAA2B;QAE3C,KAAK,CACH,YAAY,SAAS,oCAAoC,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,MAAM,EAAE,CAClG,CAAC;QALc,cAAS,GAAT,SAAS,CAAQ;QACjB,sBAAiB,GAAjB,iBAAiB,CAAU;QAK3C,IAAI,CAAC,IAAI,GAAG,sBAAsB,CAAC;IACrC,CAAC;CACF;AAVD,oDAUC"}
|