Template:Navbar/testcases

{{Template test cases notice}}

Navbar/sandbox

class="wikitable"
scope="col" | Option (high-level)

! scope="col" | Option (detail)

! scope="col" | Parameters

! scope="col" | Navbar

! scope="col" | Navbar/sandbox

rowspan="9" scope="row" | Normal

| Normal

| {{Navbar/sandbox|Template Name}}

| {{Navbar|Navbar/doc}}

| {{Navbar/sandbox|Navbar/doc}}

With other text

| {{Navbar/sandbox|Template Name|text=This template:}}

| {{Navbar|Navbar/doc|text=This template:}}

| {{Navbar/sandbox|Navbar/doc|text=This template:}}

No text

| {{Navbar/sandbox|Template Name|plain=1}}

| {{Navbar|Navbar/doc|plain=1}}

| {{Navbar/sandbox|Navbar/doc|plain=1}}

With brackets

| {{Navbar/sandbox|Template Name|plain=1|brackets=1}}

| {{Navbar|Navbar/doc|plain=1|brackets=1}}

| {{Navbar/sandbox|Navbar/doc|plain=1|brackets=1}}

Inline

| {{Navbar/sandbox|Template Name}}

| Lorem {{Navbar|Navbar/doc}} Ipsum

| Lorem {{Navbar/sandbox|Navbar/doc}} Ipsum

Inline, plain

| {{Navbar/sandbox|Template Name|plain=1}}

| Lorem {{Navbar|Navbar/doc|plain=1}} Ipsum

| Lorem {{Navbar/sandbox|Navbar/doc|plain=1}} Ipsum

With color option

| {{Navbar/sandbox|Template Name|fontstyle=color:green}}

| {{Navbar|Navbar/doc|fontstyle=color:green}}

| {{Navbar/sandbox|Navbar/doc|fontstyle=color:green}}

Linking to non-template pages

| {{Navbar/sandbox|User:Foo}}

| {{Navbar|User:Foo}}

| {{Navbar/sandbox|User:Foo}}

Linking to non-template pages

| {{Navbar/sandbox|:Foo}}

| {{Navbar|:Foo}}

| {{Navbar/sandbox|:Foo}}

rowspan="4" scope="row" | Mini

| Makes Navbar display in a mini version.

| {{Navbar/sandbox|Template Name|mini=1}}

| {{Navbar|Navbar/doc|mini=1}}

| {{Navbar/sandbox|Navbar/doc|mini=1}}

With brackets.

| {{Navbar/sandbox|Template Name|mini=1|brackets=1}}

| {{Navbar|Navbar/doc|mini=1|brackets=1}}

| {{Navbar/sandbox|Navbar/doc|mini=1|brackets=1}}

Mini colors

| {{Navbar/sandbox|Template Name|mini=1|fontstyle=color:green}}

| {{Navbar|Navbar/doc|mini=1|fontstyle=color:green}}

| {{Navbar/sandbox|Navbar/doc|mini=1|fontstyle=color:green}}

Inline

| {{Navbar/sandbox|Template Name|mini=1}}

| Lorem {{Navbar|Navbar/doc|mini=1}} Ipsum

| Lorem {{Navbar/sandbox|Navbar/doc|mini=1}} Ipsum

rowspan="4" scope="row" | View only

| For a full simpler access option

| {{Navbar/sandbox|Template Name|viewplain=1}}

| {{view|Navbar/doc}}

| {{view/sandbox|Navbar/doc}}

For a simpler access option

| {{Navbar/sandbox|Template Name|miniv=1}}

| {{v|Navbar/doc}}

| {{v/sandbox|Navbar/doc}}

For protected templates

| {{Navbar/sandbox|Template Name|noedit=1}}

| {{Navbar|Navbar/doc|noedit=1}}

| {{Navbar/sandbox|Navbar/doc|noedit=1}}

For protected templates, mini

| {{Navbar/sandbox|Template Name|noedit=1|mini=1}}

| {{Navbar|Navbar/doc|noedit=1|mini=1}}

| {{Navbar/sandbox|Navbar/doc|noedit=1|mini=1}}

In navbox

{{see also|Template:Navbox/testcases}}

{{navbox/sandbox

| name = Template:Navbar/testcases

| title = Navbox Navbar test

| group1 = Group 1 test

| list1 = List 1 test

}}

Demonstrating bug in move option

When the template name includes a space, and the move option is specified, the move link is misdisplayed and also does not work correctly:

  • {{tlx|navbar|2=template=Example template|3=m}} → {{navbar|template=Example template|m}}
  • {{tlx|v|2=template=Example template|3=m}} → {{v|template=Example template|m}}
  • {{tlx|view|2=template=Example template|3=m}} → {{view|template=Example template|m}}

It makes no difference if an underscore is used instead of the space:

  • {{tlx|navbar|2=template=Example_template|3=m}} → {{navbar|template=Example_template|m}}
  • {{tlx|v|2=template=Example_template|3=m}} → {{v|template=Example_template|m}}
  • {{tlx|view|2=template=Example_template|3=m}} → {{view|template=Example_template|m}}

The problem also occurs when the template name is given as a positional parameter, except that the {{tlx|navbar}} form then ignores the {{para||m}} parameter:

  • {{tlx|navbar|Example template|m}} → {{navbar|Example template|m}}
  • {{tlx|v|Example template|m}} → {{v|Example template|m}}
  • {{tlx|view|Example template|m}} → {{view|Example template|m}}