Template:DiceColors: Difference between revisions
Content added Content deleted
(Adding the DiceColors template) |
(Removing vertical-align as it would break if more than 1 die were shown with different alignments.) |
||
Line 1: | Line 1: | ||
<includeonly><span |
<includeonly><span>{{#if: {{#explode:{{{2}}}|,|2}}|<span style="font: {{{3|2em}}}/1 "Cards-and-Dice"; color: {{#explode:{{{2}}}|,|2}}; white-space: nowrap; overflow: hidden; word-break: keep-all;position: absolute;">:{{#explode:{{{1}}}|-|0}}solid</span>|}}{{#if: {{#explode:{{{2}}}|,|1}}|<span style="font: {{{3|2em}}}/1 "Cards-and-Dice"; color: {{#explode:{{{2}}}|,|1}}; white-space: nowrap; overflow: hidden; word-break: keep-all;position: absolute;">:{{#explode:{{{1}}}|-|0}}blank</span>|}}{{#if: {{#explode:{{{2}}}|,|0}}|<span style="font: {{{3|2em}}}/1 "Cards-and-Dice"; color: {{#explode:{{{2}}}|,|0}}; white-space: nowrap; overflow: hidden; word-break: keep-all;position: absolute;">:{{#explode:{{{1}}}|-|0}}-{{#explode:{{{1}}}|-|1}}</span>|}}<span style="font: {{{3|2em}}}/1 "Cards-and-Dice"; color: {{#explode:{{{2|black}}}|,|3}}; white-space: nowrap; overflow: hidden; word-break: keep-all;position: relative;{{#if: {{#explode:{{{2}}}|,|3}}||opacity:0%;}}">:{{#explode:{{{1}}}|-|0}}border</span></span></includeonly><noinclude> |
||
This template allows you to easily add multi-colored dice to any page. For example: |
This template allows you to easily add multi-colored dice to any page. For example: |
||
{{DiceColors|d6-3|aquamarine,blue,red,black|4em |
{{DiceColors|d6-3|aquamarine,blue,red,black|4em}} |
||
=== Usage === |
=== Usage === |
||
Line 10: | Line 10: | ||
| colors |
| colors |
||
| size |
| size |
||
| vertical-align |
|||
}} |
}} |
||
</nowiki></pre> |
</nowiki></pre> |
||
The above example used the following: <nowiki>{{DiceColors|d6-3|aquamarine,blue,red,black|4em |
The above example used the following: <nowiki>{{DiceColors|d6-3|aquamarine,blue,red,black|4em}}</nowiki> |
||
<br/><br/> |
<br/><br/> |
||
For a more in depth explanation see [[How_to_Use_DiceColors_template]] |
For a more in depth explanation see [[How_to_Use_DiceColors_template]] |
Latest revision as of 01:13, 26 April 2024
This template allows you to easily add multi-colored dice to any page. For example:
Usage[edit source]
{{DiceColors | die-value | colors | size }}
The above example used the following: {{DiceColors|d6-3|aquamarine,blue,red,black|4em}}
For a more in depth explanation see How_to_Use_DiceColors_template