[Webkit-unassigned] [Bug 127690] New: execCommand('insertHTML', ...) creates nested paragraphs under very specific circumstances

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jan 27 11:04:55 PST 2014


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

           Summary: execCommand('insertHTML', ...) creates nested
                    paragraphs under very specific circumstances
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Macintosh
               URL: http://jsbin.com/OKuXiCA/1/edit
        OS/Version: Mac OS X 10.9
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: HTML Editing
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: tim at timmolendijk.nl


Steps to reproduce the problem:
1. Open provided URL
2. Click button to execute code as described on its label
3. Notice how a nested paragraph structure has been created (and the first inserted paragraphs ends up last in the created DOM tree - but that's probably related)

What is the expected behavior?
What Firefox does: create a DOM tree that looks like this:
<p>1st inserted</p>
<p><br></p>
<p><br></p>

What went wrong?
Instead it creates a DOM tree that looks like this:
<p><p></p></p>
<p>1st inserted</p>

Does it occur on multiple sites: Yes

Is it a problem with a plugin? No 

Did this work before? N/A 

Does this work in other browsers? No Safari (verified v7.0.1)

Chrome version: 34.0.1797.2  Channel: dev
OS Version: OS X 10.9.1
Flash Version: Shockwave Flash 12.0 r0

As soon as a layout is applied to all paragraphs, this misbehavior disappears. Or when the br element is removed from the initial contenteditable, this misbehavior disappears. And probably several more subtle requirements that I haven't discovered.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list