Template:GlobalFlag: Difference between revisions

From Ephinea PSO Wiki
(added tiny margin)
(this is me being picky about notes not extending to parentheses thanks very much)
 
Line 13: Line 13:
{{#if:{{{chex|}}}|
{{#if:{{{chex|}}}|
<tr>
<tr>
<th style="text-align: left;"><div style="display: inline;" align="left">Complete {{Note|Clicking/tapping the hexadecimal value will reveal its decimal conversion, if available.|(Hex)}}</div><div style="float: right;">:</div></th>
<th style="text-align: left;"><div style="display: inline;" align="left">Complete ({{Note|Clicking/tapping the hexadecimal value will reveal its decimal conversion, if available.|Hex}})</div><div style="float: right;">:</div></th>
<td style="text-align: right;"><span class="mw-customtoggle-complete">{{{chex}}}</span></td>
<td style="text-align: right;"><span class="mw-customtoggle-complete">{{{chex}}}</span></td>
</tr>
</tr>
Line 31: Line 31:
{{#if:{{{fhex|}}}|
{{#if:{{{fhex|}}}|
<tr>
<tr>
<th style="text-align: left;"><div style="display: inline;" align="left">Flag {{Note|Clicking/tapping the hexadecimal value will reveal its decimal conversion, if available.|(Hex)}}</div><div style="float: right;">:</div></th>
<th style="text-align: left;"><div style="display: inline;" align="left">Flag ({{Note|Clicking/tapping the hexadecimal value will reveal its decimal conversion, if available.|Hex}})</div><div style="float: right;">:</div></th>
<td style="text-align: right;"><span class="mw-customtoggle-flag">{{{fhex}}}</span></td>
<td style="text-align: right;"><span class="mw-customtoggle-flag">{{{fhex}}}</span></td>
</tr>
</tr>
Line 43: Line 43:
{{#if:{{{bmhex|}}}|
{{#if:{{{bmhex|}}}|
<tr>
<tr>
<th style="text-align: left;"><div style="display: inline;" align="left">Bitmask {{Note|Clicking/tapping a hexadecimal value will reveal its decimal conversion, if available.|(Hex)}}</div><div style="float: right;">:</div></th>
<th style="text-align: left;"><div style="display: inline;" align="left">Bitmask ({{Note|Clicking/tapping a hexadecimal value will reveal its decimal conversion, if available.|Hex}})</div><div style="float: right;">:</div></th>
<td style="text-align: right;"><span class="mw-customtoggle-bitmask">{{{bmhex}}}</span></td>
<td style="text-align: right;"><span class="mw-customtoggle-bitmask">{{{bmhex}}}</span></td>
</tr>
</tr>

Latest revision as of 16:22, 23 October 2024

Global flag
GlobalFlag

Usage and Examples[edit source]

There is a side effect where an expanded hexadecimal value revealing its decimal conversion will reveal the relevant conversion for all global flag infoboxes on a page, however at that point it is likely the user will want to make use of the decimal conversions within them as well, so there is no practical reason to fix this currently.

If using {{subst:onlyinclude|id=infobox| ... }} for a global flag article, use {{:article|infobox}} to transclude the infobox, in case other parts of the article are also marked for transclusion.

Global flag
Lucky Coins
Type
:
Currency
Max Amount
:
100
Flag (Hex)
:
B
Flag (Dec)
:
11
Bitmask (Hex)
:
00001FC
Bitmask (Dec)
:
508
{{subst:onlyinclude|id=infobox| // optional, used for global flag article transclusion
{{GlobalFlag
|title = Lucky Coins
|type = Currency
|max = 100         // used with Currency type
|fhex = B
|fdec = 11         // optional, will be hidden until hexadecimal value is clicked/tapped
|bmhex = 00001FC
|bmdec = 508       // optional, will be hidden until hexadecimal value is clicked/tapped
}}
}}                 // use if above onlyinclude substitution template is also used
Global flag
Wrapping Papers
Type
:
Collection
Complete (Hex)
:
1FF
Complete (Dec)
:
511
Flag (Hex)
:
B
Flag (Dec)
:
11
Bitmask (Hex)
:
1FF00000
Bitmask (Dec)
:
535822336
{{GlobalFlag
|title = Wrapping Papers
|type = Collection
|chex = 1FF        // used with Collection type
|cdec = 511        // optional, will be hidden until hexadecimal value is clicked/tapped
|fhex = B
|fdec = 11         // optional, will be hidden until hexadecimal value is clicked/tapped
|bmhex = 1FF00000
|bmdec = 535822336 // optional, will be hidden until hexadecimal value is clicked/tapped
}}