Template:Decade years navbox/doc
Jump to navigation
Jump to search
This template can be used to create a year navigation box for year categories. Please consider before creating new year categories – there should exist a comprehensive topical categorization for the subject first.
Usage
{{Decade years navbox |header= |decade= |cat_prefix= |cat_suffix= }}
Template parameters
Parameter | Description | Default | Status | |
---|---|---|---|---|
header | The text before the list of years, describing the subject (often wikilinked to a non-year-specific page). | empty | required | |
decade | The decade with 1–3 digits. E.g. 202 for the 2020s. | empty | required | |
cat_prefix | Text in category name before the year | empty | optional | |
cat_suffix | Text in category name after the year | empty | optional | |
displayredlinks | Red links are displayed by default. Set displayredlinks=no to hide them. Use displayredlinks=minmax if you want to set the first and/or last year to be displayed. Or displayredlinks=maybe to hide non-existent or empty categories.Using displayredlinks=maybe should better not be used at all: it is costly, slow, unstable, causing existing categories to be hidden when they can have new members at any time (interacts badly with page caches, which can also be extremely long to reflect changes in counters of category members in order to refresh the page; additionally these counters are just estimations that may be corrected after many months, by admins performing special SQL requests to maintain the internal database). You should better usedisplayredlinks=no instead to avoid this problem. | yes | optional | |
minyear | The first year to be displayed with 4 digits. Requires displayredlinks=minmax to be set. | empty | optional | |
maxyear | The last year to be displayed with 4 digits. Requires displayredlinks=minmax to be set. If you want the current year to be the last year displayed, use maxyear={{CURRENTYEAR}} . | empty | optional | |
style | additional CSS | empty | optional | |
padding | character(s) used to wrap the year in the category links. It is a regular space ( ) by default. May be set to an empty string, if the affixes are to wrap the years closely in brackets or other punctuation, like a '/' for subpages (you can still append ' ' to cat_prefix or prepend ' ' to cat_suffix, if you need an explicit space in only one of them, because the named parameters for affixes have their unencoded whitespaces implicitly trimmed). | ' ' | optional |
Additional information
The template is intended to be used in the following namespaces: the Category namespace
The template is intended to be used by the following user groups: all users
See also