previewapk_wait_for
Wait for a UI element to appear or disappear, or for a human to hand control back after a takeover, instead of sleeping blind. Returns found status and wait time.
Instructions
Wait until an element is present on screen (or gone, with present=false), polling the UI. Returns {found, waited_ms} — found=false at the timeout is a result, not an error. Use after actions that load content instead of sleeping blind. With condition='driver' instead of an element: wait until the human hands the wheel back to you (after previewapk_request_human or any takeover) — the result carries the handback note (handback_note, resumed) when there is one. Driver waits default to timeout_s=300 (max 600): a human step takes human time.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | ||
| desc | No | ||
| text | No | ||
| device | No | ||
| present | No | ||
| condition | No | 'driver' waits for the handback instead of an element | element |
| timeout_s | No |