Template:Fraction: Difference between revisions

ArrowHead294 (talk | contribs)
mNo edit summary
ArrowHead294 (talk | contribs)
mNo edit summary
Line 1: Line 1:
<includeonly><!--
<includeonly><!--
--><span style="white-space: nowrap;"><!--
--><span style="white-space: nowrap;"><!--
-->{{#if: {{{3|}}}<!-- if 3
-->{{#if: {{{3|}}}<!-- If 3
   -->| {{{1}}}<span style="border: 0; clip: rect(0, 0, 0, 0); clip-path: polygon(0px 0px, 0px 0px, 0px 0px); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px;">+</span><span style="font-size: 80%; line-height: 0; vertical-align: super;">{{{2}}}</span>&frasl;<span style="font-size: 80%; line-height: 0; vertical-align: sub;">{{{3}}}</span><!-- then 1 2/3
   -->| {{{1}}}<span style="border: 0; clip: rect(0, 0, 0, 0); clip-path: polygon(0px 0px, 0px 0px, 0px 0px); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px;">+</span><span style="font-size: 80%; line-height: 0; vertical-align: super;">{{{2}}}</span>&#8260;<span style="font-size: 80%; line-height: 0; vertical-align: sub;">{{{3}}}</span><!-- Then 1 2/3
   -->| {{#if: {{{2|}}}<!-- elseif 2
   -->| {{#if: {{{2|}}}<!-- ElseIf 2
     -->| <span style="font-size: 80%; line-height: 0; vertical-align: super;">{{{1}}}</span>&frasl;<span style="font-size: 80%; line-height: 0; vertical-align: sub;">{{{2}}}</span><!-- then 1/2
     -->| <span style="font-size: 80%; line-height: 0; vertical-align: super;">{{{1}}}</span>&frasl;<span style="font-size: 80%; line-height: 0; vertical-align: sub;">{{{2}}}</span><!-- Then 1/2
     -->| {{#if: {{{1|}}}<!-- elseif 1
     -->| {{#if: {{{1|}}}<!-- ElseIf 1
       -->| <span style="font-size: 80%; line-height: 0; vertical-align: super;">1</span>&frasl;<span style="font-size: 80%; line-height: 0; vertical-align: sub;">{{{1}}}</span><!-- then 1/1
       -->| <span style="font-size: 80%; line-height: 0; vertical-align: super;">1</span>&frasl;<span style="font-size: 80%; line-height: 0; vertical-align: sub;">{{{1}}}</span><!-- Then 1/1
       -->| &frasl;<!-- else 0, a slash
       -->| &frasl;<!-- Else 0, a slash
     -->}}<!-- endif 1
     -->}}<!-- EndIf 1
   -->}}<!-- endif 2
   -->}}<!-- EndIf 2
-->}}<!-- endif 3
-->}}<!-- EndIf 3
--></span></includeonly><noinclude>
--></span></includeonly><noinclude>
This template is copied over from [[wikipedia:Template:Fraction|Wikipedia's template for fractions]], except that the styles are all inline instead of being located in a separate stylesheet.
This template is the same as Wikipedia's fraction template, except all of the CSS is done inline instead of in a separate sheet.


You can use <code>{{((}}frac{{))}}</code> as a shortcut.
You can use <code>{{((}}frac{{))}}</code> as a shortcut.