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

Specify parsing of 'noopener' feature in window.open #4079

Merged
merged 2 commits into from
Oct 11, 2018

Conversation

cdumez
Copy link

@cdumez cdumez commented Oct 10, 2018

Specify parsing of 'noopener' feature in window.open so that noopener is only set to true
if the value is either:

  • The empty string.
  • The string "yes".
  • The value is not 0 or an error when parsed as an integer.

Fixes #2600.


/window-object.html ( diff )

source Show resolved Hide resolved
source Show resolved Hide resolved
source Show resolved Hide resolved
source Show resolved Hide resolved
source Show resolved Hide resolved
@zcorpan zcorpan added the needs tests Moving the issue forward requires someone to write tests label Oct 10, 2018
string <var>value</var>:</p>
<ol>
<li><p>If <var>value</var> is the empty string, return true.</p></li>
<li><p>If <var>value</var> is a case-sensitive match for <code data-x="">yes</code>, return true.</p></li>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be ASCII case-insensitive?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

case-sensitive is sufficient because the input is always lowercase, as per the output of:
https://html.spec.whatwg.org/#concept-window-open-features-tokenize

Specify parsing of 'noopener' feature in window.open so that noopener is only set to true
if the value is either:
- The empty string.
- The string "yes".
- The value is not 0 or an error when parsed as an integer.

Fixes whatwg#2600.
@cdumez
Copy link
Author

cdumez commented Oct 10, 2018

I integrated the comments.

@cdumez
Copy link
Author

cdumez commented Oct 10, 2018

Updated tests: web-platform-tests/wpt#13458

kisg pushed a commit to paul99/webkit-mips that referenced this pull request Oct 10, 2018
Working on getting the HTML spec updated instead
(whatwg/html#4079)

Reverted changeset:

"Passing noopener=NOOPENER to window.open() should cause the
new window to not have an opener"
https://bugs.webkit.org/show_bug.cgi?id=190251
https://trac.webkit.org/changeset/236802

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@237002 268f45cc-cd09-0410-ab3c-d52691b4dbfc
@zcorpan zcorpan removed the needs tests Moving the issue forward requires someone to write tests label Oct 10, 2018
@domenic
Copy link
Member

domenic commented Oct 10, 2018

@cdumez, do you still work for Apple? If so, instead of signing up to participate as an individual, you'll want to join the https://github.com/apple-whatwg organization, and/or make your membership there public.

@cdumez
Copy link
Author

cdumez commented Oct 10, 2018

@domenic Yes, I still work for Apple. I have just made my membership at apple-whatwg public. All good?

cdumez added a commit to cdumez/web-platform-tests that referenced this pull request Oct 10, 2018
Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.
@domenic
Copy link
Member

domenic commented Oct 10, 2018

Yep, all good! Will let @zcorpan do the honors.

@zcorpan zcorpan merged commit 3bf4cec into whatwg:master Oct 11, 2018
zcorpan pushed a commit to web-platform-tests/wpt that referenced this pull request Oct 11, 2018
Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.
@zcorpan
Copy link
Member

zcorpan commented Oct 11, 2018

Thanks @cdumez!

moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Oct 14, 2018
…ndow.open, a=testonly

Automatic update from web-platform-testsUpdate test for 'noopener' feature of window.open

Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.

--

wpt-commits: 56e5e93ef1ce1097a1b8749423b52e1fa180f6aa
wpt-pr: 13458
xeonchen pushed a commit to xeonchen/gecko-cinnabar that referenced this pull request Oct 15, 2018
…ndow.open, a=testonly

Automatic update from web-platform-testsUpdate test for 'noopener' feature of window.open

Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.

--

wpt-commits: 56e5e93ef1ce1097a1b8749423b52e1fa180f6aa
wpt-pr: 13458
annevk added a commit to web-platform-tests/wpt that referenced this pull request Feb 11, 2019
annevk added a commit to web-platform-tests/wpt that referenced this pull request Feb 11, 2019
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Feb 21, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328
mykmelez pushed a commit to mykmelez/gecko that referenced this pull request Feb 22, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Feb 26, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328
mykmelez pushed a commit to mykmelez/gecko that referenced this pull request Feb 27, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 3, 2019
…ndow.open, a=testonly

Automatic update from web-platform-testsUpdate test for 'noopener' feature of window.open

Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.

--

wpt-commits: 56e5e93ef1ce1097a1b8749423b52e1fa180f6aa
wpt-pr: 13458

UltraBlame original commit: 6889ec30451700089a5ace06d3cd469a42e0b042
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 3, 2019
…ndow.open, a=testonly

Automatic update from web-platform-testsUpdate test for 'noopener' feature of window.open

Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.

--

wpt-commits: 56e5e93ef1ce1097a1b8749423b52e1fa180f6aa
wpt-pr: 13458

UltraBlame original commit: 6889ec30451700089a5ace06d3cd469a42e0b042
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 3, 2019
…ndow.open, a=testonly

Automatic update from web-platform-testsUpdate test for 'noopener' feature of window.open

Update test for 'noopener' feature of window.open to reflect the changes made in
whatwg/html#4079.

--

wpt-commits: 56e5e93ef1ce1097a1b8749423b52e1fa180f6aa
wpt-pr: 13458

UltraBlame original commit: 6889ec30451700089a5ace06d3cd469a42e0b042
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 3, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328

UltraBlame original commit: 3624a9aa806e8ea05d0401acedba7ac98b240a97
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328

UltraBlame original commit: 3624a9aa806e8ea05d0401acedba7ac98b240a97
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328

UltraBlame original commit: 957e02354f5eb4a8873a8ebb6fe3d2023ec1f025
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328

UltraBlame original commit: 3624a9aa806e8ea05d0401acedba7ac98b240a97
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328

UltraBlame original commit: 957e02354f5eb4a8873a8ebb6fe3d2023ec1f025
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 4, 2019
…estonly

Automatic update from web-platform-tests
HTML: noopener keyword is tokenized

See whatwg/html#4079.

--

wpt-commits: 6d9e199e99ce76bafb4d31a58641e5a2591c9587
wpt-pr: 15328

UltraBlame original commit: 957e02354f5eb4a8873a8ebb6fe3d2023ec1f025
ryanhaddad pushed a commit to WebKit/WebKit that referenced this pull request Dec 22, 2020
Working on getting the HTML spec updated instead
(whatwg/html#4079)

Reverted changeset:

"Passing noopener=NOOPENER to window.open() should cause the
new window to not have an opener"
https://bugs.webkit.org/show_bug.cgi?id=190251
https://trac.webkit.org/changeset/236802

Canonical link: https://commits.webkit.org/205383@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@237002 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants