Template:Icon box: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
add class property |
||
| Line 1: | Line 1: | ||
<includeonly><table role="{{{role|text container}}}" style="color: {{{color|inherit}}}; background-color: {{{background|inherit}}}; border: {{{border-width|1px}}} {{{border-style|solid}}} {{{border-color|#eaecf0}}}; margin: 4px {{#if: {{{margin|}}}|10%|0}}; border-collapse: collapse;"><tr> | <includeonly><table role="{{{role|text container}}}" {{#if: {{{class|}}}|class="{{{class}}}" }} style="color: {{{color|inherit}}}; background-color: {{{background|inherit}}}; border: {{{border-width|1px}}} {{{border-style|solid}}} {{{border-color|#eaecf0}}}; margin: 4px {{#if: {{{margin|}}}|10%|0}}; border-collapse: collapse;"><tr> | ||
<td style="padding: 2px 0 2px 0.9em; text-align: center; line-height: 1;"><span style="white-space: nowrap;">{{{box-icons}}}</span></td> | <td style="padding: 2px 0 2px 0.9em; text-align: center; line-height: 1;"><span style="white-space: nowrap;">{{{box-icons}}}</span></td> | ||
<td style="padding: {{{padding|0.35em}}} 0.9em; width: 100%;">{{{box-text}}}</td> | <td style="padding: {{{padding|0.35em}}} 0.9em; width: 100%;">{{{box-text}}}</td> | ||
| Line 70: | Line 70: | ||
"autovalue": "false", | "autovalue": "false", | ||
"suggested": true | "suggested": true | ||
}, | |||
"class": { | |||
"label": "HTML class", | |||
"description": "HTML class/classes to add to the box, space-separated.", | |||
"type": "string" | |||
} | } | ||
}, | }, | ||
| Line 84: | Line 89: | ||
"border-width", | "border-width", | ||
"padding", | "padding", | ||
"role" | "role", | ||
"class" | |||
] | ] | ||
} | } | ||
</templatedata> | </templatedata> | ||
</noinclude> | </noinclude> | ||
Latest revision as of 18:16, 20 February 2025
Floating box with an icon and background. Used for licensing templates, Template:Note and similar boxes.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Box text | box-text | Text inside of the box. | Content | required |
| Box icons | box-icons | Standard wikitext containing the icons to place inside of the box, see example syntax. | Content | suggested |
| Enable margin | margin | If set, adds a margin from the sides of the box.
| Boolean | suggested |
| Text color | color | Text color in any format supported by CSS (hex, rgb(...), ...)
| String | optional |
| Background color | background | Background color in any format supported by CSS (hex, rgb(...), ...)
| String | optional |
| Border color | border-color | Text color in any format supported by CSS (hex, rgb(...), ...)
| String | optional |
| Border style | border-style | CSS border-style value
| String | optional |
| Border width | border-width | Border width with unit
| String | optional |
| Padding | padding | Padding to add to the box, with the unit
| String | optional |
| HTML role | role | HTML accessible role parameter to add to the box.
| String | optional |
| HTML class | class | HTML class/classes to add to the box, space-separated. | String | optional |