64 lines
1.7 KiB
YAML
64 lines
1.7 KiB
YAML
# add-bound.yaml: fill one bound row on the Add Region form.
|
|
# Args: BOUND_INDEX, BOUND_NAME, BOUND_DESCRIPTION, BOUND_GEOJSON.
|
|
# Assumes the caller is already on /regions/new. Adds the row (via the
|
|
# Add Bound button) when it does not exist yet, then scrolls to and fills it
|
|
# by id. Bound rows can sit below the fold, so every target is scrolled to
|
|
# before interacting.
|
|
url: http://localhost:4175/regions/new
|
|
env:
|
|
BOUND_INDEX: ${BOUND_INDEX || "0"}
|
|
BOUND_NAME: ${BOUND_NAME || ""}
|
|
BOUND_DESCRIPTION: ${BOUND_DESCRIPTION || ""}
|
|
BOUND_GEOJSON: ${BOUND_GEOJSON || ""}
|
|
---
|
|
- runFlow:
|
|
when:
|
|
notVisible:
|
|
id: bound-${BOUND_INDEX}-name
|
|
commands:
|
|
- scrollUntilVisible:
|
|
element:
|
|
id: add-bound-button
|
|
direction: UP
|
|
timeout: 10000
|
|
speed: 50
|
|
visibilityPercentage: 60
|
|
centerElement: true
|
|
- tapOn:
|
|
id: add-bound-button
|
|
|
|
- scrollUntilVisible:
|
|
element:
|
|
id: bound-${BOUND_INDEX}-name
|
|
direction: DOWN
|
|
timeout: 10000
|
|
speed: 50
|
|
visibilityPercentage: 60
|
|
centerElement: true
|
|
- tapOn:
|
|
id: bound-${BOUND_INDEX}-name
|
|
- inputText: ${BOUND_NAME}
|
|
|
|
- scrollUntilVisible:
|
|
element:
|
|
id: bound-${BOUND_INDEX}-description
|
|
direction: DOWN
|
|
timeout: 10000
|
|
speed: 50
|
|
visibilityPercentage: 60
|
|
centerElement: true
|
|
- tapOn:
|
|
id: bound-${BOUND_INDEX}-description
|
|
- inputText: ${BOUND_DESCRIPTION}
|
|
|
|
- scrollUntilVisible:
|
|
element:
|
|
id: bound-${BOUND_INDEX}-geojson
|
|
direction: DOWN
|
|
timeout: 10000
|
|
speed: 50
|
|
visibilityPercentage: 60
|
|
centerElement: true
|
|
- tapOn:
|
|
id: bound-${BOUND_INDEX}-geojson
|
|
- inputText: ${BOUND_GEOJSON}
|