Difference between revisions of "Template:Infobox/Kerbonaut/bar"

From Kerbal Space Program Wiki
Jump to: navigation, search
(Created page with "<div style="height:20px; background: #252525; border-radius: 2px; padding: 2px"><span style="width:{{#expr: {{{1<noinclude>|0.25</noinclude>}}}{{#if: {{{2|}}}|/{{{2}}}}}*100 r...")
 
m (Add max width)
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<div style="height:20px; background: #252525; border-radius: 2px; padding: 2px"><span style="width:{{#expr: {{{1<noinclude>|0.25</noinclude>}}}{{#if: {{{2|}}}|/{{{2}}}}}*100 round 0}}%; height: 100%; overflow: hidden; display: block; background: #b1b1b1; border-radius: 2px;"></span></div><noinclude>
+
<div style="height:16px; max-width:200px; background: #252525; border-radius: 2px; padding: 2px"><span style="width:{{#expr: {{{1<noinclude>|0.25</noinclude>}}}{{#if: {{{2|}}}|/{{{2}}}}}*100 round 0}}%; height: 100%; overflow: hidden; display: block; background: #b1b1b1; border-radius: 2px;"></span></div><noinclude>
 
----
 
----
Draws a bar with the specified length.
+
Draws a bar with the specified length filled in.
  
{{Parameter Table|parameters=
+
{{Parameter table|parameters=
{{Parameter Row|1|Filled percentage with a value between 0 and the second parameter|}}
+
{{Parameter row|1|How much the bar is filled in, with a value between 0 and the second parameter.}}
{{Parameter Row|2|Maximum value.|1}}
+
{{Parameter row|2|The maximum value.|1}}
}}</noinclude>
+
}}
 +
 
 +
[[Category:Metatemplates]]</noinclude>

Latest revision as of 15:00, 22 September 2024


Draws a bar with the specified length filled in.

# Optional Description Default
1 No How much the bar is filled in, with a value between 0 and the second parameter.
2 Yes The maximum value. 1