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

           Summary: Template reference can't be indented, indent in
                    template breaks numbering
           Product: MediaWiki
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: Normal
         Component: Page rendering
        AssignedTo: [email protected]
        ReportedBy: [email protected]


Sample Template T
==================
{| style="width: 85%; margin-left: border-collapse: collapse; background:
#FBFBFB; border: 1px solid #aaa; border-left: 10px solid #ffb400;"
|
'''Note:''' {{{1}}}
|}
<noinclude>
----
This template is used for a highlighted note.
;Usage: 
:<tt><nowiki>{{Tip|1}}</nowiki>
::<nowiki>{{1}}</nowiki> = Text of the tip</tt>
</noinclude>

The goal is to transclude that template into a numbered list, to produce:

  1. Item A

     Text

  2. Item B


A. Template with no indent
==========================
If T does not contain indentation, an attempt to indent a reference to it fails
to indent properly, and breaks list numbering.

So
--
#Item A
#:{{T| Text}}
#Item B

Produces:
--------
  1. Item A

text

  1. Item B 


B. Template includes list indentation (#:{| style=...)
======================================================
If the template includes indentation using "#:", it simply breaks. 

(That would be brittle in any case, as it would require different versions of
the template for different indents, with each list type.)


C. Template includes double indent (::{| style=...)
===================================================
If the template includes indentation using "::", the transclusion appears in
the correct place, but list numbering is broken.

So
--
#Item A
#:{{T| Text}}
#Item B

Produces
--------
  1. Item A

     Text

  1. Item B

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
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