Template:Icon link
Displays a link with an icon.
This template simply calls Template:Icon text, passing on all parameters, except that the second parameter (text) implicitly becomes the link
, and an optional third parameter can override the actual text to use.
Examples
Example | Markup | Renders as |
---|---|---|
Default | {{icon link | Flourish Icon.png | Flourish }} | |
Custom link text | {{icon link | Flourish Icon.png | Flourish | Custom Text }} |
The default size is x40px
meaning the icon is scaled until the height is 40 px. It's usually important to limit the height since the icons are used inline, and a very high inline image makes for an unpleasant text layout.
An alternative value for the height can be provided via the size
or h
parameters, which are synonyms:
Markup | Renders as |
---|---|
{{icon link | size = 25 | font size = 80% | Flourish Icon.png | Flourish }} | |
{{icon link | size = 25 | font size = 80% | Flourish Icon.png | Flourish | Custom Text }} | |
{{icon link | Missing Icon 123.png | Flourish | Custom Text | size = 30}} |
The width can be set via the w
parameter. This could be useful if several elements are supposed to align vertically for design purposes, such as in the following table shown on our main page as of the writing of this documentation. This also uses the block
and gap
parameters. View the source of this page for usage.
Rolls | |
---|---|
The roll you make to determine whether an attack hits an enemy at all. | |
The roll you make to determine the amount of damage done by a successful attack. | |
The roll you make to attempt avoiding various threats other than direct attacks. | |
The roll you make when attempting anything else that requires a roll to succeed. | |
Modifiers | |
Roll the die twice, and use the higher result. Disadvantage is the exact opposite. | |
The number you add to your rolls based on your Ability Scores. | |
The number you add to your rolls based on whether you have Proficiency. |
Template parameters
Insert a linked icon.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Icon | 1 | The file to display as an icon, without the File: prefix. | String | required |
Link | 2 | Where to link to. | Page name | required |
Text | 3 | (optional) Replaces the link text with this if specified. | String | optional |
Width | w | (optional) Override the width of the image. | Number | optional |
Height | h | (optional) Override the height of the image. | Number | optional |
Size | size | (optional) Set the size of the image to this by this. | Number | optional |
Block | block | (optional) Whether to wrap the icon and link in a container HTML element. | String | optional |
Gap | gap | (optional) If 'block' is set, the exact gap to use between the icon and link. | Number | optional |
Nowrap | nowrap | (optional) If specified, will add the nowrap css style to the span. | String | optional |
Class | class | (optional) Any classes to add to the img | String | optional |
Font size | font size | (optional) Font size for the link. | Number | optional |
Separator | separator | (optional) Separator between icon and link; default is NBSP. | Content | optional |