Actions

Template

Difference between revisions of "CharacterGallery"

From Sonic Retro

m
m
Line 1: Line 1:
<includeonly>
+
<includeonly><!--{{#css:
{{#dpl:
+
##VERSION2##
|category={{{1}}}
+
.charGalleryText {
|include={CharacterBob}:image1,{CharacterBob}:image1,{CharacterBob}:charname,{CharacterBob}:charname,{CharacterBob}:charname,{CharacterBob}:debut,{CharacterBob}:debut
+
  background:#000;
 +
  filter: alpha(opacity=80);
 +
  opacity: 0.8;
 +
  left:0;
 +
  bottom:0;
 +
  right:0;
 +
  padding:5px;
 +
  text-align:left;
 +
}
 +
}}-->{{#dpl:
 +
|categorymatch={{{1}}}
 +
|include={CharacterBob}:image1,{CharacterBob}:image1,{CharacterBob}:charname,{CharacterBob}:charname,{CharacterBob}:debut
 
|ordermethod=title
 
|ordermethod=title
 
|order=ascending
 
|order=ascending
 
|mode = userformat
 
|mode = userformat
|secseparators = <div class="posrel shadow" style="float:left;margin:10px">²{#ifexist:File:,,¦²{Bobscreen¦,,¦height=144¦link=%PAGE%}²¦[[Image:Notavailable.svg{{!}}x144px{{!}}link=%PAGE%]]}²<br><span class="posabs" style="background:#000;opacity: 0.8;left:0;bottom:0;right:0;padding:5px;text-align:left;">²{#if:,,¦<span style="font-size:110%">'''[[,,¦<span style="color:#fff;filter: alpha(opacity=100)">,,</span>]]'''</span>¦<span style="font-size:110%;">'''[[%PAGE%¦<span style="color:#fff;filter: alpha(opacity=100)">%PAGE%</span>]]'''</span>}² ²{#ifeq:{{{gameTitle}}}¦hide¦<span style="display:none">¦<br />}²''[[,,¦<span style="color:#fff;filter: alpha(opacity=100)">,</span>]]''²{#ifeq:{{{gameTitle}}}¦hide¦</span>¦}²</span></div>  \n  
+
|secseparators = <div class="posrel shadow" style="float:left;margin:10px">²{#ifexist:File:,,¦²{Bobscreen¦,,¦height=144¦link=%PAGE%}²¦[[Image:Notavailable.svg{{!}}x144px{{!}}link=%PAGE%]]}²<br><div class="posabs" style="background:#000;opacity:0.8;left:0;bottom:0;right:0;padding:5px;text-align:left;">²{#if:,,¦'''[[,,]]'''¦'''[[%PAGE%]]'''}² ²{#ifeq:{{{gameTitle}}}¦hide¦<span style="display:none">¦<br />}²''[[,]]''²{#ifeq:{{{gameTitle}}}¦hide¦</span>¦}²</div></div>  \n  
}}
+
}}{{clear}}</includeonly><noinclude>{{TODO}}
 
 
</includeonly><noinclude>{{TODO}}{{cleanup|Unknown formatting issues, specially what happens to text that appears following a usage of the template, and also (but less important) what happens with certain debut game title texts. [see as reference the examples in this page]}}
 
 
==Usage==
 
==Usage==
 
Use with a category that includes character articles to create a gallery of those characters.  In order for this to work properly, level articles need to be using [[:Template:CharacterBob]].  For example, this:
 
Use with a category that includes character articles to create a gallery of those characters.  In order for this to work properly, level articles need to be using [[:Template:CharacterBob]].  For example, this:
Line 22: Line 31:
 
[[Category:Navigational templates|{{PAGENAME}}]]
 
[[Category:Navigational templates|{{PAGENAME}}]]
 
</noinclude>
 
</noinclude>
 +
<includeonly><noinclude>TemplateVERSION2 seems to have solved the issues, but I'm not quite sure, so I won't remove the tags as this is still an unfinished task as of now, without further information. TemplateVERSION1 is just scrapped at this point as it doesn't work better at all. Solved Issues in question:{{cleanup|Unknown formatting issues, specially what happens to text that appears following a usage of the template, and also (but less important) what happens with certain debut game title texts. [see as reference the examples in this page]}}
 +
</noinclude></includeonly>

Revision as of 08:04, 26 June 2024

Clock.svg
This task is unfinished
This is a wiki task that requires more thought or peer review. An important issue that needs to be solved, which will appear at the top of Sonic Retro:Todo until this message is removed.

Usage

Use with a category that includes character articles to create a gallery of those characters. In order for this to work properly, level articles need to be using Template:CharacterBob. For example, this:

{{CharacterGallery|Sonic transformations}}

produces this:

Add gameTitle=hide to hide the game title:

{{CharacterGallery|Sonic transformations|gameTitle=hide}}