Expand description
WebDriver BiDi (Firefox) counterpart of crate::session::input.
Element refs on BiDi are integer ids in a page-side registry written by
the snapshot walker (crate::dom::scripts::SNAPSHOT_TREE_JS). Geometry
is computed in the page (REF_CENTER_JS, REF_CLIP_RECT_JS) and input
is dispatched with input.performActions at viewport-origin CSS pixel
coordinates, so no locateNodes / sharedId bookkeeping is needed.
Typing goes through in-page execCommand('insertText') (with a
value-setter fallback) because BiDi has no insertText; per-character
key actions cover press_sequentially, and Enter is a key action.
Every helper returns SessionError::NodeGone when the registry no longer
resolves the id, which the tool layer maps to StaleRef.
Functions§
- accessibility_
tree - Run the walker and parse its JSON.
- click
- Left-click the node’s centre.
- document_
size - Document scroll size, for full-page screenshots.
- document_
token - Per-document token (see
DOC_TOKEN_JS). - drag
- Pointer drag from one node’s centre to another’s.
- hover
- Move the pointer over the node’s centre.
- node_
center - Scroll the node into view and return its clickable centre.
- node_
clip_ rect - Border box of the node in document coordinates.
- type_
text - Focus the node, replace its content with
text, optionally one key at a time, and optionally press Enter.