Template:Item: Difference between revisions

m
no edit summary
m (Added margin-bottom.)
mNo edit summary
 
(10 intermediate revisions by the same user not shown)
Line 1: Line 1:
{| style="display: inline-block; margin: 0 10px 10px 0; border: 2px solid #895C40; width: 54px; height: 54px; border-radius: 2px; position: relative; cursor: pointer; {{#switch: {{uc:{{{rarity|}}}}}
{| style="display: inline-block; margin: 5px; border: 3px solid #B3825B; width: 54px; height: 54px; border-radius: 3px; position: relative; cursor: pointer; {{#switch: {{uc:{{{rarity|}}}}}
   | UR      = background: radial-gradient(circle, #F65E55, #B5423F);
   | UR      = background: radial-gradient(circle, #F65E55, #B5423F);
   | SSR      = background: radial-gradient(circle, #F3C359, #9D5C28);
   | SSR      = background: radial-gradient(circle, #F3C359, #9D5C28);
   | SR      = background: radial-gradient(circle, #6A3F84, #32203A);
   | SR      = background: radial-gradient(circle, #6A3F84, #32203A);
   | R        = background: radial-gradient(circle, #2F516E, #131C2D);
   | R        = background: radial-gradient(circle, #2F516E, #131C2D);
   | #default = background: radial-gradient(circle, white, lightgray);
  | N        = background: radial-gradient(circle, #41795A, #274136);
   | #default = background: radial-gradient(circle, #835D44, #422820);
}}"
}}"
| <div style="padding: 3.5px 0 0 3.5px;">[[File:{{{img|Item_Skill_Pearl.png}}}|link={{{name|}}}]]</div>
| <div style="padding: 3.5px 0 0 3.5px; font-size: 8px;">[[File:{{{img|Sprite_Skill_Pearl.png}}}|link={{{name|}}}]]</div>
| <span style="position: absolute; bottom: 0px; right: 5px; color: white; font-weight: bold; font-size: 14px; text-shadow: 2px 2px 5px black;">{{{num|0}}}</span>
| <span style="position: absolute; bottom: 0px; right: 5px; color: white; font-weight: bold; font-size: 12px; text-shadow: 2px 2px 5px black;">{{{num|}}}</span>
|}
|}
<noinclude>
<noinclude>
'''Template:'''
<pre style="width: 500px;">
{{Item
  | name  =
  | img    =
  | rarity =
  | num    =
}}</pre>
<templatedata>
<templatedata>
{
{
"description": "This template renders an item icon.",
"params": {
"params": {
"img": {
"img": {
Line 18: Line 27:
"type": "wiki-file-name",
"type": "wiki-file-name",
"suggested": true,
"suggested": true,
"example": "Item_Icon.png",
"example": "Sprite_Skill_Pearl.png"
"default": "Item_Skill_Pearl.png"
},
},
"rarity": {
"name": {
"description": "The rarity determines the background color of the icon.",
"description": "The item's page name is listed here and will direct the user to that page upon click.",
"type": "string",
"type": "wiki-page-name",
"suggested": true,
"required": true
"default": "background: radial-gradient(circle, white, lightgray);"
},
},
"num": {
"num": {
Line 31: Line 38:
"description": "The quantity of the item is listed here.",
"description": "The quantity of the item is listed here.",
"type": "number",
"type": "number",
"default": "0",
"suggested": true
"suggested": true
},
},
"name": {
"rarity": {
"description": "The item's page name is listed here and will direct the user to that page upon click.",
"description": "The rarity determines the background color of the icon.",
"type": "wiki-page-name",
"type": "string",
"default": "background: radial-gradient(circle, #835D44, #422820);",
"suggested": true
"suggested": true
}
}
Line 45: Line 52:
"rarity",
"rarity",
"num"
"num"
],
]
"description": "This template renders an item icon."
}
}
</templatedata>
</templatedata>
'''How to use:'''
<pre>
{{Item
  | name  =
  | img    =
  | rarity =
  | num    =
}}</pre>
</noinclude>
</noinclude>
contributors, delete_pages, Interface administrators
4,719

edits