Template:Shop: Difference between revisions

From Inkipedia, the Splatoon wiki
m (→‎Output: didn't match input example)
(Changed to Lua module. In the interim, Template:Shop/new was used.)
Tag: Replaced
Line 1: Line 1:
<includeonly>[[File:{{GameShortened|{{{game|}}}}}_Icon_{{{1}}}.png|{{{2|24px}}}|link={{{1}}}]]{{#ifeq:{{{icononly|}}}|true||&#32;[[{{{1}}}|{{{1}}}]]}}</includeonly><noinclude>__NOTOC__
<includeonly>{{#invoke:Shop|main}}</includeonly><noinclude>
Displays an inline shop icon with a text link.
Invokes [[Module:Shop]].


=== Parameters ===
{{:Module:Shop/doc}}
{|
</noinclude>
|- style="vertical-align: top;"
|<code>name</code>||Unnamed.||The English name of the shop.
|- style="vertical-align: top;"
|<code>size</code>||Unnamed, optional.||A Mediawiki image size parameter for the icon. The default size is 24px.
|- style="vertical-align: top;"
|<code>game</code>||Optional.||The game that the sub weapon belongs to. The default value is "Splatoon". Must be one of the following:
*Splatoon
*Splatoon 2
*Splatoon 3
|- style="vertical-align: top;"
|<code>icononly</code>||Optional.||If present and "true", the text label will be omitted.
|}
 
== Examples ==
=== Markup ===
<nowiki>{{Shop|Ammo Knights}}<br />
{{Shop|Ammo Knights|48px}}<br />
{{Shop|Ammo Knights|icononly=true}}<br />
{{Shop|Ammo Knights|game=Splatoon 2}}<br />
{{Shop|Naut Couture|game=Splatoon 3}}</nowiki>
 
=== Output ===
{{Shop|Ammo Knights}}<br />
{{Shop|Ammo Knights|48px}}<br />
{{Shop|Ammo Knights|icononly=true}}<br />
{{Shop|Ammo Knights|game=Splatoon 2}}<br />
{{Shop|Naut Couture|game=Splatoon 3}}</noinclude>

Revision as of 16:26, 9 February 2024

Invokes Module:Shop.

Displays an inline shop icon with a link text.

Parameters

game Named, required. The abbreviation of icon's game of origin. Must be one of the following:
  • S for Splatoon.
  • S2 for Splatoon 2.
  • S3 for Splatoon 3.
name Named, required. The English name of the shop.
  • Ammo Knights (Inkopolis) (while game=S3) for Shelly/Donny solo icon.
  • Ammo Knights (Duo) (while game=S3) for Shelly and Donny pair icon.
icononly Named, optional. If present and "true", the link text will be omitted.
size Named, optional. The width of the icon in pixels (do not include px). Defaults to 24 if absent.

Examples

Markup

{{Shop|game=S|name=Ammo Knights}}<br />
{{Shop|game=S3|name=Naut Couture}}<br />
{{Shop|game=S3|name=Ammo Knights|icononly=true|size=64}}<br />
{{Shop|game=S3|name=Ammo Knights (Inkopolis)|size=48}}

Output

Script error: The function "main" does not exist.
Script error: The function "main" does not exist.
Script error: The function "main" does not exist.
Script error: The function "main" does not exist.