(add collapsed param) |
(use inline formatting instead of block for more consistent source presentation) |
||
Line 9: | Line 9: | ||
{ | { | ||
"description": "Start of a collapsible section.", | "description": "Start of a collapsible section.", | ||
"format": " | "format": "inline", | ||
"params": { | "params": { | ||
"label": { | "label": { | ||
Line 43: | Line 43: | ||
} | } | ||
} | } | ||
}</templatedata> | } | ||
</templatedata> | |||
==Sample== | ==Sample== |
Latest revision as of 23:27, 23 September 2024
Spoilers:
[Show/Hide]
This text is part of the template doc. Hi!
Used to hide content behind a collapsible section. Pair with {{CollapseEnd}}.
Parameters
Start of a collapsible section.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Label | label 1 | The text to display before the [Show/Hide] button. Supports wikitext such as italics and headers.
| Content | suggested |
Toggle Button | button | Specify what text (or template) should be used as the collapsible section toggle.
| Content | optional |
Section Class | class | Any CSS classes to style the entire collapsible section.
| Line | optional |
Label Style | style | CSS styles to apply to the label.
| Line | optional |
Collapsed | collapsed | Set to a blank value to prevent the section from being collapsed by default. | Line | optional |
Sample
Want the code to this sample?
Here's how this sample was made:
{{CollapseStart|Want the code to this sample?|button={{MWButton|Sure|class=progressive}}|class=toccolours}} Here's how this sample was made: ... {{CollapseEnd|Sample ends here.}}Sample ends here.