Use table.header()
in table with only one column
#4017
-
I'm trying to create a table with repeating headers for a table that only has one column. What I tried is this: #let date = datetime.today().display()
#show table.header : it => strong(it)
#figure(
align(center,
)[#table(
columns: 1,
align: left,
inset: 6pt,
table.header([Date],[Text 1], [Text 2]),
[#date],
[#lorem(15)],
[#lorem(30)],
)],
caption: [Journal from #date]
) On a side note: Would it be alright to open a feature request for this? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
The table header cannot be split apart, otherwise we don't have a way to correctly repeat it. The behavior you see is intended - specifying cells in a header is similar to not having the header there at all. Since there is just one column, each cell triggers a row break. You could open a feature request, but I'd suggest just typesetting your table manually for the time being, as the feature you seek seems complex to design, let alone implement. |
Beta Was this translation helpful? Give feedback.
The table header cannot be split apart, otherwise we don't have a way to correctly repeat it.
The behavior you see is intended - specifying cells in a header is similar to not having the header there at all. Since there is just one column, each cell triggers a row break.
You could open a feature request, but I'd suggest just typesetting your table manually for the time being, as the feature you seek seems complex to design, let alone implement.