Dominion Atlantic Railway Digital Preservation Initiative - Wiki

Use of this site is subject to our Terms & Conditions.

Template:Navbar/doc

From DARwiki

{{#if: |

40px This is the template documentation page for Template:Navbar.
This page may not be intended to be viewed directly.
Links using variables may appear broken; do not replace these with hardcoded page names or URLs.

{{#if:x||

}} |{{#ifeq: doc | doc

 | 

{{

   #ifeq: show | show
   | {{
 {{#switch:
 {{#if: 
   | 
   | {{#if: 
     | 
       {{#ifeq:|
       | talk
       |  
       }}
     | 
       {{#ifeq:template|template talk
       | talk
       | template 
       }}
     }}
   }}

| main | = ambox | talk = tmbox | user = ombox | wikipedia = ombox | file | image = imbox | mediawiki = ombox | template = ombox | help = ombox | category = cmbox | portal = ombox | book = ombox | other | #default = ombox

}} | type = notice | image = none | imageright = | class = | style = | textstyle = | text = This is a documentation subpage for Template:Navbar (see that page for the {{ #if: Template | template | article }} itself).
It contains usage information, categories and other content that is not part of the original {{ #if: Template |template page|article}}. | small = | smallimage = | smallimageright = | smalltext = | subst = | date = }}

   }}{{
   #if: 
   | 
   | [[Category:{{
     #if: Template
     | Template
     | Article
   }} documentation]]
 }}

| }} }} Template:High-risk

Usage

General

When one of the following examples is placed inside a given template, it adds navbar navigational functionality:

{{navbar|{{subst:PAGENAME}}|mini=1}}
{{navbar|{{subst:PAGENAME}}|plain=1}}
{{navbar|{{subst:PAGENAME}}|fontstyle=color:green}}

The {{subst:PAGENAME}} will be substituted with the template's name when parsed by the servers. For example, {{navbar|navbar/doc}} gives:

Font-size

Font-size is 88% when used in a navbar, and 100% when nested in a navbox. In the navbar, the weight is "normal"; when nested in navbox, it takes on the outer setting. The middot is bold.

Examples

Required parameters

  • {{navbar|Template Name}} – the template name is required.

Optional parameters

Options Parameters Produces...
Basic {{navbar|Template Name}} [}}
  • [[{{#switch:
#default = Navbar/doc =
   {{#ifeq:  | 
Template:navbar/doc Navbar/doc
   }}
}}|{{#if:|v|view}}]]
  • [[|{{#if:|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:|e|edit}}]}}{{#if:|]}}
    Different text {{navbar|Template Name|text=This template:}} [}}
    • [[{{#switch:
    #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|{{#if:|v|view}}]]
  • [[|{{#if:|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:|e|edit}}]}}{{#if:|]}}
    Without "This box:" text {{navbar|Template Name|plain=1}} [}}
    • [[{{#switch:
    #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|{{#if:|v|view}}]]
  • [[|{{#if:|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:|e|edit}}]}}{{#if:|]}}
    Short version {{navbar|Template Name|mini=1}} [}}
    • [[{{#switch:
    #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|{{#if:1|v|view}}]]
  • [[|{{#if:1|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:1|e|edit}}]}}{{#if:|]}}
    With brackets {{navbar|Template Name|brackets=1}} [}}
    • [[{{#switch:
    #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|{{#if:|v|view}}]]
  • [[|{{#if:|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:|e|edit}}]}}{{#if:1|]}}
    With a color option (span) {{navbar|Template Name|fontstyle=color:green}} [}}
    • [[{{#switch:
    #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|{{#if:|v|view}}]]
  • [[|{{#if:|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:|e|edit}}]}}{{#if:|]}}
    To float to the side (div) {{navbar|Template Name|style=float:right}} [}}
    • [[{{#switch:
    #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|{{#if:|v|view}}]]
  • [[|{{#if:|d|talk}}]]
  • {{#if:||
  • [{{fullurl:{{#switch:
  • #default = Navbar/doc =
       {{#ifeq:  | 
    
    Template:navbar/doc Navbar/doc
       }}
    
    }}|action=edit}} {{#if:|e|edit}}]}}{{#if:|]}}

    Deprecated parameters

    The miniv=1, viewplain=1, nodiv=1 and fontcolor= parameters have been deprecated. To implement the view-only version, use the {{{{#if:|subst:}}v{{#if:| |{{{2}}} }}{{#if:| |{{{3}}} }}{{#if:| |{{{4}}} }}{{#if:| |{{{5}}} }}{{#if:| |{{{6}}} }}{{#if:| |{{{7}}} }}{{#if:| |{{{8}}} }}{{#if:| |{{{9}}} }}{{#if:| |{{{10}}} }}{{#if:| |{{{11}}} }}{{#if:| |... }}}} or {{{{#if:|subst:}}view{{#if:| |{{{2}}} }}{{#if:| |{{{3}}} }}{{#if:| |{{{4}}} }}{{#if:| |{{{5}}} }}{{#if:| |{{{6}}} }}{{#if:| |{{{7}}} }}{{#if:| |{{{8}}} }}{{#if:| |{{{9}}} }}{{#if:| |{{{10}}} }}{{#if:| |{{{11}}} }}{{#if:| |... }}}} templates instead.

    Notes

    Navbar is contained within a Template:Tag in order to accomodate a horizontal unnumbered list. This means it cannot be placed inside a Template:Tag or other inline element, because Tidy will 'fix' situations where it finds block elements inside inline elements.

    Prepackaged

    {{Tnavbar-header}}
    Positions vTemplate:·dTemplate:·e on the right edge of the line, often used in non-collapsible navbox heading.
    {{Tnavbar-navframe}}
    For use in conjunction with Navframe divs, positions vTemplate:·dTemplate:·e opposite of the [hide]/[show] feature.
    {{Tnavbar-collapsible}}
    For use in conjunction with Collapsible tables,floats vTemplate:·dTemplate:·e opposite of the [hide]/[show] feature.

    See also

    Template:Edit templates Template:Navigational templates