macaroni

prompt

Description:
The prompt executor is used to display a prompt to the user with a text input type experience. In addition to the prompt and the text input experience, there will be two buttons, OK and Cancel.

Parent: execute, then, else

Value (simple form): string specifying the text message prompt to display
Value (key/value form):

# simple form
- prompt: (string)

# simple example
- prompt: How many do you want?

# key/value form
- prompt: (string, required)
  title: (string, optional)
  image: (string, optional)
  timeout: (time, optional)
  text: (string, optional)
  selected: (boolean, optional)

# key/value example
- prompt: How many do you want?
  timeout: 5s
  default: `1`

EXAMPLE:

- triggers:
  - '[create] [a] new macro'
  execute:
  - prompt: Enter your macro as YAML
    text: |
      commands:
      - triggers:
        - 'phrase one'
        - 'phrase two'
        execute:
        - run: "notepad" # thing to run
        - wait: 500 # time to wait in ms
        - insert: "hello" # text to insert
        - sendKeys: "{ctrl-a}" # keys to send
  - clipboard: '{prompt.text}'
  - prompt: Enter a new filename
  - file:
      name: '{folders.MyDocuments}\macros\{prompt.text}.mac'
      write: '{clipboard.text}'
  - clipboard: '{folders.MyDocuments}\macros\{prompt.text}.mac'
  - run: '{folders.MyDocuments}\macros\{prompt.text}.mac'

Status: ☑️ Partially IMPLEMENTED (needs “image”, “timeout”, “selected”, “default” support)

Additional information: