From 2224ad78e7e832959aa0f842ff1f0a9b20d59a6b Mon Sep 17 00:00:00 2001 From: Carlos Scheidegger Date: Wed, 18 Dec 2024 12:17:10 -0700 Subject: [PATCH 1/4] wrap HTML in rawblocks to avoid pandoc parsing memory blowup in large listings --- src/resources/projects/website/listing/listing-default.ejs.md | 2 ++ src/resources/projects/website/listing/listing-grid.ejs.md | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/resources/projects/website/listing/listing-default.ejs.md b/src/resources/projects/website/listing/listing-default.ejs.md index a191a600f2..079f301cfa 100644 --- a/src/resources/projects/website/listing/listing-default.ejs.md +++ b/src/resources/projects/website/listing/listing-default.ejs.md @@ -1,5 +1,7 @@ :::{.list .quarto-listing-default} +```{=html} <% for (const item of items) { %> <% partial('item-default.ejs.md', {listing, item, utils }) %> <% } %> +``` ::: diff --git a/src/resources/projects/website/listing/listing-grid.ejs.md b/src/resources/projects/website/listing/listing-grid.ejs.md index 855865c50c..f049b94bb3 100644 --- a/src/resources/projects/website/listing/listing-grid.ejs.md +++ b/src/resources/projects/website/listing/listing-grid.ejs.md @@ -3,7 +3,9 @@ const cols = listing['grid-columns']; %> :::{.list .grid .quarto-listing-cols-<%=cols%>} +```{=html} <% for (const item of items) { %> <% partial('item-grid.ejs.md', {listing, item, utils }) %> <% } %> +``` ::: From 98a0db04fc34633ab6d3bf02411a94fa4184425e Mon Sep 17 00:00:00 2001 From: Carlos Scheidegger Date: Wed, 18 Dec 2024 12:18:57 -0700 Subject: [PATCH 2/4] changelog --- news/changelog-1.7.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/news/changelog-1.7.md b/news/changelog-1.7.md index e9d7589e4e..02b92a2287 100644 --- a/news/changelog-1.7.md +++ b/news/changelog-1.7.md @@ -11,7 +11,11 @@ All changes included in 1.7: - ([#11654](https://github.com/quarto-dev/quarto-cli/issues/11654)): Allow `page-inset` as value in `column` key for code cells. -## Book Project +## Website projects + +- ([#11701](https://github.com/quarto-dev/quarto-cli/issues/11701)): Wrap HTML emitted by EJS templates in `{=html}` blocks to avoid memory blowup issues with Pandoc's parser. + +## Book projects - ([#11520](https://github.com/quarto-dev/quarto-cli/issues/11520)): Book's cover image now escapes lightbox treatment, which was incorrectly applied to it when `lightbox: true` was set in the book's configuration. From 9828b2e482fe460410025370effc2cb304bddc10 Mon Sep 17 00:00:00 2001 From: Carlos Scheidegger Date: Wed, 18 Dec 2024 12:44:52 -0700 Subject: [PATCH 3/4] wrap html in rawblock --- src/resources/projects/website/listing/listing-table.ejs.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/resources/projects/website/listing/listing-table.ejs.md b/src/resources/projects/website/listing/listing-table.ejs.md index 14b56db05b..864a26f70f 100644 --- a/src/resources/projects/website/listing/listing-table.ejs.md +++ b/src/resources/projects/website/listing/listing-table.ejs.md @@ -64,6 +64,7 @@ return listing.utilities.outputLink(item, field, value, `listing-${field}`); } %> +```{=html} @@ -90,3 +91,4 @@ return listing.utilities.outputLink(item, field, value, `listing-${field}`); <% } %>
+``` \ No newline at end of file From 38e445d793627beef2d8a7a074d9a2a8b9017d80 Mon Sep 17 00:00:00 2001 From: Carlos Scheidegger Date: Wed, 18 Dec 2024 12:51:40 -0700 Subject: [PATCH 4/4] remove rawinline from template bc it is all in a rawblock now --- src/resources/projects/website/listing/item-default.ejs.md | 2 +- src/resources/projects/website/listing/item-grid.ejs.md | 2 +- src/resources/projects/website/listing/listing-default.ejs.md | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/resources/projects/website/listing/item-default.ejs.md b/src/resources/projects/website/listing/item-default.ejs.md index 278b153b32..edaebc664f 100644 --- a/src/resources/projects/website/listing/item-default.ejs.md +++ b/src/resources/projects/website/listing/item-default.ejs.md @@ -65,7 +65,7 @@ print(`