Module:Sports color/basketball: Difference between revisions

Jump to navigation Jump to search
(Created page with "return { -- NBA -- ["Atlanta Hawks"] = {"C8102E", "FFFFFF", "FDB927", "000000"}, ["St. Louis Hawks"] = {"CF0A2C", "FFFFFF", "003DA6", "FFFFFF"}, ["Milwaukee Hawks"] = {"CF0A2C", "FFFFFF", "003DA6", "FFFFFF"}, ["Tri-Cities Blackhawks"] = {"CF0A2C", "FFFFFF", "003DA6", "FFFFFF"}, ["Boston Celtics"] = {"008348", "FFFFFF", "BB9753", "000000"}, ["Brooklyn Nets"] = {"000000", "FFFFFF", "FFFFFF", "000000"}, ["New Jersey Nets"] = {"00285E", "FFFFFF", "CE1141", "FFFFFF"},...")
 
(Undo revision 789904 by A.R.M (talk))
Tag: Undo
 
(One intermediate revision by the same user not shown)

Latest revision as of 20:17, 8 April 2024

This is the data module used by Module:Sports color. Please test any changes in Module:Sports color/basketball/sandbox first.

Format

Most lines will be of the following form

 ["TEAM NAME"] = {"HEX1", "HEX2", "HEX3", "HEX4"},

The trailing comma is very important. Here, HEX1, HEX2, HEX3, and HEX4 are hexadecimal color values.

To use the same color for more than one team name (e.g., if the team goes by more than one name, but the colors are the same), use

 ["SECONDARY TEAM NAME"] = "TEAM NAME",

where TEAM NAME has already been defined, and SECONDARY TEAM NAME is the alternative spelling, or name.

Warning

Be very careful when updating this module, as it is used in a large number of articles. Please test any changes in Module:Sports color/basketball/sandbox first.

Test table

Team1234Contrast
1/24/3
Atlanta Hawks5.8812.15
Baltimore Bullets15.885.33
Boston Celtics4.847.66
Brooklyn Nets2121
Buffalo Braves215.64
Charlotte Bobcats5.646.54
Charlotte Hornets5.1716.14
Charlotte Hornets (1988–2002)9.85.64
Chicago Bulls5.5521
Chicago Packers11.584.76
Chicago Zephyrs16.155.26
Cincinnati Royals9.825.1
Cleveland Cavaliers10.147.53
Dallas Chaparrals
Also known as Texas Chaparrals
8.334.73
Dallas Mavericks6.0711.86
Denver Nuggets15.8910.01
Detroit Pistons9.555.88
Eastern Conference9.559.55
Ft. Wayne Pistons9.476.25
Golden State Warriors9.555.52
Houston Rockets5.5521
Indiana Pacers13.537.94
Kansas City Kings9.825.1
Los Angeles Clippers9.555.88
Los Angeles Lakers15.4412.15
Memphis Grizzlies4.5417.21
Miami Heat218.84
Milwaukee Bucks10.958.46
Milwaukee Hawks5.639.47
Minneapolis Lakers8.112.8
Minnesota Timberwolves15.826.62
NBA9.555.88
NBA Finals217.37
New Jersey Americans4.529.47
New Jersey Nets14.335.55
New Orleans Hornets3.6212.15
New Orleans Jazz10.8312.54
New Orleans Pelicans15.795.74
New York Knicks9.558.21
New York Nets9.474.52
Oklahoma City Thunder4.613.95
Orlando Magic4.7721
Philadelphia 76ers9.555.88
Philadelphia Warriors9.474.35
Phoenix Suns16.146.03
Portland Trail Blazers214.84
Rochester Royals9.825.1
Sacramento Kings219.87
San Antonio Spurs2113.13
San Diego Clippers6.135.04
San Diego Rockets7.765.05
San Francisco Warriors5.5612.15
Seattle SuperSonics7.1212.62
St. Louis Hawks5.639.47
Syracuse Nationals5.113.03
Toronto Raptors5.5521
Tri-Cities Blackhawks5.639.47
Utah Jazz2117.97
Vancouver Grizzlies7.545.86
Washington Bullets11.075.1
Washington Wizards144.72
Western Conference5.885.88
Free agentXX15.31
RetiredXX15.31
The numeric columns are the calculated contrast ratio for the first/second and the fourth/third colors. Anything lower than 3 is very poor contrast and should be changed in the data module. For more information, see Template:Color contrast ratio.
["Pacific Caesar"] = {"#DEE94D", "#000000", "#008000", "#DEE94D"}

