Templat:Topik Amerika Serikat/doc: Perbedaan antara revisi
Konten dihapus Konten ditambahkan
kTidak ada ringkasan suntingan |
k bot kosmetik perubahan |
||
Baris 5:
This template allows quick creation of [[Wikipedia:Navigational templates|navigational template]] for groups of articles containing names of [[U.S. states]]. It uses [[:Template:Navbox generic]] to create the navigation box.
== Blank syntax ==
<pre>
{{United States topic
Baris 27:
== Parameters ==
=== Mandatory ===
; ''name''
: Mandatory when creating a new template (i.e. [[
''One of the following combinations is needed to create the links:
; ''prefix''
: Places text before the U.S. state name.
: Note: in instances when only ''prefix'' is specified, the template inserts "the" between the prefix text and "United States", creating the title [[List of airports in the United States]] instead of [[List of airports in United States]]. In the body it does the same for the [[Northern Mariana Islands]] and the [[United States Virgin Islands]].
; ''suffix''
: Places text after the U.S. state name.
; ''prefix'' and ''suffix''
: Places text before and after the U.S. state name.
: Note: The title in this example should be replaced by using the ''title'' parameter described below.
=== Optional ===
; ''state''
: A navbox with <code>autocollapse</code> will start out collapsed if there are two or more tables on the same page that use <tt>collapsible</tt>. If set to <code>collapsed</code>, the navbox will always start out in a collapsed state. If set to blank or anything other than <code>autocollapse</code> or <code>collapsed</code>, the navbox will always start out in an expanded state.
: Default is: <code>autocollapse</code>.
; ''title_style'' <span style="font-weight:normal;">= background
: (or ''titlebkg'' = ) Background color for the title. Use of this parameter is discouraged. Where it is used, care and consensus are needed as multiple navigational templates on one page with different titlebar colors will probably look unpleasant.
:Default is <span style="background:#ccccff; color:black;"> background:#ccccff </span>.
; ''title''
: Text that appears centered in the titlebar (the top bar). This is optional because the use of either ''prefix'', ''suffix'' or both will automatically generate a title if the ''title'' parameter is not supplied. This parameter is not automatically [[wiki-link]]ed.
; ''style''
Baris 68:
:Default is: <code>text-align:center;</code>
==== Excluding groups ====
In some instances the District of Columbia, U.S. Territories or U.S. Minor Outlying Islands may not have their own articles on particular topics. To disable their inclusion in the template and avoid unnecessary [[Wikipedia:Red link|red link]]s, add any or all of the following parameters:
Baris 81:
== Examples ==
=== Changing the navigation box title ===
<pre>
{{Amerika Serikat
Baris 128:
=== Creating a new template ===
Code used to create [[
<pre>
{{Amerika Serikat
Baris 142:
</noinclude>
</pre>
Note: '''<nowiki>{{subst:PAGENAME}}</nowiki>''' in the above example would be replaced by '''Hospitals in the United States''' when this code is saved in [[
Result:
|