Apple AI deletes selected text in user input window

To reproduce:

  1. Use the “Prompt for user input” action
  2. In the variables and default values section, add an entry with an arbitrary name and some longish text value (in my case it's the title of the current webpage, %FrontBrowserTitle%)
  3. Invoke this macro
  4. Wait for the Apple AI writing tools popup thing to appear over the text (which is selected by default)
  5. Press enter

Bug: For some reason just before the form is submitted, the text is cleared instead of being submitted as is. This only happens when the Apple AI writing tools popup has appeared; if you press enter before it shows up, all works fine.