Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-48905

atto_outdent removes blockquote tags

XMLWordPrintable

    • MOODLE_29_STABLE, MOODLE_31_STABLE
    • MDL-48905-master
    • Hide
      1. Run behat with @atto_indent
      2. Setup a page with various levels of indents inserted with atto editor indent button (include some lists)
      3. Add block quotes into the source using HTML source button at various levels of indents and save.
      4. In variety of browsers, go to your page and use the outdent button
      5. Verify that only editor indents are removed, not blockquotes.
      6. View HTML source and check that no empty or extra classes added or empty attributes are added.
      Show
      Run behat with @atto_indent Setup a page with various levels of indents inserted with atto editor indent button (include some lists) Add block quotes into the source using HTML source button at various levels of indents and save. In variety of browsers, go to your page and use the outdent button Verify that only editor indents are removed, not blockquotes. View HTML source and check that no empty or extra classes added or empty attributes are added.

      If you have HTML which contains an indented blockquote tag (the blockquote being inside the indent), then atto's outdent removes the blockquote before it removes the outdent.

      This is because all indents are converted to blockquotes, and then the outdent execCommand is called, which removes the inner-most blockquote tag. We then convert the remaining blockquotes back to divs.

      With Chrome this also will destroy div elements that have been inserted. For example include this HTML

      <div class="editor-indent" style="margin-left: 30px;"><div><p>paragraph one</p></div><div><p>paragraph two</p></div><div><p>paragraph three</p></div></div>

      Select one or more lines and outdent.
      Expected behaviour: Comple div element is outdented (indent removed)
      Actual behaviour: Div is removed from selected lines, only selected lines are outdented, inconsistent formating is applied.

            dthies Daniel Thies
            dobedobedoh Andrew Lyons
            Frédéric Massart Frédéric Massart
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.