Ask in the page
Shows a form over the page, waits for Submit, and returns the values.
Ask in the page
Details #
Like the prompt step, but inside the page and next to what you're looking at. fields is a list: a name, or {name, label, type, options, default, required, placeholder} with type text, textarea, number, checkbox, select or password. Or give html with your own inputs; the values come from the form.
The values come back as a dictionary, and go into into. Cancel (or Esc) fails the step with "cancelled", which an if can catch with onFailure.
Parameters #
| Parameter | Type | Required | Values | What it does |
|---|---|---|---|---|
browser | one of | safari chrome front | ||
fields | list of any value | The questions. Or html. | ||
html | text | |||
into | text | The variable that receives the dictionary. | ||
sample | any value | |||
tab | any value | |||
timeout | number | Seconds to wait. | ||
title | text | A heading. |
Every step also accepts label, onFailure, timeout and dryRunSafe.
Examples #
Ask for a note and show it
Do
- Ask in the page: “Note”
- Show “{{answers.note}}” for 2 s
Gotchas #
The form waits for a person, so the macro's own timeout is the limit.