Block reference / Web interaction

Hover element

Move the pointer over an element, to open a menu or show a tooltip.

Only inWarpX Browser

Hover element rests the pointer on an element without clicking it. Use it for menus that open on hover, tooltips, or product images that change when the pointer is over them. By default the pointer travels there along a human-like path.

The Hover element block's settings, filled in as in the example below.

Settings

Element Selector

The element to act on, as a CSS selector or an XPath; anything starting with /, (, @ or id( is read as XPath, and it can hold a reference such as {{variables.selector}}. The crosshair button (Select an element) lets you pick the element in the profile's browser, including inside iframes and shadow roots, and the check button (Verify selector) tests what you typed.

Examplenav .menu-item--account
Multiple

Hovers over every matching element, one after another in page order, instead of only the first. The pointer ends on the last one.

ExampleUnchecked
Mark elementwhen the selector is CSS

Skips elements this block has already handled, and tags the one it handles once the action is done, so inside a loop each pass takes the next untouched match. With Multiple, every match is tagged after all of them are handled. The tag is the attribute block-- plus the block's id, so it is gone once the page reloads or changes; only offered for CSS selectors.

ExampleUnchecked
Wait for selector

Waits, up to Selector timeout (ms), for the element to be rendered and visible before acting on it. Use it for elements that appear after a click or a network request.

ExampleChecked
Selector timeout (ms)when Wait for selector is on

How long Wait for selector keeps looking, in milliseconds. The default is 5000.

Example5000
Human Emulation

On (the default), moves the pointer to the element along a human-like path, scrolling with the mouse wheel if needed. Off, the pointer jumps straight onto it.

ExampleChecked
Delay time (ms)

A pause after the block finishes, before the next block starts. Write one number such as 1000, or a range such as 1000,3000 to pick a random pause in that range on each run.

Example800

Every block also has the shared block settings — a description, Disable block and what to do on an error, and Finding elements explains selectors in more depth. Fields that take text accept data from earlier blocks.

What it hands on

Nothing is written to the table or to variables. The block leaves by its single output with the pointer resting on the element; if no element matches, it fails.

Example: Open the account menu and go to the orders page

  1. Start
  2. New tab
  3. Hover element
  4. Click element
Where Hover element sits in the example workflow.
  1. Add a New tab block that opens https://shop.example.com.
  2. Add a Hover element block with Element Selector nav .menu-item--account and tick Wait for selector.
  3. Set Delay time (ms) to 800 so the menu has time to open.
  4. Add a Click element block with Element Selector //a[contains(., "Orders")] and tick Wait for selector.

Good to know

  • If no element matches, the block fails with an error that names the selector, and the workflow stops. Set On error in the block's settings to Continue flow or Execute fallback to carry on.
  • With Human Emulation on, the block fails if another element covers the target when the pointer arrives, and names what is in the way.
  • The hover lasts until the pointer moves again. The next block that uses the pointer, such as a click elsewhere, may close the menu.

See also

  • Click element — Click an element on the page, with human-like mouse movement by default.
  • Scroll element — Scroll the page or a scrollable area to an element or to a position.
  • Element exists — Check whether an element is on the page and continue by one of two outputs.