Difference between revisions of "Template:OtherExpansionRule"
Jump to navigation
Jump to search
Bumsakalaka (talk | contribs) |
|||
(18 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
<div {{#if: {{{selectorid|}}} | class="{{{selectorid}}}" }} style="{{#if: {{{selectorid|}}} | | <div {{#if: {{{selectorid|}}} | class="{{{selectorid}}}" }} {{#if: {{{dynamicselector|}}} | data-dynamic-selector="{{#urldecode:{{{dynamicselector}}}}}" }} style="{{#if: {{{selectorid|}}} | display:none; | }} border: 1px solid lightgray; border-radius: 10px; padding-left: 10px; padding-right: 10px; margin-bottom: 1ex;"> | ||
'''{{{expansionlink}}}''' | '''{{{expansionlink}}}''' {{#if:{{{titleafter|}}} | - {{{titleafter}}} }} | ||
<div style="margin-left: 35px; margin-bottomː 10px"> | <div style="margin-left: 35px; margin-bottomː 10px; padding-bottom: 0.5ex;"> | ||
{{{rules}}} | {{{rules}}} | ||
</div> | </div> | ||
</div><noinclude><hr /> | </div><noinclude><hr /> | ||
== Description == | |||
Create a box with special rules for combination with other expansion. It also allows to use expansion selector ID to show/hide this rules box when selected or not selected specific expansion. | Create a box with special rules for combination with other expansion. It also allows to use expansion selector ID to show/hide this rules box when selected or not selected specific expansion. | ||
== Params == | |||
<code><nowiki> | * <code>expansionlink</code> (mandatory): Expansion Link like <code><nowiki>{{InnsCathedralsLink}}</nowiki></code>, formated as '''strong text''' | ||
* <code>titleafter</code> (optional): Text showed after content of <code>expansionlink</code> without formating | |||
''' | |||
* <code> | |||
* <code>rules</code> (mandatory): Text rules usually in format <code>icon</code> <i>text of rule</i> | * <code>rules</code> (mandatory): Text rules usually in format <code>icon</code> <i>text of rule</i> | ||
* <code>selectorid</code> (optional): Expansion selector ID like <code><nowiki>showInns</nowiki></code> | * <code>selectorid</code> (optional): Expansion selector ID like <code><nowiki>showInns</nowiki></code> used by '''Expansion Selector''' to show/hide by selected expansion by visitor. | ||
* <code>dynamicselector</code> (optional): Future dynamic selector of combination of expansions need to show this rule, like <code>[ 'OR' , 'showDragon' ,'showFairy']</code>, where first directove is <code>OR</code>, <code>AND</code>, <code>NOT</code> or <code>XOR</code> and other elements can be classes or another array of expression like <code>[ 'AND' , 'showFairy', [ 'OR', 'showDragon', 'showBlackDragon']]</code> | |||
< | == Examples == | ||
{| class="wikitable light" | |||
! Code || Description | |||
|- | |||
! <code><nowiki>{{OtherExpansionRule|expansionlink={{InnsCathedralsLink|edition=C3|variant=long}}|rules={{IconBook|text=Text of rules.}} }}</nowiki></code> || Create Other Expansion Rule box allways visible | |||
|- | |||
| colspan="2" | {{OtherExpansionRule|expansionlink={{InnsCathedralsLink|edition=C3|variant=long}}|rules={{IconBook|text=Text of rules.}} }} | |||
|- | |||
! <code><nowiki>{{OtherExpansionRule|expansionlink={{InnsCathedralsLink|edition=C3|variant=long}}|titleafter=or similar expansions|rules={{IconBook|text=Text of rules.}} }}</nowiki></code> || Always visible box with title after content of <code>expansionlink</code> | |||
|- | |||
| colspan="2" | {{OtherExpansionRule|expansionlink={{InnsCathedralsLink|edition=C3|variant=long}}|titleafter=or similar expansions|rules={{IconBook|text=Text of rules.}} }} | |||
|} | |||
</noinclude> | </noinclude> |
Latest revision as of 13:11, 7 May 2024
{{{expansionlink}}}
{{{rules}}}
Description
Create a box with special rules for combination with other expansion. It also allows to use expansion selector ID to show/hide this rules box when selected or not selected specific expansion.
Params
expansionlink
(mandatory): Expansion Link like{{InnsCathedralsLink}}
, formated as strong texttitleafter
(optional): Text showed after content ofexpansionlink
without formatingrules
(mandatory): Text rules usually in formaticon
text of ruleselectorid
(optional): Expansion selector ID likeshowInns
used by Expansion Selector to show/hide by selected expansion by visitor.dynamicselector
(optional): Future dynamic selector of combination of expansions need to show this rule, like[ 'OR' , 'showDragon' ,'showFairy']
, where first directove isOR
,AND
,NOT
orXOR
and other elements can be classes or another array of expression like[ 'AND' , 'showFairy', [ 'OR', 'showDragon', 'showBlackDragon']]
Examples
Code | Description |
---|---|
{{OtherExpansionRule|expansionlink={{InnsCathedralsLink|edition=C3|variant=long}}|rules={{IconBook|text=Text of rules.}} }} |
Create Other Expansion Rule box allways visible |
Text of rules.
| |
{{OtherExpansionRule|expansionlink={{InnsCathedralsLink|edition=C3|variant=long}}|titleafter=or similar expansions|rules={{IconBook|text=Text of rules.}} }} |
Always visible box with title after content of expansionlink
|
Exp. 1 - Inns & Cathedrals - or similar expansions Text of rules.
|