Skip to content

Commit 24f44e8

Browse files
authored
Correct branching logic in choosing a browsing context
Issue for tests: web-platform-tests/wpt#14256.
1 parent aecd40e commit 24f44e8

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

source

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -77669,23 +77669,23 @@ console.assert(iframeWindow.frameElement === null);
7766977669
<li><p>If <var>name</var> is the empty string or an <span>ASCII case-insensitive</span> match for
7767077670
"<code data-x="">_self</code>", then set <var>chosen</var> to <var>current</var>.</p></li>
7767177671

77672-
<li><p>If <var>name</var> is an <span>ASCII case-insensitive</span> match for "<code
77673-
data-x="">_parent</code>", then set <var>chosen</var> to <var>current</var>'s <span>parent
77674-
browsing context</span>, if any, and <var>current</var> otherwise.</p></li>
77672+
<li><p>Otherwise, if <var>name</var> is an <span>ASCII case-insensitive</span> match for "<code
77673+
data-x="">_parent</code>", set <var>chosen</var> to <var>current</var>'s <span>parent browsing
77674+
context</span>, if any, and <var>current</var> otherwise.</p></li>
7767577675

77676-
<li><p>If <var>name</var> is an <span>ASCII case-insensitive</span> match for "<code
77677-
data-x="">_top</code>", then set <var>chosen</var> to <var>current</var>'s <span>top-level
77678-
browsing context</span>, if any, and <var>current</var> otherwise.</p></li>
77676+
<li><p>Otherwise, if <var>name</var> is an <span>ASCII case-insensitive</span> match for "<code
77677+
data-x="">_top</code>", set <var>chosen</var> to <var>current</var>'s <span>top-level browsing
77678+
context</span>, if any, and <var>current</var> otherwise.</p></li>
7767977679

7768077680
<li>
77681-
<p>If <var>name</var> is not an <span>ASCII case-insensitive</span> match for "<code
77682-
data-x="">_blank</code>" and there exists a browsing context whose <span data-x="browsing
77683-
context name">name</span> is the same as <var>name</var>, and <var>current</var> is
77684-
<span>familiar with</span> that browsing context, and the user agent determines that the two
77685-
browsing contexts are related enough that it is ok if they reach each other, then set
77686-
<var>chosen</var> to that browsing context. If there are multiple matching browsing contexts,
77687-
the user agent should set <var>chosen</var> to one in some arbitrary consistent manner, such as
77688-
the most recently opened, most recently focused, or more closely related.</p>
77681+
<p>Otherwise, if <var>name</var> is not an <span>ASCII case-insensitive</span> match for "<code
77682+
data-x="">_blank</code>", there exists a browsing context whose <span data-x="browsing context
77683+
name">name</span> is the same as <var>name</var>, <var>current</var> is <span>familiar
77684+
with</span> that browsing context, and the user agent determines that the two browsing contexts
77685+
are related enough that it is ok if they reach each other, set <var>chosen</var> to that
77686+
browsing context. If there are multiple matching browsing contexts, the user agent should set
77687+
<var>chosen</var> to one in some arbitrary consistent manner, such as the most recently opened,
77688+
most recently focused, or more closely related.</p>
7768977689

7769077690
<p class="&#x0058;&#x0058;&#x0058;">This will be made more precise in <a
7769177691
href="https://github.com/whatwg/html/issues/1440">issue #1440</a>.</p>
@@ -77705,7 +77705,7 @@ console.assert(iframeWindow.frameElement === null);
7770577705

7770677706
<dt id="sandboxWindowOpen">If <var>current</var>'s <span>active document</span>'s <span>active
7770777707
sandboxing flag set</span> has the <span>sandboxed auxiliary navigation browsing context
77708-
flag</span> set.</dt>
77708+
flag</span> set</dt>
7770977709

7771077710
<dd>
7771177711
<p>The user agent may offer the user one of:
@@ -77726,7 +77726,7 @@ console.assert(iframeWindow.frameElement === null);
7772677726
</dd>
7772777727

7772877728
<dt id="noopener">If the user agent has been configured such that in this instance it will
77729-
create a new browsing context:</dt>
77729+
create a new browsing context</dt>
7773077730

7773177731
<dd>
7773277732
<p>Set <var>chosen</var> to a <span data-x="creating a new browsing context">new</span>

0 commit comments

Comments
 (0)