Open main menu

Changes

update documentation, add see also links, keep /sandbox out of category
{{Documentation subpage}}
<!-- Place categories where indicated at the bottom of this page and interwikis at Wikidata -->

This template is for use when you wish to minimise information to be expanded at the user's discretion.

==Usage==

=== Unnamed parameters ===
<pre>
{{show
|Header!
|Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}
</pre>

''Output'':
{{show
|Header!
|Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}

=== Numbered parameters ===
<pre>
{{show
|1=Header!
|2=Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}
</pre>

''Output'':
{{show
|1=Header!
|2=Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}

=== Alignment parameters ===
The horizontal alignment of the header text and content text can be manipulated using the parameters {{para|head-align}} and {{para|content-align}}. Valid options are <code>left</code> (default), <code>center</code>, or <code>right</code>. Do not use quotes (i.e. not <code>"center"</code>) or the color of the header may change. Also, while {{para|head-align|right}} is possible, it causes the header to overlap with the [show] button.

<pre>
{{show
|head-align = center
|content-align = right
|1 = Header!
|2 = Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}
</pre>

''Output'':
{{show
|head-align = center
|content-align = right
|1 = Header!
|2 = Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}

=== Style parameters ===
The default [[Cascading Style Sheets|CSS]] styling may be changed using the parameters {{para|frame-style}}, {{para|head-style}}, and {{para|content-style}}.

<pre>
{{show
|frame-style = border: 1px solid silver; padding: 0.3em;
|head-style = background-color: #AADDAA; text-align: center;
|content-style = background-color: #CCFFCC; text-align: right;
|1 = Header!
|2 = Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}
</pre>

''Output'':
{{show
|frame-style = border: 1px solid silver; padding: 0.3em;
|head-style = background-color: #AADDAA; text-align: center;
|content-style = background-color: #CCFFCC; text-align: right;
|1 = Header!
|2 = Content!
This information here will not show until you click the "show" button. It's then hidden by collapsing the section when you press "hide" button.
}}

=== Usage in a table ===
{{Show/Table usage}}

== See also ==
* {{tl|Collapse}}
* {{tl|Collapsible section}}
* {{tl|Divhide}}
* {{tl|Hidden}}

<includeonly>{{sandbox other||
<!-- Categories below this line; interwikis at Wikidata -->
[[Category:Collapse templates]]
}}</includeonly>
Anonymous user