Difference between revisions of "Template:Toclimit/doc"

From EVE University Wiki
Jump to: navigation, search
m (Docs needs updating)
m (Update doc.)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{update|Standardize the documentation according to the template {{t|documentation}}. [[User:Arin Mara|Arin Mara]] ([[User talk:Arin Mara|talk]]) 06:27, 23 April 2022 (UTC)}}
+
; Description
;Description
+
: This limits the level of heading displayed in the table of contents(TOC).
:This limits the level of heading displayed in the TOC. This uses <nowiki>__TOC__</nowiki>, so the TOC will appear where the heading is.
+
: Due to the way this template functions the TOC will be displayed at the position where this template is placed.
  
;Required CSS
+
; Dependencies
 +
:; Uses
 +
:: {{T|TOC}}
  
:.toclimit-2 .toclevel-1 ul,
+
; Syntax
:.toclimit-3 .toclevel-2 ul,
+
: {{T|Toclimit|limit}}
:.toclimit-4 .toclevel-3 ul,
+
:; Parameters
:.toclimit-5 .toclevel-4 ul,
+
::; limit : Number indicating the highest heading level to show in the table of contents. The lower, the fewer heading levels are shown. Note that in articles, the main level for headings starts at 2 (the article title is H1). Valid values 2 till 6. Defaults to 2.
:.toclimit-6 .toclevel-5 ul,
 
:.toclimit-7 .toclevel-6 ul { display: none; }
 
  
:toclevel-# is standard in all TOCs. toclimit-# is not; it is a div encasing the TOC when this template is used.
+
; Related templates
 +
: {{T|Tocright}}
 +
<!--
 +
; Required CSS
  
;Syntax
+
: .toclimit-2 .toclevel-1 ul,
:{{t|toclimit|limit}}
+
: .toclimit-3 .toclevel-2 ul,
 +
: .toclimit-4 .toclevel-3 ul,
 +
: .toclimit-5 .toclevel-4 ul,
 +
: .toclimit-6 .toclevel-5 ul,
 +
:.toclimit-7 .toclevel-6 ul { display: none; }
  
:limit is the highest level to display. It can be either the first parameter or the <code>limit</code> parameter.<noinclude>
+
: toclevel-# is standard in all TOCs. toclimit-# is not; it is a div encasing the TOC when this template is used.-->
[[Category:Template documentation]]</noinclude>
+
 
 +
<includeonly>[[Category:Link templates]]</includeonly>
 +
<noinclude>[[Category:Template documentation]]</noinclude>

Latest revision as of 17:43, 28 May 2023

Description
This limits the level of heading displayed in the table of contents(TOC).
Due to the way this template functions the TOC will be displayed at the position where this template is placed.
Dependencies
Uses
{{TOC}}
Syntax
{{Toclimit|<limit>}}
Parameters
limit
Number indicating the highest heading level to show in the table of contents. The lower, the fewer heading levels are shown. Note that in articles, the main level for headings starts at 2 (the article title is H1). Valid values 2 till 6. Defaults to 2.
Related templates
{{Tocright}}