Jump to content
Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:Infobox tournament: Difference between revisions

Template page
m Infobox tournament: auto-generate a lead paragraph from the same infobox parameters
m Infobox tournament: auto-generate a lead paragraph from the same infobox parameters
Line 3: Line 3:
|image=
|image=
|type={{{type|}}}
|type={{{type|}}}
|content={{#if:{{{image|}}}|<div class="loka-tournament-image">[[File:{{{image|}}}|300px|frameless|alt={{{name|{{PAGENAME}}}}}]]</div>}}<div class="loka-tournament-columns"><div class="loka-tournament-details"><div class="loka-tournament-col-heading">Tournament Details</div><div class="loka-tournament-details-grid">{{#if:{{{date|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Date</span><span class="loka-tournament-detail-value">{{{date|}}}</span></div>}}{{#if:{{{format|}}}{{{mode|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Format</span><span class="loka-tournament-detail-value">{{#if:{{{format|}}}|{{{format|}}}{{#if:{{{mode|}}}|&#32;{{{mode|}}}}}|{{{mode|}}}}}</span></div>}}{{#if:{{{host|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Host town</span><span class="loka-tournament-detail-value">[[{{{host|}}}]]</span></div>}}{{#if:{{{bid|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Forums Bid</span><span class="loka-tournament-detail-value">[https://forums.lokamc.com/threads/{{{bid|}}}/ Thread]</span></div>}}{{#if:{{{challonge|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Bracket</span><span class="loka-tournament-detail-value">[[File:Challonge logo.svg|16px|link=https://challonge.com/{{{challonge|}}}]] [https://challonge.com/{{{challonge|}}} Challonge]</span></div>}}</div>{{#if:{{{runner1|}}}|<div class="loka-tournament-detail loka-tournament-runners-tile"><span class="loka-tournament-detail-label">Tournament Runners</span><span class="loka-tournament-detail-value"><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{runner1|}}}|<li>{{{runner1|}}}</li>}}{{#if:{{{runner2|}}}|<li>{{{runner2|}}}</li>}}{{#if:{{{runner3|}}}|<li>{{{runner3|}}}</li>}}{{#if:{{{runner4|}}}|<li>{{{runner4|}}}</li>}}{{#if:{{{runner5|}}}|<li>{{{runner5|}}}</li>}}{{#if:{{{runner6|}}}|<li>{{{runner6|}}}</li>}}</ul></span></div>}}</div><div class="loka-tournament-results"><div class="loka-tournament-col-heading">Results</div>{{#if:{{{winnerteam|}}}|<div class="loka-podium-row">[[File:Gold Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">Winner</div><div class="loka-podium-team">{{{winnerteam|}}}</div><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{winner1|}}}|<li>{{{winner1|}}}</li>}}{{#if:{{{winner2|}}}|<li>{{{winner2|}}}</li>}}{{#if:{{{winner3|}}}|<li>{{{winner3|}}}</li>}}</ul></div></div>|{{#if:{{{winner|}}}|<div class="loka-podium-row">[[File:Gold Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">Winner</div><div class="loka-podium-single">{{{winner|}}}</div></div></div>}}}}{{#if:{{{secondteam|}}}|<div class="loka-podium-row">[[File:Silver Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">2nd Place</div><div class="loka-podium-team">{{{secondteam|}}}</div><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{second1|}}}|<li>{{{second1|}}}</li>}}{{#if:{{{second2|}}}|<li>{{{second2|}}}</li>}}{{#if:{{{second3|}}}|<li>{{{second3|}}}</li>}}</ul></div></div>|{{#if:{{{second|}}}|<div class="loka-podium-row">[[File:Silver Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">2nd Place</div><div class="loka-podium-single">{{{second|}}}</div></div></div>}}}}{{#if:{{{thirdteam|}}}|<div class="loka-podium-row">[[File:Bronze Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">3rd Place</div><div class="loka-podium-team">{{{thirdteam|}}}</div><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{third1|}}}|<li>{{{third1|}}}</li>}}{{#if:{{{third2|}}}|<li>{{{third2|}}}</li>}}{{#if:{{{third3|}}}|<li>{{{third3|}}}</li>}}</ul></div></div>|{{#if:{{{third|}}}|<div class="loka-podium-row">[[File:Bronze Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">3rd Place</div><div class="loka-podium-single">{{{third|}}}</div></div></div>}}}}{{#if:{{{winner|}}}{{{winnerteam|}}}{{{second|}}}{{{secondteam|}}}{{{third|}}}{{{thirdteam|}}}|<div class="loka-podium-disclaimer">IGNs correct at the time of tournament</div>}}</div></div>{{#if:{{{previous|}}}{{{next|}}}|<div class="loka-chrono-box"><div class="loka-chrono-header">Festival Chronology</div><div class="loka-chrono-grid">{{#if:{{{previous|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{previous|}}}]]</div>{{#if:{{{previousyear|}}}|<div class="loka-chrono-year">({{{previousyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--empty"><div class="loka-chrono-empty">&mdash;</div></div>}}<div class="loka-chrono-pane loka-chrono-pane--current"><div class="loka-chrono-title loka-chrono-title--current">{{{name|{{PAGENAME}}}}}</div>{{#if:{{{year|}}}|<div class="loka-chrono-year">({{{year|}}})</div>}}</div>{{#if:{{{next|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{next|}}}]]</div>{{#if:{{{nextyear|}}}|<div class="loka-chrono-year">({{{nextyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--tba"><div class="loka-chrono-tba">TBA</div></div>}}</div></div>}}{{#if:{{{townprevious|}}}{{{townnext|}}}|<div class="loka-chrono-box"><div class="loka-chrono-header">{{{host|}}} Chronology</div><div class="loka-chrono-grid">{{#if:{{{townprevious|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{townprevious|}}}]]</div>{{#if:{{{townpreviousyear|}}}|<div class="loka-chrono-year">({{{townpreviousyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--empty"><div class="loka-chrono-empty">&mdash;</div></div>}}<div class="loka-chrono-pane loka-chrono-pane--current"><div class="loka-chrono-title loka-chrono-title--current">{{{name|{{PAGENAME}}}}}</div>{{#if:{{{year|}}}|<div class="loka-chrono-year">({{{year|}}})</div>}}</div>{{#if:{{{townnext|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{townnext|}}}]]</div>{{#if:{{{townnextyear|}}}|<div class="loka-chrono-year">({{{townnextyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--tba"><div class="loka-chrono-tba">TBA</div></div>}}</div></div>}}
|content=<div class="loka-tournament-columns"><div class="loka-tournament-details"><div class="loka-tournament-col-heading">Tournament Details</div><div class="loka-tournament-details-grid">{{#if:{{{date|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Date</span><span class="loka-tournament-detail-value">{{{date|}}}</span></div>}}{{#if:{{{format|}}}{{{mode|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Format</span><span class="loka-tournament-detail-value">{{#if:{{{format|}}}|{{{format|}}}{{#if:{{{mode|}}}|&#32;{{{mode|}}}}}|{{{mode|}}}}}</span></div>}}{{#if:{{{host|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Host town</span><span class="loka-tournament-detail-value">[[{{{host|}}}]]</span></div>}}{{#if:{{{bid|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Forums Bid</span><span class="loka-tournament-detail-value">[https://forums.lokamc.com/threads/{{{bid|}}}/ Thread]</span></div>}}{{#if:{{{challonge|}}}|<div class="loka-tournament-detail"><span class="loka-tournament-detail-label">Bracket</span><span class="loka-tournament-detail-value">[[File:Challonge logo.svg|16px|link=https://challonge.com/{{{challonge|}}}]] [https://challonge.com/{{{challonge|}}} Challonge]</span></div>}}</div>{{#if:{{{runner1|}}}|<div class="loka-tournament-detail loka-tournament-runners-tile"><span class="loka-tournament-detail-label">Tournament Runners</span><span class="loka-tournament-detail-value"><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{runner1|}}}|<li>{{{runner1|}}}</li>}}{{#if:{{{runner2|}}}|<li>{{{runner2|}}}</li>}}{{#if:{{{runner3|}}}|<li>{{{runner3|}}}</li>}}{{#if:{{{runner4|}}}|<li>{{{runner4|}}}</li>}}{{#if:{{{runner5|}}}|<li>{{{runner5|}}}</li>}}{{#if:{{{runner6|}}}|<li>{{{runner6|}}}</li>}}</ul></span></div>}}</div><div class="loka-tournament-results">{{#if:{{{winnerteam|}}}|<div class="loka-podium-row">[[File:Gold Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">Winner</div><div class="loka-podium-team">{{{winnerteam|}}}</div><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{winner1|}}}|<li>{{{winner1|}}}</li>}}{{#if:{{{winner2|}}}|<li>{{{winner2|}}}</li>}}{{#if:{{{winner3|}}}|<li>{{{winner3|}}}</li>}}</ul></div></div>|{{#if:{{{winner|}}}|<div class="loka-podium-row">[[File:Gold Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">Winner</div><div class="loka-podium-single">{{{winner|}}}</div></div></div>}}}}{{#if:{{{secondteam|}}}|<div class="loka-podium-row">[[File:Silver Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">2nd Place</div><div class="loka-podium-team">{{{secondteam|}}}</div><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{second1|}}}|<li>{{{second1|}}}</li>}}{{#if:{{{second2|}}}|<li>{{{second2|}}}</li>}}{{#if:{{{second3|}}}|<li>{{{second3|}}}</li>}}</ul></div></div>|{{#if:{{{second|}}}|<div class="loka-podium-row">[[File:Silver Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">2nd Place</div><div class="loka-podium-single">{{{second|}}}</div></div></div>}}}}{{#if:{{{thirdteam|}}}|<div class="loka-podium-row">[[File:Bronze Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">3rd Place</div><div class="loka-podium-team">{{{thirdteam|}}}</div><ul class="loka-hlist loka-hlist--stacked">{{#if:{{{third1|}}}|<li>{{{third1|}}}</li>}}{{#if:{{{third2|}}}|<li>{{{third2|}}}</li>}}{{#if:{{{third3|}}}|<li>{{{third3|}}}</li>}}</ul></div></div>|{{#if:{{{third|}}}|<div class="loka-podium-row">[[File:Bronze Medal.png|22px|link=]]<div class="loka-podium-info"><div class="loka-podium-label">3rd Place</div><div class="loka-podium-single">{{{third|}}}</div></div></div>}}}}{{#if:{{{winner|}}}{{{winnerteam|}}}{{{second|}}}{{{secondteam|}}}{{{third|}}}{{{thirdteam|}}}|<div class="loka-podium-disclaimer">IGNs correct at the time of tournament</div>}}</div></div>{{#if:{{{previous|}}}{{{next|}}}|<div class="loka-chrono-box"><div class="loka-chrono-header">Festival Chronology</div><div class="loka-chrono-grid">{{#if:{{{previous|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{previous|}}}]]</div>{{#if:{{{previousyear|}}}|<div class="loka-chrono-year">({{{previousyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--empty"><div class="loka-chrono-empty">&mdash;</div></div>}}<div class="loka-chrono-pane loka-chrono-pane--current"><div class="loka-chrono-title loka-chrono-title--current">{{{name|{{PAGENAME}}}}}</div>{{#if:{{{date|}}}|<div class="loka-chrono-year">({{#time:F Y|{{{date|}}}}})</div>}}</div>{{#if:{{{next|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{next|}}}]]</div>{{#if:{{{nextyear|}}}|<div class="loka-chrono-year">({{{nextyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--tba"><div class="loka-chrono-tba">TBA</div></div>}}</div></div>}}{{#if:{{{townprevious|}}}{{{townnext|}}}|<div class="loka-chrono-box"><div class="loka-chrono-header">{{{host|}}} Chronology</div><div class="loka-chrono-grid">{{#if:{{{townprevious|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{townprevious|}}}]]</div>{{#if:{{{townpreviousyear|}}}|<div class="loka-chrono-year">({{{townpreviousyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--empty"><div class="loka-chrono-empty">&mdash;</div></div>}}<div class="loka-chrono-pane loka-chrono-pane--current"><div class="loka-chrono-title loka-chrono-title--current">{{{name|{{PAGENAME}}}}}</div>{{#if:{{{date|}}}|<div class="loka-chrono-year">({{#time:F Y|{{{date|}}}}})</div>}}</div>{{#if:{{{townnext|}}}|<div class="loka-chrono-pane"><div class="loka-chrono-title">[[{{{townnext|}}}]]</div>{{#if:{{{townnextyear|}}}|<div class="loka-chrono-year">({{{townnextyear|}}})</div>}}</div>|<div class="loka-chrono-pane loka-chrono-pane--tba"><div class="loka-chrono-tba">TBA</div></div>}}</div></div>}}
|wide=1
|wide=1
|headerimage={{{image|}}}
}}
}}


Line 18: Line 19:
|name=Asgard V
|name=Asgard V
|date=February 14, 2026
|date=February 14, 2026
|year=2026
|type=Player Run Festival
|type=Player Run Festival
|format=1v1
|format=1v1
Line 41: Line 41:
</pre>
</pre>


Only <code>name</code> is required (it otherwise defaults to the page name); every tile/row is hidden when omitted. Built on [[Template:Infobox]] for the shared name/type-badge chrome, using its <code>wide</code> modifier (520px instead of the standard 300px) -- see there for the wiki's common infobox look. Unlike Infobox town/player, the image is its own full-width block (not Infobox's padded <code>image</code> slot), so it spans the panel edge to edge.
Only <code>name</code> is required (it otherwise defaults to the page name); every tile/row is hidden when omitted. Built on [[Template:Infobox]] for the shared chrome, using its <code>wide</code> modifier (520px instead of the standard 300px) and its <code>headerimage</code> slot -- see there for the wiki's common infobox look. <code>image</code> is passed through as Infobox's <code>headerimage</code>, so it renders as a photo banner spanning the very top of the box with the name and type badge overlaid on a gradient scrim (tapering off toward the bottom to reveal the photo), rather than as a separate block.


Below the image, the box splits into two columns: "Tournament Details" on the left and "Results" on the right. Tournament Details is itself a 2-column grid of compact tiles (Date, Format, Host town, Forums Bid, Bracket), each a small caption label above a bold value; "Tournament Runners" is one more tile that spans both of those sub-columns, since it's a stacked list rather than a short value.
Below the header photo, the box splits into two columns: "Tournament Details" on the left and results (no heading needed -- Winner/2nd Place/3rd Place already say what it is) on the right. Tournament Details is itself a 2-column grid of compact tiles (Date, Format, Host town, Forums Bid, Bracket), each a small caption label above a bold value; "Tournament Runners" is one more tile that spans both of those sub-columns (its list of names isn't bolded, unlike the other tiles' values, since it's often the longest one and doesn't need the same visual weight).


