Template:Infobox object: Difference between revisions

Simplify categorization scheme; add support for CC namespace
sims>LostInRiverview
m (Icon causes wrapping issues)
(Simplify categorization scheme; add support for CC namespace)
 
(13 intermediate revisions by 5 users not shown)
Line 1:
<templatestyles src="Metainfobox/styles.css" /><!---*****OVERALL DESIGN CODE*****--->
<noinclude>{{under construction}}
{{Metabox
|type = Notice
|image = Icon-warning-48x48.png
|headline = NOT A "LIVE" TEMPLATE
|text = This template is still being worked on and tested. ''Please do not use this template on any articles!''
|nocat = true
}}
</noinclude>
<!---*****OVERALL DESIGN CODE*****--->
{| class="metainfobox {{lc: {{MGL | {{vgcode | {{#if:{{{basegame|}}}|{{{basegame}}}|{{{game<includeonly>|</includeonly>}}} }} }} }} }}" cellpadding="1.5"
! class="metainfobox-header large {{lc: {{MGL | {{vgcode | {{#if:{{{basegame|}}}|{{{basegame}}}|{{{game<includeonly>|</includeonly>}}} }} }} }} }}" colspan="2"{{!}}{{{name|{{PAGENAME}}}}}
Line 15 ⟶ 6:
{{!}} class="metainfobox-image" colspan="2" {{!}} {{{image}}}
{{!}}-
}}
{{#if: {{{caption<includeonly>|</includeonly>}}} |
{{!}} class="metainfobox-caption" colspan="2" {{!}} {{{caption}}}
{{!}}-
{{!}} class="metainfobox-header line {{lc: {{MGL | {{vgcode | {{#if:{{{basegame|}}}|{{{basegame}}}|{{{game<includeonly>|</includeonly>}}} }} }} }} }}" colspan="2" {{!}}
{{!}}-
}}
Line 23 ⟶ 17:
{{!}} class="metainfobox-caption" colspan="2" {{!}} {{{desc}}}
{{!}}-
{{!}} class="metainfobox-header line {{lc: {{MGL | {{vgcode | {{#if:{{{basegame|}}}|{{{basegame}}}|{{{game<includeonly>|</includeonly>}}} }} }} }} }}" colspan="2" {{!}}
}}
{{!}}-
}}
{{#if: {{{game<includeonly>|</includeonly>}}} |
Line 49 ⟶ 44:
{{!}}-
}}
{{#if: {{{type|{{{type1<includeonly>|</includeonly>}}} }}} |
{{!}} rowspan="{{#expr: 1+{{#if:{{{type2<includeonly>|</includeonly>}}}|1|0}}+{{#if:{{{type3<includeonly>|</includeonly>}}}|1|0}}+{{#if:{{{type4<includeonly>|</includeonly>}}}|1|0}}+{{#if:{{{type5<includeonly>|</includeonly>}}}|1|0}} }}" {{!}} Object type(s)
{{!}} {{{type|{{{type1}}} }}}
{{!}}-
}}
Line 86 ⟶ 81:
}}
|}
<includeonly>{{#ifeq: {{lc:Yesno-yes|{{{cat}}}}}|n| |{{#ifeq: {{lc:{{{cat}}}no=no}}|no| |{{#ifeq:{{NAMESPACE}}|<!-- Don't add categories --> |[[Category:Objects]]
{{Namespace detect
|main = [[Category:Objects]] {{GetObjectCats|game|{{{game}}}}}{{GetObjectCats|type|{{{type}}}}}{{GetObjectCats|type|{{{type1}}}}}{{GetObjectCats|type|{{{type2}}}}}{{GetObjectCats|type|{{{type3}}}}}{{GetObjectCats|type|{{{type4}}}}}{{GetObjectCats|type|{{{type5}}}}}{{GetObjectCats|buy|{{{buy}}}|{{{game}}}}}
|<!-- Not in Main namespace -->}}}}}}</includeonly><noinclude>
|custom = [[Category:Objects (custom)]] {{GetObjectCats|game|{{{game}}}}}{{GetObjectCats|type|{{{type}}}}}{{GetObjectCats|type|{{{type1}}}}}{{GetObjectCats|type|{{{type2}}}}}{{GetObjectCats|type|{{{type3}}}}}{{GetObjectCats|type|{{{type4}}}}}{{GetObjectCats|type|{{{type5}}}}}{{GetObjectCats|buy|{{{buy}}}|{{{game}}}}}
{{Documentation}}
}}
}}</includeonly><noinclude>{{clr}}{{Documentation}}
</noinclude>