Vorlage:Template shortcut/Doku: Unterschied zwischen den Versionen

übersetzt, angepasst und etwas eingedampft
Keine Bearbeitungszusammenfassung
(übersetzt, angepasst und etwas eingedampft)
Zeile 5: Zeile 5:


== Verwendung ==
== Verwendung ==
===Which to show?===
Although the template can show up to ten aliases, editors are ''encouraged to choose well'' which ones to display. Even if many redirects exist, ''two or three at the most'' is almost always enough, and by keeping the number small, it facilitates remembering them, and the situation is kept well organized.


List others in the "aliases" section of the [[Wikipedia:Template documentation|template documentation]]. Again, not all of them need to be listed; some shortcuts are there just for historical reasons, and others differ only in whitespaces or in capitalization. Such names are usually better to hide.
Die Vorlage kann bis zu zehn Aliase anzeigen, aber man sollte die ANzahl auf ein vernünftiges Maß reduzieren, schließlich kann sich auch niemand diese ganze Menge merken. Bitte füge die Vorlage immer am Anfang einer Vorlagendokumentation ein. Prüfe auch, ob alle ALiase auf [[Wikivoyage:Shortcuts]] gelistet sind.


Place this template at the top of the template documentation page.
* {{Tlc|Template shortcut|{{Var|pre{{=}}Präfix1}}|shortcut1|{{Var|pre2{{=}}Präfix1}}|shortcut2|...}}
'''optionale Parameter:'''
* {{Para|float|left}} – blendet die Box auf der linken Seite ein (Standard ist rechts)
* {{Para|pre}}, {{Para|pre2}}, ... bis {{Para|pre10}} − gibt einen Text vor dem Link, aber innerhalb der Klammern aus. Dies wird oft genutzt, um Substitution darzustellen.


===Optional parameters===
== Beispiele==
This template has several optional parameters:
* '''float''' – if set to "left", then the box will float to the left of the page, instead of the default float "right".
* '''pre, pre2, pre3 ... up to pre10''' – can be used to show some text before the shortcut links, but within the braces. This is mostly used to indicate that the template should be used with substitution.


==Examples==
{{Tlc|Template shortcut|tsh}}
===Basic===
{{Template shortcut|tsh}}
For one template shortcut named {{tl|uw-v1}}:
{{-}}


{{tlc|template shortcut|uw-v1}}
{{Tlc|Template shortcut|tsh|sc}}
{{template shortcut|uw-v1}}
{{Template shortcut|tsh|sc}}
{{clear}}
{{-}}


To indicate that {{tl|uw-vandalism1}} has three shortcuts named: {{tl|uw-v1}}, {{tl|uw-vand1}}, and {{tl|uw-vandal1}}; then the following code may be used:


{{tlc|template shortcut|uw-v1|uw-vand1|uw-vandal1}}
<code><nowiki>{{Template shortcut|tsh|pre2=subst:|sc}}</nowiki></code>
{{template shortcut|uw-v1|uw-vand1|uw-vandal1}}
{{Template shortcut|tsh|pre2=subst:|sc}}
{{clear}}
{{-}}
 
=== With additional parameters ===
Using {{para|float|<var>left</var>}} makes this template flow to the left of the page:
 
<code><nowiki>{{template shortcut|float=left|uw-v1}}</nowiki></code>
{{template shortcut|float=left|uw-v1}}
{{clear}}
 
Using {{para|pre2|<var>subst:</var>}} and {{para|pre3|<var>subst:</var>}} will show "subst:" before the shortcut links, but within the braces. For example:
 
<code><nowiki>{{template shortcut|uw-v1|pre2=subst:|uw-vand1|pre3=subst:|uw-vandal1}}</nowiki></code>
{{template shortcut|uw-v1|pre2=subst:|uw-vand1|pre3=subst:|uw-vandal1}}
{{clear}}


== Individuelle Gestaltung ==
== Individuelle Gestaltung ==
Anonymer Benutzer