@@ -2072,24 +2072,24 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
2072
2072
2073
2073
<p>A <dfn data-x="nodes are inserted">node <var>A</var> is inserted</dfn> into a node <var>B</var>
2074
2074
when the <span data-x="concept-node-insert-ext">insertion steps</span> are invoked with
2075
- <var>A</var> as the argument and <var>A</var>'s new parent is <var>B</var>. Similarly, a <dfn
2076
- data-x="nodes are removed">node <var>A</var> is removed</dfn> from a node <var>B</var> when the
2077
- <span data-x="concept-node-remove-ext">removing steps</span> are invoked with <var>A</var> as the
2078
- <var>removedNode</var> argument and <var>B</var> as the <var>oldParent</var> argument.</p>
2075
+ <var>A</var> as the first argument and <var>A</var>'s new parent is <var>B</var>. Similarly, a
2076
+ <dfn data-x="nodes are removed">node <var>A</var> is removed</dfn> from a node <var>B</var> when
2077
+ the <span data-x="concept-node-remove-ext">removing steps</span> are invoked with <var>A</var> as
2078
+ the <var>removedNode</var> argument and <var>B</var> as the <var>oldParent</var> argument.</p>
2079
2079
2080
2080
<p>A <dfn id="insert-an-element-into-a-document" data-x="node is inserted into a document"
2081
2081
data-lt="inserted into a document|node is inserted into a document" data-export="">node is
2082
2082
inserted into a document</dfn> when the <span data-x="concept-node-insert-ext">insertion
2083
- steps</span> are invoked with it as the argument and it is now <span>in a document tree</span>.
2084
- Analogously, a <dfn id="remove-an-element-from-a-document" data-x="node is removed from a
2085
- document" data-lt="removed from a document|node is removed from a document" data-export="">node is
2086
- removed from a document</dfn> when the <span data-x="concept-node-remove-ext">removing
2087
- steps</span> are invoked with it as the argument and it is now no longer <span>in a document
2088
- tree</span>.</p>
2083
+ steps</span> are invoked with it as the first argument and it is now <span>in a document
2084
+ tree</span>. Analogously, a <dfn id="remove-an-element-from-a-document" data-x="node is removed
2085
+ from a document" data-lt="removed from a document|node is removed from a document"
2086
+ data-export="">node is removed from a document</dfn> when the <span
2087
+ data-x="concept-node-remove-ext">removing steps</span> are invoked with it as the argument and it
2088
+ is now no longer <span>in a document tree</span>.</p>
2089
2089
2090
2090
<p>A node <dfn data-export="">becomes connected</dfn> when the <span
2091
- data-x="concept-node-insert-ext">insertion steps</span> are invoked with it as the argument and it
2092
- is now <span>connected</span>. Analogously, a node <dfn data-lt="become disconnected"
2091
+ data-x="concept-node-insert-ext">insertion steps</span> are invoked with it as the first argument
2092
+ and it is now <span>connected</span>. Analogously, a node <dfn data-lt="become disconnected"
2093
2093
data-export="">becomes disconnected</dfn> when the <span data-x="concept-node-remove-ext">removing
2094
2094
steps</span> are invoked with it as the argument and it is now no longer
2095
2095
<span>connected</span>.</p>
@@ -2098,12 +2098,13 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
2098
2098
<span>connected</span> and its <span data-x="shadow-including root">shadow-including root</span>
2099
2099
has a <span data-x="concept-document-bc">browsing context</span>. A node <dfn data-lt="become
2100
2100
browsing-context connected" data-export="">becomes browsing-context connected</dfn> when the <span
2101
- data-x="concept-node-insert-ext">insertion steps</span> are invoked with it as the argument and it
2102
- is now <span>browsing-context connected</span>. A node <dfn data-lt="become browsing-context
2103
- disconnected" data-export="">becomes browsing-context disconnected</dfn> either when the <span
2104
- data-x="concept-node-remove-ext">removing steps</span> are invoked with it as the argument and it
2105
- is now no longer <span>browsing-context connected</span>, or when its <span>shadow-including
2106
- root</span> no longer has a <span data-x="concept-document-bc">browsing context</span>.
2101
+ data-x="concept-node-insert-ext">insertion steps</span> are invoked with it as the first argument
2102
+ and it is now <span>browsing-context connected</span>. A node <dfn data-lt="become
2103
+ browsing-context disconnected" data-export="">becomes browsing-context disconnected</dfn> either
2104
+ when the <span data-x="concept-node-remove-ext">removing steps</span> are invoked with it as the
2105
+ argument and it is now no longer <span>browsing-context connected</span>, or when its
2106
+ <span>shadow-including root</span> no longer has a <span data-x="concept-document-bc">browsing
2107
+ context</span>.
2107
2108
2108
2109
2109
2110
<h4>Scripting</h4>
@@ -3194,7 +3195,8 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
3194
3195
<li>The <dfn data-x-href="https://dom.spec.whatwg.org/#concept-node-pre-insert">pre-insert</dfn>, <dfn data-x="concept-node-insert" data-x-href="https://dom.spec.whatwg.org/#concept-node-insert">insert</dfn>, <dfn data-x="concept-node-append" data-x-href="https://dom.spec.whatwg.org/#concept-node-append">append</dfn>, <dfn data-x="concept-node-replace" data-x-href="https://dom.spec.whatwg.org/#concept-node-replace">replace</dfn>, <dfn data-x="concept-node-replace-all" data-x-href="https://dom.spec.whatwg.org/#concept-node-replace-all">replace all</dfn>, <dfn data-x="concept-node-remove" data-x-href="https://dom.spec.whatwg.org/#concept-node-remove">remove</dfn>, and <dfn data-x="concept-node-adopt" data-x-href="https://dom.spec.whatwg.org/#concept-node-adopt">adopt</dfn> algorithms for nodes</li>
3195
3196
<li>The <dfn data-x="concept-node-insert-ext" data-x-href="https://dom.spec.whatwg.org/#concept-node-insert-ext">insertion steps</dfn>,
3196
3197
<dfn data-x="concept-node-remove-ext" data-x-href="https://dom.spec.whatwg.org/#concept-node-remove-ext">removing steps</dfn>,
3197
- <dfn data-x="concept-node-adopt-ext" data-x-href="https://dom.spec.whatwg.org/#concept-node-adopt-ext">adopting steps</dfn>, and
3198
+ <dfn data-x="concept-node-adopt-ext" data-x-href="https://dom.spec.whatwg.org/#concept-node-adopt-ext">adopting steps</dfn>,
3199
+ <dfn data-x="concept-node-children-added" data-x-href="https://dom.spec.whatwg.org/#concept-node-children-added-ext">children added steps</dfn>, and
3198
3200
<dfn data-x-href="https://dom.spec.whatwg.org/#concept-node-text-change-ext">child text content change steps</dfn> hooks for elements</li>
3199
3201
<li>The <dfn data-x="concept-element-attributes-change" data-x-href="https://dom.spec.whatwg.org/#concept-element-attributes-change">change</dfn>, <dfn data-x="concept-element-attributes-append" data-x-href="https://dom.spec.whatwg.org/#concept-element-attributes-append">append</dfn>, <dfn data-x="concept-element-attributes-remove" data-x-href="https://dom.spec.whatwg.org/#concept-element-attributes-remove">remove</dfn>, <dfn data-x="concept-element-attributes-replace" data-x-href="https://dom.spec.whatwg.org/#concept-element-attributes-replace">replace</dfn>, and <dfn data-x="concept-element-attributes-set-value" data-x-href="https://dom.spec.whatwg.org/#concept-element-attributes-set-value">set value</dfn> algorithms for attributes</li>
3200
3202
<li>The <dfn data-x="concept-element-attributes-change-ext" data-x-href="https://dom.spec.whatwg.org/#concept-element-attributes-change-ext">attribute change steps</dfn> hook for attributes</li>
@@ -15043,8 +15045,21 @@ interface <dfn>HTMLStyleElement</dfn> : <span>HTMLElement</span> {
15043
15045
15044
15046
<div w-nodev>
15045
15047
15046
- <p>The user agent must run the <span>update a <code>style</code> block</span> algorithm whenever
15047
- one of the following conditions occur:</p>
15048
+ <p>To run the <span data-x="concept-node-insert-ext">insertion steps</span> for a
15049
+ <code>style</code> element with <var>style</var> and <var>deferredStepsQueue</var>, the user
15050
+ agent must act as follows:</p>
15051
+
15052
+ <ol>
15053
+ <li><p>If <var>style</var> is on the <span>stack of open elements</span>, then return.<p></li>
15054
+
15055
+ <li><p>If <var>style</var> is not <span>connected</span>, then return.</p></li>
15056
+
15057
+ <li><p><span>Enqueue</span> the steps to <span data-x="update a style block">update</span>
15058
+ <var>style</var> to <var>deferredStepsQueue</var>.</p></li>
15059
+ </ol>
15060
+
15061
+ <p>Additionally, the user agent must run the <span>update a <code>style</code> block</span>
15062
+ algorithm whenever one of the following conditions occur:</p>
15048
15063
<!-- note that a browsing context isn't needed:
15049
15064
https://software.hixie.ch/utilities/js/live-dom-viewer/?saved=2739 -->
15050
15065
@@ -15053,8 +15068,7 @@ interface <dfn>HTMLStyleElement</dfn> : <span>HTMLElement</span> {
15053
15068
parser</span> or <span>XML parser</span>.</p></li>
15054
15069
15055
15070
<li><p>The element is not on the <span>stack of open elements</span> of an <span>HTML
15056
- parser</span> or <span>XML parser</span>, and it <span>becomes connected</span> or <span
15057
- data-x="becomes disconnected">disconnected</span>.</p></li>
15071
+ parser</span> or <span>XML parser</span>, and it <span>becomes disconnected</span>.</p></li>
15058
15072
15059
15073
<li><p>The element's <span>child text content change steps</span> run.</p></li>
15060
15074
</ul>
@@ -58110,24 +58124,30 @@ o............A....e
58110
58124
58111
58125
<hr>
58112
58126
58113
- <p>When a <code>script</code> element that is not marked as being <span>"parser-inserted"</span>
58114
- experiences one of the events listed in the following list, the user agent must
58115
- <span>immediately</span> <span data-x="prepare a script">prepare</span> the <code>script</code>
58116
- element:</p>
58127
+ <p>To run the <span data-x="concept-node-insert-ext">insertion steps</span> for a
58128
+ <code>script</code> element with <var>script</var> and <var>deferredStepsQueue</var>, the user
58129
+ agent must act as follows:</p>
58117
58130
58118
- <ul>
58131
+ <ol>
58132
+ <li><p>If <var>script</var> is marked as being <span>"parser-inserted"</span>, then
58133
+ return.<p></li>
58119
58134
58120
- <li>The <code >script</code> element <span>becomes connected</span>. </li>
58135
+ <li><p>If <var >script</var> is not <span>connected</span>, then return.</p> </li>
58121
58136
58122
- <li>The <code>script</code> element is < span>connected </span> and a node or document fragment is
58123
- <span data-x="nodes are inserted">inserted</span> into the <code>script</code> element, after any
58124
- <code>script</code> elements <span data-x="nodes are inserted">inserted</span> at that time.</li >
58137
+ <li><p>< span>Enqueue </span> the steps to <span data-x="prepare a script">prepare</span>
58138
+ <var>script</var> to <var>deferredStepsQueue</var>.</p></li>
58139
+ </ol >
58125
58140
58126
- <li>The <code>script</code> element is <span>connected</span> and has a <code
58127
- data-x="attr-script-src">src</code> attribute set where previously the element had no such
58128
- attribute.</li>
58141
+ <p>To run the <span data-x="concept-node-children-added">children added steps</span> for a
58142
+ <code>script</code> element with <var>script</var> and <var>deferredStepsQueue</var>, the user
58143
+ agent must run the <span data-x="concept-node-insert-ext">insertion steps</span> with
58144
+ <var>script</var> and <var>deferredStepsQueue</var>.</p>
58129
58145
58130
- </ul>
58146
+ <p>Additionally, when a <code>script</code> element that is not marked as being
58147
+ <span>"parser-inserted"</span> is <span>connected</span> and has a <code
58148
+ data-x="attr-script-src">src</code> attribute set where previously the element had no such
58149
+ attribute, the user agent must <span>immediately</span> <span
58150
+ data-x="prepare a script">prepare</span> the <code>script</code> element.</p>
58131
58151
58132
58152
<p>To <dfn data-x="prepare a script" data-export="">prepare a script</dfn>, the user agent must
58133
58153
act as follows:</p>
0 commit comments