Template:Series index: Difference between revisions
RodRedlineM1 (talk | contribs) |
RodRedlineM1 (talk | contribs) |
||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<includeonly><!-- //Set default variables | <noinclude>[[Category:Mattel templates]]</noinclude><includeonly><!-- //Set default variables | ||
-->{{Default variables|year={{{year|}}}}}<!-- | -->{{Default variables|year={{{year|}}}}}<!-- | ||
-->{{#SWITCH:{{{1|}}}<!-- | -->{{#SWITCH:{{{1|}}}<!-- | ||
Line 10: | Line 10: | ||
{{#vardefine:chase| | {{#vardefine:chase| | ||
{{#switch: {{{chase|}}} | {{#switch: {{{chase|}}} | ||
| C | Chase = C{{#vardefine:chasename|{{Chase}}}}{{#vardefine:chasenote|{{Notes|[[List of Chase vehicles|<span id="chasenote" style="color:red">Chase</span>]]; limited to 20,000}}}} | | C | Chase = | ||
{{#vardefine:chasetext|Chase}}C{{#vardefine:chasename|{{Chase}}}}{{#vardefine:chasenote|{{Notes|[[List of Chase vehicles|<span id="chasenote" style="color:red">Chase</span>]]; limited to 20,000}}}} | |||
| CP = C{{#vardefine:chasename|{{Chase|P}}}} | | CP = C{{#vardefine:chasename|{{Chase|P}}}} | ||
| SC | Super Chase = SC | | SC | Super Chase = SC | ||
{{#vardefine:chasetext|Super Chase}} | |||
{{#vardefine:chase|SC}} | {{#vardefine:chase|SC}} | ||
{{#vardefine:chasenote|{{Notes|[[List of Chase vehicles|<span id="chasenote" style="color:blue">Super Chase</span>]]; limited to 4,000}}}} | {{#vardefine:chasenote|{{Notes|[[List of Chase vehicles|<span id="chasenote" style="color:blue">Super Chase</span>]]; limited to 4,000}}}} | ||
Line 73: | Line 75: | ||
{{#vardefine:ser_id|LE}} | {{#vardefine:ser_id|LE}} | ||
{{#vardefine:ser_name|Lenticular Eyes}} | {{#vardefine:ser_name|Lenticular Eyes}} | ||
{{#vardefine:ser_category|Lenticular Eyes}} | |||
{{#vardefine:ser_link|Lenticular Eyes}} | {{#vardefine:ser_link|Lenticular Eyes}} | ||
{{#switch:{{{year|}}} | {{#switch:{{{year|}}} | ||
Line 90: | Line 93: | ||
{{#vardefine:ser_id|CTC}} | {{#vardefine:ser_id|CTC}} | ||
{{#vardefine:ser_name|Cars Toon Collection}} | {{#vardefine:ser_name|Cars Toon Collection}} | ||
{{#vardefine:ser_category|Cars Toon Collection}} | |||
{{#vardefine:ser_link|Cars Toon Collection}} | {{#vardefine:ser_link|Cars Toon Collection}} | ||
{{#vardefine:c1|purple}} | {{#vardefine:c1|purple}} | ||
Line 643: | Line 647: | ||
| id = SDCC | | id = SDCC | ||
| name = SDCC Exclusives | | name = SDCC Exclusives | ||
| category = Convention Exclusive | |||
}} | }} | ||
| Mail-in | Mail-ins | Mail Order | Mail order | Promo = {{Series variables | | Mail-in | Mail-ins | Mail Order | Mail order | Promo = {{Series variables |
Latest revision as of 14:39, 19 September 2024
This is the definition list for each Mattel Disney Pixar Cars series, as referred inside the major templates ({{vehicle row}}) and {{vehicle list}}). It takes advantage of switch statement functionality to help improve performance speed: Rather than repeatedly putting the series
input through multiple different expressions, and evaluating each variable one at a time, the parser only needs to check the value once to retrieve all the pre-defined variables (and only them) all at the same time.
Some series have multiple "aliases" registered as failsafes, but for maintenance purposes (and general consistency), please only use one of the following calls (under construction):
|
|
|
Design
Returns the three variables necessary for displaying the "series" cell in each {{vehicle row}}: ID
, $name
, and $link
. Simplified visual:
<div id="$ID"> [[$link|$name]] </div>
Case-by-case it also returns pre-sets for asst
and exclusive
as well the colset
when each is needed.