Template:Navbox/doc: Difference between revisions

Jump to navigation Jump to search
new stuff; parameter capitalisation; -underconstruction
(Template Data redone)
(new stuff; parameter capitalisation; -underconstruction)
 
Line 1: Line 1:
{{UnderConstruction|Jovenan}}
This template creates a collapsible horizontal navigation box, i.e. a box containing links to articles related to the subject. Alternatively, the template can be used for any content, such as text or images. The template can be used as a basis of other templates or on its own on an article.
This template creates a collapsible horizontal navigation box, i.e. a box containing links to articles related to the subject. Alternatively, the template can be used for any content, such as text or images. The template can be used as a basis of other templates or on its own on an article.


Line 7: Line 6:


Minimal use:
Minimal use:
<pre>{{Navbox|TITLE=Title|Contents}}</pre>
<pre>{{Navbox|title=Title|Contents}}</pre>


The text within the template '''without parameter''' creates the contents of the navigation box.
The text within the template '''without parameter''' creates the contents of the navigation box.


Enter the parameter '''TITLE''' for the title of the navigation box.
Enter the parameter '''title''' for the title of the navigation box.


Other parameters are optional.
Other parameters are optional.
Line 17: Line 16:
Full use:
Full use:
<pre>{{Navbox
<pre>{{Navbox
|EXPANDED=Expanded
|expanded=
|WIDTH=Width
|width=
|TEXTCOLOR=Text color
|textcolor=
|TITLEBACKGROUND=Title background
|color=
|BACKGROUND=Background
|background=
|ALIGN=Align
|align=
|TITLE=Title
|title=
|bstyle=
|tstyle=
|cstyle=
|Contents}}</pre>
|Contents}}</pre>


'''EXPANDED''' determines if the navigation box is expanded or collapsed (open or closed) when the page is opened. Any text (such as "yes", "true", "1") causes the box to be initially opened. Leave empty if that is not desired.
'''Expanded''' determines if the navigation box is expanded or collapsed (open or closed) when the page is opened. Any text (such as "yes", "true", "1") causes the box to be initially opened. Leave empty if that is not desired.


'''WIDTH''' determines the width of the navigation box. Enter the width in pixels (e.g. 150px), as percentage of the width of the article (e.g. 80%) or in other supported measures. Defaults to full width.
'''Width''' determines the width of the navigation box. Enter the width in pixels (e.g. 150px), as percentage of the width of the article (e.g. 80%) or in other supported measures. Defaults to full width.


'''TEXTCOLOR''' determines the color of the title. Enter the color in HTML names (e.g. white) or in hex code (e.g. #FEF7FC). Defaults to the black.
'''Textcolor''' determines the color of the title. Enter the color in HTML names (e.g. white) or in hex code (e.g. #FEF7FC). Defaults to the black.


'''COLOR''' determines the background color of the title. Enter the color in HTML names (e.g. black) or in hex code (e.g. #B57EDC). Defaults to #efefef, which is a shade of light grey.
'''Color''' determines the background color of the title. Enter the color in HTML names (e.g. black) or in hex code (e.g. #B57EDC). Defaults to #efefef, which is a shade of light grey.


'''BACKGROUND''' determines the background color of the content. Enter the color in HTML names (e.g. black) or in hex code (e.g. #B57EDC). Defaults to white.
'''Background''' determines the background color of the content. Enter the color in HTML names (e.g. black) or in hex code (e.g. #B57EDC). Defaults to white.


'''ALIGN''' determines the alignment of the contents. Defaults to left.
'''Align''' determines the alignment of the contents. Defaults to left.
 
'''Bstyle''', '''tstyle''' and '''cstyle''' allow changes to the CSS styling of the template main box, title box and contents, respectively. These parameters can override all other styling to their respective objects. These are advanced parameters that can cause the template to work incorrectly if entered wrong.
 
Different capitalisations of the parameter names ("title", "Title", "TITLE") are accepted. Please only use one style per parameter name.


== Examples ==
== Examples ==
Line 45: Line 51:


<pre>{{Navbox
<pre>{{Navbox
|ALIGN=center
|align=center
|TITLE=Species of the [[Borderlands]]
|title=Species of the [[Borderlands]]
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}</pre>
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}</pre>


{{Navbox
{{Navbox
|ALIGN=center
|align=center
|TITLE=Species of the [[Borderlands]]
|title=Species of the [[Borderlands]]
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}


=== More complex navigation box ===
=== More complex navigation box ===
<pre>{{Navbox
<pre>{{Navbox
|EXPANDED=yes
|expanded=yes
|WIDTH=400px
|width=400px
|ALIGN=center
|align=center
|COLOR=#996633
|color=#996633
|TEXTCOLOR=white
|textcolor=white
|TITLE=Species of the [[Borderlands]]
|title=Species of the [[Borderlands]]
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}</pre>
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}</pre>


{{Navbox
{{Navbox
|EXPANDED=yes
|expanded=yes
|WIDTH=400px
|width=400px
|ALIGN=center
|align=center
|COLOR=#996633
|color=#996633
|TEXTCOLOR=white
|textcolor=white
|TITLE=Species of the [[Borderlands]]
|title=Species of the [[Borderlands]]
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}
|[[Klingon]]s • [[Son'a]] • [[Suliban]] • [[Da'al]] • Thama • Nascaik • Demesians}}


=== Alternate use ===
=== Alternate use ===
<pre>{{Navbox
<pre>{{Navbox
|COLOR={{Color|Blue}}
|color={{Color|Blue}}
|TEXTCOLOR=white
|textcolor=white
|WIDTH=80%
|width=80%
|TITLE=Shoreleave
|title=Shoreleave
|[[File:Classo.jpg|thumb|Rura Penthe is Class D, such as the moon above.]]
|[[File:Classo.jpg|thumb|Rura Penthe is Class D, such as the moon above.]]
After the mission in the Muppetverse, the crew of the USS ''Diana'' went to a shore leave on Rura Pethe. Exhausted by the events of the previous mission, Jo Venan decided to use the opportunity for relaxation, as opposed to joining the other officers in exploring their holiday destination. As such, she remained mostly onboard the ship.
After the mission in the Muppetverse, the crew of the USS ''Diana'' went to a shore leave on Rura Pethe. Exhausted by the events of the previous mission, Jo Venan decided to use the opportunity for relaxation, as opposed to joining the other officers in exploring their holiday destination. As such, she remained mostly onboard the ship.
Line 85: Line 91:


{{Navbox
{{Navbox
|COLOR={{Color|Blue}}
|color={{Color|Blue}}
|TEXTCOLOR=white
|textcolor=white
|WIDTH=80%
|width=80%
|TITLE=Shoreleave
|title=Shoreleave
|[[File:Classo.jpg|thumb|Rura Penthe is Class D, such as the moon above.]]
|[[File:Classo.jpg|thumb|Rura Penthe is Class D, such as the moon above.]]
After the mission in the Muppetverse, the crew of the USS ''Diana'' went to a shore leave on Rura Pethe. Exhausted by the events of the previous mission, Jo Venan decided to use the opportunity for relaxation, as opposed to joining the other officers in exploring their holiday destination. As such, she remained mostly onboard the ship.
After the mission in the Muppetverse, the crew of the USS ''Diana'' went to a shore leave on Rura Pethe. Exhausted by the events of the previous mission, Jo Venan decided to use the opportunity for relaxation, as opposed to joining the other officers in exploring their holiday destination. As such, she remained mostly onboard the ship.
1,769

edits

Navigation menu