Phial:Infobox Parts: Difference between revisions
More actions
No edit summary |
No edit summary |
||
| Line 19: | Line 19: | ||
<dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | <dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | ||
<dt class="infobox info-title">Main Title</dt> | <dt class="infobox info-title">Main Title</dt> | ||
</dl> | </dl> | ||
| Line 32: | Line 32: | ||
<dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | <dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | ||
<dd class="infobox info-name">Alternative Name</dd> | <dd class="infobox info-name">Alternative Name</dd> | ||
</dl> | </dl> | ||
==== Image ==== | ==== Image ==== | ||
This is for any single images. | This is for any single images. If you include a second field, | ||
<nowiki>*</nowiki> = the filename of the image, e.g. 'Ffv_box.png' | <nowiki>*</nowiki> = the filename of the image, e.g. 'Ffv_box.png' | ||
<nowiki>**</nowiki> = the image's caption. | |||
<pre> | <pre> | ||
{{#if:{{{*|}}} | {{#if:{{{*|}}} | ||
|[[File:{{{ | |[[File:{{{*}}}{{!}}frame{{!}}class=infobox info-image | ||
{{#if:{{{ | {{#if:{{{**|}}} | ||
|{{!}}{{{ | |{{!}}{{{**}}} | ||
}} | }} | ||
]] | ]] | ||
| Line 51: | Line 52: | ||
<dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | <dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | ||
[[File:Ffv_box.png|frame|class=infobox info-image|Final Fantasy V's box art.]] | [[File:Ffv_box.png|frame|class=infobox info-image|Final Fantasy V's box art.]] | ||
</dl> | </dl> | ||
==== Data Pairs ==== | |||
{{#if:{{{ | <pre> | ||
|{{#if:{{{ | {{#if:{{{*|}}} | ||
|{{#if:{{{**|}}} | |||
|<div class="infobox info-datablock"> | |<div class="infobox info-datablock"> | ||
<dt class="infobox info-label">{{{ | <dt class="infobox info-label">{{{*}}}</dt> | ||
<dd class="infobox info-data">{{{ | <dd class="infobox info-data">{{{**}}}</dd> | ||
</div> | </div> | ||
}} | }} | ||
}} | }} | ||
</pre> | |||
<dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> | |||
<div class="infobox info-datablock"> | |||
<dt class="infobox info-label">{{{Label}}}</dt> | |||
<dd class="infobox info-data">{{{Data point}}}</dd> | |||
</div> | |||
</dl> | |||
</dl> | </dl> | ||
</nowiki> | </nowiki> | ||
Revision as of 06:48, 17 November 2025
This is a collection of infobox parts. You can create new infoboxes using these, by pasting them into a new template in the order you want them, and wrapping the whole thing in the <dl> tag directly below.
You will need to replace any instance of asterisks (*) with the name of the field you want to use the element for. Names must be unique to each element within a given infobox, and are used to fill in the infobox from the page.
Start with this. It should wrap the entire infobox, meaning the </dl> tag should go after everything else in the template, as it does here.
<dl class="infobox info-wrapper"><templatestyles src="infobox.css"/> Everything else goes here. </dl>
Title
This is for if you want the infobox to have a title. Infoboxes generally don't need titles, unless the title is localized from Japanese translation, in which case you should use this Title part in tandem with the Name part below.
{{#if:{{{*|}}}
|<dt class="infobox info-title">{{{*}}}</dt>
}}
- Main Title
Name
This is for alternative names, including nicknames, aliases, and any original Japanese names. You should probably pair this with a Title, especially if it's at the top of an infobox.
{{#if:{{{*|}}}
|<dd class="infobox info-name">{{{*}}}</dd>
}}
- Alternative Name
Image
This is for any single images. If you include a second field,
* = the filename of the image, e.g. 'Ffv_box.png' ** = the image's caption.
{{#if:{{{*|}}}
|[[File:{{{*}}}{{!}}frame{{!}}class=infobox info-image
{{#if:{{{**|}}}
|{{!}}{{{**}}}
}}
]]
}}
Data Pairs
{{#if:{{{*|}}}
|{{#if:{{{**|}}}
|<div class="infobox info-datablock">
<dt class="infobox info-label">{{{*}}}</dt>
<dd class="infobox info-data">{{{**}}}</dd>
</div>
}}
}}
- {{{Label}}}
- {{{Data point}}}
</nowiki>
