11---
2- # Issue #14575: with tbl-cap-location: bottom, the caption of a
3- # cross-referenceable table whose content is wrapped in
4- # .cell-output-display (knitr/jupyter engine output) is placed inside
5- # the longtable body instead of in the foot (\endlastfoot).
6- #
7- # This file covers the markdown-only cases (CI-safe, no engine needed).
8- # Correct behaviour: the bottom caption sits in the longtable foot,
9- # i.e. \caption{...}\tabularnewline immediately before \endlastfoot.
10- #
11- # Cases 1-4 already render correctly (regression guards).
12- # Cases 5-6 are the bug (currently fail; should pass after the fix).
2+ # Issue #14575 — markdown-only cases (CI-safe, no engine needed).
3+ # See the body below for what each case exercises.
134format : pdf
145tbl-cap-location : bottom
156keep-tex : true
@@ -20,20 +11,24 @@ _quarto:
2011 ensureLatexFileRegexMatches :
2112 -
2213 - ' \\end\{document\}'
23- # Case 1: markdown table + caption syntax, no id (guard)
2414 - ' \\caption\{[\s\S]{0,60}CAP1 caption[\s\S]{0,60}\\tabularnewline\s*\\endlastfoot'
25- # Case 2: markdown table + caption syntax + id (guard)
2615 - ' \\caption\{[\s\S]{0,60}CAP2 caption[\s\S]{0,60}\\tabularnewline\s*\\endlastfoot'
27- # Case 3: div float + bare table + trailing caption paragraph (guard)
2816 - ' \\caption\{[\s\S]{0,60}CAP3 caption[\s\S]{0,60}\\tabularnewline\s*\\endlastfoot'
29- # Case 4: div float + tbl-cap attribute + bare table (guard)
3017 - ' \\caption\{[\s\S]{0,60}CAP4 caption[\s\S]{0,60}\\tabularnewline\s*\\endlastfoot'
31- # Case 5: div float + tbl-cap + .cell-output-display (the bug)
3218 - ' \\caption\{[\s\S]{0,60}CAP5 caption[\s\S]{0,60}\\tabularnewline\s*\\endlastfoot'
33- # Case 6: .cell + .cell-output-display, mcanouil reprex (the bug)
3419 - ' \\caption\{[\s\S]{0,60}CAP6 caption[\s\S]{0,60}\\tabularnewline\s*\\endlastfoot'
3520---
3621
22+ With ` tbl-cap-location: bottom ` , a cross-referenceable table's bottom caption
23+ must land in the longtable foot — ` \caption{...}\tabularnewline ` immediately
24+ before ` \endlastfoot ` — not after the data rows inside the table body. Each
25+ ` CAPn caption ` assertion above checks that placement for one input shape.
26+
27+ Cases 1–4 already rendered correctly before the fix and act as regression
28+ guards. Cases 5–6 wrap the table in a ` .cell-output-display ` Div (the shape
29+ Quarto produces for knitr/Jupyter output); these triggered the bug and pass
30+ only after the fix.
31+
3732# Case 1: markdown table, caption syntax, no id
3833
3934| speed| dist|
0 commit comments