What interface does the <x> element use?
Every Element object that corresponds to an SVG element (that is, an element with namespace URI "http://www.w3.org/2000/svg" and a local name that is one of the elements defined in this specification) must also implement the DOM interface identified in element definition. For example, in The ‘rect’ element, the SVGRectElement interface is identified. This means that every Element object whose namespace URI is "http://www.w3.org/2000/svg" and whose local name is "rect" must also implement SVGRectElement.
but this doesn't cover the <x> element above, which I think means it must implement the Element interface. Blink and Gecko don't do that; they use SVGElement interface for unknown elements in the SVG namespace.
I think the spec should require that all elements in the SVG namespace with a local name that is not a defined SVG element in the spec, must implement the SVGElement interface.
(HTML uses an "HTMLUnknownElement" interface for unknown elements, but that's just because legacy content required it; we don't need to copy that for SVG.)
What should happen for the same element without the wrapping html doctype tag?
Should the behaviour not be the same ?
<x> is inside of the SVG document, so I would expect it would behave according to rules of SVG and certainly not get a behavior that isn't defined in some fashion in the SVG standard.
Your comment makes no sense.
If it helps, ignore the markup in comment 0 and instead consider the following:
The SVG WG is looking into defining a SVGUnknownElement. IIRC, Blink is experimenting with it. This will be in the SVG namespace though.
Why? Just cargo-cult copy HTML? Why not just use SVGElement, as it's implemented today?
(In reply to Simon Pieters from comment #4)
> Why? Just cargo-cult copy HTML? Why not just use SVGElement, as it's
> implemented today?
You are right. Just checked Blink source code again. SVGUnknownElement is not exposed to the web but rather a placeholder to avoid rendering and to implement custom elements -> implementation detail.