Template:Collapsegallery: Difference between revisions

From Encyclopedia Dramatica
Jump to navigation Jump to search
imported>JuniusThaddeus
Note.
imported>TabbyGarf
No edit summary
Line 1: Line 1:
<includeonly><div style="{{#if:{{{3|}}}|text-align:{{{3}}};}}">
<includeonly><table cellpadding="5" cellspacing="0" border="0" style="{{#if:{{{border|}}}|border:.5em solid {{{border}}};{{roundy|{{{radius|.9em}}}}}|border:1px solid black;}}" align="{{#switch:{{{3}}}|center=center|left=left|right=right|left}}">
<div style="display: inline-block; {{#if:{{{border|}}}|border:.5em solid {{{border}}}; {{roundy|{{{radius|.9em}}}}}|border:1px solid #000;}};">
<!-- Header -->
<!-- Header -->
<div style="background-color:{{{border|#000}}}; color:{{{color|#fff}}}; text-align:left; padding:5px;"><span style="font-size:14pt;">{{{1}}}</span> <span style="font-size:6pt;">[[Template:pixplz|About&nbsp;missing&nbsp;Pics]]</span></div>
<tr style="background-color:{{{border|black}}};color:{{{color|white}}};font-size:14pt;">
<!-- Teaser -->{{{4}}}
<td align="left">{{{1}}}<div class="mw-collapsible mw-collapsed"><div class="mw-collapsible-content"></td>
<td align="right" style="font-size:6pt;">[[Template:pixpls|About&nbsp;missing&nbsp;Pics]]</td>
</tr>
<!-- Teaser -->
<tr>
<td align="center" colspan="2">{{{4}}}</td>
</tr>
<!-- Collapsing Link -->
<!-- Collapsing Link -->
<div class="collapsibletoggle" style="text-align:right; font-size:14pt; font-weight:bold; padding:0 5px 5px 5px;">[<span class="mw-customtoggle-{{{2}}} showhidetext"><span class="collapsibletoggletext hiddentext">Collapse Gallery</span><span class="collapsibletoggletext">Expand Gallery</span></span>]</div>
<tr>
<td align="right" colspan="2"></td>
</tr>
<!-- Rest of Gallery -->
<!-- Rest of Gallery -->
<div id="mw-customcollapsible-{{{2}}}" class="mw-collapsible mw-collapsed">{{{5}}}</div>
<tr>
><td align="center" colspan="2"><span class="{{{2}}}">{{{5}}}</span></td></div>
</tr>
 
</div>
</div>
</div>{{#if:{{{more_images|}}}|<center>{{{more_images}}}</center>|}}</includeonly><noinclude>
</table></includeonly><noinclude>
{{clear}}
 
== Usage ==
== Usage ==


This is the collapsing gallery template. See [[Encyclopedia Dramatica:Collapsing Objects]] for an explanation.
This is the collapsing gallery template. See [[Encyclopedia Dramatica:Collapsing Objects]] for an explanation.
 
Syntax


'''<pre>{{collapsegallery | 1=title | 2=id | 3=align | 4=<gallery> teaser </gallery> | 5=<gallery> expanded </gallery> | border | color}}</pre>'''
<nowiki>{{collapsegallery | 1=title | 2=id | 3=align | 4=<gallery> teaser </gallery> | 5=<gallery> expanded </gallery> | border | color}}</nowiki>


{| border="1"
{| border="1"
Line 24: Line 34:
|-
|-
!id
!id
|unique id for collapse gallery (examples: cg1, cg2, etc.). ''[https://www.w3.org/TR/2011/WD-html5-20110525/elements.html#the-id-attribute id's may not contain spaces].'' '''Do not include spaces in the id.'''
|unique id for collapse gallery (example:cg1, cg2, etc.)
|-
|-
!align
!align
Line 42: Line 52:
|}
|}


=== Example ===
== Example ==


This:
<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:Popcorn3.gif
File:Popcorn3.gif
Line 53: Line 63:
</gallery>}}
</gallery>}}


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


results in this:
== Output ==
 
=== Traditional (border isn't set) ===


; Traditional (border isn't set):
{{Collapsegallery|Hello, world!|cg1|center|<gallery>
{{Collapsegallery|Hello, world!|cg1|center|<gallery>
File:Popcorn3.gif
File:Popcorn3.gif
Line 69: Line 82:
</gallery>}}
</gallery>}}


; Rounded:
=== Rounded ===
 
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
{{Collapsegallery|Hello, world!|cg2|center|<gallery>
File:Popcorn2.gif
File:Popcorn2.gif

Revision as of 13:20, 7 January 2021

Usage

This is the collapsing gallery template. See Encyclopedia Dramatica:Collapsing Objects for an explanation.

{{collapsegallery | 1=title | 2=id | 3=align | 4=<gallery> teaser </gallery> | 5=<gallery> expanded </gallery> | border | color}}

title
id unique id for collapse gallery (example:cg1, cg2, etc.)
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

=== Traditional (border isn't set) ===

{{Collapsegallery|Hello, world!|cg1|center|<gallery>
File:Popcorn3.gif
</gallery>|<gallery>
File:Popcorn4.gif
</gallery>}}

=== Rounded ===

{{Collapsegallery|Hello, world!|cg2|center|<gallery>
File:Popcorn2.gif
</gallery>|<gallery>
File:Popcorn4.gif
</gallery>|border=blue|color=cyan}}

Output

Traditional (border isn't set)

>
Hello, world!
About missing Pics

Rounded

>
Hello, world!
About missing Pics