@@ -336,7 +336,7 @@ are invoked, now in reverse <a>tree order</a>.
336
336
337
337
< p > The < code > debug</ code > function will be invoked twice. Each time the < a > event</ a > 's
338
338
{{Event/target}} attribute value will be the < code > span</ code > < a for =/ > element</ a > . The first time
339
- {{Event/currentTarget}} attribute's value will be the <a>document</a> , the second time the
339
+ {{Event/currentTarget}} attribute's value will be the < a for = / > document</ a > , the second time the
340
340
< code > body</ code > < a for =/ > element</ a > . {{Event/eventPhase}} attribute's value switches from
341
341
{{Event/CAPTURING_PHASE}} to {{Event/BUBBLING_PHASE}}. If an < a > event listener</ a > was registered
342
342
for the < code > span</ code > < a for =/ > element</ a > , {{Event/eventPhase}} attribute's value would have
@@ -2340,16 +2340,16 @@ therefore alone in a <a>tree</a>.
2340
2340
< h4 id =document-trees > Document tree</ h4 >
2341
2341
2342
2342
< p > A < dfn export id =concept-document-tree > document tree</ dfn > is a < a > node tree</ a > whose
2343
- <a for=tree>root</a> is a <a>document</a> .
2343
+ < a for =tree > root</ a > is a < a for = / > document</ a > .
2344
2344
2345
- <p> The <dfn export>document element</dfn> of a <a>document</a> is the <a for=/>element</a> whose
2346
- <a for=tree>parent</a> is that <a>document</a> , if it exists; otherwise null.
2345
+ < p > The < dfn export > document element</ dfn > of a < a for = / > document</ a > is the < a for =/ > element</ a >
2346
+ whose < a for =tree > parent</ a > is that < a for = / > document</ a > , if it exists; otherwise null.
2347
2347
2348
2348
< p class =note > Per the < a > node tree</ a > constraints, there can be only one such
2349
2349
< a for =/ > element</ a > .
2350
2350
2351
2351
< p > A < a for =/ > node</ a > is < dfn export > in a document tree</ dfn > if its < a for =tree > root</ a > is a
2352
- <a>document</a> .
2352
+ < a for = / > document</ a > .
2353
2353
2354
2354
< p > A < a for =/ > node</ a > is < dfn export > in a document</ dfn > if it is < a > in a document tree</ a > .
2355
2355
< span class =note > The term < a > in a document</ a > is no longer supposed to be used. It indicates that
@@ -2370,7 +2370,7 @@ referred to as the <dfn export id=concept-light-tree>light tree</dfn>.</p>
2370
2370
itself.</ p >
2371
2371
2372
2372
< p id =in-a-shadow-including-document > A < a for =/ > node</ a > is < dfn export > connected</ dfn > if its
2373
- <a>shadow-including root</a> is a <a>document</a> .
2373
+ < a > shadow-including root</ a > is a < a for = / > document</ a > .
2374
2374
2375
2375
< h5 id =shadow-tree-slots > Slots</ h5 >
2376
2376
@@ -2628,12 +2628,12 @@ steps:
2628
2628
"{{HierarchyRequestError!!exception}}" {{DOMException}}.
2629
2629
2630
2630
< li > < p > If either < var > node</ var > is a {{Text}} < a for =/ > node</ a > and < var > parent</ var > is a
2631
- <a>document</a> , or <var> node</var> is a <a>doctype</a> and <var> parent</var> is not a
2632
- <a>document</a> , then <a>throw</a> a "{{HierarchyRequestError!!exception}} " {{DOMException}} .
2631
+ < a for = / > document</ a > , or < var > node</ var > is a < a > doctype</ a > and < var > parent</ var > is not a
2632
+ < a for = / > document</ a > , then < a > throw</ a > a "{{HierarchyRequestError!!exception}}" {{DOMException}}.
2633
2633
2634
2634
< li >
2635
- <p> If <var> parent</var> is a <a>document</a> , and any of the statements below, switched on the
2636
- interface <var> node</var> <a>implements</a> , are true, then <a>throw</a> a
2635
+ < p > If < var > parent</ var > is a < a for = / > document</ a > , and any of the statements below, switched on
2636
+ the interface < var > node</ var > < a > implements</ a > , are true, then < a > throw</ a > a
2637
2637
"{{HierarchyRequestError!!exception}}" {{DOMException}}.
2638
2638
2639
2639
< dl class =switch >
@@ -2898,12 +2898,12 @@ within a <var>parent</var>, run these steps:
2898
2898
"{{HierarchyRequestError!!exception}}" {{DOMException}}.
2899
2899
2900
2900
< li > < p > If either < var > node</ var > is a {{Text}} < a for =/ > node</ a > and < var > parent</ var > is a
2901
- <a>document</a> , or <var> node</var> is a <a>doctype</a> and <var> parent</var> is not a
2902
- <a>document</a> , then <a>throw</a> a "{{HierarchyRequestError!!exception}} " {{DOMException}} .
2901
+ < a for = / > document</ a > , or < var > node</ var > is a < a > doctype</ a > and < var > parent</ var > is not a
2902
+ < a for = / > document</ a > , then < a > throw</ a > a "{{HierarchyRequestError!!exception}}" {{DOMException}}.
2903
2903
2904
2904
< li >
2905
- <p> If <var> parent</var> is a <a>document</a> , and any of the statements below, switched on the
2906
- interface <var> node</var> <a>implements</a> , are true, then <a>throw</a> a
2905
+ < p > If < var > parent</ var > is a < a for = / > document</ a > , and any of the statements below, switched on
2906
+ the interface < var > node</ var > < a > implements</ a > , are true, then < a > throw</ a > a
2907
2907
"{{HierarchyRequestError!!exception}}" {{DOMException}}.
2908
2908
2909
2909
< dl class =switch >
@@ -4130,7 +4130,7 @@ get a direct instance of it.
4130
4130
4131
4131
< p > Each < a for =/ > node</ a > has an associated
4132
4132
< dfn export for =Node id =concept-node-document > node document</ dfn > , set upon creation, that is a
4133
- <a>document</a> .
4133
+ < a for = / > document</ a > .
4134
4134
4135
4135
< p class =note > A < a for =/ > node</ a > 's < a for =Node > node document</ a > can be changed by the
4136
4136
< a > adopt</ a > algorithm.
@@ -4334,10 +4334,11 @@ statement, switching on the interface <a>this</a> <a>implements</a>:
4334
4334
if < a > this</ a > is < a > connected</ a > ; otherwise false.</ p >
4335
4335
4336
4336
< p > The < dfn attribute for =Node > < code > ownerDocument</ code > </ dfn > getter steps are to return null,
4337
- if <a>this</a> is a <a>document</a> ; otherwise <a>this</a> 's <a for=Node>node document</a> .
4337
+ if < a > this</ a > is a < a for = / > document</ a > ; otherwise < a > this</ a > 's < a for =Node > node document</ a > .
4338
4338
4339
- <p class=note> The <a for=Node>node document</a> of a <a>document</a> is that <a>document</a> itself.
4340
- All <a for=/>nodes</a> have a <a for=Node>node document</a> at all times.
4339
+ < p class =note > The < a for =Node > node document</ a > of a < a for =/ > document</ a > is that
4340
+ < a for =/ > document</ a > itself. All < a for =/ > nodes</ a > have a < a for =Node > node document</ a > at all
4341
+ times.
4341
4342
4342
4343
< p > The < dfn method for =Node > < code > getRootNode(< var > options</ var > )</ code > </ dfn > method steps are to
4343
4344
return < a > this</ a > 's < a > shadow-including root</ a > if
@@ -5152,9 +5153,9 @@ dictionary ElementCreationOptions {
5152
5153
< p > {{Document}} < a for =/ > nodes</ a > are simply
5153
5154
known as < dfn export id =concept-document lt ="document "> documents</ dfn > .
5154
5155
5155
- <p> A <a>document</a> 's <a>node document</a> is itself.
5156
+ < p > A < a for = / > document</ a > 's < a > node document</ a > is itself.
5156
5157
5157
- <p> Each <a>document</a> has an associated
5158
+ < p > Each < a for = / > document</ a > has an associated
5158
5159
< dfn export for =Document id =concept-document-encoding > encoding</ dfn > (an < a for =/ > encoding</ a > ),
5159
5160
< dfn export for =Document id =concept-document-content-type > content type</ dfn > (a string),
5160
5161
< dfn export for =Document id =concept-document-url > URL</ dfn > (a < a for =/ > URL</ a > ),
@@ -5166,18 +5167,19 @@ known as <dfn export id=concept-document lt="document">documents</dfn>.
5166
5167
[[!URL]]
5167
5168
[[!HTML]]
5168
5169
5169
- <p> Unless stated otherwise, a <a>document</a> 's <a for=Document>encoding</a> is the <a>utf-8</a>
5170
- <a for=/>encoding</a> , <a for=Document>content type</a> is
5170
+ < p > Unless stated otherwise, a < a for = / > document</ a > 's < a for =Document > encoding</ a > is the
5171
+ < a > utf-8 </ a > < a for =/ > encoding</ a > , < a for =Document > content type</ a > is
5171
5172
"< code > application/xml</ code > ", < a for =Document > URL</ a > is "< code > about:blank</ code > ",
5172
5173
< a for =Document > origin</ a > is an < a > opaque origin</ a > ,
5173
5174
< a for =Document > type</ a > is "< code > xml</ code > ", < a for =Document > mode</ a > is
5174
5175
"< code > no-quirks</ code > ", and its < a for =Document > allow declarative shadow roots</ a > is false.
5175
5176
5176
- <p> A <a>document</a> is said to be an <dfn export>XML document</dfn> if its <a for=Document>type</a>
5177
- is "<code> xml</code> "; otherwise an <dfn export>HTML document</dfn> . Whether a <a>document</a> is an
5178
- <a>HTML document</a> or an <a>XML document</a> affects the behavior of certain APIs.
5177
+ < p > A < a for =/ > document</ a > is said to be an < dfn export > XML document</ dfn > if its
5178
+ < a for =Document > type</ a > is "< code > xml</ code > "; otherwise an < dfn export > HTML document</ dfn > .
5179
+ Whether a < a for =/ > document</ a > is an < a > HTML document</ a > or an < a > XML document</ a > affects the
5180
+ behavior of certain APIs.
5179
5181
5180
- <p> A <a>document</a> is said to be in
5182
+ < p > A < a for = / > document</ a > is said to be in
5181
5183
< dfn export id =concept-document-no-quirks > no-quirks mode</ dfn > if its
5182
5184
< a for =Document > mode</ a > is "< code > no-quirks</ code > ",
5183
5185
< dfn export id =concept-document-quirks > quirks mode</ dfn > if its < a for =Document > mode</ a >
@@ -5196,16 +5198,16 @@ is "<code>quirks</code>", and
5196
5198
are nonsensical.)
5197
5199
</ div >
5198
5200
5199
- <p> A <a>document</a> 's <a>get the parent</a> algorithm, given an <var> event</var> , returns
5201
+ < p > A < a for = / > document</ a > 's < a > get the parent</ a > algorithm, given an < var > event</ var > , returns
5200
5202
null if < var > event</ var > 's {{Event/type}} attribute value is "< code > load</ code > " or
5201
- <a>document</a> does not have a <a for=Document>browsing context</a> ; otherwise the
5202
- <a>document</a> 's <a>relevant global object</a> .
5203
+ < a for = / > document</ a > does not have a < a for =Document > browsing context</ a > ; otherwise the
5204
+ < a for = / > document</ a > 's < a > relevant global object</ a > .
5203
5205
5204
5206
< hr >
5205
5207
5206
5208
< dl class =domintro >
5207
5209
< dt > < code > < var > document</ var > = new {{Document()}}</ code >
5208
- <dd> Returns a new <a>document</a> .
5210
+ < dd > Returns a new < a for = / > document</ a > .
5209
5211
5210
5212
< dt > < code > < var > document</ var > . {{Document/implementation}}</ code >
5211
5213
< dd > Returns < var > document</ var > 's {{DOMImplementation}} object.
@@ -5233,7 +5235,7 @@ steps are to set <a>this</a>'s <a for=Document>origin</a> to the <a for=Document
5233
5235
< a > current global object</ a > 's < a > associated < code > Document</ code > </ a > . [[!HTML]]
5234
5236
5235
5237
< p class =note > Unlike {{DOMImplementation/createDocument()}}, this constructor does not
5236
- return an {{XMLDocument}} object, but a <a>document</a> ({{Document}} object).
5238
+ return an {{XMLDocument}} object, but a < a for = / > document</ a > ({{Document}} object).
5237
5239
5238
5240
< p > The
5239
5241
< dfn attribute for =Document > < code > implementation</ code > </ dfn > getter steps are to return the
@@ -5297,7 +5299,7 @@ otherwise "<code>CSS1Compat</code>".
5297
5299
< dt > < var > collection</ var > = < var > document</ var > . {{Document/getElementsByClassName(classNames)}}</ code >
5298
5300
< dt > < var > collection</ var > = < var > element</ var > . {{Element/getElementsByClassName(classNames)}}</ code >
5299
5301
< dd > < p > Returns an {{HTMLCollection}} of the < a for =/ > elements</ a > in the object on which the method
5300
- was invoked (a <a>document</a> or an <a for=/>element</a> ) that have all the classes given by
5302
+ was invoked (a < a for = / > document</ a > or an < a for =/ > element</ a > ) that have all the classes given by
5301
5303
< var > classNames</ var > . The < var > classNames</ var > argument is interpreted as a space-separated list
5302
5304
of classes.
5303
5305
</ dl >
@@ -5557,16 +5559,16 @@ method steps are:
5557
5559
< p > Returns a copy of < var > node</ var > . If < var > deep</ var > is true, the copy also includes the
5558
5560
< var > node</ var > 's < a for =tree > descendants</ a > .
5559
5561
5560
- <p> If <var> node</var> is a <a>document</a> or a <a for=/>shadow root</a> , throws a
5562
+ < p > If < var > node</ var > is a < a for = / > document</ a > or a < a for =/ > shadow root</ a > , throws a
5561
5563
"{{NotSupportedError!!exception}}" {{DOMException}}.
5562
5564
5563
5565
< dt > < var > node</ var > = < var > document</ var > . {{adoptNode(node)}}
5564
5566
5565
5567
< dd >
5566
5568
Moves < var > node</ var > from another
5567
- <a>document</a> and returns it.
5569
+ < a for = / > document</ a > and returns it.
5568
5570
5569
- If <var> node</var> is a <a>document</a> , throws a "{{NotSupportedError!!exception}} "
5571
+ If < var > node</ var > is a < a for = / > document</ a > , throws a "{{NotSupportedError!!exception}}"
5570
5572
{{DOMException}} or, if < var > node</ var > is a < a for =/ > shadow root</ a > , throws a
5571
5573
"{{HierarchyRequestError!!exception}}" {{DOMException}}.
5572
5574
</ dl >
@@ -5575,8 +5577,8 @@ method steps are:
5575
5577
method steps are:
5576
5578
5577
5579
< ol >
5578
- <li><p> If <var> node</var> is a <a>document</a> or <a for=/>shadow root</a> , then <a>throw</a> a
5579
- "{{NotSupportedError!!exception}} " {{DOMException}} .
5580
+ < li > < p > If < var > node</ var > is a < a for = / > document</ a > or < a for =/ > shadow root</ a > , then < a > throw</ a >
5581
+ a "{{NotSupportedError!!exception}}" {{DOMException}}.
5580
5582
5581
5583
< li > < p > Return a < a lt ="clone a node "> clone</ a > of < var > node</ var > , with < a > this</ a > and the
5582
5584
< i > clone children flag</ i > set if < var > deep</ var > is true.
@@ -5627,7 +5629,7 @@ these steps:
5627
5629
< p > The < dfn method for =Document > < code > adoptNode(< var > node</ var > )</ code > </ dfn > method steps are:
5628
5630
5629
5631
< ol >
5630
- <li><p> If <var> node</var> is a <a>document</a> , then <a>throw</a> a
5632
+ < li > < p > If < var > node</ var > is a < a for = / > document</ a > , then < a > throw</ a > a
5631
5633
"{{NotSupportedError!!exception}}" {{DOMException}}.
5632
5634
5633
5635
< li > < p > If < var > node</ var > is a < a for =/ > shadow root</ a > , then < a > throw</ a > a
@@ -5786,9 +5788,8 @@ method steps are:
5786
5788
5787
5789
< h4 id =interface-domimplementation > Interface {{DOMImplementation}}</ h4 >
5788
5790
5789
- User agents must create a {{DOMImplementation}} object whenever
5790
- a <a>document</a> is created and associate it
5791
- with that <a>document</a> .
5791
+ < p > User agents must create a {{DOMImplementation}} object whenever a < a for =/ > document</ a > is
5792
+ created and associate it with that < a for =/ > document</ a > .
5792
5793
5793
5794
< pre class =idl >
5794
5795
[Exposed=Window]
@@ -5831,7 +5832,7 @@ interface DOMImplementation {
5831
5832
< dt > < code > < var > doc</ var > = < var > document</ var > . {{Document/implementation}} . < a method for =DOMImplementation lt =createHTMLDocument() > createHTMLDocument([< var > title</ var > ])</ a > </ code >
5832
5833
5833
5834
< dd >
5834
- Returns a <a>document</a> , with a basic
5835
+ Returns a < a for = / > document</ a > , with a basic
5835
5836
< a > tree</ a > already constructed including a
5836
5837
< {title}> element, unless the < var > title</ var >
5837
5838
argument is omitted.
@@ -5849,7 +5850,7 @@ method steps are:
5849
5850
< li > < p > Return a new < a > doctype</ a > , with < var > qualifiedName</ var > as its
5850
5851
< a for =DocumentType > name</ a > , < var > publicId</ var > as its < a > public ID</ a > , and < var > systemId</ var >
5851
5852
as its < a > system ID</ a > , and with its < a for =Node > node document</ a > set to the associated
5852
- <a>document</a> of <a>this</a> .
5853
+ < a for = / > document</ a > of < a > this</ a > .
5853
5854
</ ol >
5854
5855
5855
5856
< p class =note > No check is performed that < var > publicId</ var > code points match the
@@ -5874,7 +5875,7 @@ method steps are:
5874
5875
< li > < p > If < var > element</ var > is non-null, < a > append</ a > < var > element</ var > to < var > document</ var > .
5875
5876
5876
5877
< li > < p > < var > document</ var > 's < a for =Document > origin</ a > is < a > this</ a > 's associated
5877
- <a>document</a> 's <a for=Document>origin</a> .
5878
+ < a for = / > document</ a > 's < a for =Document > origin</ a > .
5878
5879
5879
5880
< li >
5880
5881
< p > < var > document</ var > 's < a for =Document > content type</ a > is determined by < var > namespace</ var > :
@@ -5898,7 +5899,7 @@ method steps are:
5898
5899
method steps are:
5899
5900
5900
5901
< ol >
5901
- <li><p> Let <var> doc</var> be a new <a>document</a> that is an <a>HTML document</a> .
5902
+ < li > < p > Let < var > doc</ var > be a new < a for = / > document</ a > that is an < a > HTML document</ a > .
5902
5903
5903
5904
< li > < p > Set < var > doc</ var > 's < a for =Document > content type</ a > to "< code > text/html</ code > ".
5904
5905
@@ -5927,8 +5928,8 @@ method steps are:
5927
5928
< li > < p > < a > Append</ a > the result of < a > creating an element</ a > given < var > doc</ var > ,
5928
5929
"< code > body</ code > ", and the < a > HTML namespace</ a > , to the < {html}> element created earlier.</ li >
5929
5930
5930
- <li><p><var> doc</var> 's <a for=Document>origin</a> is <a>this</a>' s associated <a>document</a> 's
5931
- <a for=Document>origin</a> .
5931
+ < li > < p > < var > doc</ var > 's < a for =Document > origin</ a > is < a > this</ a > 's associated
5932
+ < a for =/ > document </ a > 's < a for = Document > origin</ a > .
5932
5933
5933
5934
< li > < p > Return < var > doc</ var > .
5934
5935
</ ol >
@@ -8194,7 +8195,7 @@ to set <a>this</a>'s <a for=range>start</a> and <a for=range>end</a> to
8194
8195
8195
8196
< dl class =domintro >
8196
8197
< dt > < var > container</ var > = < var > range</ var > . {{Range/commonAncestorContainer}}
8197
- <dd> Returns the <a for=/>node</a> , furthest away from the <a>document</a> , that is an
8198
+ < dd > Returns the < a for =/ > node</ a > , furthest away from the < a for = / > document</ a > , that is an
8198
8199
< a for =tree > ancestor</ a > of both < var > range</ var > 's < a for =range > start node</ a > and
8199
8200
< a for =range > end node</ a > .
8200
8201
</ dl >
0 commit comments