Open new tab with BPMN XML file in Plugin

As a developer, I am developing a plugin for Camunda Modeler App, where the user will have access to the files in the plugin, and can open the files directly in the Camunda Modeler just by clicking on it. How to access new Tab in the plugin and render the BPMN or DMN files in the new tab?
I am using client extension, just like the AutoSave plugin already available in the Github, but I use the react component for file explorer.

Could you share a repo of your plugin? Please explain the use case.

I am replicating the Autosave Plugin, as described here,
Use Case: Instead of Auto saving the files. The user will open the list of files from a certain BPMN project in this plugin, and its BPMN XML files will be listed there in overlay of the plugin.
Now the files are already accessible using ‘window.showDirectoryPicker()’ but if the user clicks on any BPMN XML files inside the plugin where it is listed . It should be opened in a new tab of Camunda Modeler. And the diagram of the respective BPMN file should be displayed in a new tab.
I tried triggerAction already mentioned in Autosave plugin but it has no such feature of opening xml files directly instead it has feature of open diagram, save xml, or create bpmn diagram.

I see, so essentially you want to trigger the application to open a selected file path. Having looked into the existing APIs, I don’t think there’s a way to do this in a plugin at the moment. Please feel free to open a feature request in the repository: Sign in to GitHub · GitHub