DashMachine icon indicating copy to clipboard operation
DashMachine copied to clipboard

Ignore "open_in = iframe" for middle mouse button clicks and open in new tab without embedding

Open ThelloD opened this issue 4 years ago • 2 comments

Embedding apps in DashMachine is great, but sometimes I would like to be able to quickly open certain apps (well, URLs) in a new tab without the application being embedded in DashMachine in an iframe. This is e.g. especially useful if some special functions of the embedded web application behave buggy if they are embedded.

One possible solution might be be to have the href= attribute always pointing to the real URL and handling left button clicks using JavaScript onClick events, which then redirects the user to the URL with the iframe (=the URL currently in the href tag). Since the onclick event is ignored for middle mouse button clicks, such clicks would then open the application in a new tab which points directly to the web application URL.

ThelloD avatar May 28 '20 22:05 ThelloD

I agree, I mostly don't use the iframe option because of this lol. This could be solved by the upcoming feature I'm planning: ability to add custom buttons on apps. That way you could make 'open in new tab' button on iframe apps that need it.

rmountjoy92 avatar May 30 '20 13:05 rmountjoy92

I agree, I mostly don't use the iframe option because of this lol. This could be solved by the upcoming feature I'm planning: ability to add custom buttons on apps. That way you could make 'open in new tab' button on iframe apps that need it.

This could be an option, but I believe, having only the app icon to click on would be simpler:

  • left click: open in iframe
  • middle click: open in new tab (usual behavior on the web)

Coming From Organizr where I had all my apps in iframe mode (I would often middle click to open them in new tabs), I found myself having to set all apps to "new_tab" instead of iframe, because even if you usually use apps in iframe, the day you want to open you app in a new tab, you are kind of stuck ...

saponace avatar Jun 03 '20 22:06 saponace