Page MenuHomePhabricator

First paragraph after a template transclusion is getting about-grouped
Closed, ResolvedPublic

Description

Author: winne2i

Description:
hovered and edited transclusion

Visible in attachment, while hovering the template [1], when selected [2] and while editing the template [3,4] (there are many more parts named "Content" with further parts of text, splitted where other templates – {{odn}}, {{R}} (both for references) – are inserted).


Version: unspecified
Severity: normal
URL: http://parsoid.wmflabs.org/plwiki/Z%C4%85b_%C4%87wiekowy?oldid=36621127

Attached:

ve05.PNG (2×1 px, 144 KB)

Details

Reference
bz49955

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 1:47 AM
bzimport added a project: Parsoid.
bzimport set Reference to bz49955.

winne2i wrote:

Appears not to be a problem when there's a [[File:…]] between template and paragraph.

Hmm. Parsoid's marking the following paragraph as generated. To investigate.

Arlolra set Security to None.

Here is the processed output of that opening template.

=================================
Szablon:Propozycja
---------------------------------
<table style="" class="metadata plainlinks ambox ambox-notice">
<tr>
<td class="ambox-image">
<div style="width:52px;">[[Plik:Information icon.svg|35px|link=||alt=]]</div></td>
<td class="ambox-text"><center>Artykuł ten został zgłoszony jako kandydat do [[Wikipedia:Artykuły na medal|medalu]].<br>Weź udział w [[Wikipedia:Propozycje do Artykułów na medal/Main Page|dyskusji na ten temat]].</center></td>

</tr></table>
<span style="clear:both;height:0px;line-height:0px;display:block">&nbsp;</span>
[[Kategoria:Propozycje do Artykułów na medal]]

So, the presence of the span with a &nbsp; forces that span to be wrapped in a paragraph. However, since the wiki page does not have a newline after the transclusion and the following content, the paragraph now contains part content from the template and part content from the top-level page. This then forces Parsoid to hoist the entire paragraph into the wrapping.

Two possible ways to fix this:

However, I now see that the current revision of the page uses a different template that doesn't have this problem.

I am not sure there is anything to be done on the Parsoid end here.

ssastry claimed this task.

As noted in the previous comment, there is nothing to be done on the Parsoid end as far as I can tell. Please reopen with more info if there is a fix needed.