"साँचा:Pie chart" के अवतरणों में अंतर
नेविगेशन पर जाएँ
खोज पर जाएँ
imported>Shivkarandholiya12 |
https://hiwiki.iiit.ac.in/index.php?title=>Dcljr (support colors other than white for the "Other" slice & legend entry) |
||
पंक्ति १: | पंक्ति १: | ||
<includeonly><div class="PieChartTemplate thumb t{{{thumb|right | <includeonly>{{#ifeq:{{{thumb|}}}|center|<div class="center">}}<div class="PieChartTemplate thumb t{{#switch:{{{thumb|}}}|center|none=none|left=left|#default=right}}" {{#if:{{{style|}}}|style="{{{style|}}}"}}><div class="thumbinner" style="width:{{#expr:2*{{{radius|100}}}+2}}px"> | ||
<!-- Graph --> | <!-- Graph --> | ||
<div style="background-color:white;margin:auto;position:relative;width:{{#expr:2*{{{radius|100}}}}}px;height:{{#expr:2*{{{radius|100}}}}}px;overflow:hidden;border-radius:{{{radius|100}}}px;border:1px solid black"> | <div style="background-color:{{{other-color|white}}};margin:auto;position:relative;width:{{#expr:2*{{{radius|100}}}}}px;height:{{#expr:2*{{{radius|100}}}}}px;overflow:hidden;border-radius:{{{radius|100}}}px;border:1px solid black"> | ||
{{#if:{{{value30|}}}|{{Pie chart/slice|radius={{{radius|100}}}|{{{color30|{{gcolor|30}}}}}|{{#expr: | {{#if:{{{value30|}}}|{{Pie chart/slice|radius={{{radius|100}}}|{{{color30|{{gcolor|30}}}}}|{{#expr: | ||
{{{value1}}}+{{{value2}}}+{{{value3}}}+{{{value4}}}+{{{value5}}}+{{{value6}}}+{{{value7}}}+{{{value8}}}+{{{value9}}}+{{{value10}}}+{{{value11}}}+{{{value12}}}+{{{value13}}}+{{{value14}}}+{{{value15}}}+{{{value16}}}+{{{value17}}}+{{{value18}}}+{{{value19}}}+{{{value20}}}+{{{value21}}}+{{{value22}}}+{{{value23}}}+{{{value24}}}+{{{value25}}}+{{{value26}}}+{{{value27}}}+{{{value28}}}+{{{value29}}}+{{{value30}}} | {{{value1}}}+{{{value2}}}+{{{value3}}}+{{{value4}}}+{{{value5}}}+{{{value6}}}+{{{value7}}}+{{{value8}}}+{{{value9}}}+{{{value10}}}+{{{value11}}}+{{{value12}}}+{{{value13}}}+{{{value14}}}+{{{value15}}}+{{{value16}}}+{{{value17}}}+{{{value18}}}+{{{value19}}}+{{{value20}}}+{{{value21}}}+{{{value22}}}+{{{value23}}}+{{{value24}}}+{{{value25}}}+{{{value26}}}+{{{value27}}}+{{{value28}}}+{{{value29}}}+{{{value30}}} | ||
पंक्ति ९४: | पंक्ति ९४: | ||
</div> | </div> | ||
<!-- Legend --> | <!-- Legend --> | ||
<div class="thumbcaption"> | <div class="thumbcaption" {{#ifeq:{{{thumb|}}}|center|style="text-align:left"}}> | ||
{{{caption|}}} | {{{caption|}}} | ||
{{#if:{{{label1|}}}|{{legend|{{{color1|{{gcolor|1}}}}}|{{{label1}}} ({{{value1}}}%)}} | {{#if:{{{label1|}}}|{{legend|{{{color1|{{gcolor|1}}}}}|{{{label1}}} ({{{value1}}}%)}} | ||
पंक्ति १२६: | पंक्ति १२६: | ||
}}{{#if:{{{label29|}}}|{{legend|{{{color29|{{gcolor|29}}}}}|{{{label29}}} ({{{value29}}}%)}} | }}{{#if:{{{label29|}}}|{{legend|{{{color29|{{gcolor|29}}}}}|{{{label29}}} ({{{value29}}}%)}} | ||
}}{{#if:{{{label30|}}}|{{legend|{{{color30|{{gcolor|30}}}}}|{{{label30}}} ({{{value30}}}%)}} | }}{{#if:{{{label30|}}}|{{legend|{{{color30|{{gcolor|30}}}}}|{{{label30}}} ({{{value30}}}%)}} | ||
}}{{#if:{{{other|}}}|{{legend|white|Other ({{#expr:100-{{{value1|0}}}-{{{value2|0}}}-{{{value3|0}}}-{{{value4|0}}}-{{{value5|0}}}-{{{value6|0}}}-{{{value7|0}}}-{{{value8|0}}}-{{{value9|0}}}-{{{value10|0}}}-{{{value11|0}}}-{{{value12|0}}}-{{{value13|0}}}-{{{value14|0}}}-{{{value15|0}}}-{{{value16|0}}}-{{{value17|0}}}-{{{value18|0}}}-{{{value19|0}}}-{{{value20|0}}}-{{{value21|0}}}-{{{value22|0}}}-{{{value23|0}}}-{{{value24|0}}}-{{{value25|0}}}-{{{value26|0}}}-{{{value27|0}}}-{{{value28|0}}}-{{{value29|0}}}-{{{value30|0}}}}}%)}}}} | }}{{#if:{{{other|}}}|{{legend|{{{other-color|white}}}|Other ({{#expr:100-{{{value1|0}}}-{{{value2|0}}}-{{{value3|0}}}-{{{value4|0}}}-{{{value5|0}}}-{{{value6|0}}}-{{{value7|0}}}-{{{value8|0}}}-{{{value9|0}}}-{{{value10|0}}}-{{{value11|0}}}-{{{value12|0}}}-{{{value13|0}}}-{{{value14|0}}}-{{{value15|0}}}-{{{value16|0}}}-{{{value17|0}}}-{{{value18|0}}}-{{{value19|0}}}-{{{value20|0}}}-{{{value21|0}}}-{{{value22|0}}}-{{{value23|0}}}-{{{value24|0}}}-{{{value25|0}}}-{{{value26|0}}}-{{{value27|0}}}-{{{value28|0}}}-{{{value29|0}}}-{{{value30|0}}}}}%)}}}} | ||
{{#if:{{{footer|}}}|<p style="margin-bottom:0">{{{footer}}}</p>}} | {{#if:{{{footer|}}}|<p style="margin-bottom:0">{{{footer}}}</p>}} | ||
</div> | </div> | ||
</div></div></includeonly><noinclude> | </div></div>{{#ifeq:{{{thumb|}}}|center|</div>}}</includeonly><noinclude> | ||
{{documentation}} | {{documentation}} | ||
<!-- Add categories to the /doc subpage, interwikis to Wikidata. --> | <!-- Add categories to the /doc subpage, interwikis to Wikidata. --> | ||
</noinclude> | </noinclude> |