nimib icon indicating copy to clipboard operation
nimib copied to clipboard

New nbDetails block?

Open neroist opened this issue 2 years ago • 2 comments

It would be cool to have a block using the <summary> and <details> html tags like this:

<details>
  <summary>
    
      summary

   </summary>

  details
</details>

This could be used in a Q&A section, long blobs of text, etc...

neroist avatar May 09 '23 18:05 neroist

indeed we showed how to produce a simple implementation of that in our latest nimib presentation: https://github.com/pietroppeter/nimconf22-nimib/blob/bb874c6f2d2fcb77c7bd4fbffbe906a8df95ebdc/pietros_slides.nim#L343 (in principle you could see the slides here but I do not know how to link to a specific slides in nimislides).

ideally an improved version would make use of the container block concept (still not available) to support multiple mixed blocks (code + text + images + ...) inside the details.

Not sure if we want already to put the simple implementation inside nimib or not...

pietroppeter avatar May 10 '23 08:05 pietroppeter

The simple implementation looks fine to me!

neroist avatar May 17 '23 02:05 neroist