For a 2v2/3v3 podium finish, use the <code>*team</code> + <code>*1</code>/<code>*2</code>/<code>*3</code> parameters instead of the plain one (e.g. <code>winnerteam</code>, <code>winner1</code>, <code>winner2</code>, <code>winner3</code>) -- team fields take priority over the plain field if both are somehow given. Team members (and Tournament Runners) are listed one per line rather than comma-separated. Whenever any podium field is filled in, a small disclaimer ("IGNs correct at the time of tournament") appears underneath.
For a 2v2/3v3 podium finish, use the <code>*team</code> + <code>*1</code>/<code>*2</code>/<code>*3</code> parameters instead of the plain one (e.g. <code>winnerteam</code>, <code>winner1</code>, <code>winner2</code>, <code>winner3</code>) -- team fields take priority over the plain field if both are somehow given. Team members (and Tournament Runners) are listed one per line rather than comma-separated. Whenever any podium field is filled in, a small disclaimer ("IGNs correct at the time of tournament") appears underneath.
Line 61: Line 61:
|-
|-
| <code>date</code>
| <code>date</code>
| Full date the tournament took place, shown as its own row.
| Full date the tournament took place (e.g. <code>July 19, 2026</code>), shown in its own tile. Its month and year are also derived from this automatically (via <code>{{#time:F Y|...}}</code>) for the chronology boxes -- there's no separate year parameter to keep in sync.
|-
| <code>year</code>
| This tournament's month and year (e.g. <code>July 2026</code>), shown under its own name in the chronology boxes. Separate from <code>date</code> since a bare month/year can't be reliably extracted from a full date without the StringFunctions extension.
|-
|-
| <code>image</code>
| <code>image</code>
| Filename of an image uploaded to the wiki (no <code>File:</code> prefix). Rendered full-width.
| Filename of an image uploaded to the wiki (no <code>File:</code> prefix). Rendered as the header photo banner.
|-
|-
| <code>type</code>
| <code>type</code>

Revision as of 07:19, 18 August 2026

Usage

{{Infobox tournament
|name=Asgard V
|date=February 14, 2026
|type=Player Run Festival
|format=1v1
|mode=Potion
|host=Asgard
|runner1=Deevil
|runner2=nainti
|runner3=Aqronso
|runner4=babisoy
|bid=10961
|challonge=exampleI
|winner=PlayerName
|second=PlayerName
|third=PlayerName
|previous=Asgard IV
|previousyear=November 2025
|next=Asgard VI
|townprevious=Asgard IV
|townpreviousyear=November 2025
|townnext=Asgard VI
}}

Only name is required (it otherwise defaults to the page name); every tile/row is hidden when omitted. Built on Template:Infobox for the shared chrome, using its wide modifier (520px instead of the standard 300px) and its headerimage slot -- see there for the wiki's common infobox look. image is passed through as Infobox's headerimage, so it renders as a photo banner spanning the very top of the box with the name and type badge overlaid on a gradient scrim (tapering off toward the bottom to reveal the photo), rather than as a separate block.

Below the header photo, the box splits into two columns: "Tournament Details" on the left and results (no heading needed -- Winner/2nd Place/3rd Place already say what it is) on the right. Tournament Details is itself a 2-column grid of compact tiles (Date, Format, Host town, Forums Bid, Bracket), each a small caption label above a bold value; "Tournament Runners" is one more tile that spans both of those sub-columns (its list of names isn't bolded, unlike the other tiles' values, since it's often the longest one and doesn't need the same visual weight).

For a 2v2/3v3 podium finish, use the *team + *1/*2/*3 parameters instead of the plain one (e.g. winnerteam, winner1, winner2, winner3) -- team fields take priority over the plain field if both are somehow given. Team members (and Tournament Runners) are listed one per line rather than comma-separated. Whenever any podium field is filled in, a small disclaimer ("IGNs correct at the time of tournament") appears underneath.

Both chronology sections render as a three-pane "previous / this tournament / next" box, matching Wikipedia's album/single succession boxes (without the vertical dividers or quote marks around the linked titles -- tournament names aren't quoted works the way song titles are). If next (or townnext) isn't given, that pane shows a grey "TBA" instead of being left blank, since a series' next entry is often simply not announced yet.

In addition to the infobox itself, the template outputs an auto-generated lead paragraph directly below it, built from the same parameters (identity/host/date, organizers, bid/bracket links, podium results, and general chronology). It's plain flowing wikitext, not part of the floated box, so it wraps to the left of the infobox the way a Wikipedia lead does. Every clause is individually optional and disappears if its underlying field is empty, so the wording is always in sync with the infobox and never needs to be hand-written or duplicated -- at the cost of being fairly formulaic, since it has no room for page-specific voice.

Parameters

Parameter Description
name Tournament name. Defaults to the page name.
date Full date the tournament took place (e.g. July 19, 2026), shown in its own tile. Its month and year are also derived from this automatically (via August 2026) for the chronology boxes -- there's no separate year parameter to keep in sync.
image Filename of an image uploaded to the wiki (no File: prefix). Rendered as the header photo banner.
type Free text, shown as a badge under the name -- e.g. Player Run Festival, matching the Loka Forums' own thread prefixes (Player Run Festival / Official Loka Festival / Unofficial Festival).
format Team size, e.g. 1v1, 2v2, 3v3. Kept separate from mode so it stays a clean, parseable value in its own right.
mode Optional ruleset/game mode, e.g. Potion, Barbones. Shown combined with format wherever format is displayed (e.g. "3v3 Potion") -- doesn't affect how many podium members are shown, that's driven purely by however many winner1/winner2/winner3 (etc.) are actually filled in.
host Hosting town. Wikilinked. Displayed as "Host town".
runner1 ... runner6 Up to six players running the festival ("Tournament Runners"), shown as a horizontal list.
bid Numeric Loka Forums thread ID for the festival's bid thread (e.g. 10961 for forums.lokamc.com/threads/asgard-v-february.10961/ -- the bare ID alone resolves correctly, no slug needed).
challonge Challonge tournament ID, e.g. riversideI for challonge.com/riversideI.
winner / second / third 1v1 podium: the winning player's name for that placing.
winnerteam / secondteam / thirdteam 2v2/3v3 podium: the team's name for that placing.
winner1-winner3 / second1-second3 / third1-third3 2v2/3v3 podium: up to three team members for that placing.
previous / previousyear / next / nextyear General festival chronology: the previous/next festival overall, with optional month/year (e.g. previousyear=April 2026).
townprevious / townpreviousyear / townnext / townnextyear Town-specific chronology: the previous/next festival hosted by the same town (e.g. Asgard IV / Asgard VI for Asgard V), shown as its own "{{{host}}} Chronology" box.