https://bugzilla.wikimedia.org/show_bug.cgi?id=71473

            Bug ID: 71473
           Summary: <small> leaks out of <li>
           Product: Parsoid
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: Unprioritized
         Component: General
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected]
       Web browser: ---
   Mobile Platform: ---

(See https://en.wikipedia.org/wiki/User:Cscott/Sandbox#Leaky_LI).

Parser test cases:

!! test
Leaky <li> (1)
!! options
parsoid=wt2html
!! wikitext
<ol>
<li>a<small>b</li>
<li>c</li>
</ol>
!! html/php+tidy
<ol>
<li>a<small>b&lt;/li&gt;</small></li>
<li><small>c</small>
<p><small>&lt;/ol&gt;</small></p>
</li>
</ol>
!! html/parsoid
<ol>
<li>a<small>b</small></li>
<small>
<li>c</li>
</small></ol>
!! end

Not sure we want to emulate the &lt;/li&gt; part of the above output, but it
does seem odd that the <small> tag "escapes" and surrounds the <li>, rather
than surrounding the *content* of the <li>.


Similarly:

!! test
Leaky <li> (2)
!! options
parsoid=wt2html
!! wikitext
== Leaky LI ==
<li>A
<li>B <small> C
<li>D

== Next Heading ==
x
!! html/php+tidy
<h2><span class="mw-headline" id="Leaky_LI">Leaky LI</span><span
class="mw-editsection"><span class="mw-editsection-bracket">[</span><a
href="/index.php?title=Parser_test&amp;action=edit&amp;section=1" title="Edit
section: Leaky LI">edit</a><span
class="mw-editsection-bracket">]</span></span></h2>
<ul>
<li>A</li>
<li>B <small>C</small></li>
<li><small>D</small></li>
</ul>
<h2><small><span class="mw-headline" id="Next_Heading">Next Heading</span><span
class="mw-editsection"><span class="mw-editsection-bracket">[</span><a
href="/index.php?title=Parser_test&amp;action=edit&amp;section=2" title="Edit
section: Next Heading">edit</a><span
class="mw-editsection-bracket">]</span></span></small></h2>
<p>x</p>
!! html/parsoid
<h2>Leaky LI</h2>
<li>A</li>
<li>B <small> C</small></li>
<li><small>D
<h2>Next Heading</h2>
<p>x</p>
</small></li>
!! end

Here the <small> isn't around the <li> (that's an improvement, although a
mysterious one).  But the trailing <li> has swallowed up the <h2>, which surely
isn't right.

May be related to bug 71185.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to