Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:Item Infobox: Difference between revisions

Template page
No edit summary
No edit summary
 
(13 intermediate revisions by the same user not shown)
Line 1: Line 1:
{| class="infobox" style="float:right; width:250px; border: 1px solid #aaaaaa; padding: 0.2em; margin-left: 1em; margin-bottom: 0.5em; background-color: #f9f9f9;"
<!-- Template:Item Infobox -->
|+ style="font-size: 1.2em; font-weight: bold; padding-bottom: 0.3em;" | {{{name|{{PAGENAME}}}}}
<!-- Uses the generic Template:Infobox to display item information -->
{{#if: {{{image|}}} | <!-- Check if image parameter is provided -->
<includeonly>{{Infobox
|- <!-- Start a new row specifically for the image -->
| bodyclass= mw-collapsible floatright <!-- Standard class -->
| colspan="2" style="text-align:center;" | [[File:{{{image}}}|{{{imagesize|200px}}}]] <!-- Image cell using '|', spanning 2 columns -->
 
}} <!-- End image conditional -->
<!-- Header/Title Row -->
{{#if: {{{introduced|}}} | <!-- Check if introduced parameter is provided -->
| header1 = {{#if:{{{name|}}}|{{Infobox title icon|{{{name|{{PAGENAME}}}}}|icon={{{icon|}}} }} }}
|- <!-- Start a new row -->
| rowclass1 = infobox-title <!-- Assign class to title row -->
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Introduced <!-- Label cell (using '!') -->
 
| style="padding-left:0.5em;" | {{{introduced}}} <!-- Value cell (using '|') -->
<!-- Image Row -->
}} <!-- End introduced conditional -->
| image1 = {{#if:{{{image|}}}|[[File:{{{image}}}|400px]]|[[File:Placeholderv2.png|400px]]}}
{{#if: {{{type|}}} |
| imagerowclass1 = infobox-image <!-- Assign class to image row -->
|-
 
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Type
<!-- Data Rows STARTING FROM label2/data2 -->
| style="padding-left:0.5em;" | {{{type}}}
| label2 = Introduced
}}
| data2 = {{{introduced|}}}
{{#if: {{{category|}}} |
| rowclass2 = data-introduced infobox-data infobox-col1 <!-- Keeping col classes for now -->
|-
 
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Category
| label3 = Type
| style="padding-left:0.5em;" | {{{category}}}
| data3 = {{{type|}}}
}}
| rowclass3 = data-type infobox-data infobox-col2
{{#if: {{{vendor|}}} |
 
|-
| label4 = Category
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Vendor
| data4 = {{{category|}}}
| style="padding-left:0.5em;" | {{{vendor}}}
| rowclass4 = data-category infobox-data infobox-col1
}}
 
{{#if: {{{dyeable|}}} |
| label5 = Vendor
|-
| data5 = {{{vendor|}}}
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Dyeable
| rowclass5 = data-vendor infobox-data infobox-col2
| style="padding-left:0.5em;" | {{{dyeable}}}
 
}}
| label6 = Dyeable
{{#if: {{{access|}}} |
| data6 = {{{dyeable|}}}
|-
| rowclass6 = data-dyeable infobox-data infobox-col1
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Access
 
| style="padding-left:0.5em;" | {{{access}}}
| label7 = Access
}}
| data7 = {{{access|}}}
{{#if: {{{use_location|}}} |
| rowclass7 = data-access infobox-data infobox-col2
|-
 
! scope="row" style="text-align:left; padding-left:0.5em; background-color:#eef;" | Use Location
| label8 = Use Location
| style="padding-left:0.5em;" | {{{use_location}}}
| data8 = {{{use_location|}}}
}}
| rowclass8 = data-uselocation infobox-data infobox-col1
<!-- Add more parameters as needed using the same structure -->
 
|}
<!-- Add more rows if needed -->
<noinclude>
 
}}</includeonly><!--
 
Optional Short description
--><includeonly>{{Short description|Game item in Outlands}}</includeonly><!--
 
Categorization
--><noinclude>
[[Category:Infobox Templates]]
[[Category:Infobox Templates]]
<!-- Add documentation here -->
[[Category:Item Templates]]
This template creates a standard item infobox.


'''Parameters:'''
== Usage ==
* name: Item name (defaults to page name)
(Documentation remains the same as previous correct version)
* image: Filename of the item image
<pre>
* imagesize: Size for the image (defaults to 200px)
{{Item Infobox
* introduced: Patch or date introduced
| name = Item Name ...
* type: Item type (e.g., Container, Weapon)
| image = ItemImage.png ...
* category: Vendor category (e.g., Misc, Reagents)
...
* vendor: NPC or source selling the item
}}
* dyeable: Is the item dyeable? (e.g., Yes, No, specific dye type)
</pre>
* access: Who can use/access it? (e.g., Owner Only, Public)
* use_location: Where must it be to function? (e.g., Secured in House)
* Add custom parameters as needed...
</noinclude>
</noinclude>

Latest revision as of 08:21, 4 April 2025


Usage

(Documentation remains the same as previous correct version)

{{Item Infobox
| name = Item Name ...
| image = ItemImage.png ...
...
}}
Contents