Template:CollapseGallery: Difference between revisions
Jump to navigation
Jump to search
(Template for collapsible galleries) |
No edit summary |
||
Line 51: | Line 51: | ||
<pre>; Traditional (border isn't set): | <pre>; Traditional (border isn't set): | ||
{{Collapsegallery|Hello, world!|cg1|center|<gallery> | {{Collapsegallery|Hello, world!|cg1|center|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>|<gallery> | </gallery>|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>}} | </gallery>}} | ||
; Rounded: | ; Rounded: | ||
{{Collapsegallery|Hello, world!|cg2|center|<gallery> | {{Collapsegallery|Hello, world!|cg2|center|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>|<gallery> | </gallery>|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>|border=blue|color=cyan}}</pre> | </gallery>|border=blue|color=cyan}}</pre> | ||
Line 67: | Line 67: | ||
; Traditional (border isn't set): | ; Traditional (border isn't set): | ||
{{CollapseGallery|Hello, world!|cg1|center|<gallery> | {{CollapseGallery|Hello, world!|cg1|center|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>|<gallery> | </gallery>|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>}} | </gallery>}} | ||
; Rounded: | ; Rounded: | ||
{{CollapseGallery|Hello, world!|cg2|center|<gallery> | {{CollapseGallery|Hello, world!|cg2|center|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>|<gallery> | </gallery>|<gallery> | ||
File: | File:Wikigetstarted.jpg | ||
</gallery>|border=blue|color=cyan}} | </gallery>|border=blue|color=cyan}} | ||
[[Category:Templates|{{PAGENAME}}]]</noinclude> | [[Category:Templates|{{PAGENAME}}]]</noinclude> |
Revision as of 01:21, 3 June 2022
Usage
Do not put any of these on the ID or the gallery will be glitched!
- Spaces (example:
Wasteland
) - An ID already used by another gallery (example: two galleries with the ID "
CollapseGallery
")
This is the collapsing gallery template.
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.). id's may not contain spaces. Do not include spaces 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
This:
; Traditional (border isn't set): {{Collapsegallery|Hello, world!|cg1|center|<gallery> File:Wikigetstarted.jpg </gallery>|<gallery> File:Wikigetstarted.jpg </gallery>}} ; Rounded: {{Collapsegallery|Hello, world!|cg2|center|<gallery> File:Wikigetstarted.jpg </gallery>|<gallery> File:Wikigetstarted.jpg </gallery>|border=blue|color=cyan}}
results in this:
- Traditional (border isn't set)
{{#if:|
|}}
- Rounded
{{#if:|
|}}