Page MenuHomePhabricator

Empty elements in DOM: PHP parser+tidy strips them; Parsoid doesn't
Closed, DeclinedPublic

Description

The infobox in itwiki:Luna has several empty rows "....|-\n|-\n....". PHP parser + Tidy combo strips them whereas Parsoid doesn't. This causes rendering visual diffs on itwiki:Luna

Reproducible with a simple test case: "{|\n|-\n|-\n|-\n|foo\n}"

What is the right behavior here?


Version: unspecified
Severity: normal

Details

Reference
bz67452

Related Objects

Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 22 2014, 3:29 AM
bzimport added a project: Parsoid.
bzimport set Reference to bz67452.
ssastry created this task.Jul 3 2014, 4:32 AM

This patch is now merged .. the only remaining issue are empty elements found in top-level content. We are going to leave them behind for now so that editors can edit them in VE (rather than hide them and make them uneditable) and maybe delete them.

Arlolra raised the priority of this task from Lowest to Normal.Nov 25 2014, 8:20 PM
Arlolra added a subscriber: Arlolra.
ssastry moved this task from Backlog to Robustness on the Parsoid board.Dec 22 2014, 12:36 AM
marcoil moved this task from Robustness to Backlog on the Parsoid board.Feb 13 2015, 12:48 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 13 2015, 4:50 PM
ssastry closed this task as Declined.Apr 20 2018, 4:26 PM

Tidy was responsible for this. RemexHtml doesn't. At this point, both RemexHtml and Parsoid leave empty elements behind but tag empty trs and lis with a mw-empty-elt css class for skins to suppress them.