return {
-- NBA --
["Atlanta Hawks"] = {"C8102E", "FFFFFF", "FDB927", "000000"},
  ["St. Louis Hawks"] = {"CF0A2C", "FFFFFF", "003DA6", "FFFFFF"},
  ["Milwaukee Hawks"] = {"CF0A2C", "FFFFFF", "003DA6", "FFFFFF"},
  ["Tri-Cities Blackhawks"] = {"CF0A2C", "FFFFFF", "003DA6", "FFFFFF"},
["Boston Celtics"] = {"008348", "FFFFFF", "BB9753", "000000"},
["Brooklyn Nets"] = {"000000", "FFFFFF", "FFFFFF", "000000"},
  ["New Jersey Nets"] = {"00285E", "FFFFFF", "CE1141", "FFFFFF"},
  ["New York Nets"] = {"003DA6", "FFFFFF", "EC0044", "FFFFFF"},
  ["New Jersey Americans"] = {"EC0044", "FFFFFF", "003DA6", "FFFFFF"},
["Charlotte Hornets"] = {"00788C", "FFFFFF", "1D1160", "FFFFFF"},
  ["Charlotte Bobcats"] = {"E75300", "000000", "3D6085", "FFFFFF"},
  ["Charlotte Hornets (1988–2002)"] = {"283A97", "FFFFFF", "0391AB", "000000"},
["Chicago Bulls"] = {"CE1141", "FFFFFF", "000000", "FFFFFF"},
["Cleveland Cavaliers"] = {"860038", "FFFFFF", "BC945C", "000000"},
["Dallas Mavericks"] = {"0064B1", "FFFFFF", "BBC4CA", "000000"},
["Denver Nuggets"] = {"0E2240", "FFFFFF", "FEC524", "0E2240"},
["Detroit Pistons"] = {"1D428A", "FFFFFF", "C8102E", "FFFFFF"},
  ["Ft. Wayne Pistons"] = {"003DA6", "FFFFFF", "C3002F", "FFFFFF"},
["Golden State Warriors"] = {"1D428A", "FFFFFF", "FDB927", "1D428A"},
  ["San Francisco Warriors"] = {"006BB6", "FFFFFF", "FDB927", "000000"},
  ["Philadelphia Warriors"] = {"003DA6", "FFFFFF", "ED174C", "FFFFFF"},
["Houston Rockets"] = {"CE1141", "FFFFFF", "000000", "FFFFFF"},
  ["San Diego Rockets"] = {"115E43", "FFFFFF", "FFC938", "115E43"},
["Indiana Pacers"] = {"002D62", "FFFFFF", "FDBB30", "002D62"},
["Los Angeles Clippers"] = {"1D428A", "FFFFFF", "C8102E", "FFFFFF"},
  ["San Diego Clippers"] = {"3E8EDE", "000000", "E24301", "000000"},
  ["Buffalo Braves"] = {"000000", "FFFFFF", "E75300", "000000"},
["Los Angeles Lakers"] = {"31006F", "FFFFFF", "FDB927", "000000"},
  ["Minneapolis Lakers"] = {"79A3DD", "000000", "F7C330", "000000"},
["Memphis Grizzlies"] = {"5D76A9", "FFFFFF", "12173F", "FFFFFF"},
  ["Vancouver Grizzlies"] = {"00ADA8", "000000", "BA7845", "000000"},
["Miami Heat"] = {"000000", "FFFFFF", "98002E", "FFFFFF"},
["Milwaukee Bucks"] = {"00471B", "FFFFFF", "EEE1C6", "00471B"},
["Minnesota Timberwolves"] = {"0C233F", "FFFFFF", "266092", "FFFFFF"},
["New Orleans Pelicans"] = {"0C2340", "FFFFFF", "B9975B", "0C2340"},
  ["New Orleans Hornets"] = {"0093B1", "FFFFFF", "FDB927", "000000"},
["New York Knicks"] = {"1D428A", "FFFFFF", "F58426", "000000"},
["Oklahoma City Thunder"] = {"007AC1", "FFFFFF", "EF3B24", "FFFFFF"},
  ["Seattle SuperSonics"] = {"006633", "FFFFFF", "FFBE00", "000000"},
["Orlando Magic"] = {"0077C0", "FFFFFF", "000000", "FFFFFF"},
["Philadelphia 76ers"] = {"1D428A", "FFFFFF", "C8102E", "FFFFFF"},
  ["Syracuse Nationals"] = {"DD0031", "FFFFFF", "002E6D", "FFFFFF"},
["Phoenix Suns"] = {"1D1160", "FFFFFF", "E56020", "000000"},
["Portland Trail Blazers"] = {"000000", "FFFFFF", "E03A3E", "000000"},
["Sacramento Kings"] = {"000000", "FFFFFF", "5A2D81", "FFFFFF"},
  ["Kansas City Kings"] = {"1E3D92", "FFFFFF", "CE3320", "FFFFFF"},
  ["Cincinnati Royals"] = {"1E3D92", "FFFFFF", "CE3320", "FFFFFF"},
  ["Rochester Royals"] = {"1E3D92", "FFFFFF", "CE3320", "FFFFFF"},
["San Antonio Spurs"] = {"000000", "FFFFFF", "C4CED4", "000000"},
  ["Dallas Chaparrals"] = {"1149A5", "FFFFFF", "EF052A", "000000"},
  ["Texas Chaparrals"] = "Dallas Chaparrals",
["Toronto Raptors"] = {"CE1141", "FFFFFF", "000000", "FFFFFF"},
["Utah Jazz"] = {"000000", "FFFFFF", "FFF21F", "000000"},
  ["New Orleans Jazz"] = {"4C3262", "FFFFFF", "EFC33D", "000000"},
["Washington Wizards"] = {"002B5C", "FFFFFF", "E31837", "FFFFFF"},
  ["Washington Bullets"] = {"213582", "FFFFFF", "F02B34", "000000"},
  ["Baltimore Bullets"] = {"112143", "FFFFFF", "E54A21", "000000"},
  ["Chicago Zephyrs"] = {"19212F", "FFFFFF", "B78C40", "19212F"},
  ["Chicago Packers"] = {"20327D", "FFFFFF", "DF203D", "FFFFFF"},
["NBA"] = {"1D428A", "FFFFFF", "C8102E", "FFFFFF"},
["Eastern Conference"] = {"1D428A", "FFFFFF", "FFFFFF", "1D428A"},
["Western Conference"] = {"C8102E", "FFFFFF", "FFFFFF", "C8102E"},
["NBA Finals"] = {"000000", "FFFFFF", "B59461", "000000"},
}