Page MenuHomePhabricator

Headings in transclusion break after saving
Closed, ResolvedPublic

Description

  1. Edit a page that transcludes a template that provides a heading (e.g. https://www.mediawiki.org/w/index.php?title=Project:Sandbox&oldid=1886644&veaction=edit or https://wikitech.wikimedia.org/w/index.php?title=static.wikipedia.org&oldid=46977&veaction=edit)
  2. Put cursor in the "Insert paragraph" placeholder above this transclusion.
  3. Now Insert a template (e.g. template "Note" on mediawiki.org, or template "Doc-old" on wikitech)
  4. Observe how the preview looks (no issues)
  5. Save

Actual result:

Page renders as Note:==Heading== Content here. where the heading syntax is no longer parsed because it must be on a new line.

This is due to the template not being considered to be on its own line when the DOM is serialised by Parsoid.

Event Timeline

Krinkle raised the priority of this task from to Needs Triage.
Krinkle updated the task description. (Show Details)
Krinkle subscribed.
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Jdforrester-WMF moved this task from To Triage to Freezer on the VisualEditor board.
Jdforrester-WMF set Security to None.
ssastry claimed this task.
ssastry subscribed.

This seems fixed now.