Спорт-вики — википедия научного бодибилдинга

Шаблон:Progress bar — различия между версиями

Материал из SportWiki энциклопедии
Перейти к: навигация, поиск
Строка 1: Строка 1:
−
<includeonly>{{
+
<includeonly><div title="{{{title|{{{progression|<!--
−
#vardefine: lpbCurrent |
+
  -->{{#ifeq:{{{mode|}}}|value|{{{current|0}}}|<!--
−
{{#ifexpr: {{{current|0}}} - {{{max|100}}} &gt; 0 |
+
      -->{{#ifexpr:({{{current|0}}}-{{{min|0}}}&gt;=0) and ({{{max|100}}}-{{{min|0}}}&gt;0)|<!--
−
{{{max|100}}} |
+
        -->{{#expr:(({{{current|0}}}-{{{min|0}}})/({{{max|100}}}-{{{min|0}}}))*100 round 1}}%|0%}}}}}}} {{{desc|}}}}}}"
−
{{{current|0}}}
+
                        style="background: {{{box-background|}}};
−
}}
+
                                border: {{{box-border|1px solid black}}};
−
}}{{
+
                                margin: {{{box-margin|1px}}};
−
#vardefine: lpbProgression |
+
                                padding: {{{box-padding|1px}}};
−
{{{progression |
+
                                width: {{{box-width|100%}}};
−
{{#ifexpr: ({{#var:lpbCurrent}} - {{{min|0}}} &gt;= 0) and ({{{max|100}}} - {{{min|0}}} &gt; 0) |
+
                                color: {{{text-color|#ffffff}}};
−
{{#expr: (({{#var:lpbCurrent}} - {{{min|0}}}) / ({{{max|100}}} - {{{min|0}}})) * 100 round 1}}% |
+
                                text-shadow: 1px 1px #000000;
−
0%
+
                                font-size: {{{text-size|small}}};
−
}}
+
                                font-weight: {{{text-weight|bold}}};
−
}}}
+
                                line-height: 1.25em;
−
}}{{
+
                                {{{box-style|}}}"><!--
−
#vardefine: lpbTooltipDisplayMode |
+
                --><div style="margin: 0;
−
{{{tooltip-display-mode |
+
                                padding:0;
−
{{#if: {{#var:pb-tooltip-display-mode}} |
+
                                position:relative;"><!--
−
{{#var:pb-tooltip-display-mode}} |
+
                --><div style="margin: 0;
−
percentage
+
                                padding: 0;
−
}}
+
                                width: 100%;
−
}}}
+
                                position: absolute;
−
}}{{
+
                                top: 0;
−
#vardefine: lpbTooltipText |
+
                                z-index: 1;
−
{{#switch: {{#var:lpbTooltipDisplayMode}} |
+
                                background: transparent;
−
percentage = {{formatnum:{{#var:lpbProgression}}}}&nbsp; |
+
                                -ms-linear-gradient(top, #4b4b4b 0%, #919191 45%, #aeaeae 50%, #939393 55%, #aaaaaa 100%);
−
current    = {{formatnum:{{{current|0}}}}}&nbsp; |
+
                                linear-gradient(to bottom, #4b4b4b 0%, #919191 45%, #aeaeae 50%, #939393 55%, #aaaaaa 100%);
−
remaining  = {{formatnum:{{#expr: {{{max|100}}} - {{{current|0}}}}}}}&nbsp; |
+
                                border-radius: 5px;
−
ratio      = {{formatnum:{{{current|0}}}}} / {{formatnum:{{{max|100}}}}}&nbsp; |
+
                                -webkit-border-radius: 5px;
−
}}{{{tooltip-text |
+
                                -moz-border-radius: 5px;
−
{{#if: {{#var:pb-tooltip-text}} |
+
                                text-align: center;"><!--
−
{{#var:pb-tooltip-text}} |
+
                -->{{{progression-text|{{{progression|<!--
−
}}
+
                    -->{{#ifeq:{{{mode|}}}|value|{{{current|0}}}|<!--
−
}}}
+
                    -->{{#ifexpr:({{{current|0}}}-{{{min|0}}}&gt;=0) and ({{{max|100}}}-{{{min|0}}}&gt;0)|<!--
−
}}{{
+
                      -->{{#expr:(({{{current|0}}}-{{{min|0}}})/({{{max|100}}}-{{{min|0}}}))*100 round 1}}%|0%}}}}}}} <!--
−
#vardefine: lpbBarDisplayMode |
+
                          -->{{{desc|}}}}}}</div><!--
−
{{{bar-display-mode |
+
                --><div style="margin: 0;
−
{{#if: {{#var:pb-bar-display-mode}} |
+
                                padding: 0;
−
{{#var:pb-bar-display-mode}} |
+
                                width: {{{progression|<!--
−
percentage
+
                                  -->{{#ifexpr:({{{current|0}}}-{{{min|0}}}&gt;=0) and ({{{max|100}}}-{{{min|0}}}&gt;0)|<!--
−
}}
+
                                  -->{{#expr:(({{{current|0}}}-{{{min|0}}})/({{{max|100}}}-{{{min|0}}}))*100 round 1}}%|0%}}}}};
−
}}}
+
                                background: {{{bar-background|transparent}}};
−
}}{{
+
                                border-radius: 5px;
−
#vardefine: lpbBarText |
+
                                -webkit-border-radius: 5px;
−
{{#switch: {{#var:lpbBarDisplayMode}} |
+
                                -moz-border-radius: 5px;
−
percentage = {{formatnum:{{#var:lpbProgression}}}}&nbsp; |
+
                                height: 1.25em;
−
current    = {{formatnum:{{{current|0}}}}}&nbsp; |
+
                                {{{bar-style|}}}">&nbsp;</div></div></div></includeonly><noinclude>
−
remaining  = {{formatnum:{{#expr: {{{max|0}}} - {{{current|0}}}}}}}&nbsp; |
 
−
ratio      = {{formatnum:{{{current|0}}}}} / {{formatnum:{{{max|100}}}}}&nbsp; |
 
−
}}{{{bar-text |
 
−
{{#if: {{#var:pb-bar-text}} |
 
−
{{#var:pb-bar-text}} |
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBarBackground |
 
−
{{{bar-background |
 
−
{{#if: {{#var:pb-bar-background}} |
 
−
{{#var:pb-bar-background}} |
 
−
#AAD5FF
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBarCustomStyle |
 
−
{{{bar-custom-style |
 
−
{{#if: {{#var:pb-bar-custom-style}} |
 
−
{{#var:pb-bar-custom-style}} |
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBoxBackground |
 
−
{{{box-background |
 
−
{{#if: {{#var:pb-box-background}} |
 
−
{{#var:pb-box-background}} |
 
−
white
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBoxBorder |
 
−
{{{box-border |
 
−
{{#if: {{#var:pb-box-border}} |
 
−
{{#var:pb-box-border}} |
 
−
1px solid black
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBoxMargin |
 
−
{{{box-margin |
 
−
{{#if: {{#var:pb-box-margin}} |
 
−
{{#var:pb-box-margin}} |
 
−
1px
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBoxPadding |
 
−
{{{box-padding |
 
−
{{#if: {{#var:pb-box-padding}} |
 
−
{{#var:pb-box-padding}} |
 
−
1px
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBoxWidth |
 
−
{{{box-width |
 
−
{{#if: {{#var:pb-box-width}} |
 
−
{{#var:pb-box-width}} |
 
−
100%
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbBoxCustomStyle |
 
−
{{{box-custom-style |
 
−
{{#if: {{#var:pb-box-custom-style}} |
 
−
{{#var:pb-box-custom-style}} |
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbTextColor |
 
−
{{{text-color |
 
−
{{#if: {{#var:pb-text-color}} |
 
−
{{#var:pb-text-color}} |
 
−
black
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbTextSize |
 
−
{{{text-size |
 
−
{{#if: {{#var:pb-text-size}} |
 
−
{{#var:pb-text-size}} |
 
−
small
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#vardefine: lpbTextWeight |
 
−
{{{text-weight |
 
−
{{#if: {{#var:pb-text-weight}} |
 
−
{{#var:pb-text-weight}} |
 
−
bold
 
−
}}
 
−
}}}
 
−
}}{{
 
−
#if: {{{title|}}} | <span style="font-size:{{#var:lpbTextSize}};font-weight:{{#var:lpbTextWeight}}">{{{title|}}}</span> |
 
−
}}<div role="progressbar" aria-valuemin="{{{min|0}}}" aria-valuemax="{{{max|100}}}" aria-valuenow="{{{current|{{{progression|0}}}}}}" aria-valuetext="{{#var:lpbBarText}}" title="{{#var:lpbTooltipText}}" style="background:{{#var:lpbBoxBackground}};border:{{#var:lpbBoxBorder}};margin:{{#var:lpbBoxMargin}};padding:{{#var:lpbBoxPadding}};width:{{#var:lpbBoxWidth}};color:{{#var:lpbTextColor}};font-size:{{#var:lpbTextSize}};font-weight:{{#var:lpbTextWeight}};line-height:1.25em;{{#var:lpbBoxCustomStyle}}"><div style="margin:0;padding:0;position:relative;"><div style="margin:0;padding:0;width:{{#var:lpbProgression}};background:{{#var:lpbBarBackground}};height:1.25em;{{#var:lpbBarCustomStyle}}">&nbsp;</div><div style="margin:0;padding:0;width:100%;position:absolute;top:0;z-index:1;background-color:transparent;text-align:center;">{{#var:lpbBarText}}</div></div></div></includeonly><noinclude>
 

Версия 11:26, 22 января 2017