From 74fd83b0b9f01717f85aa34da60128a2e9e4a77d Mon Sep 17 00:00:00 2001 From: Jay Hesselberth Date: Tue, 21 May 2024 17:31:42 -0600 Subject: [PATCH 1/2] Test quarto vignette rendering Closes #2210 --- DESCRIPTION | 1 + NEWS.md | 1 + vignettes/test/quarto.qmd | 9 +++++++++ 3 files changed, 11 insertions(+) create mode 100644 vignettes/test/quarto.qmd diff --git a/DESCRIPTION b/DESCRIPTION index 72aa52cf9..bf8991dd6 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -58,6 +58,7 @@ Suggests: rstudioapi, rticles, rvest, + quarto, sass, testthat (>= 3.1.3), tools diff --git a/NEWS.md b/NEWS.md index 5b1a15a90..e87fd55d1 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,5 +1,6 @@ # pkgdown (development version) +* A new test vignette illustrates using quarto vignettes in pkgdown sites (#2210). * YAML validation has been substantially improved so you should get much clearer errors if you have made a mistake (#1927). Please file an issue if you find a case where the error message is not helpful. * `template_reference()` and `template_article()` now only add backticks to function names if needed (#2561). * Custom navbars that specify `icon` but not `aria-label` will now generate a message reminding you to provide one for to improve accessibility (#2533). diff --git a/vignettes/test/quarto.qmd b/vignettes/test/quarto.qmd new file mode 100644 index 000000000..36157fea8 --- /dev/null +++ b/vignettes/test/quarto.qmd @@ -0,0 +1,9 @@ +--- +title: "Quarto vignette" +vignette: > + %\VignetteIndexEntry{Quarto vignette} + %\VignetteEngine{quarto::html} + %\VignetteEncoding{UTF-8} +--- + +Example of rendering a quarto vignette. From de5ce38f2d6ceea4341eb08fe4997e55664c7b35 Mon Sep 17 00:00:00 2001 From: Jay Hesselberth Date: Tue, 21 May 2024 17:50:43 -0600 Subject: [PATCH 2/2] try out figure numbers and xref --- vignettes/test/quarto.qmd | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/vignettes/test/quarto.qmd b/vignettes/test/quarto.qmd index 36157fea8..7ec879bdd 100644 --- a/vignettes/test/quarto.qmd +++ b/vignettes/test/quarto.qmd @@ -7,3 +7,19 @@ vignette: > --- Example of rendering a quarto vignette. + +## Figure numbers + +```{r, cross-ref} +#| include: false +set.seed(42) +plot(rnorm(100)) +``` + +See \@ref(fig:cross-ref) for a plot. + +## Figure cross-references + +![bacon](bacon.jpg){#fig-bacon} + +See @fig-bacon for an illustration.