I've run into an issue using the "For a selected item" SharePoint trigger action. My trigger is setup with a file user input where the user is prompted to include a file when triggering the Flow from a SharePoint list. I then need to attach this file to a "Start and wait for an approval" action. When I setup the attachment for the approval action, I provide the attachment name and content using dynamic values from the "For a selected item" trigger. Initially, the syntax is triggerBody()['file']['name'], however, after I save and when the flow runs it changes to triggerBody()['entity']['file']['name']; it is changing and adding ['entity'] which is causing it to fail.
When I look at the raw outputs from the "For a selected item" trigger, the value I need ,"name", is under file, not entity. I'm not sure why when it runs it changes to include ['entity']. I have tried selecting the value as dynamic content and manually typed the correct syntax in the function box, but no matter what I try it changes to include ['entity'] beyond my control.
Is there a way to hard code and retain syntax? Am I missing something?