Template:Character Tabs: Difference between revisions

Template page
m (QC)
mNo edit summary
Line 1: Line 1:
<noinclude>
<includeonly>
<ul class="NOL-tabs>
<li style="display:inline-block;">[[{{{1}}}|Main]]<span class="NOL-tabs-divider"> &middot; </span></li>
<li style="display:inline-block;">[[{{{1}}}/Gallery|Gallery]]<span class="NOL-tabs-divider"> &middot; </span></li>
<li style="display:inline-block;">[[{{{1}}}/Movelist|Movelist]]<span class="NOL-tabs-divider"> &middot; </span></li>
<li style="display:inline-block;">[[{{{1}}}/Quotes|Quotes]]<span class="NOL-tabs-divider"> &middot; </span></li>
</ul>
<hr><!--
--></includeonly><!--
 
DOCUMENTATION BEGINS BELOW
 
--><noinclude>
== Preview ==
== Preview ==


===Default===
This template will not show links to pages that do not exist (i.e. are redlinked and carry the class "new" (<code>a.new</code>). <ref>This feature requires the following lines of css be added to any skin (i.e. to "Common.css" and "Mobile.css") that does not already include it (any skin other than the Cathedral skin):
 
<pre>
/* CUSTOM TABS */
.NOL-tabs li {
display: inline-block;
}
/* float the bullet points to the left of each item */
.NOL-tabs-divider {
    float: left;
    margin: 0px 5px;
}
/* hide new links */
.NOL-tabs > a.new {
    display: none !important;
}
/* hide bullet points for new links */
.NOL-tabs li a.new ~ span.NOL-tabs-divider {
    display: none;
}
/* hide bullet points for the first listed item */
.NOL-tabs li:first-child a ~ span.NOL-tabs-divider {
display:none;
}</pre></ref>
{{Character Tabs|Kagura Mutsuki}}
{{Character Tabs|Kagura Mutsuki}}
{{Character Tabs|Kagura Mutsuki|Gallery}}
{{Character Tabs|Kagura Mutsuki|Gallery}}
===With movelist subpage===
{{Character Tabs|Kagura Mutsuki||Movelist=yes}}
{{Character Tabs|Kagura Mutsuki|Gallery|Movelist=yes}}


== Usage ==
== Usage ==
===Default===
<pre><nowiki>
<pre><nowiki>
On the character's page:
On the character's page:
Line 24: Line 51:
</nowiki></pre>
</nowiki></pre>


===To show the movelist subpage===
== Notes ==
<pre><nowiki>
{{#tag:references}}
{{Character Tabs|character name|subpage
  | Movelist=anything that's not blank, including "no" (leave blank or remove this parameter for "no")
}}
{{Character Tabs|Kagura Mutsuki||Movelist=yes}}
{{Character Tabs|Kagura Mutsuki|Gallery|Movelist=yes}}
</nowiki></pre>


</noinclude><includeonly>
</noinclude>
<!-- use this when I get around to making a theme.
<ul class="charnav">
  <li {{#if:{{{2|}}}|>[[{{{1}}}]]|class=active>{{{1}}}}}</li>
  <li {{#ifeq:{{{2}}}|Gallery|class=active>Gallery|>[[{{{1}}}/Gallery|Gallery]]}}</li>
  <li {{#ifeq:{{{2}}}|Movelist|class=active>Movelist|>[[{{{1}}}/Movelist|Movelist]]}}</li>
</ul>
-->{{#if: {{{2|}}}
    | [[ {{{1}}} |Main]]
    | '''Main'''}}<!--
--> &middot; {{#ifeq: {{{2}}} | Gallery
    | '''Gallery'''
    | [[ {{{1}}}/Gallery |Gallery]] }}<!--
-->{{#if:{{{Movelist|}}}| &nbsp;&middot; {{#ifeq: {{{2}}} | Movelist
    | '''Movelist'''
    | [[{{{1}}}/Movelist|Movelist]] }}
  |}}<!--
--><!-- &middot; {{#ifeq: {{{2}}} | Quotes
    | '''Quotes'''
    | [[{{{1}}}/Quotes|Quotes]]}}
-->
<hr></includeonly>

Revision as of 03:40, 10 January 2018

Preview

This template will not show links to pages that do not exist (i.e. are redlinked and carry the class "new" (a.new). [1]



Usage

On the character's page:
{{Character Tabs|character name}}
{{Character Tabs|Kagura Mutsuki}}

On a character's subpage:
{{Character Tabs|character name|subpage}}
{{Character Tabs|Kagura Mutsuki|Gallery}}

Notes

  1. This feature requires the following lines of css be added to any skin (i.e. to "Common.css" and "Mobile.css") that does not already include it (any skin other than the Cathedral skin):
    /* CUSTOM TABS */
    .NOL-tabs li {
    	display: inline-block;
    }
    /* float the bullet points to the left of each item */
    .NOL-tabs-divider {
        float: left;
        margin: 0px 5px;
    }
    /* hide new links */
    .NOL-tabs > a.new {
        display: none !important;
    }
    /* hide bullet points for new links */
    .NOL-tabs li a.new ~ span.NOL-tabs-divider {
        display: none;
    }
    /* hide bullet points for the first listed item */
    .NOL-tabs li:first-child a ~ span.NOL-tabs-divider {
    	display:none;
    }