Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Middle mouse button click does not open link in new tab when using Safari #1772

Open
raphaelbeckmann opened this issue Jan 19, 2024 · 1 comment
Labels
react Related to the react adapter

Comments

@raphaelbeckmann
Copy link

Version:

  • @inertiajs/react version: 1.0.14

Describe the problem:

Clicking an InertiaLink with the middle mouse button opens the page in the same tab.
I would expect it to behave like a normal a link, which opens the page in a new tab when using the middle mouse button.

Steps to reproduce:

Open https://inertiajs.com in Safari and click on a link using the middle mouse button. Result: It opens in the current tab, not a new tab.
Open https://inertiajs.com in Chrome and click on a link using the middle mouse button. Result: It opens in a new tab.

@raphaelbeckmann raphaelbeckmann added the react Related to the react adapter label Jan 19, 2024
@shengslogar
Copy link

Interestingly, this seems to be isolated to the React wrapper (which, as you referenced, inertiajs.com is built on) and doesn't affect Vue. The Ping CRM demo app uses the Vue adapter and works as expected in Safari.

Comparing the Vue and React link components doesn't yield anything obvious. Wondering if it has something to do with some underlying React thing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
react Related to the react adapter
Projects
None yet
Development

No branches or pull requests

2 participants