import { Protocol } from 'devtools-protocol'; import type { Browser as PuppeteerBrowser, CDPSession as PuppeteerCDPSession, Page as PuppeteerPage } from 'puppeteer-core'; import { PuppeteerCaptureBase } from './PuppeteerCaptureBase'; import { PuppeteerCaptureOptions } from './PuppeteerCaptureOptions'; export declare class PuppeteerCaptureViaHeadlessExperimental extends PuppeteerCaptureBase { static readonly REQUIRED_ARGS: string[]; protected static readonly INJECTED = "__PuppeteerCaptureViaHeadlessExperimental"; protected static readonly EJECTOR: string; protected readonly _injected: string; protected readonly _injector: string; protected readonly _ejector: string; protected readonly _requestFrameCapture: () => void; protected readonly _onSessionDisconnected: () => void; protected _session: PuppeteerCDPSession | null; protected _onNewDocumentScript: Protocol.Page.ScriptIdentifier | null; protected _frameTimeTicks: number; constructor(options?: PuppeteerCaptureOptions); /** * Returns the page's internal CDP client. This accesses Puppeteer's private * `_client()` method because `Page.addScriptToEvaluateOnNewDocument` and * `Page.removeScriptToEvaluateOnNewDocument` must be sent on the page's own * CDP session — a session created via `page.createCDPSession()` operates on * a separate target and cannot manage page-level lifecycle scripts. * * This private API has broken before (see Issue #7, where `page.client()` * was renamed to `page._client()`). The integration test matrix covering * multiple Puppeteer versions helps detect such changes early. */ protected getPageClient(page: PuppeteerPage): PuppeteerCDPSession; protected _attach(page: PuppeteerPage): Promise; protected _detach(page: PuppeteerPage): Promise; protected requestFrameCapture(): void; protected doRequestFrameCapture(page: PuppeteerPage, session: PuppeteerCDPSession): void; protected onPostCaptureStarted(): Promise; protected onPostCaptureStopped(): Promise; protected onSessionDisconnected(): void; protected static validateBrowserArgs(browser: PuppeteerBrowser): void; protected static generateInjector(fps: number): string; }