Template:Producer icon: Difference between revisions

From Corsair Cove Official Wiki
the inner icon should not have had a specified size
Dorce (talk | contribs)
m Reverted edit by 76561199005532951 (talk) to last revision by Aeredor
Tag: Rollback
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<includeonly><div style="position: relative; display: inline-block; width: {{{size|96}}}px; height: {{{size|96}}}px; padding: 0; line-height: 0; font-size: 0;"><!--
<includeonly><!--
-->[[File:T ICO BuildingSign Shield.png|x{{{size|96}}}px]]<!--
--><div class="cc-producer-icon"><!--
--><div style="position: absolute; top: 19%; left: 19%; width: 62%; height: 62%;">[[File:{{{1|}}}]]</div><!--
---->[[File:{{{1|}}}<!--
------>|x{{#switch: {{{size|xs}}}|xs=12|sm=20|md=40|lg=60|xl=80}}px<!--
---->]]<!--
--></div></includeonly><noinclude>
--></div></includeonly><noinclude>


Layers the "Producers" icon shown in the Production Chains overview, a plain wooden shield background, behind the icon with the specified filename. Applies the specified size to the ''whole'' stack, so the inner icon will be smaller.
Layers the "Producers" icon shown in the Production Chains overview, a plain wooden shield background, behind the icon with the specified filename. Applies the specified size to the ''whole'' stack, so the inner icon will be slightly smaller.


Examples:
== Usage ==


<pre>{{Producer icon|T ICO resource Hardwood.png|size=24}}</pre>
It is recommended to not use this template for extra small sizes, because it's too small to be clear. For use inline in paragraphs, use just the building name itself or rewrite to refer to the resource itself so you can use just the resource icon clearly.
{{Producer icon|T ICO resource Hardwood.png|size=24}}


<pre>{{Producer icon|T ICO resource Hardwood.png|size=32}}</pre>
{|class=wikitable
{{Producer icon|T ICO resource Hardwood.png|size=32}}
! Parameter !! Purpose
|-
| filename || specify the filename only, no ''File:'' namespace
|-
{{Parameter standardized sizes}}
|}


<pre>{{Producer icon|T ICO resource Hardwood.png|size=64}}</pre>
=== Examples ===
{{Producer icon|T ICO resource Hardwood.png|size=64}}


<pre>{{Producer icon|T ICO resource Hardwood.png|size=96}}</pre>
<pre>{{Producer icon|T ICO resource Hardwood.png}}</pre>
{{Producer icon|T ICO resource Hardwood.png|size=96}}
{{Producer icon|T ICO resource Hardwood.png}}


[[Category: Formatting templates]]
<pre>{{Producer icon|T ICO resource Hardwood.png|size=sm}}</pre>
{{Producer icon|T ICO resource Hardwood.png|size=sm}}
 
<pre>{{Producer icon|T ICO resource Hardwood.png|size=md}}</pre>
{{Producer icon|T ICO resource Hardwood.png|size=md}}
 
<pre>{{Producer icon|T ICO resource Hardwood.png|size=lg}}</pre>
{{Producer icon|T ICO resource Hardwood.png|size=lg}}
 
<pre>{{Producer icon|T ICO resource Hardwood.png|size=xl}}</pre>
{{Producer icon|T ICO resource Hardwood.png|size=xl}}
 
 
And in table cells:
<pre>{|class=wikitable
! Icon !! Name
|-
| {{Producer icon|T ICO resource Hardwood.png}} || extra small
|-
| {{Producer icon|T ICO resource Hardwood.png|size=sm}} || small
|-
| {{Producer icon|T ICO resource Hardwood.png|size=md}} || medium
|-
| {{Producer icon|T ICO resource Hardwood.png|size=lg}} || large
|-
| {{Producer icon|T ICO resource Hardwood.png|size=xl}} || extra-large
|}</pre>
{|class=wikitable
! Icon !! Name
|-
| {{Producer icon|T ICO resource Hardwood.png}} || extra small
|-
| {{Producer icon|T ICO resource Hardwood.png|size=sm}} || small
|-
| {{Producer icon|T ICO resource Hardwood.png|size=md}} || medium
|-
| {{Producer icon|T ICO resource Hardwood.png|size=lg}} || large
|-
| {{Producer icon|T ICO resource Hardwood.png|size=xl}} || extra-large
|}
 
[[Category: Icon templates]]
</noinclude>
</noinclude>

Latest revision as of 21:05, 2 August 2026


Layers the "Producers" icon shown in the Production Chains overview, a plain wooden shield background, behind the icon with the specified filename. Applies the specified size to the whole stack, so the inner icon will be slightly smaller.

Usage

It is recommended to not use this template for extra small sizes, because it's too small to be clear. For use inline in paragraphs, use just the building name itself or rewrite to refer to the resource itself so you can use just the resource icon clearly.

Parameter Purpose
filename specify the filename only, no File: namespace
size= the size of the icon, or omit for an extra small default size appropriate for inline in paragraphs:
  • xs - default
  • sm
  • md
  • lg
  • xl

Examples

{{Producer icon|T ICO resource Hardwood.png}}
{{Producer icon|T ICO resource Hardwood.png|size=sm}}
{{Producer icon|T ICO resource Hardwood.png|size=md}}
{{Producer icon|T ICO resource Hardwood.png|size=lg}}
{{Producer icon|T ICO resource Hardwood.png|size=xl}}


And in table cells:

{|class=wikitable
! Icon !! Name
|-
| {{Producer icon|T ICO resource Hardwood.png}} || extra small
|-
| {{Producer icon|T ICO resource Hardwood.png|size=sm}} || small
|-
| {{Producer icon|T ICO resource Hardwood.png|size=md}} || medium
|-
| {{Producer icon|T ICO resource Hardwood.png|size=lg}} || large
|-
| {{Producer icon|T ICO resource Hardwood.png|size=xl}} || extra-large
|}
Icon Name
extra small
small
medium
large
extra-large