@vforsh/argus-core 0.1.7 → 0.1.9
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/.tsbuildinfo +1 -1
- package/dist/protocol/http/dom.d.ts +0 -56
- package/dist/protocol/http/dom.d.ts.map +1 -1
- package/dist/protocol/http/dom.js +1 -58
- package/dist/protocol/http/dom.js.map +1 -1
- package/dist/protocol/http/domInteraction.d.ts +109 -0
- package/dist/protocol/http/domInteraction.d.ts.map +1 -0
- package/dist/protocol/http/domInteraction.js +146 -0
- package/dist/protocol/http/domInteraction.js.map +1 -0
- package/dist/protocol/http/extension.d.ts +48 -0
- package/dist/protocol/http/extension.d.ts.map +1 -1
- package/dist/protocol/http/netMock.d.ts +132 -0
- package/dist/protocol/http/netMock.d.ts.map +1 -0
- package/dist/protocol/http/netMock.js +27 -0
- package/dist/protocol/http/netMock.js.map +1 -0
- package/dist/protocol/http/record.d.ts +54 -0
- package/dist/protocol/http/record.d.ts.map +1 -0
- package/dist/protocol/http/record.js +3 -0
- package/dist/protocol/http/record.js.map +1 -0
- package/dist/protocol/http/status.d.ts +4 -0
- package/dist/protocol/http/status.d.ts.map +1 -1
- package/dist/protocol/http.d.ts +3 -0
- package/dist/protocol/http.d.ts.map +1 -1
- package/dist/protocol/http.js +3 -0
- package/dist/protocol/http.js.map +1 -1
- package/dist/registry/types.d.ts +14 -1
- package/dist/registry/types.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import type { DomElementTarget, ElementRef } from './dom.js';
|
|
2
|
+
/** Viewport coordinate or delta used by pointer/mouse interaction commands. */
|
|
3
|
+
export type DomPoint = {
|
|
4
|
+
/** CSS pixel x-coordinate or horizontal delta. */
|
|
5
|
+
x: number;
|
|
6
|
+
/** CSS pixel y-coordinate or vertical delta. */
|
|
7
|
+
y: number;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* Request payload for POST /dom/hover.
|
|
11
|
+
*/
|
|
12
|
+
export type DomHoverRequest = DomElementTarget & {
|
|
13
|
+
/** Allow multiple matches. If false and >1 match, error. Default: false. */
|
|
14
|
+
all?: boolean;
|
|
15
|
+
/** Filter elements by trimmed textContent. Plain string = exact match. /regex/flags = regex test. */
|
|
16
|
+
text?: string;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Response payload for POST /dom/hover.
|
|
20
|
+
*/
|
|
21
|
+
export type DomHoverResponse = {
|
|
22
|
+
ok: true;
|
|
23
|
+
/** Number of elements matched by selector. */
|
|
24
|
+
matches: number;
|
|
25
|
+
/** Number of elements hovered. */
|
|
26
|
+
hovered: number;
|
|
27
|
+
};
|
|
28
|
+
/** Mouse button for pointer-style interaction commands. Default: 'left'. */
|
|
29
|
+
export type MouseButton = 'left' | 'middle' | 'right';
|
|
30
|
+
/** Runtime list of mouse buttons accepted by pointer-style interaction commands. */
|
|
31
|
+
export declare const MOUSE_BUTTONS: readonly ["left", "middle", "right"];
|
|
32
|
+
/**
|
|
33
|
+
* Request payload for POST /dom/click.
|
|
34
|
+
*/
|
|
35
|
+
export type DomClickRequest = {
|
|
36
|
+
/** CSS selector to match element(s). */
|
|
37
|
+
selector?: string;
|
|
38
|
+
/** Stable element ref to click. Mutually exclusive with selector. */
|
|
39
|
+
ref?: ElementRef;
|
|
40
|
+
/** Allow multiple matches. If false and >1 match, error. Default: false. */
|
|
41
|
+
all?: boolean;
|
|
42
|
+
/** Viewport x-coordinate, or x-offset from element top-left when selector is set. */
|
|
43
|
+
x?: number;
|
|
44
|
+
/** Viewport y-coordinate, or y-offset from element top-left when selector is set. */
|
|
45
|
+
y?: number;
|
|
46
|
+
/** Mouse button to click. Default: 'left'. */
|
|
47
|
+
button?: MouseButton;
|
|
48
|
+
/** Filter elements by trimmed textContent. Plain string = exact match. /regex/flags = regex test. */
|
|
49
|
+
text?: string;
|
|
50
|
+
/** Wait up to this many ms for selector to appear before executing. */
|
|
51
|
+
wait?: number;
|
|
52
|
+
};
|
|
53
|
+
/** Schema for POST /dom/click request payloads. */
|
|
54
|
+
export declare const domClickRequestSchema: import("../schema.js").ProtocolSchema<DomClickRequest>;
|
|
55
|
+
/**
|
|
56
|
+
* Response payload for POST /dom/click.
|
|
57
|
+
*/
|
|
58
|
+
export type DomClickResponse = {
|
|
59
|
+
ok: true;
|
|
60
|
+
/** Number of elements matched by selector. */
|
|
61
|
+
matches: number;
|
|
62
|
+
/** Number of elements clicked. */
|
|
63
|
+
clicked: number;
|
|
64
|
+
};
|
|
65
|
+
/**
|
|
66
|
+
* Request payload for POST /dom/drag.
|
|
67
|
+
*
|
|
68
|
+
* When selector/ref is present, x/y is an optional offset from the element's
|
|
69
|
+
* top-left corner. Without selector/ref, x/y is the required viewport start.
|
|
70
|
+
*/
|
|
71
|
+
export type DomDragRequest = {
|
|
72
|
+
/** CSS selector to match element(s). */
|
|
73
|
+
selector?: string;
|
|
74
|
+
/** Stable element ref to drag from. Mutually exclusive with selector. */
|
|
75
|
+
ref?: ElementRef;
|
|
76
|
+
/** Allow multiple matches. If false and >1 match, error. Default: false. */
|
|
77
|
+
all?: boolean;
|
|
78
|
+
/** Viewport x-coordinate, or x-offset from element top-left when selector/ref is set. */
|
|
79
|
+
x?: number;
|
|
80
|
+
/** Viewport y-coordinate, or y-offset from element top-left when selector/ref is set. */
|
|
81
|
+
y?: number;
|
|
82
|
+
/** Absolute viewport destination. Mutually exclusive with delta. */
|
|
83
|
+
to?: DomPoint;
|
|
84
|
+
/** Destination delta from the resolved start point. Mutually exclusive with to. */
|
|
85
|
+
delta?: DomPoint;
|
|
86
|
+
/** Mouse button to hold during the drag. Default: 'left'. */
|
|
87
|
+
button?: MouseButton;
|
|
88
|
+
/** Filter start elements by trimmed textContent. Plain string = exact match. /regex/flags = regex test. */
|
|
89
|
+
text?: string;
|
|
90
|
+
/** Wait up to this many ms for selector to appear before executing. */
|
|
91
|
+
wait?: number;
|
|
92
|
+
/** Total drag duration in ms. Default: 250. */
|
|
93
|
+
duration?: number;
|
|
94
|
+
/** Number of mouseMoved events between press and release. Default: 12. */
|
|
95
|
+
steps?: number;
|
|
96
|
+
};
|
|
97
|
+
/** Schema for POST /dom/drag request payloads. */
|
|
98
|
+
export declare const domDragRequestSchema: import("../schema.js").ProtocolSchema<DomDragRequest>;
|
|
99
|
+
/**
|
|
100
|
+
* Response payload for POST /dom/drag.
|
|
101
|
+
*/
|
|
102
|
+
export type DomDragResponse = {
|
|
103
|
+
ok: true;
|
|
104
|
+
/** Number of elements matched by selector/ref. Zero for coordinate-only drags. */
|
|
105
|
+
matches: number;
|
|
106
|
+
/** Number of drag gestures completed. */
|
|
107
|
+
dragged: number;
|
|
108
|
+
};
|
|
109
|
+
//# sourceMappingURL=domInteraction.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"domInteraction.d.ts","sourceRoot":"","sources":["../../../src/protocol/http/domInteraction.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAE5D,+EAA+E;AAC/E,MAAM,MAAM,QAAQ,GAAG;IACtB,kDAAkD;IAClD,CAAC,EAAE,MAAM,CAAA;IACT,gDAAgD;IAChD,CAAC,EAAE,MAAM,CAAA;CACT,CAAA;AAED;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG,gBAAgB,GAAG;IAChD,4EAA4E;IAC5E,GAAG,CAAC,EAAE,OAAO,CAAA;IACb,qGAAqG;IACrG,IAAI,CAAC,EAAE,MAAM,CAAA;CACb,CAAA;AAED;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC9B,EAAE,EAAE,IAAI,CAAA;IACR,8CAA8C;IAC9C,OAAO,EAAE,MAAM,CAAA;IACf,kCAAkC;IAClC,OAAO,EAAE,MAAM,CAAA;CACf,CAAA;AAED,4EAA4E;AAC5E,MAAM,MAAM,WAAW,GAAG,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAA;AA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AM,CAAA;IACb,uEAAuE;IACvE,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,0EAA0E;IAC1E,KAAK,CAAC,EAAE,MAAM,CAAA;CACd,CAAA;AAED,kDAAkD;AAClD,eAAO,MAAM,oBAAoB,uDAsE/B,CAAA;AAEF;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAC7B,EAAE,EAAE,IAAI,CAAA;IACR,kFAAkF;IAClF,OAAO,EAAE,MAAM,CAAA;IACf,yCAAyC;IACzC,OAAO,EAAE,MAAM,CAAA;CACf,CAAA"}
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { defineProtocolSchema, invalidProtocolPayload, isProtocolObject, validProtocolPayload } from '../schema.js';
|
|
2
|
+
/** Runtime list of mouse buttons accepted by pointer-style interaction commands. */
|
|
3
|
+
export const MOUSE_BUTTONS = ['left', 'middle', 'right'];
|
|
4
|
+
/** Schema for POST /dom/click request payloads. */
|
|
5
|
+
export const domClickRequestSchema = defineProtocolSchema((value) => {
|
|
6
|
+
if (!isProtocolObject(value)) {
|
|
7
|
+
return invalidProtocolPayload('request body must be an object');
|
|
8
|
+
}
|
|
9
|
+
const selector = optionalString(value, 'selector');
|
|
10
|
+
const ref = optionalString(value, 'ref');
|
|
11
|
+
const hasSelector = selector != null && selector.length > 0;
|
|
12
|
+
const hasRef = ref != null && ref.length > 0;
|
|
13
|
+
const hasCoords = value.x != null || value.y != null;
|
|
14
|
+
if (!hasSelector && !hasRef && !hasCoords) {
|
|
15
|
+
return invalidProtocolPayload('selector, ref, or x,y coordinates are required');
|
|
16
|
+
}
|
|
17
|
+
if (hasSelector && hasRef) {
|
|
18
|
+
return invalidProtocolPayload('selector and ref are mutually exclusive');
|
|
19
|
+
}
|
|
20
|
+
if (hasCoords && (!isFiniteNumber(value.x) || !isFiniteNumber(value.y))) {
|
|
21
|
+
return invalidProtocolPayload('both x and y must be finite numbers');
|
|
22
|
+
}
|
|
23
|
+
if (value.all != null && typeof value.all !== 'boolean') {
|
|
24
|
+
return invalidProtocolPayload('all must be a boolean');
|
|
25
|
+
}
|
|
26
|
+
if (value.button != null && !isMouseButton(value.button)) {
|
|
27
|
+
return invalidProtocolPayload(`button must be one of: ${MOUSE_BUTTONS.join(', ')}`);
|
|
28
|
+
}
|
|
29
|
+
if (value.wait != null && (!isFiniteNumber(value.wait) || value.wait < 0)) {
|
|
30
|
+
return invalidProtocolPayload('wait must be a non-negative number (ms)');
|
|
31
|
+
}
|
|
32
|
+
if (value.text != null && typeof value.text !== 'string') {
|
|
33
|
+
return invalidProtocolPayload('text must be a string');
|
|
34
|
+
}
|
|
35
|
+
const request = {
|
|
36
|
+
all: value.all ?? false,
|
|
37
|
+
button: value.button ?? 'left',
|
|
38
|
+
wait: value.wait ?? 0,
|
|
39
|
+
};
|
|
40
|
+
if (hasSelector)
|
|
41
|
+
request.selector = selector;
|
|
42
|
+
if (hasRef)
|
|
43
|
+
request.ref = ref;
|
|
44
|
+
if (hasCoords) {
|
|
45
|
+
request.x = value.x;
|
|
46
|
+
request.y = value.y;
|
|
47
|
+
}
|
|
48
|
+
if (typeof value.text === 'string') {
|
|
49
|
+
request.text = value.text;
|
|
50
|
+
}
|
|
51
|
+
return validProtocolPayload(request);
|
|
52
|
+
});
|
|
53
|
+
/** Schema for POST /dom/drag request payloads. */
|
|
54
|
+
export const domDragRequestSchema = defineProtocolSchema((value) => {
|
|
55
|
+
if (!isProtocolObject(value)) {
|
|
56
|
+
return invalidProtocolPayload('request body must be an object');
|
|
57
|
+
}
|
|
58
|
+
const selector = optionalString(value, 'selector');
|
|
59
|
+
const ref = optionalString(value, 'ref');
|
|
60
|
+
const hasSelector = selector != null && selector.length > 0;
|
|
61
|
+
const hasRef = ref != null && ref.length > 0;
|
|
62
|
+
const hasCoords = value.x != null || value.y != null;
|
|
63
|
+
const hasTo = value.to != null;
|
|
64
|
+
const hasDelta = value.delta != null;
|
|
65
|
+
const to = optionalPoint(value, 'to');
|
|
66
|
+
const delta = optionalPoint(value, 'delta');
|
|
67
|
+
if (!hasSelector && !hasRef && !hasCoords) {
|
|
68
|
+
return invalidProtocolPayload('selector, ref, or x,y start coordinates are required');
|
|
69
|
+
}
|
|
70
|
+
if (hasSelector && hasRef) {
|
|
71
|
+
return invalidProtocolPayload('selector and ref are mutually exclusive');
|
|
72
|
+
}
|
|
73
|
+
if (hasCoords && (!isFiniteNumber(value.x) || !isFiniteNumber(value.y))) {
|
|
74
|
+
return invalidProtocolPayload('both x and y must be finite numbers');
|
|
75
|
+
}
|
|
76
|
+
if (hasTo === hasDelta) {
|
|
77
|
+
return invalidProtocolPayload('exactly one of to or delta is required');
|
|
78
|
+
}
|
|
79
|
+
if (!to.ok) {
|
|
80
|
+
return invalidProtocolPayload(to.message);
|
|
81
|
+
}
|
|
82
|
+
if (!delta.ok) {
|
|
83
|
+
return invalidProtocolPayload(delta.message);
|
|
84
|
+
}
|
|
85
|
+
if (value.all != null && typeof value.all !== 'boolean') {
|
|
86
|
+
return invalidProtocolPayload('all must be a boolean');
|
|
87
|
+
}
|
|
88
|
+
if (value.button != null && !isMouseButton(value.button)) {
|
|
89
|
+
return invalidProtocolPayload(`button must be one of: ${MOUSE_BUTTONS.join(', ')}`);
|
|
90
|
+
}
|
|
91
|
+
if (value.wait != null && (!isFiniteNumber(value.wait) || value.wait < 0)) {
|
|
92
|
+
return invalidProtocolPayload('wait must be a non-negative number (ms)');
|
|
93
|
+
}
|
|
94
|
+
if (value.duration != null && (!isFiniteNumber(value.duration) || value.duration < 0)) {
|
|
95
|
+
return invalidProtocolPayload('duration must be a non-negative number (ms)');
|
|
96
|
+
}
|
|
97
|
+
if (value.steps != null && !isPositiveInteger(value.steps)) {
|
|
98
|
+
return invalidProtocolPayload('steps must be a positive integer');
|
|
99
|
+
}
|
|
100
|
+
if (value.text != null && typeof value.text !== 'string') {
|
|
101
|
+
return invalidProtocolPayload('text must be a string');
|
|
102
|
+
}
|
|
103
|
+
const request = {
|
|
104
|
+
all: value.all ?? false,
|
|
105
|
+
button: value.button ?? 'left',
|
|
106
|
+
wait: value.wait ?? 0,
|
|
107
|
+
duration: value.duration ?? 250,
|
|
108
|
+
steps: value.steps ?? 12,
|
|
109
|
+
};
|
|
110
|
+
if (hasSelector)
|
|
111
|
+
request.selector = selector;
|
|
112
|
+
if (hasRef)
|
|
113
|
+
request.ref = ref;
|
|
114
|
+
if (hasCoords) {
|
|
115
|
+
request.x = value.x;
|
|
116
|
+
request.y = value.y;
|
|
117
|
+
}
|
|
118
|
+
if (to.ok && to.point)
|
|
119
|
+
request.to = to.point;
|
|
120
|
+
if (delta.ok && delta.point)
|
|
121
|
+
request.delta = delta.point;
|
|
122
|
+
if (typeof value.text === 'string')
|
|
123
|
+
request.text = value.text;
|
|
124
|
+
return validProtocolPayload(request);
|
|
125
|
+
});
|
|
126
|
+
const optionalString = (value, key) => {
|
|
127
|
+
const field = value[key];
|
|
128
|
+
return typeof field === 'string' ? field : undefined;
|
|
129
|
+
};
|
|
130
|
+
const isFiniteNumber = (value) => typeof value === 'number' && Number.isFinite(value);
|
|
131
|
+
const isPositiveInteger = (value) => isFiniteNumber(value) && Number.isInteger(value) && value >= 1;
|
|
132
|
+
const isMouseButton = (value) => typeof value === 'string' && MOUSE_BUTTONS.includes(value);
|
|
133
|
+
const optionalPoint = (value, key) => {
|
|
134
|
+
const field = value[key];
|
|
135
|
+
if (field == null) {
|
|
136
|
+
return { ok: true };
|
|
137
|
+
}
|
|
138
|
+
if (!isProtocolObject(field)) {
|
|
139
|
+
return { ok: false, message: `${key} must be an object with finite x and y numbers` };
|
|
140
|
+
}
|
|
141
|
+
if (!isFiniteNumber(field.x) || !isFiniteNumber(field.y)) {
|
|
142
|
+
return { ok: false, message: `${key}.x and ${key}.y must be finite numbers` };
|
|
143
|
+
}
|
|
144
|
+
return { ok: true, point: { x: field.x, y: field.y } };
|
|
145
|
+
};
|
|
146
|
+
//# sourceMappingURL=domInteraction.js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GAAG,gDAAgD,EAAE,CAAA;IACtF,CAAC;IACD,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;QAC1D,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,GAAG,UAAU,GAAG,2BAA2B,EAAE,CAAA;IAC9E,CAAC;IACD,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC,EAAE,KAAK,CAAC,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,CAAC,EAAE,EAAE,CAAA;AACvD,CAAC,CAAA"}
|
|
@@ -4,9 +4,57 @@ export type ExtensionBrowserTab = {
|
|
|
4
4
|
title: string;
|
|
5
5
|
faviconUrl?: string;
|
|
6
6
|
attached: boolean;
|
|
7
|
+
watcherId?: string;
|
|
7
8
|
};
|
|
8
9
|
export type ExtensionTabsResponse = {
|
|
9
10
|
ok: true;
|
|
10
11
|
tabs: ExtensionBrowserTab[];
|
|
11
12
|
};
|
|
13
|
+
/** Result of an extension-control attach/detach request after the extension has applied it. */
|
|
14
|
+
export type ExtensionTabActionResponse = {
|
|
15
|
+
ok: true;
|
|
16
|
+
tab: ExtensionBrowserTab;
|
|
17
|
+
watcherId?: string;
|
|
18
|
+
};
|
|
19
|
+
/** Runtime state for the extension-control native messaging bridge. */
|
|
20
|
+
export type ExtensionControlBridgeStatus = {
|
|
21
|
+
connected: boolean;
|
|
22
|
+
watcherId: string | null;
|
|
23
|
+
watcherHost: string | null;
|
|
24
|
+
watcherPort: number | null;
|
|
25
|
+
pid: number | null;
|
|
26
|
+
lastMessageAt: number | null;
|
|
27
|
+
};
|
|
28
|
+
/** Runtime state for one tab-scoped extension watcher bridge. */
|
|
29
|
+
export type ExtensionTabBridgeStatus = {
|
|
30
|
+
tabId: number;
|
|
31
|
+
connected: boolean;
|
|
32
|
+
watcherId: string | null;
|
|
33
|
+
watcherHost: string | null;
|
|
34
|
+
watcherPort: number | null;
|
|
35
|
+
pid: number | null;
|
|
36
|
+
targetId: string | null;
|
|
37
|
+
targetTitle: string | null;
|
|
38
|
+
targetUrl: string | null;
|
|
39
|
+
targetReady: boolean | null;
|
|
40
|
+
lastMessageAt: number | null;
|
|
41
|
+
};
|
|
42
|
+
/** Recent extension-side event surfaced for diagnostics. */
|
|
43
|
+
export type ExtensionRecentEvent = {
|
|
44
|
+
ts: number;
|
|
45
|
+
level: 'info' | 'error';
|
|
46
|
+
source: 'popup' | 'bridge' | 'debugger';
|
|
47
|
+
message: string;
|
|
48
|
+
};
|
|
49
|
+
/** Live diagnostics from the extension-control watcher and connected browser extension. */
|
|
50
|
+
export type ExtensionDiagnosticsResponse = {
|
|
51
|
+
ok: true;
|
|
52
|
+
extension: {
|
|
53
|
+
id: string | null;
|
|
54
|
+
version: string | null;
|
|
55
|
+
};
|
|
56
|
+
control: ExtensionControlBridgeStatus;
|
|
57
|
+
tabWatchers: ExtensionTabBridgeStatus[];
|
|
58
|
+
recentEvents: ExtensionRecentEvent[];
|
|
59
|
+
};
|
|
12
60
|
//# sourceMappingURL=extension.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extension.d.ts","sourceRoot":"","sources":["../../../src/protocol/http/extension.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,mBAAmB,GAAG;IACjC,KAAK,EAAE,MAAM,CAAA;IACb,GAAG,EAAE,MAAM,CAAA;IACX,KAAK,EAAE,MAAM,CAAA;IACb,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,EAAE,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"extension.d.ts","sourceRoot":"","sources":["../../../src/protocol/http/extension.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,mBAAmB,GAAG;IACjC,KAAK,EAAE,MAAM,CAAA;IACb,GAAG,EAAE,MAAM,CAAA;IACX,KAAK,EAAE,MAAM,CAAA;IACb,UAA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,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,GAAG,OAAO,CAAA;IACvB,MAAM,EAAE,OAAO,GAAG,QAAQ,GAAG,UAAU,CAAA;IACvC,OAAO,EAAE,MAAM,CAAA;CACf,CAAA;AAED,2FAA2F;AAC3F,MAAM,MAAM,4BAA4B,GAAG;IAC1C,EAAE,EAAE,IAAI,CAAA;IACR,SAAS,EAAE;QACV,EAAE,EAAE,MAAM,GAAG,IAAI,CAAA;QACjB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;KACtB,CAAA;IACD,OAAO,EAAE,4BAA4B,CAAA;IACrC,WAAW,EAAE,wBAAwB,EAAE,CAAA;IACvC,YAAY,EAAE,oBAAoB,EAAE,CAAA;CACpC,CAAA"}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Network request mocking protocol (`/net/mock*` endpoints).
|
|
3
|
+
*
|
|
4
|
+
* Rules intercept live requests via the CDP `Fetch` domain. Each rule pairs a
|
|
5
|
+
* match (URL pattern + optional method/resource-type) with an action:
|
|
6
|
+
* block, fail with a network error, fulfill with a stubbed response, or
|
|
7
|
+
* continue with rewrites. Rules persist in the watcher until removed and are
|
|
8
|
+
* re-armed when the watcher reattaches.
|
|
9
|
+
*/
|
|
10
|
+
/**
|
|
11
|
+
* Match criteria for a mock rule.
|
|
12
|
+
*
|
|
13
|
+
* `url` is matched against the full request URL, case-insensitively.
|
|
14
|
+
* `*` matches any run of characters; a pattern without `*` is treated as a
|
|
15
|
+
* substring match (equivalent to `*pattern*`).
|
|
16
|
+
*/
|
|
17
|
+
export type NetMockMatch = {
|
|
18
|
+
/** URL wildcard pattern (substring match when it contains no `*`). */
|
|
19
|
+
url: string;
|
|
20
|
+
/** Optional HTTP method filter (case-insensitive, e.g. "POST"). */
|
|
21
|
+
method?: string;
|
|
22
|
+
/** Optional CDP resource type filter (case-insensitive, e.g. "Fetch", "XHR", "Document"). */
|
|
23
|
+
resourceType?: string;
|
|
24
|
+
};
|
|
25
|
+
/** One HTTP header entry used in fulfill/continue actions. */
|
|
26
|
+
export type NetMockHeader = {
|
|
27
|
+
name: string;
|
|
28
|
+
value: string;
|
|
29
|
+
};
|
|
30
|
+
/** CDP network error reasons accepted by `fail` actions. */
|
|
31
|
+
export declare const NET_MOCK_FAIL_REASONS: readonly ["Failed", "Aborted", "TimedOut", "AccessDenied", "ConnectionClosed", "ConnectionReset", "ConnectionRefused", "ConnectionAborted", "ConnectionFailed", "NameNotResolved", "InternetDisconnected", "AddressUnreachable", "BlockedByClient", "BlockedByResponse"];
|
|
32
|
+
/** Network error reason for `fail` actions. */
|
|
33
|
+
export type NetMockFailReason = (typeof NET_MOCK_FAIL_REASONS)[number];
|
|
34
|
+
/**
|
|
35
|
+
* Action applied when a rule matches.
|
|
36
|
+
*
|
|
37
|
+
* - `block` aborts the request as `BlockedByClient`.
|
|
38
|
+
* - `fail` aborts with the given network error reason, so page `fetch()` calls reject.
|
|
39
|
+
* - `fulfill` answers with a synthetic response; the request never reaches the network.
|
|
40
|
+
* - `continue` forwards the request, optionally overriding headers or the URL host/origin.
|
|
41
|
+
*/
|
|
42
|
+
export type NetMockAction = {
|
|
43
|
+
kind: 'block';
|
|
44
|
+
} | {
|
|
45
|
+
kind: 'fail';
|
|
46
|
+
reason: NetMockFailReason;
|
|
47
|
+
} | {
|
|
48
|
+
kind: 'fulfill';
|
|
49
|
+
status: number;
|
|
50
|
+
headers?: NetMockHeader[];
|
|
51
|
+
bodyBase64?: string;
|
|
52
|
+
} | {
|
|
53
|
+
kind: 'continue';
|
|
54
|
+
setHeaders?: NetMockHeader[];
|
|
55
|
+
rewriteHost?: string;
|
|
56
|
+
};
|
|
57
|
+
/** One installed mock rule, including hit accounting. */
|
|
58
|
+
export type NetMockRule = {
|
|
59
|
+
/** Watcher-local rule id, unique for the watcher lifetime. */
|
|
60
|
+
id: number;
|
|
61
|
+
match: NetMockMatch;
|
|
62
|
+
action: NetMockAction;
|
|
63
|
+
/** Delay before the action executes, in milliseconds. */
|
|
64
|
+
delayMs?: number;
|
|
65
|
+
/** Maximum number of applications; the rule stops matching after `hits` reaches this. Undefined = unlimited. */
|
|
66
|
+
times?: number;
|
|
67
|
+
/** How many requests this rule has been applied to. */
|
|
68
|
+
hits: number;
|
|
69
|
+
/** Epoch ms when the rule was added. */
|
|
70
|
+
createdAt: number;
|
|
71
|
+
};
|
|
72
|
+
/** POST /net/mock/add request payload. */
|
|
73
|
+
export type NetMockAddRequest = {
|
|
74
|
+
match: NetMockMatch;
|
|
75
|
+
action: NetMockAction;
|
|
76
|
+
/** Delay before the action executes, in milliseconds. Must be a finite number >= 0. */
|
|
77
|
+
delayMs?: number;
|
|
78
|
+
/** Maximum number of applications. Must be an integer >= 1. */
|
|
79
|
+
times?: number;
|
|
80
|
+
};
|
|
81
|
+
/** POST /net/mock/add response. */
|
|
82
|
+
export type NetMockAddResponse = {
|
|
83
|
+
ok: true;
|
|
84
|
+
/** Whether the watcher is currently attached to a CDP target. */
|
|
85
|
+
attached: boolean;
|
|
86
|
+
/** Whether Fetch interception is active on the attached target. False when detached (rule is queued). */
|
|
87
|
+
enabled: boolean;
|
|
88
|
+
/** The installed rule. */
|
|
89
|
+
rule: NetMockRule;
|
|
90
|
+
/** Optional error details when interception could not be enabled. */
|
|
91
|
+
error?: {
|
|
92
|
+
message: string;
|
|
93
|
+
code?: string;
|
|
94
|
+
} | null;
|
|
95
|
+
};
|
|
96
|
+
/** POST /net/mock/remove request payload. */
|
|
97
|
+
export type NetMockRemoveRequest = {
|
|
98
|
+
/** Rule id to remove. */
|
|
99
|
+
id: number;
|
|
100
|
+
};
|
|
101
|
+
/** POST /net/mock/remove response. */
|
|
102
|
+
export type NetMockRemoveResponse = {
|
|
103
|
+
ok: true;
|
|
104
|
+
/** True when a rule with the given id existed and was removed. */
|
|
105
|
+
removed: boolean;
|
|
106
|
+
/** Whether Fetch interception remains active after the removal. */
|
|
107
|
+
enabled: boolean;
|
|
108
|
+
};
|
|
109
|
+
/** POST /net/mock/clear response. */
|
|
110
|
+
export type NetMockClearResponse = {
|
|
111
|
+
ok: true;
|
|
112
|
+
/** Number of rules removed. */
|
|
113
|
+
removed: number;
|
|
114
|
+
/** Whether Fetch interception remains active (always false after clear unless disable failed). */
|
|
115
|
+
enabled: boolean;
|
|
116
|
+
};
|
|
117
|
+
/** GET /net/mock response. */
|
|
118
|
+
export type NetMockStatusResponse = {
|
|
119
|
+
ok: true;
|
|
120
|
+
/** Whether the watcher is currently attached to a CDP target. */
|
|
121
|
+
attached: boolean;
|
|
122
|
+
/** Whether Fetch interception is active on the attached target. */
|
|
123
|
+
enabled: boolean;
|
|
124
|
+
/** Installed rules in match order (first match wins). */
|
|
125
|
+
rules: NetMockRule[];
|
|
126
|
+
/** Last interception error (enable/disable or action failure), if any. */
|
|
127
|
+
lastError?: {
|
|
128
|
+
message: string;
|
|
129
|
+
code?: string;
|
|
130
|
+
} | null;
|
|
131
|
+
};
|
|
132
|
+
//# sourceMappingURL=netMock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"netMock.d.ts","sourceRoot":"","sources":["../../../src/protocol/http/netMock.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH;;;;;;GAMG;AACH,MAAM,MAAM,YAAY,GAAG;IAC1B,sEAAsE;IACtE,GAAG,EAAE,MAAM,CAAA;IACX,mEAAmE;IACnE,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,6FAA6F;IAC7F,YAAY,CAAC,EAAE,MAAM,CAAA;CACrB,CAAA;AAED,8DAA8D;AAC9D,MAAM,MAAM,aAAa,GAAG;IAC3B,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,MAAM,CAAA;CACb,CAAA;AAED,4DAA4D;AAC5D,eAAO,MAAM,qBAAqB,0QAexB,CAAA;AAEV,+CAA+C;AAC/C,MAAM,MAAM,iBAAiB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,C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qEAAqE;IACrE,KAAK,CAAC,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACjD,CAAA;AAED,6CAA6C;AAC7C,MAAM,MAAM,oBAAoB,GAAG;IAClC,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAA;CACV,CAAA;AAED,sCAAsC;AACtC,MAAM,MAAM,qBAAqB,GAAG;IACnC,EAAE,EAAE,IAAI,CAAA;IACR,kEAAkE;IAClE,OAAO,EAAE,OAAO,CAAA;IAChB,mEAAmE;IACnE,OAAO,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,qCAAqC;AACrC,MAAM,MAAM,oBAAoB,GAAG;IAClC,EAAE,EAAE,IAAI,CAAA;IACR,+BAA+B;IAC/B,OAAO,EAAE,MAAM,CAAA;IACf,kGAAkG;IAClG,OAAO,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,8BAA8B;AAC9B,MAAM,MAAM,qBAAqB,GAAG;IACnC,EAAE,EAAE,IAAI,CAAA;IACR,iEAAiE;IACjE,QAAQ,EAAE,OAAO,CAAA;IACjB,mEAAmE;IACnE,OAAO,EAAE,OAAO,CAAA;IAChB,yDAAyD;IACzD,KAAK,EAAE,WAAW,EAAE,CAAA;IACpB,0EAA0E;IAC1E,SAAS,CAAC,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACrD,CAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Network request mocking protocol (`/net/mock*` endpoints).
|
|
3
|
+
*
|
|
4
|
+
* Rules intercept live requests via the CDP `Fetch` domain. Each rule pairs a
|
|
5
|
+
* match (URL pattern + optional method/resource-type) with an action:
|
|
6
|
+
* block, fail with a network error, fulfill with a stubbed response, or
|
|
7
|
+
* continue with rewrites. Rules persist in the watcher until removed and are
|
|
8
|
+
* re-armed when the watcher reattaches.
|
|
9
|
+
*/
|
|
10
|
+
/** CDP network error reasons accepted by `fail` actions. */
|
|
11
|
+
export const NET_MOCK_FAIL_REASONS = [
|
|
12
|
+
'Failed',
|
|
13
|
+
'Aborted',
|
|
14
|
+
'TimedOut',
|
|
15
|
+
'AccessDenied',
|
|
16
|
+
'ConnectionClosed',
|
|
17
|
+
'ConnectionReset',
|
|
18
|
+
'ConnectionRefused',
|
|
19
|
+
'ConnectionAborted',
|
|
20
|
+
'ConnectionFailed',
|
|
21
|
+
'NameNotResolved',
|
|
22
|
+
'InternetDisconnected',
|
|
23
|
+
'AddressUnreachable',
|
|
24
|
+
'BlockedByClient',
|
|
25
|
+
'BlockedByResponse',
|
|
26
|
+
];
|
|
27
|
+
//# sourceMappingURL=netMock.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"netMock.js","sourceRoot":"","sources":["../../../src/protocol/http/netMock.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAwBH,4DAA4D;AAC5D,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACpC,QAAQ;IACR,SAAS;IACT,UAAU;IACV,cAAc;IACd,kBAAkB;IAClB,iBAAiB;IACjB,mBAAmB;IACnB,mBAAmB;IACnB,kBAAkB;IAClB,iBAAiB;IACjB,sBAAsB;IACtB,oBAAoB;IACpB,iBAAiB;IACjB,mBAAmB;CACV,CAAA"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type { ScreenshotClipRegion } from './screenshot.js';
|
|
2
|
+
/** Viewport-relative crop rectangle in CSS pixels. */
|
|
3
|
+
export type RecordClipRegion = ScreenshotClipRegion;
|
|
4
|
+
/** Supported recording containers/codecs. */
|
|
5
|
+
export declare const RECORD_FORMATS: readonly ["mp4", "webm"];
|
|
6
|
+
/** Recording container/codec preset. */
|
|
7
|
+
export type RecordFormat = (typeof RECORD_FORMATS)[number];
|
|
8
|
+
/** Shared options for video recording requests. */
|
|
9
|
+
export type RecordOptions = {
|
|
10
|
+
outFile?: string;
|
|
11
|
+
selector?: string;
|
|
12
|
+
/** Viewport-relative crop rectangle in CSS pixels. Mutually exclusive with `selector`. */
|
|
13
|
+
clip?: RecordClipRegion;
|
|
14
|
+
/** Output frames per second. Defaults to 30. */
|
|
15
|
+
fps?: number;
|
|
16
|
+
/** Output format. Defaults to mp4 unless inferred from outFile extension. */
|
|
17
|
+
format?: RecordFormat;
|
|
18
|
+
};
|
|
19
|
+
/** Request payload for POST /record. */
|
|
20
|
+
export type RecordRequest = RecordOptions & {
|
|
21
|
+
/** Capture duration in milliseconds. */
|
|
22
|
+
durationMs: number;
|
|
23
|
+
};
|
|
24
|
+
/** Request payload for POST /record/start. */
|
|
25
|
+
export type RecordStartRequest = RecordOptions;
|
|
26
|
+
/** Response payload for POST /record/start. */
|
|
27
|
+
export type RecordStartResponse = {
|
|
28
|
+
ok: true;
|
|
29
|
+
recordId: string;
|
|
30
|
+
sessionName: string;
|
|
31
|
+
outFile: string;
|
|
32
|
+
format: RecordFormat;
|
|
33
|
+
fps: number;
|
|
34
|
+
clipped: boolean;
|
|
35
|
+
};
|
|
36
|
+
/** Request payload for POST /record/stop. */
|
|
37
|
+
export type RecordStopRequest = {
|
|
38
|
+
recordId?: string;
|
|
39
|
+
outFile?: string;
|
|
40
|
+
};
|
|
41
|
+
/** Response payload for POST /record and POST /record/stop. */
|
|
42
|
+
export type RecordStopResponse = {
|
|
43
|
+
ok: true;
|
|
44
|
+
recordId: string;
|
|
45
|
+
sessionName: string;
|
|
46
|
+
outFile: string;
|
|
47
|
+
format: RecordFormat;
|
|
48
|
+
frameCount: number;
|
|
49
|
+
durationMs: number;
|
|
50
|
+
fps: number;
|
|
51
|
+
clipped: boolean;
|
|
52
|
+
};
|
|
53
|
+
export type RecordResponse = RecordStopResponse;
|
|
54
|
+
//# sourceMappingURL=record.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"record.d.ts","sourceRoot":"","sources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AE,IAAI,CAAA;IACR,QAAQ,EAAE,MAAM,CAAA;IAChB,WAAW,EAAE,MAAM,CAAA;IACnB,OAAO,EAAE,MAAM,CAAA;IACf,MAAM,EAAE,YAAY,CAAA;IACpB,UAAU,EAAE,MAAM,CAAA;IAClB,UAAU,EAAE,MAAM,CAAA;IAClB,GAAG,EAAE,MAAM,CAAA;IACX,OAAO,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,MAAM,MAAM,cAAc,GAAG,kBAAkB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"record.js","sourceRoot":"","sources":["../../../src/protocol/http/record.ts"],"names":[],"mappings":"AAKA,6CAA6C;AAC7C,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,KAAK,EAAE,MAAM,CAAU,CAAA"}
|
|
@@ -12,6 +12,10 @@ export type StatusResponse = {
|
|
|
12
12
|
target: {
|
|
13
13
|
title: string | null;
|
|
14
14
|
url: string | null;
|
|
15
|
+
/** Target type, such as `page` or `iframe`, when the source can report it. */
|
|
16
|
+
type?: string | null;
|
|
17
|
+
/** Parent target id for nested targets, e.g. `tab:<tabId>` for extension iframes. */
|
|
18
|
+
parentId?: string | null;
|
|
15
19
|
} | null;
|
|
16
20
|
dialog?: DialogStatus | null;
|
|
17
21
|
buffer: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../../../src/protocol/http/status.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAA;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC/C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAA;AAEzD,wCAAwC;AACxC,MAAM,MAAM,cAAc,GAAG;IAC5B,EAAE,EAAE,IAAI,CAAA;IACR,EAAE,EAAE,MAAM,CAAA;IACV,GAAG,EAAE,MAAM,CAAA;IACX,QAAQ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8C;IAC9C,cAAc,CAAC,EAAE,MAAM,CAAA;CACvB,CAAA;AAED,2CAA2C;AAC3C,MAAM,MAAM,gBAAgB,GAAG;IAC9B,EAAE,EAAE,IAAI,CAAA;CACR,CAAA;AAED,wCAAwC;AACxC,MAAM,MAAM,aAAa,GAAG;IAC3B,qDAAqD;IACrD,WAAW,CAAC,EAAE,OAAO,CAAA;CACrB,CAAA;AAED,yCAAyC;AACzC,MAAM,MAAM,cAAc,GAAG;IAC5B,EAAE,EAAE,IAAI,CAAA;CACR,CAAA"}
|
package/dist/protocol/http.d.ts
CHANGED
|
@@ -2,13 +2,16 @@ export * from './schema.js';
|
|
|
2
2
|
export type * from './http/status.js';
|
|
3
3
|
export type * from './http/logs.js';
|
|
4
4
|
export type * from './http/net.js';
|
|
5
|
+
export * from './http/netMock.js';
|
|
5
6
|
export type * from './http/eval.js';
|
|
6
7
|
export type * from './http/trace.js';
|
|
8
|
+
export * from './http/record.js';
|
|
7
9
|
export type * from './http/screenshot.js';
|
|
8
10
|
export type * from './http/snapshot.js';
|
|
9
11
|
export type * from './http/locate.js';
|
|
10
12
|
export type * from './http/code.js';
|
|
11
13
|
export * from './http/dom.js';
|
|
14
|
+
export * from './http/domInteraction.js';
|
|
12
15
|
export type * from './http/storage.js';
|
|
13
16
|
export type * from './http/auth.js';
|
|
14
17
|
export { AUTH_STATE_METADATA_SCHEMA_VERSION } from './http/auth.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/protocol/http.ts"],"names":[],"mappings":"AACA,cAAc,aAAa,CAAA;AAC3B,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,gBAAgB,CAAA;AACnC,mBAAmB,eAAe,CAAA;AAClC,mBAAmB,gBAAgB,CAAA;AACnC,mBAAmB,iBAAiB,CAAA;AACpC,mBAAmB,sBAAsB,CAAA;AACzC,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,gBAAgB,CAAA;AACnC,cAAc,eAAe,CAAA;AAC7B,mBAAmB,mBAAmB,CAAA;AACtC,mBAAmB,gBAAgB,CAAA;AACnC,OAAO,EAAE,kCAAkC,EAAE,MAAM,gBAAgB,CAAA;AACnE,mBAAmB,qBAAqB,CAAA;AACxC,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,sBAAsB,CAAA;AACzC,mBAAmB,qBAAqB,CAAA;AACxC,mBAAmB,kBAAkB,CAAA"}
|
|
1
|
+
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/protocol/http.ts"],"names":[],"mappings":"AACA,cAAc,aAAa,CAAA;AAC3B,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,gBAAgB,CAAA;AACnC,mBAAmB,eAAe,CAAA;AAClC,cAAc,mBAAmB,CAAA;AACjC,mBAAmB,gBAAgB,CAAA;AACnC,mBAAmB,iBAAiB,CAAA;AACpC,cAAc,kBAAkB,CAAA;AAChC,mBAAmB,sBAAsB,CAAA;AACzC,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,gBAAgB,CAAA;AACnC,cAAc,eAAe,CAAA;AAC7B,cAAc,0BAA0B,CAAA;AACxC,mBAAmB,mBAAmB,CAAA;AACtC,mBAAmB,gBAAgB,CAAA;AACnC,OAAO,EAAE,kCAAkC,EAAE,MAAM,gBAAgB,CAAA;AACnE,mBAAmB,qBAAqB,CAAA;AACxC,mBAAmB,oBAAoB,CAAA;AACvC,mBAAmB,kBAAkB,CAAA;AACrC,mBAAmB,sBAAsB,CAAA;AACzC,mBAAmB,qBAAqB,CAAA;AACxC,mBAAmB,kBAAkB,CAAA"}
|
package/dist/protocol/http.js
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
// Barrel re-exports — keeps existing import paths working.
|
|
2
2
|
export * from './schema.js';
|
|
3
|
+
export * from './http/netMock.js';
|
|
4
|
+
export * from './http/record.js';
|
|
3
5
|
export * from './http/dom.js';
|
|
6
|
+
export * from './http/domInteraction.js';
|
|
4
7
|
export { AUTH_STATE_METADATA_SCHEMA_VERSION } from './http/auth.js';
|
|
5
8
|
//# sourceMappingURL=http.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http.js","sourceRoot":"","sources":["../../src/protocol/http.ts"],"names":[],"mappings":"AAAA,2DAA2D;AAC3D,cAAc,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"http.js","sourceRoot":"","sources":["../../src/protocol/http.ts"],"names":[],"mappings":"AAAA,2DAA2D;AAC3D,cAAc,aAAa,CAAA;AAI3B,cAAc,mBAAmB,CAAA;AAGjC,cAAc,kBAAkB,CAAA;AAKhC,cAAc,eAAe,CAAA;AAC7B,cAAc,0BAA0B,CAAA;AAGxC,OAAO,EAAE,kCAAkC,EAAE,MAAM,gBAAgB,CAAA"}
|