Template:Infobox album/color/doc
| This is a documentation subpage for Template:Infobox album/color. It contains usage information, categories and other content that is not part of the original template page. |
Important
When modifying this template, don't forget to update Template:Infobox Album/link.
Usage
This is an auxiliary template which should be only used by the {{Infobox Album}} template. The first parameter should be one of the codes from the table below, representing a type of album (parameter "Type"). The template returns the color that will be used.
Quick reference table
Template:Infobox Album/doc/type
Unit test
If at any time the Expected and Obtained columns do not match, this template can be considered broken. This table makes the template automatically check itself. If a
mark is seen, it means that self test worked fine. If there is a
mark, it means the test failed. Whenever you make a modification to the template, please save the page, hit CTRL+F5, and check if all the self tests have passed. If you add a new type to the template, remember to add the type using this format:
| <nowiki>typename</nowiki>
| typecolor
| {{Template:Infobox Album/color|typename}}
| {{#ifeq:{{Template:Infobox Album/color|typename}}|typecolor|{{y}}|{{n}}}}
Replace typename with the new type name (in example, Epic soundtrack), and typecolor with the color assigned to the type (in example, brown). See Wikipedia:Colours and Wikipedia:Infobox colours for additional information.
Note: Sometimes the test may pass while previewing the page, but once saved the test would fail, no matter how many times the cache is cleared. In this case, please click this link to purge the cache. If that doesn't solve the problem, please post a note in the Talk page of the template and an editor will review the changes.
| Code | Expected | Obtained | Test |
|---|---|---|---|
| Studio album | |||
| studio | lightsteelblue | Template:Infobox Album/color | |
| Studio album | lightsteelblue | Template:Infobox Album/color | |
| Double album | lightsteelblue | Template:Infobox Album/color | |
| [[Double album]] | lightsteelblue | Template:Infobox Album/color | |
| Demo album | |||
| demo | lightsteelblue | Template:Infobox Album/color | |
| EP | |||
| ep | lightsalmon | Template:Infobox Album/color | |
| [[EP]] | lightsalmon | Template:Infobox Album/color | |
| Live album | |||
| live | burlywood | Template:Infobox Album/color | |
| Live album | burlywood | Template:Infobox Album/color | |
| Greatest hits | |||
| greatest | darkseagreen | Template:Infobox Album/color | |
| Greatest hits | darkseagreen | Template:Infobox Album/color | |
| Remix album | |||
| remix | darkseagreen | Template:Infobox Album/color | |
| Remix album | darkseagreen | Template:Infobox Album/color | |
| Box set | |||
| box | darkseagreen | Template:Infobox Album/color | |
| Box set | darkseagreen | Template:Infobox Album/color | |
| Compilation album | |||
| compilation | darkseagreen | Template:Infobox Album/color | |
| Compilation album | darkseagreen | Template:Infobox Album/color | |
| Cover album | |||
| cover | thistle | Template:Infobox Album/color | |
| Cover album | thistle | Template:Infobox Album/color | |
| Tribute album | |||
| tribute | thistle | Template:Infobox Album/color | |
| Tribute album | thistle | Template:Infobox Album/color | |
| Soundtrack | |||
| soundtrack | gainsboro | Template:Infobox Album/color | |
| Television theme | |||
| television | gainsboro | Template:Infobox Album/color | |
| Television theme | gainsboro | Template:Infobox Album/color | |
| Film score | |||
| film | gainsboro | Template:Infobox Album/color | |
| Film score | gainsboro | Template:Infobox Album/color | |
| Video album | |||
| video | #99CCFF | Template:Infobox Album/color | |
| dvd | #99CCFF | Template:Infobox Album/color | |
| Other cases | |||
| peachpuff | Template:Infobox Album/color | ||
| xyz | peachpuff | Template:Infobox Album/color | |