Template:Collapse top/doc: Difference between revisions
Jump to navigation
Jump to search
Add information for |left=true parameter with an example shown.
w:en>JPaestpreornJeolhlna (Format) |
w:en>John Cline (Add information for |left=true parameter with an example shown.) |
||
Line 23: | Line 23: | ||
;positional parameter 1, named parameter 'title': These parameters give the main title of collapsed box, which occurs on the same line as the ''show'' link and is always visible. It defaults to 'Extended content'. | ;positional parameter 1, named parameter 'title': These parameters give the main title of collapsed box, which occurs on the same line as the ''show'' link and is always visible. It defaults to 'Extended content'. | ||
;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.}}" | ;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.}}" | ||
;positional parameter 2: This is optional warning-line text. It will override the standard warning line above, and obviate the need for setting the 'warning' parameter. | ;positional parameter 2: This is optional warning-line text. It will override the standard warning line above, and obviate the need for setting the 'warning' parameter. | ||
;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. | |||
;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. | ;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. | ||
;bg: Sets the background color of the collapsed material. Defaults to #CFC - a pleasant green. Other colors available from [[List of colors]]. | ;bg: Sets the background color of the collapsed material. Defaults to #CFC - a pleasant green. Other colors available from [[List of colors]]. | ||
Line 37: | Line 38: | ||
== Examples == | == Examples == | ||
*aligning title along left margin - <nowiki>{{Collapse top|left=true}} or {{cot|left=right}}</nowiki> | |||
{{cot|left=right}} | |||
Text | |||
{{cob}} | |||
*changing background color - <nowiki>{{Collapse top|bg=#F0F2F5}} or {{cot|bg=#F0F2F5}}</nowiki> | *changing background color - <nowiki>{{Collapse top|bg=#F0F2F5}} or {{cot|bg=#F0F2F5}}</nowiki> | ||
{{cot|bg=#F0F2F5}} | {{cot|bg=#F0F2F5}} |