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

fmt_markdown breaks a line and put footnote reference onto new line #993

Closed
Dobrokhotov1989 opened this issue Jul 24, 2022 · 1 comment · Fixed by #1013
Closed

fmt_markdown breaks a line and put footnote reference onto new line #993

Dobrokhotov1989 opened this issue Jul 24, 2022 · 1 comment · Fixed by #1013

Comments

@Dobrokhotov1989
Copy link

I've faced an issue when trying to use footnote on the cells formatted with fmt_markdown(). With fmt_markdown() linebreak between cell content and footnote reference (i.e. 1) is added. In the example below, fmt_markdown() does nothing useful but shows the problem.

  library(tidyverse)
  library(gt)
  
  mpg %>%
    sample_n(10) %>%
    select(manufacturer, model, displ, cty, hwy, year) %>%
    gt() %>%
    tab_footnote(
      footnote = "This is old car",
      locations = cells_body(columns = model,
                             rows = year < 2000)
    ) %>%
    cols_hide(columns = year) %>%
    fmt_markdown(columns = model)

Rplot01

@rich-iannone
Copy link
Member

Thank you for discovering this bug and bringing it to our attention! This is a fairly bad bug that could be solved without too much effort (I think!), so, I hope to have a fix ready soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment