rstudio/gt

Spanners appear incorrect when rendering with Quarto

snhansen opened this issue · 1 comments

Table spanners in gt-tables appear above the spanner label and not below as it should when rendering to html.

Steps to reproduce

---
format: html
---

```{r}
mtcars[1:3, 1:4] |> 
  gt::gt() |> 
  gt::tab_spanner(label = gt::md("Header"), columns = 2:3)
```

Expected behavior

image

Actual behavior

image

I posted the issue on the Quarto repository and was told that the HTML emitted by gt doesn't validate in this case (quarto-dev/quarto-cli#10534)

Thanks for the report! We may have identified the source of the problem #1842 (comment)