Template:TOC top: Difference between revisions

Nothing to hide, but nothing to show you either.
Jump to navigation Jump to search
Content added Content deleted
(boilerplate)
 
m (30 revisions imported from wikipedia:Template:TOC_top)
 
(29 intermediate revisions by 16 users not shown)
Line 1: Line 1:
<includeonly>__NOTOC__<table class="toc plainlinks" id="toc" {{#if:{{{align|}}}|align="{{{align}}}"}}>
{{#ifeq:{{{primary|}}}|false||__NOTOC__}}<div role="navigation" aria-labelledby="toc-title-text" class="toc plainlinks hlist" {{#ifeq:{{{primary|}}}|false||id="toc"}} style="{{#switch:{{lc:{{{align|}}}}}
|left=float: left; clear: {{{clear|left}}};
<tr>
|right=float: right; clear: {{{clear|right}}};
<td>
|center= margin:auto; clear: {{{clear|none}}};
<div id="toctitle">
|#default=clear: {{{clear|left}}};
<h2>Contents</h2>
}}">
</div>
<div {{#ifeq:{{{primary|}}}|false|style="text-align:center"|class="toctitle"}}>{{#ifeq:{{{primary|}}}|false|<strong role="heading" id="toc-title-text">{{{title|{{MediaWiki:Toc}} }}}</strong>|<h2 id="toc-title-text">{{{title|{{MediaWiki:Toc}} }}}</h2>}}
<div><div class="hlist" style="margin: auto"></includeonly><noinclude>{{doc|content=
</div><noinclude>

{{TOC bottom}}
This is used to create custom table of contents templates such as {{tl|list TOC}}.
{{documentation}}</noinclude>

Please note that this is '''solely for ease of maintaining existing templates'''. Please '''do not use this to write new templates''': instead, browse through [[:category:Wikipedia table of contents templates]] and use an existing template. This code is one of the final pieces in cleaning up years of redundant and overlapping code in this area.

== See also ==

* {{tl|TOC bottom}}

[[category:Wikipedia table of contents templates]]
}}</noinclude>

Latest revision as of 11:05, 22 June 2021