Template:Imagelink: Difference between revisions

From Official Factorio Wiki
Jump to navigation Jump to search
No edit summary
m (WHITESPACE :DDD)
 
(12 intermediate revisions by 3 users not shown)
Line 1: Line 1:
<includeonly><div style="padding:5px;"><div class="icon" style="display:inline-block; position:relative; padding:3px; width:32px; height:32px; background-color:#999; border:1px solid #ccc;">[[File:{{{1}}}.png{{!}}32px{{!}}link={{{2|}}}]]</div><span style="position:relative; padding:3px; font-size:larger; color: black;">{{#if: {{{link|}}}| {{{3|{{{2}}}}}}|{{#if: {{{3|}}} | [[{{{2}}}{{!}}{{{3}}}]] | [[{{{2}}}]]}}}}</span></div></includeonly>
<includeonly>{{#if:{{{2|}}}|{{Icon|{{{1}}}||{{{2}}}}}|{{Icon|{{{1}}}}}}}{{#if:{{{3|}}}|[[{{{2}}}|{{{3}}}]]|{{#if:{{{2|}}}|[[{{{2}}}|{{Translation|{{#titleparts:{{{2}}}|1|1}}}}]]|{{TransLink|{{{1}}}}}}}}}</includeonly><noinclude>
 
{{documentation}}
<noinclude>
 
== Usage ==
<pre>
{{imagelink|icon|link|caption}}
1. {{imagelink|rocket|Rocket}}
2. {{imagelink|basic-splitter|Transport network#Basic splitter|Basic splitter}}
 
</pre>
 
 
== Result ==
1. {{imagelink|rocket|Rocket}}
2. {{imagelink|basic-splitter|Transport network#Basic splitter|Basic splitter}}
 
</noinclude>
</noinclude>

Latest revision as of 10:34, 14 August 2017

[View] [Edit] [Page history]

Documentation
{{imagelink|icon|link|caption}}
  • The link and caption parameters are optional. If both are not present the link will go to the page with the name of the first parameter with language suffix if the icon is on a non-english page (e.g. icon/de on a German page). The text next the icon is translated to the language of the page it is on.
  • If the second parameter is present, the links will go to exactly that page, no language suffixes are added. The text next to the icon is then translated from that second parameter.
  • If the third parameter is present the text next to the icon is exactly that text.

Usage

{{imagelink|Rocket}} {{Imagelink|Rocket|Transport belt/de}} {{imagelink|splitter|Belt transport system#Splitters|Basic splitter}}

Result

Rocket.png
Rocket
Rocket.png
Transport belt
Splitter.png
Basic splitter
List of all templates