Template:Navbar/en

From Holocaustmap

<languages/> {{#if:||{{#if:|{{{text}}}|This box:}} }}{{#if:|[}}[[{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}|{{#if:|v|view}}]] · [{{fullurl:{{TALKPAGENAME:{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}}}}} {{#if:|d|talk}}]{{#if:|| · [{{fullurl:{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}|action=edit}} {{#if:|e|edit}}]}}{{#if:|]}} Lua error: Module:TNT:172: '''Missing JsonConfig extension, or not properly configured; Cannot load https://commons.wikimedia.org/wiki/Data:I18n/Documentation.tab. See https://www.mediawiki.org/wiki/Extension:JsonConfig#Supporting_Wikimedia_templates'''.{{#if:Lua error: callParserFunction: function "#translation" was not found.

Usage

General

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

{{Navbar|Navbar|mini=1}}
{{Navbar|Navbar|plain=1}}
{{Navbar|Navbar|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:

{{#if:||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}}

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

Template:(| class="wikitable" ! Options ! Parameters ! Produces... |- | Basic | {{Navbar|template name}} | {{#if:||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} |- | Different text | {{Navbar|template name|text=This template:}} | {{#if:||{{#if:This template:|This template:|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} |- | Without "This box:" text | {{Navbar|template name|plain=1}} | {{#if:1||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} |- | Short version | {{Navbar|template name|mini=1}} | {{#if:1||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:1|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:1|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:1|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} |- | With a color option | {{Navbar|template name|fontstyle=color:green}} | {{#if:||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="color:green" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="color:green" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="color:green" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} |- | With brackets | {{Navbar|template name|brackets=1}} | {{#if:||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:1|[}}[[{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = Navbar/doc 
| = 
   {{#ifeq:  | 
     | Template:navbar/doc            
     | Navbar/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:1|]}} |- | Custom namespace | {{Navbar|namespaced template name|plain=1|brackets=1}} | {{#if:1||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:1|[}}[[{{#switch: User

|#default = User:Example 
| = 
   {{#ifeq: User | 
     | Template:User:Example            
     | Example      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch: User

|#default = User:Example 
| = 
   {{#ifeq: User | 
     | Template:User:Example            
     | Example      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:1|]}} |Template:)

TemplateData

Template:Navbar/doc

Notes

Navbar is contained within a {{#switch:pair

 |c|close =
 |e|empty|s|single|v|void
 |o|open
 |p|pair = <{{#if:|div|div}}{{#if:| {{{attribs}}}}}
}}{{#switch:pair
 |c|close = 
 |e|empty|s|single|v|void =  />
 |o|open = >
 |p|pair = {{#ifeq:div|!--||>}}...
}}{{#switch:pair
 |e|empty|s|single|v|void
 |o|open =
 |c|close
 |p|pair = {{#ifeq:div|!--|-->|</div>}}
}} in order to accommodate a horizontal unnumbered list.

This means it cannot be placed inside a {{#switch:pair

 |c|close =
 |e|empty|s|single|v|void
 |o|open
 |p|pair = <{{#if:|span|span}}{{#if:| {{{attribs}}}}}
}}{{#switch:pair
 |c|close = 
 |e|empty|s|single|v|void =  />
 |o|open = >
 |p|pair = {{#ifeq:span|!--||>}}...
}}{{#switch:pair
 |e|empty|s|single|v|void
 |o|open =
 |c|close
 |p|pair = {{#ifeq:span|!--|-->|</span>}}
}} or other inline element, because Tidy will 'fix' situations where it finds block elements inside inline elements.|

[[Category:Template documentation pages{{#translation:}}]] }}