Closed jthomasmock closed 1 year ago
Can you try splitting them with empty divs instead?
::: {}
:::
Using fenced divs with no attributes works and is a more general approach to explicitly tell Quarto what are the blocks "layout" should use and split across columns.
I used that trick several times in a slow work in progress introductory slides to Quarto. Although, I added an id attribute to make it more "appealing".
I cannot get a grid layout to work when two lists should appear next to each other. I use the following snippet:
::::{layout-ncol=2 layout-nrow=2}
**Header 1**
**Header 2**
- this is the left list
- it should appear on the left
- this is the right list
- it should appear on the right
::::
However, what happens is that the right list just gets appended to the left list, and thus appears in the left column. I cannot add named or empty divs, because this messes with the flow of the rows. There is probably a more elegant way to do this, but I don't think this set-up is that exotic. Any pointers? Thanks!
I found the solution to my problem in this discussion. The correct syntax for my problem would be:
::: {layout-ncol="2"}
:::: {#first-column}
**Header 1**
- this is the left list
- it should appear on the left
:::
::: {#second-column}
**Header 2**
- this is the right list
- it should appear on the right
:::
::::
This produces the correct output:
I would greatly appreciate more documentation, or at least examples, around the ways you can use the layout-ncol
feature. Many thanks in advance.
Proposed Actions:
Bug description
Good morning Quarto crew!
Running on RStudio 2022.12.0+353 with Quarto 1.2.269 on Mac OSX
I would expect to be able to split up lists by providing a newline in between the list elements.
The Quarto Markdown docs do not cover how to "split up" lists, for example, long lists to be used in presentations or multi-column layouts. There are various ways depending on the markdown flavor based on Google search, but most are reliant on HTML, and it's not clear if they will transfer 1:1 across formats, for example, at Stack Overflow.
However, per the Pandoc guide, I guess the best method is a blank HTML comment which is parsed and ignored?
In general, lists are kind of inconsistent across markdown flavors, and it may be worth beefing up the Quarto documentation or linking out to the canonical methods; again, see something like Stack Overflow or Pandoc guide.
Ideally, we could do something like this to safely and across format indicates to the Quarto/Pandoc parser that a list is broken up into several unrelated lists.
However, the various mechanisms don't appear to work as far as I'd expect (and this reprex also breaks sourcecode embedding? đŸ˜¬ )
Reprex at: QuartoPub