Difference between revisions of "Template:Ingredient List Row"
Jump to navigation
Jump to search
(show the header even if the table is collapsed) |
|||
Line 1: | Line 1: | ||
<includeonly> | <includeonly> | ||
− | + | {{#ifexist:{{{?Name}}} | | |
− | {{#ifexist:{{{?Name}}}| | + | <tr class="mw-collapsible {{#if: {{{noCollapse|}}}||mw-collapsed}}" id="mw-customcollapsible-ingredient-list"> |
! {{DLC Icons|{{{?Name}}}}} | ! {{DLC Icons|{{{?Name}}}}} | ||
− | {{!}} {{#ifeq: {{{?R1|-}}} | + | {{!}} {{#ifeq: {{{?R1|-}}} | {{#var:name}} | {{{?R1a}}}|<!-- |
− | -->{{#ifeq: {{{?R2|-}}} | {{#var:name}} | {{{?R2a}}}|<!-- | + | -->{{#ifeq: {{{?R2|-}}} | {{#var:name}} | {{{?R2a}}}|<!-- |
− | -->{{#ifeq: {{{?R3|-}}} | {{#var:name}} | {{{?R3a}}}|<!-- | + | -->{{#ifeq: {{{?R3|-}}} | {{#var:name}} | {{{?R3a}}}|<!-- |
− | -->{{#ifeq: {{{?R4|-}}} | {{#var:name}} | {{{?R4a}}}|<!-- | + | -->{{#ifeq: {{{?R4|-}}} | {{#var:name}} | {{{?R4a}}}|<!-- |
− | -->{{#ifeq: {{{?R5|-}}} | {{#var:name}} | {{{?R5a}}}|<!-- | + | -->{{#ifeq: {{{?R5|-}}} | {{#var:name}} | {{{?R5a}}}|<!-- |
− | -->{{#ifeq: {{{?R6|-}}} | {{#var:name}} | {{{?R6a}}}}} }} }} }} }} }} | + | -->{{#ifeq: {{{?R6|-}}} | {{#var:name}} | {{{?R6a}}}}} }} }} }} }} }} |
{{!}} [[{{{?Type}}}]] {{#if:{{{?Type2}}}|- [[{{{?Type2}}}]] }} | {{!}} [[{{{?Type}}}]] {{#if:{{{?Type2}}}|- [[{{{?Type2}}}]] }} | ||
+ | </tr> | ||
}}</includeonly><noinclude> | }}</includeonly><noinclude> | ||
{{Documentation}}</noinclude> | {{Documentation}}</noinclude> |
Revision as of 09:52, 12 December 2023
This template is only ever called as part of Template:Ingredient List. It uses the variables provided by the different #asks in that template to create sections of the table that the primary template then assembles into one table.
Example usage
This template isn't designed to be used in isolation, so as an example we'll show {{Ingredient List|Steel}}
Product | Ingredients | Type [ExpandCollapse]
|
---|
And {{Ingredient List|Patchleather}}
Product | Ingredients | Type [ExpandCollapse]
|
---|
The above documentation is transcluded from Template:Ingredient List Row/doc. (edit | history) Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages. Please add categories to the /doc subpage. Subpages of this template. |