What is a good Markdown syntax for the spoiler extension? #963
-
|
I am currently reworking my This works in latest Yellow, however only with HTML elements, and not with Markdown. My guess is that this is simply a limitation I have to deal with, but maybe there are other solutions I can try? |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 3 replies
-
|
For inline text I would suggest a shortcut, for example |
Beta Was this translation helpful? Give feedback.
-
|
For slightly more fancy formatted messages I would suggest a |
Beta Was this translation helpful? Give feedback.
-
|
Thanks for your suggestions. I like and marked the notice solution, allthough the syntax is slightly less comfortable than my code block variant, and I still have to find out how to correctly implement this in my extension. Another solution for using code blocks could be a very small markdown parsing function, I remember @GiovanniSalmeri using this nice approach for parsing external files in his Pinboard extension. It doesn't have all the bells and whistles, but at least it is more comfortable to use than HTML. |
Beta Was this translation helpful? Give feedback.
-
|
I changed my opinion about the Markdown syntax for the spoiler extension. I misunderstood which problem you wanted to solve, sorry, perhaps this could be described as collapsible blocks. After looking into different Markdown implementations I couldn't find a good syntax for collapsible blocks. The Markdown syntax for fenced code blocks would be a great match, but it could never be nested, e.g. for collapsible code snippets. Our Markdown syntax for custom block elements is a pretty good match, but it lacks customisable toggle text, e.g. for collapsible FAQ sections. AsciiDoc has its own syntax for collapsible blocks, but, I think the complexity is not what I was looking for. Perhaps add a new syntax for collapsible blocks to our Markdown parser... any thoughts? |
Beta Was this translation helpful? Give feedback.
-
|
I have marked this extension as obsolete and removed it from all topics, as the Markdown parser now has a much better syntax for collapsible blocks. Many thanks for your feedback! 👍 |
Beta Was this translation helpful? Give feedback.
I have marked this extension as obsolete and removed it from all topics, as the Markdown parser now has a much better syntax for collapsible blocks. Many thanks for your feedback! 👍