Template:Navbox/doc
This template is used to create a basic navigation box. You can do so by calling the template, via the steps under "Syntax", but it is recommended to copy the code verbatim via the steps under "Navbox Creation".
The Navbox template utilizes the NavboxBuilder module. The invoked code can be viewed at Module:NavboxBuilder.
Parameters
Below is the list of all available parameters. At least one list is required for the navbox to show up. Apart from that, all other parameters are optional.
Main
title
– main title of the navbox.links
– links that appear on left side of the title bar.- You can put any wikisyntax here.
title
is required for it to work.
state
– should the navbox be collapsed or expanded by default- Values:
collapsed
orexpanded
(case insensitive) - Empty or unrecognized values will disable collapsing.
title
is required for it to work
- Values:
above
andbelow
– fields above and below sections and images.left_image
andright_image
– fields beside sections, most commonly used to add images.- You can put any content here, not only images.
Sections
Sections include all lists with the same or higher number up to the next section.
header_n
– heading of a section- n – any positive integer
- Requires at least one list to be included to show up
state_n
– should the section be collapsed or expanded by default- n – number of an existing header
- Values:
collapsed
orexpanded
(case insensitive) - Empty or unrecognized values will disable collapsing.
header_state
– same as above, but affects all headers- Values:
collapsed
orexpanded
(case insensitive) - Empty or unrecognized values will disable collapsing.
- Can be overridden by
state_n
- Values:
layout_n
– selects layout for that section- n – any positive integer
- Can be used without
header_n
to create a separate section without a header - Values:
table
orhorizontal
(case insensitive) - Empty or unrecognized values will use default (
table
).
Table layout (table
)
Standard layout with lists and sublists.
left_image_n
andright_image_n
– fields beside sections lists in that section, most commonly used to add images.- n – number of an existing header
- You can put any content here, not only images.
Horizontal layout (horizontal
)
Horizontal layout with lists forming columns. Sublists are not supported and will be treated as regular lists.
per_row_n
– maximum number of lists per row.- n – number of an existing section.
- Value: any number above 1.
- Number of columns is still limited by space needed. You can't go higher than flexbox allows.
span_n
– how many columns should the list span.- n – number of an existing list.
- Value: any number between 0 and corresponding
per_row_n
Lists
list_n
– single row with a list of links- n – any positive integer
group_n
– heading of a list- n – number of an existing list or sublist
Sublists will appear as sub entries of the group with same n.
list_n_m
– single row with a list of links- n and m – any positive integers
group_n_m
– heading of a sublist- n and m – numbers of an existing sublist
Styling
navbox_class
andnavbox_style
– applied to the main navbox elementtitle_class
andtitle_style
– applied to the title barbase_class
andbase_style
– applied to all groups, subgroups, headers, above and below fieldsabove_class
andabove_style
– applied to the above fieldbelow_class
andbelow_style
– applied to the below fieldimage_class
andimage_style
– applied to all image fieldsleft_image_class
andleft_image_style
– applied to the main left image fieldright_image_class
andright_image_style
– applied to the main right image fieldheader_class
andheader_style
– applied to all headersheader_n_class
andheader_n_style
– applied to the header specified with nleft_image_n_class
andleft_image_n_style
– applied to the left image field in the section specified with nright_image_n_class
andright_image_n_style
– applied to the right image field in the section specified with ngroup_class
andgroup_style
– applied to all groupssubgroup_class
andsubgroup_style
– applied to all subgroupsgroup_n_class
andgroup_n_style
– applied to the group specified with ngroup_n_m_class
andgroup_n_m_style
– applied to the subgroup specified with n and mlist_class
andlist_style
– applied to all listslist_n_class
andlist_n_style
– applied to the list specified with nlist_n_m_class
andlist_n_m_style
– applied to the list specified with n and m