Additional Features

Additional Features

Collapsible Example Blocks

AsciiDoc collapsible example blocks are translated to Confluence with help of the expand macro.

[%collapsible] ==== This content is revealed when the label is clicked. ====

This content is revealed when the label is clicked.

An optional block title can be specified:

.Toggle Me [%collapsible] ==== This content is revealed when the "Toggle Me" label is clicked. ====

This content is revealed when the "Toggle Me" label is clicked.

Non-collapsible example blocks are currently converted to a tip admonition, since Confluence does not provide any specified example element.

Using the open option on collapsible expand blocks is currently not supported.

Source File Information

The Confluence Publisher automatically exposes information about the source AsciiDoc file being processed through built-in attributes. These attributes can be used in your AsciiDoc content to reference information about the current file:

Attribute

Description

Example Value

Attribute

Description

Example Value

cp-source-path

The relative path of the source file from the base directory

pages/user-guide.adoc

cp-source-file

The filename of the source file including extension

user-guide.adoc

cp-source-name

The filename of the source file without extension

user-guide

Usage Examples

The source file path is: {cp-source-path}

The source file path is: 00-index/13-additional-features.adoc

This page was generated from: {cp-source-file}

This page was generated from: 13-additional-features.adoc

The page name is: {cp-source-name}

The page name is: 13-additional-features