Skip to content

Markdown table in PDF gets incorrect renderings due to longtable usage by Pandoc #13095

@cderv

Description

@cderv

Discussed in #13063

---
format: pdf
keep-tex: true
---

| a | b |
|---|---|
| 1 | 2 |


| a | b |
|---|---|
| 1 | 2 |

: Caption {#tbl-test}

Counter gets incremented

Image

Because longtable is used by the first table

\begin{document}


\begin{longtable}[]{@{}ll@{}}
\toprule\noalign{}
a & b \\
\midrule\noalign{}
\endhead
\bottomrule\noalign{}
\endlastfoot
1 & 2 \\
\end{longtable}

\begin{longtable}[]{@{}ll@{}}
\caption{Caption}\label{tbl-test}\tabularnewline
\toprule\noalign{}
a & b \\
\midrule\noalign{}
\endfirsthead
\toprule\noalign{}
a & b \\
\midrule\noalign{}
\endhead
\bottomrule\noalign{}
\endlastfoot
1 & 2 \\
\end{longtable}




\end{document} 

It seems we missed something in our tests - the documents are compiling, but the counter fix is not working.

This could also be related to a change in LaTeX package - more complex to know.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingcrossreflatexLaTeX engines related libraries and technologiestablesIssues with Tables including the gt integration

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions