Template:StoreLine/doc: Difference between revisions

From Discord Dungeons Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 30: Line 30:
*'''image:''' override the image, file extension is required  
*'''image:''' override the image, file extension is required  
*'''smwname:''' Differentiate items that have a switch infobox for Semantic MediaWiki. It will lookup the item's value from its wiki page
*'''smwname:''' Differentiate items that have a switch infobox for Semantic MediaWiki. It will lookup the item's value from its wiki page
*'''members:''' If the item can only be bought by members
*'''smw:''' set to "No" to disable smw for this line
*'''smw:''' set to "No" to disable smw for this line
*'''column1:''' Add an additional column with this as contents
*'''column1:''' Add an additional column with this as contents

Revision as of 09:57, 4 April 2022

This is a documentation subpage for Template:StoreLine.
It contains usage information, categories, and other content that is not part of the original template page.
Template:StoreLine invokes function main in Module:StoreLine using Lua.

The StoreLine template is to be used in conjunction with {{StoreTableHeader}} provide a listing of items that are found in a shop. It also helps to provide a uniform look of how the shop information is presented for all articles about shop on the wiki.

Usage

{{StoreTableHeader|currency=LUX}}
{{StoreLine|name=Felix's Bait Rod|sell=20|currency=LUX|level=100}}
{{StoreLine|name=Felix's Book|sell=1|currency=LUX|level=1}}
{{StoreLine|name=Felix's Pencil|sell=5|currency=LUX|level=1}}
{{StoreLine|name=History of the Terist|sell=1|currency=LUX|level=3}}
{{StoreTableFooter}}

gives

ItemBuyable forSellable forLevelMembers only
File:Felix's Bait Rod.pngFelix's Bait RodN/A20 LUX100No
File:Felix's Book.pngFelix's BookN/A1 LUX1No
File:Felix's Pencil.pngFelix's PencilN/A5 LUX1No
File:History of the Terist.pngHistory of the TeristN/A1 LUX3No


Parameters

  • name: the item
  • sell: the price the item sells at
  • buy: the price the item can be sold for to the shop
  • image: override the image, file extension is required.

Optional Parameters

  • displayname: an optional name to display
  • image: override the image, file extension is required
  • smwname: Differentiate items that have a switch infobox for Semantic MediaWiki. It will lookup the item's value from its wiki page
  • members: If the item can only be bought by members
  • smw: set to "No" to disable smw for this line
  • column1: Add an additional column with this as contents
  • column2: Add an additional column with this as contents
  • columnX: ... Add an additional column with this as contents

See also

Template data

Show/hide template's data

The following information is used by extensions and applications, such as VisualEditor, to help users implement this template onto pages. Please ensure that it is up-to-date.

The StoreLine template is used to provide a listing of items that are found in a shop.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Item namename

The item to link to and display

Page namerequired
Display namedisplayname

Overrides the displayed item name

Stringoptional
Sell valuesell

The price the shop sells the item for

Stringoptional
Buy valuebuy

What the item can be sold for to the shop

Stringoptional
Image overrideimage

Overrides the image, file extension is required

Stringoptional
smw name overridesmwname

Differentiate items that have a switch infobox for Semantic MediaWiki. It will lookup the item's value from its wiki page

Stringoptional