New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow currentScript to return SVGScriptElement #913
Conversation
@@ -8389,6 +8389,7 @@ interface <dfn>DOMStringMap</dfn> { | |||
this specification extends significantly:</p> | |||
|
|||
<pre class="idl">enum <dfn>DocumentReadyState</dfn> { "loading", "interactive", "complete" }; | |||
typedef (<span>HTMLScriptElement</span> or SVGScriptElement) <dfn>HTMLOrSVGScriptElement</dfn>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be xrefed to https://www.w3.org/TR/SVG11/script.html#InterfaceSVGScriptElement
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be okay to just <dfn>
it in place for now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, maybe there should be an SVG section in dependencies somewhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah I think a new section is a good idea. I thought there was one already...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have an SVG section as part of "The elements of HTML", but no SVG dependency section. We also currently do not xref SVG elements. E.g., we have SVG title element somewhere. Should that be cleaned up as part of this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be really nice if you could. The only other instance I found matching SVG[a-zA-Z]*Element
is a single SVGSVGElement
in an appendix.
And I guess we just assume that SVG eventually defines steps to set the SVG script element's node document's currentScript value, and it's OK for now to have a return type which there's no normative text explaining how it takes that value? |
Yeah, my assumption is that either SVG will define its processing model or we'll eventually have to do it somehow. |
20349ae
to
77997e7
Compare
That was a lot more work than I anticipated. I added SVG to the dependencies and then MathML didn't look quite right, so I had to add that too. It all looks pretty good now I think and a lot cleaner than before. |
It looks like the MathML URLs should be updated to https://www.w3.org/Math/draft-spec/. Currently they are a bit inconsistent: the bibliography lists https://www.w3.org/TR/MathML/ but the individual links use https://www.w3.org/TR/MathML3/ as their base. |
|
||
<dd> | ||
<p>While support for MathML as a whole is not required by this specification (though it is | ||
encouraged, at least for Web browsers), certain features depened upon small parts of MathML |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/depened/depend/
Really nice improvement. LGTM with the nits above. |
Instead of defining MathML and SVG requirements midway through the section dedicated to elements in HTML, do this more logically upfront. This also introduces a consistent way to reference MathML and SVG elements inside the HTML standard.
77997e7
to
6762f87
Compare
Fixes https://www.w3.org/Bugs/Public/show_bug.cgi?id=28753.