[Webkit-unassigned] [Bug 169600] New: innerText setter inserts empty text node if value starts with newline
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Mar 14 06:53:07 PDT 2017
https://bugs.webkit.org/show_bug.cgi?id=169600
Bug ID: 169600
Summary: innerText setter inserts empty text node if value
starts with newline
Classification: Unclassified
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: HTML DOM
Assignee: webkit-unassigned at lists.webkit.org
Reporter: zcorpan at gmail.com
CC: buildbot at hotmail.com, cdumez at apple.com,
commit-queue at webkit.org, darin at apple.com,
d at domenic.me, rniwa at webkit.org, sam at webkit.org
+++ This bug was initially created as a clone of Bug #160971 +++
<!DOCTYPE html>
<body>
<script>document.body.innerText = '\nfoo'</script>
The body will have 3 children (empty text node, <br>, text node "foo"), expect 2 (<br>, text node "foo").
If the assigned value starts with a newline, WebKit/Chromium inserts an empty text node, the spec/Gecko/IE don't.
Spec at https://html.spec.whatwg.org/multipage/dom.html#the-innertext-idl-attribute
Tests: https://github.com/w3c/web-platform-tests/pull/3492
Fail Start with CR assert_not_equals: Should not have empty text nodes got disallowed value ""
Fail Start with LF assert_not_equals: Should not have empty text nodes got disallowed value ""
Fail Start with CRLF assert_not_equals: Should not have empty text nodes got disallowed value ""
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20170314/64d6c425/attachment.html>
More information about the webkit-unassigned
mailing list