Plantilla:Float file box
This is an alternative version of {{float file}}. It is similarly used to display an image to the left of an infobox, but it additionally accommodates placing long captions on small images (small images usually cause long captions to cut off and/or break into many unsightly lines). It will also accommodate placing one caption under multiple small images.
Usage
{{ float file box | <image wiki code> | <image caption> | title = <box title> | float = right/left | width = <box width> | css/style = <custom box styling> | image-css = <custom image styling> | caption-css | <custom caption styling> }}
- First unnamed parameter
Complete wiki code for the image, including brackets.
- Second unnamed parameter
Text of the caption beneath the image.
- title
Text displayed as the title of the box.
- float
Float position, defaults to right
.
- width
Width of the box, defaults to 150px
.
- css/style
Additional styling for the entire box.
- image-css
Styling for the image, in the format of table row styling (e.g. | image-css = class="myclass" style="color:red"
).
- caption-css
Styling for the caption, in the format of table row styling.
Examples
Code | Result | |||
---|---|---|---|---|
{{float file box|[[File:Dye test on Orichalcum armor (Pink Dye).png]]|This very long caption would normally look ''very awkward'' underneath this narrow image of [[Orichalcum armor]] being dyed with [[Pink Dye]].}}
|
| |||
{{float file box|[[File:Tree.png|link=]]|This is an image of a tree.|title=CSS demo|width=90px|css=border-width:3px|image-css=style="background-color:var(--custom-notice-red-background-color)"|caption-css=class="terraria" style="color:var(--theme-text-color-note)"}}
|
|
- Formatting templates