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

Here is an example:

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:

Parameters

Parameter

Default

Description

Title


Click here to expand...

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

Code examples

The following examples are provided for advanced users who want to inspect or edit the underlying markup for a Confluence page. 

Macro name: expand

Macro body: Accepts rich text.

Storage format example

<ac:structured-macro ac:name="expand">
  <ac:parameter ac:name="title">Expand me...</ac:parameter>
  <ac:rich-text-body>
    
<p>This text is hidden until you expand the section.</p>
  </ac:rich-text-body>
</ac:structured-macro>

Wikimarkup example

{expand:This is my message}
This text is _hidden_ until you expand it.
{expand}

Notes