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

Inaccurate Rd to html conversion for tables with empty cells #645 Issue is persisting #780

Closed
aravind-j opened this issue Aug 6, 2018 · 7 comments

Comments

@aravind-j
Copy link

@aravind-j aravind-j commented Aug 6, 2018

After the issue #645 was closed, the error message has disappeared, but the tables are not still as expected,

The empty cells are shifting.

Here are the links to the specific lines for one such table.

Rd - roxygen2
https://github.com/aravind-j/rmelting/blob/c54cede6852bbff36cf3ae8cd5403fbc2292a0e6/man/melting.Rd#L285-L299

html
https://github.com/aravind-j/rmelting/blob/c54cede6852bbff36cf3ae8cd5403fbc2292a0e6/docs/reference/melting.html#L499-L517

pkgdown

Expected
required

@hadley

This comment has been hidden.

@hadley hadley added the reprex label Nov 12, 2018
@aravind-j

This comment has been hidden.

@hadley

This comment has been hidden.

@aravind-j

This comment has been hidden.

@hadley

This comment has been hidden.

@hadley hadley removed the reprex label Nov 19, 2018
@jayhesselberth

This comment has been hidden.

@hadley hadley added this to the pkgdown 1.2.0 milestone Nov 19, 2018
@hadley
Copy link
Member

@hadley hadley commented Nov 20, 2018

Even more minimal reprex:

library(pkgdown)

x1 <- "\\tabular{lll}{A \\tab B \\tab C \\cr A \\tab\\tab C}"
cat(rd2html(x1), sep = "\n")
#> Warning in matrix(cell_contents, ncol = length(align), byrow = TRUE): data
#> length [5] is not a sub-multiple or multiple of the number of rows [2]
#> <table class='table'>
#> <tr><td>A</td><td>B</td><td>C</td></tr>
#> <tr><td>A</td><td>C</td><td>A</td></tr>
#> </table>

x2 <- "\\tabular{lll}{A \\tab B \\tab\\cr A \\tab B \\tab C}"
cat(rd2html(x2), sep = "\n")
#> Warning in matrix(cell_contents, ncol = length(align), byrow = TRUE): data
#> length [5] is not a sub-multiple or multiple of the number of rows [2]
#> <table class='table'>
#> <tr><td>A</td><td>B</td><td>A</td></tr>
#> <tr><td>B</td><td>C</td><td>A</td></tr>
#> </table>

Created on 2018-11-20 by the reprex package (v0.2.1)

@hadley hadley closed this in e1e6e68 Nov 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants