[IGN-8841] Perspective | Hyperlink | CTRL + Clic

I'm on 8.1.33

There is a way that hyperlink ctrl+clic open the link into a new tab without using scripting event?

Can use a navigation event to go to any URL, there will be an option to open as a new tab.
Though I'm not sure how you'd check if the ctrl key is being pressed, if it was possible.

If you mean in a Perspective session in a browser, then most browsers offer Right-Click | Open in new tab ...

Right-Click work well, but I don't want to pass by it, I want to use directly CTRL-Click but don't want to have to create a scripting event on it.

The answer to the OP question is to use the Link component?

If you make it a link, it will be emitted to the DOM as a regular-ol-<a> element. Then it's up to the user agent (the browser) to interpret a click/ctrl click/long press/etc as whatever link clicking action to either open in the user's current tab or a new tab, per what the user has defined.

If you want control, you have to use scripting. If you want standard behavior for users, you have to use the Link component.

1 Like

I tried Link component with Chrome, Firefox, Edge and only the Right+Click works, CTRL+Click doesn't open link in new tab like any other website

Just to make sure we are clear (Luc's colleague here), we did try to use a link. When we do, if we right-click the link (Chrome), we have "open in a new tab" in the menu and it works. If we CTRL-click the link, it does not open in a new tab like the same browser does usually. It seems there is something that disrupts the browser from seeing this as a normal link, but somehow only when CTRL-clicking.

This does appear to be a bug, though it's unclear if we're preventing the requested/desired behavior, or if its a consequence of our key-handling during click events. I've opened an internal ticket to investigate and see about a potential fix.