Page MenuHomePhabricator

Table in fosterable position doesn't round-trip
Closed, DeclinedPublic

Description

Tested with selser:

curl 'http://localhost:8000/mediawikiwiki/User%3AGWicke%2FTest%2FTableFoster?oldid=846340' | sed s/Foo/Fooo/g > /tmp/test.html
curl --data-urlencode "html@/tmp/test.html" -d 'oldid=846340' http://localhost:8000/mediawikiwiki/User%3AGWicke%2FTest%2FTableFoster

Fooo                                                                                              
                                                                                                 
{||}                                                                                             
{||}                                                                                             
                                                                                                 
Bar

A possible scheme discussed on IRC is this:

  1. Give the first empty (broken-up) table a zero-width dsr, similar to fostered content. The broken-up table will always be empty as other content would first be fostered out of the table itself.
  1. Give the nested (surviving) table the full dsr width of both tables, with start/end tag widths inflated to include the outer table

The net effect should be:

  • clean round-tripping with selser when the table content is not edited (yay!)
  • stripping of the broken empty table when the table is edited

Not sure how complicated this is to implement.


Version: unspecified
Severity: normal

Details

Reference
bz58730

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 2:38 AM
bzimport added a project: Parsoid.
bzimport set Reference to bz58730.
Arlolra set Security to None.

I think we have linting for wikitext like this and it is better to fix that.