/** * Capture a PNG screenshot of an Electron app via Playwright over CDP. * * Targeting precedence (matches `electron_*` tools that share `targetId` / * `windowTitle` — see `src/commands/shared/window-target.ts`): * 1. `targetId` — exact CDP target match across every running app. * 2. `windowTitle` — first app with a target whose title matches (case- * insensitive substring). * 3. neither — first app returned by `scanForElectronApps`. * * Without `targetId`, parallel Electron apps (skills-desktop on :9222 and * qa-fixture on :9223, for example) can collide on `apps[0]` and silently * return the wrong app's screenshot — that's the bug fixed in #18. * * @param options.outputPath Optional path to save the PNG (and an * `.encrypted` companion). When omitted, returns base64 only. * @param options.windowTitle Case-insensitive substring matched against page * titles. Used both to pick the app and to pick the right page within it. * @param options.targetId Exact CDP target ID. Wins over `windowTitle`. */ export declare function takeScreenshot(options: { outputPath?: string; windowTitle?: string; targetId?: string; }): Promise<{ filePath?: string; base64: string; data: string; error?: string; }>;