Difference between revisions of "Template:Navbox/doc"

From Nookipedia, the Animal Crossing wiki
(Created page with "==Usage== <pre> {{Navbox | Title = | Link = | Icon = | IconSize = | Image = | TextColor = | PrimaryColor = |...")
 
(Updating documentation)
Line 1: Line 1:
 
==Usage==
 
==Usage==
 
<pre>
 
<pre>
{{Navbox
+
{{User:Dorsal Axe/Sandbox4
 
  | Title          =  
 
  | Title          =  
 
  | Link          =  
 
  | Link          =  
Line 7: Line 7:
 
  | IconSize      =  
 
  | IconSize      =  
 
  | Image          =  
 
  | Image          =  
| TextColor      =
 
 
  | PrimaryColor  =  
 
  | PrimaryColor  =  
 
  | SecondaryColor =  
 
  | SecondaryColor =  
| GroupColor    =
 
| RowColor      =
 
 
  | Width          =
 
  | Width          =
| State          =
 
 
| PlainList      =
 
  
 
  | Above          =
 
  | Above          =
| AboveLink      =
 
 
  | Group          =  
 
  | Group          =  
 
  | GroupLink      =  
 
  | GroupLink      =  
 
  | List          =  
 
  | List          =  
  
  | Below         =
+
  | Above2        =
  | BelowLink      =
+
| Group2        =
}}
+
| Group2Link    =
</pre>
+
| List2          =
 +
 
 +
| Above3        =
 +
| Group3        =
 +
| Group3Link    =
 +
| List3          =
 +
 
 +
| Above4        =
 +
| Group4        =
 +
| Group4Link    =
 +
| List4         =  
 +
 
 +
  | Above5        =
 +
| Group5        =
 +
| Group5Link    =
 +
| List5          =
  
This template is intended to be used for all navboxes, as it allows them to be easily created and maintained and gives them a consistent visual style and functionality. A mobile-friendly version is displayed when viewing Nookipedia in Mobile view, which adjusts the positioning of elements and leaves out the image parameter to save space on smaller screens.
+
| Above6        =
 +
| Group6        =
 +
| Group6Link    =
 +
| List6          =
  
The following parameters primarily set the visual style of the template:
+
| Above7        =
* <code>Title</code> sets the displayed heading of the navbox
+
| Group7        =
* <code>Link</code> is an optional parameter that sets the page that the heading will link to.
+
| Group7Link    =
* <code>Icon</code> is an optional parameter that displays a small icon in the upper-left corner of the navbox.
+
| List7          =
* <code>IconSize</code> is an optional parameter that allows the size of the icon to be manually adjusted.
 
* <code>Image</code> is an optional parameter that allows an image to be displayed in the right side of the navbox in Desktop view.
 
* <code>TextColor</code> sets the displayed colour of the heading text and group label text.
 
* <code>PrimaryColor</code> sets the displayed colour of the outer part of the navbox
 
* <code>SecondaryColor</code> sets the displayed colour of the inner part of the navbox
 
* <code>GroupColor</code> sets the displayed colour of the groups, dividers and footer.
 
* <code>RowColor</code> sets the displayed colour of alternate rows.
 
* <code>Width</code> sets the width of the entire navbox. This should only be manually set if the navbox is only using the <code>PlainList</code> parameter.
 
* <code>State</code> toggles whether the navbox appears in a collapsed or uncollapsed state. <code>Hide</code> will result in a collapsed state, while <code>Show</code> will keep it uncollapsed.
 
  
The following parameters primarily set the content of the template:
+
| Above8        =
*<code>PlainList</code> omits the group cells and simply shows a single list in a centered alignment. This is useful if the navbox is only showing a few links and grouping them is unnecessary. It's not recommended to use this in conjunction with additional groups as it may result in visual errors.
+
| Group8        =
 +
| Group8Link    =
 +
| List8          =
  
* <code>Above</code> creates a divider heading that is shown above the specified group.
+
| Above9        =
* <code>AboveLink</code> is an optional parameter that sets the page that the heading will link to.
+
| Group9        =
* <code>Group</code> sets the displayed label of the specified group.
+
| Group9Link    =
* <code>GroupLink</code> is an optional parameter that sets the page that the group label will link to.
+
| List9          =
* <code>List</code> is the content to be displayed adjacent to the specified group, typically links to other pages.
 
  
The navbox template supports up to 10 groups and corresponding lists, and up to 5 links in the footer. When adding more than one group or link to the footer, you must append the number to the names of the parameters like so. Failing to this will result in display errors.
+
  | Above10        =
<pre>
+
  | Group10        =  
  | Above2        =
+
  | Group10Link    =  
  | Group2        =  
+
  | List10        =  
  | Group2Link    =  
 
  | List2          =  
 
  
  | Below2         =
+
| Below          =
  | Below2Link     =
+
| BelowLink      =
 +
  | Below2         =
 +
  | Below2Link     =
 +
| Below3        =
 +
| Below3Link    =
 +
| Below4        =
 +
| Below4Link    =
 +
| Below5        =
 +
| Below5Link    =  
 +
}}
 
