From 95aa23647efb759a9b37a808d2c2e794671808ce Mon Sep 17 00:00:00 2001 From: unohee Date: Fri, 23 Oct 2026 14:36:27 +0900 Subject: [PATCH] feat(native): the tree view and aria-refs, into cross-site iframes too (phase 4) read_page(mode="tree") now runs on the native driver, and click / type_text / any element tool take its aria-refs. - snapshot: Accessibility.getFullAXTree frame by frame, written as Playwright's aria_snapshot(mode="ai", boxes=True) so compact_snapshot reads it unchanged. Chrome's internal roles are mapped back (MenuListOption is an option, StaticText a text), a link's /url is its href as written (Chrome's tree has the resolved URL), boxes are in the element's own frame's viewport as Playwright gives them, and refs go to every rendered node with a box: e in the top frame, fe in the k-th frame met. A snapshot replaces the page's ref table, so refs belong to the latest read. - frames: out-of-process iframes are auto-attached (no waitForDebuggerOnStart, as for tabs: cdp_guard holds them) and every frame maps to the session that speaks for its document; nested OOPIFs included. Coordinates from an OOPIF session get the owner