Skip to content

Commit dfd1db1

Browse files
committed
Remove mentions of XSLT from the html spec
1 parent 911f6bb commit dfd1db1

File tree

1 file changed

+6
-122
lines changed

1 file changed

+6
-122
lines changed

source

Lines changed: 6 additions & 122 deletions
Original file line numberDiff line numberDiff line change
@@ -2001,12 +2001,6 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
20012001
so that users can interact with them, unless the semantics of those elements have been
20022002
overridden by other specifications.</p>
20032003

2004-
<p class="example">A conforming web browser would, upon finding a <code>script</code> element in
2005-
an XML document, execute the script contained in that element. However, if the element is found
2006-
within a transformation expressed in XSLT (assuming the user agent also supports XSLT), then the
2007-
processor would instead treat the <code>script</code> element as an opaque element that forms
2008-
part of the transform.</p>
2009-
20102004
<p>Web browsers that support <span>the HTML syntax</span> must process documents labeled with an
20112005
<span>HTML MIME type</span> as described in this specification, so that users can interact with
20122006
them.</p>
@@ -2401,11 +2395,7 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
24012395
processing instruction, defined in <cite>Associating Style Sheets with XML documents</cite>.
24022396
<ref>XMLSSPI</ref></p>
24032397

2404-
<p>This specification also non-normatively mentions the <dfn><code>XSLTProcessor</code></dfn>
2405-
interface and its <dfn><code
2406-
data-x="dom-XSLTProcessor-transformToFragment">transformToFragment()</code></dfn> and <dfn><code
2407-
data-x="dom-XSLTProcessor-transformToDocument">transformToDocument()</code></dfn> methods.
2408-
<ref>XSLTP</ref></p>
2398+
24092399
</dd>
24102400

24112401

@@ -4956,12 +4946,7 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
49564946

49574947
<div w-nodev>
49584948

4959-
<h4>Interactions with XPath and XSLT</h4>
49604949

4961-
<p id="xpath-1.0-processors">Implementations of XPath 1.0 that operate on <span>HTML
4962-
documents</span> parsed or created in the manners described in this specification (e.g. as part of
4963-
the <code data-x="">document.evaluate()</code> API) must act as if the following edit was applied
4964-
to the XPath 1.0 specification.</p>
49654950

49664951
<p>First, remove this paragraph:</p>
49674952

@@ -5018,45 +5003,6 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
50185003
used for HTML elements. <ref>XPATH10</ref></p> <!-- note: version matters for
50195004
this ref -->
50205005

5021-
<hr>
5022-
5023-
<p id="dom-based-xslt-1.0-processors">XSLT 1.0 processors outputting to a DOM when the output
5024-
method is "html" (either explicitly or via the defaulting rule in XSLT 1.0) are affected as
5025-
follows:</p>
5026-
5027-
<p>If the transformation program outputs an element in no namespace, the processor must, prior to
5028-
constructing the corresponding DOM element node, change the namespace of the element to the
5029-
<span>HTML namespace</span>, <span data-x="converted to ASCII lowercase">ASCII-lowercase</span> the
5030-
element's local name, and <span data-x="converted to ASCII lowercase">ASCII-lowercase</span> the
5031-
names of any non-namespaced attributes on the element.</p>
5032-
5033-
<p class="note">This requirement is a <span>willful violation</span> of the XSLT 1.0
5034-
specification, required because this specification changes the namespaces and case-sensitivity
5035-
rules of HTML in a manner that would otherwise be incompatible with DOM-based XSLT
5036-
transformations. (Processors that serialize the output are unaffected.) <ref>XSLT10</ref></p> <!--
5037-
note: version matters for this ref -->
5038-
5039-
<hr>
5040-
5041-
<p>This specification does not specify precisely how XSLT processing interacts with the <span>HTML
5042-
parser</span> infrastructure (for example, whether an XSLT processor acts as if it puts any
5043-
elements into a <span>stack of open elements</span>). However, XSLT processors must <span>stop
5044-
parsing</span> if they successfully complete, and must <span>update the current document
5045-
readiness</span> first to "<code data-x="">interactive</code>" and then to "<code
5046-
data-x="">complete</code>" if they are aborted.</p>
5047-
5048-
<hr>
5049-
5050-
<p>This specification does not specify how XSLT interacts with the <span
5051-
data-x="navigate">navigation</span> algorithm, how it fits in with the <span>event loop</span>, nor
5052-
how error pages are to be handled (e.g. whether XSLT errors are to replace an incremental XSLT
5053-
output, or are rendered inline, etc.).</p>
5054-
5055-
<p class="note">There are also additional non-normative comments regarding the interaction of XSLT
5056-
and HTML <a href="#scriptTagXSLT">in the <code>script</code> element section</a>, and of
5057-
XSLT, XPath, and HTML <a href="#template-XSLT-XPath">in the <code>template</code> element
5058-
section</a>.</p>
5059-
50605006
</div>
50615007

