-
Notifications
You must be signed in to change notification settings - Fork 243
Add Back to Opener Explainer #1057
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
Add Back to Opener Explainer #1057
Conversation
@aluhrs13 and @erik-anderson could you help take a look at the explainer? |
BackToOpener/explainer.md
Outdated
|
||
Developers can signal their intent via `window.open()` and `<a>` elements. The browser will then handle the navigation logic, ensuring that when the user navigates back in the new tab, it automatically returns focus to the originating tab and closes the new tab if the opener is still active. | ||
|
||
- For `window.open()`, we propose introducing a new `windowFeatures` parameter called `addOpenerToHistory`. When this feature is specified, the browser will add the opener to the new tab's history. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should think more about the name here-- e.g. should it actually be a history entry or not?
Is there some other name that conveys more about the behavior? I can't immediately think of a better name, however.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 on the naming comment. I don't necessarily think we need to bikeshed/block on that though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I chose addOpenerToHistory to describe the implementation. But I am open to something along the lines of "linkedHistory"
Thank you all for the help reviewing - I have addressed most of the comments and would appreciate a second look. Thank you! |
|
2fb51fe
to
31275f9
Compare
This PR introduces an explainer for Back to the Opener, a proposed feature to improve navigation when links open in new tabs.
It allows developers to opt-in (via
window.open()
or<a>
tag attributes) to have the opener tab added to the new tab's history. This enables a seamless "back" navigation to the opener, closing the new tab and reducing tab clutter, especially useful for search and chat interfaces.