Jump to content

Template:Template category/doc

From Wikipedia

{{Template category}} suppose dey put for top of categories wey contain template pages and their related subcategories. Dis template dey fill Category:Wikipedia template categories.

How to use am

[edit source]

Syntax

[edit source]
Basic
{{Template category
|description=
}}
Basic topical
Syntax of {{Template category}}
No typeNavboxSidebarStub
{{Template category
|topic=
}}
{{Template category
|type=navbox
|topic=
}}
{{Template category
|type=sidebar
|topic=
}}
{{Template category
|type=stub
|topic=
}}
Full
{{Template category
| onright = 
| type = 
| container = 
| topic = 
| description = 
| ALTTEXT = 
| help = 
}}

Parameters and examples

[edit source]

You fit use dis template without any parameters.

Template:Hidden begin

Template:Hidden end

But di following ones fit make di template give more information:

onright

[edit source]

Use onright (or rhs) to put right-aligned boxes beside di template, like {{Portal}} (to give links to related portals), {{Commons category}} (to give link to same or similar Commons category), and others. If more than one box dey used, make sure di widest one come first (see example below), otherwise dem fit overlap.

Template:Hidden begin

{{Template category
| topic = di [[United States]]
| onright = {{Commons category|United States|di United States}}{{Portal|United States}}
}}

Template:Portal

Template:Hidden end


Setting type to any of these values go add one ready-made note explaining which type of template di category (but not necessarily di subcategories) suppose contain. Di values be:
  • ambox
  • campaignbox
  • (category header
  • category heading
  • catheader
  • cat header
  • cathead)
  • conversion
  • external link
  • formatting
  • function
  • infobox
  • message
  • meta
  • module
  • (navigation
  • navigational
  • navbox)
  • sidebar
  • stub
  • sub
  • timeline
  • (user
  • userbox)
If type be set to something wey no dey inside these values, di default note "Di pages listed in this category be templates" go show without change.

Template:Hidden begin

{{Template category |type=sidebar}}

Template:Hidden end

container

[edit source]

Set container as true, yes, etc. to show say di category be a container category, meaning say di category suppose contain only subcategories. A note go dey added to tell people make dem no add templates to di template category. Di category go automatically enter Category:Container categories.

Template:Hidden begin

{{Template category |container=true}}

Template:Hidden end

Another way instead of using container be to put {{Container category}} after di {{Template category}} template:

Template:Hidden begin

{{Template category
| type = ''type''
| topic = ''[[topic]]''
| description = Dis text come from di ''description'' parameter.
}}
{{Container category}}

Template:Container category

Template:Hidden end


Use topic to add default description wey end with "...relating to topic". Usually topic be one wikilink to di main article connected to di category. Example: United States for Category:United States templates.

Template:Hidden begin

{{Template category |topic=di [[United States]]}}

Template:Hidden end

Template:Hidden begin

{{Template category |type=infobox |topic=di [[United States]]}}

Template:Hidden end

description

[edit source]

Use description if you want custom description instead of — or if you also use topic, after — di default description above.

Template:Hidden begin

{{Template category
| type = navbox
| topic = [[China]]
| description = <br />{{small|For templates wey relate specially to di [[People's Republic of China|People's Republic of China (PRC)]] or di current [[Taiwan|Republic of China (ROC, "Taiwan")]], see respectively {{c|People's Republic of China templates}} and {{c|Taiwan templates}}.}}
}}

Template:Hidden end

Template:Hidden begin

{{Template category |description=Dis text come from di ''description'' parameter.}}

Template:Hidden end


Use help to replace di instruction wey dey tell people how to add template to category (di second paragraph of "Further template category notes" section):

Template:Hidden begin

{{Template category |help=Dis text come from di ''help'' parameter.}}

Template:Hidden end

To remove di default instructions, set help to no:

Template:Hidden begin

{{Template category |help=no}}

Template:Hidden end

Tracking category

[edit source]

Uses wey get topic or description parameter dey tracked:

TemplateData

[edit source]
This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. See a monthly parameter usage report for Template:Template category in articles based on its TemplateData.

TemplateData for Template category

Dis template dey work as header for category pages wey contain templates.

Template parameters

ParameterDescriptionTypeStatus
onrightonright rhs

no description

Unknownoptional
typetype

no description

Suggested values
ambox campaignbox category header conversion external link formatting function infobox meta module navigation sidebar stub sub timeline user
Stringoptional
E be container category?container

Whether di category be a "container category" wey suppose only contain subcategories.

Booleanoptional
topictopic

no description

Unknownoptional
descriptiondescription 1

no description

Unknownoptional
ALTTEXTALTTEXT

no description

Unknownoptional
helphelp 2

no description

Unknownoptional
categorycategory

no description

Unknownoptional

See also

[edit source]

Template:Other category-header templates