</pre>
 
</pre>
 +
 +
This template is used for all navboxes, and allows them to be easily created and maintained.
  
 
===Example===
 
===Example===
 
<pre>
 
<pre>
{{Navbox
+
{{User:Dorsal Axe/Sandbox4
 
  | Title          = Fashion
 
  | Title          = Fashion
 
  | Icon          = Tops NH Icon cropped.png
 
  | Icon          = Tops NH Icon cropped.png
 
  | Image          = [[File:Gracie NLa.png|40px|link=]]
 
  | Image          = [[File:Gracie NLa.png|40px|link=]]
| TextColor      = #722756
+
  | PrimaryColor  = 322 49
  | PrimaryColor  = #d88dbc
 
| SecondaryColor = #f8ecf4
 
| GroupColor    = #e3b5d4
 
| RowColor      = #f1dae9
 
  
 
  | Group          = Clothing
 
  | Group          = Clothing
Line 95: Line 103:
 
</pre>
 
</pre>
  
{{Navbox
+
{{User:Dorsal Axe/Sandbox4
 
  | Title          = Fashion
 
  | Title          = Fashion
 
  | Icon          =  
 
  | Icon          =  
 
  | Image          = [[File:Gracie NLa.png|40px|link=]]
 
  | Image          = [[File:Gracie NLa.png|40px|link=]]
| TextColor      = #722756
+
  | PrimaryColor  = 322 49
  | PrimaryColor  = #d88dbc
 
| SecondaryColor = #f8ecf4
 
| GroupColor    = #e3b5d4
 
| RowColor      = #f1dae9
 
  
 
<!-- CLOTHING -->
 
<!-- CLOTHING -->

Revision as of 14:08, July 4, 2020

Usage

{{User:Dorsal Axe/Sandbox4
 | Title          = 
 | Link           = 
 | Icon           = 
 | IconSize       = 
 | Image          = 
 | PrimaryColor   = 
 | SecondaryColor = 
 | Width          =

 | Above          =
 | Group          = 
 | GroupLink      = 
 | List           = 

 | Above2         =
 | Group2         = 
 | Group2Link     = 
 | List2          = 

 | Above3         =
 | Group3         = 
 | Group3Link     = 
 | List3          = 

 | Above4         =
 | Group4         = 
 | Group4Link     = 
 | List4          = 

 | Above5         =
 | Group5         = 
 | Group5Link     = 
 | List5          = 

 | Above6         =
 | Group6         = 
 | Group6Link     = 
 | List6          = 

 | Above7         =
 | Group7         = 
 | Group7Link     = 
 | List7          = 

 | Above8         =
 | Group8         = 
 | Group8Link     = 
 | List8          = 

 | Above9         =
 | Group9         = 
 | Group9Link     = 
 | List9          = 

 | Above10        =
 | Group10        = 
 | Group10Link    = 
 | List10         = 

 | Below          =
 | BelowLink      =
 | Below2         =
 | Below2Link     =
 | Below3         = 
 | Below3Link     =
 | Below4         = 
 | Below4Link     =
 | Below5         = 
 | Below5Link     = 
}}

This template is used for all navboxes, and allows them to be easily created and maintained.

Example

{{User:Dorsal Axe/Sandbox4
 | Title          = Fashion
 | Icon           = Tops NH Icon cropped.png
 | Image          = [[File:Gracie NLa.png|40px|link=]]
 | PrimaryColor   = 322 49

 | Group          = Clothing
 | List           = [[Clothes]] • [[Accessories]] • [[Bottoms]] • [[Dress|Dresses]] • [[Headgear]] • [[Shoes]] • [[Socks]] • [[Tops]] • [[Umbrellas]] • [[Wigs]]

 | Group2         = Concepts
 | List2          = [[Design]]s • [[Look]] • [[Hairstyle]] • [[Mii Mask]]

 | Group3         = Merchants
 | List3          = [[Able Sisters]] • [[GracieGrace]] • [[Kicks (shop)|Kicks]] • [[Shampoodle]]

 | Group4         = Designers
 | List4          = [[Gracie]] • [[Harriet]] • [[Kicks]] • [[Label]] • [[Mabel]] • [[Sable]]

 | Below          = Category
 | BelowLink      = :Category:Furniture
 | Below2         = Project
 | Below2Link     = Nookipedia:Project Fashion
}}

User:Dorsal Axe/Sandbox4