The Adaptavist Group LogoDocumentation

Rollover

The Rollover macro allows the quick and easy creation of CSS rollover effects.

Rollover effects are often used to create a button of some kind.

This macro will require additional CSS styling which can be added using the Stylesheet macro, the Confluence Stylesheet or a product such as Adaptavist ThemeBuilder.

The instructions on this page use Stylesheet macro.

Add a Rollover Macro to your page

  1. Navigate to the page you want to edit.
  2. Click Edit.
  3. Click Insert More Content → Other Macros .
  4. Select the Rollover macro from the Macro Browser.
  5. Complete the desired fields.
    Parameter Description Type Default Required
    Normal CSS ClassSpecify the class name for the normal (roll-out) statestringnone
    Roll Over CSS ClassAn optional class name for the roll-over state (defaults to the %class%-rollover)stringclass-rollover
    LinkThe page that the rollover links to when clickedstringnone
    TargetAn optional external target to modify.stringnone
    Target CSS ClassAn optional class name to use solely for the external target (defaults to class)stringnone
    Target Roll Over CSS ClassAn optional class name to use solely for the external target roll-over state (defaults to %targetclass%-rollover)stringnone
    Output TypeSpecifies that the macro will be displayed inline with the surrounding contentsingle selectInline
  6. Click Insert.
    The macro placeholder displays.

Basic Use

The following example shows you how to create a basic rollover using the rollover macro and the Stylesheet macro.

  1. Edit a page and insert a Rollover macro.
  2. In the Normal CSS class field, enter the name of the class (in this example = test)
  3. In the Roll Over CSS class field, enter the name of the class for the rollover state, or leave it blank if you use what is in the Normal CSS class field plus "-rollover" (the default).
  4. Save the macro.
  5. In the Rollover macro placeholder, add a div macro as a container for your rollover text.
  6. Save the page to see the text with a color background that changes on hover.

Search documentation

Start typing to search the docs.