Template:topic cat
This template should be used on pages in the Category: namespace, and automatically generates descriptions and categorization for categories of a recognized type (see below). It is implemented by Module:category tree and its submodule Module:category tree/topic cat. It is preferable not to invoke this template directly, but to simply use {{auto cat}}
(with no parameters), which will automatically invoke this template on appropriately-named category pages.
- The following documentation is located at Template:topic cat/documentation. [edit]
- Useful links: subpage list • links • redirects • transclusions • errors (parser/module) • sandbox
This template automatically generates descriptions and categorization for categories whose name follows the format "(language code):(label)" and "(label)".
Parameters
|1=
- The language code (see Wiktionary:Languages) of the language that the category name begins with, and which the category's contents belongs to. Leave this empty for categories that do not start with a language code.
|2=
- The label of the category. This is the part of the category name that follows the language code.
- Note
This template can now figure out any missing parameters from the name of the category, but parameters which are included must be correct.
Examples
- On Category:en:Sciences:
{{topic cat|en|Sciences}}
or{{topic cat}}
- On Category:Sciences:
{{topic cat||Sciences}}
or{{topic cat}}
- On Category:fr:All topics:
{{topic cat|fr|All topics}}
or{{topic cat}}
Adding, removing or modifying categories
The information on each label for this template is contained in Module:category tree/topic cat/data and its submodules. For a list of all data modules, see Category:Category tree data modules/topic cat.
TemplateData
TemplateData for topic cat
Provides information about the topic of a category, such as Category:Sciences or Category:en:Light sources
Parameter | Description | Type | Status | |
---|---|---|---|---|
language code | 1 | The language code of the language that the category name begins with, and which the category's contents belongs to. Leave this empty for categories that do not start with a language code. | Unknown | required |
label | 2 | The label of the category. This is the part of the category name that follows the language code. | Unknown | required |