Extra line break added when editing certain content in the legacy editor

XMLWordPrintable

    • 2
    • Severity 3 - Minor

      Issue Summary

      • Some content which only have a single line break, get an extra "<br />" tag added when we enter into edit in the legacy editor.

      Steps to Reproduce

      1. Create a new legacy editor page.
      2. Publish the page with this storage format.
        • <p><span style="color: rgb(51,51,51);">Lorem is not lorem.</span>
          <br style="text-align: left;" /><br />
          <span style="color: rgb(51,51,51);">Lorem is ipsum.</span></p>
          
      3. Notice there's only a single line break.
      4. Edit the page, and notice an extra line break added automatically.
      5. Without making any changes, publish the page and notice the extra line break added to the page as well.
        • <p><span style="color: rgb(51,51,51);">Lorem is not lorem.</span>
          <br style="text-align: left;" /><br /><br />
          <span style="color: rgb(51,51,51);">Lorem is ipsum.</span></p>

      Expected Results

      • Simply editing a page should not add any extra content or line breaks.

      Actual Results

      • Editing a page causes an extra "<br />" tag to be added.

      Workaround

      • Edit the page, and copy and paste the text into a text editor.
      • Remove the extra line in the text editor and paste the text back in.
        • This should clear the problematic HTML/CSS that's triggering the issue.

        1. nice.png
          3 kB
          Sattesh M
        2. not_nice.png
          4 kB
          Sattesh M

            Assignee:
            Unassigned
            Reporter:
            Sattesh M
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: