Jump to content

Template:Icon box

From postmarketOS Wiki
This page is a template. It contains no postmarketOS-related information, but should be used as part of other articles.

Check out all pages using this template and feel free to discuss it in the gitlab issues.

For more information, read Templates and Template:Template.

This is a template for a box with an icon, largely inspired by Wikipedia's Template:Mbox. It's mainly used for license boxes.

Icon This is an example of the icon box.
I can also use HTML tags and MediaWiki syntax, like links.
{{Icon box
| box-icons = [[File:Icon-numix-light-start-here.svg|28px|link=|Icon]]
| box-text = This is an example of the icon box.<br>I can also use HTML tags and [[Templates|MediaWiki syntax, like links]].
}}
Icon This is an example license box.
{{Icon box
| box-icons = [[File:Icon-numix-light-start-here.svg|28px|link=|Icon]]
| box-text = This is an example license box.
| border-color = #88a
| border-width = 3px
| background = #f7f8ff
}}
Note This is a box with no side margins.
{{Icon box
| box-icons = [[File:Icon-numix-light-start-here.svg|20px|link=|Note]]
| box-text = This is a box with no side margins.
| border-color = #ac6600
| border-width = 1px
| background = #f6efe5
| nomargin = yes
}}
Note Warning: Make sure to set your icon's size (like in the examples above).


Floating box with an icon and background. Used for licensing templates, Template:Note and similar boxes.

Template parameters[Edit template data]

This template prefers block formatting of parameters.

ParameterDescriptionTypeStatus
Box textbox-text

Text inside of the box.

Contentrequired
Box iconsbox-icons

Standard wikitext containing the icons to place inside of the box, see example syntax.

Contentsuggested
Disable marginnomargin

If set, removes the margin from the sides of the box.

Auto value
false
Booleansuggested
Text colorcolor

Text color in any format supported by CSS (hex, rgb(...), ...)

Auto value
inherit
Stringoptional
Background colorbackground

Background color in any format supported by CSS (hex, rgb(...), ...)

Auto value
inherit
Stringoptional
Border colorborder-color

Text color in any format supported by CSS (hex, rgb(...), ...)

Auto value
#eaecf0
Stringoptional
Border styleborder-style

CSS border-style value

Example
solid
Auto value
solid
Stringoptional
Border widthborder-width

Border width with unit

Example
1px
Auto value
1px
Stringoptional
Paddingpadding

Padding to add to the box, with the unit

Auto value
0.35em
Stringoptional
HTML rolerole

HTML accessible role parameter to add to the box.

Auto value
text container
Stringoptional
HTML classclass

HTML class/classes to add to the box.

Stringoptional