Template:Infobox Game Fancy: Difference between revisions

Content added Content deleted
imported>Umjahwa
(Added cleaning functions to "other_equip" and "BGG url". Almost good to go!)
imported>Umjahwa
m (minor fix)
Line 31: Line 31:
|- {{#if: {{{other_equip|}}} | valign=top | style="display: none;" }}
|- {{#if: {{{other_equip|}}} | valign=top | style="display: none;" }}
! colspan=2 align=right valign=top | Other equipment:
! colspan=2 align=right valign=top | Other equipment:
| {{{other_equip|}}} {{#set:|Other Equipment={{#invoke: Infobox Tools | clean_equip | {{{designer|unknown}}}}}|+sep=,}}
| {{{other_equip|}}} {{#set:|Other Equipment={{#invoke: Infobox Tools | clean_equip | {{{other_equip|}}}}}|+sep=,}}
|- {{#if: {{{setup_time|}}} | | style="display: none;" }}
|- {{#if: {{{setup_time|}}} | | style="display: none;" }}
! colspan=2 align=right valign=top | Setup time:
! colspan=2 align=right valign=top | Setup time:
Line 67: Line 67:
Change list:
Change list:
* Added player count, game length, and rule complexity icons
* Added player count, game length, and rule complexity icons
* Added options for "username", "game_length", and "trios"
* Added options for "game_length" and "trios"
* Compressed min & max players count and min and max playing time to single lines separated by a dash when both variables are defined (note: the variables are still mapped to separate properties, only the infobox display is different)
* Compressed min & max players count and min and max playing time to single lines separated by a dash when both variables are defined (note: the variables are still mapped to separate properties, only the infobox display is different)
* Added logic to hide most lines when the parameter is left blank (should look cleaner and work better on mobile browsers). Note: due to this coding, the box at right does not show all of the available input parameters.
* Added logic to hide most lines when the parameter is left blank (should look cleaner and work better on mobile browsers). Note: due to this coding, the box at right does not show all of the available input parameters.
* (hopefully) fixed some of the mapping of input values to semantic properties (hence the creation of this template to test on a dummy game)
* Fixed some of the mapping of input values to semantic properties (now using Lua scripts!)


Note: all of the original parameters are included with the exact same variable names as the original infobox. In theory, this template could be swapped with the existing template without breaking anything... however, there is a lot more testing that needs to be done and the design needs to be vetted by the wiki administrators as well as the more senior wiki users. Please do not use this infobox on any of the current game pages.
Note: all of the original parameters are included with the exact same variable names as the original infobox. In theory, this template could be swapped with the existing template without breaking anything... however, there is a lot more testing that needs to be done and the design needs to be vetted by the wiki administrators as well as the more senior wiki users. Please do not use this infobox on any of the current game pages.
Line 115: Line 115:


'''''Designer'' => designer'''
'''''Designer'' => designer'''
:The name of the person who created the game. By default, the designer's name is assumed to be the title of a page on the icehousegames.org wiki. Note: you should not need to use square brackets to create the link!
:The name of the person who created the game. If that person has a page on icehousegames.org, you can enclose the name in double square brackets to provide a link to that person's page.
:<pre>designer=<nowiki>Andrew Looney</nowiki></pre>
:<pre>designer=<nowiki>Andrew Looney</nowiki></pre>

'''''NOT_SHOWN'' => username'''
:(optional) If the designer as a user account on the icehousegames.org wiki, you can indicate it here so as to (hopefully) redirect the link correctly. Note: this feature is currently under testing.
:<pre>username=<nowiki>eeyore</nowiki></pre>


'''''(Image)'' => image_link'''
'''''(Image)'' => image_link'''