User:Darkid/Template:Chart Bar: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
mNo edit summary |
||
Line 3: | Line 3: | ||
width: {{#expr: {{formatnum:{{{1|0}}}|R}} / {{formatnum:{{{max|100}}}|R}} * 100}}%; | width: {{#expr: {{formatnum:{{{1|0}}}|R}} / {{formatnum:{{{max|100}}}|R}} * 100}}%; | ||
height: {{{height|16px}}}; | height: {{{height|16px}}}; | ||
background:{{{hex|# | background:{{{hex|#5081D1}}}; | ||
float:left; | float:left; | ||
line-height:{{{height|16px}}}; | line-height:{{{height|16px}}}; |
Latest revision as of 14:51, 15 September 2015
Draws a single horizontal percentage bar. Does not display the input value to a percentage. Default max value is 100.
{{User:Darkid/Template:Chart Bar|33}}
Generates:
The max value can be edited.
{{User:Darkid/Template:Chart Bar|360|max=500}}
Generates:
The bar color can be changed, and text can be made to appear on rollover.
{{User:Darkid/Template:Chart Bar|33|hex=#c5c5c5|hover=Light grey}} {{User:Darkid/Template:Chart Bar|54|hex=#a4a4a4|hover=Dark grey}} {{User:Darkid/Template:Chart Bar|19|hex=#865839|hover=Brown}}
Generates:
The max width can be edited.
{{User:Darkid/Template:Chart Bar|100|width=10%}} {{User:Darkid/Template:Chart Bar|100|width=30%}} {{User:Darkid/Template:Chart Bar|100|width=80%}}
Generates: