markbind
markbind copied to clipboard
Minimized panels: support a way to show in previous line
Current: minimized panels appear in a new line, although multiple minimized panels can appear in a single line.
Suggest: support a way to push a panel that are minimized by default to the end of the previous line. Reason: Saves vertical space (more printer friendly)
Example:
Some text. Some text. Minimized Panel 1Panel 2
If we do not leave a new line after "Some text, some text", the panels will be minimized at the end of the previous line:
Some text, some text
<panel type="info" header="Minimized panel 1" minimized >
Content 1
</panel>
<panel type="info" header="Minimized panel 2" minimized >
Content 2
</panel>
Output:
You mean it is like that already?
You mean it is like that already?
Yes, it already works. I didn't change any code.
It works only for trivial cases. If you add blank lines inside one of the panels, it won't work anymore. This code results in totally unexpected behavior:
Some text, some text
<panel type="info" header="Minimized panel 1" minimized >
* Content 1
* Content 2
</panel>
Hello! I just tried out the code and currently this gives:
Some text, some text
<panel type="info" header="Minimized panel 1" minimized >
* Content 1
* Content 2
</panel>
<panel type="info" header="Minimized panel 1" minimized >
* Content 1
* Content 2
</panel>
to give
.
However, removing the new line:
Some text, some text
<panel type="info" header="Minimized panel 1" minimized >
* Content 1
* Content 2
</panel>
<panel type="info" header="Minimized panel 1" minimized >
* Content 1
* Content 2
</panel>
results in
Seems like its an issue with the new line and parsing..
For the original issue, I am unsure if there is still a need to show minimized panels on one line, given that users can always alternate towards popover components instead. And given that we have ways to hide minimized panels for print view, introduced into the User Guide in 2019 (after discussion on this issue died down), I am wondering if the issue is still relevant @damithc?
On a separate note, @yucheng11122017 I think we can file the bug you found as a separate issue relating to newlines if we decide to close the original issue 👍
On a separate note, @yucheng11122017 I think we can file the bug you found as a separate issue relating to newlines if we decide to close the original issue 👍
Yup I think this makes sense! We can include it in issue #500 if that makes sense
For the original issue, I am unsure if there is still a need to show minimized panels on one line, given that users can always alternate towards popover components instead. And given that we have ways to hide minimized panels for print view, introduced into the User Guide in 2019 (after discussion on this issue died down), I am wondering if the issue is still relevant @damithc?
Although it is not explicitly stated in my original description, what I'm aiming for is to use panels to achieve inline expansion/collapse of content so that the reader can control the level of details in a contiguous chunk of content. Content that pops doesn't give the same visual outcome. However, I'm fine to let panels be what they are now, and use an entirely different syntax for inline-expandable text. e.g.,
Bat is a nocturnal animal. <inline header="more info on their behavior">They
hunt at night and sleep during the day</inline>