yoohoo! hot sauce please

10:27, 7 September 2026 (UTC)

Template:Collapsegallery: Difference between revisions

From 2swagg wiki
Jump to navigationJump to search
Bulgogi2 (talk | contribs)
Created page with "<includeonly><div style="{{#if:{{{3|}}}|text-align:{{{3}}};}}"> <div style="display: inline-block; {{#if:{{{border|}}}|border:.5em solid {{{border}}}; border-radius:{{{radius|.9em}}}|border:1px solid #000;}};"> <!-- Header --> <div style="background-color:{{{border|#000}}}; color:{{{color|#fff}}}; text-align:left; padding:5px;"><span style="font-size:14pt;">{{{1}}}</span></div> <!-- Teaser -->{{{4}}} <!-- Collapsing Link --> <div class="collapsibletoggle" style="text-ali..."
 
Bulgogi2 (talk | contribs)
mNo edit summary
 
(2 intermediate revisions by the same user not shown)
Line 11: Line 11:
</div>{{#if:{{{more_images|}}}|<center>{{{more_images}}}</center>|}}</includeonly><noinclude>
</div>{{#if:{{{more_images|}}}|<center>{{{more_images}}}</center>|}}</includeonly><noinclude>
== Usage ==
== Usage ==
Stolen from ED. This is the collapsing gallery template. See [[Soyjak Wiki:Collapsing objects]] for an explanation.<br>
Stolen from the 'ty and ED. This is the collapsing gallery template. See [[2swagg Wiki:Collapsing objects]] for an explanation.<br>
You can also add multiple gallery headings inside the box by using {{t|Collapsegalleryheader}}.
You can also add multiple gallery headings inside the box by using {{t|Collapsegalleryheader}}.


Line 50: Line 50:
File:
File:
</gallery>|<gallery>
</gallery>|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>}}
</gallery>}}


; Rounded:
; Rounded:
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>|<gallery>
</gallery>|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>|border=blue|color=cyan}}</pre>
</gallery>|border=blue|color=cyan}}</pre>


Line 64: Line 64:
; Traditional (border isn't set):
; Traditional (border isn't set):
{{Collapsegallery|Hello, world!|cg1|center|<gallery>
{{Collapsegallery|Hello, world!|cg1|center|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>|<gallery>
</gallery>|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>}}
</gallery>}}


; Rounded:
; Rounded:
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>|<gallery>
</gallery>|<gallery>
File:Soot.png
File:SomeBois.png
</gallery>|border=blue|color=cyan}}
</gallery>|border=blue|color=cyan}}


[[Category:Formatting Templates|{{PAGENAME}}]]</noinclude>
[[Category:Formatting Templates|{{PAGENAME}}]]</noinclude>

Latest revision as of 08:25, 15 October 2026

Usage[edit source]

Stolen from the 'ty and ED. This is the collapsing gallery template. See 2swagg Wiki:Collapsing objects for an explanation.
You can also add multiple gallery headings inside the box by using {{Collapsegalleryheader}}.

Syntax:

{{collapsegallery | 1=title | 2=id | 3=align | 4=<gallery> teaser </gallery> | 5=<gallery> expanded </gallery> | border | color}}
title
id unique id for collapse gallery (examples: cg1, cg2, etc.). IDs may not contain spaces or special characters. Do not put spaces/special characters in the ID.
align left, right or center, default is left.
4 teaser gallery
5 expanded gallery
border border color and have it be thicker with rounded edges. default is the traditional collapse gallery style.
color title color, default is white.

Example[edit source]

This:

; Traditional (border isn't set):
{{Collapsegallery|Hello, world!|cg1|center|<gallery>
File:
</gallery>|<gallery>
File:SomeBois.png
</gallery>}}

; Rounded:
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
File:SomeBois.png
</gallery>|<gallery>
File:SomeBois.png
</gallery>|border=blue|color=cyan}}

results in this:

Traditional (border isn't set)
Hello, world!
[Collapse GalleryExpand Gallery]
Rounded
Hello, world!
[Collapse GalleryExpand Gallery]