Visual editor: issues with removing leading space pre blocks


When a page with blocks of pre-formatted text that use the leading space in wikitaxt is edited in Visual Editor there are various issues trying to remove the pre-formatted blocks. can be used for testing.

  • It is not possible to delete a block on the first line of a page
  • When the pre-formatted block follows a mutli-line template, that template is deleted and the contents of the pre-formatted block becomes normal text on the line above where the template as, appended to any text that was already there.
  • When the pre-formatted block follows a normal line of text or a single line template the contents of the block are appended to the end of that line.
  • When the block follows indented text, the contents are appended to the last line of the indented block, even if that is a line that doesn't exist in wikitext (see bug 50995)
  • When the block follows an ordered or unordered list, the text is appended to the last line of the last item in the list

*When the block follows an image, the contents are appended to the image caption. This is probably depends on bug 51624 and so I would expect the same behaviour with tables, but I have not tested that.
*If the block follows another pre-formatted block, the contents gets appended to the end of that block.

In all cases this can be worked around by inserting and then backspacing a new line at the start of the block.

In cases when there is a line of normal text, a blank line or a single line template before the pre-formatted block then pressing delete at the end of that line appends the contents of the block at the cursor position as normal text.

The differing behaviour of single and multi-line templates may be related to bug 51708

Version: unspecified
Severity: normal

bzimport set Reference to bz51758.
Thryduulf created this task.Via LegacyJul 20 2013, 7:13 PM
Spinningspark added a comment.Via ConduitSep 8 2013, 3:36 PM

In this edit the multiple leading spaces of a pre-formatted block have been removed while a totally unrelated line was being edited. The edit summary gives no indication that this was done deliberately so I am assuming this was the result of a bug in VisEd.

Add Comment

Column Prototype
This is a very early prototype of a persistent column. It is not expected to work yet, and leaving it open will activate other new features which will break things. Press "\" (backslash) on your keyboard to close it now.