Difference between revisions of "Template:Tile"
From AYSO Wiki
(add support for external links) |
|||
Line 1: | Line 1: | ||
<includeonly><div class="tile d-inline-block"> | <includeonly><div class="tile d-inline-block"> | ||
<div class="tile-icon" {{#if:{{{image|}}}|data-background="{{#ifeq:{{{image|}}}|default|/w/extensions/MyWikisLocalConfig/favicon/apple-touch-icon.png|{{filepath:{{PAGENAME:{{{image|}}}}}}}}}"}}></div><!-- | <div class="tile-icon" {{#if:{{{image|}}}|data-background="{{#ifeq:{{{image|}}}|default|/w/extensions/MyWikisLocalConfig/favicon/apple-touch-icon.png|{{filepath:{{PAGENAME:{{{image|}}}}}}}}}"}}></div><!-- | ||
− | --><div class="tile-caption">{{#if:{{{target|}}} | + | --><div class="tile-caption">{{#if:{{{target|}}} or {{{external_target|}}} |
− | |[[{{{target|}}}|{{{title|}}}]] | + | |{{#if:{{{external_target|}}}|[{{{external_target}}} {{{title|}}}]|[[{{{target|}}}|{{{title|}}}]]}} |
|{{{title|}}} | |{{{title|}}} | ||
}}</div></div></includeonly><noinclude> | }}</div></div></includeonly><noinclude> | ||
Line 36: | Line 36: | ||
|image=Icon money.png | |image=Icon money.png | ||
}} | }} | ||
− | {{Tile | + | <!--{{Tile |
|title=Division Coordinator | |title=Division Coordinator | ||
|target=Division Coordinator | |target=Division Coordinator | ||
|image=Icon soccer.png | |image=Icon soccer.png | ||
+ | }}--> | ||
+ | {{Tile | ||
+ | |title=AYSO Website | ||
+ | |external_target=https://ayso.org | ||
+ | |image=Icon referee.png | ||
}} | }} | ||
}} | }} |
Revision as of 00:18, 11 May 2022
- Usage
{{Tile |title= |target= |image= }}
- Example
(Wrapped into Template:Tiles)
Creates a tile.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Tile title | title | Tile text. | String | optional |
Link target | target | Name of the page to link the tile to. | Page | optional |
Image | image | Name of the uploaded image to be shown as the tile icon. | File | optional |