pkgdown icon indicating copy to clipboard operation
pkgdown copied to clipboard

Awkward formatting in "DBI specification" article

Open krlmlr opened this issue 3 years ago • 1 comments

https://dbi.r-dbi.org/articles/spec

image

This vignette is generated with a very unconventional way, so might be not representative. I'd appreciate any hints on how to fix the layout on my end.

krlmlr avatar Feb 03 '22 20:02 krlmlr

The key problem is that the divs for each section somehow get the class "container". If you remove that, the problem goes away. How are you making this vignette?

hadley avatar May 31 '22 21:05 hadley

Still a problem today. Vignette source at https://github.com/r-dbi/DBI/blob/main/vignettes/spec.Rmd

hadley avatar Apr 12 '24 14:04 hadley

Looks okay to me in Firefox now. What browser are you using, what is wrong with the display? https://dbi.r-dbi.org/articles/spec.html

The rendering process has changed, the contents are now essentially this Markdown file: https://raw.githubusercontent.com/r-dbi/DBI/a23c544adb11eebc4f3372e99177172f723cee23/vignettes/spec.md .

krlmlr avatar Apr 13 '24 06:04 krlmlr

I still see the same problem as in your initial screenshot, i.e. DBI: R Database Interface and subheadings are indented. I'm using safari.

hadley avatar Apr 15 '24 13:04 hadley

Right, the subheaders are indented, but they no longer overflow.

Confirming the "container" class as likely cause of this problem, also on Firefox (right-clicking "DBI: R Database Interface" -> Inspect, the outer element has this "container" class).

The vignette is now dead simple, a single "asis" chunk:

https://github.com/r-dbi/DBI/blob/453148fa5327356cd29e543eb49b472fc2d7144a/vignettes/spec.Rmd#L26-L28

This chunk reads an .md file from disk and prints it: https://github.com/r-dbi/DBI/blob/453148fa5327356cd29e543eb49b472fc2d7144a/vignettes/spec.md

Coud the "asis" chunk be the problem here? @maelle: can you please help?

krlmlr avatar Apr 15 '24 13:04 krlmlr

Ok, planning to have a look tomorrow

maelle avatar Apr 15 '24 14:04 maelle

Now suspecting Pandoc as it renders fine locally.

maelle avatar Apr 16 '24 08:04 maelle

https://maelle.github.io/notdbi/articles/spec.html is fine :upside_down_face: (same source as the DBI vignette)

maelle avatar Apr 16 '24 08:04 maelle

but these two workflows are using the same Pandoc version.

https://github.com/r-dbi/DBI/actions/runs/8505670650/job/23294557762

https://github.com/maelle/notdbi/actions/runs/8702331645/job/23866158124

maelle avatar Apr 16 '24 09:04 maelle

knitr 1.45 2023-10-30 in DBI

vs

knitr 1.46 2024-04-06 [1] RSPM in my reprex

@krlmlr could you please delete the actions cache for the DBI pkgdown workflow?

maelle avatar Apr 16 '24 09:04 maelle

Looks good in dev: https://dbi.r-dbi.org/dev/articles/spec.html

I've pushed to the docs branch, now looks good on the main site too: https://dbi.r-dbi.org/articles/spec.html

Closing, please reopen if needed.

krlmlr avatar Apr 16 '24 11:04 krlmlr