Template:Switch: Difference between revisions
No edit summary |
No edit summary |
||
Line 3: | Line 3: | ||
-->'''<span class="_toggle {{{option1|Manga}}}"><span style="color:black;">{{{option1|Manga}}}</span></span><!-- |
-->'''<span class="_toggle {{{option1|Manga}}}"><span style="color:black;">{{{option1|Manga}}}</span></span><!-- |
||
INACTIVE STYLE 1 |
INACTIVE STYLE 1 |
||
--><span class="_toggle inact1 _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option3| |
--><span class="_toggle inact1 _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option3|One-Shot}}} _toggler_hide-{{{option4|OVA}}} _toggler_hide-{{{option5|Film}}} _toggler_hide-inact1 _toggler_show-{{{option1|Manga}}} _toggler_show-inact2 _toggler_show-inact3 _toggler_show-inact4 _toggler_show-inact5" style="display:none;">{{{option1|Manga}}}</span> - <!-- |
||
ACTIVE STYLE 2 |
ACTIVE STYLE 2 |
||
--><span class="_toggle {{{option2|Anime}}}" style="display:none;"><span style="color:black;">{{{option2|Anime}}}</span></span><!-- |
--><span class="_toggle {{{option2|Anime}}}" style="display:none;"><span style="color:black;">{{{option2|Anime}}}</span></span><!-- |
||
INACTIVE STYLE 2 (DEFAULT) |
INACTIVE STYLE 2 (DEFAULT) |
||
--><span class="_toggle inact2 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option3| |
--><span class="_toggle inact2 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option3|One-Shot}}} _toggler_hide-{{{option4|OVA}}} _toggler_hide-{{{option5|Film}}} _toggler_hide-inact2 _toggler_show-{{{option2|Anime}}} _toggler_show-inact1 _toggler_show-inact3 _toggler_show-inact4 _toggler_show-inact5">{{{option2|Anime}}}</span> - <!-- |
||
ACTIVE STYLE 3 |
ACTIVE STYLE 3 |
||
--><span class="_toggle {{{option3| |
--><span class="_toggle {{{option3|One-Shot}}}" style="display:none;"><span style="color:black;">{{{option3|One-Shot}}}</span></span><!-- |
||
INACTIVE STYLE 3 (DEFAULT) |
INACTIVE STYLE 3 (DEFAULT) |
||
--><span class="_toggle inact3 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option4|Film}}} _toggler_hide-inact3 _toggler_show-{{{option3| |
--><span class="_toggle inact3 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option4|One-Shot}}} _toggler_hide-{{{option5|Film}}} _toggler_hide-inact3 _toggler_show-{{{option3|One-Shot}}} _toggler_show-inact1 _toggler_show-inact2 _toggler_show-inact4 _toggler_show-inact5">{{{option3|One-Shot}}}</span> - <!---- |
||
ACTIVE STYLE 4 |
ACTIVE STYLE 4 |
||
--><span class="_toggle {{{ |
--><span class="_toggle {{{option3|OVA}}}" style="display:none;"><span style="color:black;">{{{option3|OVA}}}</span></span><!-- |
||
INACTIVE STYLE 4 (DEFAULT) |
INACTIVE STYLE 4 (DEFAULT) |
||
--><span class="_toggle inact4 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option3| |
--><span class="_toggle inact4 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option3|One-Shot}}} _toggler_hide-{{{option5|Film}}} _toggler_hide-inact4 _toggler_show-{{{option4|OVA}}} _toggler_show-inact1 _toggler_show-inact2 _toggler_show-inact3 _toggler_show-inact5">{{{option4|OVA}}}</span> - <!-- |
||
ACTIVE STYLE 5 |
|||
--><span class="_toggle {{{option5|Film}}}" style="display:none;"><span style="color:black;">{{{option5|Film}}}</span></span><!-- |
|||
INACTIVE STYLE 5 (DEFAULT) |
|||
--><span class="_toggle inact5 _toggler_hide-{{{option1|Manga}}} _toggler_hide-{{{option2|Anime}}} _toggler_hide-{{{option3|One-Shot}}} _toggler_hide-{{{option4|OVA}}} _toggler_hide-inact5 _toggler_show-{{{option5|Film}}} _toggler_show-inact1 _toggler_show-inact2 _toggler_show-inact3 _toggler_show-inact4">{{{option5|Film}}}</span>''' |
|||
{{Toggle |
{{Toggle |
||
| default = {{#ifeq: {{{image1|{{{1|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png| |
| default = {{#ifeq: {{{image1|{{{1|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png|{{ImageSize}}|No picture available]] | {{{image1|{{{1|}}} }}} }} |
||
| <!-- nothing |
| <!-- nothing |
||
-->| var = {{{option1|Manga}}} |
-->| var = {{{option1|Manga}}} |
||
Line 23: | Line 27: | ||
{{Toggle |
{{Toggle |
||
| <!-- nothing |
| <!-- nothing |
||
-->| sost = {{#ifeq: {{{image2|{{{2|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png| |
-->| sost = {{#ifeq: {{{image2|{{{2|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png|{{ImageSize}}|No picture available]] | {{{image2|{{{2|}}} }}} }} |
||
| var = {{{option2|Anime}}} |
| var = {{{option2|Anime}}} |
||
}} |
}} |
||
{{Toggle |
{{Toggle |
||
| <!-- nothing |
| <!-- nothing |
||
-->| sost = {{#ifeq: {{{image3|{{{3|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png| |
-->| sost = {{#ifeq: {{{image3|{{{3|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png|{{ImageSize}}|No picture available]] | {{{image3|{{{3|}}} }}} }} |
||
| var = {{{option3| |
| var = {{{option3|One-Shot}}} |
||
}} |
|||
{{Toggle |
|||
| <!-- nothing |
|||
-->| sost = {{#ifeq: {{{image4|{{{4|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png|{{ImageSize}}|No picture available]] | {{{image4|{{{4|}}} }}} }} |
|||
| var = {{{option4|OVA}}} |
|||
}} |
}} |
||
{{Toggle |
{{Toggle |
||
| <!-- nothing |
| <!-- nothing |
||
-->| sost = {{#ifeq: {{{ |
-->| sost = {{#ifeq: {{{image5|{{{5|}}} }}} | <!-- no value --> | [[File:NoPicAvailable.png|{{ImageSize}}|No picture available]] | {{{image5|{{{5|}}} }}} }} |
||
| var = {{{ |
| var = {{{option5|Film}}} |
||
}}<noinclude> |
}}<noinclude> |
||
{{Documentation}} |
{{Documentation}} |
Revision as of 03:13, 15 March 2018
Manga - Anime - One-Shot - OVA - Film Template:Toggle Template:Toggle Template:Toggle Template:Toggle Template:Toggle
Template Documentation (sometimes hidden or invisible)
Template tools: purge • what links here • what transclude this • subpages |
- Description
This template is used to do create a switch between two images, useful for {{Character Infobox}}.
- Dependencies
This template uses File:NoPicAvailable.png.
- Syntax
{{Switch |option1 = Text image 1 <!-- Default --> |image1 = Image 1 <!-- Default --> |option2 = Text image 2 |image2 = Image 2 }}
- Parameters
- option1= the text associated with image 1 (this is the default text) - optional, default:
Post Timeskip
. - image1/1= the default image to be displayed, can be given as first free parameter - default: File:NoPicAvailable.png.
- option2= the text associated with image 2 - optional, default:
Pre Timeskip
. - image2/2= the secondary image, can be given as second free parameter - default: File:NoPicAvailable.png..
- Samples
Manga - Anime - One-Shot - OVA - Film Template:Toggle Template:Toggle Template:Toggle Template:Toggle Template:Toggle
{{Switch | [[File:Jotaro SC Infobox Manga.png|250px|Jotaro Kujo]] <!-- Default --> | [[File:Jotaro SC Infobox Anime.png|250px|Jotaro Kujo]] }}
Second part - First part - One-Shot - OVA - Film Template:Toggle Template:Toggle Template:Toggle Template:Toggle Template:Toggle
With custom options:
{{Switch | option1 = Second part <!-- Default --> | image1 = [[File:Jotaro SC Infobox Manga.png|250px|Jotaro Kujo]] <!-- Default --> | option2 = First part | image2 = [[File:Jotaro SC Infobox Anime.png|250px|Jotaro Kujo]] }}
Second part - First part - One-Shot - OVA - Film Template:Toggle Template:Toggle Template:Toggle Template:Toggle Template:Toggle
With missing images:
{{Switch | option1 = Second part <!-- Default --> | image1 = [[File:Jotaro SC Infobox Anime.png|250px|Jotaro Kujo]] <!-- Default --> | option2 = First part | image2 = }}
Visit Template:Switch/doc to edit this text! (How does this work?) (Refresh this text)