Jump to content

Template:TOCfloat: Difference between revisions

added note that the template doesn't do anything now
(forgot to update end of doc)
(added note that the template doesn't do anything now)
 
Line 1: Line 1:
<includeonly><div style="clear:left; margin-bottom:0.5em; float:{{{side|left}}}; padding:0.5em 1.4em 0.8em 0; background:none; width:{{{width|auto}}};" class="{{#ifeq:{{{numbers}}}|no|nonumtoc}} {{#if:{{{limit|}}}|toclimit-{{{limit}}}}}">__TOC__</div></includeonly><noinclude>Especially for articles which do not need a [[wp:WP:LEDE|lede]], a long table of contents (TOC) can be visually unsettling – "Hey, where's the article? There's just this long box!" Use this template to make the TOC a floating table, so that the article text wraps around it. Now, sometimes a long TOC is the best approach, as in [[Quotes/Speech]] where we want the reader to be able to choose from the full directory of conversations in the game without any distracting text to the right. But for a more normal article like [[Daodan DLL]] it would look bad if the article didn't start until after the lengthy TOC.
<includeonly><div style="clear:left; margin-bottom:0.5em; float:{{{side|left}}}; padding:0.5em 1.4em 0.8em 0; background:none; width:{{{width|auto}}};" class="{{#ifeq:{{{numbers}}}|no|nonumtoc}} {{#if:{{{limit|}}}|toclimit-{{{limit}}}}}">__TOC__</div></includeonly><noinclude>{{fmbox
  | text = This template used to be handy, but it does not do anything when using a skin that puts the TOC in the lefthand margin beside the content instead of embedding the TOC in the article. This includes Vector 2022, which was made the default skin for the wiki in 2025.
  }}
 
Especially for articles which do not need a [[wp:WP:LEDE|lede]], a long table of contents (TOC) can be visually unsettling – "Hey, where's the article? There's just this long box!" Use this template to make the TOC a floating table, so that the article text wraps around it. Now, sometimes a long TOC is the best approach, as in [[Quotes/Speech]] where we want the reader to be able to choose from the full directory of conversations in the game without any distracting text to the right. But for a more normal article like [[Daodan DLL]] it would look bad if the article didn't start until after the lengthy TOC.


See the [[Template:TOClimit|TOClimit]] template if you just want to omit lower-level section headers from the TOC, but note that this TOCfloat template does perform the same function if you use the "limit" parameter. See the [[Template:TOCnonum|TOCnonum]] template if you just want to omit automatic numbering from the TOC, but note that TOCfloat also offers the parameter "numbers=no" for this purpose.
See the [[Template:TOClimit|TOClimit]] template if you just want to omit lower-level section headers from the TOC, but note that this TOCfloat template does perform the same function if you use the "limit" parameter. See the [[Template:TOCnonum|TOCnonum]] template if you just want to omit automatic numbering from the TOC, but note that TOCfloat also offers the parameter "numbers=no" for this purpose.