@qontinui/ui-bridge-wrapper 0.12.0 → 0.14.0
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/README.md +119 -8
- package/dist/capture-specs-cli.cjs +166 -48
- package/dist/capture-specs-cli.cjs.map +1 -1
- package/dist/capture-specs-cli.d.ts.map +1 -1
- package/dist/index.cjs +83 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +83 -2
- package/dist/index.js.map +1 -1
- package/dist/inject-cli.cjs +278 -113
- package/dist/inject-cli.cjs.map +1 -1
- package/dist/inject-cli.d.ts +1 -1
- package/dist/inject-cli.d.ts.map +1 -1
- package/dist/login-web-cli.cjs +173 -52
- package/dist/login-web-cli.cjs.map +1 -1
- package/dist/login-web-cli.d.ts.map +1 -1
- package/dist/network-throttle.d.ts +5 -0
- package/dist/network-throttle.d.ts.map +1 -1
- package/dist/timeline-capture.d.ts +75 -9
- package/dist/timeline-capture.d.ts.map +1 -1
- package/dist/transports/headless.d.ts +46 -1
- package/dist/transports/headless.d.ts.map +1 -1
- package/dist/transports/injected.d.ts +8 -0
- package/dist/transports/injected.d.ts.map +1 -1
- package/dist/types.d.ts +3 -1
- package/dist/types.d.ts.map +1 -1
- package/package.json +4 -6
- package/dist/cli-args.d.ts +0 -13
- package/dist/cli-args.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"login-web-cli.d.ts","sourceRoot":"","sources":["../src/login-web-cli.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;
|
|
1
|
+
{"version":3,"file":"login-web-cli.d.ts","sourceRoot":"","sources":["../src/login-web-cli.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AA2BH,eAAO,MAAM,KAAK,khIA2DjB,CAAC;AAEF,uCAAuC;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gBAAgB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAClC,sGAAsG;IACtG,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,sEAAsE;IACtE,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;IACzB,8FAA8F;IAC9F,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,gHAAgH;IAChH,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
|
|
@@ -58,6 +58,11 @@ export declare function cdpConditions(profile: NetworkProfile): Record<string, u
|
|
|
58
58
|
/**
|
|
59
59
|
* Apply `profile` (and, with `disableCache`, turn the HTTP cache off — a warm
|
|
60
60
|
* cache would let a "slow network" reload paint instantly) to `page`.
|
|
61
|
+
*
|
|
62
|
+
* Neither reaches the document's in-memory image cache: an image URL the page
|
|
63
|
+
* has already decoded is served from memory, unthrottled, even with the HTTP
|
|
64
|
+
* cache off (observed on the Chromium Playwright 1.65 ships). A timed swap must
|
|
65
|
+
* use a URL the page has not loaded yet.
|
|
61
66
|
*/
|
|
62
67
|
export declare function applyNetworkEmulation(page: ThrottlePage, profile: NetworkProfile | null, disableCache: boolean): Promise<NetworkEmulation | null>;
|
|
63
68
|
//# sourceMappingURL=network-throttle.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"network-throttle.d.ts","sourceRoot":"","sources":["../src/network-throttle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAIH,oEAAoE;AACpE,MAAM,WAAW,cAAc;IAC7B,oCAAoC;IACpC,IAAI,EAAE,MAAM,CAAC;IACb,sCAAsC;IACtC,SAAS,EAAE,MAAM,CAAC;IAClB,kDAAkD;IAClD,YAAY,EAAE,MAAM,CAAC;IACrB,gDAAgD;IAChD,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,QAA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AM,cAAc,QAAS,CAAC;AACrC,eAAO,MAAM,mBAAmB,WAAa,CAAC;AAY9C;;;GAGG;AACH,wBAAgB,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,cAAc,CAkCzD;AAED,mFAAmF;AACnF,MAAM,WAAW,gBAAiB,SAAQ,cAAc;IACtD,6DAA6D;IAC7D,OAAO,EAAE,IAAI,CAAC;IACd,wFAAwF;IACxF,aAAa,EAAE,OAAO,CAAC;CACxB;AAED,gEAAgE;AAChE,MAAM,WAAW,YAAY;IAC3B,OAAO,IAAI;QACT,aAAa,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC;YACpC,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;SAC1E,CAAC,CAAC;KACJ,CAAC;CACH;AAED,wEAAwE;AACxE,wBAAgB,aAAa,CAAC,OAAO,EAAE,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAO9E;AAED;;;;;;;;GAQG;AACH,wBAAsB,qBAAqB,CACzC,IAAI,EAAE,YAAY,EAClB,OAAO,EAAE,cAAc,GAAG,IAAI,EAC9B,YAAY,EAAE,OAAO,GACpB,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAalC"}
|
|
@@ -16,16 +16,34 @@
|
|
|
16
16
|
* the slot's slow-network arrival). The action's own result rides on the
|
|
17
17
|
* timeline result, and a failed action fails the step.
|
|
18
18
|
*
|
|
19
|
-
* `reload: true` starts the clock at a fresh navigation commit
|
|
20
|
-
* the page
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
19
|
+
* `reload: true` starts the clock at a fresh navigation commit. Frame 1 is the
|
|
20
|
+
* first frame the page produced after that commit, and its `offsetMs` says how
|
|
21
|
+
* long after the commit the screenshot that produced it was requested. Right
|
|
22
|
+
* after the commit the reloaded document can have no compositor frame yet (the
|
|
23
|
+
* renderer is still evaluating the injected runtime at document start); then
|
|
24
|
+
* Chromium refuses the screenshot outright ({@link NO_COMPOSITOR_FRAME}), and
|
|
25
|
+
* frame 1 reads the tens of milliseconds the retries below took, not 0. Under
|
|
26
|
+
* a throttled network that first frame can still be the previous document's
|
|
27
|
+
* held frame, its body not yet arrived; `offsetMs` dates it either way. A
|
|
28
|
+
* reload re-runs the injected runtime and drops any media override the page
|
|
29
|
+
* held (the DOM is new), so the action waits for the runtime to be ready again
|
|
30
|
+
* before it answers — the next exec step finds a drivable page.
|
|
31
|
+
*
|
|
32
|
+
* That refusal, and no other error, is retried every
|
|
33
|
+
* {@link NO_COMPOSITOR_FRAME_RETRY_MS} ms until a frame comes back or the
|
|
34
|
+
* frame's deadline passes: `t0 + readyTimeoutMs` for frame 1 after a reload
|
|
35
|
+
* (the budget the reload already has), and the next frame's due time for every
|
|
36
|
+
* other frame. A retry is made only when it falls due before that deadline
|
|
37
|
+
* (`intervalMs: 0` is one attempt), so retries never take a later frame's
|
|
38
|
+
* slot; an attempt still under way when the next frame falls due delays that
|
|
39
|
+
* frame by what is left of it, as any slow screenshot does. A frame that took
|
|
40
|
+
* more than one attempt says how many in `attempts`.
|
|
24
41
|
*
|
|
25
42
|
* Every frame records what was MEASURED: the PNG's own dimensions and the
|
|
26
|
-
* instant the screenshot was requested. A frame that could
|
|
27
|
-
*
|
|
28
|
-
* never a gap silently
|
|
43
|
+
* instant the screenshot that produced it was requested. A frame that could
|
|
44
|
+
* not be taken, or was still refused at its deadline, is a per-frame `error`
|
|
45
|
+
* and makes the action answer `success: false` (exit 1), never a gap silently
|
|
46
|
+
* closed up.
|
|
29
47
|
*/
|
|
30
48
|
import { type FrameColorScheme, type FramePage } from './frame-capture.js';
|
|
31
49
|
/** The CLI-side action id. No in-page action is named this. */
|
|
@@ -33,6 +51,23 @@ export declare const CAPTURE_TIMELINE_ACTION = "captureTimeline";
|
|
|
33
51
|
export declare const MAX_TIMELINE_FRAMES = 120;
|
|
34
52
|
export declare const MAX_TIMELINE_INTERVAL_MS = 10000;
|
|
35
53
|
export declare const DEFAULT_TIMELINE_READY_TIMEOUT_MS = 30000;
|
|
54
|
+
/**
|
|
55
|
+
* Chromium's refusal to screenshot a document that has no compositor frame
|
|
56
|
+
* yet — CDP `Page.captureScreenshot` answering `Unable to capture screenshot`,
|
|
57
|
+
* measured on frame 1 right after a reload commit. The ONLY screenshot error
|
|
58
|
+
* {@link takeFrameByDeadline} retries; every other one is final at once.
|
|
59
|
+
*/
|
|
60
|
+
export declare const NO_COMPOSITOR_FRAME: RegExp;
|
|
61
|
+
/** The wait between attempts at a frame Chromium refused: about one 60 Hz frame. */
|
|
62
|
+
export declare const NO_COMPOSITOR_FRAME_RETRY_MS = 16;
|
|
63
|
+
/**
|
|
64
|
+
* The most sleeps one frame's wait for its due time may take: one for the
|
|
65
|
+
* wait, two more for timers that fire a millisecond early. A constant, so the
|
|
66
|
+
* bound never depends on the clock advancing: with a moving clock the due time
|
|
67
|
+
* ends the wait, and with a frozen injected `now` this cap does, instead of the
|
|
68
|
+
* schedule waiting forever.
|
|
69
|
+
*/
|
|
70
|
+
export declare const MAX_SLEEPS_PER_FRAME_WAIT = 3;
|
|
36
71
|
export interface CaptureTimelinePayload {
|
|
37
72
|
/** Directory the frames go into; must be empty or not exist yet. */
|
|
38
73
|
dir: string;
|
|
@@ -53,11 +88,17 @@ export interface TimelineFrame {
|
|
|
53
88
|
index: number;
|
|
54
89
|
/** Absolute path of the PNG, or null when the frame failed. */
|
|
55
90
|
path: string | null;
|
|
56
|
-
/**
|
|
91
|
+
/**
|
|
92
|
+
* ms from the timeline's start (the reload commit, or the action start) to
|
|
93
|
+
* the request of the attempt this frame records: the one that succeeded, or
|
|
94
|
+
* the last one refused.
|
|
95
|
+
*/
|
|
57
96
|
offsetMs: number;
|
|
58
97
|
capturedAt: string;
|
|
59
98
|
width: number | null;
|
|
60
99
|
height: number | null;
|
|
100
|
+
/** Screenshot attempts this frame took; present only when more than one. */
|
|
101
|
+
attempts?: number;
|
|
61
102
|
error?: string;
|
|
62
103
|
}
|
|
63
104
|
export interface TimelineResult {
|
|
@@ -96,6 +137,31 @@ export interface TimelinePage extends FramePage {
|
|
|
96
137
|
timeout: number;
|
|
97
138
|
}): Promise<unknown>;
|
|
98
139
|
}
|
|
140
|
+
/** One frame taken by {@link takeFrameByDeadline}: its PNG, or the last attempt's error. */
|
|
141
|
+
export type FrameShot = {
|
|
142
|
+
png: Uint8Array;
|
|
143
|
+
at: number;
|
|
144
|
+
attempts: number;
|
|
145
|
+
} | {
|
|
146
|
+
error: string;
|
|
147
|
+
at: number;
|
|
148
|
+
attempts: number;
|
|
149
|
+
};
|
|
150
|
+
/**
|
|
151
|
+
* Take one screenshot. A {@link NO_COMPOSITOR_FRAME} refusal is retried every
|
|
152
|
+
* {@link NO_COMPOSITOR_FRAME_RETRY_MS} ms for as long as the next attempt is
|
|
153
|
+
* due before `deadline` (an instant on the `now` clock); any other error is
|
|
154
|
+
* returned at once. `at` is the request instant of the attempt the result
|
|
155
|
+
* describes: the one that succeeded, or the last one refused.
|
|
156
|
+
*
|
|
157
|
+
* The clock bounds the retries only while it advances, so the attempts are
|
|
158
|
+
* also capped, by a count fixed ONCE from the budget before the first attempt:
|
|
159
|
+
* `ceil((deadline - start) / NO_COMPOSITOR_FRAME_RETRY_MS) + 2` — what the
|
|
160
|
+
* deadline admits at the nominal spacing, plus two for timers that fire early.
|
|
161
|
+
* With a moving clock the deadline ends the retries; with a frozen injected
|
|
162
|
+
* `now` the cap does, so a refusal can never spin the loop forever.
|
|
163
|
+
*/
|
|
164
|
+
export declare function takeFrameByDeadline(page: Pick<FramePage, 'screenshot'>, deadline: number, now: () => number): Promise<FrameShot>;
|
|
99
165
|
/** Run one timeline against `page`. */
|
|
100
166
|
export declare function captureTimeline(page: TimelinePage, payload: CaptureTimelinePayload, now?: () => number, execute?: (action: string, payload: unknown) => Promise<unknown>): Promise<TimelineResult>;
|
|
101
167
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"timeline-capture.d.ts","sourceRoot":"","sources":["../src/timeline-capture.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"timeline-capture.d.ts","sourceRoot":"","sources":["../src/timeline-capture.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AAKH,OAAO,EAKL,KAAK,gBAAgB,EACrB,KAAK,SAAS,EACf,MAAM,oBAAoB,CAAC;AAE5B,+DAA+D;AAC/D,eAAO,MAAM,uBAAuB,oBAAoB,CAAC;AAEzD,eAAO,MAAM,mBAAmB,MAAM,CAAC;AACvC,eAAO,MAAM,wBAAwB,QAAS,CAAC;AAC/C,eAAO,MAAM,iCAAiC,QAAS,CAAC;AAExD;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB,QAAiC,CAAC;AAElE,oFAAoF;AACpF,eAAO,MAAM,4BAA4B,KAAK,CAAC;AAE/C;;;;;;GAMG;AACH,eAAO,MAAM,yBAAyB,IAAI,CAAC;AAE3C,MAAM,WAAW,sBAAsB;IACrC,oEAAoE;IACpE,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,OAAO,CAAC;IAChB,cAAc,EAAE,MAAM,CAAC;IACvB,mFAAmF;IACnF,MAAM,CAAC,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAE,GAAG,IAAI,CAAC;CACtD;AAqBD,oFAAoF;AACpF,wBAAgB,2BAA2B,CAAC,OAAO,EAAE,OAAO,GAAG,sBAAsB,CAiDpF;AAED,iCAAiC;AACjC,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,+DAA+D;IAC/D,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB;;;;OAIG;IACH,Q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,CAAC,CAAC;CACrB;AAwBD,4FAA4F;AAC5F,MAAM,MAAM,SAAS,GACjB;IAAE,GAAG,EAAE,UAAU,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GACjD;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,CAAC;AAEpD;;;;;;;;;;;;;GAaG;AACH,wBAAsB,mBAAmB,CACvC,IAAI,EAAE,IAAI,CAAC,SAAS,EAAE,YAAY,CAAC,EACnC,QAAQ,EAAE,MAAM,EAChB,GAAG,EAAE,MAAM,MAAM,GAChB,OAAO,CAAC,SAAS,CAAC,CAqBpB;AAED,uCAAuC;AACvC,wBAAsB,eAAe,CACnC,IAAI,EAAE,YAAY,EAClB,OAAO,EAAE,sBAAsB,EAC/B,GAAG,GAAE,MAAM,MAAiB,EAC5B,OAAO,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,KAAK,OAAO,CAAC,OAAO,CAAC,GAC/D,OAAO,CAAC,cAAc,CAAC,CAsHzB;AAED;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CACrC,SAAS,EAAE;IAAE,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,KAAK,OAAO,GAAG,IAAI,CAAA;CAAE,EAC7F,OAAO,EAAE,MAAM,OAAO,EACtB,OAAO,CAAC,EAAE,MAAM,GACf,IAAI,CA6BN"}
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* Action code lives in the wrapper's handler registrations, not in the
|
|
13
13
|
* transport. Headless and headed differ only in the `headless` flag.
|
|
14
14
|
*/
|
|
15
|
-
import type { Browser, BrowserContext, Page } from 'playwright';
|
|
15
|
+
import type { Browser, BrowserContext, BrowserContextOptions, Page } from 'playwright';
|
|
16
16
|
import { BaseTransport } from '../base-transport.js';
|
|
17
17
|
import { HandlerRegistry } from '../handler-registry.js';
|
|
18
18
|
import type { TransportConfig, WrapperTransportKind } from '../types.js';
|
|
@@ -60,6 +60,43 @@ export interface HeadlessTransportOptions {
|
|
|
60
60
|
* `storageStatePath`.
|
|
61
61
|
*/
|
|
62
62
|
storageStatePath?: string;
|
|
63
|
+
/**
|
|
64
|
+
* Record a HAR of every request the browser context makes: Playwright's own
|
|
65
|
+
* `recordHar` shape (`{ path, content?, mode?, urlFilter?, omitContent? }`),
|
|
66
|
+
* passed to the launcher's `newContext` unchanged. Playwright writes the
|
|
67
|
+
* archive when the context closes, which this transport's `close()` does
|
|
68
|
+
* (the launcher closes the context before the browser), so the file is
|
|
69
|
+
* complete once `close()` resolves. A launch that fails inside the launcher
|
|
70
|
+
* writes no HAR. A `ready()` that fails AFTER the launch (an emulation
|
|
71
|
+
* refusal, an injected-runtime wait) may still leave a
|
|
72
|
+
* complete archive, because the tab is closed through the context, so a
|
|
73
|
+
* missing file is not how to tell that `ready()` failed.
|
|
74
|
+
*/
|
|
75
|
+
recordHar?: NonNullable<BrowserContextOptions['recordHar']>;
|
|
76
|
+
/**
|
|
77
|
+
* Record a video of the tab: Playwright's `recordVideo` shape with a
|
|
78
|
+
* required `dir` (`{ dir, size?, … }`), passed to the launcher unchanged. The
|
|
79
|
+
* launcher defaults a missing `size` to the viewport. Like the HAR, the file
|
|
80
|
+
* is complete once this transport's `close()` resolves; the launcher's
|
|
81
|
+
* `page.video()?.path()` names it.
|
|
82
|
+
*/
|
|
83
|
+
recordVideo?: NonNullable<BrowserContextOptions['recordVideo']> & {
|
|
84
|
+
dir: string;
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* `'block'` stops pages registering service workers. A service worker
|
|
88
|
+
* answers requests itself, so they reach neither `recordHar` nor a route
|
|
89
|
+
* installed by `initRouter`; block them when either must see every request.
|
|
90
|
+
* Unset: Playwright's default (`'allow'`).
|
|
91
|
+
*/
|
|
92
|
+
serviceWorkers?: NonNullable<BrowserContextOptions['serviceWorkers']>;
|
|
93
|
+
/**
|
|
94
|
+
* Called with the browser context after it is created and before its first
|
|
95
|
+
* page exists, so a `context.route('**\/*', …)` it installs intercepts the
|
|
96
|
+
* first navigation's own document request. If it throws, `ready()` fails
|
|
97
|
+
* and the browser is closed.
|
|
98
|
+
*/
|
|
99
|
+
initRouter?: (context: BrowserContext) => void | Promise<void>;
|
|
63
100
|
}
|
|
64
101
|
/** Context shape delivered to each headless/headed handler. */
|
|
65
102
|
export interface HeadlessContext {
|
|
@@ -94,6 +131,14 @@ export declare class HeadlessTransport extends BaseTransport {
|
|
|
94
131
|
headless?: boolean;
|
|
95
132
|
});
|
|
96
133
|
private parseOptions;
|
|
134
|
+
/**
|
|
135
|
+
* `recordHar`, `recordVideo`, `serviceWorkers` and `initRouter`. Unlike the display
|
|
136
|
+
* options above, a malformed value is REFUSED rather than dropped: dropping
|
|
137
|
+
* `recordHar` would leave a caller waiting for an archive that is never
|
|
138
|
+
* written, and dropping `initRouter` would let requests it meant to answer
|
|
139
|
+
* reach the network.
|
|
140
|
+
*/
|
|
141
|
+
private parseContextOptions;
|
|
97
142
|
protected onReady(): Promise<void>;
|
|
98
143
|
/**
|
|
99
144
|
* Read back the requested device scale factor and colour scheme from the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"headless.d.ts","sourceRoot":"","sources":["../../src/transports/headless.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"headless.d.ts","sourceRoot":"","sources":["../../src/transports/headless.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,qBAAqB,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AACvF,OAAO,E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rD;;;;;OAKG;IACH,SAAS,CAAC,SAAS,IAAI;QAAE,SAAS,CAAC,EAAE,MAAM,CAAC;QAAC,YAAY,CAAC,EAAE,MAAM,CAAA;KAAE;IAIpE;;;OAGG;IACH,SAAS,CAAC,WAAW,IAAI,MAAM,GAAG,SAAS;IAI3C;;;OAGG;cACa,WAAW,CAAC,KAAK,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;cAIvC,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC;cAOxB,YAAY,IAAI,OAAO,CAAC,eAAe,CAAC;CAgBzD"}
|
|
@@ -77,6 +77,14 @@ export interface InjectedContext extends HeadlessContext {
|
|
|
77
77
|
find(criteria?: Record<string, unknown>): Promise<unknown>;
|
|
78
78
|
/** Act on an element by registry id: `{ action: 'click' | 'type' | ... }`. */
|
|
79
79
|
act(id: string, request: Record<string, unknown>): Promise<unknown>;
|
|
80
|
+
/**
|
|
81
|
+
* Read one element by registry id: its identity, state, box and actions —
|
|
82
|
+
* the same object its entry in `snapshot()` is. An unknown id resolves to the
|
|
83
|
+
* returned `{ success: false, failureDetails: { errorCode: 'ELEMENT_NOT_FOUND' } }`
|
|
84
|
+
* envelope, never `null`. An in-page runtime whose dispatcher predates the
|
|
85
|
+
* `getElement` case rejects instead, with `Unknown command action: getElement`.
|
|
86
|
+
*/
|
|
87
|
+
element(id: string): Promise<unknown>;
|
|
80
88
|
/** Read the interactive-element control snapshot. */
|
|
81
89
|
snapshot(options?: Record<string, unknown>): Promise<unknown>;
|
|
82
90
|
/** Assert a user-visible outcome (NL `{assertion}` or `{target,type,expected}`). */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"injected.d.ts","sourceRoot":"","sources":["../../src/transports/injected.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAKH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,iBAAiB,EAAE,KAAK,eAAe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AM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAC9D,oFAAoF;IACpF,MAAM,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;CACzD;AAED,qBAAa,iBAAkB,SAAQ,iBAAiB;IACtD,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAuB;IAChD;;;;;;OAMG;IACH,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAyC;gBAEpD,MAAM,EAAE,eAAe,EAAE,QAAQ,CAAC,EAAE,eAAe;IA2B/D;;;;OAIG;IACH,OAAO,CAAC,cAAc;IA8BtB;;;;;OAKG;cACgB,SAAS,IAAI;QAAE,SAAS,CAAC,EAAE,MAAM,CAAC;QAAC,YAAY,CAAC,EAAE,MAAM,CAAA;KAAE;cAS1D,WAAW,IAAI,MAAM,GAAG,SAAS;cAI3B,gBAAgB,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;cAWrC,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;IA4H/D;;;;;;;OAOG;YACW,uBAAuB;cA6CZ,YAAY,IAAI,OAAO,CAAC,eAAe,CAAC;CAyFlE"}
|
package/dist/types.d.ts
CHANGED
|
@@ -35,7 +35,9 @@ export interface TransportConfig {
|
|
|
35
35
|
* uiBridgeBase?: string; forwardConsole?: boolean }` — a requested
|
|
36
36
|
* deviceScaleFactor / colorScheme is read back from the page after
|
|
37
37
|
* launch, and a page reporting anything else fails `ready()` with
|
|
38
|
-
* `EMULATION_NOT_APPLIED`
|
|
38
|
+
* `EMULATION_NOT_APPLIED`. Also `recordHar`, `recordVideo`, `serviceWorkers` and
|
|
39
|
+
* `initRouter`, passed to the launcher's browser context (a peer that
|
|
40
|
+
* ignores them fails `ready()` with `CONTEXT_OPTIONS_NOT_APPLIED`)
|
|
39
41
|
* - `live`: `{ handshakeTimeoutMs?: number; authToken?: string }`
|
|
40
42
|
*/
|
|
41
43
|
options?: Record<string, unknown>;
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE7E,uDAAuD;AACvD,MAAM,MAAM,oBAAoB,GAAG,KAAK,GAAG,UAAU,GAAG,QAAQ,GAAG,MAAM,GAAG,UAAU,CAAC;AAEvF,yFAAyF;AACzF,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,QAAQ,CAAC;AAE1F,mDAAmD;AACnD,MAAM,WAAW,eAAe;IAC9B,kCAAkC;IAClC,IAAI,EAAE,oBAAoB,CAAC;IAC3B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,kEAAkE;IAClE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,0EAA0E;IAC1E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE7E,uDAAuD;AACvD,MAAM,MAAM,oBAAoB,GAAG,KAAK,GAAG,UAAU,GAAG,QAAQ,GAAG,MAAM,GAAG,UAAU,CAAC;AAEvF,yFAAyF;AACzF,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,QAAQ,CAAC;AAE1F,mDAAmD;AACnD,MAAM,WAAW,eAAe;IAC9B,kCAAkC;IAClC,IAAI,EAAE,oBAAoB,CAAC;IAC3B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC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GAAG,MAAM,IAAI,CAAC;CAC3E;AAED;;;;GAIG;AACH,qBAAa,qBAAsB,SAAQ,KAAK;IAC9C,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAC5B,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IACzB;;;;;OAKG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC;gBAGzB,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,OAAO,GAAE;QAAE,SAAS,CAAC,EAAE,OAAO,CAAC;QAAC,KAAK,CAAC,EAAE,OAAO,CAAC;QAAC,OAAO,CAAC,EAAE,OAAO,CAAA;KAAO;CAa5E"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@qontinui/ui-bridge-wrapper",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.14.0",
|
|
4
4
|
"description": "Runtime for building UI Bridge wrapper apps — transport-agnostic semantic actions.",
|
|
5
5
|
"main": "./dist/index.cjs",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"scripts": {
|
|
31
31
|
"build": "tsup && tsc -p tsconfig.build.json",
|
|
32
32
|
"dev": "tsup --watch",
|
|
33
|
-
"typecheck": "tsc --noEmit",
|
|
33
|
+
"typecheck": "tsc --noEmit && tsc -p tsconfig.vitest.json",
|
|
34
34
|
"test": "vitest run",
|
|
35
35
|
"test:smoke": "vitest run smoke --reporter=default --reporter=json --outputFile.json=.smoke-report.json && node ../../test-support/assert-no-skipped-tests.mjs .smoke-report.json",
|
|
36
36
|
"clean": "rimraf dist",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"access": "public"
|
|
55
55
|
},
|
|
56
56
|
"peerDependencies": {
|
|
57
|
-
"@qontinui/ui-bridge": ">=0.
|
|
57
|
+
"@qontinui/ui-bridge": ">=0.47.0 <1",
|
|
58
58
|
"@qontinui/ui-bridge-headless": ">=0.6.0 <1",
|
|
59
59
|
"react": "^18.0.0 || ^19.0.0"
|
|
60
60
|
},
|
|
@@ -66,10 +66,8 @@
|
|
|
66
66
|
"optional": true
|
|
67
67
|
}
|
|
68
68
|
},
|
|
69
|
-
"dependencies": {
|
|
70
|
-
"@qontinui/ui-bridge-cli-args": ">=0.1.0 <1"
|
|
71
|
-
},
|
|
72
69
|
"devDependencies": {
|
|
70
|
+
"@qontinui/ui-bridge-cli-args": ">=0.3.0 <1",
|
|
73
71
|
"@types/node": "^20.10.0",
|
|
74
72
|
"@types/react": "^19.0.0",
|
|
75
73
|
"react": "^19.0.0",
|
package/dist/cli-args.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Shared CLI argument primitives for the wrapper bins (`ui-bridge-login-web`,
|
|
3
|
-
* `ui-bridge-capture-specs`, `ui-bridge-inject`).
|
|
4
|
-
*
|
|
5
|
-
* The primitives themselves now live in the zero-dependency leaf package
|
|
6
|
-
* `@qontinui/ui-bridge-cli-args`, so the sibling `@qontinui/ui-bridge-headless`
|
|
7
|
-
* bin (`ui-bridge-tab`) can import the same swallow guard without a dependency
|
|
8
|
-
* cycle (the wrapper AND the engine both depend *down* onto headless, so neither
|
|
9
|
-
* could host code headless imports). This file stays as a stable re-export so the
|
|
10
|
-
* three bins' `import … from './cli-args.js'` keep working — no bin churn.
|
|
11
|
-
*/
|
|
12
|
-
export * from '@qontinui/ui-bridge-cli-args';
|
|
13
|
-
//# sourceMappingURL=cli-args.d.ts.map
|
package/dist/cli-args.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cli-args.d.ts","sourceRoot":"","sources":["../src/cli-args.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,cAAc,8BAA8B,CAAC"}
|