No edit summary |
No edit summary |
||
(10 intermediate revisions by the same user not shown) | |||
Line 9: | Line 9: | ||
| Image-1 = | | Image-1 = | ||
| tab background-1 = | | tab background-1 = | ||
| tab align-1 = left, center, right | |||
| Tab-2 = | | Tab-2 = | ||
| URL-2 = | | URL-2 = | ||
| Image-2 = | | Image-2 = | ||
| tab background-2 = | | tab background-2 = | ||
| tab align-2 = left, center, right | |||
etc... | etc... | ||
| Tab-9 = | | Tab-9 = | ||
| URL-9 = | | URL-9 = | ||
| Image-9 = | | Image-9 = | ||
| tab background-9 = | | tab background-9 = | ||
| tab align-9 = left, center, right | |||
| tab align = left, center, right | | tab align = left, center, right | ||
| frame background = | | frame background = | ||
Line 24: | Line 27: | ||
| rounding = | | rounding = | ||
| asym = | | asym = | ||
| gap = | |||
| | | frame = Yes, No | ||
| font size = | |||
| image size = | |||
| selected = | |||
}} | }} | ||
</pre> | </pre> | ||
Line 38: | Line 44: | ||
'''Image-n''' | '''Image-n''' | ||
:Optional. Name of optional image (set to | :Optional. Name of optional image (set by default to 25px) to place next to tab title. Use {{para|<var>Image-n</var>|<var>Name of the picture as stored in the wiki</var>}} if you want to add a small picture in the tab. | ||
'''tab background-n''' | '''tab background-n''' | ||
:Optional. Color (either a named color or an Hex triplet) of the associated tab. If not specified, either the specified background parameter or the default built-in color is used. Use {{para|<var>tab background-n</var>|<var>color name or Hex triplet</var>}} if you want to specify a dedicated color for this specific tab. | :Optional. Color (either a named color or an Hex triplet) of the associated tab. If not specified, either the specified background parameter or the default built-in color is used. Use {{para|<var>tab background-n</var>|<var>color name or Hex triplet</var>}} if you want to specify a dedicated color for this specific tab. | ||
'''tab align-n''' | |||
:Optional. Text alignment for the tab box #n. It could be left, center or right. If not specified, the default alignment is either the one specified in ''tab align'' parameter, or the default built-in alignment : center. Use {{para|<var>tab align-n</var>|<var>left or center or right</var>}} if you want to specify a text alignment into the a specific tab box. | |||
'''tab align''' | '''tab align''' | ||
Line 52: | Line 61: | ||
'''border''' | '''border''' | ||
:Optional. | :Optional. CSS style (i.e. width, style and color) of the tabbed interface borders. If not specified, the default style is <span style="background-color:#87CEEB">''a solid line of 2px width with the color #87CEEB''</span> . Use {{para|<var>border</var>|<var>CSS Style</var>}} if you want to specify a color for the borders. A typical CSS style could be : ''solid 2px #87CEEB''. This is the combination of | ||
::a line style: ''solid'', ''dashed'', ''double'' or ''dotted'' | |||
::a line width: specified in pixel (with the ''px'' suffix) | |||
::a color name or color Hex triplet. | |||
'''rounding''' | '''rounding''' | ||
:Optional. Add rounding effect to edges of tab boxes. If not specified, the tab boxes are square and slightly separated. Use {{para|<var>rounding</var>|<var>numeric value</var>}} to specify the radius (in px) of the rounded edges. | :Optional. Add rounding effect to edges of tab boxes. If not specified, the tab boxes are square and slightly separated. Use {{para|<var>rounding</var>|<var>numeric value</var>}} (<u>without</u> the px suffix) to specify the radius (in px) of the rounded edges. | ||
'''asym''' | '''asym''' | ||
:Optional. useful only if ''rounding'' parameter is set. Add an asymmetric rounding effect by applying a coefficient on the radius of the left corner only. If not specified, the tab boxes are symmetrically rounded. Use {{para|<var>asym</var>|<var>numeric value</var>}} to specify coefficient to apply. | :Optional. useful only if ''rounding'' parameter is set. Add an asymmetric rounding effect by applying a coefficient on the radius of the left corner only. If not specified, the tab boxes are symmetrically rounded. Use {{para|<var>asym</var>|<var>numeric value</var>}} to specify coefficient to apply. | ||
'''gap''' | |||
:Optional. Specify the width (in % or the page width) of the gap between tabs. If not specified, the default gap is 2%, except if the ''rounding'' parameter is set (in this case there is no gap). Use {{para|<var>gap</var>|<var>percentage</var>}} (with the % sign) to specify the gap you want between tabs. | |||
'''frame''' | |||
:Optional. Specify if there is a frame (body) below the tabs bar or not. If not specified, the default value is Yes. Use {{para|<var>frame</var>|<var>No</var>}} if you don't want a frame below the tabs bar. | |||
:'''Important''' : ''if you use a frame below the tabs bar (i.e. default behavior) then the frame will extend until the end of the page. If you want to close the frame before the end of the page, put the template {{tl|Tab bottom}} at the desired position'' | |||
'''font size''' | |||
:Optional. Specify the font size (in %, as a ratio from the normal font) in the tab boxes. If not specified, the default size is 100%. Use {{para|<var>font size</var>|<var>percentage</var>}} (with the % sign) to specify the font size you want in the tab boxes. | |||
'''image size''' | |||
:Optional. Specify the image resizing (in px) if image are added in the tab boxes. If not specified, the default size is 25px. Use {{para|<var>image size</var>|<var>numeric value px</var>}} (with the px suffix) to specify the image resizing you want. | |||
'''selected''' | |||
:Optional. Specify which tab is selected. If not specified, the template automatically select the tab with an URL that matchs the displayed page. If no match are found, none of the tabs is selected. Use {{para|<var>selected</var>|<var>name of the tab</var>}} to specify the tab caption of the tab you want to show as selected. | |||
== | == Examples == | ||
Visit the [[Template:Tab top/Examples]] page to see the various customisation that can be applied on this template. | |||
== Where used == | |||
You can find all occurrences of this template with [[Special:WhatLinksHere/Template:Tab top|this link]]. | |||
[[ | |||
== Category added == | |||
This template does not add a category. |
Latest revision as of 12:26, 31 October 2014
This is a documentation subpage for . It contains usage information, categories and other content that is not part of the original template page. |
This template provides a tabbed interface to navigate between the core/main sections of a set of articles. This will result in displaying a menu of tabs for linking different pages. Up to 9 tabs can be specified. Whichever tab is the current page is automatically detected and the specified tab is presented with a different style.
Usage
{{Tab top | Tab-1 = | URL-1 = | Image-1 = | tab background-1 = | tab align-1 = left, center, right | Tab-2 = | URL-2 = | Image-2 = | tab background-2 = | tab align-2 = left, center, right etc... | Tab-9 = | URL-9 = | Image-9 = | tab background-9 = | tab align-9 = left, center, right | tab align = left, center, right | frame background = | tab background = | border = | rounding = | asym = | gap = | frame = Yes, No | font size = | image size = | selected = }}
Parameters
Tab-n
- Caption to display in tab #n. required for each tab to be displayed. use
|Tab-n=Title for tab #n
.
URL-n
- wiki link (thus, not an external URL) to the destination page to be reached if the tab #n is selected. required for each displayed tab. use
|URL-n=wiki link to the associated page for tav #n
.
Image-n
- Optional. Name of optional image (set by default to 25px) to place next to tab title. Use
|Image-n=Name of the picture as stored in the wiki
if you want to add a small picture in the tab.
tab background-n
- Optional. Color (either a named color or an Hex triplet) of the associated tab. If not specified, either the specified background parameter or the default built-in color is used. Use
|tab background-n=color name or Hex triplet
if you want to specify a dedicated color for this specific tab.
tab align-n
- Optional. Text alignment for the tab box #n. It could be left, center or right. If not specified, the default alignment is either the one specified in tab align parameter, or the default built-in alignment : center. Use
|tab align-n=left or center or right
if you want to specify a text alignment into the a specific tab box.
tab align
- Optional. Text alignment in the tab boxes. It could be left, center or right. If not specified, the default alignment is center. Use
|tab align=left or center or right
if you want to specify a text alignment into the tab boxes.
frame background
- Optional. Color (either a named color or an Hex triplet) of the selected tab and its body. If not specified, the default color is transparent. Use
|frame background=color name or Hex triplet
if you want to specify a color for the selected tab and its body.
tab background
- Optional. Default color (either a named color or an Hex triplet) of each non-selected tab. If not specified, the default color is skyblue . If a tab get its own background color (tab background-n parameter set) then this last one prevails for this tab. Use
|tab background=color name or Hex triplet
if you want to specify a default color for the non-selected tabs.
border
- Optional. CSS style (i.e. width, style and color) of the tabbed interface borders. If not specified, the default style is a solid line of 2px width with the color #87CEEB . Use
|border=CSS Style
if you want to specify a color for the borders. A typical CSS style could be : solid 2px #87CEEB. This is the combination of- a line style: solid, dashed, double or dotted
- a line width: specified in pixel (with the px suffix)
- a color name or color Hex triplet.
rounding
- Optional. Add rounding effect to edges of tab boxes. If not specified, the tab boxes are square and slightly separated. Use
|rounding=numeric value
(without the px suffix) to specify the radius (in px) of the rounded edges.
asym
- Optional. useful only if rounding parameter is set. Add an asymmetric rounding effect by applying a coefficient on the radius of the left corner only. If not specified, the tab boxes are symmetrically rounded. Use
|asym=numeric value
to specify coefficient to apply.
gap
- Optional. Specify the width (in % or the page width) of the gap between tabs. If not specified, the default gap is 2%, except if the rounding parameter is set (in this case there is no gap). Use
|gap=percentage
(with the % sign) to specify the gap you want between tabs.
frame
- Optional. Specify if there is a frame (body) below the tabs bar or not. If not specified, the default value is Yes. Use
|frame=No
if you don't want a frame below the tabs bar. - Important : if you use a frame below the tabs bar (i.e. default behavior) then the frame will extend until the end of the page. If you want to close the frame before the end of the page, put the template {{Tab bottom}} at the desired position
font size
- Optional. Specify the font size (in %, as a ratio from the normal font) in the tab boxes. If not specified, the default size is 100%. Use
|font size=percentage
(with the % sign) to specify the font size you want in the tab boxes.
image size
- Optional. Specify the image resizing (in px) if image are added in the tab boxes. If not specified, the default size is 25px. Use
|image size=numeric value px
(with the px suffix) to specify the image resizing you want.
selected
- Optional. Specify which tab is selected. If not specified, the template automatically select the tab with an URL that matchs the displayed page. If no match are found, none of the tabs is selected. Use
|selected=name of the tab
to specify the tab caption of the tab you want to show as selected.
Examples
Visit the Template:Tab top/Examples page to see the various customisation that can be applied on this template.
Where used
You can find all occurrences of this template with this link.
Category added
This template does not add a category.