Page MenuHomePhabricator

Cannot create multi-paragraph citations using the visual editor
Open, LowPublic

Description

In the wikitext editor, the only way to create multi-paragraph citations is to explicitly wrap the paragraphs in <p> tags. Any line breaks in the source are silently dropped from read mode.

In the visual editor, you can place line breaks within a citation simply by hitting return. After you add them, they will display in both the citation inspector and the citation list. If you open a page which has a preexisting citation with linebreaks, the linebreaks will not display in the citation inspector and will display as arrow characters (↵) in the citation list.

Screen Shot 2015-07-24 at 12.03.28.png (462×465 px, 46 KB)

In both cases, the breaks will not display at all in read mode.

We should either:

  1. prevent the user from entering line breaks in basic citation dialog, or
  2. preserve any line breaks the user does enter using <p> tags.

Personally, I lean towards 2.

Details

Reference
bz57078

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 2:41 AM
bzimport set Reference to bz57078.

Created attachment 13800
reference editor

Attached:

Screen_Shot_2013-11-14_at_12.47.02_PM.png (508×801 px, 31 KB)

ARRRGH. So it turns out that double newlines to create a new paragraph don't work in references, in neither the PHP parser nor in Parsoid. So something like <ref>Foo\n\nBar</ref> actually renders as 1: Foo bar.

So, what do we do? Disallow the creation of multi-paragraph references?

nshahquinn-wmf renamed this task from VisualEditor: Disallow the creation of multi-paragraph references to Cannot create multi-paragraph citations using the visual editor.Jul 24 2015, 7:06 PM
nshahquinn-wmf lowered the priority of this task from Medium to Low.
nshahquinn-wmf updated the task description. (Show Details)
nshahquinn-wmf set Security to None.