Vorlage:Navbar: Unterschied zwischen den Versionen
imported>Edokter (Update from sandbox: fontsize now controlled by common.css; use bold middot with tighter spacing; always use span.) |
imported>Edokter (thinsp has issues, using word-spacing instead.) |
||
| Zeile 6: | Zeile 6: | ||
-->{{#if:{{{brackets|}}}|<span style="{{{fontstyle|}}}">[</span>}}<!-- | -->{{#if:{{{brackets|}}}|<span style="{{{fontstyle|}}}">[</span>}}<!-- | ||
--><span style="white-space:nowrap;word-spacing:-.12em;"><!-- | |||
-->[[{{transclude|{{{1}}}}}|<span style="{{{fontstyle|}}}" title="View this template"><!-- | -->[[{{transclude|{{{1}}}}}|<span style="{{{fontstyle|}}}" title="View this template"><!-- | ||
-->{{#if:{{{mini|}}}|v|view}}</span>]]<!-- | -->{{#if:{{{mini|}}}|v|view}}</span>]]<!-- | ||
--><span style=" | --><span style="{{{fontstyle|}}}"> <b>·</b> </span><!-- | ||
-->[[{{TALKPAGENAME:{{transclude|{{{1}}}}}}}|<span style="{{{fontstyle|}}}" title="Discuss this template"><!-- | -->[[{{TALKPAGENAME:{{transclude|{{{1}}}}}}}|<span style="{{{fontstyle|}}}" title="Discuss this template"><!-- | ||
-->{{#if:{{{mini|}}}|d|talk}}</span>]]<!-- | -->{{#if:{{{mini|}}}|d|talk}}</span>]]<!-- | ||
-->{{#if:{{{noedit|}}}|<!--nothing-->|<!--else: | -->{{#if:{{{noedit|}}}|<!--nothing-->|<!--else: | ||
--><span style=" | --><span style="{{{fontstyle|}}}"> <b>·</b> </span><!-- | ||
-->[{{fullurl:{{transclude|{{{1}}}}}|action=edit}} <span style="{{{fontstyle|}}}" title="Edit this template"><!-- | -->[{{fullurl:{{transclude|{{{1}}}}}|action=edit}} <span style="{{{fontstyle|}}}" title="Edit this template"><!-- | ||
-->{{#if:{{{mini|}}}|e|edit}}</span>]}}<!-- | -->{{#if:{{{mini|}}}|e|edit}}</span>]}}<!-- | ||
--></span><!-- | |||
-->{{#if:{{{brackets|}}}|<span style="{{{fontstyle|}}}">]</span>}}<!-- | -->{{#if:{{{brackets|}}}|<span style="{{{fontstyle|}}}">]</span>}}<!-- | ||
Version vom 20. Januar 2011, 03:28 Uhr
| Diese Vorlage benutzt Modul:Navbar, Skripte geschrieben in der Programmiersprache Lua. Bitte informiere dich dort, wenn du mehr über die Sprache und ihren Einsatz erfahren willst. Diese Vorlagen sollte im Regelfall nicht ersetzt werden. |
| Diese Vorlage verwendet TemplateStyles. Die Stilvorlagen sind in den folgenden Dateien notiert: |
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}} |
|
| Different text | {{navbar|Template Name|text=This template:}} |
|
| Without "This box:" text | {{navbar|Template Name|plain=1}} |
|
| Short version | {{navbar|Template Name|mini=1}} |
|
| With brackets | {{navbar|Template Name|brackets=1}}
|
|
| With a color option (span) | {{navbar|Template Name|fontstyle=color:green}} |
|
| To float to the side (div) | {{navbar|Template Name|style=float:right}} |
Deprecated parameters
The miniv=1, viewplain=1, nodiv=1 and fontcolor= parameters have been deprecated. To implement the view-only version, use the {{v}} or {{view}} templates instead.
Notes
Navbar is contained within a <div>...</div> in order to accommodate a horizontal unnumbered list. This means it cannot be placed inside a <span>...</span> or other inline element, because Tidy will 'fix' situations where it finds block elements inside inline elements.
Prepackaged
- {{Navbar-header}}
- Positions on the right edge of the line, often used in non-collapsible navbox heading.
See also
- {{Ed}} – navbar style edit link
- {{Ed right}} – navbar style edit link aligned to right of page
- {{Edit}} – plain edit link
- {{Edit section}} – edit link aligned to right of page
- {{Navbar}} – with additional links
| Collapsible | Header color | Image | Groups | Style (body) parameter/s |
Examples | |
|---|---|---|---|---|---|---|
| {{Navbox}} | collapsible | navbox | Left/right of body | Yes | Yes | |
| {{Navbox with collapsible groups}} | collapsible | navbox | Left/right of body and/or in each list | Yes | Yes | |
| {{Navbox with columns}} | collapsible | navbox | Left/right of columns | No | Yes | |
| {{Navbox years}} | collapsible | navbox | No | No | No |
| Type | CSS classes | Javascript | Collapses when | Custom initial state |
Nesting |
|---|---|---|---|---|---|
| Collapsible tables | collapsible | Defined in Common.js | 2 or more autocollapse on page | Yes | Yes |
When placed inside a given template, it adds navbar navigational functionality
| Parameter | Beschreibung | Typ | Status | |
|---|---|---|---|---|
| Template Name | | The name of the template, so links work correctly
| Mehrzeiliger Text | erforderlich |
| Different text | text | Allows custom text to replace the default 'this box'
| Mehrzeiliger Text | optional |
| Without 'This box:' text | plain | Removes 'This box'
| Zahlenwert | optional |
| Short Version | mini | Shortens text to V T E
| Zahlenwert | optional |
| with brackets | brackets | adds brackets before and after the links
| Zahlenwert | optional |
| Font color | fontstyle | Allows you to change the color of the font (in the format color:green)
| Mehrzeiliger Text | optional |
| To float to the side | style | Allows the template to float to the side (format=float:right)
| Mehrzeiliger Text | optional |
- Die obige Dokumentation wurde aus der Seite Vorlage:Navbar/Doku eingefügt. (bearbeiten | Versionsgeschichte) Die Kategorien für diese Vorlage sollten in der Dokumentation eingetragen werden. Die Interwiki-Links sollten auf Wikidata eingepflegt werden.
- Testseite anlegen -Editnotice anlegen -Wartungsseite anlegen
- Liste der Unterseiten