Template:Portal box placard/doc

From blackwiki
Jump to navigation Jump to search

Template:Template rating Script error: No such module "Uses TemplateStyles".

Usage

This template is designed to be used in Portals (Portal Boxes).

{{Portal box placard|1=<file>|res-width=<width-in-px>|caption=<caption>}}


Examples:

{{Portal box placard|1=File:Santa Catalina Mountains Banner.jpg|res-width=1024px|caption=test caption}}

"res-width" and "caption" are optional.

{{Portal box placard|1=File:Santa Catalina Mountains Banner.jpg}}



test caption


Catalonia 2016 Zout Fotografie (196 van 196) (32589506286) crop.jpg


Catalonia 2016 Zout Fotografie (196 van 196) (32589506286) crop.jpg


Catalonia 2016 Zout Fotografie (196 van 196) (32589506286) crop.jpg


Catalonia 2016 Zout Fotografie (196 van 196) (32589506286) crop.jpg

More complex example with Flexboxes Template

Page Template:Flex columns/styles.css has no content.

What is the point of the res-width?

Big images take a long time to load and take up bandwidth. So please don't embed 8k high resolution images without setting a reasonable res-width, especially if you use a box that is smaller than 100%.
For instance if your box takes up 25% of the available space, then 1000px is definitely more than enough. And it will probably still look fine with less, even on 4k monitors.
Even for full width boxes, more than 3840px does not make much sense (as of 2019. Things might change in the future).

This is similar to Template:Portal image banner?

Yes, but this...

  • ...does not use any Lua
  • ...allows you to set a resolution width
  • ...has a more consistent margin on top and left/right
  • ...does not offer image carousels
  • ...does not place any text below the image
  • ...does not crop the image

Maybe at some point both can be merged.

See also

No description.

Template parameters

ParameterDescriptionTypeStatus
11

no description

Filerequired
Res-widthres-width

no description

Unknownoptional
Captioncaption

no description

Unknownoptional