SVG element names lowercased |
||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2746.0 Safari/537.36 Steps to reproduce the problem: 1. Go to "data:text/html,<svg><feComposite>" 2. Open dev tools, expand all elements What is the expected behavior? There is an "feComposite" element within the "svg" element What went wrong? There is an "fecomposite" element within the "svg" element (note the lowercase). Did this work before? N/A Chrome version: 53.0.2746.0 Channel: canary OS Version: OS X 10.11.5 Flash Version: Shockwave Flash 22.0 r0 document.body.firstChild.firstChild.tagName and document.body.firstChild.firstChild.localName both give the correctly camel-cased version.
,
May 23 2016
We change all tag names to the lower case when displaying in DevTools. Is that an issue for you? Can you add more details on how this affects you?
,
May 23 2016
I think it's definitely an issue: I was having problems with SVG filters not applying, and when I looked in the devtools to make sure they were in the tree I found my feComposite elements weren't feComposite elements after all, but rather fecomposite elements, which would explain why the filters weren't working as I expected. I then spent half an hour trying to work out why Chrome was lowercasing the elements, before eventually realising only the devtools were. I'd expect the element name in the devtools to match el.prefix === null ? el.localName : el.prefix + ":" + el.localName
,
May 24 2016
Yes, it makes a lot more sense to take advantage of the case-canonicalization the platform already does via `el.localName`, and not try to create home-grown lowercasing code which fails in important cases like this one.
,
May 24 2016
Note that Elements panel predates el.localName by quite a while. We'll look into using localName though, thanks for suggestion.
,
May 24 2016
FWIW, el.localName has been around since⦠forever. Certainly I don't remember it ever not existing; I'm pretty sure it goes all the way back to pre-fork KHTML. The only "newness" is it getting moved from Node.prototype to Element.prototype, but that makes no difference to its availability on elements.
,
Jun 20 2016
,
Jun 21 2016
,
Jun 27 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/eaaec7148620764d61412022338beebb69ad61d5 commit eaaec7148620764d61412022338beebb69ad61d5 Author: einbinder <einbinder@chromium.org> Date: Mon Jun 27 21:49:05 2016 DevTools: Don't lowercase SVG and other XML-like elements BUG= 614171 Review-Url: https://codereview.chromium.org/2087653003 Cr-Commit-Position: refs/heads/master@{#402301} [add] https://crrev.com/eaaec7148620764d61412022338beebb69ad61d5/third_party/WebKit/LayoutTests/inspector/elements/elements-panel-correct-case-expected.txt [add] https://crrev.com/eaaec7148620764d61412022338beebb69ad61d5/third_party/WebKit/LayoutTests/inspector/elements/elements-panel-correct-case.html [modify] https://crrev.com/eaaec7148620764d61412022338beebb69ad61d5/third_party/WebKit/Source/devtools/front_end/sdk/DOMModel.js
,
Jun 27 2016
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by eostroukhov@chromium.org
, May 23 2016Owner: dgozman@chromium.org
Status: Assigned (was: Unconfirmed)