50625008

@@ -11960,7 +11906,7 @@ partial interface <dfn id="document" data-lt="">Document</dfn> {
1196011906
<p>The nodes representing <span>HTML elements</span> in the DOM <span w-nodev>must</span>
1196111907
implement, and expose to scripts, the interfaces listed for them in the relevant sections of this
1196211908
specification. This includes <span>HTML elements</span> in <span>XML documents</span>, even when
11963-
those documents are in another context (e.g. inside an XSLT transform).</p>
11909+
those documents are in another context.</p>
1196411910

1196511911
<p>Elements in the DOM <dfn data-x="represents">represent</dfn> things; that is, they have
1196611912
intrinsic <em>meaning</em>, also known as semantics.</p>
@@ -64227,12 +64173,10 @@ document.body.append(script1, script2);
6422764173
<p class="note">The definition of <span data-x="concept-n-noscript">scripting is
6422864174
disabled</span> means that, amongst others, the following scripts will not execute: scripts in
6422964175
<code>XMLHttpRequest</code>'s <code data-x="dom-XMLHttpRequest-responseXML">responseXML</code>
64230-
documents, scripts in <code>DOMParser</code>-created documents, scripts in documents created by
64231-
<code>XSLTProcessor</code>'s <code
64232-
data-x="dom-XSLTProcessor-transformToDocument">transformToDocument</code> feature, and scripts
64176+
documents, scripts in <code>DOMParser</code>-created documents, and scripts
6423364177
that are first inserted by a script into a <code>Document</code> that was created using the
6423464178
<code data-x="dom-DOMImplementation-createDocument">createDocument()</code> API. <ref>XHR</ref>
64235-
<ref>DOMPARSING</ref> <ref>XSLTP</ref> <ref>DOM</ref></p>
64179+
<ref>DOMPARSING</ref> <ref>DOM</ref></p>
6423664180
</li>
6423764181

6423864182
<li>
@@ -64957,52 +64901,6 @@ not-slash = %x0000-002E / %x0030-10FFFF
6495764901
</div>
6495864902

6495964903

64960-
<div w-nodev>
64961-
64962-
<h5 id="scriptTagXSLT">Interaction of <code>script</code> elements and XSLT</h5>
64963-
64964-
<!-- NON-NORMATIVE SECTION -->
64965-
64966-
<p>This specification does not define how XSLT interacts with the <code>script</code> element.
64967-
However, in the absence of another specification actually defining this, here are some guidelines
64968-
for implementers, based on existing implementations:</p>
64969-
64970-
<ul>
64971-
<li><p>When an XSLT transformation program is triggered by an <code
64972-
data-x="">&lt;?xml-stylesheet?></code> processing instruction and the browser implements a
64973-
direct-to-DOM transformation, <code>script</code> elements created by the XSLT processor need to
64974-
have its <span>parser document</span> set correctly, and run in document order (modulo scripts
64975-
marked <code data-x="attr-script-defer">defer</code> or <code
64976-
data-x="attr-script-async">async</code>), <span>immediately</span>, as the transformation is
64977-
occurring.</p></li>
64978-
64979-
<li><p>The <code>XSLTProcessor</code> <code
64980-
data-x="dom-XSLTProcessor-transformToDocument">transformToDocument()</code> method adds elements
64981-
to a <code>Document</code> object with a null <span data-x="concept-document-bc">browsing
64982-
context</span>, and, accordingly, any <code>script</code> elements they create need to have
64983-
their <span>already started</span> set to true in the <span>prepare the script element</span>
64984-
algorithm and never get executed (<span data-x="concept-environment-noscript">scripting is
64985-
disabled</span>). Such <code>script</code> elements still need to have their <span>parser
64986-
document</span> set, though, such that their <code data-x="dom-script-async">async</code> IDL
64987-
attribute will return false in the absence of an <code data-x="attr-script-async">async</code>
64988-
content attribute.</p></li>
64989-
64990-
<li><p>The <code>XSLTProcessor</code> <code
64991-
data-x="dom-XSLTProcessor-transformToFragment">transformToFragment()</code> method needs to
64992-
create a fragment that is equivalent to one built manually by creating the elements using <code
64993-
data-x="dom-document-createElementNS">document.createElementNS()</code>. For instance, it needs
64994-
to create <code>script</code> elements with null <span>parser document</span> and with their
64995-
<span>already started</span> set to false, so that they will execute when the fragment is
64996-
inserted into a document.</p></li>
64997-
</ul>
64998-
64999-
<p>The main distinction between the first two cases and the last case is that the first two
65000-
operate on <code>Document</code>s and the last operates on a fragment.</p>
65001-
65002-
</div>
65003-
65004-
65005-
6500664904
<h4>The <dfn element><code>noscript</code></dfn> element</h4>
6500764905

6500864906
<dl class="element">
@@ -65478,24 +65376,16 @@ interface <dfn interface>HTMLTemplateElement</dfn> : <span>HTMLElement</span> {
6547865376

6547965377
<div w-nodev>
6548065378

65481-
<h5 id="template-XSLT-XPath">Interaction of <code>template</code> elements with XSLT and XPath</h5>
65379+
<h5 id="template-XPath">Interaction of <code>template</code> elements with XPath</h5>
6548265380

6548365381
<!-- NON-NORMATIVE SECTION -->
6548465382

65485-
<p>This specification does not define how XSLT and XPath interact with the <code>template</code>
65383+
<p>This specification does not define how XPath interacts with the <code>template</code>
6548665384
element. However, in the absence of another specification actually defining this, here are some
6548765385
guidelines for implementers, which are intended to be consistent with other processing described
6548865386
in this specification:</p>
6548965387

6549065388
<ul>
65491-
<li><p>An XSLT processor based on an XML parser that acts <span data-x="xml parser">as described
65492-
in this specification</span> needs to act as if <code>template</code> elements contain as
65493-
descendants their <span>template contents</span> for the purposes of the transform.</p></li>
65494-
65495-
<li><p>An XSLT processor that outputs a DOM needs to ensure that nodes that would go into a
65496-
<code>template</code> element are instead placed into the element's <span>template
65497-
contents</span>.</p></li>
65498-
6549965389
<li><p>XPath evaluation using the XPath DOM API when applied to a <code>Document</code> parsed
6550065390
using the <span>HTML parser</span> or the <span>XML parser</span> described in this specification
6550165391
needs to ignore <span>template contents</span>.</p>
@@ -147611,12 +147501,6 @@ INSERT INTERFACES HERE
147611147501

147612147502
<dt id="refsXPATH10">[XPATH10]</dt>
147613147503
<dd><cite><a href="https://www.w3.org/TR/1999/REC-xpath-19991116/">XML Path Language (XPath) Version 1.0</a></cite>, J. Clark, S. DeRose. W3C.</dd>
147614-
147615-
<dt id="refsXSLT10">[XSLT10]</dt>
147616-
<dd>(Non-normative) <cite><a href="https://www.w3.org/TR/1999/REC-xslt-19991116">XSL Transformations (XSLT) Version 1.0</a></cite>, J. Clark. W3C.</dd>
147617-
147618-
<dt id="refsXSLTP">[XSLTP]</dt>
147619-
<dd>(Non-normative) <cite><a href="https://wiki.whatwg.org/wiki/DOM_XSLTProcessor">DOM XSLTProcessor</a></cite>, WHATWG Wiki. WHATWG.</dd>
147620147504
</dl>
147621147505

147622147506

0 commit comments

Comments
 (0)