Template:CenterAlignIcon/doc: Difference between revisions

From City of Heroes: Rebirth Wiki
Jump to navigation Jump to search
imported>Sekoia
(Created page with "{{Documentation subpage}} <!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE. --> ==Usage== This template will allow a column of icons to be aligned such that ...")
 
imported>Sekoia
No edit summary
Line 3: Line 3:
==Usage==
==Usage==


This template will allow a column of icons to be aligned such that their icons are all in a vertical column, irrespective of whatever text is to their right.
This template will allow a column of icons to be aligned such that their icons are all in a vertical column, irrespective of whatever text is to their right. In order for them to center align, they must be in a context that is centered.


Permissible option:
Permissible option:
Line 15: Line 15:
; hover=
; hover=
: The text do display if the mouse is hovered over the image. Default is <nowiki>{{{image}}}</nowiki>.
: The text do display if the mouse is hovered over the image. Default is <nowiki>{{{image}}}</nowiki>.
==Examples==
{| class="wikitable" style="text-align:center;"
! Template Call !! width=150px | Result
|-
| <nowiki>{{CenterAlignIcon|width=24|text=33%|image=File:TO Training Endurance Cost.png|hover=Endurance Cost}}</nowiki>
| {{CenterAlignIcon|width=24|text=33%|image=File:TO Training Endurance Cost.png|hover=Endurance Cost}}
|-
| <nowiki>{{CenterAlignIcon|width=24|text=16.5%|image=File:TO Training Fear Duration.png|hover=Fear Duration}}</nowiki>
| {{CenterAlignIcon|width=24|text=16.5%|image=File:TO Training Fear Duration.png|hover=Fear Duration}}
|}


<includeonly><!--
<includeonly><!--
++++ PLEASE ADD CATEGORIES AND INTERWIKIS BELOW THIS LINE, THANK YOU. -->
++++ PLEASE ADD CATEGORIES AND INTERWIKIS BELOW THIS LINE, THANK YOU. -->
</includeonly>
</includeonly>

Revision as of 00:07, 15 November 2010

This is a documentation subpage for Template:CenterAlignIcon (see that page for the template itself).
It contains usage information, categories and other content that is not part of the original template page.

Usage

This template will allow a column of icons to be aligned such that their icons are all in a vertical column, irrespective of whatever text is to their right. In order for them to center align, they must be in a context that is centered.

Permissible option:

width=
The width of the image to use, in pixels. Required.
text=
The text to show at the right. Required.
image=
The image to show. Required.
hover=
The text do display if the mouse is hovered over the image. Default is {{{image}}}.

Examples

Template Call Result
{{CenterAlignIcon|width=24|text=33%|image=File:TO Training Endurance Cost.png|hover=Endurance Cost}} 33%Endurance Cost
{{CenterAlignIcon|width=24|text=16.5%|image=File:TO Training Fear Duration.png|hover=Fear Duration}} 16.5%Fear Duration