Template:Infobox

From Love and Deepspace Wiki

Description[edit source]

This is a template approach to building custom infoboxes (e.g. Template:Character infobox). There are several sub-templates that are used.

  • Required Templates to create infobox
  • Infobox Parts

Excluding the row-data template, the naming of the templates follows the structure of the Wikipedia Infobox template, which a visual guide can be found here - w:Template:Infobox.

Usage[edit source]

Start/End[edit source]

To use these infobox templates, keep in mind that they must all include the start and end templates to work correctly. The other templates are put between these two.

{{Infobox/start}}
...content
{{Infobox/end}}

Title, Above, Header, Subheader, Below, Image[edit source]

All only take a single argument, which is the content to be displayed. For example, to get title:

{{Infobox/title|Title text here}}

Image follows a similar format, but you do need to provide it with the full file link (e.g. [[File:<filename>]].

line[edit source]

No arguments, simply renders an hr line element when used.

{{Infobox/line}}

row-data[edit source]

This is where this infobox differs. This template creates a row in the infobox, but also has the ability to split the row up to 4 sections if desired.

# of Sections Example Template
1 section only (Full row)
{{Infobox/row-data|content here}}
2 sections (e.g. For the standard label/data row)
{{Infobox/row-data
|sections=2
|left=
|right=
}}
3 sections (e.g. For next/label/previous rows)
{{Infobox/row-data
|sections=3
|left=
|mid=
|right=
}}
4 sections
{{Infobox/row-data
|sections=4
|left=
|midLeft=
|midRight=
|right=
}}

Full Example[edit source]

{{Infobox/start}}
{{Infobox/title|Sample Infobox}}
{{Infobox/above|Page name}}
{{Infobox/subheader|Subheader}}
{{Infobox/image|[[File:10 Days With You banner.png|link=]]}}
{{Infobox/line}}
{{Infobox/header|Sample Header}}
{{Infobox/row-data|some text here}}
{{Infobox/row-data
|sections=2
|left='''Label'''
|right=Data
}}
{{Infobox/line}}
{{Infobox/row-data
|sections=3
|left={{#fas:arrow-left}} Previous
|mid=Episodes
|right=Next {{#fas:arrow-right}}
}}
{{Infobox/below|The end...}}
{{Infobox/end}}
Sample Infobox
Page name
Subheader

Sample Header
some text here
Label
Data

Previous
Episodes
Next
The end...