Template:Item/doc: Difference between revisions
Jump to navigation
Jump to search
Created page with "{{Documentation/Header}} {{Lua|Item}} This template creates the icon and link for an item. ==Syntax== This template has 2 unnamed parameters: #'''(mandatory)''' Name of the item. If set to Unknown no link is set. #'''(optional)''' Size of the icon. Defaults to 30. There are also 8 optional named parameters: *'''link''': Sets another page to be linked. *'''text''': Displays another text instead of the name of the item. *'''notext''': If set to ''1'', the complete tex..." |
|||
| Line 15: | Line 15: | ||
==See also== | ==See also== | ||
* [[Template:Card]] | * [[Template:Card]] | ||
Revision as of 10:19, 10 June 2025
This is the documentation page for Item. It contains usage information, categories, and other content not part of the original template page. | ||
|---|---|---|
| Main | Documentation | Usage |
This template uses Module:Item, a script written in Lua.
This template creates the icon and link for an item.
Syntax
This template has 2 unnamed parameters:
- (mandatory) Name of the item. If set to Unknown no link is set.
- (optional) Size of the icon. Defaults to 30.
There are also 8 optional named parameters:
- link: Sets another page to be linked.
- text: Displays another text instead of the name of the item.
- notext: If set to 1, the complete text will be omitted. The picture will no longer behave like an inline-block.
- count (x): Quantity of the item. Part of the text.
- white: Adds White suffix to file name.
See also
Examples
* {{Item|Satchel}}
* {{Item|Unknown}}
Satchel
Unknown
* {{Item|Satchel|20}}
* {{Item|Satchel|80}}
* {{Item|Satchel|link=Items}}
* {{Item|Satchel|text=Not Satchel}}
* {{Item|Satchel|notext=1}}
* {{Item|Satchel|x=2}}
Satchel ×2
* {{Item|Eugene Grant|type=survivor}}
Template Data
Create item image and link.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Name | 1 name | Name of item and file name.
| String | suggested |
| Image Size | 2 size | Size of Item
| Number | suggested |
| Item Count | x count | Number of Items. Displayed with ×.
| Number | optional |
| Item Type | type | The type of item to add as prefix to file name. Automatically adds suffix when needed.
| String | optional |
| Display Text | text | Link displayed to the right if image.
| String | optional |
| Link | link | Link of image and text.
| Page name | optional |
| Blueprint | blueprint | Show furnishing blueprint icon in top left of image.
| Boolean | optional |
| No Text | notext | Hide item name and link.
| Boolean | optional |
| White | white | Adds White to suffix of file name.
| Boolean | optional |