Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Render details admonitions as <details> in HTML backend #2128

Merged
merged 2 commits into from
May 27, 2023
Merged

Conversation

fredrikekre
Copy link
Member

This patch renders admonitions with category details as <details> in the HTML output. The admonition title is used for the <summary>. For example

!!! details "Expand for more details"
    Here are the details.

is rendered as

<details>
  <summary>
    Expand for more details
  </summary>
  Here are the details.
</details>

This patch renders admonitions with category `details` as `<details>` in
the HTML output. The admonition title is used for the `<summary>`. For
example
```markdown
!!! details "Expand for more details"
    Here are the details.
```
is rendered as
```html
<details>
  <summary>
    Expand for more details
  </summary>
  Here are the details.
</details>
```
@mortenpi mortenpi added Type: Enhancement Format: HTML Related to the default HTML output labels May 24, 2023
@fredrikekre
Copy link
Member Author

Screenshot 2023-05-24 at 02 55 51

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Format: HTML Related to the default HTML output Type: Enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants