Possibility to right click on menu bar items and open in new tab - Mendix Forum

Possibility to right click on menu bar items and open in new tab

1

When user right click on menu bar items in the navigation and open in new tab (default chrome option) , it is opening the home page in new tab irrespective of selected items. This happens for every menu bar item. Page URL is useful when user bookmarks the page .

 

we couldn't find solution to achieve this. This would be a value addition as this is common usecase.

asked
2 answers

Here's a workaround that works well:


# Setting up the Page URL

  1. Open your overview page
  2. Go to Properties > General section
  3. Set the URL field (e.g. 'my-overview')


Your page will be accessibale at:

'https://yourappdomain.mx.lowcode.cloud/p/my-overview'


You can bookmark this URL directly ;)


# Opening pages in new tabs (from your app)

Create a Javascript Action

  1. Add a string parameter named _url
  2. In the Code tab, add this to the User Code section:
window.open(_url, '_blank').focus();


Create a Nanoflow

  1. Use GetRemoteURL from NanoflowCommons module
  2. Use a Change Variable action to build the full URL
    $RemoveURL+'/p/' + 'my-overview'
  3. Call your JavaScript action with this URL
  4. Assing the nanoflow to a button


Nanoflow example

Created

Would love to see this. Doing it a lot myself and having to "double" click the menu is anoying.

Created