attributeChangedCallback gets "" for the namespace URI when it should be null |
||||||||
Issue descriptionChrome appears to pass empty strings instead of null for old values (when adding) or new values (when removing.) See: https://dom.spec.whatwg.org/#concept-element-attributes-append https://dom.spec.whatwg.org/#concept-element-attributes-remove
,
Sep 1 2016
,
Sep 2 2016
,
Sep 2 2016
,
Sep 2 2016
,
Sep 2 2016
Note that DOM says attribute namespaces are null, or a non-empty string: https://dom.spec.whatwg.org/#concept-attribute-namespace Chrome passes an empty string, not null, when there is no namespace. This causes a number of WebKit's tests to fail: LayoutTests/fast/custom-elements/attribute-changed-callback.html.
,
Sep 2 2016
I notice we have to tests for namespaced attributes, either.
,
Sep 2 2016
,
Sep 4 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/d39405eee528d5cec4edcb6dd9abfdc83b897fe8 commit d39405eee528d5cec4edcb6dd9abfdc83b897fe8 Author: dominicc <dominicc@chromium.org> Date: Sun Sep 04 00:11:52 2016 Pass null to attributeChangedCallback when there's no namespace URI The DOM spec says attribute namespaces may be null, or non-empty [1]. We should accurately transmit those nulls to the attributeChangedCallback [2]. We were converting null to empty string. This also adds a test that non-null namespaces are transmitted, too. [1] https://dom.spec.whatwg.org/#concept-attribute-namespace [2] https://dom.spec.whatwg.org/#concept-element-attributes-change , etc. BUG= 643046 Review-Url: https://codereview.chromium.org/2303663004 Cr-Commit-Position: refs/heads/master@{#416458} [modify] https://crrev.com/d39405eee528d5cec4edcb6dd9abfdc83b897fe8/third_party/WebKit/LayoutTests/custom-elements/spec/callback.html [modify] https://crrev.com/d39405eee528d5cec4edcb6dd9abfdc83b897fe8/third_party/WebKit/LayoutTests/custom-elements/spec/upgrade-element.html [modify] https://crrev.com/d39405eee528d5cec4edcb6dd9abfdc83b897fe8/third_party/WebKit/Source/bindings/core/v8/ScriptCustomElementDefinition.cpp
,
Sep 7 2016
|
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by davaajav@google.com
, Sep 1 2016