Template:Collapse top/doc: Difference between revisions

update
w:en>Giraffedata
(simplify)
w:en>SMcCandlish
(update)
Line 28: Line 28:
;warning: If this parameter evaluates to true (i.e. is not empty) it will display a default warning line under the main title which reads "The following is a closed debate. {{strongbad|Please do not modify it.}}" For example, <code><nowiki>{{collapse top|This is the title text|warning=true}}</nowiki></code>
;warning: If this parameter evaluates to true (i.e. is not empty) it will display a default warning line under the main title which reads "The following is a closed debate. {{strongbad|Please do not modify it.}}" For example, <code><nowiki>{{collapse top|This is the title text|warning=true}}</nowiki></code>
;positional parameter 2: This is optional warning-line text. It will override the standard warning line above, and make the 'warning' parameter unnecessary. For example, <code><nowiki>{{collapse top|This is the title text|This is a custom warning line}}</nowiki></code>
;positional parameter 2: This is optional warning-line text. It will override the standard warning line above, and make the 'warning' parameter unnecessary. For example, <code><nowiki>{{collapse top|This is the title text|This is a custom warning line}}</nowiki></code>
;left: If this parameter evaluates to true (i.e. is not empty) it will align the 'parameter 1 title' along the left margin. Text aligns centered between the left margin and the left bracket of the left ''show'' link by default. For example, <code><nowiki>{{collapse top|This is the title text|left=true}}</nowiki></code>
;cemter: If this parameter evaluates to true (i.e. is not empty) it will center the 'parameter 1 title', between the left margin and the left bracket of the left ''show'' link (by default, it is left-aligned, along the left margin). For example, <code><nowiki>{{collapse top|This is the title text|center=y}}</nowiki></code>
;expand: If this parameter evaluates to true (i.e. is not empty) it will leave the material uncollapsed with the border and coloring. Default is to collapse the material. For example, <code><nowiki>{{collapse top|This is the title text|expand=true}}</nowiki></code>
;expand: If this parameter evaluates to true (i.e. is not empty) it will leave the material uncollapsed with the border and coloring. Default is to collapse the material. For example, <code><nowiki>{{collapse top|This is the title text|expand=true}}</nowiki></code>
;bg: Sets the background color of the collapsed material. Defaults to #CFC - a pleasant green. Other colors available from [[List of colors]]. For example, <code><nowiki>{{collapse top|This is the title text|bg=#F0F2F5}}</nowiki></code>
;bg: Sets the background color of the collapsed material. Defaults to #CFC - a pleasant green. Other colors available from [[List of colors]]. For example, <code><nowiki>{{collapse top|This is the title text|bg=#F0F2F5}}</nowiki></code>
Line 55: Line 55:
{{lorem ipsum}}
{{lorem ipsum}}
{{collapse bottom}}
{{collapse bottom}}
* Aligning box title along left margin - <code><nowiki>{{collapse top|left=true}} or {{collapse top|left=true}}</nowiki></code>
* Centering box title along - <code><nowiki>{{collapse top|center=yes}} or {{collapse top|center=yes}}</nowiki></code>
{{collapse top|left=true}}
{{collapse top|center=yes}}
{{lorem ipsum}}
{{lorem ipsum}}
{{collapse bottom}}
{{collapse bottom}}
Anonymous user