Access Keys:
Skip to content (Access Key - 0)

deck macro

Overview:

The {deck} and {card} macros are both part of the Composition Plugin by Customware. When used together they create a tabbed panel which is ideal for separating out blocks of related content.

The {deck} macro is the outer wrapper which defines the general properties of any tabs such as their graphical style, location (above or below the deck) and a unique ID that's used to remember which card you have selected for when you return to the page.

The tabs are each defined by the card macro which provides card specific settings such as the text that appears in the tab and it's access key (also known as a keyboard shortcut).

This tutorial is primarily concerned with the {deck} macro and there is a related tutorial on the card macro.

Parameters:

The {deck} macro parameters that define the position of the tabs and the CSS class used to define how they look.

{deck:id=myDeck|tablocation=top|class=someDeck}
  {card}
    Content
  {card}
  {card}
    Content
  {card}
{deck}
Parameter Required Default Notes
id   The ID for the deck. Must be unique to this page.
tablocation top Either 'top', 'bottom' or 'none'. Defaults to 'top'.
class   The custom CSS class the deck is decorated by.

Examples

The deck of cards below, that contains our examples, uses the default Confluence tabs theme. Example three shows how to use alternate themes.


Hints and Tips

Only use these macros where they are really needed as they can sometimes make a web page look a little cluttered.

When using these macros, remember that printouts will only include whichever card (ie. tab) is selected within each deck on a page.

Try not to nest decks of cards within each other (as seen in our examples). While it can be tempting to have a deck of sections with each section containing a deck of topics and each topic containing a deck of sub-topics, it can be very confusing for the end user if they are presented with such a structure - it's easy to loose track of where you are in relation to the other content. Instead, you should consider using the cloak macro for the inner content.

See Also



Ask questions, get help and report bugs & issues on our Community Site

View old comments


Adaptavist Theme Builder Powered by Atlassian Confluence