Difference between revisions of "Template:Infobox"

From FEX-Emu Wiki
Jump to navigation Jump to search
 
(85 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<includeonly>{{Infobox
+
<div class="infobox">
 +
<div class="infobox-title">{{{title|{{PAGENAME}}}}}</div>
 +
{{#if:{{{image|}}}|<div class="infobox-image">[[File:{{{image}}}|300px]]</div>}}
 +
{{#if:{{{steamheader|}}}|<div class="portrait300px">https://cdn.cloudflare.steamstatic.com/steam/apps/{{{steamheader}}}/header.jpg</div>|{{#if:{{{steamappid|}}}|<div class="portrait300px">https://cdn.cloudflare.steamstatic.com/steam/apps/{{{steamappid}}}/library_600x900.jpg</div>}}|}}
 +
{|
  
<!-- Start and styling -->
+
{{#if:{{{steamappid|}}}{{{gogurl|}}}|
| child          = {{{child|}}}
+
    <!-- First element -->
| subbox        = {{{subbox|}}}
+
    {{!}}'''Storefronts'''
| italic title  = {{{italic title|<noinclude>no</noinclude>}}}
+
{{!!}}
| bodystyle      = float: {{{align|right}}}; width: {{#if:{{{width|}}}|{{{width|}}}|22em}}; font-size: 90%; text-align: left; border-spacing: 3px;
+
{{#if:{{{steamappid|}}}|
| bodyclass      = {{#ifeq:{{{collapsible|}}}|yes|collapsible {{#if:{{{state|}}}|{{{state}}}|autocollapse}}}} hproduct
+
{{#regex:{{{steamurl}}}|/([^,]+)(,? ?)/rs|
| labelstyle    = white-space:nowrap;padding-right:0.65em<!--(to ensure gap between any long/nonwrapped label and subsequent data on same line-->;
+
[[Image:Steam_logo.svg|24px|link=https://store.steampowered.com/app/{{{steamappid}}}]]}}[[Category:On Steam]]
| datastyle      = line-height:1.3em;
+
}}
| aboveclass    = fn
+
{{#if:{{{gogurl|}}}|
| abovestyle    = font-size:110%;font-style:italic;
+
{{#regex:{{{gogurl}}}|/([^,]+)(,? ?)/rs|
 
+
[[Image:Gog_logo.svg|24px|link=$1]]}}[[Category:On GOG]]
<!-- Title -->
+
}}
| above          = <includeonly>{{{title|{{#if:{{#invoke:WikidataIB|label}}|{{#invoke:WikidataIB|label}}|{{PAGENAMEBASE}}}}}}}</includeonly>
+
{{!}}</tr>|
 
+
}}
<!-- Image -->
+
{{#if:{{{os|}}}|{{!}}'''Operating Systems'''{{!!}}{{#ifeq:{{#regex:{{{os|}}}|/>/rs|}}||
| image          = {{#invoke:InfoboxImage|InfoboxImage|image={{#invoke:WikidataIB |getValue|rank=best|P18 |name=image |qid={{{qid|}}} |suppressfields={{{suppressfields|}}} |fetchwikidata={{{fetchwikidata|ALL}}} |onlysourced=no |noicon=yes|{{{image|}}}}}|size={{{image size|{{{image_size|{{{imagesize|}}}}}}}}}|sizedefault=frameless|upright={{{image_upright|1}}}|alt={{{alt|}}}|border={{{border|}}}|suppressplaceholder=yes}}
+
<!--List-->{{#regex:{{{os|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Games|$1]][[Category:$1 Games]]$2}}</tr>|
| captionstyle  = font-size: 95%;
+
}}}}
| caption        = {{#if:{{{image|}}}|{{{caption|}}}|{{{caption|{{#invoke:WikidataIB|getValue|P18|qual=P2096|qualsonly=y|fwd=ALL}}}}}}}
+
{{#if:{{{engine|}}}|{{!}}'''Engine'''{{!!}}{{#ifeq:{{#regex:{{{engine|}}}|/>/rs|}}||
 
+
<!--List-->{{#regex:{{{engine|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Engine|$1]][[Category:$1 Engine]]$2}}</tr>|
 
+
}}}}
<!-- Start of content -->
+
{{#if:{{{arch|}}}|{{!}}'''Architecture'''{{!!}}{{#ifeq:{{#regex:{{{arch|}}}|/>/rs|}}||
| label2  = [[Video game developer|Developer(s)]]
+
<!--List-->{{#regex:{{{arch|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1|$1]][[Category:$1]]$2}}</tr>|
| data2  = {{{developer|{{If first display both|{{#invoke:WikidataIB|getValue|rank=best|P178|qid={{{qid|}}}|name=developer|suppressfields={{{suppressfields|}}}|fetchwikidata={{{fetchwikidata|ALL}}}|onlysourced={{{onlysourced|no}}}|noicon={{{noicon|no}}}|sep="<br />"|sorted=yes|{{{developer|}}} }}|{{#ifeq:{{{refs|no}}}|yes|{{wikidata|references|normal+|{{{qid|}}}|P178}}}}}}}}}
+
}}}}
 
+
{{#if:{{{cpufeats|}}}|{{!}}'''CPU Features Used'''{{!!}}{{#ifeq:{{#regex:{{{cpufeats|}}}|/>/rs|}}||
</includeonly>
+
<!--List-->{{#regex:{{{cpufeats|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 CPU Feature|$1]][[Category:$1 CPU Feature]]$2}}</tr>|
<noinclude>
+
}}}}
{{documentation}}
+
{{#if:{{{compat|}}}|{{!}}'''Compatibility'''{{!!}}{{#ifeq:{{#regex:{{{compat|}}}|/>/rs|}}||
<!-- Categories go in the /doc subpage, and interwikis go in Wikidata. -->
+
<!--List-->{{#regex:{{{compat|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Compatibility|$1]][[Category:$1 Compatibility]]$2}}</tr>|
</noinclude>
+
}}}}
 +
{{#if:{{{apptype|}}}|{{!}}'''Type'''{{!!}}{{#ifeq:{{#regex:{{{apptype|}}}|/>/rs|}}||
 +
<!--List-->{{#regex:{{{apptype|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Type Application|$1]][[Category:$1 Type Application]]$2}}</tr>|
 +
}}}}
 +
{{#if:{{{renderapi|}}}|{{!}}'''Render API'''{{!!}}{{#ifeq:{{#regex:{{{renderapi|}}}|/>/rs|}}||
 +
<!--List-->{{#regex:{{{renderapi|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Render API|$1]][[Category:$1 Render API]]$2}}</tr>|
 +
}}}}
 +
{{#if:{{{workingthunks|}}}|{{!}}'''Supported Thunks'''{{!!}}{{#ifeq:{{#regex:{{{workingthunks|}}}|/>/rs|}}||
 +
<!--List-->{{#regex:{{{workingthunks|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Thunk Capable|$1]][[Category:$1 Thunk Capable]]$2}}</tr>|
 +
}}}}
 +
{{#if:{{{nonworkingthunks|}}}|{{!}}'''Unsupported Thunks'''{{!!}}{{#ifeq:{{#regex:{{{nonworkingthunks|}}}|/>/rs|}}||
 +
<!--List-->{{#regex:{{{nonworkingthunks|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 Thunk Incapable|$1]][[Category:$1 Thunk Incapable]]$2}}</tr>|
 +
}}}}
 +
{{#if:{{{drm|}}}|{{!}}'''DRM'''{{!!}}{{#ifeq:{{#regex:{{{drm|}}}|/>/rs|}}||
 +
<!--List-->{{#regex:{{{drm|}}}|/([^,]+)(,? ?)/rs|[[:Category:$1 DRM|$1]][[Category:$1 DRM]]$2}}</tr>|
 +
}}}}
 +
|}
 +
</div>

Latest revision as of 01:21, 24 November 2022

Infobox