Details

Add a disclosure widget with the Doks details shortcode. Information is visible only when the widget is toggled into open state.

Usage

{{< details <summary> [state] >}}
<content>
{{< /details >}}

Examples

Markdown and HTML

{{< details "Markdown and HTML" >}}
_Markdown_ and <em>HTML</em> will be rendered.
{{< /details >}}
Markdown and HTML Markdown and HTML will be rendered.

Ordered list

{{< details "Ordered list" >}}

1. step 1
2. step 2
3. step 3

{{< /details >}}
Ordered list
  1. step 1
  2. step 2
  3. step 3

Nested details

{{< details "Parent" >}}
Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.
{{< details "Child" >}}
Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.
{{< details "Grandchild" >}}
Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.
{{< /details >}}
{{< /details >}}
{{< /details >}}
Parent

Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.

Child

Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.

Grandchild Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.

Start in open state

{{< details "Start in open state" open >}}
Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.
{{< /details >}}
Start in open state Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.

Custom HTML styled summary

{{< details "<span class=\"fw-bold\">Custom HTML styled summary</span>" >}}
Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.
{{< /details >}}
Custom HTML styled summary Doks is a Hugo theme for building secure, fast, and SEO-ready documentation websites, which you can easily update and customize.

Edit this page on GitHub