Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Comments

fix footnote marks in summary stub + footmark render in cells_stubhead() in opt_interactive() #1833

Merged
rich-iannone merged 3 commits intorstudio:masterfrom
olivroy:cov-footnote
Aug 16, 2024
Merged

fix footnote marks in summary stub + footmark render in cells_stubhead() in opt_interactive() #1833
rich-iannone merged 3 commits intorstudio:masterfrom
olivroy:cov-footnote

Conversation

@olivroy
Copy link
Collaborator

@olivroy olivroy commented Aug 15, 2024

Summary

The footnote marks issue took me a while to figure out! Turns out it was a one-liner. Updating the reference to "::rowname::" magically solved the issue!

In a future PR, we could change this to rowname_col_private.

exibble %>% gt() %>% grand_summary_rows(fns = "sum", columns = tidyselect::where(is.numeric)) %>% tab_footnote("xx", locations = cells_stub_grand_summary())

before
image

This PR
image

The tests are maybe wonky? I am just testing that we see a footnote mark in the table body. (before the footer)


For the stubhead issue, the problem was that html was FALSE before

It made footnote rendering bad:
Capture d’écran, le 2024-08-15 à 12 16 29 p m

Adding html = TRUE to colDef() fixes the issue!

Related GitHub Issues and PRs

Checklist

@olivroy olivroy changed the title Add more tests for tab_footnote() + fix some styling Add more tests for tab_footnote() + fix some footnote rendering with cells_stubhead() in opt_interactive() Aug 15, 2024
@olivroy olivroy changed the title Add more tests for tab_footnote() + fix some footnote rendering with cells_stubhead() in opt_interactive() fix footnote marks in summary stub + footmark render in cells_stubhead() in opt_interactive() Aug 15, 2024
@rich-iannone
Copy link
Member

Thank you!

@rich-iannone rich-iannone merged commit f7faec9 into rstudio:master Aug 16, 2024
@olivroy olivroy deleted the cov-footnote branch August 16, 2024 06:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Footnote marks are not added to the summary stub with cells_stub_grand_summary()

2 participants