Creates an expandable block of content.
{{< expand "Text to click to expand content." >}}
Content that is revealed upon expansion.
{{< /expand >}}
Renders to:
Supports Markdown in the expand text.
scroll
: Optional. Imposes a standard maximum height on the expanded text box.{{< expand "Text to click to expand content." scroll >}}
...
{{< /expand >}}
{{< expand "Text to click to expand content." scroll >}}
...
{{< /expand >}}
Renders to:
{{< expand "Text to click to expand content." >}}
Content that is revealed upon expansion.
{{% prism %}}
Prism content.
{{% /prism %}}
{{< /expand >}}
Renders to:
Expand supports shortcodes in the expansion content.
For Hugo to properly render prism
nested in expand
, use %
for the inner prism
shortcode to render its content, and use <
/>
for the outer expand
shortcode to prevent it from rendering twice.
To create a series of expand
s that will only open one at a time, wrap multiple expand
s with accordion
.