Skip to content

Commit 85e1e72

Browse files
foolipannevk
authored andcommitted
Make popstate and hashchange events not bubble
Out of Chrome, Edge, Firefox and Safari, only Firefox sets bubbles to true for these events. Since they are dispatched on the Window object, that is not particularly meaningful, so match the 3/4 majority. Tests: web-platform-tests/wpt#11355.
1 parent 326c644 commit 85e1e72

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

source

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -83201,20 +83201,19 @@ interface <dfn>Location</dfn> { // but see also <a href="#the-location-interface
8320183201
<li><p>If <var>state changed</var> is true, then <span data-x="concept-event-fire">fire an
8320283202
event</span> named <code data-x="event-popstate">popstate</code> at the <code>Document</code>
8320383203
object's <code>Window</code> object, using <code>PopStateEvent</code>, with the <code
83204-
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true and the <code
83205-
data-x="dom-PopStateEvent-state">state</code> attribute initialized <var>state</var>.</p></li>
83204+
data-x="dom-PopStateEvent-state">state</code> attribute initialized to
83205+
<var>state</var>.</p></li>
8320683206

8320783207
<li><p>If <var>entry</var> is <span>an entry with persisted user state</span>, then the user
8320883208
agent may <span>restore persisted user state</span> and update aspects of the document and its
8320983209
rendering.</p></li>
8321083210

8321183211
<li><p>If <var>hash changed</var> is true, then <span data-x="concept-event-fire">fire an
8321283212
event</span> named <code data-x="event-hashchange">hashchange</code> at the <span>browsing
83213-
context</span>'s <code>Window</code> object, using <code>HashChangeEvent</code>, with the <code
83214-
data-x="dom-Event-bubbles">bubbles</code> attribute initialized to true, the <code
83215-
data-x="dom-HashChangeEvent-oldURL">oldURL</code> attribute initialized to <var>old URL</var>,
83216-
and the <code data-x="dom-HashChangeEvent-newURL">newURL</code> attribute initialized to
83217-
<var>new URL</var>.</p></li>
83213+
context</span>'s <code>Window</code> object, using <code>HashChangeEvent</code>, with the
83214+
<code data-x="dom-HashChangeEvent-oldURL">oldURL</code> attribute initialized to <var>old
83215+
URL</var> and the <code data-x="dom-HashChangeEvent-newURL">newURL</code> attribute
83216+
initialized to <var>new URL</var>.</p></li>
8321883217

8321983218
</ol>
8322083219

0 commit comments

Comments
 (0)