Difference between revisions of "Module:Gridiron color/doc"
blackwiki>Ahecht (secondary moved) |
m (12 revisions imported) |
||
| (7 intermediate revisions by one other user not shown) | |||
| Line 1: | Line 1: | ||
| − | {{Module rating| | + | {{Module rating|beta}} |
| − | < | + | {{high use|30000}} |
| − | {{lua|Module:Gridiron color/data}} | + | <includeonly>{{accessibility dispute|reason=insufficient [[Wikipedia:Manual of Style/Accessibility#Color|color contrast]] for some teams|talk=Accessibility problems|date=December 2009}}</includeonly> |
| + | {{lua|Module:Gridiron color/data|Module:Yesno|Module:Color contrast}} | ||
Implements: | Implements: | ||
| − | * {{tl|Gridiron primary color | + | * {{tl|Gridiron primary color}} |
| − | * {{tl|Gridiron primary color raw | + | * {{tl|Gridiron primary color raw}} |
| − | * {{tl|Gridiron primary style | + | * {{tl|Gridiron primary style}} |
| − | * {{tl|Gridiron secondary color | + | * {{tl|Gridiron secondary color}} |
| − | * {{tl|Gridiron secondary color raw | + | * {{tl|Gridiron secondary color raw}} |
| − | * {{tl|Gridiron tertiary color raw | + | * {{tl|Gridiron tertiary color raw}} |
| − | * {{tl|Gridiron alt primary color | + | * {{tl|Gridiron alt primary color}} |
| − | * {{tl|Gridiron alt primary style | + | * {{tl|Gridiron alt primary style}} |
| − | * {{tl|Gridiron alt secondary color | + | * {{tl|Gridiron alt secondary color}} |
| + | |||
| + | Uses color data from [[Module:Gridiron color/data]]. | ||
== Usage == | == Usage == | ||
Latest revision as of 17:07, 26 September 2020
| 40x40px | This module is rated as beta, and is ready for widespread use. It is still new and should be used with some caution to ensure the results are as expected. |
| 40px | This Lua module is used on approximately 32,000 pages and changes may be widely noticed. Test changes in the module's /sandbox or /testcases subpages. Consider discussing changes on the talk page before implementing them.
Transclusion count updated automatically (see documentation). |
| 30px | This module depends on the following other modules: |
Implements:
- {{Gridiron primary color}}
- {{Gridiron primary color raw}}
- {{Gridiron primary style}}
- {{Gridiron secondary color}}
- {{Gridiron secondary color raw}}
- {{Gridiron tertiary color raw}}
- {{Gridiron alt primary color}}
- {{Gridiron alt primary style}}
- {{Gridiron alt secondary color}}
Uses color data from Module:Gridiron color/data.
Usage
Debugging
Displays entire row from Module:Gridiron color/data for team and year passed in template call or using |team= and |year= (if omitted from invoke, module will take values from the template call):
{{#invoke:Gridiron color|test|team=team name (optional)|year=#### (optional)}}
["Buffalo Bills"] = {{ "#00274D", #FFFFFF", #C60C30", #00338D", #FFFFFF"}}
Return team color
Returns either raw color value or prefixed color value. |column= uses the following values:
- Primary color
- Secondary color
- Tertiary color
- Alternative primary color
- Alternative secondary color
Set |raw=true to display raw hex values. Team name and year passed in template call or specified using |team= and |year=:
{{#invoke:Gridiron color|color|column=#|raw=true (optional)|team=team name (optional)|year=#### (optional)}}
background: #00274D
Return team style
Returns complete CSS style for given team. A border will be displayed using the tertiary color if |border= is set to "true" (in which case the border will be 2px wide) or to a positive integer value (in which case the width will be the value specified in pixels). Team name and year passed in template call or specified using |team= and |year=:
{{#invoke:Gridiron color|style|border=# or yes (optional)|team=team name (optional)|year=#### (optional)}}
background: #00274D; color: #FFFFFF; -moz-box-shadow: inset 2px 2px 0 #C60C30, inset -2px -2px 0 #C60C30; -webkit-box-shadow: inset 2px 2px 0 #C60C30, inset -2px -2px 0 #C60C30; box-shadow: inset 2px 2px 0 #C60C30, inset -2px -2px 0 #C60C30;