Click a widget
clickActivates the center of the single widget matching a selector and returns the redrawn tree. Ensure states make repeatable checkbox or selection actions safe.
Instructions
Clicks the centre of the one widget the selector matches, then returns the tree after the application redraws. Refused if the selector matches more than one widget. Clicking toggles a checkbox; to make a step safe to repeat, pass ensure: checked, unchecked or selected, and the widget is clicked only if it is not already in that state.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | The widget's ID, exactly as shown after # in the tree. | |
| nth | No | Which match to use when several qualify, 0-based; negative counts from the end. | |
| role | No | The semantic role. | |
| label | No | The label, matched exactly. | |
| value | No | The current value, matched exactly — for example the selected item of a list. | |
| ensure | No | Click only if the widget is not already in this state, then confirm it reached it. Makes the call idempotent. | |
| label_contains | No | A substring of the label, for labels that carry live data. |