The Expand macro displays an expandable/collapsible section of text on your page.

Here is an example:

Click here to expand...

This text is hidden until you expand the section.

Using the Expand Macro

To insert the Expand macro into a page using the macro browser:

  1. In the Confluence editor, choose Insert > Other Macros.
  2. Find and select the required macro.

Speeding up macro entry with autocomplete: Type { and the beginning of the macro name, to see a list of suggested macros. Details are in Using Autocomplete.

To edit an existing macro: Click the macro placeholder and choose Edit. A macro dialog window will open, where you can edit the parameters of the macro.

 

On this page:

Related pages:

Parameters

Parameters are options that you can set to control the content or format of the macro output.

Parameter

Default

Description

Title

Click here to expand...

Defines the text that appears next to the expand/collapse icon.

Code examples

See:

Notes

  • Text is expanded in PDF and HTML exports. When you export the page to PDF or HTML, the text between the macro tags is expanded so that readers can see it in the PDF and HTML versions of the page.
  • Nesting your Expand macros. You can put one Expand macro inside another, and Confluence will correctly show and hide the contents of all Expand macros, including the nested ones.