[Webkit-unassigned] [Bug 154676] New: Webkit adds multiple   to HTML pasted into contenteditable element.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Feb 25 07:02:38 PST 2016


https://bugs.webkit.org/show_bug.cgi?id=154676

            Bug ID: 154676
           Summary: Webkit adds multiple   to HTML pasted into
                    contenteditable element.
    Classification: Unclassified
           Product: WebKit
           Version: Safari 9
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: HTML Editing
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: j.swiderski at cksource.com

Created attachment 272201
  --> https://bugs.webkit.org/attachment.cgi?id=272201&action=review
Sample page which shows how browsers sees HTML.

Safari Version       : 9.0.3 (11601.4.4)
Other browsers tested: 
     Chrome: Fail, version: 48.0.2564.116 m
    Firefox: OK 
         IE: OK
----

What steps will reproduce the problem?
1. Open attached sample in a browser.
2. Go to https://en.wikipedia.org/wiki/HTTPS and copy first paragraph (from HTTPS to https://en.wikipedia.org/wiki/HTTPS)
3. Paste it in editable element, click the "Get HTML" button and observe what HTML gets produced.

----

What is the expected result?

The expected HTML is without   being inserted before closing and after opening span tag.

If I go to https://en.wikipedia.org/wiki/HTTPS and execute below in console everything seems to be in order 
console.log(document.getElementById('mw-content-text').getElementsByTagName('p')[0].innerHTML);
Also viewing HTML with dev-tools doesn't show any  

----

What happens instead?

There are &nbsp being inserted before closing and after opening span tag.


Please provide any additional information below. Attach a screenshot if possible.
I have tested this on Windows 7 and Mac 10.11

-- 
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/20160225/c61bd19b/attachment.html>


More information about the webkit-unassigned mailing list