Template:Demo RecipeItemIcon: Difference between revisions
From Eco - English Wiki
| [checked revision] | [unchecked revision] |
No edit summary |
Starting to try to remove static sizing requirement Tags: Reverted 2017 source edit |
||
| Line 1: | Line 1: | ||
<templatestyles src="Template:Demo_RecipeItemIcon/styles.css" /> | <templatestyles src="Template:Demo_RecipeItemIcon/styles.css" /> | ||
<includeonly><div class="recipe-item-icon {{#if: {{{count|}}} | has-count }} {{#switch: {{{border|}}} | yellow = border-yellow | white = border-white | green = border-green | #default = border-white}}" style="font-size:{{{size|64}}}px"><div class="recipe-item-icon__img-container">[[File:{{{icon}}} | <includeonly><div class="recipe-item-icon {{#if: {{{count|}}} | has-count }} {{#switch: {{{border|}}} | yellow = border-yellow | white = border-white | green = border-green | #default = border-white}}" style="font-size:{{{size|64}}}px"><div class="recipe-item-icon__img-container">[[File:{{{icon}}}]]</div><span class="recipe-item-icon__count">{{{count|}}}</span></div></includeonly> | ||
<noinclude> | <noinclude> | ||
Revision as of 16:04, 21 February 2026
Visual Goals
Template Examples
| Color | Example |
|---|---|
| White (Default) |
|
| Yellow |
|
| Green |
|
| Size | Example |
|---|---|
| 64px (Default) |
|
| 128px |
|
| 256px |
|
| Count | Example |
|---|---|
| No Count/Shadow |
|
| 10 |
|
| 100 |
|
Grid Demo
Recipe Demo
No description.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| size | size | Size in pixels (numbers only)
| Number | optional |
| icon | icon | File name for icon.
| String | required |
| count | count num | A number to display over this icon's image. Useful for showing counts.
| Number | optional |
| border | border | Border color
| String | optional |