added: APA style table

This commit is contained in:
Sven Vogel 2024-07-08 09:34:33 +02:00
parent f30c0fe950
commit c3d65f93b2
2 changed files with 18 additions and 2 deletions

View File

@ -52,6 +52,19 @@
show figure: set block(breakable: true)
// APA style table
set table(
inset: 0.5em,
align: left,
stroke: (x, y) => (
left: none,
right: none,
top: if y == 0 { 1.5pt } else if y < 2 { 1pt } else { 0pt },
bottom: if y == 0 { 1pt } else { 1.5pt } ))
// make table header bold
show table.cell.where(y: 0): set text(weight: "bold")
set block(spacing: 2em)
set par(
justify: true,

View File

@ -63,8 +63,11 @@ $
#figure(
table(
columns: 2,
"Hello", "World"),
columns: 3,
table.header[Date][Exercise Type][Calories Burned],
[2023-03-15], [Swimming], [400],
[2023-03-17], [Weightlifting], [250],
[2023-03-18], [Yoga], [200]),
caption: [ Some table ])
#pagebreak()