Page MenuHomePhabricator

Minor P-wrapping diff between Parsoid & PHP Parser+Tidy combo
Closed, ResolvedPublic


In this snippet,


the PHP parser + Tidy combo doesn't wrap the image in a p-tag. Parsoid wraps it in a p-tag. This then introduces a small whitespace rendering diff in the infobox -- this might be the source of several of the visual diffs seen in infoboxes where there is a leading image.

This could potentially also go away when Tidy goes away. Might not be worth fixing right yet.

Related Objects

Event Timeline

ssastry created this task.Aug 19 2015, 10:49 PM
ssastry updated the task description. (Show Details)
ssastry raised the priority of this task from to Normal.
ssastry added a project: Parsoid.
ssastry added a subscriber: ssastry.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 19 2015, 10:49 PM
Arlolra added a subscriber: Arlolra.Jun 7 2018, 2:23 PM

A simpler test case is,


This is similar to the tests around "Paragraphs inside blockquotes/divs (no extra line breaks)"

where the comment will say,

## This is a corner case interaction between the paragraph wrapping in the
## php parser's BlockLevelPass and Remex.  `doBlockLevels` has a notion of
## some tags which close paragraphs (and thus prevent wrapping on their line),
## of which "div" is one, but do p-wrapping inside them.  These are referred
## to as "never suppressing".  Remex, for its part, doesn't traverse into
## "div"s to p-wrap.  Hence, we only get this partial wrapping.
Arlolra closed this task as Resolved.Jul 23 2018, 5:06 PM
Arlolra claimed this task.

The Parsoid and Remex outputs now match