Template:Infobox: Difference between revisions

From Plover Wiki
No edit summary
No edit summary
Line 1: Line 1:
<includeonly><table class="infobox" style="width: 20%; margin: 0 0 1em 1em; float:right; background:#eee;">
<includeonly><table class="infobox" style="width: 25%; margin: 0 0 1em 1em; float:right; background:#eee;">
<caption class="infobox-title" style="background:{{{title-bg-color|#789}}}; color:{{{title-text-color|white}}}; text-align:center; padding:5px 10px">'''{{{name}}}'''</caption>
<caption class="infobox-title" style="background:{{{title-bg-color|#789}}}; color:{{{title-text-color|white}}}; text-align:center; padding:5px 10px">'''{{{name}}}'''</caption>
<tr {{#if:{{{image|}}}||style="display: none;"}}>
<tr {{#if:{{{image|}}}||style="display: none;"}}>

Revision as of 00:35, 25 July 2025


Default infobox template.

Although wikis usually use other technology to implement infoboxes, I don't think the commands are currently enabled and I don't have the power to turn it on. So this editor BTackt (talk) has decided to improve the poor and ugly HTML implementation into a slightly better and ugly HTML implementation.

Currently equipped for up to 9 rows in the info table.

Intended usage is as a default template for other infobox templates.

Attributes

title

Title text for the infobox.

title-bg-color (default: #789)

Background color in hexcode for the title of the infobox.

title-text-color (default: white)

Text color in hexcode for the title of the infobox. Recommended to switch to black if the title-bg-color has been switched to a light color.

image (optional)

Filename of image uploaded to this wiki.

image-size (default: 200px)

Size of the image to be displayed.

image-caption (optional)

Caption to be displayed under the image.

label1 (optional)

Label of the first item.

data1 (optional)

Data of the first item.

label2 (optional)

Label of the second item.

data2 (optional)

Data of the second item.

etc...
label9 (optional)

Label of the ninth item.

data9 (optional)

Data of the ninth item.

Usage example

{{Infobox
|name = Example Infobox
|label1 = Color
|data1 = red
|label2 = Shape
|data2 = star
|label3 = Language
|data3 = English
}}
Example Infobox
[[File:||200px]]
Color red
Shape star
Language English