Difference between revisions of "Template:Infobox color"

From blackwiki
Jump to navigation Jump to search
imported>Circeus
(trying out an infobox from Trade and use of saffron)
imported>Circeus
(+ a new variable)
Line 1: Line 1:
 
{| class="toccolours" style="float:right; width:225px; clear:right; margin: 0em 0em 1em 1em;"
 
{| class="toccolours" style="float:right; width:225px; clear:right; margin: 0em 0em 1em 1em;"
 
|-
 
|-
! colspan="3" style="text-align: center; background-color:#{{{hex}}};" | {{{title}}}
+
! colspan="3" style="text-align: center; background-color:#{{{hex}}}; color:{{{textcolor}}};" | {{{title}}}
 
|-
 
|-
| colspan="3" style="height:25px; background-color:#{{{hex}}}; text-align: center;" | — Colour coordinates —
+
| colspan="3" style="height:25px; background-color:#{{{hex}}}; color:{{{textcolor}}}; text-align: center;" | — Colour coordinates —
 
|-
 
|-
 
! style="text-align:left;" colspan="2" | [[Web colours|Hex triplet]]
 
! style="text-align:left;" colspan="2" | [[Web colours|Hex triplet]]
Line 20: Line 20:
 
| ({{{h}}}°, {{{s}}}%, {{{v}}}%)
 
| ({{{h}}}°, {{{s}}}%, {{{v}}}%)
 
|-
 
|-
| colspan="3" style="text-align: center; background-color:#{{{hex}}}; font-size:smaller;" | <sup>'''N'''</sup>: '''N'''ormalised to <nowiki>[</nowiki>&nbsp;0&ndash;255&nbsp;] (changing to [0&ndash;100])
+
| colspan="3" style="text-align: center; background-color:#{{{hex}}}; font-size:smaller; color:{{{textcolor}}};" | <sup>'''N'''</sup>: '''N'''ormalised to <nowiki>[</nowiki>&nbsp;0&ndash;255&nbsp;] (changing to [0&ndash;100])
 
|}
 
|}
  

Revision as of 22:14, 10 February 2006

{{{title}}}
— Colour coordinates —
Hex triplet #{{{hex}}}
RGBN (r, g, b) ({{{r}}}, {{{g}}}, {{{b}}})
CMYKN (c, m, y, b) ({{{c}}}, {{{m}}}, {{{y}}}, {{{k}}})
HSV (h, s, v) ({{{h}}}°, {{{s}}}%, {{{v}}}%)
N: Normalised to [ 0–255 ] (changing to [0–100])

fr:Modèle:Infobox couleur