> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt.

# subflows/leave-to-song-list.yaml

[Source](https://github.com/leapgame/leap-sim-piano/blob/f794b594016038c483e2d20b6af56aea0ae1b982/.maestro/subflows/leave-to-song-list.yaml)

```yaml
appId: ${APP_ID}
---
# From wherever the app went (a song's gameplay, its result, an offer over the list) back to the song
# list: pause and leave a running song, leave a result, close what opens on its own (dismiss-offers.yaml).
- repeat:
    times: 20
    while:
      notVisible:
        id: "songs-search-input"
    commands:
      - runFlow:
          when:
            visible:
              id: "gameplay-header-pause"
          commands:
            - tapOn:
                id: "gameplay-header-pause"
      - runFlow:
          when:
            visible:
              id: "session-action-songs"
          commands:
            - tapOn:
                id: "session-action-songs"
      - runFlow: dismiss-offers.yaml
      - runFlow:
          file: sleep.yaml
          env:
            MS: "3000"
- runFlow: to-song-list.yaml
```
