Jump to content

Template:Infobox episode: Difference between revisions

From wiki58
m 1 revision: Updates made for portability
 
Replace Fandom component markup with native Wikipedia classes; retain source parameters, content, and archived history
Line 1: Line 1:
<infobox>
{{#if:{{{title|}}}{{{image|}}}{{{partOfSeason|}}}{{{episodeNumber|}}}{{{airDate|}}}{{{writer|}}}{{{director|}}}{{{previousEpisode|}}}{{{nextEpisode|}}}|<table class="infobox">
<title source="title"/>
{{#if:{{{title|}}}|<caption class="infobox-title">{{{title|}}}</caption>|}}
<image source="image"><caption source="imagecaption"/></image>
{{#if:{{{image|}}}|<tr>
<data source="partOfSeason"><label>Season</label></data>
<td class="infobox-image" colspan="2">
<data source="episodeNumber"><label>Episode</label></data>
{{#ifeq:{{#sub:{{{image|}}}|0|1}}|[|{{{image|}}}|[[{{#ifeq:{{lc:{{#sub:{{{image|}}}|0|5}}}}|file:||{{#ifeq:{{lc:{{#sub:{{{image|}}}|0|6}}}}|image:||File:}}}}{{{image|}}}|frameless|220px]]}}{{#if:{{{imagecaption|}}}|
<data source="airDate"><label>Air date</label></data>
<div class="infobox-caption">
<data source="writer"><label>Writer</label></data>
{{{imagecaption|}}}
<data source="director"><label>Director</label></data>
</div>|}}
<group layout="horizontal">
</td>
    <header>Episode guide</header>
</tr>|}}
    <data source="previousEpisode"><label>Previous</label></data>
{{#if:{{{partOfSeason|}}}|<tr>
    <data source="nextEpisode"><label>Next</label></data>
<th class="infobox-label" scope="row">
</group>
Season
</infobox><includeonly>[[Category:Episodes]]</includeonly><noinclude>{{Documentation}}</noinclude>
</th>
<td class="infobox-data">
{{{partOfSeason|}}}
</td>
</tr>|}}
{{#if:{{{episodeNumber|}}}|<tr>
<th class="infobox-label" scope="row">
Episode
</th>
<td class="infobox-data">
{{{episodeNumber|}}}
</td>
</tr>|}}
{{#if:{{{airDate|}}}|<tr>
<th class="infobox-label" scope="row">
Air date
</th>
<td class="infobox-data">
{{{airDate|}}}
</td>
</tr>|}}
{{#if:{{{writer|}}}|<tr>
<th class="infobox-label" scope="row">
Writer
</th>
<td class="infobox-data">
{{{writer|}}}
</td>
</tr>|}}
{{#if:{{{director|}}}|<tr>
<th class="infobox-label" scope="row">
Director
</th>
<td class="infobox-data">
{{{director|}}}
</td>
</tr>|}}
{{#if:{{{previousEpisode|}}}{{{nextEpisode|}}}|<tr>
<th class="infobox-header" colspan="2">
Episode guide
</th>
</tr>
<tr>
<td class="infobox-full-data" colspan="2">
<table class="infobox-subbox">
<tr>
{{#if:{{{previousEpisode|}}}|<th class="infobox-label" scope="col">
Previous
</th>|}}
{{#if:{{{nextEpisode|}}}|<th class="infobox-label" scope="col">
Next
</th>|}}
</tr>
<tr>
{{#if:{{{previousEpisode|}}}|<td class="infobox-data">
{{{previousEpisode|}}}
</td>|}}
{{#if:{{{nextEpisode|}}}|<td class="infobox-data">
{{{nextEpisode|}}}
</td>|}}
</tr>
</table>
</td>
</tr>|}}
</table>|}}<includeonly>[[Category:Episodes]]</includeonly><noinclude>
Native MediaWiki infobox using locally mirrored Wikipedia styles. Image fields accept a bare filename, a <code>File:</code>-prefixed name, or complete <code><nowiki>[[File:…]]</nowiki></code> markup. Fields, defaults, and categories retain the imported template API.
 
{{Documentation}}</noinclude>

Revision as of 17:59, 11 November 2026

Native MediaWiki infobox using locally mirrored Wikipedia styles. Image fields accept a bare filename, a File:-prefixed name, or complete [[File:…]] markup. Fields, defaults, and categories retain the imported template API.