type Browser = import('playwright').Browser; type BrowserContext = import('playwright').BrowserContext; type Page = import('playwright').Page; /** * Get a Playwright browser instance * Tries to connect to existing CDP first, then falls back to launching a new instance */ export declare function getBrowser(url?: string, options?: { verbose?: boolean; }): Promise<{ browser: Browser; page: Page; isNew: boolean; }>; /** Temporarily hide DevBar chrome on a Playwright page. */ export declare function hideDevbarOnPage(page: Page): Promise<() => Promise>; /** Run an arbitrary Playwright capture while DevBar chrome is hidden. */ export declare function withHiddenDevbarForScreenshot(page: Page, capture: () => Promise): Promise; /** * Patch a Playwright page so every `page.screenshot()` call temporarily hides * DevBar chrome. This cannot intercept OS/browser screenshots, but it covers * the common Playwright test path without changing each call site. * * @returns Cleanup function that restores the original screenshot method. */ export declare function installAutoHideDevbarScreenshots(page: Page): () => void; /** * Patch all existing pages in a BrowserContext and any future pages emitted by * the context. Useful as a Playwright fixture installed once per test. */ export declare function installAutoHideDevbarScreenshotsForContext(context: BrowserContext): () => void; /** * Take a screenshot using Playwright. * * Wrapped with a hard timeout (OPERATION_TIMEOUT_MS) to prevent orphaned * processes when the dev server dies mid-operation. */ export declare function screenshotViaPlaywright(options: { selector?: string; output?: string; fullPage?: boolean; viewport?: import('./viewportUtils.js').ViewportName | string; hover?: boolean; hideDevbar?: boolean; a11y?: boolean; url?: string; /** Enable progress logging (default: false) */ verbose?: boolean; /** Override the operation timeout in ms (default: OPERATION_TIMEOUT_MS) */ timeout?: number; }): Promise<{ buffer: Buffer; width: number; height: number; }>; export {}; //# sourceMappingURL=playwright.d.ts.map