btcp-browser-agent 0.1.2 → 0.1.4
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "btcp-browser-agent",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "Give AI agents the power to control browsers. A foundation for building agentic systems with smart DOM snapshots and stable element references.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -8,23 +8,28 @@
|
|
|
8
8
|
"exports": {
|
|
9
9
|
".": {
|
|
10
10
|
"types": "./dist/index.d.ts",
|
|
11
|
-
"import": "./dist/index.js"
|
|
11
|
+
"import": "./dist/index.js",
|
|
12
|
+
"default": "./dist/index.js"
|
|
12
13
|
},
|
|
13
14
|
"./core": {
|
|
14
15
|
"types": "./packages/core/dist/index.d.ts",
|
|
15
|
-
"import": "./packages/core/dist/index.js"
|
|
16
|
+
"import": "./packages/core/dist/index.js",
|
|
17
|
+
"default": "./packages/core/dist/index.js"
|
|
16
18
|
},
|
|
17
19
|
"./extension": {
|
|
18
20
|
"types": "./packages/extension/dist/index.d.ts",
|
|
19
|
-
"import": "./packages/extension/dist/index.js"
|
|
21
|
+
"import": "./packages/extension/dist/index.js",
|
|
22
|
+
"default": "./packages/extension/dist/index.js"
|
|
20
23
|
},
|
|
21
24
|
"./extension/content": {
|
|
22
25
|
"types": "./packages/extension/dist/content.d.ts",
|
|
23
|
-
"import": "./packages/extension/dist/content.js"
|
|
26
|
+
"import": "./packages/extension/dist/content.js",
|
|
27
|
+
"default": "./packages/extension/dist/content.js"
|
|
24
28
|
},
|
|
25
29
|
"./extension/background": {
|
|
26
30
|
"types": "./packages/extension/dist/background.d.ts",
|
|
27
|
-
"import": "./packages/extension/dist/background.js"
|
|
31
|
+
"import": "./packages/extension/dist/background.js",
|
|
32
|
+
"default": "./packages/extension/dist/background.js"
|
|
28
33
|
}
|
|
29
34
|
},
|
|
30
35
|
"scripts": {
|
|
@@ -136,9 +136,8 @@ export class SessionManager {
|
|
|
136
136
|
}
|
|
137
137
|
}
|
|
138
138
|
console.log('[SessionManager] Creating group with tabs:', targetTabIds);
|
|
139
|
-
// Get the
|
|
140
|
-
const
|
|
141
|
-
const targetTab = tabs.find(t => targetTabIds.includes(t.id));
|
|
139
|
+
// Get the tab details to find its window
|
|
140
|
+
const targetTab = await chrome.tabs.get(targetTabIds[0]);
|
|
142
141
|
if (!targetTab || !targetTab.windowId) {
|
|
143
142
|
console.error('[SessionManager] Could not find valid window for tab');
|
|
144
143
|
throw new Error('Could not find a normal window for the tab');
|