Template:Color

From Shinycolors Wiki
Jump to navigation Jump to search

Gives the provided text a background color based on the specified name (case-insensitive). If text is omitted then this gives the color itself for the specified color name instead.

{{Color | colorname | text to display}}

colorname: Required. The name of the color to use. If not a valid name then white is used.

text to display: Optional. If present, the text put here will be given a background color based on the color name.

Example Usage[edit source]

Getting a color code from the name (note that the # is NOT provided by this template):

{| class="wikitable"
|style="background-color:#{{Color | Vocal}}"|Vocal Skill
|-
|style="background-color:#{{Color | Dance}}"|Dance Skill
|-
|style="background-color:#{{Color | Visual}}"|Visual Skill
|}

The above will result in the following page content:

Vocal Skill
Dance Skill
Visual Skill


Coloring the background of text:

'''''{{Color | Visual | Visual Appeal x2}}'''''

The above will result in the following page content:

Visual Appeal x2