Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spanners appear incorrect in tables produced with gt #10534

Closed
snhansen opened this issue Aug 16, 2024 · 3 comments
Closed

Spanners appear incorrect in tables produced with gt #10534

snhansen opened this issue Aug 16, 2024 · 3 comments
Assignees
Labels
support a request for support

Comments

@snhansen
Copy link

Bug description

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

Your environment

  • On Windows 11.
  • gt v. 0.11.0

Quarto check output

Quarto 1.6.4
[>] Checking versions of quarto binary dependencies...
	  Pandoc version 3.2.0: OK
	  Dart Sass version 1.70.0: OK
	  Deno version 1.41.0: OK
	  Typst version 0.11.0: OK
[>] Checking versions of quarto dependencies......OK
[>] Checking Quarto installation......OK
	  Version: 1.6.4
	  Path: C:\Users\au234616\AppData\Local\Programs\Quarto\bin
	  CodePage: 1252

[>] Checking tools....................OK
	  TinyTeX: (not installed)
	  Chromium: (not installed)

[>] Checking LaTeX....................OK
	  Tex:  (not detected)

[>] Checking basic markdown render....OK

[>] Checking Python 3 installation....OK
	  Version: 3.11.1
	  Path: C:/Users/au234616/AppData/Local/Programs/Python/Python311/python.exe
	  Jupyter: 5.2.0
	  Kernels: python3

[>] Checking Jupyter engine render....OK

[>] Checking R installation...........OK
	  Version: 4.4.0
	  Path: C:/PROGRA~1/R/R-44~1.0
	  LibPaths:
		- C:/Users/au234616/AppData/Local/R/win-library/4.4
		- C:/Program Files/R/R-4.4.0/library
	  knitr: 1.47
	  rmarkdown: 2.27

[>] Checking Knitr engine render......OK
@snhansen snhansen added the bug Something isn't working label Aug 16, 2024
@cscheid
Copy link
Collaborator

cscheid commented Aug 16, 2024

Thanks, I can repro.

The typical html-table-processing: none workaround does apply here, so that might be something you want to use.

@cscheid cscheid added the tables Issues with Tables including the gt integration label Aug 16, 2024
@cscheid cscheid self-assigned this Aug 16, 2024
@cscheid
Copy link
Collaborator

cscheid commented Aug 16, 2024

This is currently a GT bug. The HTML doesn't validate. Quarto requires the HTML to validate before we can make promises about the behavior.

See below.

image

@cscheid cscheid closed this as not planned Won't fix, can't repro, duplicate, stale Aug 16, 2024
@cscheid cscheid removed tables Issues with Tables including the gt integration bug Something isn't working labels Aug 16, 2024
@cscheid
Copy link
Collaborator

cscheid commented Aug 16, 2024

(In the feature, please make sure to check if the HTML generated by GT validates before filing a bug. Thanks!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support a request for support
Projects
None yet
Development

No branches or pull requests

3 participants