User:Donni Iris/Sandbox/Template Navbox/doc

From Project Gorgon
Revision as of 16:17, 21 April 2026 by Donni Iris (talk | contribs) (wholesale yoink from mirheze)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Template:Dependencies Template:Uses TemplateStyles Template:Navbox suite

Usage

{{Navbox

| name       = {{PAGENAME}} <!-- This has to be the name of the template -->
| title      = TITLE
| titleclass = wraplinks
| listclass  = hlist
| state = autocollapse

| aboveclass = hlist
| above = Example of Navbox

| group1 = A
| list1      = 
 • [[1]]

| group2 = B
| list2      =  
 • [[2]]

| group3 = C
| list3      = 
 • [[3]]

<!-- ... -->

| below      = [[4]]

}}

Template:Navbox

The basic and most common parameters are as follows (see below for the full list):

name – the name (Wikipedia location) of the template.
title – text in the title bar, such as: [[Navigation stuff]].
listclass – a CSS class for the list cells, usually hlist for horizontal lists. Alternatively, use bodyclass for the whole box.
state – controls when a navbox is expanded or collapsed.
titlestyle – a CSS style for the title-bar, such as: background: gray;
groupstyle – a CSS style for the group-cells, such as: background: #eee;
above – text to appear above the group/list section (could be a list of overall wikilinks).
image – an optional right-side image, coded as the whole image, such as: [[File:XX.jpg|80px|alt=Alternate text]]
imageleft – an optional left-side image (code the same as the "image" parameter).
groupn – the left-side text before list-n (if group-n omitted, list-n extends to the left edge of the box, and defaults to text-align:center styling).
listn – text listing wikilinks using a wikilist format.
below – optional text to appear below the group/list section.